Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
94 ashish 1
#
3431 rajveer 2
# Autogenerated by Thrift Compiler (0.7.0)
94 ashish 3
#
4
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
#
6
 
7
from thrift.Thrift import *
3376 rajveer 8
import shop2020.thriftpy.generic.GenericService
94 ashish 9
from ttypes import *
10
from thrift.Thrift import TProcessor
11
from thrift.transport import TTransport
3431 rajveer 12
from thrift.protocol import TBinaryProtocol, TProtocol
94 ashish 13
try:
14
  from thrift.protocol import fastbinary
15
except:
16
  fastbinary = None
17
 
18
 
3376 rajveer 19
class Iface(shop2020.thriftpy.generic.GenericService.Iface):
94 ashish 20
  def createTransaction(self, transaction):
21
    """
22
    Parameters:
23
     - transaction
24
    """
25
    pass
26
 
27
  def getTransaction(self, id):
28
    """
29
    Parameters:
30
     - id
31
    """
32
    pass
33
 
34
  def getTransactionsForCustomer(self, customerId, from_date, to_date, status):
35
    """
36
    Parameters:
37
     - customerId
38
     - from_date
39
     - to_date
40
     - status
41
    """
42
    pass
43
 
132 ashish 44
  def getTransactionsForShoppingCartId(self, shoppingCartId):
45
    """
46
    Parameters:
47
     - shoppingCartId
48
    """
49
    pass
50
 
94 ashish 51
  def getTransactionStatus(self, transactionId):
52
    """
53
    Parameters:
54
     - transactionId
55
    """
56
    pass
57
 
58
  def changeTransactionStatus(self, transactionId, status, description):
59
    """
60
    Parameters:
61
     - transactionId
62
     - status
63
     - description
64
    """
65
    pass
66
 
1398 varun.gupt 67
  def enqueueTransactionInfoEmail(self, transactionId):
1382 varun.gupt 68
    """
69
    Parameters:
70
     - transactionId
71
    """
72
    pass
73
 
483 rajveer 74
  def getAllOrders(self, status, from_date, to_date, warehouse_id):
94 ashish 75
    """
76
    Parameters:
483 rajveer 77
     - status
78
     - from_date
79
     - to_date
80
     - warehouse_id
94 ashish 81
    """
82
    pass
83
 
999 varun.gupt 84
  def getOrdersByBillingDate(self, status, start_billing_date, end_billing_date, warehouse_id):
85
    """
1132 chandransh 86
    Returns orders within a range of their billing dates
3431 rajveer 87
 
999 varun.gupt 88
    Parameters:
89
     - status
90
     - start_billing_date
91
     - end_billing_date
92
     - warehouse_id
93
    """
94
    pass
95
 
3451 chandransh 96
  def getOrdersByShippingDate(self, fromShippingDate, toShippingDate, providerId, warehouseId, cod):
3427 chandransh 97
    """
98
    Returns orders for a particular provider and warehouse which were shipped between the given dates.
3451 chandransh 99
    Returned orders comprise of COD orders if cod parameter is true. It comprises of prepaid orders otherwise.
100
    Pass providerId and warehouseId as -1 to ignore both these parameters.
3431 rajveer 101
 
3427 chandransh 102
    Parameters:
103
     - fromShippingDate
104
     - toShippingDate
105
     - providerId
106
     - warehouseId
3451 chandransh 107
     - cod
3427 chandransh 108
    """
109
    pass
110
 
1382 varun.gupt 111
  def getReturnableOrdersForCustomer(self, customer_id, limit):
112
    """
113
    Returns order ids for orders which can be returned
3431 rajveer 114
 
1382 varun.gupt 115
    Parameters:
116
     - customer_id
117
     - limit
118
    """
119
    pass
120
 
121
  def getCancellableOrdersForCustomer(self, customer_id, limit):
122
    """
123
    Returns order ids for orders which can be cancelled
3431 rajveer 124
 
1382 varun.gupt 125
    Parameters:
126
     - customer_id
127
     - limit
128
    """
129
    pass
130
 
483 rajveer 131
  def changeOrderStatus(self, orderId, status, description):
94 ashish 132
    """
133
    Parameters:
483 rajveer 134
     - orderId
135
     - status
136
     - description
94 ashish 137
    """
138
    pass
139
 
1528 ankur.sing 140
  def getOrdersForTransaction(self, transactionId, customerId):
94 ashish 141
    """
1528 ankur.sing 142
    Returns list of orders for given transaction Id. Also filters based on customer Id so that
143
    only user who owns the transaction can view its order details.
3431 rajveer 144
 
94 ashish 145
    Parameters:
146
     - transactionId
1528 ankur.sing 147
     - customerId
94 ashish 148
    """
149
    pass
150
 
3014 chandransh 151
  def getOrdersForCustomer(self, customerId, from_date, to_date, statuses):
94 ashish 152
    """
3014 chandransh 153
    Returns list of orders for the given customer created between the given dates and having the given statuses.
154
    Pass and empty list to ignore filtering on statuses.
3431 rajveer 155
 
94 ashish 156
    Parameters:
483 rajveer 157
     - customerId
158
     - from_date
159
     - to_date
3014 chandransh 160
     - statuses
94 ashish 161
    """
162
    pass
163
 
483 rajveer 164
  def createOrder(self, order):
94 ashish 165
    """
166
    Parameters:
483 rajveer 167
     - order
94 ashish 168
    """
169
    pass
170
 
483 rajveer 171
  def getOrder(self, id):
94 ashish 172
    """
173
    Parameters:
483 rajveer 174
     - id
94 ashish 175
    """
176
    pass
177
 
483 rajveer 178
  def getLineItemsForOrder(self, orderId):
94 ashish 179
    """
180
    Parameters:
483 rajveer 181
     - orderId
94 ashish 182
    """
183
    pass
184
 
1528 ankur.sing 185
  def getOrderForCustomer(self, orderId, customerId):
186
    """
187
    Returns an order for the order Id. Also checks if the order belongs to the customer whose Id is passed.
188
    Throws exception if either order Id is invalid or order does not below to the customer whose Id is passed.
3431 rajveer 189
 
1528 ankur.sing 190
    Parameters:
191
     - orderId
192
     - customerId
193
    """
194
    pass
195
 
3064 chandransh 196
  def getAlerts(self, orderId, valid):
197
    """
198
    Parameters:
199
     - orderId
200
     - valid
201
    """
202
    pass
203
 
204
  def setAlert(self, orderId, unset, type, comment):
205
    """
206
    Parameters:
207
     - orderId
208
     - unset
209
     - type
210
     - comment
211
    """
212
    pass
213
 
214
  def getValidOrderCount(self, ):
215
    """
216
    Return the number of valid orders. (OrderStatus >= OrderStatus.SUBMITTED_FOR_PROCESSING)
217
    """
218
    pass
219
 
220
  def getNoOfCustomersWithSuccessfulTransaction(self, ):
221
    """
222
    Returns the number of distinct customers who have done successful transactions
223
    """
224
    pass
225
 
226
  def getValidOrdersAmountRange(self, ):
227
    """
228
    Returns the minimum and maximum amounts of a valid order. (OrderStatus >= OrderStatus.SUBMITTED_FOR_PROCESSING)
229
    List contains two values, first minimum amount and second maximum amount.
230
    """
231
    pass
232
 
233
  def getValidOrders(self, limit):
234
    """
235
    Returns list of Orders in descending order by Order creation date. List is restricted to limit Orders.
236
    If limit is passed as 0, then all valid Orders are returned.
3431 rajveer 237
 
3064 chandransh 238
    Parameters:
239
     - limit
240
    """
241
    pass
242
 
1220 chandransh 243
  def batchOrders(self, warehouseId):
244
    """
245
    Create a batch of all the pending orders for the given warehouse.
246
    The returned list is orderd by created_timestamp.
247
    If there are no pending orders, an empty list is returned.
3431 rajveer 248
 
1220 chandransh 249
    Parameters:
250
     - warehouseId
251
    """
252
    pass
253
 
1208 chandransh 254
  def markOrderAsOutOfStock(self, orderId):
255
    """
256
    Mark the given order as out of stock. Throws an exception if the order with the given Id couldn't be found.
3431 rajveer 257
 
1208 chandransh 258
    Parameters:
259
     - orderId
260
    """
261
    pass
262
 
3064 chandransh 263
  def verifyOrder(self, orderId):
759 chandransh 264
    """
3064 chandransh 265
    Marks the given order as SUBMITTED_FOR_PROCESSING and updates the verified
266
    timestamp. It is intended to be used for COD orders but can be harmlessly
267
    used for all other orders as well.
268
    Throws an exception if no such order exists.
3431 rajveer 269
 
759 chandransh 270
    Parameters:
3064 chandransh 271
     - orderId
272
    """
273
    pass
274
 
275
  def acceptOrder(self, orderId):
276
    """
277
    Marks the given order as ACCEPTED and updates the accepted timestamp. If the
278
    given order is not a COD order, it also captures the payment if the same has
279
    not been captured.
280
    Throws an exception if no such order exists.
3431 rajveer 281
 
3064 chandransh 282
    Parameters:
283
     - orderId
284
    """
285
    pass
286
 
287
  def billOrder(self, orderId):
288
    """
289
    Parameters:
290
     - orderId
291
    """
292
    pass
293
 
294
  def addBillingDetails(self, orderId, invoice_number, billed_by):
295
    """
296
    Add billing details such as the bill number and the biller to the Order.
297
    Should be used when the bill is issued by a 3rd party and we've to feed
298
    the information into our system.
3431 rajveer 299
 
3064 chandransh 300
    Parameters:
301
     - orderId
302
     - invoice_number
303
     - billed_by
304
    """
305
    pass
306
 
307
  def addJacketNumber(self, orderId, jacketNumber, imeiNumber, itemNumber, billedBy, billingType):
308
    """
309
    Adds jacket number, item number and IMEI no. to the order. Doesn't update
310
    the IMEI no. if a -1 is supplied.
311
    Also, it generates an invoice number for the order, marks the order as
312
    BILLED and sets the billing timestamp.
313
    It should be used when we are billing the orders ourselves.
3431 rajveer 314
 
3064 chandransh 315
    Returns false if it doesn't find the order with the given ID.
3431 rajveer 316
 
3064 chandransh 317
    Parameters:
318
     - orderId
319
     - jacketNumber
320
     - imeiNumber
321
     - itemNumber
322
     - billedBy
323
     - billingType
324
    """
325
    pass
326
 
327
  def markOrdersAsManifested(self, warehouseId, providerId, cod):
328
    """
329
    Depending on the third parameter, marks either all prepaid or all cod orders BILLED by the
330
    given warehouse and were picked up by the given provider as SHIPPED_FROM_WH.
3431 rajveer 331
 
3064 chandransh 332
    Parameters:
759 chandransh 333
     - warehouseId
334
     - providerId
3064 chandransh 335
     - cod
759 chandransh 336
    """
337
    pass
338
 
1113 chandransh 339
  def markOrdersAsPickedUp(self, providerId, pickupDetails):
340
    """
341
    Marks all SHIPPED_FROM_WH orders of the previous day for a provider as SHIPPED_TO_LOGISTICS.
342
    Returns a list of orders that were shipped from warehouse but did not appear in the pick-up report.
343
    Raises an exception if we encounter report for an AWB number that we did not ship.
3431 rajveer 344
 
1113 chandransh 345
    Parameters:
346
     - providerId
347
     - pickupDetails
348
    """
349
    pass
350
 
1132 chandransh 351
  def markOrdersAsDelivered(self, providerId, deliveredOrders):
352
    """
353
    Marks all orders with AWBs in the given map as delivered. Also sets the delivery timestamp and
354
    the name of the receiver.
355
    Raises an exception if we encounter report for an AWB number that we did not ship.
3431 rajveer 356
 
1132 chandransh 357
    Parameters:
358
     - providerId
359
     - deliveredOrders
360
    """
361
    pass
362
 
1135 chandransh 363
  def markOrdersAsFailed(self, providerId, returnedOrders):
364
    """
365
    Mark all orders with AWBs in the given map as failed. Also sets the delivery timestamp.
366
    Raises an exception if we encounter report for an AWB number that we did not ship.
3431 rajveer 367
 
1135 chandransh 368
    Parameters:
369
     - providerId
370
     - returnedOrders
371
    """
372
    pass
373
 
1246 chandransh 374
  def updateNonDeliveryReason(self, providerId, undeliveredOrders):
375
    """
376
    Update the status description of orders whose AWB numbers are keys of the Map.
3431 rajveer 377
 
1246 chandransh 378
    Parameters:
379
     - providerId
380
     - undeliveredOrders
381
    """
382
    pass
383
 
1408 ankur.sing 384
  def getUndeliveredOrders(self, providerId, warehouseId):
385
    """
386
    Returns the list of orders whose delivery time has passed but have not been
387
    delivered yet for the given provider and warehouse. To get a complete list of
388
    undelivered orders, pass them as -1.
389
    Returns an empty list if no such orders exist.
3431 rajveer 390
 
1408 ankur.sing 391
    Parameters:
392
     - providerId
393
     - warehouseId
394
    """
395
    pass
396
 
2536 chandransh 397
  def toggleDOAFlag(self, orderId):
398
    """
399
    Toggle the DOA flag of an order. This should be used to flag an order for follow-up and unflag it when the follow-up is complete.
400
    Returns the final flag status.
401
    Throws an exception if the order with the given id couldn't be found or if the order status is not DELVIERY_SUCCESS.
3431 rajveer 402
 
2536 chandransh 403
    Parameters:
404
     - orderId
405
    """
406
    pass
1886 ankur.sing 407
 
2536 chandransh 408
  def requestPickupNumber(self, orderId):
409
    """
410
    Sends out an email to the account manager of the original courier provider used to ship the order.
411
    If the order status was DELIVERY_SUCCESS, it is changed to be DOA_PICKUP_REQUESTED.
412
    If the order status was DOA_PICKUP_REQUESTED, it is left unchanged.
413
    For any other status, it returns false.
414
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 415
 
2536 chandransh 416
    Parameters:
417
     - orderId
418
    """
419
    pass
420
 
421
  def authorizePickup(self, orderId, pickupNumber):
422
    """
423
    If the order status is DOA_PICKUP_REQUESTED, it does the following
424
    	1. Sends out an email to the customer with the dispatch advice that he has to print as an attachment.
425
    	2. Changes order status to be DOA_PICKUP_AUTHORIZED.
426
    	3. Returns true
2591 chandransh 427
    If the order is in any other status, it returns false.
2536 chandransh 428
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 429
 
2536 chandransh 430
    Parameters:
431
     - orderId
432
     - pickupNumber
433
    """
434
    pass
435
 
2764 chandransh 436
  def markDoasAsPickedUp(self, providerId, pickupDetails):
437
    """
438
    Marks all DOA_PICKUP_AUTHORIZED orders of the previous day for a provider as DOA_RETURN_IN_TRANSIT.
439
    Returns a list of orders that were authorized for pickup but did not appear in the pick-up report.
3431 rajveer 440
 
2764 chandransh 441
    Parameters:
442
     - providerId
443
     - pickupDetails
444
    """
445
    pass
446
 
2616 chandransh 447
  def receiveReturn(self, orderId):
2591 chandransh 448
    """
2599 chandransh 449
    If the order status is DOA_RETURN_AUTHORIZED or DOA_RETURN_IN_TRANSIT, marks the order status as DOA_RECEIVED and returns true.
2616 chandransh 450
    If the order status is SALES_RETURN_IN_TRANSIT, marks the order status as SALES_RET_RECEIVED and returns true.
2591 chandransh 451
    If the order is in any other state, it returns false.
452
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 453
 
2591 chandransh 454
    Parameters:
455
     - orderId
456
    """
457
    pass
2536 chandransh 458
 
2591 chandransh 459
  def validateDoa(self, orderId, isValid):
460
    """
2599 chandransh 461
    Used to validate the DOA certificate for an order in the DOA_RECEIVED state. If the certificate is valid,
2616 chandransh 462
    the order state is changed to DOA_CERT_VALID. If the certificate is invalid, the order state is changed to DOA_CERT_INVALID.
2591 chandransh 463
    If the order is in any other state, it returns false.
464
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 465
 
2591 chandransh 466
    Parameters:
467
     - orderId
468
     - isValid
469
    """
470
    pass
471
 
2616 chandransh 472
  def reshipOrder(self, orderId):
473
    """
474
    If the order is in SALES_RET_RECEIVED or DOA_CERT_INVALID state, it does the following:
475
    	1. Creates a new order for processing in the BILLED state. All billing information is saved.
476
    	2. Marks the current order as one of the final states SALES_RET_RESHIPPED and DOA_INVALID_RESHIPPED depending on what state the order started in.
477
 
478
    If the order is in DOA_CERT_VALID state, it does the following:
479
    	1. Creates a new order for processing in the SUBMITTED_FOR_PROCESSING state.
480
    	2. Creates a return order for the warehouse executive to return the DOA material.
481
    	3. Marks the current order as the final DOA_RESHIPPED state.
3431 rajveer 482
 
2616 chandransh 483
    Returns the id of the newly created order.
3431 rajveer 484
 
2616 chandransh 485
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 486
 
2616 chandransh 487
    Parameters:
488
     - orderId
489
    """
490
    pass
2591 chandransh 491
 
3226 chandransh 492
  def refundOrder(self, orderId, refundedBy, reason):
2616 chandransh 493
    """
494
    If the order is in SALES_RET_RECEIVED, DOA_CERT_VALID or DOA_CERT_INVALID state, it does the following:
495
    	1. Creates a refund request for batch processing.
496
    	2. Creates a return order for the warehouse executive to return the shipped material.
497
    	3. Marks the current order as SALES_RET_REFUNDED, DOA_VALID_REFUNDED or DOA_INVALID_REFUNDED final states.
3431 rajveer 498
 
2616 chandransh 499
    If the order is in SUBMITTED_FOR_PROCESSING or INVENTORY_LOW state, it does the following:
500
    	1. Creates a refund request for batch processing.
3226 chandransh 501
    	2. Cancels the reservation of the item in the warehouse.
502
    	3. Marks the current order as the REFUNDED final state.
3431 rajveer 503
 
3226 chandransh 504
    For all COD orders, if the order is in INIT, SUBMITTED_FOR_PROCESSING or INVENTORY_LOW state, it does the following:
505
    	1. Cancels the reservation of the item in the warehouse.
506
    	2. Marks the current order as CANCELED.
507
 
508
    In all cases, it updates the reason for cancellation or refund and the person who performed the action.
509
 
2616 chandransh 510
    Returns True if it is successful, False otherwise.
3431 rajveer 511
 
2616 chandransh 512
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 513
 
2616 chandransh 514
    Parameters:
515
     - orderId
3226 chandransh 516
     - refundedBy
517
     - reason
2616 chandransh 518
    """
519
    pass
520
 
2690 chandransh 521
  def getReturnOrders(self, warehouseId, fromDate, toDate):
522
    """
523
    Get all return orders created between the from and to dates for the given warehouse.
524
    Ignores the warehouse if it is passed as -1.
3431 rajveer 525
 
2690 chandransh 526
    Parameters:
527
     - warehouseId
528
     - fromDate
529
     - toDate
530
    """
531
    pass
2616 chandransh 532
 
2700 chandransh 533
  def getReturnOrder(self, id):
534
    """
535
    Returns the ReturnOrder corresponding to the given id.
536
    Throws an exception if the return order with the given id couldn't be found.
3431 rajveer 537
 
2700 chandransh 538
    Parameters:
539
     - id
540
    """
541
    pass
542
 
2690 chandransh 543
  def processReturn(self, returnOrderId):
544
    """
545
    Marks the return order with the given id as processed. Raises an exception if no such return order exists.
3431 rajveer 546
 
2690 chandransh 547
    Parameters:
548
     - returnOrderId
549
    """
550
    pass
551
 
2819 chandransh 552
  def createPurchaseOrder(self, warehouseId):
553
    """
554
    Creates a purchase order corresponding to all the pending orders of the given warehouse.
2842 chandransh 555
    Returns the PO no. of the newly created purchase order. Returns -1 no new purchase order had to be created.
3431 rajveer 556
 
2819 chandransh 557
    Parameters:
558
     - warehouseId
559
    """
560
    pass
2690 chandransh 561
 
3451 chandransh 562
  def updateWeight(self, orderId, weight):
563
    """
564
    Set the weight of the given order to the provided value. Will attempt to update the weight of the item in the catalog as well.
2819 chandransh 565
 
3451 chandransh 566
    Parameters:
567
     - orderId
568
     - weight
569
    """
570
    pass
571
 
572
 
3376 rajveer 573
class Client(shop2020.thriftpy.generic.GenericService.Client, Iface):
94 ashish 574
  def __init__(self, iprot, oprot=None):
3376 rajveer 575
    shop2020.thriftpy.generic.GenericService.Client.__init__(self, iprot, oprot)
94 ashish 576
 
577
  def createTransaction(self, transaction):
578
    """
579
    Parameters:
580
     - transaction
581
    """
582
    self.send_createTransaction(transaction)
132 ashish 583
    return self.recv_createTransaction()
94 ashish 584
 
585
  def send_createTransaction(self, transaction):
586
    self._oprot.writeMessageBegin('createTransaction', TMessageType.CALL, self._seqid)
587
    args = createTransaction_args()
588
    args.transaction = transaction
589
    args.write(self._oprot)
590
    self._oprot.writeMessageEnd()
591
    self._oprot.trans.flush()
592
 
593
  def recv_createTransaction(self, ):
594
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
595
    if mtype == TMessageType.EXCEPTION:
596
      x = TApplicationException()
597
      x.read(self._iprot)
598
      self._iprot.readMessageEnd()
599
      raise x
600
    result = createTransaction_result()
601
    result.read(self._iprot)
602
    self._iprot.readMessageEnd()
3431 rajveer 603
    if result.success is not None:
132 ashish 604
      return result.success
3431 rajveer 605
    if result.ex is not None:
94 ashish 606
      raise result.ex
132 ashish 607
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createTransaction failed: unknown result");
94 ashish 608
 
609
  def getTransaction(self, id):
610
    """
611
    Parameters:
612
     - id
613
    """
614
    self.send_getTransaction(id)
615
    return self.recv_getTransaction()
616
 
617
  def send_getTransaction(self, id):
618
    self._oprot.writeMessageBegin('getTransaction', TMessageType.CALL, self._seqid)
619
    args = getTransaction_args()
620
    args.id = id
621
    args.write(self._oprot)
622
    self._oprot.writeMessageEnd()
623
    self._oprot.trans.flush()
624
 
625
  def recv_getTransaction(self, ):
626
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
627
    if mtype == TMessageType.EXCEPTION:
628
      x = TApplicationException()
629
      x.read(self._iprot)
630
      self._iprot.readMessageEnd()
631
      raise x
632
    result = getTransaction_result()
633
    result.read(self._iprot)
634
    self._iprot.readMessageEnd()
3431 rajveer 635
    if result.success is not None:
94 ashish 636
      return result.success
3431 rajveer 637
    if result.ex is not None:
94 ashish 638
      raise result.ex
639
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransaction failed: unknown result");
640
 
641
  def getTransactionsForCustomer(self, customerId, from_date, to_date, status):
642
    """
643
    Parameters:
644
     - customerId
645
     - from_date
646
     - to_date
647
     - status
648
    """
649
    self.send_getTransactionsForCustomer(customerId, from_date, to_date, status)
650
    return self.recv_getTransactionsForCustomer()
651
 
652
  def send_getTransactionsForCustomer(self, customerId, from_date, to_date, status):
653
    self._oprot.writeMessageBegin('getTransactionsForCustomer', TMessageType.CALL, self._seqid)
654
    args = getTransactionsForCustomer_args()
655
    args.customerId = customerId
656
    args.from_date = from_date
657
    args.to_date = to_date
658
    args.status = status
659
    args.write(self._oprot)
660
    self._oprot.writeMessageEnd()
661
    self._oprot.trans.flush()
662
 
663
  def recv_getTransactionsForCustomer(self, ):
664
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
665
    if mtype == TMessageType.EXCEPTION:
666
      x = TApplicationException()
667
      x.read(self._iprot)
668
      self._iprot.readMessageEnd()
669
      raise x
670
    result = getTransactionsForCustomer_result()
671
    result.read(self._iprot)
672
    self._iprot.readMessageEnd()
3431 rajveer 673
    if result.success is not None:
94 ashish 674
      return result.success
3431 rajveer 675
    if result.ex is not None:
94 ashish 676
      raise result.ex
677
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransactionsForCustomer failed: unknown result");
678
 
132 ashish 679
  def getTransactionsForShoppingCartId(self, shoppingCartId):
680
    """
681
    Parameters:
682
     - shoppingCartId
683
    """
684
    self.send_getTransactionsForShoppingCartId(shoppingCartId)
685
    return self.recv_getTransactionsForShoppingCartId()
686
 
687
  def send_getTransactionsForShoppingCartId(self, shoppingCartId):
688
    self._oprot.writeMessageBegin('getTransactionsForShoppingCartId', TMessageType.CALL, self._seqid)
689
    args = getTransactionsForShoppingCartId_args()
690
    args.shoppingCartId = shoppingCartId
691
    args.write(self._oprot)
692
    self._oprot.writeMessageEnd()
693
    self._oprot.trans.flush()
694
 
695
  def recv_getTransactionsForShoppingCartId(self, ):
696
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
697
    if mtype == TMessageType.EXCEPTION:
698
      x = TApplicationException()
699
      x.read(self._iprot)
700
      self._iprot.readMessageEnd()
701
      raise x
702
    result = getTransactionsForShoppingCartId_result()
703
    result.read(self._iprot)
704
    self._iprot.readMessageEnd()
3431 rajveer 705
    if result.success is not None:
132 ashish 706
      return result.success
3431 rajveer 707
    if result.ex is not None:
132 ashish 708
      raise result.ex
709
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransactionsForShoppingCartId failed: unknown result");
710
 
94 ashish 711
  def getTransactionStatus(self, transactionId):
712
    """
713
    Parameters:
714
     - transactionId
715
    """
716
    self.send_getTransactionStatus(transactionId)
717
    return self.recv_getTransactionStatus()
718
 
719
  def send_getTransactionStatus(self, transactionId):
720
    self._oprot.writeMessageBegin('getTransactionStatus', TMessageType.CALL, self._seqid)
721
    args = getTransactionStatus_args()
722
    args.transactionId = transactionId
723
    args.write(self._oprot)
724
    self._oprot.writeMessageEnd()
725
    self._oprot.trans.flush()
726
 
727
  def recv_getTransactionStatus(self, ):
728
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
729
    if mtype == TMessageType.EXCEPTION:
730
      x = TApplicationException()
731
      x.read(self._iprot)
732
      self._iprot.readMessageEnd()
733
      raise x
734
    result = getTransactionStatus_result()
735
    result.read(self._iprot)
736
    self._iprot.readMessageEnd()
3431 rajveer 737
    if result.success is not None:
94 ashish 738
      return result.success
3431 rajveer 739
    if result.ex is not None:
94 ashish 740
      raise result.ex
741
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransactionStatus failed: unknown result");
742
 
743
  def changeTransactionStatus(self, transactionId, status, description):
744
    """
745
    Parameters:
746
     - transactionId
747
     - status
748
     - description
749
    """
750
    self.send_changeTransactionStatus(transactionId, status, description)
751
    return self.recv_changeTransactionStatus()
752
 
753
  def send_changeTransactionStatus(self, transactionId, status, description):
754
    self._oprot.writeMessageBegin('changeTransactionStatus', TMessageType.CALL, self._seqid)
755
    args = changeTransactionStatus_args()
756
    args.transactionId = transactionId
757
    args.status = status
758
    args.description = description
759
    args.write(self._oprot)
760
    self._oprot.writeMessageEnd()
761
    self._oprot.trans.flush()
762
 
763
  def recv_changeTransactionStatus(self, ):
764
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
765
    if mtype == TMessageType.EXCEPTION:
766
      x = TApplicationException()
767
      x.read(self._iprot)
768
      self._iprot.readMessageEnd()
769
      raise x
770
    result = changeTransactionStatus_result()
771
    result.read(self._iprot)
772
    self._iprot.readMessageEnd()
3431 rajveer 773
    if result.success is not None:
94 ashish 774
      return result.success
3431 rajveer 775
    if result.ex is not None:
94 ashish 776
      raise result.ex
777
    raise TApplicationException(TApplicationException.MISSING_RESULT, "changeTransactionStatus failed: unknown result");
778
 
1398 varun.gupt 779
  def enqueueTransactionInfoEmail(self, transactionId):
1382 varun.gupt 780
    """
781
    Parameters:
782
     - transactionId
783
    """
1398 varun.gupt 784
    self.send_enqueueTransactionInfoEmail(transactionId)
785
    return self.recv_enqueueTransactionInfoEmail()
1382 varun.gupt 786
 
1398 varun.gupt 787
  def send_enqueueTransactionInfoEmail(self, transactionId):
788
    self._oprot.writeMessageBegin('enqueueTransactionInfoEmail', TMessageType.CALL, self._seqid)
789
    args = enqueueTransactionInfoEmail_args()
1382 varun.gupt 790
    args.transactionId = transactionId
791
    args.write(self._oprot)
792
    self._oprot.writeMessageEnd()
793
    self._oprot.trans.flush()
794
 
1398 varun.gupt 795
  def recv_enqueueTransactionInfoEmail(self, ):
1382 varun.gupt 796
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
797
    if mtype == TMessageType.EXCEPTION:
798
      x = TApplicationException()
799
      x.read(self._iprot)
800
      self._iprot.readMessageEnd()
801
      raise x
1398 varun.gupt 802
    result = enqueueTransactionInfoEmail_result()
1382 varun.gupt 803
    result.read(self._iprot)
804
    self._iprot.readMessageEnd()
3431 rajveer 805
    if result.success is not None:
1382 varun.gupt 806
      return result.success
3431 rajveer 807
    if result.ex is not None:
1382 varun.gupt 808
      raise result.ex
1398 varun.gupt 809
    raise TApplicationException(TApplicationException.MISSING_RESULT, "enqueueTransactionInfoEmail failed: unknown result");
1382 varun.gupt 810
 
483 rajveer 811
  def getAllOrders(self, status, from_date, to_date, warehouse_id):
94 ashish 812
    """
813
    Parameters:
483 rajveer 814
     - status
815
     - from_date
816
     - to_date
817
     - warehouse_id
94 ashish 818
    """
483 rajveer 819
    self.send_getAllOrders(status, from_date, to_date, warehouse_id)
820
    return self.recv_getAllOrders()
94 ashish 821
 
483 rajveer 822
  def send_getAllOrders(self, status, from_date, to_date, warehouse_id):
823
    self._oprot.writeMessageBegin('getAllOrders', TMessageType.CALL, self._seqid)
824
    args = getAllOrders_args()
825
    args.status = status
826
    args.from_date = from_date
827
    args.to_date = to_date
828
    args.warehouse_id = warehouse_id
94 ashish 829
    args.write(self._oprot)
830
    self._oprot.writeMessageEnd()
831
    self._oprot.trans.flush()
832
 
483 rajveer 833
  def recv_getAllOrders(self, ):
94 ashish 834
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
835
    if mtype == TMessageType.EXCEPTION:
836
      x = TApplicationException()
837
      x.read(self._iprot)
838
      self._iprot.readMessageEnd()
839
      raise x
483 rajveer 840
    result = getAllOrders_result()
94 ashish 841
    result.read(self._iprot)
842
    self._iprot.readMessageEnd()
3431 rajveer 843
    if result.success is not None:
94 ashish 844
      return result.success
3431 rajveer 845
    if result.ex is not None:
94 ashish 846
      raise result.ex
483 rajveer 847
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllOrders failed: unknown result");
94 ashish 848
 
999 varun.gupt 849
  def getOrdersByBillingDate(self, status, start_billing_date, end_billing_date, warehouse_id):
850
    """
1132 chandransh 851
    Returns orders within a range of their billing dates
3431 rajveer 852
 
999 varun.gupt 853
    Parameters:
854
     - status
855
     - start_billing_date
856
     - end_billing_date
857
     - warehouse_id
858
    """
859
    self.send_getOrdersByBillingDate(status, start_billing_date, end_billing_date, warehouse_id)
860
    return self.recv_getOrdersByBillingDate()
861
 
862
  def send_getOrdersByBillingDate(self, status, start_billing_date, end_billing_date, warehouse_id):
863
    self._oprot.writeMessageBegin('getOrdersByBillingDate', TMessageType.CALL, self._seqid)
864
    args = getOrdersByBillingDate_args()
865
    args.status = status
866
    args.start_billing_date = start_billing_date
867
    args.end_billing_date = end_billing_date
868
    args.warehouse_id = warehouse_id
869
    args.write(self._oprot)
870
    self._oprot.writeMessageEnd()
871
    self._oprot.trans.flush()
872
 
873
  def recv_getOrdersByBillingDate(self, ):
874
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
875
    if mtype == TMessageType.EXCEPTION:
876
      x = TApplicationException()
877
      x.read(self._iprot)
878
      self._iprot.readMessageEnd()
879
      raise x
880
    result = getOrdersByBillingDate_result()
881
    result.read(self._iprot)
882
    self._iprot.readMessageEnd()
3431 rajveer 883
    if result.success is not None:
999 varun.gupt 884
      return result.success
3431 rajveer 885
    if result.ex is not None:
999 varun.gupt 886
      raise result.ex
887
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrdersByBillingDate failed: unknown result");
888
 
3451 chandransh 889
  def getOrdersByShippingDate(self, fromShippingDate, toShippingDate, providerId, warehouseId, cod):
3427 chandransh 890
    """
891
    Returns orders for a particular provider and warehouse which were shipped between the given dates.
3451 chandransh 892
    Returned orders comprise of COD orders if cod parameter is true. It comprises of prepaid orders otherwise.
893
    Pass providerId and warehouseId as -1 to ignore both these parameters.
3431 rajveer 894
 
3427 chandransh 895
    Parameters:
896
     - fromShippingDate
897
     - toShippingDate
898
     - providerId
899
     - warehouseId
3451 chandransh 900
     - cod
3427 chandransh 901
    """
3451 chandransh 902
    self.send_getOrdersByShippingDate(fromShippingDate, toShippingDate, providerId, warehouseId, cod)
3427 chandransh 903
    return self.recv_getOrdersByShippingDate()
904
 
3451 chandransh 905
  def send_getOrdersByShippingDate(self, fromShippingDate, toShippingDate, providerId, warehouseId, cod):
3427 chandransh 906
    self._oprot.writeMessageBegin('getOrdersByShippingDate', TMessageType.CALL, self._seqid)
907
    args = getOrdersByShippingDate_args()
908
    args.fromShippingDate = fromShippingDate
909
    args.toShippingDate = toShippingDate
910
    args.providerId = providerId
911
    args.warehouseId = warehouseId
3451 chandransh 912
    args.cod = cod
3427 chandransh 913
    args.write(self._oprot)
914
    self._oprot.writeMessageEnd()
915
    self._oprot.trans.flush()
916
 
917
  def recv_getOrdersByShippingDate(self, ):
918
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
919
    if mtype == TMessageType.EXCEPTION:
920
      x = TApplicationException()
921
      x.read(self._iprot)
922
      self._iprot.readMessageEnd()
923
      raise x
924
    result = getOrdersByShippingDate_result()
925
    result.read(self._iprot)
926
    self._iprot.readMessageEnd()
3431 rajveer 927
    if result.success is not None:
3427 chandransh 928
      return result.success
3431 rajveer 929
    if result.ex is not None:
3427 chandransh 930
      raise result.ex
931
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrdersByShippingDate failed: unknown result");
932
 
1382 varun.gupt 933
  def getReturnableOrdersForCustomer(self, customer_id, limit):
934
    """
935
    Returns order ids for orders which can be returned
3431 rajveer 936
 
1382 varun.gupt 937
    Parameters:
938
     - customer_id
939
     - limit
940
    """
941
    self.send_getReturnableOrdersForCustomer(customer_id, limit)
942
    return self.recv_getReturnableOrdersForCustomer()
943
 
944
  def send_getReturnableOrdersForCustomer(self, customer_id, limit):
945
    self._oprot.writeMessageBegin('getReturnableOrdersForCustomer', TMessageType.CALL, self._seqid)
946
    args = getReturnableOrdersForCustomer_args()
947
    args.customer_id = customer_id
948
    args.limit = limit
949
    args.write(self._oprot)
950
    self._oprot.writeMessageEnd()
951
    self._oprot.trans.flush()
952
 
953
  def recv_getReturnableOrdersForCustomer(self, ):
954
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
955
    if mtype == TMessageType.EXCEPTION:
956
      x = TApplicationException()
957
      x.read(self._iprot)
958
      self._iprot.readMessageEnd()
959
      raise x
960
    result = getReturnableOrdersForCustomer_result()
961
    result.read(self._iprot)
962
    self._iprot.readMessageEnd()
3431 rajveer 963
    if result.success is not None:
1382 varun.gupt 964
      return result.success
3431 rajveer 965
    if result.ex is not None:
1382 varun.gupt 966
      raise result.ex
967
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getReturnableOrdersForCustomer failed: unknown result");
968
 
969
  def getCancellableOrdersForCustomer(self, customer_id, limit):
970
    """
971
    Returns order ids for orders which can be cancelled
3431 rajveer 972
 
1382 varun.gupt 973
    Parameters:
974
     - customer_id
975
     - limit
976
    """
977
    self.send_getCancellableOrdersForCustomer(customer_id, limit)
978
    return self.recv_getCancellableOrdersForCustomer()
979
 
980
  def send_getCancellableOrdersForCustomer(self, customer_id, limit):
981
    self._oprot.writeMessageBegin('getCancellableOrdersForCustomer', TMessageType.CALL, self._seqid)
982
    args = getCancellableOrdersForCustomer_args()
983
    args.customer_id = customer_id
984
    args.limit = limit
985
    args.write(self._oprot)
986
    self._oprot.writeMessageEnd()
987
    self._oprot.trans.flush()
988
 
989
  def recv_getCancellableOrdersForCustomer(self, ):
990
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
991
    if mtype == TMessageType.EXCEPTION:
992
      x = TApplicationException()
993
      x.read(self._iprot)
994
      self._iprot.readMessageEnd()
995
      raise x
996
    result = getCancellableOrdersForCustomer_result()
997
    result.read(self._iprot)
998
    self._iprot.readMessageEnd()
3431 rajveer 999
    if result.success is not None:
1382 varun.gupt 1000
      return result.success
3431 rajveer 1001
    if result.ex is not None:
1382 varun.gupt 1002
      raise result.ex
1003
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCancellableOrdersForCustomer failed: unknown result");
1004
 
483 rajveer 1005
  def changeOrderStatus(self, orderId, status, description):
94 ashish 1006
    """
1007
    Parameters:
483 rajveer 1008
     - orderId
1009
     - status
1010
     - description
94 ashish 1011
    """
483 rajveer 1012
    self.send_changeOrderStatus(orderId, status, description)
1013
    return self.recv_changeOrderStatus()
94 ashish 1014
 
483 rajveer 1015
  def send_changeOrderStatus(self, orderId, status, description):
1016
    self._oprot.writeMessageBegin('changeOrderStatus', TMessageType.CALL, self._seqid)
1017
    args = changeOrderStatus_args()
1018
    args.orderId = orderId
1019
    args.status = status
1020
    args.description = description
94 ashish 1021
    args.write(self._oprot)
1022
    self._oprot.writeMessageEnd()
1023
    self._oprot.trans.flush()
1024
 
483 rajveer 1025
  def recv_changeOrderStatus(self, ):
94 ashish 1026
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1027
    if mtype == TMessageType.EXCEPTION:
1028
      x = TApplicationException()
1029
      x.read(self._iprot)
1030
      self._iprot.readMessageEnd()
1031
      raise x
483 rajveer 1032
    result = changeOrderStatus_result()
94 ashish 1033
    result.read(self._iprot)
1034
    self._iprot.readMessageEnd()
3431 rajveer 1035
    if result.success is not None:
94 ashish 1036
      return result.success
3431 rajveer 1037
    if result.ex is not None:
94 ashish 1038
      raise result.ex
483 rajveer 1039
    raise TApplicationException(TApplicationException.MISSING_RESULT, "changeOrderStatus failed: unknown result");
94 ashish 1040
 
1528 ankur.sing 1041
  def getOrdersForTransaction(self, transactionId, customerId):
94 ashish 1042
    """
1528 ankur.sing 1043
    Returns list of orders for given transaction Id. Also filters based on customer Id so that
1044
    only user who owns the transaction can view its order details.
3431 rajveer 1045
 
94 ashish 1046
    Parameters:
1047
     - transactionId
1528 ankur.sing 1048
     - customerId
94 ashish 1049
    """
1528 ankur.sing 1050
    self.send_getOrdersForTransaction(transactionId, customerId)
483 rajveer 1051
    return self.recv_getOrdersForTransaction()
94 ashish 1052
 
1528 ankur.sing 1053
  def send_getOrdersForTransaction(self, transactionId, customerId):
483 rajveer 1054
    self._oprot.writeMessageBegin('getOrdersForTransaction', TMessageType.CALL, self._seqid)
1055
    args = getOrdersForTransaction_args()
94 ashish 1056
    args.transactionId = transactionId
1528 ankur.sing 1057
    args.customerId = customerId
94 ashish 1058
    args.write(self._oprot)
1059
    self._oprot.writeMessageEnd()
1060
    self._oprot.trans.flush()
1061
 
483 rajveer 1062
  def recv_getOrdersForTransaction(self, ):
94 ashish 1063
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1064
    if mtype == TMessageType.EXCEPTION:
1065
      x = TApplicationException()
1066
      x.read(self._iprot)
1067
      self._iprot.readMessageEnd()
1068
      raise x
483 rajveer 1069
    result = getOrdersForTransaction_result()
94 ashish 1070
    result.read(self._iprot)
1071
    self._iprot.readMessageEnd()
3431 rajveer 1072
    if result.success is not None:
94 ashish 1073
      return result.success
3431 rajveer 1074
    if result.ex is not None:
94 ashish 1075
      raise result.ex
483 rajveer 1076
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrdersForTransaction failed: unknown result");
94 ashish 1077
 
3014 chandransh 1078
  def getOrdersForCustomer(self, customerId, from_date, to_date, statuses):
94 ashish 1079
    """
3014 chandransh 1080
    Returns list of orders for the given customer created between the given dates and having the given statuses.
1081
    Pass and empty list to ignore filtering on statuses.
3431 rajveer 1082
 
94 ashish 1083
    Parameters:
483 rajveer 1084
     - customerId
1085
     - from_date
1086
     - to_date
3014 chandransh 1087
     - statuses
94 ashish 1088
    """
3014 chandransh 1089
    self.send_getOrdersForCustomer(customerId, from_date, to_date, statuses)
483 rajveer 1090
    return self.recv_getOrdersForCustomer()
94 ashish 1091
 
3014 chandransh 1092
  def send_getOrdersForCustomer(self, customerId, from_date, to_date, statuses):
483 rajveer 1093
    self._oprot.writeMessageBegin('getOrdersForCustomer', TMessageType.CALL, self._seqid)
1094
    args = getOrdersForCustomer_args()
1095
    args.customerId = customerId
1096
    args.from_date = from_date
1097
    args.to_date = to_date
3014 chandransh 1098
    args.statuses = statuses
94 ashish 1099
    args.write(self._oprot)
1100
    self._oprot.writeMessageEnd()
1101
    self._oprot.trans.flush()
1102
 
483 rajveer 1103
  def recv_getOrdersForCustomer(self, ):
94 ashish 1104
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1105
    if mtype == TMessageType.EXCEPTION:
1106
      x = TApplicationException()
1107
      x.read(self._iprot)
1108
      self._iprot.readMessageEnd()
1109
      raise x
483 rajveer 1110
    result = getOrdersForCustomer_result()
94 ashish 1111
    result.read(self._iprot)
1112
    self._iprot.readMessageEnd()
3431 rajveer 1113
    if result.success is not None:
94 ashish 1114
      return result.success
3431 rajveer 1115
    if result.ex is not None:
94 ashish 1116
      raise result.ex
483 rajveer 1117
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrdersForCustomer failed: unknown result");
94 ashish 1118
 
483 rajveer 1119
  def createOrder(self, order):
94 ashish 1120
    """
1121
    Parameters:
483 rajveer 1122
     - order
94 ashish 1123
    """
483 rajveer 1124
    self.send_createOrder(order)
1125
    return self.recv_createOrder()
94 ashish 1126
 
483 rajveer 1127
  def send_createOrder(self, order):
1128
    self._oprot.writeMessageBegin('createOrder', TMessageType.CALL, self._seqid)
1129
    args = createOrder_args()
1130
    args.order = order
94 ashish 1131
    args.write(self._oprot)
1132
    self._oprot.writeMessageEnd()
1133
    self._oprot.trans.flush()
1134
 
483 rajveer 1135
  def recv_createOrder(self, ):
94 ashish 1136
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1137
    if mtype == TMessageType.EXCEPTION:
1138
      x = TApplicationException()
1139
      x.read(self._iprot)
1140
      self._iprot.readMessageEnd()
1141
      raise x
483 rajveer 1142
    result = createOrder_result()
94 ashish 1143
    result.read(self._iprot)
1144
    self._iprot.readMessageEnd()
3431 rajveer 1145
    if result.success is not None:
94 ashish 1146
      return result.success
3431 rajveer 1147
    if result.ex is not None:
94 ashish 1148
      raise result.ex
483 rajveer 1149
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createOrder failed: unknown result");
94 ashish 1150
 
483 rajveer 1151
  def getOrder(self, id):
94 ashish 1152
    """
1153
    Parameters:
483 rajveer 1154
     - id
94 ashish 1155
    """
483 rajveer 1156
    self.send_getOrder(id)
1157
    return self.recv_getOrder()
94 ashish 1158
 
483 rajveer 1159
  def send_getOrder(self, id):
1160
    self._oprot.writeMessageBegin('getOrder', TMessageType.CALL, self._seqid)
1161
    args = getOrder_args()
1162
    args.id = id
94 ashish 1163
    args.write(self._oprot)
1164
    self._oprot.writeMessageEnd()
1165
    self._oprot.trans.flush()
1166
 
483 rajveer 1167
  def recv_getOrder(self, ):
94 ashish 1168
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1169
    if mtype == TMessageType.EXCEPTION:
1170
      x = TApplicationException()
1171
      x.read(self._iprot)
1172
      self._iprot.readMessageEnd()
1173
      raise x
483 rajveer 1174
    result = getOrder_result()
94 ashish 1175
    result.read(self._iprot)
1176
    self._iprot.readMessageEnd()
3431 rajveer 1177
    if result.success is not None:
94 ashish 1178
      return result.success
3431 rajveer 1179
    if result.ex is not None:
94 ashish 1180
      raise result.ex
483 rajveer 1181
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrder failed: unknown result");
94 ashish 1182
 
483 rajveer 1183
  def getLineItemsForOrder(self, orderId):
94 ashish 1184
    """
1185
    Parameters:
483 rajveer 1186
     - orderId
94 ashish 1187
    """
483 rajveer 1188
    self.send_getLineItemsForOrder(orderId)
1189
    return self.recv_getLineItemsForOrder()
94 ashish 1190
 
483 rajveer 1191
  def send_getLineItemsForOrder(self, orderId):
1192
    self._oprot.writeMessageBegin('getLineItemsForOrder', TMessageType.CALL, self._seqid)
1193
    args = getLineItemsForOrder_args()
1194
    args.orderId = orderId
94 ashish 1195
    args.write(self._oprot)
1196
    self._oprot.writeMessageEnd()
1197
    self._oprot.trans.flush()
1198
 
483 rajveer 1199
  def recv_getLineItemsForOrder(self, ):
94 ashish 1200
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1201
    if mtype == TMessageType.EXCEPTION:
1202
      x = TApplicationException()
1203
      x.read(self._iprot)
1204
      self._iprot.readMessageEnd()
1205
      raise x
483 rajveer 1206
    result = getLineItemsForOrder_result()
94 ashish 1207
    result.read(self._iprot)
1208
    self._iprot.readMessageEnd()
3431 rajveer 1209
    if result.success is not None:
94 ashish 1210
      return result.success
3431 rajveer 1211
    if result.ex is not None:
94 ashish 1212
      raise result.ex
483 rajveer 1213
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getLineItemsForOrder failed: unknown result");
94 ashish 1214
 
1528 ankur.sing 1215
  def getOrderForCustomer(self, orderId, customerId):
1216
    """
1217
    Returns an order for the order Id. Also checks if the order belongs to the customer whose Id is passed.
1218
    Throws exception if either order Id is invalid or order does not below to the customer whose Id is passed.
3431 rajveer 1219
 
1528 ankur.sing 1220
    Parameters:
1221
     - orderId
1222
     - customerId
1223
    """
1224
    self.send_getOrderForCustomer(orderId, customerId)
1225
    return self.recv_getOrderForCustomer()
1226
 
1227
  def send_getOrderForCustomer(self, orderId, customerId):
1228
    self._oprot.writeMessageBegin('getOrderForCustomer', TMessageType.CALL, self._seqid)
1229
    args = getOrderForCustomer_args()
1230
    args.orderId = orderId
1231
    args.customerId = customerId
1232
    args.write(self._oprot)
1233
    self._oprot.writeMessageEnd()
1234
    self._oprot.trans.flush()
1235
 
1236
  def recv_getOrderForCustomer(self, ):
1237
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1238
    if mtype == TMessageType.EXCEPTION:
1239
      x = TApplicationException()
1240
      x.read(self._iprot)
1241
      self._iprot.readMessageEnd()
1242
      raise x
1243
    result = getOrderForCustomer_result()
1244
    result.read(self._iprot)
1245
    self._iprot.readMessageEnd()
3431 rajveer 1246
    if result.success is not None:
1528 ankur.sing 1247
      return result.success
3431 rajveer 1248
    if result.ex is not None:
1528 ankur.sing 1249
      raise result.ex
1250
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrderForCustomer failed: unknown result");
1251
 
3064 chandransh 1252
  def getAlerts(self, orderId, valid):
1253
    """
1254
    Parameters:
1255
     - orderId
1256
     - valid
1257
    """
1258
    self.send_getAlerts(orderId, valid)
1259
    return self.recv_getAlerts()
1260
 
1261
  def send_getAlerts(self, orderId, valid):
1262
    self._oprot.writeMessageBegin('getAlerts', TMessageType.CALL, self._seqid)
1263
    args = getAlerts_args()
1264
    args.orderId = orderId
1265
    args.valid = valid
1266
    args.write(self._oprot)
1267
    self._oprot.writeMessageEnd()
1268
    self._oprot.trans.flush()
1269
 
1270
  def recv_getAlerts(self, ):
1271
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1272
    if mtype == TMessageType.EXCEPTION:
1273
      x = TApplicationException()
1274
      x.read(self._iprot)
1275
      self._iprot.readMessageEnd()
1276
      raise x
1277
    result = getAlerts_result()
1278
    result.read(self._iprot)
1279
    self._iprot.readMessageEnd()
3431 rajveer 1280
    if result.success is not None:
3064 chandransh 1281
      return result.success
1282
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAlerts failed: unknown result");
1283
 
1284
  def setAlert(self, orderId, unset, type, comment):
1285
    """
1286
    Parameters:
1287
     - orderId
1288
     - unset
1289
     - type
1290
     - comment
1291
    """
1292
    self.send_setAlert(orderId, unset, type, comment)
1293
    self.recv_setAlert()
1294
 
1295
  def send_setAlert(self, orderId, unset, type, comment):
1296
    self._oprot.writeMessageBegin('setAlert', TMessageType.CALL, self._seqid)
1297
    args = setAlert_args()
1298
    args.orderId = orderId
1299
    args.unset = unset
1300
    args.type = type
1301
    args.comment = comment
1302
    args.write(self._oprot)
1303
    self._oprot.writeMessageEnd()
1304
    self._oprot.trans.flush()
1305
 
1306
  def recv_setAlert(self, ):
1307
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1308
    if mtype == TMessageType.EXCEPTION:
1309
      x = TApplicationException()
1310
      x.read(self._iprot)
1311
      self._iprot.readMessageEnd()
1312
      raise x
1313
    result = setAlert_result()
1314
    result.read(self._iprot)
1315
    self._iprot.readMessageEnd()
1316
    return
1317
 
1318
  def getValidOrderCount(self, ):
1319
    """
1320
    Return the number of valid orders. (OrderStatus >= OrderStatus.SUBMITTED_FOR_PROCESSING)
1321
    """
1322
    self.send_getValidOrderCount()
1323
    return self.recv_getValidOrderCount()
1324
 
1325
  def send_getValidOrderCount(self, ):
1326
    self._oprot.writeMessageBegin('getValidOrderCount', TMessageType.CALL, self._seqid)
1327
    args = getValidOrderCount_args()
1328
    args.write(self._oprot)
1329
    self._oprot.writeMessageEnd()
1330
    self._oprot.trans.flush()
1331
 
1332
  def recv_getValidOrderCount(self, ):
1333
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1334
    if mtype == TMessageType.EXCEPTION:
1335
      x = TApplicationException()
1336
      x.read(self._iprot)
1337
      self._iprot.readMessageEnd()
1338
      raise x
1339
    result = getValidOrderCount_result()
1340
    result.read(self._iprot)
1341
    self._iprot.readMessageEnd()
3431 rajveer 1342
    if result.success is not None:
3064 chandransh 1343
      return result.success
1344
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getValidOrderCount failed: unknown result");
1345
 
1346
  def getNoOfCustomersWithSuccessfulTransaction(self, ):
1347
    """
1348
    Returns the number of distinct customers who have done successful transactions
1349
    """
1350
    self.send_getNoOfCustomersWithSuccessfulTransaction()
1351
    return self.recv_getNoOfCustomersWithSuccessfulTransaction()
1352
 
1353
  def send_getNoOfCustomersWithSuccessfulTransaction(self, ):
1354
    self._oprot.writeMessageBegin('getNoOfCustomersWithSuccessfulTransaction', TMessageType.CALL, self._seqid)
1355
    args = getNoOfCustomersWithSuccessfulTransaction_args()
1356
    args.write(self._oprot)
1357
    self._oprot.writeMessageEnd()
1358
    self._oprot.trans.flush()
1359
 
1360
  def recv_getNoOfCustomersWithSuccessfulTransaction(self, ):
1361
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1362
    if mtype == TMessageType.EXCEPTION:
1363
      x = TApplicationException()
1364
      x.read(self._iprot)
1365
      self._iprot.readMessageEnd()
1366
      raise x
1367
    result = getNoOfCustomersWithSuccessfulTransaction_result()
1368
    result.read(self._iprot)
1369
    self._iprot.readMessageEnd()
3431 rajveer 1370
    if result.success is not None:
3064 chandransh 1371
      return result.success
1372
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getNoOfCustomersWithSuccessfulTransaction failed: unknown result");
1373
 
1374
  def getValidOrdersAmountRange(self, ):
1375
    """
1376
    Returns the minimum and maximum amounts of a valid order. (OrderStatus >= OrderStatus.SUBMITTED_FOR_PROCESSING)
1377
    List contains two values, first minimum amount and second maximum amount.
1378
    """
1379
    self.send_getValidOrdersAmountRange()
1380
    return self.recv_getValidOrdersAmountRange()
1381
 
1382
  def send_getValidOrdersAmountRange(self, ):
1383
    self._oprot.writeMessageBegin('getValidOrdersAmountRange', TMessageType.CALL, self._seqid)
1384
    args = getValidOrdersAmountRange_args()
1385
    args.write(self._oprot)
1386
    self._oprot.writeMessageEnd()
1387
    self._oprot.trans.flush()
1388
 
1389
  def recv_getValidOrdersAmountRange(self, ):
1390
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1391
    if mtype == TMessageType.EXCEPTION:
1392
      x = TApplicationException()
1393
      x.read(self._iprot)
1394
      self._iprot.readMessageEnd()
1395
      raise x
1396
    result = getValidOrdersAmountRange_result()
1397
    result.read(self._iprot)
1398
    self._iprot.readMessageEnd()
3431 rajveer 1399
    if result.success is not None:
3064 chandransh 1400
      return result.success
1401
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getValidOrdersAmountRange failed: unknown result");
1402
 
1403
  def getValidOrders(self, limit):
1404
    """
1405
    Returns list of Orders in descending order by Order creation date. List is restricted to limit Orders.
1406
    If limit is passed as 0, then all valid Orders are returned.
3431 rajveer 1407
 
3064 chandransh 1408
    Parameters:
1409
     - limit
1410
    """
1411
    self.send_getValidOrders(limit)
1412
    return self.recv_getValidOrders()
1413
 
1414
  def send_getValidOrders(self, limit):
1415
    self._oprot.writeMessageBegin('getValidOrders', TMessageType.CALL, self._seqid)
1416
    args = getValidOrders_args()
1417
    args.limit = limit
1418
    args.write(self._oprot)
1419
    self._oprot.writeMessageEnd()
1420
    self._oprot.trans.flush()
1421
 
1422
  def recv_getValidOrders(self, ):
1423
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1424
    if mtype == TMessageType.EXCEPTION:
1425
      x = TApplicationException()
1426
      x.read(self._iprot)
1427
      self._iprot.readMessageEnd()
1428
      raise x
1429
    result = getValidOrders_result()
1430
    result.read(self._iprot)
1431
    self._iprot.readMessageEnd()
3431 rajveer 1432
    if result.success is not None:
3064 chandransh 1433
      return result.success
1434
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getValidOrders failed: unknown result");
1435
 
1220 chandransh 1436
  def batchOrders(self, warehouseId):
1437
    """
1438
    Create a batch of all the pending orders for the given warehouse.
1439
    The returned list is orderd by created_timestamp.
1440
    If there are no pending orders, an empty list is returned.
3431 rajveer 1441
 
1220 chandransh 1442
    Parameters:
1443
     - warehouseId
1444
    """
1445
    self.send_batchOrders(warehouseId)
1446
    return self.recv_batchOrders()
1447
 
1448
  def send_batchOrders(self, warehouseId):
1449
    self._oprot.writeMessageBegin('batchOrders', TMessageType.CALL, self._seqid)
1450
    args = batchOrders_args()
1451
    args.warehouseId = warehouseId
1452
    args.write(self._oprot)
1453
    self._oprot.writeMessageEnd()
1454
    self._oprot.trans.flush()
1455
 
1456
  def recv_batchOrders(self, ):
1457
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1458
    if mtype == TMessageType.EXCEPTION:
1459
      x = TApplicationException()
1460
      x.read(self._iprot)
1461
      self._iprot.readMessageEnd()
1462
      raise x
1463
    result = batchOrders_result()
1464
    result.read(self._iprot)
1465
    self._iprot.readMessageEnd()
3431 rajveer 1466
    if result.success is not None:
1220 chandransh 1467
      return result.success
3431 rajveer 1468
    if result.ex is not None:
1220 chandransh 1469
      raise result.ex
1470
    raise TApplicationException(TApplicationException.MISSING_RESULT, "batchOrders failed: unknown result");
1471
 
1208 chandransh 1472
  def markOrderAsOutOfStock(self, orderId):
1473
    """
1474
    Mark the given order as out of stock. Throws an exception if the order with the given Id couldn't be found.
3431 rajveer 1475
 
1208 chandransh 1476
    Parameters:
1477
     - orderId
1478
    """
1479
    self.send_markOrderAsOutOfStock(orderId)
1480
    return self.recv_markOrderAsOutOfStock()
1481
 
1482
  def send_markOrderAsOutOfStock(self, orderId):
1483
    self._oprot.writeMessageBegin('markOrderAsOutOfStock', TMessageType.CALL, self._seqid)
1484
    args = markOrderAsOutOfStock_args()
1485
    args.orderId = orderId
1486
    args.write(self._oprot)
1487
    self._oprot.writeMessageEnd()
1488
    self._oprot.trans.flush()
1489
 
1490
  def recv_markOrderAsOutOfStock(self, ):
1491
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1492
    if mtype == TMessageType.EXCEPTION:
1493
      x = TApplicationException()
1494
      x.read(self._iprot)
1495
      self._iprot.readMessageEnd()
1496
      raise x
1497
    result = markOrderAsOutOfStock_result()
1498
    result.read(self._iprot)
1499
    self._iprot.readMessageEnd()
3431 rajveer 1500
    if result.success is not None:
1208 chandransh 1501
      return result.success
3431 rajveer 1502
    if result.ex is not None:
1208 chandransh 1503
      raise result.ex
1504
    raise TApplicationException(TApplicationException.MISSING_RESULT, "markOrderAsOutOfStock failed: unknown result");
1505
 
3064 chandransh 1506
  def verifyOrder(self, orderId):
759 chandransh 1507
    """
3064 chandransh 1508
    Marks the given order as SUBMITTED_FOR_PROCESSING and updates the verified
1509
    timestamp. It is intended to be used for COD orders but can be harmlessly
1510
    used for all other orders as well.
1511
    Throws an exception if no such order exists.
3431 rajveer 1512
 
759 chandransh 1513
    Parameters:
3064 chandransh 1514
     - orderId
759 chandransh 1515
    """
3064 chandransh 1516
    self.send_verifyOrder(orderId)
1517
    return self.recv_verifyOrder()
759 chandransh 1518
 
3064 chandransh 1519
  def send_verifyOrder(self, orderId):
1520
    self._oprot.writeMessageBegin('verifyOrder', TMessageType.CALL, self._seqid)
1521
    args = verifyOrder_args()
1522
    args.orderId = orderId
759 chandransh 1523
    args.write(self._oprot)
1524
    self._oprot.writeMessageEnd()
1525
    self._oprot.trans.flush()
1526
 
3064 chandransh 1527
  def recv_verifyOrder(self, ):
759 chandransh 1528
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1529
    if mtype == TMessageType.EXCEPTION:
1530
      x = TApplicationException()
1531
      x.read(self._iprot)
1532
      self._iprot.readMessageEnd()
1533
      raise x
3064 chandransh 1534
    result = verifyOrder_result()
759 chandransh 1535
    result.read(self._iprot)
1536
    self._iprot.readMessageEnd()
3431 rajveer 1537
    if result.success is not None:
759 chandransh 1538
      return result.success
3431 rajveer 1539
    if result.ex is not None:
759 chandransh 1540
      raise result.ex
3064 chandransh 1541
    raise TApplicationException(TApplicationException.MISSING_RESULT, "verifyOrder failed: unknown result");
759 chandransh 1542
 
3064 chandransh 1543
  def acceptOrder(self, orderId):
1113 chandransh 1544
    """
3064 chandransh 1545
    Marks the given order as ACCEPTED and updates the accepted timestamp. If the
1546
    given order is not a COD order, it also captures the payment if the same has
1547
    not been captured.
1548
    Throws an exception if no such order exists.
3431 rajveer 1549
 
1113 chandransh 1550
    Parameters:
3064 chandransh 1551
     - orderId
1113 chandransh 1552
    """
3064 chandransh 1553
    self.send_acceptOrder(orderId)
1554
    return self.recv_acceptOrder()
1113 chandransh 1555
 
3064 chandransh 1556
  def send_acceptOrder(self, orderId):
1557
    self._oprot.writeMessageBegin('acceptOrder', TMessageType.CALL, self._seqid)
1558
    args = acceptOrder_args()
1559
    args.orderId = orderId
1113 chandransh 1560
    args.write(self._oprot)
1561
    self._oprot.writeMessageEnd()
1562
    self._oprot.trans.flush()
1563
 
3064 chandransh 1564
  def recv_acceptOrder(self, ):
1113 chandransh 1565
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1566
    if mtype == TMessageType.EXCEPTION:
1567
      x = TApplicationException()
1568
      x.read(self._iprot)
1569
      self._iprot.readMessageEnd()
1570
      raise x
3064 chandransh 1571
    result = acceptOrder_result()
1113 chandransh 1572
    result.read(self._iprot)
1573
    self._iprot.readMessageEnd()
3431 rajveer 1574
    if result.success is not None:
1113 chandransh 1575
      return result.success
3431 rajveer 1576
    if result.ex is not None:
1113 chandransh 1577
      raise result.ex
3064 chandransh 1578
    raise TApplicationException(TApplicationException.MISSING_RESULT, "acceptOrder failed: unknown result");
1113 chandransh 1579
 
3064 chandransh 1580
  def billOrder(self, orderId):
1132 chandransh 1581
    """
1582
    Parameters:
3064 chandransh 1583
     - orderId
1132 chandransh 1584
    """
3064 chandransh 1585
    self.send_billOrder(orderId)
1586
    return self.recv_billOrder()
1132 chandransh 1587
 
3064 chandransh 1588
  def send_billOrder(self, orderId):
1589
    self._oprot.writeMessageBegin('billOrder', TMessageType.CALL, self._seqid)
1590
    args = billOrder_args()
1591
    args.orderId = orderId
1132 chandransh 1592
    args.write(self._oprot)
1593
    self._oprot.writeMessageEnd()
1594
    self._oprot.trans.flush()
1595
 
3064 chandransh 1596
  def recv_billOrder(self, ):
1132 chandransh 1597
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1598
    if mtype == TMessageType.EXCEPTION:
1599
      x = TApplicationException()
1600
      x.read(self._iprot)
1601
      self._iprot.readMessageEnd()
1602
      raise x
3064 chandransh 1603
    result = billOrder_result()
1132 chandransh 1604
    result.read(self._iprot)
1605
    self._iprot.readMessageEnd()
3431 rajveer 1606
    if result.success is not None:
3064 chandransh 1607
      return result.success
3431 rajveer 1608
    if result.ex is not None:
1132 chandransh 1609
      raise result.ex
3064 chandransh 1610
    raise TApplicationException(TApplicationException.MISSING_RESULT, "billOrder failed: unknown result");
1132 chandransh 1611
 
3064 chandransh 1612
  def addBillingDetails(self, orderId, invoice_number, billed_by):
1135 chandransh 1613
    """
3064 chandransh 1614
    Add billing details such as the bill number and the biller to the Order.
1615
    Should be used when the bill is issued by a 3rd party and we've to feed
1616
    the information into our system.
3431 rajveer 1617
 
1135 chandransh 1618
    Parameters:
3064 chandransh 1619
     - orderId
1620
     - invoice_number
1621
     - billed_by
1135 chandransh 1622
    """
3064 chandransh 1623
    self.send_addBillingDetails(orderId, invoice_number, billed_by)
1624
    return self.recv_addBillingDetails()
1135 chandransh 1625
 
3064 chandransh 1626
  def send_addBillingDetails(self, orderId, invoice_number, billed_by):
1627
    self._oprot.writeMessageBegin('addBillingDetails', TMessageType.CALL, self._seqid)
1628
    args = addBillingDetails_args()
1629
    args.orderId = orderId
1630
    args.invoice_number = invoice_number
1631
    args.billed_by = billed_by
1135 chandransh 1632
    args.write(self._oprot)
1633
    self._oprot.writeMessageEnd()
1634
    self._oprot.trans.flush()
1635
 
3064 chandransh 1636
  def recv_addBillingDetails(self, ):
1135 chandransh 1637
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1638
    if mtype == TMessageType.EXCEPTION:
1639
      x = TApplicationException()
1640
      x.read(self._iprot)
1641
      self._iprot.readMessageEnd()
1642
      raise x
3064 chandransh 1643
    result = addBillingDetails_result()
1135 chandransh 1644
    result.read(self._iprot)
1645
    self._iprot.readMessageEnd()
3431 rajveer 1646
    if result.success is not None:
3064 chandransh 1647
      return result.success
3431 rajveer 1648
    if result.ex is not None:
1135 chandransh 1649
      raise result.ex
3064 chandransh 1650
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addBillingDetails failed: unknown result");
1135 chandransh 1651
 
3064 chandransh 1652
  def addJacketNumber(self, orderId, jacketNumber, imeiNumber, itemNumber, billedBy, billingType):
1246 chandransh 1653
    """
3064 chandransh 1654
    Adds jacket number, item number and IMEI no. to the order. Doesn't update
1655
    the IMEI no. if a -1 is supplied.
1656
    Also, it generates an invoice number for the order, marks the order as
1657
    BILLED and sets the billing timestamp.
1658
    It should be used when we are billing the orders ourselves.
3431 rajveer 1659
 
3064 chandransh 1660
    Returns false if it doesn't find the order with the given ID.
3431 rajveer 1661
 
1246 chandransh 1662
    Parameters:
3064 chandransh 1663
     - orderId
1664
     - jacketNumber
1665
     - imeiNumber
1666
     - itemNumber
1667
     - billedBy
1668
     - billingType
1246 chandransh 1669
    """
3064 chandransh 1670
    self.send_addJacketNumber(orderId, jacketNumber, imeiNumber, itemNumber, billedBy, billingType)
1671
    return self.recv_addJacketNumber()
1246 chandransh 1672
 
3064 chandransh 1673
  def send_addJacketNumber(self, orderId, jacketNumber, imeiNumber, itemNumber, billedBy, billingType):
1674
    self._oprot.writeMessageBegin('addJacketNumber', TMessageType.CALL, self._seqid)
1675
    args = addJacketNumber_args()
1676
    args.orderId = orderId
1677
    args.jacketNumber = jacketNumber
1678
    args.imeiNumber = imeiNumber
1679
    args.itemNumber = itemNumber
1680
    args.billedBy = billedBy
1681
    args.billingType = billingType
1246 chandransh 1682
    args.write(self._oprot)
1683
    self._oprot.writeMessageEnd()
1684
    self._oprot.trans.flush()
1685
 
3064 chandransh 1686
  def recv_addJacketNumber(self, ):
1246 chandransh 1687
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1688
    if mtype == TMessageType.EXCEPTION:
1689
      x = TApplicationException()
1690
      x.read(self._iprot)
1691
      self._iprot.readMessageEnd()
1692
      raise x
3064 chandransh 1693
    result = addJacketNumber_result()
1246 chandransh 1694
    result.read(self._iprot)
1695
    self._iprot.readMessageEnd()
3431 rajveer 1696
    if result.success is not None:
3064 chandransh 1697
      return result.success
3431 rajveer 1698
    if result.ex is not None:
1246 chandransh 1699
      raise result.ex
3064 chandransh 1700
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addJacketNumber failed: unknown result");
1246 chandransh 1701
 
3064 chandransh 1702
  def markOrdersAsManifested(self, warehouseId, providerId, cod):
1408 ankur.sing 1703
    """
3064 chandransh 1704
    Depending on the third parameter, marks either all prepaid or all cod orders BILLED by the
1705
    given warehouse and were picked up by the given provider as SHIPPED_FROM_WH.
3431 rajveer 1706
 
1408 ankur.sing 1707
    Parameters:
3064 chandransh 1708
     - warehouseId
1408 ankur.sing 1709
     - providerId
3064 chandransh 1710
     - cod
1408 ankur.sing 1711
    """
3064 chandransh 1712
    self.send_markOrdersAsManifested(warehouseId, providerId, cod)
1713
    return self.recv_markOrdersAsManifested()
1408 ankur.sing 1714
 
3064 chandransh 1715
  def send_markOrdersAsManifested(self, warehouseId, providerId, cod):
1716
    self._oprot.writeMessageBegin('markOrdersAsManifested', TMessageType.CALL, self._seqid)
1717
    args = markOrdersAsManifested_args()
1718
    args.warehouseId = warehouseId
1408 ankur.sing 1719
    args.providerId = providerId
3064 chandransh 1720
    args.cod = cod
1408 ankur.sing 1721
    args.write(self._oprot)
1722
    self._oprot.writeMessageEnd()
1723
    self._oprot.trans.flush()
1724
 
3064 chandransh 1725
  def recv_markOrdersAsManifested(self, ):
1408 ankur.sing 1726
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1727
    if mtype == TMessageType.EXCEPTION:
1728
      x = TApplicationException()
1729
      x.read(self._iprot)
1730
      self._iprot.readMessageEnd()
1731
      raise x
3064 chandransh 1732
    result = markOrdersAsManifested_result()
1408 ankur.sing 1733
    result.read(self._iprot)
1734
    self._iprot.readMessageEnd()
3431 rajveer 1735
    if result.success is not None:
1408 ankur.sing 1736
      return result.success
3431 rajveer 1737
    if result.ex is not None:
3064 chandransh 1738
      raise result.ex
1739
    raise TApplicationException(TApplicationException.MISSING_RESULT, "markOrdersAsManifested failed: unknown result");
1408 ankur.sing 1740
 
3064 chandransh 1741
  def markOrdersAsPickedUp(self, providerId, pickupDetails):
94 ashish 1742
    """
3064 chandransh 1743
    Marks all SHIPPED_FROM_WH orders of the previous day for a provider as SHIPPED_TO_LOGISTICS.
1744
    Returns a list of orders that were shipped from warehouse but did not appear in the pick-up report.
1745
    Raises an exception if we encounter report for an AWB number that we did not ship.
3431 rajveer 1746
 
94 ashish 1747
    Parameters:
3064 chandransh 1748
     - providerId
1749
     - pickupDetails
304 ashish 1750
    """
3064 chandransh 1751
    self.send_markOrdersAsPickedUp(providerId, pickupDetails)
1752
    return self.recv_markOrdersAsPickedUp()
94 ashish 1753
 
3064 chandransh 1754
  def send_markOrdersAsPickedUp(self, providerId, pickupDetails):
1755
    self._oprot.writeMessageBegin('markOrdersAsPickedUp', TMessageType.CALL, self._seqid)
1756
    args = markOrdersAsPickedUp_args()
1757
    args.providerId = providerId
1758
    args.pickupDetails = pickupDetails
304 ashish 1759
    args.write(self._oprot)
1760
    self._oprot.writeMessageEnd()
1761
    self._oprot.trans.flush()
1762
 
3064 chandransh 1763
  def recv_markOrdersAsPickedUp(self, ):
304 ashish 1764
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1765
    if mtype == TMessageType.EXCEPTION:
1766
      x = TApplicationException()
1767
      x.read(self._iprot)
1768
      self._iprot.readMessageEnd()
1769
      raise x
3064 chandransh 1770
    result = markOrdersAsPickedUp_result()
304 ashish 1771
    result.read(self._iprot)
1772
    self._iprot.readMessageEnd()
3431 rajveer 1773
    if result.success is not None:
304 ashish 1774
      return result.success
3431 rajveer 1775
    if result.ex is not None:
3064 chandransh 1776
      raise result.ex
1777
    raise TApplicationException(TApplicationException.MISSING_RESULT, "markOrdersAsPickedUp failed: unknown result");
304 ashish 1778
 
3064 chandransh 1779
  def markOrdersAsDelivered(self, providerId, deliveredOrders):
304 ashish 1780
    """
3064 chandransh 1781
    Marks all orders with AWBs in the given map as delivered. Also sets the delivery timestamp and
1782
    the name of the receiver.
1783
    Raises an exception if we encounter report for an AWB number that we did not ship.
3431 rajveer 1784
 
304 ashish 1785
    Parameters:
3064 chandransh 1786
     - providerId
1787
     - deliveredOrders
304 ashish 1788
    """
3064 chandransh 1789
    self.send_markOrdersAsDelivered(providerId, deliveredOrders)
1790
    self.recv_markOrdersAsDelivered()
304 ashish 1791
 
3064 chandransh 1792
  def send_markOrdersAsDelivered(self, providerId, deliveredOrders):
1793
    self._oprot.writeMessageBegin('markOrdersAsDelivered', TMessageType.CALL, self._seqid)
1794
    args = markOrdersAsDelivered_args()
1795
    args.providerId = providerId
1796
    args.deliveredOrders = deliveredOrders
304 ashish 1797
    args.write(self._oprot)
1798
    self._oprot.writeMessageEnd()
1799
    self._oprot.trans.flush()
1800
 
3064 chandransh 1801
  def recv_markOrdersAsDelivered(self, ):
304 ashish 1802
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1803
    if mtype == TMessageType.EXCEPTION:
1804
      x = TApplicationException()
1805
      x.read(self._iprot)
1806
      self._iprot.readMessageEnd()
1807
      raise x
3064 chandransh 1808
    result = markOrdersAsDelivered_result()
304 ashish 1809
    result.read(self._iprot)
1810
    self._iprot.readMessageEnd()
3431 rajveer 1811
    if result.ex is not None:
3064 chandransh 1812
      raise result.ex
304 ashish 1813
    return
1814
 
3064 chandransh 1815
  def markOrdersAsFailed(self, providerId, returnedOrders):
1596 ankur.sing 1816
    """
3064 chandransh 1817
    Mark all orders with AWBs in the given map as failed. Also sets the delivery timestamp.
1818
    Raises an exception if we encounter report for an AWB number that we did not ship.
3431 rajveer 1819
 
3064 chandransh 1820
    Parameters:
1821
     - providerId
1822
     - returnedOrders
1596 ankur.sing 1823
    """
3064 chandransh 1824
    self.send_markOrdersAsFailed(providerId, returnedOrders)
1825
    self.recv_markOrdersAsFailed()
304 ashish 1826
 
3064 chandransh 1827
  def send_markOrdersAsFailed(self, providerId, returnedOrders):
1828
    self._oprot.writeMessageBegin('markOrdersAsFailed', TMessageType.CALL, self._seqid)
1829
    args = markOrdersAsFailed_args()
1830
    args.providerId = providerId
1831
    args.returnedOrders = returnedOrders
1596 ankur.sing 1832
    args.write(self._oprot)
1833
    self._oprot.writeMessageEnd()
1834
    self._oprot.trans.flush()
1835
 
3064 chandransh 1836
  def recv_markOrdersAsFailed(self, ):
1596 ankur.sing 1837
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1838
    if mtype == TMessageType.EXCEPTION:
1839
      x = TApplicationException()
1840
      x.read(self._iprot)
1841
      self._iprot.readMessageEnd()
1842
      raise x
3064 chandransh 1843
    result = markOrdersAsFailed_result()
1596 ankur.sing 1844
    result.read(self._iprot)
1845
    self._iprot.readMessageEnd()
3431 rajveer 1846
    if result.ex is not None:
3064 chandransh 1847
      raise result.ex
1848
    return
1596 ankur.sing 1849
 
3064 chandransh 1850
  def updateNonDeliveryReason(self, providerId, undeliveredOrders):
1627 ankur.sing 1851
    """
3064 chandransh 1852
    Update the status description of orders whose AWB numbers are keys of the Map.
3431 rajveer 1853
 
3064 chandransh 1854
    Parameters:
1855
     - providerId
1856
     - undeliveredOrders
1627 ankur.sing 1857
    """
3064 chandransh 1858
    self.send_updateNonDeliveryReason(providerId, undeliveredOrders)
1859
    self.recv_updateNonDeliveryReason()
1596 ankur.sing 1860
 
3064 chandransh 1861
  def send_updateNonDeliveryReason(self, providerId, undeliveredOrders):
1862
    self._oprot.writeMessageBegin('updateNonDeliveryReason', TMessageType.CALL, self._seqid)
1863
    args = updateNonDeliveryReason_args()
1864
    args.providerId = providerId
1865
    args.undeliveredOrders = undeliveredOrders
1627 ankur.sing 1866
    args.write(self._oprot)
1867
    self._oprot.writeMessageEnd()
1868
    self._oprot.trans.flush()
1869
 
3064 chandransh 1870
  def recv_updateNonDeliveryReason(self, ):
1627 ankur.sing 1871
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1872
    if mtype == TMessageType.EXCEPTION:
1873
      x = TApplicationException()
1874
      x.read(self._iprot)
1875
      self._iprot.readMessageEnd()
1876
      raise x
3064 chandransh 1877
    result = updateNonDeliveryReason_result()
1627 ankur.sing 1878
    result.read(self._iprot)
1879
    self._iprot.readMessageEnd()
3431 rajveer 1880
    if result.ex is not None:
3064 chandransh 1881
      raise result.ex
1882
    return
1627 ankur.sing 1883
 
3064 chandransh 1884
  def getUndeliveredOrders(self, providerId, warehouseId):
1627 ankur.sing 1885
    """
3064 chandransh 1886
    Returns the list of orders whose delivery time has passed but have not been
1887
    delivered yet for the given provider and warehouse. To get a complete list of
1888
    undelivered orders, pass them as -1.
1889
    Returns an empty list if no such orders exist.
3431 rajveer 1890
 
1886 ankur.sing 1891
    Parameters:
3064 chandransh 1892
     - providerId
1893
     - warehouseId
1886 ankur.sing 1894
    """
3064 chandransh 1895
    self.send_getUndeliveredOrders(providerId, warehouseId)
1896
    return self.recv_getUndeliveredOrders()
1627 ankur.sing 1897
 
3064 chandransh 1898
  def send_getUndeliveredOrders(self, providerId, warehouseId):
1899
    self._oprot.writeMessageBegin('getUndeliveredOrders', TMessageType.CALL, self._seqid)
1900
    args = getUndeliveredOrders_args()
1901
    args.providerId = providerId
1902
    args.warehouseId = warehouseId
1886 ankur.sing 1903
    args.write(self._oprot)
1904
    self._oprot.writeMessageEnd()
1905
    self._oprot.trans.flush()
1906
 
3064 chandransh 1907
  def recv_getUndeliveredOrders(self, ):
1886 ankur.sing 1908
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1909
    if mtype == TMessageType.EXCEPTION:
1910
      x = TApplicationException()
1911
      x.read(self._iprot)
1912
      self._iprot.readMessageEnd()
1913
      raise x
3064 chandransh 1914
    result = getUndeliveredOrders_result()
1886 ankur.sing 1915
    result.read(self._iprot)
1916
    self._iprot.readMessageEnd()
3431 rajveer 1917
    if result.success is not None:
1886 ankur.sing 1918
      return result.success
3064 chandransh 1919
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUndeliveredOrders failed: unknown result");
1886 ankur.sing 1920
 
2536 chandransh 1921
  def toggleDOAFlag(self, orderId):
1922
    """
1923
    Toggle the DOA flag of an order. This should be used to flag an order for follow-up and unflag it when the follow-up is complete.
1924
    Returns the final flag status.
1925
    Throws an exception if the order with the given id couldn't be found or if the order status is not DELVIERY_SUCCESS.
3431 rajveer 1926
 
2536 chandransh 1927
    Parameters:
1928
     - orderId
1929
    """
1930
    self.send_toggleDOAFlag(orderId)
1931
    return self.recv_toggleDOAFlag()
1886 ankur.sing 1932
 
2536 chandransh 1933
  def send_toggleDOAFlag(self, orderId):
1934
    self._oprot.writeMessageBegin('toggleDOAFlag', TMessageType.CALL, self._seqid)
1935
    args = toggleDOAFlag_args()
1936
    args.orderId = orderId
1937
    args.write(self._oprot)
1938
    self._oprot.writeMessageEnd()
1939
    self._oprot.trans.flush()
1940
 
1941
  def recv_toggleDOAFlag(self, ):
1942
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1943
    if mtype == TMessageType.EXCEPTION:
1944
      x = TApplicationException()
1945
      x.read(self._iprot)
1946
      self._iprot.readMessageEnd()
1947
      raise x
1948
    result = toggleDOAFlag_result()
1949
    result.read(self._iprot)
1950
    self._iprot.readMessageEnd()
3431 rajveer 1951
    if result.success is not None:
2536 chandransh 1952
      return result.success
3431 rajveer 1953
    if result.ex is not None:
2536 chandransh 1954
      raise result.ex
1955
    raise TApplicationException(TApplicationException.MISSING_RESULT, "toggleDOAFlag failed: unknown result");
1956
 
1957
  def requestPickupNumber(self, orderId):
1958
    """
1959
    Sends out an email to the account manager of the original courier provider used to ship the order.
1960
    If the order status was DELIVERY_SUCCESS, it is changed to be DOA_PICKUP_REQUESTED.
1961
    If the order status was DOA_PICKUP_REQUESTED, it is left unchanged.
1962
    For any other status, it returns false.
1963
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 1964
 
2536 chandransh 1965
    Parameters:
1966
     - orderId
1967
    """
1968
    self.send_requestPickupNumber(orderId)
1969
    return self.recv_requestPickupNumber()
1970
 
1971
  def send_requestPickupNumber(self, orderId):
1972
    self._oprot.writeMessageBegin('requestPickupNumber', TMessageType.CALL, self._seqid)
1973
    args = requestPickupNumber_args()
1974
    args.orderId = orderId
1975
    args.write(self._oprot)
1976
    self._oprot.writeMessageEnd()
1977
    self._oprot.trans.flush()
1978
 
1979
  def recv_requestPickupNumber(self, ):
1980
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1981
    if mtype == TMessageType.EXCEPTION:
1982
      x = TApplicationException()
1983
      x.read(self._iprot)
1984
      self._iprot.readMessageEnd()
1985
      raise x
1986
    result = requestPickupNumber_result()
1987
    result.read(self._iprot)
1988
    self._iprot.readMessageEnd()
3431 rajveer 1989
    if result.success is not None:
2536 chandransh 1990
      return result.success
3431 rajveer 1991
    if result.ex is not None:
2536 chandransh 1992
      raise result.ex
1993
    raise TApplicationException(TApplicationException.MISSING_RESULT, "requestPickupNumber failed: unknown result");
1994
 
1995
  def authorizePickup(self, orderId, pickupNumber):
1996
    """
1997
    If the order status is DOA_PICKUP_REQUESTED, it does the following
1998
    	1. Sends out an email to the customer with the dispatch advice that he has to print as an attachment.
1999
    	2. Changes order status to be DOA_PICKUP_AUTHORIZED.
2000
    	3. Returns true
2591 chandransh 2001
    If the order is in any other status, it returns false.
2536 chandransh 2002
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 2003
 
2536 chandransh 2004
    Parameters:
2005
     - orderId
2006
     - pickupNumber
2007
    """
2008
    self.send_authorizePickup(orderId, pickupNumber)
2009
    return self.recv_authorizePickup()
2010
 
2011
  def send_authorizePickup(self, orderId, pickupNumber):
2012
    self._oprot.writeMessageBegin('authorizePickup', TMessageType.CALL, self._seqid)
2013
    args = authorizePickup_args()
2014
    args.orderId = orderId
2015
    args.pickupNumber = pickupNumber
2016
    args.write(self._oprot)
2017
    self._oprot.writeMessageEnd()
2018
    self._oprot.trans.flush()
2019
 
2020
  def recv_authorizePickup(self, ):
2021
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2022
    if mtype == TMessageType.EXCEPTION:
2023
      x = TApplicationException()
2024
      x.read(self._iprot)
2025
      self._iprot.readMessageEnd()
2026
      raise x
2027
    result = authorizePickup_result()
2028
    result.read(self._iprot)
2029
    self._iprot.readMessageEnd()
3431 rajveer 2030
    if result.success is not None:
2536 chandransh 2031
      return result.success
3431 rajveer 2032
    if result.ex is not None:
2536 chandransh 2033
      raise result.ex
2034
    raise TApplicationException(TApplicationException.MISSING_RESULT, "authorizePickup failed: unknown result");
2035
 
2764 chandransh 2036
  def markDoasAsPickedUp(self, providerId, pickupDetails):
2037
    """
2038
    Marks all DOA_PICKUP_AUTHORIZED orders of the previous day for a provider as DOA_RETURN_IN_TRANSIT.
2039
    Returns a list of orders that were authorized for pickup but did not appear in the pick-up report.
3431 rajveer 2040
 
2764 chandransh 2041
    Parameters:
2042
     - providerId
2043
     - pickupDetails
2044
    """
2045
    self.send_markDoasAsPickedUp(providerId, pickupDetails)
2046
    return self.recv_markDoasAsPickedUp()
2047
 
2048
  def send_markDoasAsPickedUp(self, providerId, pickupDetails):
2049
    self._oprot.writeMessageBegin('markDoasAsPickedUp', TMessageType.CALL, self._seqid)
2050
    args = markDoasAsPickedUp_args()
2051
    args.providerId = providerId
2052
    args.pickupDetails = pickupDetails
2053
    args.write(self._oprot)
2054
    self._oprot.writeMessageEnd()
2055
    self._oprot.trans.flush()
2056
 
2057
  def recv_markDoasAsPickedUp(self, ):
2058
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2059
    if mtype == TMessageType.EXCEPTION:
2060
      x = TApplicationException()
2061
      x.read(self._iprot)
2062
      self._iprot.readMessageEnd()
2063
      raise x
2064
    result = markDoasAsPickedUp_result()
2065
    result.read(self._iprot)
2066
    self._iprot.readMessageEnd()
3431 rajveer 2067
    if result.success is not None:
2764 chandransh 2068
      return result.success
2069
    raise TApplicationException(TApplicationException.MISSING_RESULT, "markDoasAsPickedUp failed: unknown result");
2070
 
2616 chandransh 2071
  def receiveReturn(self, orderId):
2591 chandransh 2072
    """
2599 chandransh 2073
    If the order status is DOA_RETURN_AUTHORIZED or DOA_RETURN_IN_TRANSIT, marks the order status as DOA_RECEIVED and returns true.
2616 chandransh 2074
    If the order status is SALES_RETURN_IN_TRANSIT, marks the order status as SALES_RET_RECEIVED and returns true.
2591 chandransh 2075
    If the order is in any other state, it returns false.
2076
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 2077
 
2591 chandransh 2078
    Parameters:
2079
     - orderId
2080
    """
2616 chandransh 2081
    self.send_receiveReturn(orderId)
2082
    return self.recv_receiveReturn()
2536 chandransh 2083
 
2616 chandransh 2084
  def send_receiveReturn(self, orderId):
2085
    self._oprot.writeMessageBegin('receiveReturn', TMessageType.CALL, self._seqid)
2086
    args = receiveReturn_args()
2591 chandransh 2087
    args.orderId = orderId
2088
    args.write(self._oprot)
2089
    self._oprot.writeMessageEnd()
2090
    self._oprot.trans.flush()
2091
 
2616 chandransh 2092
  def recv_receiveReturn(self, ):
2591 chandransh 2093
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2094
    if mtype == TMessageType.EXCEPTION:
2095
      x = TApplicationException()
2096
      x.read(self._iprot)
2097
      self._iprot.readMessageEnd()
2098
      raise x
2616 chandransh 2099
    result = receiveReturn_result()
2591 chandransh 2100
    result.read(self._iprot)
2101
    self._iprot.readMessageEnd()
3431 rajveer 2102
    if result.success is not None:
2591 chandransh 2103
      return result.success
3431 rajveer 2104
    if result.ex is not None:
2591 chandransh 2105
      raise result.ex
2616 chandransh 2106
    raise TApplicationException(TApplicationException.MISSING_RESULT, "receiveReturn failed: unknown result");
2591 chandransh 2107
 
2108
  def validateDoa(self, orderId, isValid):
2109
    """
2599 chandransh 2110
    Used to validate the DOA certificate for an order in the DOA_RECEIVED state. If the certificate is valid,
2616 chandransh 2111
    the order state is changed to DOA_CERT_VALID. If the certificate is invalid, the order state is changed to DOA_CERT_INVALID.
2591 chandransh 2112
    If the order is in any other state, it returns false.
2113
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 2114
 
2591 chandransh 2115
    Parameters:
2116
     - orderId
2117
     - isValid
2118
    """
2119
    self.send_validateDoa(orderId, isValid)
2120
    return self.recv_validateDoa()
2121
 
2122
  def send_validateDoa(self, orderId, isValid):
2123
    self._oprot.writeMessageBegin('validateDoa', TMessageType.CALL, self._seqid)
2124
    args = validateDoa_args()
2125
    args.orderId = orderId
2126
    args.isValid = isValid
2127
    args.write(self._oprot)
2128
    self._oprot.writeMessageEnd()
2129
    self._oprot.trans.flush()
2130
 
2131
  def recv_validateDoa(self, ):
2132
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2133
    if mtype == TMessageType.EXCEPTION:
2134
      x = TApplicationException()
2135
      x.read(self._iprot)
2136
      self._iprot.readMessageEnd()
2137
      raise x
2138
    result = validateDoa_result()
2139
    result.read(self._iprot)
2140
    self._iprot.readMessageEnd()
3431 rajveer 2141
    if result.success is not None:
2591 chandransh 2142
      return result.success
3431 rajveer 2143
    if result.ex is not None:
2591 chandransh 2144
      raise result.ex
2145
    raise TApplicationException(TApplicationException.MISSING_RESULT, "validateDoa failed: unknown result");
2146
 
2616 chandransh 2147
  def reshipOrder(self, orderId):
2148
    """
2149
    If the order is in SALES_RET_RECEIVED or DOA_CERT_INVALID state, it does the following:
2150
    	1. Creates a new order for processing in the BILLED state. All billing information is saved.
2151
    	2. Marks the current order as one of the final states SALES_RET_RESHIPPED and DOA_INVALID_RESHIPPED depending on what state the order started in.
2152
 
2153
    If the order is in DOA_CERT_VALID state, it does the following:
2154
    	1. Creates a new order for processing in the SUBMITTED_FOR_PROCESSING state.
2155
    	2. Creates a return order for the warehouse executive to return the DOA material.
2156
    	3. Marks the current order as the final DOA_RESHIPPED state.
3431 rajveer 2157
 
2616 chandransh 2158
    Returns the id of the newly created order.
3431 rajveer 2159
 
2616 chandransh 2160
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 2161
 
2616 chandransh 2162
    Parameters:
2163
     - orderId
2164
    """
2165
    self.send_reshipOrder(orderId)
2166
    return self.recv_reshipOrder()
2591 chandransh 2167
 
2616 chandransh 2168
  def send_reshipOrder(self, orderId):
2169
    self._oprot.writeMessageBegin('reshipOrder', TMessageType.CALL, self._seqid)
2170
    args = reshipOrder_args()
2171
    args.orderId = orderId
2172
    args.write(self._oprot)
2173
    self._oprot.writeMessageEnd()
2174
    self._oprot.trans.flush()
2175
 
2176
  def recv_reshipOrder(self, ):
2177
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2178
    if mtype == TMessageType.EXCEPTION:
2179
      x = TApplicationException()
2180
      x.read(self._iprot)
2181
      self._iprot.readMessageEnd()
2182
      raise x
2183
    result = reshipOrder_result()
2184
    result.read(self._iprot)
2185
    self._iprot.readMessageEnd()
3431 rajveer 2186
    if result.success is not None:
2616 chandransh 2187
      return result.success
3431 rajveer 2188
    if result.ex is not None:
2616 chandransh 2189
      raise result.ex
2190
    raise TApplicationException(TApplicationException.MISSING_RESULT, "reshipOrder failed: unknown result");
2191
 
3226 chandransh 2192
  def refundOrder(self, orderId, refundedBy, reason):
2616 chandransh 2193
    """
2194
    If the order is in SALES_RET_RECEIVED, DOA_CERT_VALID or DOA_CERT_INVALID state, it does the following:
2195
    	1. Creates a refund request for batch processing.
2196
    	2. Creates a return order for the warehouse executive to return the shipped material.
2197
    	3. Marks the current order as SALES_RET_REFUNDED, DOA_VALID_REFUNDED or DOA_INVALID_REFUNDED final states.
3431 rajveer 2198
 
2616 chandransh 2199
    If the order is in SUBMITTED_FOR_PROCESSING or INVENTORY_LOW state, it does the following:
2200
    	1. Creates a refund request for batch processing.
3226 chandransh 2201
    	2. Cancels the reservation of the item in the warehouse.
2202
    	3. Marks the current order as the REFUNDED final state.
3431 rajveer 2203
 
3226 chandransh 2204
    For all COD orders, if the order is in INIT, SUBMITTED_FOR_PROCESSING or INVENTORY_LOW state, it does the following:
2205
    	1. Cancels the reservation of the item in the warehouse.
2206
    	2. Marks the current order as CANCELED.
2207
 
2208
    In all cases, it updates the reason for cancellation or refund and the person who performed the action.
2209
 
2616 chandransh 2210
    Returns True if it is successful, False otherwise.
3431 rajveer 2211
 
2616 chandransh 2212
    Throws an exception if the order with the given id couldn't be found.
3431 rajveer 2213
 
2616 chandransh 2214
    Parameters:
2215
     - orderId
3226 chandransh 2216
     - refundedBy
2217
     - reason
2616 chandransh 2218
    """
3226 chandransh 2219
    self.send_refundOrder(orderId, refundedBy, reason)
2616 chandransh 2220
    return self.recv_refundOrder()
2221
 
3226 chandransh 2222
  def send_refundOrder(self, orderId, refundedBy, reason):
2616 chandransh 2223
    self._oprot.writeMessageBegin('refundOrder', TMessageType.CALL, self._seqid)
2224
    args = refundOrder_args()
2225
    args.orderId = orderId
3226 chandransh 2226
    args.refundedBy = refundedBy
2227
    args.reason = reason
2616 chandransh 2228
    args.write(self._oprot)
2229
    self._oprot.writeMessageEnd()
2230
    self._oprot.trans.flush()
2231
 
2232
  def recv_refundOrder(self, ):
2233
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2234
    if mtype == TMessageType.EXCEPTION:
2235
      x = TApplicationException()
2236
      x.read(self._iprot)
2237
      self._iprot.readMessageEnd()
2238
      raise x
2239
    result = refundOrder_result()
2240
    result.read(self._iprot)
2241
    self._iprot.readMessageEnd()
3431 rajveer 2242
    if result.success is not None:
2616 chandransh 2243
      return result.success
3431 rajveer 2244
    if result.ex is not None:
2616 chandransh 2245
      raise result.ex
2246
    raise TApplicationException(TApplicationException.MISSING_RESULT, "refundOrder failed: unknown result");
2247
 
2690 chandransh 2248
  def getReturnOrders(self, warehouseId, fromDate, toDate):
2249
    """
2250
    Get all return orders created between the from and to dates for the given warehouse.
2251
    Ignores the warehouse if it is passed as -1.
3431 rajveer 2252
 
2690 chandransh 2253
    Parameters:
2254
     - warehouseId
2255
     - fromDate
2256
     - toDate
2257
    """
2258
    self.send_getReturnOrders(warehouseId, fromDate, toDate)
2259
    return self.recv_getReturnOrders()
2616 chandransh 2260
 
2690 chandransh 2261
  def send_getReturnOrders(self, warehouseId, fromDate, toDate):
2262
    self._oprot.writeMessageBegin('getReturnOrders', TMessageType.CALL, self._seqid)
2263
    args = getReturnOrders_args()
2264
    args.warehouseId = warehouseId
2265
    args.fromDate = fromDate
2266
    args.toDate = toDate
2267
    args.write(self._oprot)
2268
    self._oprot.writeMessageEnd()
2269
    self._oprot.trans.flush()
2270
 
2271
  def recv_getReturnOrders(self, ):
2272
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2273
    if mtype == TMessageType.EXCEPTION:
2274
      x = TApplicationException()
2275
      x.read(self._iprot)
2276
      self._iprot.readMessageEnd()
2277
      raise x
2278
    result = getReturnOrders_result()
2279
    result.read(self._iprot)
2280
    self._iprot.readMessageEnd()
3431 rajveer 2281
    if result.success is not None:
2690 chandransh 2282
      return result.success
2283
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getReturnOrders failed: unknown result");
2284
 
2700 chandransh 2285
  def getReturnOrder(self, id):
2286
    """
2287
    Returns the ReturnOrder corresponding to the given id.
2288
    Throws an exception if the return order with the given id couldn't be found.
3431 rajveer 2289
 
2700 chandransh 2290
    Parameters:
2291
     - id
2292
    """
2293
    self.send_getReturnOrder(id)
2294
    return self.recv_getReturnOrder()
2295
 
2296
  def send_getReturnOrder(self, id):
2297
    self._oprot.writeMessageBegin('getReturnOrder', TMessageType.CALL, self._seqid)
2298
    args = getReturnOrder_args()
2299
    args.id = id
2300
    args.write(self._oprot)
2301
    self._oprot.writeMessageEnd()
2302
    self._oprot.trans.flush()
2303
 
2304
  def recv_getReturnOrder(self, ):
2305
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2306
    if mtype == TMessageType.EXCEPTION:
2307
      x = TApplicationException()
2308
      x.read(self._iprot)
2309
      self._iprot.readMessageEnd()
2310
      raise x
2311
    result = getReturnOrder_result()
2312
    result.read(self._iprot)
2313
    self._iprot.readMessageEnd()
3431 rajveer 2314
    if result.success is not None:
2700 chandransh 2315
      return result.success
3431 rajveer 2316
    if result.ex is not None:
2700 chandransh 2317
      raise result.ex
2318
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getReturnOrder failed: unknown result");
2319
 
2690 chandransh 2320
  def processReturn(self, returnOrderId):
2321
    """
2322
    Marks the return order with the given id as processed. Raises an exception if no such return order exists.
3431 rajveer 2323
 
2690 chandransh 2324
    Parameters:
2325
     - returnOrderId
2326
    """
2327
    self.send_processReturn(returnOrderId)
2328
    self.recv_processReturn()
2329
 
2330
  def send_processReturn(self, returnOrderId):
2331
    self._oprot.writeMessageBegin('processReturn', TMessageType.CALL, self._seqid)
2332
    args = processReturn_args()
2333
    args.returnOrderId = returnOrderId
2334
    args.write(self._oprot)
2335
    self._oprot.writeMessageEnd()
2336
    self._oprot.trans.flush()
2337
 
2338
  def recv_processReturn(self, ):
2339
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2340
    if mtype == TMessageType.EXCEPTION:
2341
      x = TApplicationException()
2342
      x.read(self._iprot)
2343
      self._iprot.readMessageEnd()
2344
      raise x
2345
    result = processReturn_result()
2346
    result.read(self._iprot)
2347
    self._iprot.readMessageEnd()
3431 rajveer 2348
    if result.ex is not None:
2690 chandransh 2349
      raise result.ex
2350
    return
2351
 
2819 chandransh 2352
  def createPurchaseOrder(self, warehouseId):
2353
    """
2354
    Creates a purchase order corresponding to all the pending orders of the given warehouse.
2842 chandransh 2355
    Returns the PO no. of the newly created purchase order. Returns -1 no new purchase order had to be created.
3431 rajveer 2356
 
2819 chandransh 2357
    Parameters:
2358
     - warehouseId
2359
    """
2360
    self.send_createPurchaseOrder(warehouseId)
2361
    return self.recv_createPurchaseOrder()
2690 chandransh 2362
 
2819 chandransh 2363
  def send_createPurchaseOrder(self, warehouseId):
2364
    self._oprot.writeMessageBegin('createPurchaseOrder', TMessageType.CALL, self._seqid)
2365
    args = createPurchaseOrder_args()
2366
    args.warehouseId = warehouseId
2367
    args.write(self._oprot)
2368
    self._oprot.writeMessageEnd()
2369
    self._oprot.trans.flush()
2370
 
2371
  def recv_createPurchaseOrder(self, ):
2372
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2373
    if mtype == TMessageType.EXCEPTION:
2374
      x = TApplicationException()
2375
      x.read(self._iprot)
2376
      self._iprot.readMessageEnd()
2377
      raise x
2378
    result = createPurchaseOrder_result()
2379
    result.read(self._iprot)
2380
    self._iprot.readMessageEnd()
3431 rajveer 2381
    if result.success is not None:
2819 chandransh 2382
      return result.success
3431 rajveer 2383
    if result.ex is not None:
2819 chandransh 2384
      raise result.ex
2385
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createPurchaseOrder failed: unknown result");
2386
 
3451 chandransh 2387
  def updateWeight(self, orderId, weight):
2388
    """
2389
    Set the weight of the given order to the provided value. Will attempt to update the weight of the item in the catalog as well.
2819 chandransh 2390
 
3451 chandransh 2391
    Parameters:
2392
     - orderId
2393
     - weight
2394
    """
2395
    self.send_updateWeight(orderId, weight)
2396
    return self.recv_updateWeight()
2397
 
2398
  def send_updateWeight(self, orderId, weight):
2399
    self._oprot.writeMessageBegin('updateWeight', TMessageType.CALL, self._seqid)
2400
    args = updateWeight_args()
2401
    args.orderId = orderId
2402
    args.weight = weight
2403
    args.write(self._oprot)
2404
    self._oprot.writeMessageEnd()
2405
    self._oprot.trans.flush()
2406
 
2407
  def recv_updateWeight(self, ):
2408
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
2409
    if mtype == TMessageType.EXCEPTION:
2410
      x = TApplicationException()
2411
      x.read(self._iprot)
2412
      self._iprot.readMessageEnd()
2413
      raise x
2414
    result = updateWeight_result()
2415
    result.read(self._iprot)
2416
    self._iprot.readMessageEnd()
2417
    if result.success is not None:
2418
      return result.success
2419
    if result.ex is not None:
2420
      raise result.ex
2421
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updateWeight failed: unknown result");
2422
 
2423
 
3376 rajveer 2424
class Processor(shop2020.thriftpy.generic.GenericService.Processor, Iface, TProcessor):
94 ashish 2425
  def __init__(self, handler):
3376 rajveer 2426
    shop2020.thriftpy.generic.GenericService.Processor.__init__(self, handler)
94 ashish 2427
    self._processMap["createTransaction"] = Processor.process_createTransaction
2428
    self._processMap["getTransaction"] = Processor.process_getTransaction
2429
    self._processMap["getTransactionsForCustomer"] = Processor.process_getTransactionsForCustomer
132 ashish 2430
    self._processMap["getTransactionsForShoppingCartId"] = Processor.process_getTransactionsForShoppingCartId
94 ashish 2431
    self._processMap["getTransactionStatus"] = Processor.process_getTransactionStatus
2432
    self._processMap["changeTransactionStatus"] = Processor.process_changeTransactionStatus
1398 varun.gupt 2433
    self._processMap["enqueueTransactionInfoEmail"] = Processor.process_enqueueTransactionInfoEmail
483 rajveer 2434
    self._processMap["getAllOrders"] = Processor.process_getAllOrders
999 varun.gupt 2435
    self._processMap["getOrdersByBillingDate"] = Processor.process_getOrdersByBillingDate
3427 chandransh 2436
    self._processMap["getOrdersByShippingDate"] = Processor.process_getOrdersByShippingDate
1382 varun.gupt 2437
    self._processMap["getReturnableOrdersForCustomer"] = Processor.process_getReturnableOrdersForCustomer
2438
    self._processMap["getCancellableOrdersForCustomer"] = Processor.process_getCancellableOrdersForCustomer
483 rajveer 2439
    self._processMap["changeOrderStatus"] = Processor.process_changeOrderStatus
2440
    self._processMap["getOrdersForTransaction"] = Processor.process_getOrdersForTransaction
2441
    self._processMap["getOrdersForCustomer"] = Processor.process_getOrdersForCustomer
2442
    self._processMap["createOrder"] = Processor.process_createOrder
2443
    self._processMap["getOrder"] = Processor.process_getOrder
2444
    self._processMap["getLineItemsForOrder"] = Processor.process_getLineItemsForOrder
1528 ankur.sing 2445
    self._processMap["getOrderForCustomer"] = Processor.process_getOrderForCustomer
3064 chandransh 2446
    self._processMap["getAlerts"] = Processor.process_getAlerts
2447
    self._processMap["setAlert"] = Processor.process_setAlert
2448
    self._processMap["getValidOrderCount"] = Processor.process_getValidOrderCount
2449
    self._processMap["getNoOfCustomersWithSuccessfulTransaction"] = Processor.process_getNoOfCustomersWithSuccessfulTransaction
2450
    self._processMap["getValidOrdersAmountRange"] = Processor.process_getValidOrdersAmountRange
2451
    self._processMap["getValidOrders"] = Processor.process_getValidOrders
1220 chandransh 2452
    self._processMap["batchOrders"] = Processor.process_batchOrders
1208 chandransh 2453
    self._processMap["markOrderAsOutOfStock"] = Processor.process_markOrderAsOutOfStock
3064 chandransh 2454
    self._processMap["verifyOrder"] = Processor.process_verifyOrder
2455
    self._processMap["acceptOrder"] = Processor.process_acceptOrder
2456
    self._processMap["billOrder"] = Processor.process_billOrder
2457
    self._processMap["addBillingDetails"] = Processor.process_addBillingDetails
2458
    self._processMap["addJacketNumber"] = Processor.process_addJacketNumber
759 chandransh 2459
    self._processMap["markOrdersAsManifested"] = Processor.process_markOrdersAsManifested
1113 chandransh 2460
    self._processMap["markOrdersAsPickedUp"] = Processor.process_markOrdersAsPickedUp
1132 chandransh 2461
    self._processMap["markOrdersAsDelivered"] = Processor.process_markOrdersAsDelivered
1135 chandransh 2462
    self._processMap["markOrdersAsFailed"] = Processor.process_markOrdersAsFailed
1246 chandransh 2463
    self._processMap["updateNonDeliveryReason"] = Processor.process_updateNonDeliveryReason
1408 ankur.sing 2464
    self._processMap["getUndeliveredOrders"] = Processor.process_getUndeliveredOrders
2536 chandransh 2465
    self._processMap["toggleDOAFlag"] = Processor.process_toggleDOAFlag
2466
    self._processMap["requestPickupNumber"] = Processor.process_requestPickupNumber
2467
    self._processMap["authorizePickup"] = Processor.process_authorizePickup
2764 chandransh 2468
    self._processMap["markDoasAsPickedUp"] = Processor.process_markDoasAsPickedUp
2616 chandransh 2469
    self._processMap["receiveReturn"] = Processor.process_receiveReturn
2591 chandransh 2470
    self._processMap["validateDoa"] = Processor.process_validateDoa
2616 chandransh 2471
    self._processMap["reshipOrder"] = Processor.process_reshipOrder
2472
    self._processMap["refundOrder"] = Processor.process_refundOrder
2690 chandransh 2473
    self._processMap["getReturnOrders"] = Processor.process_getReturnOrders
2700 chandransh 2474
    self._processMap["getReturnOrder"] = Processor.process_getReturnOrder
2690 chandransh 2475
    self._processMap["processReturn"] = Processor.process_processReturn
2819 chandransh 2476
    self._processMap["createPurchaseOrder"] = Processor.process_createPurchaseOrder
3451 chandransh 2477
    self._processMap["updateWeight"] = Processor.process_updateWeight
94 ashish 2478
 
2479
  def process(self, iprot, oprot):
2480
    (name, type, seqid) = iprot.readMessageBegin()
2481
    if name not in self._processMap:
2482
      iprot.skip(TType.STRUCT)
2483
      iprot.readMessageEnd()
2484
      x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
2485
      oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
2486
      x.write(oprot)
2487
      oprot.writeMessageEnd()
2488
      oprot.trans.flush()
2489
      return
2490
    else:
2491
      self._processMap[name](self, seqid, iprot, oprot)
2492
    return True
2493
 
2494
  def process_createTransaction(self, seqid, iprot, oprot):
2495
    args = createTransaction_args()
2496
    args.read(iprot)
2497
    iprot.readMessageEnd()
2498
    result = createTransaction_result()
2499
    try:
132 ashish 2500
      result.success = self._handler.createTransaction(args.transaction)
94 ashish 2501
    except TransactionServiceException, ex:
2502
      result.ex = ex
2503
    oprot.writeMessageBegin("createTransaction", TMessageType.REPLY, seqid)
2504
    result.write(oprot)
2505
    oprot.writeMessageEnd()
2506
    oprot.trans.flush()
2507
 
2508
  def process_getTransaction(self, seqid, iprot, oprot):
2509
    args = getTransaction_args()
2510
    args.read(iprot)
2511
    iprot.readMessageEnd()
2512
    result = getTransaction_result()
2513
    try:
2514
      result.success = self._handler.getTransaction(args.id)
2515
    except TransactionServiceException, ex:
2516
      result.ex = ex
2517
    oprot.writeMessageBegin("getTransaction", TMessageType.REPLY, seqid)
2518
    result.write(oprot)
2519
    oprot.writeMessageEnd()
2520
    oprot.trans.flush()
2521
 
2522
  def process_getTransactionsForCustomer(self, seqid, iprot, oprot):
2523
    args = getTransactionsForCustomer_args()
2524
    args.read(iprot)
2525
    iprot.readMessageEnd()
2526
    result = getTransactionsForCustomer_result()
2527
    try:
2528
      result.success = self._handler.getTransactionsForCustomer(args.customerId, args.from_date, args.to_date, args.status)
2529
    except TransactionServiceException, ex:
2530
      result.ex = ex
2531
    oprot.writeMessageBegin("getTransactionsForCustomer", TMessageType.REPLY, seqid)
2532
    result.write(oprot)
2533
    oprot.writeMessageEnd()
2534
    oprot.trans.flush()
2535
 
132 ashish 2536
  def process_getTransactionsForShoppingCartId(self, seqid, iprot, oprot):
2537
    args = getTransactionsForShoppingCartId_args()
2538
    args.read(iprot)
2539
    iprot.readMessageEnd()
2540
    result = getTransactionsForShoppingCartId_result()
2541
    try:
2542
      result.success = self._handler.getTransactionsForShoppingCartId(args.shoppingCartId)
2543
    except TransactionServiceException, ex:
2544
      result.ex = ex
2545
    oprot.writeMessageBegin("getTransactionsForShoppingCartId", TMessageType.REPLY, seqid)
2546
    result.write(oprot)
2547
    oprot.writeMessageEnd()
2548
    oprot.trans.flush()
2549
 
94 ashish 2550
  def process_getTransactionStatus(self, seqid, iprot, oprot):
2551
    args = getTransactionStatus_args()
2552
    args.read(iprot)
2553
    iprot.readMessageEnd()
2554
    result = getTransactionStatus_result()
2555
    try:
2556
      result.success = self._handler.getTransactionStatus(args.transactionId)
2557
    except TransactionServiceException, ex:
2558
      result.ex = ex
2559
    oprot.writeMessageBegin("getTransactionStatus", TMessageType.REPLY, seqid)
2560
    result.write(oprot)
2561
    oprot.writeMessageEnd()
2562
    oprot.trans.flush()
2563
 
2564
  def process_changeTransactionStatus(self, seqid, iprot, oprot):
2565
    args = changeTransactionStatus_args()
2566
    args.read(iprot)
2567
    iprot.readMessageEnd()
2568
    result = changeTransactionStatus_result()
2569
    try:
2570
      result.success = self._handler.changeTransactionStatus(args.transactionId, args.status, args.description)
2571
    except TransactionServiceException, ex:
2572
      result.ex = ex
2573
    oprot.writeMessageBegin("changeTransactionStatus", TMessageType.REPLY, seqid)
2574
    result.write(oprot)
2575
    oprot.writeMessageEnd()
2576
    oprot.trans.flush()
2577
 
1398 varun.gupt 2578
  def process_enqueueTransactionInfoEmail(self, seqid, iprot, oprot):
2579
    args = enqueueTransactionInfoEmail_args()
1382 varun.gupt 2580
    args.read(iprot)
2581
    iprot.readMessageEnd()
1398 varun.gupt 2582
    result = enqueueTransactionInfoEmail_result()
1382 varun.gupt 2583
    try:
1398 varun.gupt 2584
      result.success = self._handler.enqueueTransactionInfoEmail(args.transactionId)
1382 varun.gupt 2585
    except TransactionServiceException, ex:
2586
      result.ex = ex
1398 varun.gupt 2587
    oprot.writeMessageBegin("enqueueTransactionInfoEmail", TMessageType.REPLY, seqid)
1382 varun.gupt 2588
    result.write(oprot)
2589
    oprot.writeMessageEnd()
2590
    oprot.trans.flush()
2591
 
483 rajveer 2592
  def process_getAllOrders(self, seqid, iprot, oprot):
2593
    args = getAllOrders_args()
94 ashish 2594
    args.read(iprot)
2595
    iprot.readMessageEnd()
483 rajveer 2596
    result = getAllOrders_result()
94 ashish 2597
    try:
483 rajveer 2598
      result.success = self._handler.getAllOrders(args.status, args.from_date, args.to_date, args.warehouse_id)
94 ashish 2599
    except TransactionServiceException, ex:
2600
      result.ex = ex
483 rajveer 2601
    oprot.writeMessageBegin("getAllOrders", TMessageType.REPLY, seqid)
94 ashish 2602
    result.write(oprot)
2603
    oprot.writeMessageEnd()
2604
    oprot.trans.flush()
2605
 
999 varun.gupt 2606
  def process_getOrdersByBillingDate(self, seqid, iprot, oprot):
2607
    args = getOrdersByBillingDate_args()
2608
    args.read(iprot)
2609
    iprot.readMessageEnd()
2610
    result = getOrdersByBillingDate_result()
2611
    try:
2612
      result.success = self._handler.getOrdersByBillingDate(args.status, args.start_billing_date, args.end_billing_date, args.warehouse_id)
2613
    except TransactionServiceException, ex:
2614
      result.ex = ex
2615
    oprot.writeMessageBegin("getOrdersByBillingDate", TMessageType.REPLY, seqid)
2616
    result.write(oprot)
2617
    oprot.writeMessageEnd()
2618
    oprot.trans.flush()
2619
 
3427 chandransh 2620
  def process_getOrdersByShippingDate(self, seqid, iprot, oprot):
2621
    args = getOrdersByShippingDate_args()
2622
    args.read(iprot)
2623
    iprot.readMessageEnd()
2624
    result = getOrdersByShippingDate_result()
2625
    try:
3451 chandransh 2626
      result.success = self._handler.getOrdersByShippingDate(args.fromShippingDate, args.toShippingDate, args.providerId, args.warehouseId, args.cod)
3427 chandransh 2627
    except TransactionServiceException, ex:
2628
      result.ex = ex
2629
    oprot.writeMessageBegin("getOrdersByShippingDate", TMessageType.REPLY, seqid)
2630
    result.write(oprot)
2631
    oprot.writeMessageEnd()
2632
    oprot.trans.flush()
2633
 
1382 varun.gupt 2634
  def process_getReturnableOrdersForCustomer(self, seqid, iprot, oprot):
2635
    args = getReturnableOrdersForCustomer_args()
2636
    args.read(iprot)
2637
    iprot.readMessageEnd()
2638
    result = getReturnableOrdersForCustomer_result()
2639
    try:
2640
      result.success = self._handler.getReturnableOrdersForCustomer(args.customer_id, args.limit)
2641
    except TransactionServiceException, ex:
2642
      result.ex = ex
2643
    oprot.writeMessageBegin("getReturnableOrdersForCustomer", TMessageType.REPLY, seqid)
2644
    result.write(oprot)
2645
    oprot.writeMessageEnd()
2646
    oprot.trans.flush()
2647
 
2648
  def process_getCancellableOrdersForCustomer(self, seqid, iprot, oprot):
2649
    args = getCancellableOrdersForCustomer_args()
2650
    args.read(iprot)
2651
    iprot.readMessageEnd()
2652
    result = getCancellableOrdersForCustomer_result()
2653
    try:
2654
      result.success = self._handler.getCancellableOrdersForCustomer(args.customer_id, args.limit)
2655
    except TransactionServiceException, ex:
2656
      result.ex = ex
2657
    oprot.writeMessageBegin("getCancellableOrdersForCustomer", TMessageType.REPLY, seqid)
2658
    result.write(oprot)
2659
    oprot.writeMessageEnd()
2660
    oprot.trans.flush()
2661
 
483 rajveer 2662
  def process_changeOrderStatus(self, seqid, iprot, oprot):
2663
    args = changeOrderStatus_args()
94 ashish 2664
    args.read(iprot)
2665
    iprot.readMessageEnd()
483 rajveer 2666
    result = changeOrderStatus_result()
94 ashish 2667
    try:
483 rajveer 2668
      result.success = self._handler.changeOrderStatus(args.orderId, args.status, args.description)
94 ashish 2669
    except TransactionServiceException, ex:
2670
      result.ex = ex
483 rajveer 2671
    oprot.writeMessageBegin("changeOrderStatus", TMessageType.REPLY, seqid)
94 ashish 2672
    result.write(oprot)
2673
    oprot.writeMessageEnd()
2674
    oprot.trans.flush()
2675
 
483 rajveer 2676
  def process_getOrdersForTransaction(self, seqid, iprot, oprot):
2677
    args = getOrdersForTransaction_args()
94 ashish 2678
    args.read(iprot)
2679
    iprot.readMessageEnd()
483 rajveer 2680
    result = getOrdersForTransaction_result()
94 ashish 2681
    try:
1528 ankur.sing 2682
      result.success = self._handler.getOrdersForTransaction(args.transactionId, args.customerId)
94 ashish 2683
    except TransactionServiceException, ex:
2684
      result.ex = ex
483 rajveer 2685
    oprot.writeMessageBegin("getOrdersForTransaction", TMessageType.REPLY, seqid)
94 ashish 2686
    result.write(oprot)
2687
    oprot.writeMessageEnd()
2688
    oprot.trans.flush()
2689
 
483 rajveer 2690
  def process_getOrdersForCustomer(self, seqid, iprot, oprot):
2691
    args = getOrdersForCustomer_args()
94 ashish 2692
    args.read(iprot)
2693
    iprot.readMessageEnd()
483 rajveer 2694
    result = getOrdersForCustomer_result()
94 ashish 2695
    try:
3014 chandransh 2696
      result.success = self._handler.getOrdersForCustomer(args.customerId, args.from_date, args.to_date, args.statuses)
94 ashish 2697
    except TransactionServiceException, ex:
2698
      result.ex = ex
483 rajveer 2699
    oprot.writeMessageBegin("getOrdersForCustomer", TMessageType.REPLY, seqid)
94 ashish 2700
    result.write(oprot)
2701
    oprot.writeMessageEnd()
2702
    oprot.trans.flush()
2703
 
483 rajveer 2704
  def process_createOrder(self, seqid, iprot, oprot):
2705
    args = createOrder_args()
94 ashish 2706
    args.read(iprot)
2707
    iprot.readMessageEnd()
483 rajveer 2708
    result = createOrder_result()
94 ashish 2709
    try:
483 rajveer 2710
      result.success = self._handler.createOrder(args.order)
94 ashish 2711
    except TransactionServiceException, ex:
2712
      result.ex = ex
483 rajveer 2713
    oprot.writeMessageBegin("createOrder", TMessageType.REPLY, seqid)
94 ashish 2714
    result.write(oprot)
2715
    oprot.writeMessageEnd()
2716
    oprot.trans.flush()
2717
 
483 rajveer 2718
  def process_getOrder(self, seqid, iprot, oprot):
2719
    args = getOrder_args()
94 ashish 2720
    args.read(iprot)
2721
    iprot.readMessageEnd()
483 rajveer 2722
    result = getOrder_result()
94 ashish 2723
    try:
483 rajveer 2724
      result.success = self._handler.getOrder(args.id)
94 ashish 2725
    except TransactionServiceException, ex:
2726
      result.ex = ex
483 rajveer 2727
    oprot.writeMessageBegin("getOrder", TMessageType.REPLY, seqid)
94 ashish 2728
    result.write(oprot)
2729
    oprot.writeMessageEnd()
2730
    oprot.trans.flush()
2731
 
483 rajveer 2732
  def process_getLineItemsForOrder(self, seqid, iprot, oprot):
2733
    args = getLineItemsForOrder_args()
94 ashish 2734
    args.read(iprot)
2735
    iprot.readMessageEnd()
483 rajveer 2736
    result = getLineItemsForOrder_result()
94 ashish 2737
    try:
483 rajveer 2738
      result.success = self._handler.getLineItemsForOrder(args.orderId)
94 ashish 2739
    except TransactionServiceException, ex:
2740
      result.ex = ex
483 rajveer 2741
    oprot.writeMessageBegin("getLineItemsForOrder", TMessageType.REPLY, seqid)
94 ashish 2742
    result.write(oprot)
2743
    oprot.writeMessageEnd()
2744
    oprot.trans.flush()
2745
 
1528 ankur.sing 2746
  def process_getOrderForCustomer(self, seqid, iprot, oprot):
2747
    args = getOrderForCustomer_args()
2748
    args.read(iprot)
2749
    iprot.readMessageEnd()
2750
    result = getOrderForCustomer_result()
2751
    try:
2752
      result.success = self._handler.getOrderForCustomer(args.orderId, args.customerId)
2753
    except TransactionServiceException, ex:
2754
      result.ex = ex
2755
    oprot.writeMessageBegin("getOrderForCustomer", TMessageType.REPLY, seqid)
2756
    result.write(oprot)
2757
    oprot.writeMessageEnd()
2758
    oprot.trans.flush()
2759
 
3064 chandransh 2760
  def process_getAlerts(self, seqid, iprot, oprot):
2761
    args = getAlerts_args()
2762
    args.read(iprot)
2763
    iprot.readMessageEnd()
2764
    result = getAlerts_result()
2765
    result.success = self._handler.getAlerts(args.orderId, args.valid)
2766
    oprot.writeMessageBegin("getAlerts", TMessageType.REPLY, seqid)
2767
    result.write(oprot)
2768
    oprot.writeMessageEnd()
2769
    oprot.trans.flush()
2770
 
2771
  def process_setAlert(self, seqid, iprot, oprot):
2772
    args = setAlert_args()
2773
    args.read(iprot)
2774
    iprot.readMessageEnd()
2775
    result = setAlert_result()
2776
    self._handler.setAlert(args.orderId, args.unset, args.type, args.comment)
2777
    oprot.writeMessageBegin("setAlert", TMessageType.REPLY, seqid)
2778
    result.write(oprot)
2779
    oprot.writeMessageEnd()
2780
    oprot.trans.flush()
2781
 
2782
  def process_getValidOrderCount(self, seqid, iprot, oprot):
2783
    args = getValidOrderCount_args()
2784
    args.read(iprot)
2785
    iprot.readMessageEnd()
2786
    result = getValidOrderCount_result()
2787
    result.success = self._handler.getValidOrderCount()
2788
    oprot.writeMessageBegin("getValidOrderCount", TMessageType.REPLY, seqid)
2789
    result.write(oprot)
2790
    oprot.writeMessageEnd()
2791
    oprot.trans.flush()
2792
 
2793
  def process_getNoOfCustomersWithSuccessfulTransaction(self, seqid, iprot, oprot):
2794
    args = getNoOfCustomersWithSuccessfulTransaction_args()
2795
    args.read(iprot)
2796
    iprot.readMessageEnd()
2797
    result = getNoOfCustomersWithSuccessfulTransaction_result()
2798
    result.success = self._handler.getNoOfCustomersWithSuccessfulTransaction()
2799
    oprot.writeMessageBegin("getNoOfCustomersWithSuccessfulTransaction", TMessageType.REPLY, seqid)
2800
    result.write(oprot)
2801
    oprot.writeMessageEnd()
2802
    oprot.trans.flush()
2803
 
2804
  def process_getValidOrdersAmountRange(self, seqid, iprot, oprot):
2805
    args = getValidOrdersAmountRange_args()
2806
    args.read(iprot)
2807
    iprot.readMessageEnd()
2808
    result = getValidOrdersAmountRange_result()
2809
    result.success = self._handler.getValidOrdersAmountRange()
2810
    oprot.writeMessageBegin("getValidOrdersAmountRange", TMessageType.REPLY, seqid)
2811
    result.write(oprot)
2812
    oprot.writeMessageEnd()
2813
    oprot.trans.flush()
2814
 
2815
  def process_getValidOrders(self, seqid, iprot, oprot):
2816
    args = getValidOrders_args()
2817
    args.read(iprot)
2818
    iprot.readMessageEnd()
2819
    result = getValidOrders_result()
2820
    result.success = self._handler.getValidOrders(args.limit)
2821
    oprot.writeMessageBegin("getValidOrders", TMessageType.REPLY, seqid)
2822
    result.write(oprot)
2823
    oprot.writeMessageEnd()
2824
    oprot.trans.flush()
2825
 
1220 chandransh 2826
  def process_batchOrders(self, seqid, iprot, oprot):
2827
    args = batchOrders_args()
2828
    args.read(iprot)
2829
    iprot.readMessageEnd()
2830
    result = batchOrders_result()
2831
    try:
2832
      result.success = self._handler.batchOrders(args.warehouseId)
2833
    except TransactionServiceException, ex:
2834
      result.ex = ex
2835
    oprot.writeMessageBegin("batchOrders", TMessageType.REPLY, seqid)
2836
    result.write(oprot)
2837
    oprot.writeMessageEnd()
2838
    oprot.trans.flush()
2839
 
1208 chandransh 2840
  def process_markOrderAsOutOfStock(self, seqid, iprot, oprot):
2841
    args = markOrderAsOutOfStock_args()
2842
    args.read(iprot)
2843
    iprot.readMessageEnd()
2844
    result = markOrderAsOutOfStock_result()
2845
    try:
2846
      result.success = self._handler.markOrderAsOutOfStock(args.orderId)
2847
    except TransactionServiceException, ex:
2848
      result.ex = ex
2849
    oprot.writeMessageBegin("markOrderAsOutOfStock", TMessageType.REPLY, seqid)
2850
    result.write(oprot)
2851
    oprot.writeMessageEnd()
2852
    oprot.trans.flush()
2853
 
3064 chandransh 2854
  def process_verifyOrder(self, seqid, iprot, oprot):
2855
    args = verifyOrder_args()
759 chandransh 2856
    args.read(iprot)
2857
    iprot.readMessageEnd()
3064 chandransh 2858
    result = verifyOrder_result()
759 chandransh 2859
    try:
3064 chandransh 2860
      result.success = self._handler.verifyOrder(args.orderId)
759 chandransh 2861
    except TransactionServiceException, ex:
2862
      result.ex = ex
3064 chandransh 2863
    oprot.writeMessageBegin("verifyOrder", TMessageType.REPLY, seqid)
759 chandransh 2864
    result.write(oprot)
2865
    oprot.writeMessageEnd()
2866
    oprot.trans.flush()
2867
 
3064 chandransh 2868
  def process_acceptOrder(self, seqid, iprot, oprot):
2869
    args = acceptOrder_args()
1113 chandransh 2870
    args.read(iprot)
2871
    iprot.readMessageEnd()
3064 chandransh 2872
    result = acceptOrder_result()
1113 chandransh 2873
    try:
3064 chandransh 2874
      result.success = self._handler.acceptOrder(args.orderId)
1113 chandransh 2875
    except TransactionServiceException, ex:
2876
      result.ex = ex
3064 chandransh 2877
    oprot.writeMessageBegin("acceptOrder", TMessageType.REPLY, seqid)
1113 chandransh 2878
    result.write(oprot)
2879
    oprot.writeMessageEnd()
2880
    oprot.trans.flush()
2881
 
3064 chandransh 2882
  def process_billOrder(self, seqid, iprot, oprot):
2883
    args = billOrder_args()
1132 chandransh 2884
    args.read(iprot)
2885
    iprot.readMessageEnd()
3064 chandransh 2886
    result = billOrder_result()
1132 chandransh 2887
    try:
3064 chandransh 2888
      result.success = self._handler.billOrder(args.orderId)
1132 chandransh 2889
    except TransactionServiceException, ex:
2890
      result.ex = ex
3064 chandransh 2891
    oprot.writeMessageBegin("billOrder", TMessageType.REPLY, seqid)
1132 chandransh 2892
    result.write(oprot)
2893
    oprot.writeMessageEnd()
2894
    oprot.trans.flush()
2895
 
3064 chandransh 2896
  def process_addBillingDetails(self, seqid, iprot, oprot):
2897
    args = addBillingDetails_args()
1135 chandransh 2898
    args.read(iprot)
2899
    iprot.readMessageEnd()
3064 chandransh 2900
    result = addBillingDetails_result()
1135 chandransh 2901
    try:
3064 chandransh 2902
      result.success = self._handler.addBillingDetails(args.orderId, args.invoice_number, args.billed_by)
1135 chandransh 2903
    except TransactionServiceException, ex:
2904
      result.ex = ex
3064 chandransh 2905
    oprot.writeMessageBegin("addBillingDetails", TMessageType.REPLY, seqid)
1135 chandransh 2906
    result.write(oprot)
2907
    oprot.writeMessageEnd()
2908
    oprot.trans.flush()
2909
 
3064 chandransh 2910
  def process_addJacketNumber(self, seqid, iprot, oprot):
2911
    args = addJacketNumber_args()
1246 chandransh 2912
    args.read(iprot)
2913
    iprot.readMessageEnd()
3064 chandransh 2914
    result = addJacketNumber_result()
1246 chandransh 2915
    try:
3064 chandransh 2916
      result.success = self._handler.addJacketNumber(args.orderId, args.jacketNumber, args.imeiNumber, args.itemNumber, args.billedBy, args.billingType)
1246 chandransh 2917
    except TransactionServiceException, ex:
2918
      result.ex = ex
3064 chandransh 2919
    oprot.writeMessageBegin("addJacketNumber", TMessageType.REPLY, seqid)
1246 chandransh 2920
    result.write(oprot)
2921
    oprot.writeMessageEnd()
2922
    oprot.trans.flush()
2923
 
3064 chandransh 2924
  def process_markOrdersAsManifested(self, seqid, iprot, oprot):
2925
    args = markOrdersAsManifested_args()
1408 ankur.sing 2926
    args.read(iprot)
2927
    iprot.readMessageEnd()
3064 chandransh 2928
    result = markOrdersAsManifested_result()
2929
    try:
2930
      result.success = self._handler.markOrdersAsManifested(args.warehouseId, args.providerId, args.cod)
2931
    except TransactionServiceException, ex:
2932
      result.ex = ex
2933
    oprot.writeMessageBegin("markOrdersAsManifested", TMessageType.REPLY, seqid)
1408 ankur.sing 2934
    result.write(oprot)
2935
    oprot.writeMessageEnd()
2936
    oprot.trans.flush()
2937
 
3064 chandransh 2938
  def process_markOrdersAsPickedUp(self, seqid, iprot, oprot):
2939
    args = markOrdersAsPickedUp_args()
304 ashish 2940
    args.read(iprot)
2941
    iprot.readMessageEnd()
3064 chandransh 2942
    result = markOrdersAsPickedUp_result()
2943
    try:
2944
      result.success = self._handler.markOrdersAsPickedUp(args.providerId, args.pickupDetails)
2945
    except TransactionServiceException, ex:
2946
      result.ex = ex
2947
    oprot.writeMessageBegin("markOrdersAsPickedUp", TMessageType.REPLY, seqid)
304 ashish 2948
    result.write(oprot)
2949
    oprot.writeMessageEnd()
2950
    oprot.trans.flush()
94 ashish 2951
 
3064 chandransh 2952
  def process_markOrdersAsDelivered(self, seqid, iprot, oprot):
2953
    args = markOrdersAsDelivered_args()
304 ashish 2954
    args.read(iprot)
2955
    iprot.readMessageEnd()
3064 chandransh 2956
    result = markOrdersAsDelivered_result()
2957
    try:
2958
      self._handler.markOrdersAsDelivered(args.providerId, args.deliveredOrders)
2959
    except TransactionServiceException, ex:
2960
      result.ex = ex
2961
    oprot.writeMessageBegin("markOrdersAsDelivered", TMessageType.REPLY, seqid)
304 ashish 2962
    result.write(oprot)
2963
    oprot.writeMessageEnd()
2964
    oprot.trans.flush()
2965
 
3064 chandransh 2966
  def process_markOrdersAsFailed(self, seqid, iprot, oprot):
2967
    args = markOrdersAsFailed_args()
1596 ankur.sing 2968
    args.read(iprot)
2969
    iprot.readMessageEnd()
3064 chandransh 2970
    result = markOrdersAsFailed_result()
2971
    try:
2972
      self._handler.markOrdersAsFailed(args.providerId, args.returnedOrders)
2973
    except TransactionServiceException, ex:
2974
      result.ex = ex
2975
    oprot.writeMessageBegin("markOrdersAsFailed", TMessageType.REPLY, seqid)
1596 ankur.sing 2976
    result.write(oprot)
2977
    oprot.writeMessageEnd()
2978
    oprot.trans.flush()
304 ashish 2979
 
3064 chandransh 2980
  def process_updateNonDeliveryReason(self, seqid, iprot, oprot):
2981
    args = updateNonDeliveryReason_args()
1627 ankur.sing 2982
    args.read(iprot)
2983
    iprot.readMessageEnd()
3064 chandransh 2984
    result = updateNonDeliveryReason_result()
2985
    try:
2986
      self._handler.updateNonDeliveryReason(args.providerId, args.undeliveredOrders)
2987
    except TransactionServiceException, ex:
2988
      result.ex = ex
2989
    oprot.writeMessageBegin("updateNonDeliveryReason", TMessageType.REPLY, seqid)
1627 ankur.sing 2990
    result.write(oprot)
2991
    oprot.writeMessageEnd()
2992
    oprot.trans.flush()
1596 ankur.sing 2993
 
3064 chandransh 2994
  def process_getUndeliveredOrders(self, seqid, iprot, oprot):
2995
    args = getUndeliveredOrders_args()
1627 ankur.sing 2996
    args.read(iprot)
2997
    iprot.readMessageEnd()
3064 chandransh 2998
    result = getUndeliveredOrders_result()
2999
    result.success = self._handler.getUndeliveredOrders(args.providerId, args.warehouseId)
3000
    oprot.writeMessageBegin("getUndeliveredOrders", TMessageType.REPLY, seqid)
1627 ankur.sing 3001
    result.write(oprot)
3002
    oprot.writeMessageEnd()
3003
    oprot.trans.flush()
3004
 
2536 chandransh 3005
  def process_toggleDOAFlag(self, seqid, iprot, oprot):
3006
    args = toggleDOAFlag_args()
3007
    args.read(iprot)
3008
    iprot.readMessageEnd()
3009
    result = toggleDOAFlag_result()
3010
    try:
3011
      result.success = self._handler.toggleDOAFlag(args.orderId)
3012
    except TransactionServiceException, ex:
3013
      result.ex = ex
3014
    oprot.writeMessageBegin("toggleDOAFlag", TMessageType.REPLY, seqid)
3015
    result.write(oprot)
3016
    oprot.writeMessageEnd()
3017
    oprot.trans.flush()
1886 ankur.sing 3018
 
2536 chandransh 3019
  def process_requestPickupNumber(self, seqid, iprot, oprot):
3020
    args = requestPickupNumber_args()
3021
    args.read(iprot)
3022
    iprot.readMessageEnd()
3023
    result = requestPickupNumber_result()
3024
    try:
3025
      result.success = self._handler.requestPickupNumber(args.orderId)
3026
    except TransactionServiceException, ex:
3027
      result.ex = ex
3028
    oprot.writeMessageBegin("requestPickupNumber", TMessageType.REPLY, seqid)
3029
    result.write(oprot)
3030
    oprot.writeMessageEnd()
3031
    oprot.trans.flush()
3032
 
3033
  def process_authorizePickup(self, seqid, iprot, oprot):
3034
    args = authorizePickup_args()
3035
    args.read(iprot)
3036
    iprot.readMessageEnd()
3037
    result = authorizePickup_result()
3038
    try:
3039
      result.success = self._handler.authorizePickup(args.orderId, args.pickupNumber)
3040
    except TransactionServiceException, ex:
3041
      result.ex = ex
3042
    oprot.writeMessageBegin("authorizePickup", TMessageType.REPLY, seqid)
3043
    result.write(oprot)
3044
    oprot.writeMessageEnd()
3045
    oprot.trans.flush()
3046
 
2764 chandransh 3047
  def process_markDoasAsPickedUp(self, seqid, iprot, oprot):
3048
    args = markDoasAsPickedUp_args()
3049
    args.read(iprot)
3050
    iprot.readMessageEnd()
3051
    result = markDoasAsPickedUp_result()
3052
    result.success = self._handler.markDoasAsPickedUp(args.providerId, args.pickupDetails)
3053
    oprot.writeMessageBegin("markDoasAsPickedUp", TMessageType.REPLY, seqid)
3054
    result.write(oprot)
3055
    oprot.writeMessageEnd()
3056
    oprot.trans.flush()
3057
 
2616 chandransh 3058
  def process_receiveReturn(self, seqid, iprot, oprot):
3059
    args = receiveReturn_args()
2591 chandransh 3060
    args.read(iprot)
3061
    iprot.readMessageEnd()
2616 chandransh 3062
    result = receiveReturn_result()
2591 chandransh 3063
    try:
2616 chandransh 3064
      result.success = self._handler.receiveReturn(args.orderId)
2591 chandransh 3065
    except TransactionServiceException, ex:
3066
      result.ex = ex
2616 chandransh 3067
    oprot.writeMessageBegin("receiveReturn", TMessageType.REPLY, seqid)
2591 chandransh 3068
    result.write(oprot)
3069
    oprot.writeMessageEnd()
3070
    oprot.trans.flush()
2536 chandransh 3071
 
2591 chandransh 3072
  def process_validateDoa(self, seqid, iprot, oprot):
3073
    args = validateDoa_args()
3074
    args.read(iprot)
3075
    iprot.readMessageEnd()
3076
    result = validateDoa_result()
3077
    try:
3078
      result.success = self._handler.validateDoa(args.orderId, args.isValid)
3079
    except TransactionServiceException, ex:
3080
      result.ex = ex
3081
    oprot.writeMessageBegin("validateDoa", TMessageType.REPLY, seqid)
3082
    result.write(oprot)
3083
    oprot.writeMessageEnd()
3084
    oprot.trans.flush()
3085
 
2616 chandransh 3086
  def process_reshipOrder(self, seqid, iprot, oprot):
3087
    args = reshipOrder_args()
3088
    args.read(iprot)
3089
    iprot.readMessageEnd()
3090
    result = reshipOrder_result()
3091
    try:
3092
      result.success = self._handler.reshipOrder(args.orderId)
3093
    except TransactionServiceException, ex:
3094
      result.ex = ex
3095
    oprot.writeMessageBegin("reshipOrder", TMessageType.REPLY, seqid)
3096
    result.write(oprot)
3097
    oprot.writeMessageEnd()
3098
    oprot.trans.flush()
2591 chandransh 3099
 
2616 chandransh 3100
  def process_refundOrder(self, seqid, iprot, oprot):
3101
    args = refundOrder_args()
3102
    args.read(iprot)
3103
    iprot.readMessageEnd()
3104
    result = refundOrder_result()
3105
    try:
3226 chandransh 3106
      result.success = self._handler.refundOrder(args.orderId, args.refundedBy, args.reason)
2616 chandransh 3107
    except TransactionServiceException, ex:
3108
      result.ex = ex
3109
    oprot.writeMessageBegin("refundOrder", TMessageType.REPLY, seqid)
3110
    result.write(oprot)
3111
    oprot.writeMessageEnd()
3112
    oprot.trans.flush()
3113
 
2690 chandransh 3114
  def process_getReturnOrders(self, seqid, iprot, oprot):
3115
    args = getReturnOrders_args()
3116
    args.read(iprot)
3117
    iprot.readMessageEnd()
3118
    result = getReturnOrders_result()
3119
    result.success = self._handler.getReturnOrders(args.warehouseId, args.fromDate, args.toDate)
3120
    oprot.writeMessageBegin("getReturnOrders", TMessageType.REPLY, seqid)
3121
    result.write(oprot)
3122
    oprot.writeMessageEnd()
3123
    oprot.trans.flush()
2616 chandransh 3124
 
2700 chandransh 3125
  def process_getReturnOrder(self, seqid, iprot, oprot):
3126
    args = getReturnOrder_args()
3127
    args.read(iprot)
3128
    iprot.readMessageEnd()
3129
    result = getReturnOrder_result()
3130
    try:
3131
      result.success = self._handler.getReturnOrder(args.id)
3132
    except TransactionServiceException, ex:
3133
      result.ex = ex
3134
    oprot.writeMessageBegin("getReturnOrder", TMessageType.REPLY, seqid)
3135
    result.write(oprot)
3136
    oprot.writeMessageEnd()
3137
    oprot.trans.flush()
3138
 
2690 chandransh 3139
  def process_processReturn(self, seqid, iprot, oprot):
3140
    args = processReturn_args()
3141
    args.read(iprot)
3142
    iprot.readMessageEnd()
3143
    result = processReturn_result()
3144
    try:
3145
      self._handler.processReturn(args.returnOrderId)
3146
    except TransactionServiceException, ex:
3147
      result.ex = ex
3148
    oprot.writeMessageBegin("processReturn", TMessageType.REPLY, seqid)
3149
    result.write(oprot)
3150
    oprot.writeMessageEnd()
3151
    oprot.trans.flush()
3152
 
2819 chandransh 3153
  def process_createPurchaseOrder(self, seqid, iprot, oprot):
3154
    args = createPurchaseOrder_args()
3155
    args.read(iprot)
3156
    iprot.readMessageEnd()
3157
    result = createPurchaseOrder_result()
3158
    try:
3159
      result.success = self._handler.createPurchaseOrder(args.warehouseId)
3160
    except TransactionServiceException, ex:
3161
      result.ex = ex
3162
    oprot.writeMessageBegin("createPurchaseOrder", TMessageType.REPLY, seqid)
3163
    result.write(oprot)
3164
    oprot.writeMessageEnd()
3165
    oprot.trans.flush()
2690 chandransh 3166
 
3451 chandransh 3167
  def process_updateWeight(self, seqid, iprot, oprot):
3168
    args = updateWeight_args()
3169
    args.read(iprot)
3170
    iprot.readMessageEnd()
3171
    result = updateWeight_result()
3172
    try:
3173
      result.success = self._handler.updateWeight(args.orderId, args.weight)
3174
    except TransactionServiceException, ex:
3175
      result.ex = ex
3176
    oprot.writeMessageBegin("updateWeight", TMessageType.REPLY, seqid)
3177
    result.write(oprot)
3178
    oprot.writeMessageEnd()
3179
    oprot.trans.flush()
2819 chandransh 3180
 
3451 chandransh 3181
 
94 ashish 3182
# HELPER FUNCTIONS AND STRUCTURES
3183
 
3184
class createTransaction_args:
3185
  """
3186
  Attributes:
3187
   - transaction
3188
  """
3189
 
3190
  thrift_spec = (
3191
    None, # 0
3192
    (1, TType.STRUCT, 'transaction', (Transaction, Transaction.thrift_spec), None, ), # 1
3193
  )
3194
 
3195
  def __init__(self, transaction=None,):
3196
    self.transaction = transaction
3197
 
3198
  def read(self, iprot):
3199
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3200
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3201
      return
3202
    iprot.readStructBegin()
3203
    while True:
3204
      (fname, ftype, fid) = iprot.readFieldBegin()
3205
      if ftype == TType.STOP:
3206
        break
3207
      if fid == 1:
3208
        if ftype == TType.STRUCT:
3209
          self.transaction = Transaction()
3210
          self.transaction.read(iprot)
3211
        else:
3212
          iprot.skip(ftype)
3213
      else:
3214
        iprot.skip(ftype)
3215
      iprot.readFieldEnd()
3216
    iprot.readStructEnd()
3217
 
3218
  def write(self, oprot):
3219
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3220
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3221
      return
3222
    oprot.writeStructBegin('createTransaction_args')
3431 rajveer 3223
    if self.transaction is not None:
94 ashish 3224
      oprot.writeFieldBegin('transaction', TType.STRUCT, 1)
3225
      self.transaction.write(oprot)
3226
      oprot.writeFieldEnd()
3227
    oprot.writeFieldStop()
3228
    oprot.writeStructEnd()
3229
 
3431 rajveer 3230
  def validate(self):
3231
    return
3232
 
3233
 
94 ashish 3234
  def __repr__(self):
3235
    L = ['%s=%r' % (key, value)
3236
      for key, value in self.__dict__.iteritems()]
3237
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3238
 
3239
  def __eq__(self, other):
3240
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3241
 
3242
  def __ne__(self, other):
3243
    return not (self == other)
3244
 
3245
class createTransaction_result:
3246
  """
3247
  Attributes:
132 ashish 3248
   - success
94 ashish 3249
   - ex
3250
  """
3251
 
3252
  thrift_spec = (
132 ashish 3253
    (0, TType.I64, 'success', None, None, ), # 0
94 ashish 3254
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3255
  )
3256
 
132 ashish 3257
  def __init__(self, success=None, ex=None,):
3258
    self.success = success
94 ashish 3259
    self.ex = ex
3260
 
3261
  def read(self, iprot):
3262
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3263
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3264
      return
3265
    iprot.readStructBegin()
3266
    while True:
3267
      (fname, ftype, fid) = iprot.readFieldBegin()
3268
      if ftype == TType.STOP:
3269
        break
132 ashish 3270
      if fid == 0:
3271
        if ftype == TType.I64:
3272
          self.success = iprot.readI64();
3273
        else:
3274
          iprot.skip(ftype)
3275
      elif fid == 1:
94 ashish 3276
        if ftype == TType.STRUCT:
3277
          self.ex = TransactionServiceException()
3278
          self.ex.read(iprot)
3279
        else:
3280
          iprot.skip(ftype)
3281
      else:
3282
        iprot.skip(ftype)
3283
      iprot.readFieldEnd()
3284
    iprot.readStructEnd()
3285
 
3286
  def write(self, oprot):
3287
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3288
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3289
      return
3290
    oprot.writeStructBegin('createTransaction_result')
3431 rajveer 3291
    if self.success is not None:
132 ashish 3292
      oprot.writeFieldBegin('success', TType.I64, 0)
3293
      oprot.writeI64(self.success)
3294
      oprot.writeFieldEnd()
3431 rajveer 3295
    if self.ex is not None:
94 ashish 3296
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3297
      self.ex.write(oprot)
3298
      oprot.writeFieldEnd()
3299
    oprot.writeFieldStop()
3300
    oprot.writeStructEnd()
3301
 
3431 rajveer 3302
  def validate(self):
3303
    return
3304
 
3305
 
94 ashish 3306
  def __repr__(self):
3307
    L = ['%s=%r' % (key, value)
3308
      for key, value in self.__dict__.iteritems()]
3309
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3310
 
3311
  def __eq__(self, other):
3312
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3313
 
3314
  def __ne__(self, other):
3315
    return not (self == other)
3316
 
3317
class getTransaction_args:
3318
  """
3319
  Attributes:
3320
   - id
3321
  """
3322
 
3323
  thrift_spec = (
3324
    None, # 0
3325
    (1, TType.I64, 'id', None, None, ), # 1
3326
  )
3327
 
3328
  def __init__(self, id=None,):
3329
    self.id = id
3330
 
3331
  def read(self, iprot):
3332
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3333
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3334
      return
3335
    iprot.readStructBegin()
3336
    while True:
3337
      (fname, ftype, fid) = iprot.readFieldBegin()
3338
      if ftype == TType.STOP:
3339
        break
3340
      if fid == 1:
3341
        if ftype == TType.I64:
3342
          self.id = iprot.readI64();
3343
        else:
3344
          iprot.skip(ftype)
3345
      else:
3346
        iprot.skip(ftype)
3347
      iprot.readFieldEnd()
3348
    iprot.readStructEnd()
3349
 
3350
  def write(self, oprot):
3351
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3352
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3353
      return
3354
    oprot.writeStructBegin('getTransaction_args')
3431 rajveer 3355
    if self.id is not None:
94 ashish 3356
      oprot.writeFieldBegin('id', TType.I64, 1)
3357
      oprot.writeI64(self.id)
3358
      oprot.writeFieldEnd()
3359
    oprot.writeFieldStop()
3360
    oprot.writeStructEnd()
3361
 
3431 rajveer 3362
  def validate(self):
3363
    return
3364
 
3365
 
94 ashish 3366
  def __repr__(self):
3367
    L = ['%s=%r' % (key, value)
3368
      for key, value in self.__dict__.iteritems()]
3369
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3370
 
3371
  def __eq__(self, other):
3372
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3373
 
3374
  def __ne__(self, other):
3375
    return not (self == other)
3376
 
3377
class getTransaction_result:
3378
  """
3379
  Attributes:
3380
   - success
3381
   - ex
3382
  """
3383
 
3384
  thrift_spec = (
3385
    (0, TType.STRUCT, 'success', (Transaction, Transaction.thrift_spec), None, ), # 0
3386
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3387
  )
3388
 
3389
  def __init__(self, success=None, ex=None,):
3390
    self.success = success
3391
    self.ex = ex
3392
 
3393
  def read(self, iprot):
3394
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3395
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3396
      return
3397
    iprot.readStructBegin()
3398
    while True:
3399
      (fname, ftype, fid) = iprot.readFieldBegin()
3400
      if ftype == TType.STOP:
3401
        break
3402
      if fid == 0:
3403
        if ftype == TType.STRUCT:
3404
          self.success = Transaction()
3405
          self.success.read(iprot)
3406
        else:
3407
          iprot.skip(ftype)
3408
      elif fid == 1:
3409
        if ftype == TType.STRUCT:
3410
          self.ex = TransactionServiceException()
3411
          self.ex.read(iprot)
3412
        else:
3413
          iprot.skip(ftype)
3414
      else:
3415
        iprot.skip(ftype)
3416
      iprot.readFieldEnd()
3417
    iprot.readStructEnd()
3418
 
3419
  def write(self, oprot):
3420
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3421
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3422
      return
3423
    oprot.writeStructBegin('getTransaction_result')
3431 rajveer 3424
    if self.success is not None:
94 ashish 3425
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
3426
      self.success.write(oprot)
3427
      oprot.writeFieldEnd()
3431 rajveer 3428
    if self.ex is not None:
94 ashish 3429
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3430
      self.ex.write(oprot)
3431
      oprot.writeFieldEnd()
3432
    oprot.writeFieldStop()
3433
    oprot.writeStructEnd()
3434
 
3431 rajveer 3435
  def validate(self):
3436
    return
3437
 
3438
 
94 ashish 3439
  def __repr__(self):
3440
    L = ['%s=%r' % (key, value)
3441
      for key, value in self.__dict__.iteritems()]
3442
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3443
 
3444
  def __eq__(self, other):
3445
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3446
 
3447
  def __ne__(self, other):
3448
    return not (self == other)
3449
 
3450
class getTransactionsForCustomer_args:
3451
  """
3452
  Attributes:
3453
   - customerId
3454
   - from_date
3455
   - to_date
3456
   - status
3457
  """
3458
 
3459
  thrift_spec = (
3460
    None, # 0
3461
    (1, TType.I64, 'customerId', None, None, ), # 1
3462
    (2, TType.I64, 'from_date', None, None, ), # 2
3463
    (3, TType.I64, 'to_date', None, None, ), # 3
3464
    (4, TType.I32, 'status', None, None, ), # 4
3465
  )
3466
 
3467
  def __init__(self, customerId=None, from_date=None, to_date=None, status=None,):
3468
    self.customerId = customerId
3469
    self.from_date = from_date
3470
    self.to_date = to_date
3471
    self.status = status
3472
 
3473
  def read(self, iprot):
3474
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3475
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3476
      return
3477
    iprot.readStructBegin()
3478
    while True:
3479
      (fname, ftype, fid) = iprot.readFieldBegin()
3480
      if ftype == TType.STOP:
3481
        break
3482
      if fid == 1:
3483
        if ftype == TType.I64:
3484
          self.customerId = iprot.readI64();
3485
        else:
3486
          iprot.skip(ftype)
3487
      elif fid == 2:
3488
        if ftype == TType.I64:
3489
          self.from_date = iprot.readI64();
3490
        else:
3491
          iprot.skip(ftype)
3492
      elif fid == 3:
3493
        if ftype == TType.I64:
3494
          self.to_date = iprot.readI64();
3495
        else:
3496
          iprot.skip(ftype)
3497
      elif fid == 4:
3498
        if ftype == TType.I32:
3499
          self.status = iprot.readI32();
3500
        else:
3501
          iprot.skip(ftype)
3502
      else:
3503
        iprot.skip(ftype)
3504
      iprot.readFieldEnd()
3505
    iprot.readStructEnd()
3506
 
3507
  def write(self, oprot):
3508
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3509
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3510
      return
3511
    oprot.writeStructBegin('getTransactionsForCustomer_args')
3431 rajveer 3512
    if self.customerId is not None:
94 ashish 3513
      oprot.writeFieldBegin('customerId', TType.I64, 1)
3514
      oprot.writeI64(self.customerId)
3515
      oprot.writeFieldEnd()
3431 rajveer 3516
    if self.from_date is not None:
94 ashish 3517
      oprot.writeFieldBegin('from_date', TType.I64, 2)
3518
      oprot.writeI64(self.from_date)
3519
      oprot.writeFieldEnd()
3431 rajveer 3520
    if self.to_date is not None:
94 ashish 3521
      oprot.writeFieldBegin('to_date', TType.I64, 3)
3522
      oprot.writeI64(self.to_date)
3523
      oprot.writeFieldEnd()
3431 rajveer 3524
    if self.status is not None:
94 ashish 3525
      oprot.writeFieldBegin('status', TType.I32, 4)
3526
      oprot.writeI32(self.status)
3527
      oprot.writeFieldEnd()
3528
    oprot.writeFieldStop()
3529
    oprot.writeStructEnd()
3530
 
3431 rajveer 3531
  def validate(self):
3532
    return
3533
 
3534
 
94 ashish 3535
  def __repr__(self):
3536
    L = ['%s=%r' % (key, value)
3537
      for key, value in self.__dict__.iteritems()]
3538
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3539
 
3540
  def __eq__(self, other):
3541
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3542
 
3543
  def __ne__(self, other):
3544
    return not (self == other)
3545
 
3546
class getTransactionsForCustomer_result:
3547
  """
3548
  Attributes:
3549
   - success
3550
   - ex
3551
  """
3552
 
3553
  thrift_spec = (
3554
    (0, TType.LIST, 'success', (TType.STRUCT,(Transaction, Transaction.thrift_spec)), None, ), # 0
3555
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3556
  )
3557
 
3558
  def __init__(self, success=None, ex=None,):
3559
    self.success = success
3560
    self.ex = ex
3561
 
3562
  def read(self, iprot):
3563
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3564
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3565
      return
3566
    iprot.readStructBegin()
3567
    while True:
3568
      (fname, ftype, fid) = iprot.readFieldBegin()
3569
      if ftype == TType.STOP:
3570
        break
3571
      if fid == 0:
3572
        if ftype == TType.LIST:
3573
          self.success = []
685 chandransh 3574
          (_etype17, _size14) = iprot.readListBegin()
3575
          for _i18 in xrange(_size14):
3576
            _elem19 = Transaction()
3577
            _elem19.read(iprot)
3578
            self.success.append(_elem19)
94 ashish 3579
          iprot.readListEnd()
3580
        else:
3581
          iprot.skip(ftype)
3582
      elif fid == 1:
3583
        if ftype == TType.STRUCT:
3584
          self.ex = TransactionServiceException()
3585
          self.ex.read(iprot)
3586
        else:
3587
          iprot.skip(ftype)
3588
      else:
3589
        iprot.skip(ftype)
3590
      iprot.readFieldEnd()
3591
    iprot.readStructEnd()
3592
 
3593
  def write(self, oprot):
3594
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3595
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3596
      return
3597
    oprot.writeStructBegin('getTransactionsForCustomer_result')
3431 rajveer 3598
    if self.success is not None:
94 ashish 3599
      oprot.writeFieldBegin('success', TType.LIST, 0)
3600
      oprot.writeListBegin(TType.STRUCT, len(self.success))
685 chandransh 3601
      for iter20 in self.success:
3602
        iter20.write(oprot)
94 ashish 3603
      oprot.writeListEnd()
3604
      oprot.writeFieldEnd()
3431 rajveer 3605
    if self.ex is not None:
94 ashish 3606
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3607
      self.ex.write(oprot)
3608
      oprot.writeFieldEnd()
3609
    oprot.writeFieldStop()
3610
    oprot.writeStructEnd()
3611
 
3431 rajveer 3612
  def validate(self):
3613
    return
3614
 
3615
 
94 ashish 3616
  def __repr__(self):
3617
    L = ['%s=%r' % (key, value)
3618
      for key, value in self.__dict__.iteritems()]
3619
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3620
 
3621
  def __eq__(self, other):
3622
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3623
 
3624
  def __ne__(self, other):
3625
    return not (self == other)
3626
 
132 ashish 3627
class getTransactionsForShoppingCartId_args:
3628
  """
3629
  Attributes:
3630
   - shoppingCartId
3631
  """
3632
 
3633
  thrift_spec = (
3634
    None, # 0
3635
    (1, TType.I64, 'shoppingCartId', None, None, ), # 1
3636
  )
3637
 
3638
  def __init__(self, shoppingCartId=None,):
3639
    self.shoppingCartId = shoppingCartId
3640
 
3641
  def read(self, iprot):
3642
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3643
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3644
      return
3645
    iprot.readStructBegin()
3646
    while True:
3647
      (fname, ftype, fid) = iprot.readFieldBegin()
3648
      if ftype == TType.STOP:
3649
        break
3650
      if fid == 1:
3651
        if ftype == TType.I64:
3652
          self.shoppingCartId = iprot.readI64();
3653
        else:
3654
          iprot.skip(ftype)
3655
      else:
3656
        iprot.skip(ftype)
3657
      iprot.readFieldEnd()
3658
    iprot.readStructEnd()
3659
 
3660
  def write(self, oprot):
3661
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3662
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3663
      return
3664
    oprot.writeStructBegin('getTransactionsForShoppingCartId_args')
3431 rajveer 3665
    if self.shoppingCartId is not None:
132 ashish 3666
      oprot.writeFieldBegin('shoppingCartId', TType.I64, 1)
3667
      oprot.writeI64(self.shoppingCartId)
3668
      oprot.writeFieldEnd()
3669
    oprot.writeFieldStop()
3670
    oprot.writeStructEnd()
3671
 
3431 rajveer 3672
  def validate(self):
3673
    return
3674
 
3675
 
132 ashish 3676
  def __repr__(self):
3677
    L = ['%s=%r' % (key, value)
3678
      for key, value in self.__dict__.iteritems()]
3679
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3680
 
3681
  def __eq__(self, other):
3682
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3683
 
3684
  def __ne__(self, other):
3685
    return not (self == other)
3686
 
3687
class getTransactionsForShoppingCartId_result:
3688
  """
3689
  Attributes:
3690
   - success
3691
   - ex
3692
  """
3693
 
3694
  thrift_spec = (
3695
    (0, TType.LIST, 'success', (TType.STRUCT,(Transaction, Transaction.thrift_spec)), None, ), # 0
3696
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3697
  )
3698
 
3699
  def __init__(self, success=None, ex=None,):
3700
    self.success = success
3701
    self.ex = ex
3702
 
3703
  def read(self, iprot):
3704
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3705
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3706
      return
3707
    iprot.readStructBegin()
3708
    while True:
3709
      (fname, ftype, fid) = iprot.readFieldBegin()
3710
      if ftype == TType.STOP:
3711
        break
3712
      if fid == 0:
3713
        if ftype == TType.LIST:
3714
          self.success = []
685 chandransh 3715
          (_etype24, _size21) = iprot.readListBegin()
3716
          for _i25 in xrange(_size21):
3717
            _elem26 = Transaction()
3718
            _elem26.read(iprot)
3719
            self.success.append(_elem26)
132 ashish 3720
          iprot.readListEnd()
3721
        else:
3722
          iprot.skip(ftype)
3723
      elif fid == 1:
3724
        if ftype == TType.STRUCT:
3725
          self.ex = TransactionServiceException()
3726
          self.ex.read(iprot)
3727
        else:
3728
          iprot.skip(ftype)
3729
      else:
3730
        iprot.skip(ftype)
3731
      iprot.readFieldEnd()
3732
    iprot.readStructEnd()
3733
 
3734
  def write(self, oprot):
3735
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3736
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3737
      return
3738
    oprot.writeStructBegin('getTransactionsForShoppingCartId_result')
3431 rajveer 3739
    if self.success is not None:
132 ashish 3740
      oprot.writeFieldBegin('success', TType.LIST, 0)
3741
      oprot.writeListBegin(TType.STRUCT, len(self.success))
685 chandransh 3742
      for iter27 in self.success:
3743
        iter27.write(oprot)
132 ashish 3744
      oprot.writeListEnd()
3745
      oprot.writeFieldEnd()
3431 rajveer 3746
    if self.ex is not None:
132 ashish 3747
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3748
      self.ex.write(oprot)
3749
      oprot.writeFieldEnd()
3750
    oprot.writeFieldStop()
3751
    oprot.writeStructEnd()
3752
 
3431 rajveer 3753
  def validate(self):
3754
    return
3755
 
3756
 
132 ashish 3757
  def __repr__(self):
3758
    L = ['%s=%r' % (key, value)
3759
      for key, value in self.__dict__.iteritems()]
3760
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3761
 
3762
  def __eq__(self, other):
3763
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3764
 
3765
  def __ne__(self, other):
3766
    return not (self == other)
3767
 
94 ashish 3768
class getTransactionStatus_args:
3769
  """
3770
  Attributes:
3771
   - transactionId
3772
  """
3773
 
3774
  thrift_spec = (
3775
    None, # 0
3776
    (1, TType.I64, 'transactionId', None, None, ), # 1
3777
  )
3778
 
3779
  def __init__(self, transactionId=None,):
3780
    self.transactionId = transactionId
3781
 
3782
  def read(self, iprot):
3783
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3784
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3785
      return
3786
    iprot.readStructBegin()
3787
    while True:
3788
      (fname, ftype, fid) = iprot.readFieldBegin()
3789
      if ftype == TType.STOP:
3790
        break
3791
      if fid == 1:
3792
        if ftype == TType.I64:
3793
          self.transactionId = iprot.readI64();
3794
        else:
3795
          iprot.skip(ftype)
3796
      else:
3797
        iprot.skip(ftype)
3798
      iprot.readFieldEnd()
3799
    iprot.readStructEnd()
3800
 
3801
  def write(self, oprot):
3802
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3803
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3804
      return
3805
    oprot.writeStructBegin('getTransactionStatus_args')
3431 rajveer 3806
    if self.transactionId is not None:
94 ashish 3807
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
3808
      oprot.writeI64(self.transactionId)
3809
      oprot.writeFieldEnd()
3810
    oprot.writeFieldStop()
3811
    oprot.writeStructEnd()
3812
 
3431 rajveer 3813
  def validate(self):
3814
    return
3815
 
3816
 
94 ashish 3817
  def __repr__(self):
3818
    L = ['%s=%r' % (key, value)
3819
      for key, value in self.__dict__.iteritems()]
3820
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3821
 
3822
  def __eq__(self, other):
3823
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3824
 
3825
  def __ne__(self, other):
3826
    return not (self == other)
3827
 
3828
class getTransactionStatus_result:
3829
  """
3830
  Attributes:
3831
   - success
3832
   - ex
3833
  """
3834
 
3835
  thrift_spec = (
3836
    (0, TType.I32, 'success', None, None, ), # 0
3837
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3838
  )
3839
 
3840
  def __init__(self, success=None, ex=None,):
3841
    self.success = success
3842
    self.ex = ex
3843
 
3844
  def read(self, iprot):
3845
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3846
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3847
      return
3848
    iprot.readStructBegin()
3849
    while True:
3850
      (fname, ftype, fid) = iprot.readFieldBegin()
3851
      if ftype == TType.STOP:
3852
        break
3853
      if fid == 0:
3854
        if ftype == TType.I32:
3855
          self.success = iprot.readI32();
3856
        else:
3857
          iprot.skip(ftype)
3858
      elif fid == 1:
3859
        if ftype == TType.STRUCT:
3860
          self.ex = TransactionServiceException()
3861
          self.ex.read(iprot)
3862
        else:
3863
          iprot.skip(ftype)
3864
      else:
3865
        iprot.skip(ftype)
3866
      iprot.readFieldEnd()
3867
    iprot.readStructEnd()
3868
 
3869
  def write(self, oprot):
3870
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3871
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3872
      return
3873
    oprot.writeStructBegin('getTransactionStatus_result')
3431 rajveer 3874
    if self.success is not None:
94 ashish 3875
      oprot.writeFieldBegin('success', TType.I32, 0)
3876
      oprot.writeI32(self.success)
3877
      oprot.writeFieldEnd()
3431 rajveer 3878
    if self.ex is not None:
94 ashish 3879
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3880
      self.ex.write(oprot)
3881
      oprot.writeFieldEnd()
3882
    oprot.writeFieldStop()
3883
    oprot.writeStructEnd()
3884
 
3431 rajveer 3885
  def validate(self):
3886
    return
3887
 
3888
 
94 ashish 3889
  def __repr__(self):
3890
    L = ['%s=%r' % (key, value)
3891
      for key, value in self.__dict__.iteritems()]
3892
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3893
 
3894
  def __eq__(self, other):
3895
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3896
 
3897
  def __ne__(self, other):
3898
    return not (self == other)
3899
 
3900
class changeTransactionStatus_args:
3901
  """
3902
  Attributes:
3903
   - transactionId
3904
   - status
3905
   - description
3906
  """
3907
 
3908
  thrift_spec = (
3909
    None, # 0
3910
    (1, TType.I64, 'transactionId', None, None, ), # 1
3911
    (2, TType.I32, 'status', None, None, ), # 2
3912
    (3, TType.STRING, 'description', None, None, ), # 3
3913
  )
3914
 
3915
  def __init__(self, transactionId=None, status=None, description=None,):
3916
    self.transactionId = transactionId
3917
    self.status = status
3918
    self.description = description
3919
 
3920
  def read(self, iprot):
3921
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3922
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3923
      return
3924
    iprot.readStructBegin()
3925
    while True:
3926
      (fname, ftype, fid) = iprot.readFieldBegin()
3927
      if ftype == TType.STOP:
3928
        break
3929
      if fid == 1:
3930
        if ftype == TType.I64:
3931
          self.transactionId = iprot.readI64();
3932
        else:
3933
          iprot.skip(ftype)
3934
      elif fid == 2:
3935
        if ftype == TType.I32:
3936
          self.status = iprot.readI32();
3937
        else:
3938
          iprot.skip(ftype)
3939
      elif fid == 3:
3940
        if ftype == TType.STRING:
3941
          self.description = iprot.readString();
3942
        else:
3943
          iprot.skip(ftype)
3944
      else:
3945
        iprot.skip(ftype)
3946
      iprot.readFieldEnd()
3947
    iprot.readStructEnd()
3948
 
3949
  def write(self, oprot):
3950
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3951
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3952
      return
3953
    oprot.writeStructBegin('changeTransactionStatus_args')
3431 rajveer 3954
    if self.transactionId is not None:
94 ashish 3955
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
3956
      oprot.writeI64(self.transactionId)
3957
      oprot.writeFieldEnd()
3431 rajveer 3958
    if self.status is not None:
94 ashish 3959
      oprot.writeFieldBegin('status', TType.I32, 2)
3960
      oprot.writeI32(self.status)
3961
      oprot.writeFieldEnd()
3431 rajveer 3962
    if self.description is not None:
94 ashish 3963
      oprot.writeFieldBegin('description', TType.STRING, 3)
3964
      oprot.writeString(self.description)
3965
      oprot.writeFieldEnd()
3966
    oprot.writeFieldStop()
3967
    oprot.writeStructEnd()
3968
 
3431 rajveer 3969
  def validate(self):
3970
    return
3971
 
3972
 
94 ashish 3973
  def __repr__(self):
3974
    L = ['%s=%r' % (key, value)
3975
      for key, value in self.__dict__.iteritems()]
3976
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3977
 
3978
  def __eq__(self, other):
3979
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3980
 
3981
  def __ne__(self, other):
3982
    return not (self == other)
3983
 
3984
class changeTransactionStatus_result:
3985
  """
3986
  Attributes:
3987
   - success
3988
   - ex
3989
  """
3990
 
3991
  thrift_spec = (
3992
    (0, TType.BOOL, 'success', None, None, ), # 0
3993
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3994
  )
3995
 
3996
  def __init__(self, success=None, ex=None,):
3997
    self.success = success
3998
    self.ex = ex
3999
 
4000
  def read(self, iprot):
4001
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4002
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4003
      return
4004
    iprot.readStructBegin()
4005
    while True:
4006
      (fname, ftype, fid) = iprot.readFieldBegin()
4007
      if ftype == TType.STOP:
4008
        break
4009
      if fid == 0:
4010
        if ftype == TType.BOOL:
4011
          self.success = iprot.readBool();
4012
        else:
4013
          iprot.skip(ftype)
4014
      elif fid == 1:
4015
        if ftype == TType.STRUCT:
4016
          self.ex = TransactionServiceException()
4017
          self.ex.read(iprot)
4018
        else:
4019
          iprot.skip(ftype)
4020
      else:
4021
        iprot.skip(ftype)
4022
      iprot.readFieldEnd()
4023
    iprot.readStructEnd()
4024
 
4025
  def write(self, oprot):
4026
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4027
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4028
      return
4029
    oprot.writeStructBegin('changeTransactionStatus_result')
3431 rajveer 4030
    if self.success is not None:
94 ashish 4031
      oprot.writeFieldBegin('success', TType.BOOL, 0)
4032
      oprot.writeBool(self.success)
4033
      oprot.writeFieldEnd()
3431 rajveer 4034
    if self.ex is not None:
94 ashish 4035
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4036
      self.ex.write(oprot)
4037
      oprot.writeFieldEnd()
4038
    oprot.writeFieldStop()
4039
    oprot.writeStructEnd()
4040
 
3431 rajveer 4041
  def validate(self):
4042
    return
4043
 
4044
 
94 ashish 4045
  def __repr__(self):
4046
    L = ['%s=%r' % (key, value)
4047
      for key, value in self.__dict__.iteritems()]
4048
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4049
 
4050
  def __eq__(self, other):
4051
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4052
 
4053
  def __ne__(self, other):
4054
    return not (self == other)
4055
 
1398 varun.gupt 4056
class enqueueTransactionInfoEmail_args:
1382 varun.gupt 4057
  """
4058
  Attributes:
4059
   - transactionId
4060
  """
4061
 
4062
  thrift_spec = (
4063
    None, # 0
4064
    (1, TType.I64, 'transactionId', None, None, ), # 1
4065
  )
4066
 
4067
  def __init__(self, transactionId=None,):
4068
    self.transactionId = transactionId
4069
 
4070
  def read(self, iprot):
4071
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4072
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4073
      return
4074
    iprot.readStructBegin()
4075
    while True:
4076
      (fname, ftype, fid) = iprot.readFieldBegin()
4077
      if ftype == TType.STOP:
4078
        break
4079
      if fid == 1:
4080
        if ftype == TType.I64:
4081
          self.transactionId = iprot.readI64();
4082
        else:
4083
          iprot.skip(ftype)
4084
      else:
4085
        iprot.skip(ftype)
4086
      iprot.readFieldEnd()
4087
    iprot.readStructEnd()
4088
 
4089
  def write(self, oprot):
4090
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4091
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4092
      return
1398 varun.gupt 4093
    oprot.writeStructBegin('enqueueTransactionInfoEmail_args')
3431 rajveer 4094
    if self.transactionId is not None:
1382 varun.gupt 4095
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
4096
      oprot.writeI64(self.transactionId)
4097
      oprot.writeFieldEnd()
4098
    oprot.writeFieldStop()
4099
    oprot.writeStructEnd()
4100
 
3431 rajveer 4101
  def validate(self):
4102
    return
4103
 
4104
 
1382 varun.gupt 4105
  def __repr__(self):
4106
    L = ['%s=%r' % (key, value)
4107
      for key, value in self.__dict__.iteritems()]
4108
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4109
 
4110
  def __eq__(self, other):
4111
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4112
 
4113
  def __ne__(self, other):
4114
    return not (self == other)
4115
 
1398 varun.gupt 4116
class enqueueTransactionInfoEmail_result:
1382 varun.gupt 4117
  """
4118
  Attributes:
4119
   - success
4120
   - ex
4121
  """
4122
 
4123
  thrift_spec = (
4124
    (0, TType.BOOL, 'success', None, None, ), # 0
4125
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4126
  )
4127
 
4128
  def __init__(self, success=None, ex=None,):
4129
    self.success = success
4130
    self.ex = ex
4131
 
4132
  def read(self, iprot):
4133
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4134
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4135
      return
4136
    iprot.readStructBegin()
4137
    while True:
4138
      (fname, ftype, fid) = iprot.readFieldBegin()
4139
      if ftype == TType.STOP:
4140
        break
4141
      if fid == 0:
4142
        if ftype == TType.BOOL:
4143
          self.success = iprot.readBool();
4144
        else:
4145
          iprot.skip(ftype)
4146
      elif fid == 1:
4147
        if ftype == TType.STRUCT:
4148
          self.ex = TransactionServiceException()
4149
          self.ex.read(iprot)
4150
        else:
4151
          iprot.skip(ftype)
4152
      else:
4153
        iprot.skip(ftype)
4154
      iprot.readFieldEnd()
4155
    iprot.readStructEnd()
4156
 
4157
  def write(self, oprot):
4158
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4159
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4160
      return
1398 varun.gupt 4161
    oprot.writeStructBegin('enqueueTransactionInfoEmail_result')
3431 rajveer 4162
    if self.success is not None:
1382 varun.gupt 4163
      oprot.writeFieldBegin('success', TType.BOOL, 0)
4164
      oprot.writeBool(self.success)
4165
      oprot.writeFieldEnd()
3431 rajveer 4166
    if self.ex is not None:
1382 varun.gupt 4167
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4168
      self.ex.write(oprot)
4169
      oprot.writeFieldEnd()
4170
    oprot.writeFieldStop()
4171
    oprot.writeStructEnd()
4172
 
3431 rajveer 4173
  def validate(self):
4174
    return
4175
 
4176
 
1382 varun.gupt 4177
  def __repr__(self):
4178
    L = ['%s=%r' % (key, value)
4179
      for key, value in self.__dict__.iteritems()]
4180
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4181
 
4182
  def __eq__(self, other):
4183
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4184
 
4185
  def __ne__(self, other):
4186
    return not (self == other)
4187
 
483 rajveer 4188
class getAllOrders_args:
94 ashish 4189
  """
4190
  Attributes:
483 rajveer 4191
   - status
4192
   - from_date
4193
   - to_date
4194
   - warehouse_id
94 ashish 4195
  """
4196
 
4197
  thrift_spec = (
4198
    None, # 0
483 rajveer 4199
    (1, TType.I32, 'status', None, None, ), # 1
4200
    (2, TType.I64, 'from_date', None, None, ), # 2
4201
    (3, TType.I64, 'to_date', None, None, ), # 3
4202
    (4, TType.I64, 'warehouse_id', None, None, ), # 4
94 ashish 4203
  )
4204
 
483 rajveer 4205
  def __init__(self, status=None, from_date=None, to_date=None, warehouse_id=None,):
4206
    self.status = status
4207
    self.from_date = from_date
4208
    self.to_date = to_date
4209
    self.warehouse_id = warehouse_id
94 ashish 4210
 
4211
  def read(self, iprot):
4212
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4213
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4214
      return
4215
    iprot.readStructBegin()
4216
    while True:
4217
      (fname, ftype, fid) = iprot.readFieldBegin()
4218
      if ftype == TType.STOP:
4219
        break
4220
      if fid == 1:
483 rajveer 4221
        if ftype == TType.I32:
4222
          self.status = iprot.readI32();
94 ashish 4223
        else:
4224
          iprot.skip(ftype)
483 rajveer 4225
      elif fid == 2:
4226
        if ftype == TType.I64:
4227
          self.from_date = iprot.readI64();
94 ashish 4228
        else:
4229
          iprot.skip(ftype)
483 rajveer 4230
      elif fid == 3:
4231
        if ftype == TType.I64:
4232
          self.to_date = iprot.readI64();
94 ashish 4233
        else:
4234
          iprot.skip(ftype)
483 rajveer 4235
      elif fid == 4:
94 ashish 4236
        if ftype == TType.I64:
483 rajveer 4237
          self.warehouse_id = iprot.readI64();
94 ashish 4238
        else:
4239
          iprot.skip(ftype)
4240
      else:
4241
        iprot.skip(ftype)
4242
      iprot.readFieldEnd()
4243
    iprot.readStructEnd()
4244
 
4245
  def write(self, oprot):
4246
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4247
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4248
      return
483 rajveer 4249
    oprot.writeStructBegin('getAllOrders_args')
3431 rajveer 4250
    if self.status is not None:
483 rajveer 4251
      oprot.writeFieldBegin('status', TType.I32, 1)
4252
      oprot.writeI32(self.status)
94 ashish 4253
      oprot.writeFieldEnd()
3431 rajveer 4254
    if self.from_date is not None:
483 rajveer 4255
      oprot.writeFieldBegin('from_date', TType.I64, 2)
4256
      oprot.writeI64(self.from_date)
94 ashish 4257
      oprot.writeFieldEnd()
3431 rajveer 4258
    if self.to_date is not None:
483 rajveer 4259
      oprot.writeFieldBegin('to_date', TType.I64, 3)
4260
      oprot.writeI64(self.to_date)
94 ashish 4261
      oprot.writeFieldEnd()
3431 rajveer 4262
    if self.warehouse_id is not None:
483 rajveer 4263
      oprot.writeFieldBegin('warehouse_id', TType.I64, 4)
4264
      oprot.writeI64(self.warehouse_id)
94 ashish 4265
      oprot.writeFieldEnd()
4266
    oprot.writeFieldStop()
4267
    oprot.writeStructEnd()
4268
 
3431 rajveer 4269
  def validate(self):
4270
    return
4271
 
4272
 
94 ashish 4273
  def __repr__(self):
4274
    L = ['%s=%r' % (key, value)
4275
      for key, value in self.__dict__.iteritems()]
4276
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4277
 
4278
  def __eq__(self, other):
4279
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4280
 
4281
  def __ne__(self, other):
4282
    return not (self == other)
4283
 
483 rajveer 4284
class getAllOrders_result:
94 ashish 4285
  """
4286
  Attributes:
4287
   - success
4288
   - ex
4289
  """
4290
 
4291
  thrift_spec = (
483 rajveer 4292
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
94 ashish 4293
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4294
  )
4295
 
4296
  def __init__(self, success=None, ex=None,):
4297
    self.success = success
4298
    self.ex = ex
4299
 
4300
  def read(self, iprot):
4301
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4302
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4303
      return
4304
    iprot.readStructBegin()
4305
    while True:
4306
      (fname, ftype, fid) = iprot.readFieldBegin()
4307
      if ftype == TType.STOP:
4308
        break
4309
      if fid == 0:
483 rajveer 4310
        if ftype == TType.LIST:
4311
          self.success = []
685 chandransh 4312
          (_etype31, _size28) = iprot.readListBegin()
4313
          for _i32 in xrange(_size28):
4314
            _elem33 = Order()
4315
            _elem33.read(iprot)
4316
            self.success.append(_elem33)
483 rajveer 4317
          iprot.readListEnd()
94 ashish 4318
        else:
4319
          iprot.skip(ftype)
4320
      elif fid == 1:
4321
        if ftype == TType.STRUCT:
4322
          self.ex = TransactionServiceException()
4323
          self.ex.read(iprot)
4324
        else:
4325
          iprot.skip(ftype)
4326
      else:
4327
        iprot.skip(ftype)
4328
      iprot.readFieldEnd()
4329
    iprot.readStructEnd()
4330
 
4331
  def write(self, oprot):
4332
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4333
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4334
      return
483 rajveer 4335
    oprot.writeStructBegin('getAllOrders_result')
3431 rajveer 4336
    if self.success is not None:
483 rajveer 4337
      oprot.writeFieldBegin('success', TType.LIST, 0)
4338
      oprot.writeListBegin(TType.STRUCT, len(self.success))
685 chandransh 4339
      for iter34 in self.success:
4340
        iter34.write(oprot)
483 rajveer 4341
      oprot.writeListEnd()
94 ashish 4342
      oprot.writeFieldEnd()
3431 rajveer 4343
    if self.ex is not None:
94 ashish 4344
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4345
      self.ex.write(oprot)
4346
      oprot.writeFieldEnd()
4347
    oprot.writeFieldStop()
4348
    oprot.writeStructEnd()
4349
 
3431 rajveer 4350
  def validate(self):
4351
    return
4352
 
4353
 
94 ashish 4354
  def __repr__(self):
4355
    L = ['%s=%r' % (key, value)
4356
      for key, value in self.__dict__.iteritems()]
4357
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4358
 
4359
  def __eq__(self, other):
4360
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4361
 
4362
  def __ne__(self, other):
4363
    return not (self == other)
4364
 
999 varun.gupt 4365
class getOrdersByBillingDate_args:
4366
  """
4367
  Attributes:
4368
   - status
4369
   - start_billing_date
4370
   - end_billing_date
4371
   - warehouse_id
4372
  """
4373
 
4374
  thrift_spec = (
4375
    None, # 0
4376
    (1, TType.I32, 'status', None, None, ), # 1
4377
    (2, TType.I64, 'start_billing_date', None, None, ), # 2
4378
    (3, TType.I64, 'end_billing_date', None, None, ), # 3
4379
    (4, TType.I64, 'warehouse_id', None, None, ), # 4
4380
  )
4381
 
4382
  def __init__(self, status=None, start_billing_date=None, end_billing_date=None, warehouse_id=None,):
4383
    self.status = status
4384
    self.start_billing_date = start_billing_date
4385
    self.end_billing_date = end_billing_date
4386
    self.warehouse_id = warehouse_id
4387
 
4388
  def read(self, iprot):
4389
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4390
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4391
      return
4392
    iprot.readStructBegin()
4393
    while True:
4394
      (fname, ftype, fid) = iprot.readFieldBegin()
4395
      if ftype == TType.STOP:
4396
        break
4397
      if fid == 1:
4398
        if ftype == TType.I32:
4399
          self.status = iprot.readI32();
4400
        else:
4401
          iprot.skip(ftype)
4402
      elif fid == 2:
4403
        if ftype == TType.I64:
4404
          self.start_billing_date = iprot.readI64();
4405
        else:
4406
          iprot.skip(ftype)
4407
      elif fid == 3:
4408
        if ftype == TType.I64:
4409
          self.end_billing_date = iprot.readI64();
4410
        else:
4411
          iprot.skip(ftype)
4412
      elif fid == 4:
4413
        if ftype == TType.I64:
4414
          self.warehouse_id = iprot.readI64();
4415
        else:
4416
          iprot.skip(ftype)
4417
      else:
4418
        iprot.skip(ftype)
4419
      iprot.readFieldEnd()
4420
    iprot.readStructEnd()
4421
 
4422
  def write(self, oprot):
4423
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4424
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4425
      return
4426
    oprot.writeStructBegin('getOrdersByBillingDate_args')
3431 rajveer 4427
    if self.status is not None:
999 varun.gupt 4428
      oprot.writeFieldBegin('status', TType.I32, 1)
4429
      oprot.writeI32(self.status)
4430
      oprot.writeFieldEnd()
3431 rajveer 4431
    if self.start_billing_date is not None:
999 varun.gupt 4432
      oprot.writeFieldBegin('start_billing_date', TType.I64, 2)
4433
      oprot.writeI64(self.start_billing_date)
4434
      oprot.writeFieldEnd()
3431 rajveer 4435
    if self.end_billing_date is not None:
999 varun.gupt 4436
      oprot.writeFieldBegin('end_billing_date', TType.I64, 3)
4437
      oprot.writeI64(self.end_billing_date)
4438
      oprot.writeFieldEnd()
3431 rajveer 4439
    if self.warehouse_id is not None:
999 varun.gupt 4440
      oprot.writeFieldBegin('warehouse_id', TType.I64, 4)
4441
      oprot.writeI64(self.warehouse_id)
4442
      oprot.writeFieldEnd()
4443
    oprot.writeFieldStop()
4444
    oprot.writeStructEnd()
4445
 
3431 rajveer 4446
  def validate(self):
4447
    return
4448
 
4449
 
999 varun.gupt 4450
  def __repr__(self):
4451
    L = ['%s=%r' % (key, value)
4452
      for key, value in self.__dict__.iteritems()]
4453
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4454
 
4455
  def __eq__(self, other):
4456
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4457
 
4458
  def __ne__(self, other):
4459
    return not (self == other)
4460
 
4461
class getOrdersByBillingDate_result:
4462
  """
4463
  Attributes:
4464
   - success
4465
   - ex
4466
  """
4467
 
4468
  thrift_spec = (
4469
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
4470
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4471
  )
4472
 
4473
  def __init__(self, success=None, ex=None,):
4474
    self.success = success
4475
    self.ex = ex
4476
 
4477
  def read(self, iprot):
4478
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4479
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4480
      return
4481
    iprot.readStructBegin()
4482
    while True:
4483
      (fname, ftype, fid) = iprot.readFieldBegin()
4484
      if ftype == TType.STOP:
4485
        break
4486
      if fid == 0:
4487
        if ftype == TType.LIST:
4488
          self.success = []
4489
          (_etype38, _size35) = iprot.readListBegin()
4490
          for _i39 in xrange(_size35):
4491
            _elem40 = Order()
4492
            _elem40.read(iprot)
4493
            self.success.append(_elem40)
4494
          iprot.readListEnd()
4495
        else:
4496
          iprot.skip(ftype)
4497
      elif fid == 1:
4498
        if ftype == TType.STRUCT:
4499
          self.ex = TransactionServiceException()
4500
          self.ex.read(iprot)
4501
        else:
4502
          iprot.skip(ftype)
4503
      else:
4504
        iprot.skip(ftype)
4505
      iprot.readFieldEnd()
4506
    iprot.readStructEnd()
4507
 
4508
  def write(self, oprot):
4509
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4510
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4511
      return
4512
    oprot.writeStructBegin('getOrdersByBillingDate_result')
3431 rajveer 4513
    if self.success is not None:
999 varun.gupt 4514
      oprot.writeFieldBegin('success', TType.LIST, 0)
4515
      oprot.writeListBegin(TType.STRUCT, len(self.success))
4516
      for iter41 in self.success:
4517
        iter41.write(oprot)
4518
      oprot.writeListEnd()
4519
      oprot.writeFieldEnd()
3431 rajveer 4520
    if self.ex is not None:
999 varun.gupt 4521
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4522
      self.ex.write(oprot)
4523
      oprot.writeFieldEnd()
4524
    oprot.writeFieldStop()
4525
    oprot.writeStructEnd()
4526
 
3431 rajveer 4527
  def validate(self):
4528
    return
4529
 
4530
 
999 varun.gupt 4531
  def __repr__(self):
4532
    L = ['%s=%r' % (key, value)
4533
      for key, value in self.__dict__.iteritems()]
4534
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4535
 
4536
  def __eq__(self, other):
4537
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4538
 
4539
  def __ne__(self, other):
4540
    return not (self == other)
4541
 
3427 chandransh 4542
class getOrdersByShippingDate_args:
4543
  """
4544
  Attributes:
4545
   - fromShippingDate
4546
   - toShippingDate
4547
   - providerId
4548
   - warehouseId
3451 chandransh 4549
   - cod
3427 chandransh 4550
  """
4551
 
4552
  thrift_spec = (
4553
    None, # 0
4554
    (1, TType.I64, 'fromShippingDate', None, None, ), # 1
4555
    (2, TType.I64, 'toShippingDate', None, None, ), # 2
4556
    (3, TType.I64, 'providerId', None, None, ), # 3
4557
    (4, TType.I64, 'warehouseId', None, None, ), # 4
3451 chandransh 4558
    (5, TType.BOOL, 'cod', None, None, ), # 5
3427 chandransh 4559
  )
4560
 
3451 chandransh 4561
  def __init__(self, fromShippingDate=None, toShippingDate=None, providerId=None, warehouseId=None, cod=None,):
3427 chandransh 4562
    self.fromShippingDate = fromShippingDate
4563
    self.toShippingDate = toShippingDate
4564
    self.providerId = providerId
4565
    self.warehouseId = warehouseId
3451 chandransh 4566
    self.cod = cod
3427 chandransh 4567
 
4568
  def read(self, iprot):
4569
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4570
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4571
      return
4572
    iprot.readStructBegin()
4573
    while True:
4574
      (fname, ftype, fid) = iprot.readFieldBegin()
4575
      if ftype == TType.STOP:
4576
        break
4577
      if fid == 1:
4578
        if ftype == TType.I64:
4579
          self.fromShippingDate = iprot.readI64();
4580
        else:
4581
          iprot.skip(ftype)
4582
      elif fid == 2:
4583
        if ftype == TType.I64:
4584
          self.toShippingDate = iprot.readI64();
4585
        else:
4586
          iprot.skip(ftype)
4587
      elif fid == 3:
4588
        if ftype == TType.I64:
4589
          self.providerId = iprot.readI64();
4590
        else:
4591
          iprot.skip(ftype)
4592
      elif fid == 4:
4593
        if ftype == TType.I64:
4594
          self.warehouseId = iprot.readI64();
4595
        else:
4596
          iprot.skip(ftype)
3451 chandransh 4597
      elif fid == 5:
4598
        if ftype == TType.BOOL:
4599
          self.cod = iprot.readBool();
4600
        else:
4601
          iprot.skip(ftype)
3427 chandransh 4602
      else:
4603
        iprot.skip(ftype)
4604
      iprot.readFieldEnd()
4605
    iprot.readStructEnd()
4606
 
4607
  def write(self, oprot):
4608
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4609
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4610
      return
4611
    oprot.writeStructBegin('getOrdersByShippingDate_args')
3431 rajveer 4612
    if self.fromShippingDate is not None:
3427 chandransh 4613
      oprot.writeFieldBegin('fromShippingDate', TType.I64, 1)
4614
      oprot.writeI64(self.fromShippingDate)
4615
      oprot.writeFieldEnd()
3431 rajveer 4616
    if self.toShippingDate is not None:
3427 chandransh 4617
      oprot.writeFieldBegin('toShippingDate', TType.I64, 2)
4618
      oprot.writeI64(self.toShippingDate)
4619
      oprot.writeFieldEnd()
3431 rajveer 4620
    if self.providerId is not None:
3427 chandransh 4621
      oprot.writeFieldBegin('providerId', TType.I64, 3)
4622
      oprot.writeI64(self.providerId)
4623
      oprot.writeFieldEnd()
3431 rajveer 4624
    if self.warehouseId is not None:
3427 chandransh 4625
      oprot.writeFieldBegin('warehouseId', TType.I64, 4)
4626
      oprot.writeI64(self.warehouseId)
4627
      oprot.writeFieldEnd()
3451 chandransh 4628
    if self.cod is not None:
4629
      oprot.writeFieldBegin('cod', TType.BOOL, 5)
4630
      oprot.writeBool(self.cod)
4631
      oprot.writeFieldEnd()
3427 chandransh 4632
    oprot.writeFieldStop()
4633
    oprot.writeStructEnd()
4634
 
3431 rajveer 4635
  def validate(self):
4636
    return
4637
 
4638
 
3427 chandransh 4639
  def __repr__(self):
4640
    L = ['%s=%r' % (key, value)
4641
      for key, value in self.__dict__.iteritems()]
4642
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4643
 
4644
  def __eq__(self, other):
4645
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4646
 
4647
  def __ne__(self, other):
4648
    return not (self == other)
4649
 
4650
class getOrdersByShippingDate_result:
4651
  """
4652
  Attributes:
4653
   - success
4654
   - ex
4655
  """
4656
 
4657
  thrift_spec = (
4658
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
4659
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4660
  )
4661
 
4662
  def __init__(self, success=None, ex=None,):
4663
    self.success = success
4664
    self.ex = ex
4665
 
4666
  def read(self, iprot):
4667
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4668
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4669
      return
4670
    iprot.readStructBegin()
4671
    while True:
4672
      (fname, ftype, fid) = iprot.readFieldBegin()
4673
      if ftype == TType.STOP:
4674
        break
4675
      if fid == 0:
4676
        if ftype == TType.LIST:
4677
          self.success = []
4678
          (_etype45, _size42) = iprot.readListBegin()
4679
          for _i46 in xrange(_size42):
4680
            _elem47 = Order()
4681
            _elem47.read(iprot)
4682
            self.success.append(_elem47)
4683
          iprot.readListEnd()
4684
        else:
4685
          iprot.skip(ftype)
4686
      elif fid == 1:
4687
        if ftype == TType.STRUCT:
4688
          self.ex = TransactionServiceException()
4689
          self.ex.read(iprot)
4690
        else:
4691
          iprot.skip(ftype)
4692
      else:
4693
        iprot.skip(ftype)
4694
      iprot.readFieldEnd()
4695
    iprot.readStructEnd()
4696
 
4697
  def write(self, oprot):
4698
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4699
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4700
      return
4701
    oprot.writeStructBegin('getOrdersByShippingDate_result')
3431 rajveer 4702
    if self.success is not None:
3427 chandransh 4703
      oprot.writeFieldBegin('success', TType.LIST, 0)
4704
      oprot.writeListBegin(TType.STRUCT, len(self.success))
4705
      for iter48 in self.success:
4706
        iter48.write(oprot)
4707
      oprot.writeListEnd()
4708
      oprot.writeFieldEnd()
3431 rajveer 4709
    if self.ex is not None:
3427 chandransh 4710
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4711
      self.ex.write(oprot)
4712
      oprot.writeFieldEnd()
4713
    oprot.writeFieldStop()
4714
    oprot.writeStructEnd()
4715
 
3431 rajveer 4716
  def validate(self):
4717
    return
4718
 
4719
 
3427 chandransh 4720
  def __repr__(self):
4721
    L = ['%s=%r' % (key, value)
4722
      for key, value in self.__dict__.iteritems()]
4723
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4724
 
4725
  def __eq__(self, other):
4726
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4727
 
4728
  def __ne__(self, other):
4729
    return not (self == other)
4730
 
1382 varun.gupt 4731
class getReturnableOrdersForCustomer_args:
4732
  """
4733
  Attributes:
4734
   - customer_id
4735
   - limit
4736
  """
4737
 
4738
  thrift_spec = (
4739
    None, # 0
4740
    (1, TType.I64, 'customer_id', None, None, ), # 1
4741
    (2, TType.I64, 'limit', None, None, ), # 2
4742
  )
4743
 
4744
  def __init__(self, customer_id=None, limit=None,):
4745
    self.customer_id = customer_id
4746
    self.limit = limit
4747
 
4748
  def read(self, iprot):
4749
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4750
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4751
      return
4752
    iprot.readStructBegin()
4753
    while True:
4754
      (fname, ftype, fid) = iprot.readFieldBegin()
4755
      if ftype == TType.STOP:
4756
        break
4757
      if fid == 1:
4758
        if ftype == TType.I64:
4759
          self.customer_id = iprot.readI64();
4760
        else:
4761
          iprot.skip(ftype)
4762
      elif fid == 2:
4763
        if ftype == TType.I64:
4764
          self.limit = iprot.readI64();
4765
        else:
4766
          iprot.skip(ftype)
4767
      else:
4768
        iprot.skip(ftype)
4769
      iprot.readFieldEnd()
4770
    iprot.readStructEnd()
4771
 
4772
  def write(self, oprot):
4773
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4774
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4775
      return
4776
    oprot.writeStructBegin('getReturnableOrdersForCustomer_args')
3431 rajveer 4777
    if self.customer_id is not None:
1382 varun.gupt 4778
      oprot.writeFieldBegin('customer_id', TType.I64, 1)
4779
      oprot.writeI64(self.customer_id)
4780
      oprot.writeFieldEnd()
3431 rajveer 4781
    if self.limit is not None:
1382 varun.gupt 4782
      oprot.writeFieldBegin('limit', TType.I64, 2)
4783
      oprot.writeI64(self.limit)
4784
      oprot.writeFieldEnd()
4785
    oprot.writeFieldStop()
4786
    oprot.writeStructEnd()
4787
 
3431 rajveer 4788
  def validate(self):
4789
    return
4790
 
4791
 
1382 varun.gupt 4792
  def __repr__(self):
4793
    L = ['%s=%r' % (key, value)
4794
      for key, value in self.__dict__.iteritems()]
4795
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4796
 
4797
  def __eq__(self, other):
4798
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4799
 
4800
  def __ne__(self, other):
4801
    return not (self == other)
4802
 
4803
class getReturnableOrdersForCustomer_result:
4804
  """
4805
  Attributes:
4806
   - success
4807
   - ex
4808
  """
4809
 
4810
  thrift_spec = (
4811
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
4812
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4813
  )
4814
 
4815
  def __init__(self, success=None, ex=None,):
4816
    self.success = success
4817
    self.ex = ex
4818
 
4819
  def read(self, iprot):
4820
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4821
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4822
      return
4823
    iprot.readStructBegin()
4824
    while True:
4825
      (fname, ftype, fid) = iprot.readFieldBegin()
4826
      if ftype == TType.STOP:
4827
        break
4828
      if fid == 0:
4829
        if ftype == TType.LIST:
4830
          self.success = []
3427 chandransh 4831
          (_etype52, _size49) = iprot.readListBegin()
4832
          for _i53 in xrange(_size49):
4833
            _elem54 = iprot.readI64();
4834
            self.success.append(_elem54)
1382 varun.gupt 4835
          iprot.readListEnd()
4836
        else:
4837
          iprot.skip(ftype)
4838
      elif fid == 1:
4839
        if ftype == TType.STRUCT:
4840
          self.ex = TransactionServiceException()
4841
          self.ex.read(iprot)
4842
        else:
4843
          iprot.skip(ftype)
4844
      else:
4845
        iprot.skip(ftype)
4846
      iprot.readFieldEnd()
4847
    iprot.readStructEnd()
4848
 
4849
  def write(self, oprot):
4850
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4851
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4852
      return
4853
    oprot.writeStructBegin('getReturnableOrdersForCustomer_result')
3431 rajveer 4854
    if self.success is not None:
1382 varun.gupt 4855
      oprot.writeFieldBegin('success', TType.LIST, 0)
4856
      oprot.writeListBegin(TType.I64, len(self.success))
3427 chandransh 4857
      for iter55 in self.success:
4858
        oprot.writeI64(iter55)
1382 varun.gupt 4859
      oprot.writeListEnd()
4860
      oprot.writeFieldEnd()
3431 rajveer 4861
    if self.ex is not None:
1382 varun.gupt 4862
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4863
      self.ex.write(oprot)
4864
      oprot.writeFieldEnd()
4865
    oprot.writeFieldStop()
4866
    oprot.writeStructEnd()
4867
 
3431 rajveer 4868
  def validate(self):
4869
    return
4870
 
4871
 
1382 varun.gupt 4872
  def __repr__(self):
4873
    L = ['%s=%r' % (key, value)
4874
      for key, value in self.__dict__.iteritems()]
4875
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4876
 
4877
  def __eq__(self, other):
4878
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4879
 
4880
  def __ne__(self, other):
4881
    return not (self == other)
4882
 
4883
class getCancellableOrdersForCustomer_args:
4884
  """
4885
  Attributes:
4886
   - customer_id
4887
   - limit
4888
  """
4889
 
4890
  thrift_spec = (
4891
    None, # 0
4892
    (1, TType.I64, 'customer_id', None, None, ), # 1
4893
    (2, TType.I64, 'limit', None, None, ), # 2
4894
  )
4895
 
4896
  def __init__(self, customer_id=None, limit=None,):
4897
    self.customer_id = customer_id
4898
    self.limit = limit
4899
 
4900
  def read(self, iprot):
4901
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4902
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4903
      return
4904
    iprot.readStructBegin()
4905
    while True:
4906
      (fname, ftype, fid) = iprot.readFieldBegin()
4907
      if ftype == TType.STOP:
4908
        break
4909
      if fid == 1:
4910
        if ftype == TType.I64:
4911
          self.customer_id = iprot.readI64();
4912
        else:
4913
          iprot.skip(ftype)
4914
      elif fid == 2:
4915
        if ftype == TType.I64:
4916
          self.limit = iprot.readI64();
4917
        else:
4918
          iprot.skip(ftype)
4919
      else:
4920
        iprot.skip(ftype)
4921
      iprot.readFieldEnd()
4922
    iprot.readStructEnd()
4923
 
4924
  def write(self, oprot):
4925
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4926
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4927
      return
4928
    oprot.writeStructBegin('getCancellableOrdersForCustomer_args')
3431 rajveer 4929
    if self.customer_id is not None:
1382 varun.gupt 4930
      oprot.writeFieldBegin('customer_id', TType.I64, 1)
4931
      oprot.writeI64(self.customer_id)
4932
      oprot.writeFieldEnd()
3431 rajveer 4933
    if self.limit is not None:
1382 varun.gupt 4934
      oprot.writeFieldBegin('limit', TType.I64, 2)
4935
      oprot.writeI64(self.limit)
4936
      oprot.writeFieldEnd()
4937
    oprot.writeFieldStop()
4938
    oprot.writeStructEnd()
4939
 
3431 rajveer 4940
  def validate(self):
4941
    return
4942
 
4943
 
1382 varun.gupt 4944
  def __repr__(self):
4945
    L = ['%s=%r' % (key, value)
4946
      for key, value in self.__dict__.iteritems()]
4947
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4948
 
4949
  def __eq__(self, other):
4950
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4951
 
4952
  def __ne__(self, other):
4953
    return not (self == other)
4954
 
4955
class getCancellableOrdersForCustomer_result:
4956
  """
4957
  Attributes:
4958
   - success
4959
   - ex
4960
  """
4961
 
4962
  thrift_spec = (
4963
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
4964
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4965
  )
4966
 
4967
  def __init__(self, success=None, ex=None,):
4968
    self.success = success
4969
    self.ex = ex
4970
 
4971
  def read(self, iprot):
4972
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4973
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4974
      return
4975
    iprot.readStructBegin()
4976
    while True:
4977
      (fname, ftype, fid) = iprot.readFieldBegin()
4978
      if ftype == TType.STOP:
4979
        break
4980
      if fid == 0:
4981
        if ftype == TType.LIST:
4982
          self.success = []
3427 chandransh 4983
          (_etype59, _size56) = iprot.readListBegin()
4984
          for _i60 in xrange(_size56):
4985
            _elem61 = iprot.readI64();
4986
            self.success.append(_elem61)
1382 varun.gupt 4987
          iprot.readListEnd()
4988
        else:
4989
          iprot.skip(ftype)
4990
      elif fid == 1:
4991
        if ftype == TType.STRUCT:
4992
          self.ex = TransactionServiceException()
4993
          self.ex.read(iprot)
4994
        else:
4995
          iprot.skip(ftype)
4996
      else:
4997
        iprot.skip(ftype)
4998
      iprot.readFieldEnd()
4999
    iprot.readStructEnd()
5000
 
5001
  def write(self, oprot):
5002
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5003
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5004
      return
5005
    oprot.writeStructBegin('getCancellableOrdersForCustomer_result')
3431 rajveer 5006
    if self.success is not None:
1382 varun.gupt 5007
      oprot.writeFieldBegin('success', TType.LIST, 0)
5008
      oprot.writeListBegin(TType.I64, len(self.success))
3427 chandransh 5009
      for iter62 in self.success:
5010
        oprot.writeI64(iter62)
1382 varun.gupt 5011
      oprot.writeListEnd()
5012
      oprot.writeFieldEnd()
3431 rajveer 5013
    if self.ex is not None:
1382 varun.gupt 5014
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5015
      self.ex.write(oprot)
5016
      oprot.writeFieldEnd()
5017
    oprot.writeFieldStop()
5018
    oprot.writeStructEnd()
5019
 
3431 rajveer 5020
  def validate(self):
5021
    return
5022
 
5023
 
1382 varun.gupt 5024
  def __repr__(self):
5025
    L = ['%s=%r' % (key, value)
5026
      for key, value in self.__dict__.iteritems()]
5027
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5028
 
5029
  def __eq__(self, other):
5030
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5031
 
5032
  def __ne__(self, other):
5033
    return not (self == other)
5034
 
483 rajveer 5035
class changeOrderStatus_args:
94 ashish 5036
  """
5037
  Attributes:
483 rajveer 5038
   - orderId
5039
   - status
5040
   - description
94 ashish 5041
  """
5042
 
5043
  thrift_spec = (
5044
    None, # 0
483 rajveer 5045
    (1, TType.I64, 'orderId', None, None, ), # 1
5046
    (2, TType.I32, 'status', None, None, ), # 2
5047
    (3, TType.STRING, 'description', None, None, ), # 3
94 ashish 5048
  )
5049
 
483 rajveer 5050
  def __init__(self, orderId=None, status=None, description=None,):
5051
    self.orderId = orderId
5052
    self.status = status
5053
    self.description = description
94 ashish 5054
 
5055
  def read(self, iprot):
5056
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5057
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5058
      return
5059
    iprot.readStructBegin()
5060
    while True:
5061
      (fname, ftype, fid) = iprot.readFieldBegin()
5062
      if ftype == TType.STOP:
5063
        break
5064
      if fid == 1:
5065
        if ftype == TType.I64:
483 rajveer 5066
          self.orderId = iprot.readI64();
94 ashish 5067
        else:
5068
          iprot.skip(ftype)
5069
      elif fid == 2:
483 rajveer 5070
        if ftype == TType.I32:
5071
          self.status = iprot.readI32();
94 ashish 5072
        else:
5073
          iprot.skip(ftype)
483 rajveer 5074
      elif fid == 3:
5075
        if ftype == TType.STRING:
5076
          self.description = iprot.readString();
5077
        else:
5078
          iprot.skip(ftype)
94 ashish 5079
      else:
5080
        iprot.skip(ftype)
5081
      iprot.readFieldEnd()
5082
    iprot.readStructEnd()
5083
 
5084
  def write(self, oprot):
5085
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5086
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5087
      return
483 rajveer 5088
    oprot.writeStructBegin('changeOrderStatus_args')
3431 rajveer 5089
    if self.orderId is not None:
483 rajveer 5090
      oprot.writeFieldBegin('orderId', TType.I64, 1)
5091
      oprot.writeI64(self.orderId)
94 ashish 5092
      oprot.writeFieldEnd()
3431 rajveer 5093
    if self.status is not None:
483 rajveer 5094
      oprot.writeFieldBegin('status', TType.I32, 2)
5095
      oprot.writeI32(self.status)
94 ashish 5096
      oprot.writeFieldEnd()
3431 rajveer 5097
    if self.description is not None:
483 rajveer 5098
      oprot.writeFieldBegin('description', TType.STRING, 3)
5099
      oprot.writeString(self.description)
5100
      oprot.writeFieldEnd()
94 ashish 5101
    oprot.writeFieldStop()
5102
    oprot.writeStructEnd()
5103
 
3431 rajveer 5104
  def validate(self):
5105
    return
5106
 
5107
 
94 ashish 5108
  def __repr__(self):
5109
    L = ['%s=%r' % (key, value)
5110
      for key, value in self.__dict__.iteritems()]
5111
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5112
 
5113
  def __eq__(self, other):
5114
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5115
 
5116
  def __ne__(self, other):
5117
    return not (self == other)
5118
 
483 rajveer 5119
class changeOrderStatus_result:
94 ashish 5120
  """
5121
  Attributes:
5122
   - success
5123
   - ex
5124
  """
5125
 
5126
  thrift_spec = (
5127
    (0, TType.BOOL, 'success', None, None, ), # 0
5128
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5129
  )
5130
 
5131
  def __init__(self, success=None, ex=None,):
5132
    self.success = success
5133
    self.ex = ex
5134
 
5135
  def read(self, iprot):
5136
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5137
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5138
      return
5139
    iprot.readStructBegin()
5140
    while True:
5141
      (fname, ftype, fid) = iprot.readFieldBegin()
5142
      if ftype == TType.STOP:
5143
        break
5144
      if fid == 0:
5145
        if ftype == TType.BOOL:
5146
          self.success = iprot.readBool();
5147
        else:
5148
          iprot.skip(ftype)
5149
      elif fid == 1:
5150
        if ftype == TType.STRUCT:
5151
          self.ex = TransactionServiceException()
5152
          self.ex.read(iprot)
5153
        else:
5154
          iprot.skip(ftype)
5155
      else:
5156
        iprot.skip(ftype)
5157
      iprot.readFieldEnd()
5158
    iprot.readStructEnd()
5159
 
5160
  def write(self, oprot):
5161
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5162
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5163
      return
483 rajveer 5164
    oprot.writeStructBegin('changeOrderStatus_result')
3431 rajveer 5165
    if self.success is not None:
94 ashish 5166
      oprot.writeFieldBegin('success', TType.BOOL, 0)
5167
      oprot.writeBool(self.success)
5168
      oprot.writeFieldEnd()
3431 rajveer 5169
    if self.ex is not None:
94 ashish 5170
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5171
      self.ex.write(oprot)
5172
      oprot.writeFieldEnd()
5173
    oprot.writeFieldStop()
5174
    oprot.writeStructEnd()
5175
 
3431 rajveer 5176
  def validate(self):
5177
    return
5178
 
5179
 
94 ashish 5180
  def __repr__(self):
5181
    L = ['%s=%r' % (key, value)
5182
      for key, value in self.__dict__.iteritems()]
5183
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5184
 
5185
  def __eq__(self, other):
5186
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5187
 
5188
  def __ne__(self, other):
5189
    return not (self == other)
5190
 
3064 chandransh 5191
class getOrdersForTransaction_args:
494 rajveer 5192
  """
5193
  Attributes:
3064 chandransh 5194
   - transactionId
5195
   - customerId
494 rajveer 5196
  """
5197
 
5198
  thrift_spec = (
5199
    None, # 0
3064 chandransh 5200
    (1, TType.I64, 'transactionId', None, None, ), # 1
5201
    (2, TType.I64, 'customerId', None, None, ), # 2
494 rajveer 5202
  )
5203
 
3064 chandransh 5204
  def __init__(self, transactionId=None, customerId=None,):
5205
    self.transactionId = transactionId
5206
    self.customerId = customerId
494 rajveer 5207
 
5208
  def read(self, iprot):
5209
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5210
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5211
      return
5212
    iprot.readStructBegin()
5213
    while True:
5214
      (fname, ftype, fid) = iprot.readFieldBegin()
5215
      if ftype == TType.STOP:
5216
        break
5217
      if fid == 1:
5218
        if ftype == TType.I64:
3064 chandransh 5219
          self.transactionId = iprot.readI64();
494 rajveer 5220
        else:
5221
          iprot.skip(ftype)
5222
      elif fid == 2:
3064 chandransh 5223
        if ftype == TType.I64:
5224
          self.customerId = iprot.readI64();
494 rajveer 5225
        else:
5226
          iprot.skip(ftype)
5227
      else:
5228
        iprot.skip(ftype)
5229
      iprot.readFieldEnd()
5230
    iprot.readStructEnd()
5231
 
5232
  def write(self, oprot):
5233
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5234
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5235
      return
3064 chandransh 5236
    oprot.writeStructBegin('getOrdersForTransaction_args')
3431 rajveer 5237
    if self.transactionId is not None:
3064 chandransh 5238
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
5239
      oprot.writeI64(self.transactionId)
494 rajveer 5240
      oprot.writeFieldEnd()
3431 rajveer 5241
    if self.customerId is not None:
3064 chandransh 5242
      oprot.writeFieldBegin('customerId', TType.I64, 2)
5243
      oprot.writeI64(self.customerId)
494 rajveer 5244
      oprot.writeFieldEnd()
5245
    oprot.writeFieldStop()
5246
    oprot.writeStructEnd()
5247
 
3431 rajveer 5248
  def validate(self):
5249
    return
5250
 
5251
 
494 rajveer 5252
  def __repr__(self):
5253
    L = ['%s=%r' % (key, value)
5254
      for key, value in self.__dict__.iteritems()]
5255
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5256
 
5257
  def __eq__(self, other):
5258
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5259
 
5260
  def __ne__(self, other):
5261
    return not (self == other)
5262
 
3064 chandransh 5263
class getOrdersForTransaction_result:
494 rajveer 5264
  """
5265
  Attributes:
5266
   - success
5267
   - ex
5268
  """
5269
 
5270
  thrift_spec = (
3064 chandransh 5271
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
494 rajveer 5272
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5273
  )
5274
 
5275
  def __init__(self, success=None, ex=None,):
5276
    self.success = success
5277
    self.ex = ex
5278
 
5279
  def read(self, iprot):
5280
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5281
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5282
      return
5283
    iprot.readStructBegin()
5284
    while True:
5285
      (fname, ftype, fid) = iprot.readFieldBegin()
5286
      if ftype == TType.STOP:
5287
        break
5288
      if fid == 0:
3064 chandransh 5289
        if ftype == TType.LIST:
5290
          self.success = []
3427 chandransh 5291
          (_etype66, _size63) = iprot.readListBegin()
5292
          for _i67 in xrange(_size63):
5293
            _elem68 = Order()
5294
            _elem68.read(iprot)
5295
            self.success.append(_elem68)
3064 chandransh 5296
          iprot.readListEnd()
494 rajveer 5297
        else:
5298
          iprot.skip(ftype)
5299
      elif fid == 1:
5300
        if ftype == TType.STRUCT:
5301
          self.ex = TransactionServiceException()
5302
          self.ex.read(iprot)
5303
        else:
5304
          iprot.skip(ftype)
5305
      else:
5306
        iprot.skip(ftype)
5307
      iprot.readFieldEnd()
5308
    iprot.readStructEnd()
5309
 
5310
  def write(self, oprot):
5311
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5312
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5313
      return
3064 chandransh 5314
    oprot.writeStructBegin('getOrdersForTransaction_result')
3431 rajveer 5315
    if self.success is not None:
3064 chandransh 5316
      oprot.writeFieldBegin('success', TType.LIST, 0)
5317
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 5318
      for iter69 in self.success:
5319
        iter69.write(oprot)
3064 chandransh 5320
      oprot.writeListEnd()
494 rajveer 5321
      oprot.writeFieldEnd()
3431 rajveer 5322
    if self.ex is not None:
494 rajveer 5323
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5324
      self.ex.write(oprot)
5325
      oprot.writeFieldEnd()
5326
    oprot.writeFieldStop()
5327
    oprot.writeStructEnd()
5328
 
3431 rajveer 5329
  def validate(self):
5330
    return
5331
 
5332
 
494 rajveer 5333
  def __repr__(self):
5334
    L = ['%s=%r' % (key, value)
5335
      for key, value in self.__dict__.iteritems()]
5336
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5337
 
5338
  def __eq__(self, other):
5339
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5340
 
5341
  def __ne__(self, other):
5342
    return not (self == other)
5343
 
3064 chandransh 5344
class getOrdersForCustomer_args:
1149 chandransh 5345
  """
5346
  Attributes:
3064 chandransh 5347
   - customerId
5348
   - from_date
5349
   - to_date
5350
   - statuses
1149 chandransh 5351
  """
5352
 
5353
  thrift_spec = (
5354
    None, # 0
3064 chandransh 5355
    (1, TType.I64, 'customerId', None, None, ), # 1
5356
    (2, TType.I64, 'from_date', None, None, ), # 2
5357
    (3, TType.I64, 'to_date', None, None, ), # 3
5358
    (4, TType.LIST, 'statuses', (TType.I32,None), None, ), # 4
1149 chandransh 5359
  )
5360
 
3064 chandransh 5361
  def __init__(self, customerId=None, from_date=None, to_date=None, statuses=None,):
5362
    self.customerId = customerId
5363
    self.from_date = from_date
5364
    self.to_date = to_date
5365
    self.statuses = statuses
1149 chandransh 5366
 
5367
  def read(self, iprot):
5368
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5369
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5370
      return
5371
    iprot.readStructBegin()
5372
    while True:
5373
      (fname, ftype, fid) = iprot.readFieldBegin()
5374
      if ftype == TType.STOP:
5375
        break
5376
      if fid == 1:
5377
        if ftype == TType.I64:
3064 chandransh 5378
          self.customerId = iprot.readI64();
1149 chandransh 5379
        else:
5380
          iprot.skip(ftype)
5381
      elif fid == 2:
5382
        if ftype == TType.I64:
3064 chandransh 5383
          self.from_date = iprot.readI64();
1149 chandransh 5384
        else:
5385
          iprot.skip(ftype)
2783 chandransh 5386
      elif fid == 3:
5387
        if ftype == TType.I64:
3064 chandransh 5388
          self.to_date = iprot.readI64();
2783 chandransh 5389
        else:
5390
          iprot.skip(ftype)
5391
      elif fid == 4:
3064 chandransh 5392
        if ftype == TType.LIST:
5393
          self.statuses = []
3427 chandransh 5394
          (_etype73, _size70) = iprot.readListBegin()
5395
          for _i74 in xrange(_size70):
5396
            _elem75 = iprot.readI32();
5397
            self.statuses.append(_elem75)
3064 chandransh 5398
          iprot.readListEnd()
2783 chandransh 5399
        else:
5400
          iprot.skip(ftype)
1149 chandransh 5401
      else:
5402
        iprot.skip(ftype)
5403
      iprot.readFieldEnd()
5404
    iprot.readStructEnd()
5405
 
5406
  def write(self, oprot):
5407
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5408
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5409
      return
3064 chandransh 5410
    oprot.writeStructBegin('getOrdersForCustomer_args')
3431 rajveer 5411
    if self.customerId is not None:
3064 chandransh 5412
      oprot.writeFieldBegin('customerId', TType.I64, 1)
5413
      oprot.writeI64(self.customerId)
1149 chandransh 5414
      oprot.writeFieldEnd()
3431 rajveer 5415
    if self.from_date is not None:
3064 chandransh 5416
      oprot.writeFieldBegin('from_date', TType.I64, 2)
5417
      oprot.writeI64(self.from_date)
1149 chandransh 5418
      oprot.writeFieldEnd()
3431 rajveer 5419
    if self.to_date is not None:
3064 chandransh 5420
      oprot.writeFieldBegin('to_date', TType.I64, 3)
5421
      oprot.writeI64(self.to_date)
2783 chandransh 5422
      oprot.writeFieldEnd()
3431 rajveer 5423
    if self.statuses is not None:
3064 chandransh 5424
      oprot.writeFieldBegin('statuses', TType.LIST, 4)
5425
      oprot.writeListBegin(TType.I32, len(self.statuses))
3427 chandransh 5426
      for iter76 in self.statuses:
5427
        oprot.writeI32(iter76)
3064 chandransh 5428
      oprot.writeListEnd()
2783 chandransh 5429
      oprot.writeFieldEnd()
1149 chandransh 5430
    oprot.writeFieldStop()
5431
    oprot.writeStructEnd()
5432
 
3431 rajveer 5433
  def validate(self):
5434
    return
5435
 
5436
 
1149 chandransh 5437
  def __repr__(self):
5438
    L = ['%s=%r' % (key, value)
5439
      for key, value in self.__dict__.iteritems()]
5440
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5441
 
5442
  def __eq__(self, other):
5443
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5444
 
5445
  def __ne__(self, other):
5446
    return not (self == other)
5447
 
3064 chandransh 5448
class getOrdersForCustomer_result:
1149 chandransh 5449
  """
5450
  Attributes:
5451
   - success
5452
   - ex
5453
  """
5454
 
5455
  thrift_spec = (
3064 chandransh 5456
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
1149 chandransh 5457
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5458
  )
5459
 
5460
  def __init__(self, success=None, ex=None,):
5461
    self.success = success
5462
    self.ex = ex
5463
 
5464
  def read(self, iprot):
5465
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5466
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5467
      return
5468
    iprot.readStructBegin()
5469
    while True:
5470
      (fname, ftype, fid) = iprot.readFieldBegin()
5471
      if ftype == TType.STOP:
5472
        break
5473
      if fid == 0:
3064 chandransh 5474
        if ftype == TType.LIST:
5475
          self.success = []
3427 chandransh 5476
          (_etype80, _size77) = iprot.readListBegin()
5477
          for _i81 in xrange(_size77):
5478
            _elem82 = Order()
5479
            _elem82.read(iprot)
5480
            self.success.append(_elem82)
3064 chandransh 5481
          iprot.readListEnd()
1149 chandransh 5482
        else:
5483
          iprot.skip(ftype)
5484
      elif fid == 1:
5485
        if ftype == TType.STRUCT:
5486
          self.ex = TransactionServiceException()
5487
          self.ex.read(iprot)
5488
        else:
5489
          iprot.skip(ftype)
5490
      else:
5491
        iprot.skip(ftype)
5492
      iprot.readFieldEnd()
5493
    iprot.readStructEnd()
5494
 
5495
  def write(self, oprot):
5496
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5497
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5498
      return
3064 chandransh 5499
    oprot.writeStructBegin('getOrdersForCustomer_result')
3431 rajveer 5500
    if self.success is not None:
3064 chandransh 5501
      oprot.writeFieldBegin('success', TType.LIST, 0)
5502
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 5503
      for iter83 in self.success:
5504
        iter83.write(oprot)
3064 chandransh 5505
      oprot.writeListEnd()
1149 chandransh 5506
      oprot.writeFieldEnd()
3431 rajveer 5507
    if self.ex is not None:
1149 chandransh 5508
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5509
      self.ex.write(oprot)
5510
      oprot.writeFieldEnd()
5511
    oprot.writeFieldStop()
5512
    oprot.writeStructEnd()
5513
 
3431 rajveer 5514
  def validate(self):
5515
    return
5516
 
5517
 
1149 chandransh 5518
  def __repr__(self):
5519
    L = ['%s=%r' % (key, value)
5520
      for key, value in self.__dict__.iteritems()]
5521
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5522
 
5523
  def __eq__(self, other):
5524
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5525
 
5526
  def __ne__(self, other):
5527
    return not (self == other)
5528
 
3064 chandransh 5529
class createOrder_args:
921 rajveer 5530
  """
5531
  Attributes:
3064 chandransh 5532
   - order
921 rajveer 5533
  """
5534
 
5535
  thrift_spec = (
5536
    None, # 0
3064 chandransh 5537
    (1, TType.STRUCT, 'order', (Order, Order.thrift_spec), None, ), # 1
921 rajveer 5538
  )
5539
 
3064 chandransh 5540
  def __init__(self, order=None,):
5541
    self.order = order
921 rajveer 5542
 
5543
  def read(self, iprot):
5544
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5545
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5546
      return
5547
    iprot.readStructBegin()
5548
    while True:
5549
      (fname, ftype, fid) = iprot.readFieldBegin()
5550
      if ftype == TType.STOP:
5551
        break
5552
      if fid == 1:
3064 chandransh 5553
        if ftype == TType.STRUCT:
5554
          self.order = Order()
5555
          self.order.read(iprot)
921 rajveer 5556
        else:
5557
          iprot.skip(ftype)
5558
      else:
5559
        iprot.skip(ftype)
5560
      iprot.readFieldEnd()
5561
    iprot.readStructEnd()
5562
 
5563
  def write(self, oprot):
5564
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5565
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5566
      return
3064 chandransh 5567
    oprot.writeStructBegin('createOrder_args')
3431 rajveer 5568
    if self.order is not None:
3064 chandransh 5569
      oprot.writeFieldBegin('order', TType.STRUCT, 1)
5570
      self.order.write(oprot)
921 rajveer 5571
      oprot.writeFieldEnd()
5572
    oprot.writeFieldStop()
5573
    oprot.writeStructEnd()
5574
 
3431 rajveer 5575
  def validate(self):
5576
    return
5577
 
5578
 
921 rajveer 5579
  def __repr__(self):
5580
    L = ['%s=%r' % (key, value)
5581
      for key, value in self.__dict__.iteritems()]
5582
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5583
 
5584
  def __eq__(self, other):
5585
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5586
 
5587
  def __ne__(self, other):
5588
    return not (self == other)
5589
 
3064 chandransh 5590
class createOrder_result:
921 rajveer 5591
  """
5592
  Attributes:
5593
   - success
5594
   - ex
5595
  """
5596
 
5597
  thrift_spec = (
3064 chandransh 5598
    (0, TType.I64, 'success', None, None, ), # 0
921 rajveer 5599
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5600
  )
5601
 
5602
  def __init__(self, success=None, ex=None,):
5603
    self.success = success
5604
    self.ex = ex
5605
 
5606
  def read(self, iprot):
5607
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5608
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5609
      return
5610
    iprot.readStructBegin()
5611
    while True:
5612
      (fname, ftype, fid) = iprot.readFieldBegin()
5613
      if ftype == TType.STOP:
5614
        break
5615
      if fid == 0:
3064 chandransh 5616
        if ftype == TType.I64:
5617
          self.success = iprot.readI64();
921 rajveer 5618
        else:
5619
          iprot.skip(ftype)
5620
      elif fid == 1:
5621
        if ftype == TType.STRUCT:
5622
          self.ex = TransactionServiceException()
5623
          self.ex.read(iprot)
5624
        else:
5625
          iprot.skip(ftype)
5626
      else:
5627
        iprot.skip(ftype)
5628
      iprot.readFieldEnd()
5629
    iprot.readStructEnd()
5630
 
5631
  def write(self, oprot):
5632
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5633
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5634
      return
3064 chandransh 5635
    oprot.writeStructBegin('createOrder_result')
3431 rajveer 5636
    if self.success is not None:
3064 chandransh 5637
      oprot.writeFieldBegin('success', TType.I64, 0)
5638
      oprot.writeI64(self.success)
921 rajveer 5639
      oprot.writeFieldEnd()
3431 rajveer 5640
    if self.ex is not None:
921 rajveer 5641
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5642
      self.ex.write(oprot)
5643
      oprot.writeFieldEnd()
5644
    oprot.writeFieldStop()
5645
    oprot.writeStructEnd()
5646
 
3431 rajveer 5647
  def validate(self):
5648
    return
5649
 
5650
 
921 rajveer 5651
  def __repr__(self):
5652
    L = ['%s=%r' % (key, value)
5653
      for key, value in self.__dict__.iteritems()]
5654
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5655
 
5656
  def __eq__(self, other):
5657
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5658
 
5659
  def __ne__(self, other):
5660
    return not (self == other)
5661
 
3064 chandransh 5662
class getOrder_args:
921 rajveer 5663
  """
5664
  Attributes:
3064 chandransh 5665
   - id
921 rajveer 5666
  """
5667
 
5668
  thrift_spec = (
5669
    None, # 0
3064 chandransh 5670
    (1, TType.I64, 'id', None, None, ), # 1
921 rajveer 5671
  )
5672
 
3064 chandransh 5673
  def __init__(self, id=None,):
5674
    self.id = id
921 rajveer 5675
 
5676
  def read(self, iprot):
5677
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5678
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5679
      return
5680
    iprot.readStructBegin()
5681
    while True:
5682
      (fname, ftype, fid) = iprot.readFieldBegin()
5683
      if ftype == TType.STOP:
5684
        break
5685
      if fid == 1:
5686
        if ftype == TType.I64:
3064 chandransh 5687
          self.id = iprot.readI64();
921 rajveer 5688
        else:
5689
          iprot.skip(ftype)
5690
      else:
5691
        iprot.skip(ftype)
5692
      iprot.readFieldEnd()
5693
    iprot.readStructEnd()
5694
 
5695
  def write(self, oprot):
5696
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5697
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5698
      return
3064 chandransh 5699
    oprot.writeStructBegin('getOrder_args')
3431 rajveer 5700
    if self.id is not None:
3064 chandransh 5701
      oprot.writeFieldBegin('id', TType.I64, 1)
5702
      oprot.writeI64(self.id)
921 rajveer 5703
      oprot.writeFieldEnd()
5704
    oprot.writeFieldStop()
5705
    oprot.writeStructEnd()
5706
 
3431 rajveer 5707
  def validate(self):
5708
    return
5709
 
5710
 
921 rajveer 5711
  def __repr__(self):
5712
    L = ['%s=%r' % (key, value)
5713
      for key, value in self.__dict__.iteritems()]
5714
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5715
 
5716
  def __eq__(self, other):
5717
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5718
 
5719
  def __ne__(self, other):
5720
    return not (self == other)
5721
 
3064 chandransh 5722
class getOrder_result:
921 rajveer 5723
  """
5724
  Attributes:
5725
   - success
5726
   - ex
5727
  """
5728
 
5729
  thrift_spec = (
3064 chandransh 5730
    (0, TType.STRUCT, 'success', (Order, Order.thrift_spec), None, ), # 0
921 rajveer 5731
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5732
  )
5733
 
5734
  def __init__(self, success=None, ex=None,):
5735
    self.success = success
5736
    self.ex = ex
5737
 
5738
  def read(self, iprot):
5739
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5740
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5741
      return
5742
    iprot.readStructBegin()
5743
    while True:
5744
      (fname, ftype, fid) = iprot.readFieldBegin()
5745
      if ftype == TType.STOP:
5746
        break
5747
      if fid == 0:
3064 chandransh 5748
        if ftype == TType.STRUCT:
5749
          self.success = Order()
5750
          self.success.read(iprot)
921 rajveer 5751
        else:
5752
          iprot.skip(ftype)
5753
      elif fid == 1:
5754
        if ftype == TType.STRUCT:
5755
          self.ex = TransactionServiceException()
5756
          self.ex.read(iprot)
5757
        else:
5758
          iprot.skip(ftype)
5759
      else:
5760
        iprot.skip(ftype)
5761
      iprot.readFieldEnd()
5762
    iprot.readStructEnd()
5763
 
5764
  def write(self, oprot):
5765
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5766
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5767
      return
3064 chandransh 5768
    oprot.writeStructBegin('getOrder_result')
3431 rajveer 5769
    if self.success is not None:
3064 chandransh 5770
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
5771
      self.success.write(oprot)
921 rajveer 5772
      oprot.writeFieldEnd()
3431 rajveer 5773
    if self.ex is not None:
921 rajveer 5774
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5775
      self.ex.write(oprot)
5776
      oprot.writeFieldEnd()
5777
    oprot.writeFieldStop()
5778
    oprot.writeStructEnd()
5779
 
3431 rajveer 5780
  def validate(self):
5781
    return
5782
 
5783
 
921 rajveer 5784
  def __repr__(self):
5785
    L = ['%s=%r' % (key, value)
5786
      for key, value in self.__dict__.iteritems()]
5787
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5788
 
5789
  def __eq__(self, other):
5790
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5791
 
5792
  def __ne__(self, other):
5793
    return not (self == other)
5794
 
3064 chandransh 5795
class getLineItemsForOrder_args:
94 ashish 5796
  """
5797
  Attributes:
3064 chandransh 5798
   - orderId
94 ashish 5799
  """
5800
 
5801
  thrift_spec = (
5802
    None, # 0
3064 chandransh 5803
    (1, TType.I64, 'orderId', None, None, ), # 1
94 ashish 5804
  )
5805
 
3064 chandransh 5806
  def __init__(self, orderId=None,):
5807
    self.orderId = orderId
94 ashish 5808
 
5809
  def read(self, iprot):
5810
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5811
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5812
      return
5813
    iprot.readStructBegin()
5814
    while True:
5815
      (fname, ftype, fid) = iprot.readFieldBegin()
5816
      if ftype == TType.STOP:
5817
        break
5818
      if fid == 1:
5819
        if ftype == TType.I64:
3064 chandransh 5820
          self.orderId = iprot.readI64();
94 ashish 5821
        else:
5822
          iprot.skip(ftype)
5823
      else:
5824
        iprot.skip(ftype)
5825
      iprot.readFieldEnd()
5826
    iprot.readStructEnd()
5827
 
5828
  def write(self, oprot):
5829
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5830
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5831
      return
3064 chandransh 5832
    oprot.writeStructBegin('getLineItemsForOrder_args')
3431 rajveer 5833
    if self.orderId is not None:
3064 chandransh 5834
      oprot.writeFieldBegin('orderId', TType.I64, 1)
5835
      oprot.writeI64(self.orderId)
94 ashish 5836
      oprot.writeFieldEnd()
5837
    oprot.writeFieldStop()
5838
    oprot.writeStructEnd()
5839
 
3431 rajveer 5840
  def validate(self):
5841
    return
5842
 
5843
 
94 ashish 5844
  def __repr__(self):
5845
    L = ['%s=%r' % (key, value)
5846
      for key, value in self.__dict__.iteritems()]
5847
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5848
 
5849
  def __eq__(self, other):
5850
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5851
 
5852
  def __ne__(self, other):
5853
    return not (self == other)
5854
 
3064 chandransh 5855
class getLineItemsForOrder_result:
94 ashish 5856
  """
5857
  Attributes:
5858
   - success
5859
   - ex
5860
  """
5861
 
5862
  thrift_spec = (
3064 chandransh 5863
    (0, TType.LIST, 'success', (TType.STRUCT,(LineItem, LineItem.thrift_spec)), None, ), # 0
94 ashish 5864
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5865
  )
5866
 
5867
  def __init__(self, success=None, ex=None,):
5868
    self.success = success
5869
    self.ex = ex
5870
 
5871
  def read(self, iprot):
5872
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5873
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5874
      return
5875
    iprot.readStructBegin()
5876
    while True:
5877
      (fname, ftype, fid) = iprot.readFieldBegin()
5878
      if ftype == TType.STOP:
5879
        break
5880
      if fid == 0:
483 rajveer 5881
        if ftype == TType.LIST:
5882
          self.success = []
3427 chandransh 5883
          (_etype87, _size84) = iprot.readListBegin()
5884
          for _i88 in xrange(_size84):
5885
            _elem89 = LineItem()
5886
            _elem89.read(iprot)
5887
            self.success.append(_elem89)
483 rajveer 5888
          iprot.readListEnd()
94 ashish 5889
        else:
5890
          iprot.skip(ftype)
5891
      elif fid == 1:
5892
        if ftype == TType.STRUCT:
5893
          self.ex = TransactionServiceException()
5894
          self.ex.read(iprot)
5895
        else:
5896
          iprot.skip(ftype)
5897
      else:
5898
        iprot.skip(ftype)
5899
      iprot.readFieldEnd()
5900
    iprot.readStructEnd()
5901
 
5902
  def write(self, oprot):
5903
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5904
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5905
      return
3064 chandransh 5906
    oprot.writeStructBegin('getLineItemsForOrder_result')
3431 rajveer 5907
    if self.success is not None:
483 rajveer 5908
      oprot.writeFieldBegin('success', TType.LIST, 0)
5909
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 5910
      for iter90 in self.success:
5911
        iter90.write(oprot)
483 rajveer 5912
      oprot.writeListEnd()
94 ashish 5913
      oprot.writeFieldEnd()
3431 rajveer 5914
    if self.ex is not None:
94 ashish 5915
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5916
      self.ex.write(oprot)
5917
      oprot.writeFieldEnd()
5918
    oprot.writeFieldStop()
5919
    oprot.writeStructEnd()
5920
 
3431 rajveer 5921
  def validate(self):
5922
    return
5923
 
5924
 
94 ashish 5925
  def __repr__(self):
5926
    L = ['%s=%r' % (key, value)
5927
      for key, value in self.__dict__.iteritems()]
5928
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5929
 
5930
  def __eq__(self, other):
5931
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5932
 
5933
  def __ne__(self, other):
5934
    return not (self == other)
5935
 
3064 chandransh 5936
class getOrderForCustomer_args:
94 ashish 5937
  """
5938
  Attributes:
3064 chandransh 5939
   - orderId
483 rajveer 5940
   - customerId
94 ashish 5941
  """
5942
 
5943
  thrift_spec = (
5944
    None, # 0
3064 chandransh 5945
    (1, TType.I64, 'orderId', None, None, ), # 1
5946
    (2, TType.I64, 'customerId', None, None, ), # 2
94 ashish 5947
  )
5948
 
3064 chandransh 5949
  def __init__(self, orderId=None, customerId=None,):
5950
    self.orderId = orderId
483 rajveer 5951
    self.customerId = customerId
94 ashish 5952
 
5953
  def read(self, iprot):
5954
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5955
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5956
      return
5957
    iprot.readStructBegin()
5958
    while True:
5959
      (fname, ftype, fid) = iprot.readFieldBegin()
5960
      if ftype == TType.STOP:
5961
        break
5962
      if fid == 1:
5963
        if ftype == TType.I64:
3064 chandransh 5964
          self.orderId = iprot.readI64();
94 ashish 5965
        else:
5966
          iprot.skip(ftype)
5967
      elif fid == 2:
5968
        if ftype == TType.I64:
3064 chandransh 5969
          self.customerId = iprot.readI64();
94 ashish 5970
        else:
5971
          iprot.skip(ftype)
5972
      else:
5973
        iprot.skip(ftype)
5974
      iprot.readFieldEnd()
5975
    iprot.readStructEnd()
5976
 
5977
  def write(self, oprot):
5978
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5979
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5980
      return
3064 chandransh 5981
    oprot.writeStructBegin('getOrderForCustomer_args')
3431 rajveer 5982
    if self.orderId is not None:
3064 chandransh 5983
      oprot.writeFieldBegin('orderId', TType.I64, 1)
5984
      oprot.writeI64(self.orderId)
5985
      oprot.writeFieldEnd()
3431 rajveer 5986
    if self.customerId is not None:
3064 chandransh 5987
      oprot.writeFieldBegin('customerId', TType.I64, 2)
483 rajveer 5988
      oprot.writeI64(self.customerId)
94 ashish 5989
      oprot.writeFieldEnd()
5990
    oprot.writeFieldStop()
5991
    oprot.writeStructEnd()
5992
 
3431 rajveer 5993
  def validate(self):
5994
    return
5995
 
5996
 
94 ashish 5997
  def __repr__(self):
5998
    L = ['%s=%r' % (key, value)
5999
      for key, value in self.__dict__.iteritems()]
6000
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6001
 
6002
  def __eq__(self, other):
6003
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6004
 
6005
  def __ne__(self, other):
6006
    return not (self == other)
6007
 
3064 chandransh 6008
class getOrderForCustomer_result:
94 ashish 6009
  """
6010
  Attributes:
6011
   - success
6012
   - ex
6013
  """
6014
 
6015
  thrift_spec = (
3064 chandransh 6016
    (0, TType.STRUCT, 'success', (Order, Order.thrift_spec), None, ), # 0
94 ashish 6017
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
6018
  )
6019
 
6020
  def __init__(self, success=None, ex=None,):
6021
    self.success = success
6022
    self.ex = ex
6023
 
6024
  def read(self, iprot):
6025
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6026
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6027
      return
6028
    iprot.readStructBegin()
6029
    while True:
6030
      (fname, ftype, fid) = iprot.readFieldBegin()
6031
      if ftype == TType.STOP:
6032
        break
6033
      if fid == 0:
3064 chandransh 6034
        if ftype == TType.STRUCT:
6035
          self.success = Order()
6036
          self.success.read(iprot)
94 ashish 6037
        else:
6038
          iprot.skip(ftype)
6039
      elif fid == 1:
6040
        if ftype == TType.STRUCT:
6041
          self.ex = TransactionServiceException()
6042
          self.ex.read(iprot)
6043
        else:
6044
          iprot.skip(ftype)
6045
      else:
6046
        iprot.skip(ftype)
6047
      iprot.readFieldEnd()
6048
    iprot.readStructEnd()
6049
 
6050
  def write(self, oprot):
6051
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6052
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6053
      return
3064 chandransh 6054
    oprot.writeStructBegin('getOrderForCustomer_result')
3431 rajveer 6055
    if self.success is not None:
3064 chandransh 6056
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
6057
      self.success.write(oprot)
94 ashish 6058
      oprot.writeFieldEnd()
3431 rajveer 6059
    if self.ex is not None:
94 ashish 6060
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
6061
      self.ex.write(oprot)
6062
      oprot.writeFieldEnd()
6063
    oprot.writeFieldStop()
6064
    oprot.writeStructEnd()
6065
 
3431 rajveer 6066
  def validate(self):
6067
    return
6068
 
6069
 
94 ashish 6070
  def __repr__(self):
6071
    L = ['%s=%r' % (key, value)
6072
      for key, value in self.__dict__.iteritems()]
6073
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6074
 
6075
  def __eq__(self, other):
6076
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6077
 
6078
  def __ne__(self, other):
6079
    return not (self == other)
6080
 
3064 chandransh 6081
class getAlerts_args:
94 ashish 6082
  """
6083
  Attributes:
3064 chandransh 6084
   - orderId
6085
   - valid
94 ashish 6086
  """
6087
 
6088
  thrift_spec = (
6089
    None, # 0
3064 chandransh 6090
    (1, TType.I64, 'orderId', None, None, ), # 1
6091
    (2, TType.BOOL, 'valid', None, None, ), # 2
94 ashish 6092
  )
6093
 
3064 chandransh 6094
  def __init__(self, orderId=None, valid=None,):
6095
    self.orderId = orderId
6096
    self.valid = valid
94 ashish 6097
 
6098
  def read(self, iprot):
6099
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6100
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6101
      return
6102
    iprot.readStructBegin()
6103
    while True:
6104
      (fname, ftype, fid) = iprot.readFieldBegin()
6105
      if ftype == TType.STOP:
6106
        break
6107
      if fid == 1:
3064 chandransh 6108
        if ftype == TType.I64:
6109
          self.orderId = iprot.readI64();
94 ashish 6110
        else:
6111
          iprot.skip(ftype)
3064 chandransh 6112
      elif fid == 2:
6113
        if ftype == TType.BOOL:
6114
          self.valid = iprot.readBool();
6115
        else:
6116
          iprot.skip(ftype)
94 ashish 6117
      else:
6118
        iprot.skip(ftype)
6119
      iprot.readFieldEnd()
6120
    iprot.readStructEnd()
6121
 
6122
  def write(self, oprot):
6123
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6124
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6125
      return
3064 chandransh 6126
    oprot.writeStructBegin('getAlerts_args')
3431 rajveer 6127
    if self.orderId is not None:
3064 chandransh 6128
      oprot.writeFieldBegin('orderId', TType.I64, 1)
6129
      oprot.writeI64(self.orderId)
94 ashish 6130
      oprot.writeFieldEnd()
3431 rajveer 6131
    if self.valid is not None:
3064 chandransh 6132
      oprot.writeFieldBegin('valid', TType.BOOL, 2)
6133
      oprot.writeBool(self.valid)
6134
      oprot.writeFieldEnd()
94 ashish 6135
    oprot.writeFieldStop()
6136
    oprot.writeStructEnd()
6137
 
3431 rajveer 6138
  def validate(self):
6139
    return
6140
 
6141
 
94 ashish 6142
  def __repr__(self):
6143
    L = ['%s=%r' % (key, value)
6144
      for key, value in self.__dict__.iteritems()]
6145
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6146
 
6147
  def __eq__(self, other):
6148
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6149
 
6150
  def __ne__(self, other):
6151
    return not (self == other)
6152
 
3064 chandransh 6153
class getAlerts_result:
94 ashish 6154
  """
6155
  Attributes:
6156
   - success
6157
  """
6158
 
6159
  thrift_spec = (
3064 chandransh 6160
    (0, TType.LIST, 'success', (TType.STRUCT,(Alert, Alert.thrift_spec)), None, ), # 0
94 ashish 6161
  )
6162
 
3064 chandransh 6163
  def __init__(self, success=None,):
94 ashish 6164
    self.success = success
6165
 
6166
  def read(self, iprot):
6167
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6168
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6169
      return
6170
    iprot.readStructBegin()
6171
    while True:
6172
      (fname, ftype, fid) = iprot.readFieldBegin()
6173
      if ftype == TType.STOP:
6174
        break
6175
      if fid == 0:
3064 chandransh 6176
        if ftype == TType.LIST:
6177
          self.success = []
3427 chandransh 6178
          (_etype94, _size91) = iprot.readListBegin()
6179
          for _i95 in xrange(_size91):
6180
            _elem96 = Alert()
6181
            _elem96.read(iprot)
6182
            self.success.append(_elem96)
3064 chandransh 6183
          iprot.readListEnd()
94 ashish 6184
        else:
6185
          iprot.skip(ftype)
6186
      else:
6187
        iprot.skip(ftype)
6188
      iprot.readFieldEnd()
6189
    iprot.readStructEnd()
6190
 
6191
  def write(self, oprot):
6192
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6193
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6194
      return
3064 chandransh 6195
    oprot.writeStructBegin('getAlerts_result')
3431 rajveer 6196
    if self.success is not None:
3064 chandransh 6197
      oprot.writeFieldBegin('success', TType.LIST, 0)
6198
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 6199
      for iter97 in self.success:
6200
        iter97.write(oprot)
3064 chandransh 6201
      oprot.writeListEnd()
94 ashish 6202
      oprot.writeFieldEnd()
6203
    oprot.writeFieldStop()
6204
    oprot.writeStructEnd()
6205
 
3431 rajveer 6206
  def validate(self):
6207
    return
6208
 
6209
 
94 ashish 6210
  def __repr__(self):
6211
    L = ['%s=%r' % (key, value)
6212
      for key, value in self.__dict__.iteritems()]
6213
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6214
 
6215
  def __eq__(self, other):
6216
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6217
 
6218
  def __ne__(self, other):
6219
    return not (self == other)
6220
 
3064 chandransh 6221
class setAlert_args:
94 ashish 6222
  """
6223
  Attributes:
3064 chandransh 6224
   - orderId
6225
   - unset
6226
   - type
6227
   - comment
94 ashish 6228
  """
6229
 
6230
  thrift_spec = (
6231
    None, # 0
3064 chandransh 6232
    (1, TType.I64, 'orderId', None, None, ), # 1
6233
    (2, TType.BOOL, 'unset', None, None, ), # 2
6234
    (3, TType.I64, 'type', None, None, ), # 3
6235
    (4, TType.STRING, 'comment', None, None, ), # 4
94 ashish 6236
  )
6237
 
3064 chandransh 6238
  def __init__(self, orderId=None, unset=None, type=None, comment=None,):
6239
    self.orderId = orderId
6240
    self.unset = unset
6241
    self.type = type
6242
    self.comment = comment
94 ashish 6243
 
6244
  def read(self, iprot):
6245
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6246
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6247
      return
6248
    iprot.readStructBegin()
6249
    while True:
6250
      (fname, ftype, fid) = iprot.readFieldBegin()
6251
      if ftype == TType.STOP:
6252
        break
6253
      if fid == 1:
6254
        if ftype == TType.I64:
3064 chandransh 6255
          self.orderId = iprot.readI64();
94 ashish 6256
        else:
6257
          iprot.skip(ftype)
3064 chandransh 6258
      elif fid == 2:
6259
        if ftype == TType.BOOL:
6260
          self.unset = iprot.readBool();
6261
        else:
6262
          iprot.skip(ftype)
6263
      elif fid == 3:
6264
        if ftype == TType.I64:
6265
          self.type = iprot.readI64();
6266
        else:
6267
          iprot.skip(ftype)
6268
      elif fid == 4:
6269
        if ftype == TType.STRING:
6270
          self.comment = iprot.readString();
6271
        else:
6272
          iprot.skip(ftype)
94 ashish 6273
      else:
6274
        iprot.skip(ftype)
6275
      iprot.readFieldEnd()
6276
    iprot.readStructEnd()
6277
 
6278
  def write(self, oprot):
6279
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6280
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6281
      return
3064 chandransh 6282
    oprot.writeStructBegin('setAlert_args')
3431 rajveer 6283
    if self.orderId is not None:
3064 chandransh 6284
      oprot.writeFieldBegin('orderId', TType.I64, 1)
6285
      oprot.writeI64(self.orderId)
94 ashish 6286
      oprot.writeFieldEnd()
3431 rajveer 6287
    if self.unset is not None:
3064 chandransh 6288
      oprot.writeFieldBegin('unset', TType.BOOL, 2)
6289
      oprot.writeBool(self.unset)
6290
      oprot.writeFieldEnd()
3431 rajveer 6291
    if self.type is not None:
3064 chandransh 6292
      oprot.writeFieldBegin('type', TType.I64, 3)
6293
      oprot.writeI64(self.type)
6294
      oprot.writeFieldEnd()
3431 rajveer 6295
    if self.comment is not None:
3064 chandransh 6296
      oprot.writeFieldBegin('comment', TType.STRING, 4)
6297
      oprot.writeString(self.comment)
6298
      oprot.writeFieldEnd()
94 ashish 6299
    oprot.writeFieldStop()
6300
    oprot.writeStructEnd()
6301
 
3431 rajveer 6302
  def validate(self):
6303
    return
6304
 
6305
 
94 ashish 6306
  def __repr__(self):
6307
    L = ['%s=%r' % (key, value)
6308
      for key, value in self.__dict__.iteritems()]
6309
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6310
 
6311
  def __eq__(self, other):
6312
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6313
 
6314
  def __ne__(self, other):
6315
    return not (self == other)
6316
 
3064 chandransh 6317
class setAlert_result:
6318
 
6319
  thrift_spec = (
6320
  )
6321
 
6322
  def read(self, iprot):
6323
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6324
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6325
      return
6326
    iprot.readStructBegin()
6327
    while True:
6328
      (fname, ftype, fid) = iprot.readFieldBegin()
6329
      if ftype == TType.STOP:
6330
        break
6331
      else:
6332
        iprot.skip(ftype)
6333
      iprot.readFieldEnd()
6334
    iprot.readStructEnd()
6335
 
6336
  def write(self, oprot):
6337
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6338
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6339
      return
6340
    oprot.writeStructBegin('setAlert_result')
6341
    oprot.writeFieldStop()
6342
    oprot.writeStructEnd()
6343
 
3431 rajveer 6344
  def validate(self):
6345
    return
6346
 
6347
 
3064 chandransh 6348
  def __repr__(self):
6349
    L = ['%s=%r' % (key, value)
6350
      for key, value in self.__dict__.iteritems()]
6351
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6352
 
6353
  def __eq__(self, other):
6354
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6355
 
6356
  def __ne__(self, other):
6357
    return not (self == other)
6358
 
6359
class getValidOrderCount_args:
6360
 
6361
  thrift_spec = (
6362
  )
6363
 
6364
  def read(self, iprot):
6365
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6366
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6367
      return
6368
    iprot.readStructBegin()
6369
    while True:
6370
      (fname, ftype, fid) = iprot.readFieldBegin()
6371
      if ftype == TType.STOP:
6372
        break
6373
      else:
6374
        iprot.skip(ftype)
6375
      iprot.readFieldEnd()
6376
    iprot.readStructEnd()
6377
 
6378
  def write(self, oprot):
6379
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6380
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6381
      return
6382
    oprot.writeStructBegin('getValidOrderCount_args')
6383
    oprot.writeFieldStop()
6384
    oprot.writeStructEnd()
6385
 
3431 rajveer 6386
  def validate(self):
6387
    return
6388
 
6389
 
3064 chandransh 6390
  def __repr__(self):
6391
    L = ['%s=%r' % (key, value)
6392
      for key, value in self.__dict__.iteritems()]
6393
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6394
 
6395
  def __eq__(self, other):
6396
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6397
 
6398
  def __ne__(self, other):
6399
    return not (self == other)
6400
 
6401
class getValidOrderCount_result:
94 ashish 6402
  """
6403
  Attributes:
6404
   - success
6405
  """
6406
 
6407
  thrift_spec = (
3064 chandransh 6408
    (0, TType.I64, 'success', None, None, ), # 0
94 ashish 6409
  )
6410
 
3064 chandransh 6411
  def __init__(self, success=None,):
94 ashish 6412
    self.success = success
6413
 
6414
  def read(self, iprot):
6415
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6416
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6417
      return
6418
    iprot.readStructBegin()
6419
    while True:
6420
      (fname, ftype, fid) = iprot.readFieldBegin()
6421
      if ftype == TType.STOP:
6422
        break
6423
      if fid == 0:
3064 chandransh 6424
        if ftype == TType.I64:
6425
          self.success = iprot.readI64();
94 ashish 6426
        else:
6427
          iprot.skip(ftype)
6428
      else:
6429
        iprot.skip(ftype)
6430
      iprot.readFieldEnd()
6431
    iprot.readStructEnd()
6432
 
6433
  def write(self, oprot):
6434
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6435
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6436
      return
3064 chandransh 6437
    oprot.writeStructBegin('getValidOrderCount_result')
3431 rajveer 6438
    if self.success is not None:
3064 chandransh 6439
      oprot.writeFieldBegin('success', TType.I64, 0)
6440
      oprot.writeI64(self.success)
94 ashish 6441
      oprot.writeFieldEnd()
6442
    oprot.writeFieldStop()
6443
    oprot.writeStructEnd()
6444
 
3431 rajveer 6445
  def validate(self):
6446
    return
6447
 
6448
 
94 ashish 6449
  def __repr__(self):
6450
    L = ['%s=%r' % (key, value)
6451
      for key, value in self.__dict__.iteritems()]
6452
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6453
 
6454
  def __eq__(self, other):
6455
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6456
 
6457
  def __ne__(self, other):
6458
    return not (self == other)
6459
 
3064 chandransh 6460
class getNoOfCustomersWithSuccessfulTransaction_args:
6461
 
6462
  thrift_spec = (
6463
  )
6464
 
6465
  def read(self, iprot):
6466
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6467
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6468
      return
6469
    iprot.readStructBegin()
6470
    while True:
6471
      (fname, ftype, fid) = iprot.readFieldBegin()
6472
      if ftype == TType.STOP:
6473
        break
6474
      else:
6475
        iprot.skip(ftype)
6476
      iprot.readFieldEnd()
6477
    iprot.readStructEnd()
6478
 
6479
  def write(self, oprot):
6480
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6481
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6482
      return
6483
    oprot.writeStructBegin('getNoOfCustomersWithSuccessfulTransaction_args')
6484
    oprot.writeFieldStop()
6485
    oprot.writeStructEnd()
6486
 
3431 rajveer 6487
  def validate(self):
6488
    return
6489
 
6490
 
3064 chandransh 6491
  def __repr__(self):
6492
    L = ['%s=%r' % (key, value)
6493
      for key, value in self.__dict__.iteritems()]
6494
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6495
 
6496
  def __eq__(self, other):
6497
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6498
 
6499
  def __ne__(self, other):
6500
    return not (self == other)
6501
 
6502
class getNoOfCustomersWithSuccessfulTransaction_result:
94 ashish 6503
  """
6504
  Attributes:
3064 chandransh 6505
   - success
94 ashish 6506
  """
6507
 
6508
  thrift_spec = (
3064 chandransh 6509
    (0, TType.I64, 'success', None, None, ), # 0
94 ashish 6510
  )
6511
 
3064 chandransh 6512
  def __init__(self, success=None,):
6513
    self.success = success
94 ashish 6514
 
6515
  def read(self, iprot):
6516
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6517
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6518
      return
6519
    iprot.readStructBegin()
6520
    while True:
6521
      (fname, ftype, fid) = iprot.readFieldBegin()
6522
      if ftype == TType.STOP:
6523
        break
3064 chandransh 6524
      if fid == 0:
94 ashish 6525
        if ftype == TType.I64:
3064 chandransh 6526
          self.success = iprot.readI64();
94 ashish 6527
        else:
6528
          iprot.skip(ftype)
6529
      else:
6530
        iprot.skip(ftype)
6531
      iprot.readFieldEnd()
6532
    iprot.readStructEnd()
6533
 
6534
  def write(self, oprot):
6535
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6536
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6537
      return
3064 chandransh 6538
    oprot.writeStructBegin('getNoOfCustomersWithSuccessfulTransaction_result')
3431 rajveer 6539
    if self.success is not None:
3064 chandransh 6540
      oprot.writeFieldBegin('success', TType.I64, 0)
6541
      oprot.writeI64(self.success)
94 ashish 6542
      oprot.writeFieldEnd()
6543
    oprot.writeFieldStop()
6544
    oprot.writeStructEnd()
6545
 
3431 rajveer 6546
  def validate(self):
6547
    return
6548
 
6549
 
94 ashish 6550
  def __repr__(self):
6551
    L = ['%s=%r' % (key, value)
6552
      for key, value in self.__dict__.iteritems()]
6553
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6554
 
6555
  def __eq__(self, other):
6556
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6557
 
6558
  def __ne__(self, other):
6559
    return not (self == other)
6560
 
3064 chandransh 6561
class getValidOrdersAmountRange_args:
6562
 
6563
  thrift_spec = (
6564
  )
6565
 
6566
  def read(self, iprot):
6567
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6568
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6569
      return
6570
    iprot.readStructBegin()
6571
    while True:
6572
      (fname, ftype, fid) = iprot.readFieldBegin()
6573
      if ftype == TType.STOP:
6574
        break
6575
      else:
6576
        iprot.skip(ftype)
6577
      iprot.readFieldEnd()
6578
    iprot.readStructEnd()
6579
 
6580
  def write(self, oprot):
6581
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6582
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6583
      return
6584
    oprot.writeStructBegin('getValidOrdersAmountRange_args')
6585
    oprot.writeFieldStop()
6586
    oprot.writeStructEnd()
6587
 
3431 rajveer 6588
  def validate(self):
6589
    return
6590
 
6591
 
3064 chandransh 6592
  def __repr__(self):
6593
    L = ['%s=%r' % (key, value)
6594
      for key, value in self.__dict__.iteritems()]
6595
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6596
 
6597
  def __eq__(self, other):
6598
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6599
 
6600
  def __ne__(self, other):
6601
    return not (self == other)
6602
 
6603
class getValidOrdersAmountRange_result:
94 ashish 6604
  """
6605
  Attributes:
6606
   - success
6607
  """
6608
 
6609
  thrift_spec = (
3064 chandransh 6610
    (0, TType.LIST, 'success', (TType.DOUBLE,None), None, ), # 0
94 ashish 6611
  )
6612
 
3064 chandransh 6613
  def __init__(self, success=None,):
94 ashish 6614
    self.success = success
6615
 
6616
  def read(self, iprot):
6617
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6618
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6619
      return
6620
    iprot.readStructBegin()
6621
    while True:
6622
      (fname, ftype, fid) = iprot.readFieldBegin()
6623
      if ftype == TType.STOP:
6624
        break
6625
      if fid == 0:
483 rajveer 6626
        if ftype == TType.LIST:
6627
          self.success = []
3427 chandransh 6628
          (_etype101, _size98) = iprot.readListBegin()
6629
          for _i102 in xrange(_size98):
6630
            _elem103 = iprot.readDouble();
6631
            self.success.append(_elem103)
483 rajveer 6632
          iprot.readListEnd()
94 ashish 6633
        else:
6634
          iprot.skip(ftype)
6635
      else:
6636
        iprot.skip(ftype)
6637
      iprot.readFieldEnd()
6638
    iprot.readStructEnd()
6639
 
6640
  def write(self, oprot):
6641
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6642
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6643
      return
3064 chandransh 6644
    oprot.writeStructBegin('getValidOrdersAmountRange_result')
3431 rajveer 6645
    if self.success is not None:
483 rajveer 6646
      oprot.writeFieldBegin('success', TType.LIST, 0)
3064 chandransh 6647
      oprot.writeListBegin(TType.DOUBLE, len(self.success))
3427 chandransh 6648
      for iter104 in self.success:
6649
        oprot.writeDouble(iter104)
483 rajveer 6650
      oprot.writeListEnd()
94 ashish 6651
      oprot.writeFieldEnd()
6652
    oprot.writeFieldStop()
6653
    oprot.writeStructEnd()
6654
 
3431 rajveer 6655
  def validate(self):
6656
    return
6657
 
6658
 
94 ashish 6659
  def __repr__(self):
6660
    L = ['%s=%r' % (key, value)
6661
      for key, value in self.__dict__.iteritems()]
6662
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6663
 
6664
  def __eq__(self, other):
6665
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6666
 
6667
  def __ne__(self, other):
6668
    return not (self == other)
6669
 
3064 chandransh 6670
class getValidOrders_args:
1528 ankur.sing 6671
  """
6672
  Attributes:
3064 chandransh 6673
   - limit
1528 ankur.sing 6674
  """
6675
 
6676
  thrift_spec = (
6677
    None, # 0
3064 chandransh 6678
    (1, TType.I64, 'limit', None, None, ), # 1
1528 ankur.sing 6679
  )
6680
 
3064 chandransh 6681
  def __init__(self, limit=None,):
6682
    self.limit = limit
1528 ankur.sing 6683
 
6684
  def read(self, iprot):
6685
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6686
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6687
      return
6688
    iprot.readStructBegin()
6689
    while True:
6690
      (fname, ftype, fid) = iprot.readFieldBegin()
6691
      if ftype == TType.STOP:
6692
        break
6693
      if fid == 1:
6694
        if ftype == TType.I64:
3064 chandransh 6695
          self.limit = iprot.readI64();
1528 ankur.sing 6696
        else:
6697
          iprot.skip(ftype)
6698
      else:
6699
        iprot.skip(ftype)
6700
      iprot.readFieldEnd()
6701
    iprot.readStructEnd()
6702
 
6703
  def write(self, oprot):
6704
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6705
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6706
      return
3064 chandransh 6707
    oprot.writeStructBegin('getValidOrders_args')
3431 rajveer 6708
    if self.limit is not None:
3064 chandransh 6709
      oprot.writeFieldBegin('limit', TType.I64, 1)
6710
      oprot.writeI64(self.limit)
1528 ankur.sing 6711
      oprot.writeFieldEnd()
6712
    oprot.writeFieldStop()
6713
    oprot.writeStructEnd()
6714
 
3431 rajveer 6715
  def validate(self):
6716
    return
6717
 
6718
 
1528 ankur.sing 6719
  def __repr__(self):
6720
    L = ['%s=%r' % (key, value)
6721
      for key, value in self.__dict__.iteritems()]
6722
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6723
 
6724
  def __eq__(self, other):
6725
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6726
 
6727
  def __ne__(self, other):
6728
    return not (self == other)
6729
 
3064 chandransh 6730
class getValidOrders_result:
1528 ankur.sing 6731
  """
6732
  Attributes:
6733
   - success
6734
  """
6735
 
6736
  thrift_spec = (
3064 chandransh 6737
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
1528 ankur.sing 6738
  )
6739
 
3064 chandransh 6740
  def __init__(self, success=None,):
1528 ankur.sing 6741
    self.success = success
6742
 
6743
  def read(self, iprot):
6744
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6745
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6746
      return
6747
    iprot.readStructBegin()
6748
    while True:
6749
      (fname, ftype, fid) = iprot.readFieldBegin()
6750
      if ftype == TType.STOP:
6751
        break
6752
      if fid == 0:
3064 chandransh 6753
        if ftype == TType.LIST:
6754
          self.success = []
3427 chandransh 6755
          (_etype108, _size105) = iprot.readListBegin()
6756
          for _i109 in xrange(_size105):
6757
            _elem110 = Order()
6758
            _elem110.read(iprot)
6759
            self.success.append(_elem110)
3064 chandransh 6760
          iprot.readListEnd()
1528 ankur.sing 6761
        else:
6762
          iprot.skip(ftype)
6763
      else:
6764
        iprot.skip(ftype)
6765
      iprot.readFieldEnd()
6766
    iprot.readStructEnd()
6767
 
6768
  def write(self, oprot):
6769
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6770
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6771
      return
3064 chandransh 6772
    oprot.writeStructBegin('getValidOrders_result')
3431 rajveer 6773
    if self.success is not None:
3064 chandransh 6774
      oprot.writeFieldBegin('success', TType.LIST, 0)
6775
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 6776
      for iter111 in self.success:
6777
        iter111.write(oprot)
3064 chandransh 6778
      oprot.writeListEnd()
1528 ankur.sing 6779
      oprot.writeFieldEnd()
6780
    oprot.writeFieldStop()
6781
    oprot.writeStructEnd()
6782
 
3431 rajveer 6783
  def validate(self):
6784
    return
6785
 
6786
 
1528 ankur.sing 6787
  def __repr__(self):
6788
    L = ['%s=%r' % (key, value)
6789
      for key, value in self.__dict__.iteritems()]
6790
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6791
 
6792
  def __eq__(self, other):
6793
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6794
 
6795
  def __ne__(self, other):
6796
    return not (self == other)
6797
 
1220 chandransh 6798
class batchOrders_args:
6799
  """
6800
  Attributes:
6801
   - warehouseId
6802
  """
6803
 
6804
  thrift_spec = (
6805
    None, # 0
6806
    (1, TType.I64, 'warehouseId', None, None, ), # 1
6807
  )
6808
 
6809
  def __init__(self, warehouseId=None,):
6810
    self.warehouseId = warehouseId
6811
 
6812
  def read(self, iprot):
6813
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6814
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6815
      return
6816
    iprot.readStructBegin()
6817
    while True:
6818
      (fname, ftype, fid) = iprot.readFieldBegin()
6819
      if ftype == TType.STOP:
6820
        break
6821
      if fid == 1:
6822
        if ftype == TType.I64:
6823
          self.warehouseId = iprot.readI64();
6824
        else:
6825
          iprot.skip(ftype)
6826
      else:
6827
        iprot.skip(ftype)
6828
      iprot.readFieldEnd()
6829
    iprot.readStructEnd()
6830
 
6831
  def write(self, oprot):
6832
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6833
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6834
      return
6835
    oprot.writeStructBegin('batchOrders_args')
3431 rajveer 6836
    if self.warehouseId is not None:
1220 chandransh 6837
      oprot.writeFieldBegin('warehouseId', TType.I64, 1)
6838
      oprot.writeI64(self.warehouseId)
6839
      oprot.writeFieldEnd()
6840
    oprot.writeFieldStop()
6841
    oprot.writeStructEnd()
6842
 
3431 rajveer 6843
  def validate(self):
6844
    return
6845
 
6846
 
1220 chandransh 6847
  def __repr__(self):
6848
    L = ['%s=%r' % (key, value)
6849
      for key, value in self.__dict__.iteritems()]
6850
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6851
 
6852
  def __eq__(self, other):
6853
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6854
 
6855
  def __ne__(self, other):
6856
    return not (self == other)
6857
 
6858
class batchOrders_result:
6859
  """
6860
  Attributes:
6861
   - success
6862
   - ex
6863
  """
6864
 
6865
  thrift_spec = (
6866
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
6867
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
6868
  )
6869
 
6870
  def __init__(self, success=None, ex=None,):
6871
    self.success = success
6872
    self.ex = ex
6873
 
6874
  def read(self, iprot):
6875
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6876
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6877
      return
6878
    iprot.readStructBegin()
6879
    while True:
6880
      (fname, ftype, fid) = iprot.readFieldBegin()
6881
      if ftype == TType.STOP:
6882
        break
6883
      if fid == 0:
6884
        if ftype == TType.LIST:
6885
          self.success = []
3427 chandransh 6886
          (_etype115, _size112) = iprot.readListBegin()
6887
          for _i116 in xrange(_size112):
6888
            _elem117 = Order()
6889
            _elem117.read(iprot)
6890
            self.success.append(_elem117)
1220 chandransh 6891
          iprot.readListEnd()
6892
        else:
6893
          iprot.skip(ftype)
6894
      elif fid == 1:
6895
        if ftype == TType.STRUCT:
6896
          self.ex = TransactionServiceException()
6897
          self.ex.read(iprot)
6898
        else:
6899
          iprot.skip(ftype)
6900
      else:
6901
        iprot.skip(ftype)
6902
      iprot.readFieldEnd()
6903
    iprot.readStructEnd()
6904
 
6905
  def write(self, oprot):
6906
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6907
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6908
      return
6909
    oprot.writeStructBegin('batchOrders_result')
3431 rajveer 6910
    if self.success is not None:
1220 chandransh 6911
      oprot.writeFieldBegin('success', TType.LIST, 0)
6912
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 6913
      for iter118 in self.success:
6914
        iter118.write(oprot)
1220 chandransh 6915
      oprot.writeListEnd()
6916
      oprot.writeFieldEnd()
3431 rajveer 6917
    if self.ex is not None:
1220 chandransh 6918
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
6919
      self.ex.write(oprot)
6920
      oprot.writeFieldEnd()
6921
    oprot.writeFieldStop()
6922
    oprot.writeStructEnd()
6923
 
3431 rajveer 6924
  def validate(self):
6925
    return
6926
 
6927
 
1220 chandransh 6928
  def __repr__(self):
6929
    L = ['%s=%r' % (key, value)
6930
      for key, value in self.__dict__.iteritems()]
6931
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6932
 
6933
  def __eq__(self, other):
6934
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6935
 
6936
  def __ne__(self, other):
6937
    return not (self == other)
6938
 
1208 chandransh 6939
class markOrderAsOutOfStock_args:
6940
  """
6941
  Attributes:
6942
   - orderId
6943
  """
6944
 
6945
  thrift_spec = (
6946
    None, # 0
6947
    (1, TType.I64, 'orderId', None, None, ), # 1
6948
  )
6949
 
6950
  def __init__(self, orderId=None,):
6951
    self.orderId = orderId
6952
 
6953
  def read(self, iprot):
6954
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6955
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6956
      return
6957
    iprot.readStructBegin()
6958
    while True:
6959
      (fname, ftype, fid) = iprot.readFieldBegin()
6960
      if ftype == TType.STOP:
6961
        break
6962
      if fid == 1:
6963
        if ftype == TType.I64:
6964
          self.orderId = iprot.readI64();
6965
        else:
6966
          iprot.skip(ftype)
6967
      else:
6968
        iprot.skip(ftype)
6969
      iprot.readFieldEnd()
6970
    iprot.readStructEnd()
6971
 
6972
  def write(self, oprot):
6973
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6974
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6975
      return
6976
    oprot.writeStructBegin('markOrderAsOutOfStock_args')
3431 rajveer 6977
    if self.orderId is not None:
1208 chandransh 6978
      oprot.writeFieldBegin('orderId', TType.I64, 1)
6979
      oprot.writeI64(self.orderId)
6980
      oprot.writeFieldEnd()
6981
    oprot.writeFieldStop()
6982
    oprot.writeStructEnd()
6983
 
3431 rajveer 6984
  def validate(self):
6985
    return
6986
 
6987
 
1208 chandransh 6988
  def __repr__(self):
6989
    L = ['%s=%r' % (key, value)
6990
      for key, value in self.__dict__.iteritems()]
6991
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6992
 
6993
  def __eq__(self, other):
6994
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6995
 
6996
  def __ne__(self, other):
6997
    return not (self == other)
6998
 
6999
class markOrderAsOutOfStock_result:
7000
  """
7001
  Attributes:
7002
   - success
7003
   - ex
7004
  """
7005
 
7006
  thrift_spec = (
7007
    (0, TType.BOOL, 'success', None, None, ), # 0
7008
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
7009
  )
7010
 
7011
  def __init__(self, success=None, ex=None,):
7012
    self.success = success
7013
    self.ex = ex
7014
 
7015
  def read(self, iprot):
7016
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7017
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7018
      return
7019
    iprot.readStructBegin()
7020
    while True:
7021
      (fname, ftype, fid) = iprot.readFieldBegin()
7022
      if ftype == TType.STOP:
7023
        break
7024
      if fid == 0:
7025
        if ftype == TType.BOOL:
7026
          self.success = iprot.readBool();
7027
        else:
7028
          iprot.skip(ftype)
7029
      elif fid == 1:
7030
        if ftype == TType.STRUCT:
7031
          self.ex = TransactionServiceException()
7032
          self.ex.read(iprot)
7033
        else:
7034
          iprot.skip(ftype)
7035
      else:
7036
        iprot.skip(ftype)
7037
      iprot.readFieldEnd()
7038
    iprot.readStructEnd()
7039
 
7040
  def write(self, oprot):
7041
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7042
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7043
      return
7044
    oprot.writeStructBegin('markOrderAsOutOfStock_result')
3431 rajveer 7045
    if self.success is not None:
1208 chandransh 7046
      oprot.writeFieldBegin('success', TType.BOOL, 0)
7047
      oprot.writeBool(self.success)
7048
      oprot.writeFieldEnd()
3431 rajveer 7049
    if self.ex is not None:
1208 chandransh 7050
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
7051
      self.ex.write(oprot)
7052
      oprot.writeFieldEnd()
7053
    oprot.writeFieldStop()
7054
    oprot.writeStructEnd()
7055
 
3431 rajveer 7056
  def validate(self):
7057
    return
7058
 
7059
 
1208 chandransh 7060
  def __repr__(self):
7061
    L = ['%s=%r' % (key, value)
7062
      for key, value in self.__dict__.iteritems()]
7063
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7064
 
7065
  def __eq__(self, other):
7066
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7067
 
7068
  def __ne__(self, other):
7069
    return not (self == other)
7070
 
3064 chandransh 7071
class verifyOrder_args:
759 chandransh 7072
  """
7073
  Attributes:
3064 chandransh 7074
   - orderId
759 chandransh 7075
  """
7076
 
7077
  thrift_spec = (
7078
    None, # 0
3064 chandransh 7079
    (1, TType.I64, 'orderId', None, None, ), # 1
759 chandransh 7080
  )
7081
 
3064 chandransh 7082
  def __init__(self, orderId=None,):
7083
    self.orderId = orderId
759 chandransh 7084
 
7085
  def read(self, iprot):
7086
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7087
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7088
      return
7089
    iprot.readStructBegin()
7090
    while True:
7091
      (fname, ftype, fid) = iprot.readFieldBegin()
7092
      if ftype == TType.STOP:
7093
        break
7094
      if fid == 1:
7095
        if ftype == TType.I64:
3064 chandransh 7096
          self.orderId = iprot.readI64();
759 chandransh 7097
        else:
7098
          iprot.skip(ftype)
7099
      else:
7100
        iprot.skip(ftype)
7101
      iprot.readFieldEnd()
7102
    iprot.readStructEnd()
7103
 
7104
  def write(self, oprot):
7105
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7106
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7107
      return
3064 chandransh 7108
    oprot.writeStructBegin('verifyOrder_args')
3431 rajveer 7109
    if self.orderId is not None:
3064 chandransh 7110
      oprot.writeFieldBegin('orderId', TType.I64, 1)
7111
      oprot.writeI64(self.orderId)
759 chandransh 7112
      oprot.writeFieldEnd()
7113
    oprot.writeFieldStop()
7114
    oprot.writeStructEnd()
7115
 
3431 rajveer 7116
  def validate(self):
7117
    return
7118
 
7119
 
759 chandransh 7120
  def __repr__(self):
7121
    L = ['%s=%r' % (key, value)
7122
      for key, value in self.__dict__.iteritems()]
7123
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7124
 
7125
  def __eq__(self, other):
7126
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7127
 
7128
  def __ne__(self, other):
7129
    return not (self == other)
7130
 
3064 chandransh 7131
class verifyOrder_result:
759 chandransh 7132
  """
7133
  Attributes:
7134
   - success
7135
   - ex
7136
  """
7137
 
7138
  thrift_spec = (
7139
    (0, TType.BOOL, 'success', None, None, ), # 0
7140
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
7141
  )
7142
 
7143
  def __init__(self, success=None, ex=None,):
7144
    self.success = success
7145
    self.ex = ex
7146
 
7147
  def read(self, iprot):
7148
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7149
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7150
      return
7151
    iprot.readStructBegin()
7152
    while True:
7153
      (fname, ftype, fid) = iprot.readFieldBegin()
7154
      if ftype == TType.STOP:
7155
        break
7156
      if fid == 0:
7157
        if ftype == TType.BOOL:
7158
          self.success = iprot.readBool();
7159
        else:
7160
          iprot.skip(ftype)
7161
      elif fid == 1:
7162
        if ftype == TType.STRUCT:
7163
          self.ex = TransactionServiceException()
7164
          self.ex.read(iprot)
7165
        else:
7166
          iprot.skip(ftype)
7167
      else:
7168
        iprot.skip(ftype)
7169
      iprot.readFieldEnd()
7170
    iprot.readStructEnd()
7171
 
7172
  def write(self, oprot):
7173
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7174
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7175
      return
3064 chandransh 7176
    oprot.writeStructBegin('verifyOrder_result')
3431 rajveer 7177
    if self.success is not None:
759 chandransh 7178
      oprot.writeFieldBegin('success', TType.BOOL, 0)
7179
      oprot.writeBool(self.success)
7180
      oprot.writeFieldEnd()
3431 rajveer 7181
    if self.ex is not None:
759 chandransh 7182
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
7183
      self.ex.write(oprot)
7184
      oprot.writeFieldEnd()
7185
    oprot.writeFieldStop()
7186
    oprot.writeStructEnd()
7187
 
3431 rajveer 7188
  def validate(self):
7189
    return
7190
 
7191
 
759 chandransh 7192
  def __repr__(self):
7193
    L = ['%s=%r' % (key, value)
7194
      for key, value in self.__dict__.iteritems()]
7195
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7196
 
7197
  def __eq__(self, other):
7198
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7199
 
7200
  def __ne__(self, other):
7201
    return not (self == other)
7202
 
3064 chandransh 7203
class acceptOrder_args:
1113 chandransh 7204
  """
7205
  Attributes:
3064 chandransh 7206
   - orderId
1113 chandransh 7207
  """
7208
 
7209
  thrift_spec = (
7210
    None, # 0
3064 chandransh 7211
    (1, TType.I64, 'orderId', None, None, ), # 1
1113 chandransh 7212
  )
7213
 
3064 chandransh 7214
  def __init__(self, orderId=None,):
7215
    self.orderId = orderId
1113 chandransh 7216
 
7217
  def read(self, iprot):
7218
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7219
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7220
      return
7221
    iprot.readStructBegin()
7222
    while True:
7223
      (fname, ftype, fid) = iprot.readFieldBegin()
7224
      if ftype == TType.STOP:
7225
        break
7226
      if fid == 1:
7227
        if ftype == TType.I64:
3064 chandransh 7228
          self.orderId = iprot.readI64();
1113 chandransh 7229
        else:
7230
          iprot.skip(ftype)
7231
      else:
7232
        iprot.skip(ftype)
7233
      iprot.readFieldEnd()
7234
    iprot.readStructEnd()
7235
 
7236
  def write(self, oprot):
7237
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7238
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7239
      return
3064 chandransh 7240
    oprot.writeStructBegin('acceptOrder_args')
3431 rajveer 7241
    if self.orderId is not None:
3064 chandransh 7242
      oprot.writeFieldBegin('orderId', TType.I64, 1)
7243
      oprot.writeI64(self.orderId)
1113 chandransh 7244
      oprot.writeFieldEnd()
7245
    oprot.writeFieldStop()
7246
    oprot.writeStructEnd()
7247
 
3431 rajveer 7248
  def validate(self):
7249
    return
7250
 
7251
 
1113 chandransh 7252
  def __repr__(self):
7253
    L = ['%s=%r' % (key, value)
7254
      for key, value in self.__dict__.iteritems()]
7255
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7256
 
7257
  def __eq__(self, other):
7258
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7259
 
7260
  def __ne__(self, other):
7261
    return not (self == other)
7262
 
3064 chandransh 7263
class acceptOrder_result:
1113 chandransh 7264
  """
7265
  Attributes:
7266
   - success
7267
   - ex
7268
  """
7269
 
7270
  thrift_spec = (
3064 chandransh 7271
    (0, TType.BOOL, 'success', None, None, ), # 0
1113 chandransh 7272
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
7273
  )
7274
 
7275
  def __init__(self, success=None, ex=None,):
7276
    self.success = success
7277
    self.ex = ex
7278
 
7279
  def read(self, iprot):
7280
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7281
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7282
      return
7283
    iprot.readStructBegin()
7284
    while True:
7285
      (fname, ftype, fid) = iprot.readFieldBegin()
7286
      if ftype == TType.STOP:
7287
        break
7288
      if fid == 0:
3064 chandransh 7289
        if ftype == TType.BOOL:
7290
          self.success = iprot.readBool();
1113 chandransh 7291
        else:
7292
          iprot.skip(ftype)
7293
      elif fid == 1:
7294
        if ftype == TType.STRUCT:
7295
          self.ex = TransactionServiceException()
7296
          self.ex.read(iprot)
7297
        else:
7298
          iprot.skip(ftype)
7299
      else:
7300
        iprot.skip(ftype)
7301
      iprot.readFieldEnd()
7302
    iprot.readStructEnd()
7303
 
7304
  def write(self, oprot):
7305
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7306
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7307
      return
3064 chandransh 7308
    oprot.writeStructBegin('acceptOrder_result')
3431 rajveer 7309
    if self.success is not None:
3064 chandransh 7310
      oprot.writeFieldBegin('success', TType.BOOL, 0)
7311
      oprot.writeBool(self.success)
1113 chandransh 7312
      oprot.writeFieldEnd()
3431 rajveer 7313
    if self.ex is not None:
1113 chandransh 7314
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
7315
      self.ex.write(oprot)
7316
      oprot.writeFieldEnd()
7317
    oprot.writeFieldStop()
7318
    oprot.writeStructEnd()
7319
 
3431 rajveer 7320
  def validate(self):
7321
    return
7322
 
7323
 
1113 chandransh 7324
  def __repr__(self):
7325
    L = ['%s=%r' % (key, value)
7326
      for key, value in self.__dict__.iteritems()]
7327
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7328
 
7329
  def __eq__(self, other):
7330
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7331
 
7332
  def __ne__(self, other):
7333
    return not (self == other)
7334
 
3064 chandransh 7335
class billOrder_args:
1132 chandransh 7336
  """
7337
  Attributes:
3064 chandransh 7338
   - orderId
1132 chandransh 7339
  """
7340
 
7341
  thrift_spec = (
7342
    None, # 0
3064 chandransh 7343
    (1, TType.I64, 'orderId', None, None, ), # 1
1132 chandransh 7344
  )
7345
 
3064 chandransh 7346
  def __init__(self, orderId=None,):
7347
    self.orderId = orderId
1132 chandransh 7348
 
7349
  def read(self, iprot):
7350
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7351
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7352
      return
7353
    iprot.readStructBegin()
7354
    while True:
7355
      (fname, ftype, fid) = iprot.readFieldBegin()
7356
      if ftype == TType.STOP:
7357
        break
7358
      if fid == 1:
7359
        if ftype == TType.I64:
3064 chandransh 7360
          self.orderId = iprot.readI64();
1132 chandransh 7361
        else:
7362
          iprot.skip(ftype)
7363
      else:
7364
        iprot.skip(ftype)
7365
      iprot.readFieldEnd()
7366
    iprot.readStructEnd()
7367
 
7368
  def write(self, oprot):
7369
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7370
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7371
      return
3064 chandransh 7372
    oprot.writeStructBegin('billOrder_args')
3431 rajveer 7373
    if self.orderId is not None:
3064 chandransh 7374
      oprot.writeFieldBegin('orderId', TType.I64, 1)
7375
      oprot.writeI64(self.orderId)
1132 chandransh 7376
      oprot.writeFieldEnd()
7377
    oprot.writeFieldStop()
7378
    oprot.writeStructEnd()
7379
 
3431 rajveer 7380
  def validate(self):
7381
    return
7382
 
7383
 
1132 chandransh 7384
  def __repr__(self):
7385
    L = ['%s=%r' % (key, value)
7386
      for key, value in self.__dict__.iteritems()]
7387
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7388
 
7389
  def __eq__(self, other):
7390
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7391
 
7392
  def __ne__(self, other):
7393
    return not (self == other)
7394
 
3064 chandransh 7395
class billOrder_result:
1132 chandransh 7396
  """
7397
  Attributes:
3064 chandransh 7398
   - success
1132 chandransh 7399
   - ex
7400
  """
7401
 
7402
  thrift_spec = (
3064 chandransh 7403
    (0, TType.BOOL, 'success', None, None, ), # 0
1132 chandransh 7404
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
7405
  )
7406
 
3064 chandransh 7407
  def __init__(self, success=None, ex=None,):
7408
    self.success = success
1132 chandransh 7409
    self.ex = ex
7410
 
7411
  def read(self, iprot):
7412
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7413
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7414
      return
7415
    iprot.readStructBegin()
7416
    while True:
7417
      (fname, ftype, fid) = iprot.readFieldBegin()
7418
      if ftype == TType.STOP:
7419
        break
3064 chandransh 7420
      if fid == 0:
7421
        if ftype == TType.BOOL:
7422
          self.success = iprot.readBool();
7423
        else:
7424
          iprot.skip(ftype)
7425
      elif fid == 1:
1132 chandransh 7426
        if ftype == TType.STRUCT:
7427
          self.ex = TransactionServiceException()
7428
          self.ex.read(iprot)
7429
        else:
7430
          iprot.skip(ftype)
7431
      else:
7432
        iprot.skip(ftype)
7433
      iprot.readFieldEnd()
7434
    iprot.readStructEnd()
7435
 
7436
  def write(self, oprot):
7437
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7438
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7439
      return
3064 chandransh 7440
    oprot.writeStructBegin('billOrder_result')
3431 rajveer 7441
    if self.success is not None:
3064 chandransh 7442
      oprot.writeFieldBegin('success', TType.BOOL, 0)
7443
      oprot.writeBool(self.success)
7444
      oprot.writeFieldEnd()
3431 rajveer 7445
    if self.ex is not None:
1132 chandransh 7446
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
7447
      self.ex.write(oprot)
7448
      oprot.writeFieldEnd()
7449
    oprot.writeFieldStop()
7450
    oprot.writeStructEnd()
7451
 
3431 rajveer 7452
  def validate(self):
7453
    return
7454
 
7455
 
1132 chandransh 7456
  def __repr__(self):
7457
    L = ['%s=%r' % (key, value)
7458
      for key, value in self.__dict__.iteritems()]
7459
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7460
 
7461
  def __eq__(self, other):
7462
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7463
 
7464
  def __ne__(self, other):
7465
    return not (self == other)
7466
 
3064 chandransh 7467
class addBillingDetails_args:
1135 chandransh 7468
  """
7469
  Attributes:
3064 chandransh 7470
   - orderId
7471
   - invoice_number
7472
   - billed_by
1135 chandransh 7473
  """
7474
 
7475
  thrift_spec = (
7476
    None, # 0
3064 chandransh 7477
    (1, TType.I64, 'orderId', None, None, ), # 1
7478
    (2, TType.STRING, 'invoice_number', None, None, ), # 2
7479
    (3, TType.STRING, 'billed_by', None, None, ), # 3
1135 chandransh 7480
  )
7481
 
3064 chandransh 7482
  def __init__(self, orderId=None, invoice_number=None, billed_by=None,):
7483
    self.orderId = orderId
7484
    self.invoice_number = invoice_number
7485
    self.billed_by = billed_by
1135 chandransh 7486
 
7487
  def read(self, iprot):
7488
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7489
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7490
      return
7491
    iprot.readStructBegin()
7492
    while True:
7493
      (fname, ftype, fid) = iprot.readFieldBegin()
7494
      if ftype == TType.STOP:
7495
        break
7496
      if fid == 1:
7497
        if ftype == TType.I64:
3064 chandransh 7498
          self.orderId = iprot.readI64();
1135 chandransh 7499
        else:
7500
          iprot.skip(ftype)
7501
      elif fid == 2:
3064 chandransh 7502
        if ftype == TType.STRING:
7503
          self.invoice_number = iprot.readString();
1135 chandransh 7504
        else:
7505
          iprot.skip(ftype)
3064 chandransh 7506
      elif fid == 3:
7507
        if ftype == TType.STRING:
7508
          self.billed_by = iprot.readString();
7509
        else:
7510
          iprot.skip(ftype)
1135 chandransh 7511
      else:
7512
        iprot.skip(ftype)
7513
      iprot.readFieldEnd()
7514
    iprot.readStructEnd()
7515
 
7516
  def write(self, oprot):
7517
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7518
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7519
      return
3064 chandransh 7520
    oprot.writeStructBegin('addBillingDetails_args')
3431 rajveer 7521
    if self.orderId is not None:
3064 chandransh 7522
      oprot.writeFieldBegin('orderId', TType.I64, 1)
7523
      oprot.writeI64(self.orderId)
1135 chandransh 7524
      oprot.writeFieldEnd()
3431 rajveer 7525
    if self.invoice_number is not None:
3064 chandransh 7526
      oprot.writeFieldBegin('invoice_number', TType.STRING, 2)
7527
      oprot.writeString(self.invoice_number)
1135 chandransh 7528
      oprot.writeFieldEnd()
3431 rajveer 7529
    if self.billed_by is not None:
3064 chandransh 7530
      oprot.writeFieldBegin('billed_by', TType.STRING, 3)
7531
      oprot.writeString(self.billed_by)
7532
      oprot.writeFieldEnd()
1135 chandransh 7533
    oprot.writeFieldStop()
7534
    oprot.writeStructEnd()
7535
 
3431 rajveer 7536
  def validate(self):
7537
    return
7538
 
7539
 
1135 chandransh 7540
  def __repr__(self):
7541
    L = ['%s=%r' % (key, value)
7542
      for key, value in self.__dict__.iteritems()]
7543
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7544
 
7545
  def __eq__(self, other):
7546
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7547
 
7548
  def __ne__(self, other):
7549
    return not (self == other)
7550
 
3064 chandransh 7551
class addBillingDetails_result:
1135 chandransh 7552
  """
7553
  Attributes:
3064 chandransh 7554
   - success
1135 chandransh 7555
   - ex
7556
  """
7557
 
7558
  thrift_spec = (
3064 chandransh 7559
    (0, TType.BOOL, 'success', None, None, ), # 0
1135 chandransh 7560
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
7561
  )
7562
 
3064 chandransh 7563
  def __init__(self, success=None, ex=None,):
7564
    self.success = success
1135 chandransh 7565
    self.ex = ex
7566
 
7567
  def read(self, iprot):
7568
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7569
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7570
      return
7571
    iprot.readStructBegin()
7572
    while True:
7573
      (fname, ftype, fid) = iprot.readFieldBegin()
7574
      if ftype == TType.STOP:
7575
        break
3064 chandransh 7576
      if fid == 0:
7577
        if ftype == TType.BOOL:
7578
          self.success = iprot.readBool();
7579
        else:
7580
          iprot.skip(ftype)
7581
      elif fid == 1:
1135 chandransh 7582
        if ftype == TType.STRUCT:
7583
          self.ex = TransactionServiceException()
7584
          self.ex.read(iprot)
7585
        else:
7586
          iprot.skip(ftype)
7587
      else:
7588
        iprot.skip(ftype)
7589
      iprot.readFieldEnd()
7590
    iprot.readStructEnd()
7591
 
7592
  def write(self, oprot):
7593
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7594
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7595
      return
3064 chandransh 7596
    oprot.writeStructBegin('addBillingDetails_result')
3431 rajveer 7597
    if self.success is not None:
3064 chandransh 7598
      oprot.writeFieldBegin('success', TType.BOOL, 0)
7599
      oprot.writeBool(self.success)
7600
      oprot.writeFieldEnd()
3431 rajveer 7601
    if self.ex is not None:
1135 chandransh 7602
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
7603
      self.ex.write(oprot)
7604
      oprot.writeFieldEnd()
7605
    oprot.writeFieldStop()
7606
    oprot.writeStructEnd()
7607
 
3431 rajveer 7608
  def validate(self):
7609
    return
7610
 
7611
 
1135 chandransh 7612
  def __repr__(self):
7613
    L = ['%s=%r' % (key, value)
7614
      for key, value in self.__dict__.iteritems()]
7615
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7616
 
7617
  def __eq__(self, other):
7618
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7619
 
7620
  def __ne__(self, other):
7621
    return not (self == other)
7622
 
3064 chandransh 7623
class addJacketNumber_args:
1246 chandransh 7624
  """
7625
  Attributes:
3064 chandransh 7626
   - orderId
7627
   - jacketNumber
7628
   - imeiNumber
7629
   - itemNumber
7630
   - billedBy
7631
   - billingType
1246 chandransh 7632
  """
7633
 
7634
  thrift_spec = (
7635
    None, # 0
3064 chandransh 7636
    (1, TType.I64, 'orderId', None, None, ), # 1
7637
    (2, TType.I64, 'jacketNumber', None, None, ), # 2
7638
    (3, TType.I64, 'imeiNumber', None, None, ), # 3
7639
    (4, TType.STRING, 'itemNumber', None, None, ), # 4
7640
    (5, TType.STRING, 'billedBy', None, None, ), # 5
7641
    (6, TType.I64, 'billingType', None, None, ), # 6
1246 chandransh 7642
  )
7643
 
3064 chandransh 7644
  def __init__(self, orderId=None, jacketNumber=None, imeiNumber=None, itemNumber=None, billedBy=None, billingType=None,):
7645
    self.orderId = orderId
7646
    self.jacketNumber = jacketNumber
7647
    self.imeiNumber = imeiNumber
7648
    self.itemNumber = itemNumber
7649
    self.billedBy = billedBy
7650
    self.billingType = billingType
1246 chandransh 7651
 
7652
  def read(self, iprot):
7653
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7654
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7655
      return
7656
    iprot.readStructBegin()
7657
    while True:
7658
      (fname, ftype, fid) = iprot.readFieldBegin()
7659
      if ftype == TType.STOP:
7660
        break
7661
      if fid == 1:
7662
        if ftype == TType.I64:
3064 chandransh 7663
          self.orderId = iprot.readI64();
1246 chandransh 7664
        else:
7665
          iprot.skip(ftype)
7666
      elif fid == 2:
3064 chandransh 7667
        if ftype == TType.I64:
7668
          self.jacketNumber = iprot.readI64();
1246 chandransh 7669
        else:
7670
          iprot.skip(ftype)
3064 chandransh 7671
      elif fid == 3:
7672
        if ftype == TType.I64:
7673
          self.imeiNumber = iprot.readI64();
7674
        else:
7675
          iprot.skip(ftype)
7676
      elif fid == 4:
7677
        if ftype == TType.STRING:
7678
          self.itemNumber = iprot.readString();
7679
        else:
7680
          iprot.skip(ftype)
7681
      elif fid == 5:
7682
        if ftype == TType.STRING:
7683
          self.billedBy = iprot.readString();
7684
        else:
7685
          iprot.skip(ftype)
7686
      elif fid == 6:
7687
        if ftype == TType.I64:
7688
          self.billingType = iprot.readI64();
7689
        else:
7690
          iprot.skip(ftype)
1246 chandransh 7691
      else:
7692
        iprot.skip(ftype)
7693
      iprot.readFieldEnd()
7694
    iprot.readStructEnd()
7695
 
7696
  def write(self, oprot):
7697
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7698
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7699
      return
3064 chandransh 7700
    oprot.writeStructBegin('addJacketNumber_args')
3431 rajveer 7701
    if self.orderId is not None:
3064 chandransh 7702
      oprot.writeFieldBegin('orderId', TType.I64, 1)
7703
      oprot.writeI64(self.orderId)
1246 chandransh 7704
      oprot.writeFieldEnd()
3431 rajveer 7705
    if self.jacketNumber is not None:
3064 chandransh 7706
      oprot.writeFieldBegin('jacketNumber', TType.I64, 2)
7707
      oprot.writeI64(self.jacketNumber)
1246 chandransh 7708
      oprot.writeFieldEnd()
3431 rajveer 7709
    if self.imeiNumber is not None:
3064 chandransh 7710
      oprot.writeFieldBegin('imeiNumber', TType.I64, 3)
7711
      oprot.writeI64(self.imeiNumber)
7712
      oprot.writeFieldEnd()
3431 rajveer 7713
    if self.itemNumber is not None:
3064 chandransh 7714
      oprot.writeFieldBegin('itemNumber', TType.STRING, 4)
7715
      oprot.writeString(self.itemNumber)
7716
      oprot.writeFieldEnd()
3431 rajveer 7717
    if self.billedBy is not None:
3064 chandransh 7718
      oprot.writeFieldBegin('billedBy', TType.STRING, 5)
7719
      oprot.writeString(self.billedBy)
7720
      oprot.writeFieldEnd()
3431 rajveer 7721
    if self.billingType is not None:
3064 chandransh 7722
      oprot.writeFieldBegin('billingType', TType.I64, 6)
7723
      oprot.writeI64(self.billingType)
7724
      oprot.writeFieldEnd()
1246 chandransh 7725
    oprot.writeFieldStop()
7726
    oprot.writeStructEnd()
7727
 
3431 rajveer 7728
  def validate(self):
7729
    return
7730
 
7731
 
1246 chandransh 7732
  def __repr__(self):
7733
    L = ['%s=%r' % (key, value)
7734
      for key, value in self.__dict__.iteritems()]
7735
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7736
 
7737
  def __eq__(self, other):
7738
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7739
 
7740
  def __ne__(self, other):
7741
    return not (self == other)
7742
 
3064 chandransh 7743
class addJacketNumber_result:
1246 chandransh 7744
  """
7745
  Attributes:
3064 chandransh 7746
   - success
1246 chandransh 7747
   - ex
7748
  """
7749
 
7750
  thrift_spec = (
3064 chandransh 7751
    (0, TType.BOOL, 'success', None, None, ), # 0
1246 chandransh 7752
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
7753
  )
7754
 
3064 chandransh 7755
  def __init__(self, success=None, ex=None,):
7756
    self.success = success
1246 chandransh 7757
    self.ex = ex
7758
 
7759
  def read(self, iprot):
7760
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7761
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7762
      return
7763
    iprot.readStructBegin()
7764
    while True:
7765
      (fname, ftype, fid) = iprot.readFieldBegin()
7766
      if ftype == TType.STOP:
7767
        break
3064 chandransh 7768
      if fid == 0:
7769
        if ftype == TType.BOOL:
7770
          self.success = iprot.readBool();
7771
        else:
7772
          iprot.skip(ftype)
7773
      elif fid == 1:
1246 chandransh 7774
        if ftype == TType.STRUCT:
7775
          self.ex = TransactionServiceException()
7776
          self.ex.read(iprot)
7777
        else:
7778
          iprot.skip(ftype)
7779
      else:
7780
        iprot.skip(ftype)
7781
      iprot.readFieldEnd()
7782
    iprot.readStructEnd()
7783
 
7784
  def write(self, oprot):
7785
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7786
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7787
      return
3064 chandransh 7788
    oprot.writeStructBegin('addJacketNumber_result')
3431 rajveer 7789
    if self.success is not None:
3064 chandransh 7790
      oprot.writeFieldBegin('success', TType.BOOL, 0)
7791
      oprot.writeBool(self.success)
7792
      oprot.writeFieldEnd()
3431 rajveer 7793
    if self.ex is not None:
1246 chandransh 7794
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
7795
      self.ex.write(oprot)
7796
      oprot.writeFieldEnd()
7797
    oprot.writeFieldStop()
7798
    oprot.writeStructEnd()
7799
 
3431 rajveer 7800
  def validate(self):
7801
    return
7802
 
7803
 
1246 chandransh 7804
  def __repr__(self):
7805
    L = ['%s=%r' % (key, value)
7806
      for key, value in self.__dict__.iteritems()]
7807
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7808
 
7809
  def __eq__(self, other):
7810
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7811
 
7812
  def __ne__(self, other):
7813
    return not (self == other)
7814
 
3064 chandransh 7815
class markOrdersAsManifested_args:
1408 ankur.sing 7816
  """
7817
  Attributes:
3064 chandransh 7818
   - warehouseId
1408 ankur.sing 7819
   - providerId
3064 chandransh 7820
   - cod
1408 ankur.sing 7821
  """
7822
 
7823
  thrift_spec = (
7824
    None, # 0
3064 chandransh 7825
    (1, TType.I64, 'warehouseId', None, None, ), # 1
7826
    (2, TType.I64, 'providerId', None, None, ), # 2
7827
    (3, TType.BOOL, 'cod', None, None, ), # 3
1408 ankur.sing 7828
  )
7829
 
3064 chandransh 7830
  def __init__(self, warehouseId=None, providerId=None, cod=None,):
7831
    self.warehouseId = warehouseId
1408 ankur.sing 7832
    self.providerId = providerId
3064 chandransh 7833
    self.cod = cod
1408 ankur.sing 7834
 
7835
  def read(self, iprot):
7836
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7837
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7838
      return
7839
    iprot.readStructBegin()
7840
    while True:
7841
      (fname, ftype, fid) = iprot.readFieldBegin()
7842
      if ftype == TType.STOP:
7843
        break
7844
      if fid == 1:
7845
        if ftype == TType.I64:
3064 chandransh 7846
          self.warehouseId = iprot.readI64();
1408 ankur.sing 7847
        else:
7848
          iprot.skip(ftype)
7849
      elif fid == 2:
7850
        if ftype == TType.I64:
3064 chandransh 7851
          self.providerId = iprot.readI64();
1408 ankur.sing 7852
        else:
7853
          iprot.skip(ftype)
3064 chandransh 7854
      elif fid == 3:
7855
        if ftype == TType.BOOL:
7856
          self.cod = iprot.readBool();
7857
        else:
7858
          iprot.skip(ftype)
1408 ankur.sing 7859
      else:
7860
        iprot.skip(ftype)
7861
      iprot.readFieldEnd()
7862
    iprot.readStructEnd()
7863
 
7864
  def write(self, oprot):
7865
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7866
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7867
      return
3064 chandransh 7868
    oprot.writeStructBegin('markOrdersAsManifested_args')
3431 rajveer 7869
    if self.warehouseId is not None:
3064 chandransh 7870
      oprot.writeFieldBegin('warehouseId', TType.I64, 1)
7871
      oprot.writeI64(self.warehouseId)
7872
      oprot.writeFieldEnd()
3431 rajveer 7873
    if self.providerId is not None:
3064 chandransh 7874
      oprot.writeFieldBegin('providerId', TType.I64, 2)
1408 ankur.sing 7875
      oprot.writeI64(self.providerId)
7876
      oprot.writeFieldEnd()
3431 rajveer 7877
    if self.cod is not None:
3064 chandransh 7878
      oprot.writeFieldBegin('cod', TType.BOOL, 3)
7879
      oprot.writeBool(self.cod)
1408 ankur.sing 7880
      oprot.writeFieldEnd()
7881
    oprot.writeFieldStop()
7882
    oprot.writeStructEnd()
7883
 
3431 rajveer 7884
  def validate(self):
7885
    return
7886
 
7887
 
1408 ankur.sing 7888
  def __repr__(self):
7889
    L = ['%s=%r' % (key, value)
7890
      for key, value in self.__dict__.iteritems()]
7891
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7892
 
7893
  def __eq__(self, other):
7894
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7895
 
7896
  def __ne__(self, other):
7897
    return not (self == other)
7898
 
3064 chandransh 7899
class markOrdersAsManifested_result:
1408 ankur.sing 7900
  """
7901
  Attributes:
7902
   - success
3064 chandransh 7903
   - ex
1408 ankur.sing 7904
  """
7905
 
7906
  thrift_spec = (
3064 chandransh 7907
    (0, TType.BOOL, 'success', None, None, ), # 0
7908
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
1408 ankur.sing 7909
  )
7910
 
3064 chandransh 7911
  def __init__(self, success=None, ex=None,):
1408 ankur.sing 7912
    self.success = success
3064 chandransh 7913
    self.ex = ex
1408 ankur.sing 7914
 
7915
  def read(self, iprot):
7916
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7917
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7918
      return
7919
    iprot.readStructBegin()
7920
    while True:
7921
      (fname, ftype, fid) = iprot.readFieldBegin()
7922
      if ftype == TType.STOP:
7923
        break
7924
      if fid == 0:
3064 chandransh 7925
        if ftype == TType.BOOL:
7926
          self.success = iprot.readBool();
1408 ankur.sing 7927
        else:
7928
          iprot.skip(ftype)
3064 chandransh 7929
      elif fid == 1:
7930
        if ftype == TType.STRUCT:
7931
          self.ex = TransactionServiceException()
7932
          self.ex.read(iprot)
7933
        else:
7934
          iprot.skip(ftype)
1408 ankur.sing 7935
      else:
7936
        iprot.skip(ftype)
7937
      iprot.readFieldEnd()
7938
    iprot.readStructEnd()
7939
 
7940
  def write(self, oprot):
7941
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
7942
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
7943
      return
3064 chandransh 7944
    oprot.writeStructBegin('markOrdersAsManifested_result')
3431 rajveer 7945
    if self.success is not None:
3064 chandransh 7946
      oprot.writeFieldBegin('success', TType.BOOL, 0)
7947
      oprot.writeBool(self.success)
1408 ankur.sing 7948
      oprot.writeFieldEnd()
3431 rajveer 7949
    if self.ex is not None:
3064 chandransh 7950
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
7951
      self.ex.write(oprot)
7952
      oprot.writeFieldEnd()
1408 ankur.sing 7953
    oprot.writeFieldStop()
7954
    oprot.writeStructEnd()
7955
 
3431 rajveer 7956
  def validate(self):
7957
    return
7958
 
7959
 
1408 ankur.sing 7960
  def __repr__(self):
7961
    L = ['%s=%r' % (key, value)
7962
      for key, value in self.__dict__.iteritems()]
7963
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
7964
 
7965
  def __eq__(self, other):
7966
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
7967
 
7968
  def __ne__(self, other):
7969
    return not (self == other)
7970
 
3064 chandransh 7971
class markOrdersAsPickedUp_args:
304 ashish 7972
  """
7973
  Attributes:
3064 chandransh 7974
   - providerId
7975
   - pickupDetails
304 ashish 7976
  """
94 ashish 7977
 
304 ashish 7978
  thrift_spec = (
7979
    None, # 0
3064 chandransh 7980
    (1, TType.I64, 'providerId', None, None, ), # 1
7981
    (2, TType.MAP, 'pickupDetails', (TType.STRING,None,TType.STRING,None), None, ), # 2
304 ashish 7982
  )
7983
 
3064 chandransh 7984
  def __init__(self, providerId=None, pickupDetails=None,):
7985
    self.providerId = providerId
7986
    self.pickupDetails = pickupDetails
304 ashish 7987
 
7988
  def read(self, iprot):
7989
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
7990
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
7991
      return
7992
    iprot.readStructBegin()
7993
    while True:
7994
      (fname, ftype, fid) = iprot.readFieldBegin()
7995
      if ftype == TType.STOP:
7996
        break
7997
      if fid == 1:
7998
        if ftype == TType.I64:
3064 chandransh 7999
          self.providerId = iprot.readI64();
304 ashish 8000
        else:
8001
          iprot.skip(ftype)
8002
      elif fid == 2:
3064 chandransh 8003
        if ftype == TType.MAP:
8004
          self.pickupDetails = {}
3427 chandransh 8005
          (_ktype120, _vtype121, _size119 ) = iprot.readMapBegin() 
8006
          for _i123 in xrange(_size119):
8007
            _key124 = iprot.readString();
8008
            _val125 = iprot.readString();
8009
            self.pickupDetails[_key124] = _val125
3064 chandransh 8010
          iprot.readMapEnd()
304 ashish 8011
        else:
8012
          iprot.skip(ftype)
8013
      else:
8014
        iprot.skip(ftype)
8015
      iprot.readFieldEnd()
8016
    iprot.readStructEnd()
8017
 
8018
  def write(self, oprot):
8019
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8020
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8021
      return
3064 chandransh 8022
    oprot.writeStructBegin('markOrdersAsPickedUp_args')
3431 rajveer 8023
    if self.providerId is not None:
3064 chandransh 8024
      oprot.writeFieldBegin('providerId', TType.I64, 1)
8025
      oprot.writeI64(self.providerId)
304 ashish 8026
      oprot.writeFieldEnd()
3431 rajveer 8027
    if self.pickupDetails is not None:
3064 chandransh 8028
      oprot.writeFieldBegin('pickupDetails', TType.MAP, 2)
8029
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.pickupDetails))
3427 chandransh 8030
      for kiter126,viter127 in self.pickupDetails.items():
8031
        oprot.writeString(kiter126)
8032
        oprot.writeString(viter127)
3064 chandransh 8033
      oprot.writeMapEnd()
304 ashish 8034
      oprot.writeFieldEnd()
8035
    oprot.writeFieldStop()
8036
    oprot.writeStructEnd()
8037
 
3431 rajveer 8038
  def validate(self):
8039
    return
8040
 
8041
 
304 ashish 8042
  def __repr__(self):
8043
    L = ['%s=%r' % (key, value)
8044
      for key, value in self.__dict__.iteritems()]
8045
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8046
 
8047
  def __eq__(self, other):
8048
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8049
 
8050
  def __ne__(self, other):
8051
    return not (self == other)
8052
 
3064 chandransh 8053
class markOrdersAsPickedUp_result:
304 ashish 8054
  """
8055
  Attributes:
8056
   - success
3064 chandransh 8057
   - ex
304 ashish 8058
  """
8059
 
8060
  thrift_spec = (
3064 chandransh 8061
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
8062
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
304 ashish 8063
  )
8064
 
3064 chandransh 8065
  def __init__(self, success=None, ex=None,):
304 ashish 8066
    self.success = success
3064 chandransh 8067
    self.ex = ex
304 ashish 8068
 
8069
  def read(self, iprot):
8070
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8071
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8072
      return
8073
    iprot.readStructBegin()
8074
    while True:
8075
      (fname, ftype, fid) = iprot.readFieldBegin()
8076
      if ftype == TType.STOP:
8077
        break
8078
      if fid == 0:
8079
        if ftype == TType.LIST:
8080
          self.success = []
3427 chandransh 8081
          (_etype131, _size128) = iprot.readListBegin()
8082
          for _i132 in xrange(_size128):
8083
            _elem133 = Order()
8084
            _elem133.read(iprot)
8085
            self.success.append(_elem133)
304 ashish 8086
          iprot.readListEnd()
8087
        else:
8088
          iprot.skip(ftype)
3064 chandransh 8089
      elif fid == 1:
8090
        if ftype == TType.STRUCT:
8091
          self.ex = TransactionServiceException()
8092
          self.ex.read(iprot)
8093
        else:
8094
          iprot.skip(ftype)
304 ashish 8095
      else:
8096
        iprot.skip(ftype)
8097
      iprot.readFieldEnd()
8098
    iprot.readStructEnd()
8099
 
8100
  def write(self, oprot):
8101
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8102
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8103
      return
3064 chandransh 8104
    oprot.writeStructBegin('markOrdersAsPickedUp_result')
3431 rajveer 8105
    if self.success is not None:
304 ashish 8106
      oprot.writeFieldBegin('success', TType.LIST, 0)
8107
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 8108
      for iter134 in self.success:
8109
        iter134.write(oprot)
304 ashish 8110
      oprot.writeListEnd()
8111
      oprot.writeFieldEnd()
3431 rajveer 8112
    if self.ex is not None:
3064 chandransh 8113
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
8114
      self.ex.write(oprot)
8115
      oprot.writeFieldEnd()
304 ashish 8116
    oprot.writeFieldStop()
8117
    oprot.writeStructEnd()
8118
 
3431 rajveer 8119
  def validate(self):
8120
    return
8121
 
8122
 
304 ashish 8123
  def __repr__(self):
8124
    L = ['%s=%r' % (key, value)
8125
      for key, value in self.__dict__.iteritems()]
8126
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8127
 
8128
  def __eq__(self, other):
8129
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8130
 
8131
  def __ne__(self, other):
8132
    return not (self == other)
8133
 
3064 chandransh 8134
class markOrdersAsDelivered_args:
304 ashish 8135
  """
8136
  Attributes:
3064 chandransh 8137
   - providerId
8138
   - deliveredOrders
304 ashish 8139
  """
8140
 
8141
  thrift_spec = (
8142
    None, # 0
3064 chandransh 8143
    (1, TType.I64, 'providerId', None, None, ), # 1
8144
    (2, TType.MAP, 'deliveredOrders', (TType.STRING,None,TType.STRING,None), None, ), # 2
304 ashish 8145
  )
8146
 
3064 chandransh 8147
  def __init__(self, providerId=None, deliveredOrders=None,):
8148
    self.providerId = providerId
8149
    self.deliveredOrders = deliveredOrders
304 ashish 8150
 
8151
  def read(self, iprot):
8152
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8153
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8154
      return
8155
    iprot.readStructBegin()
8156
    while True:
8157
      (fname, ftype, fid) = iprot.readFieldBegin()
8158
      if ftype == TType.STOP:
8159
        break
8160
      if fid == 1:
8161
        if ftype == TType.I64:
3064 chandransh 8162
          self.providerId = iprot.readI64();
304 ashish 8163
        else:
8164
          iprot.skip(ftype)
8165
      elif fid == 2:
3064 chandransh 8166
        if ftype == TType.MAP:
8167
          self.deliveredOrders = {}
3427 chandransh 8168
          (_ktype136, _vtype137, _size135 ) = iprot.readMapBegin() 
8169
          for _i139 in xrange(_size135):
8170
            _key140 = iprot.readString();
8171
            _val141 = iprot.readString();
8172
            self.deliveredOrders[_key140] = _val141
3064 chandransh 8173
          iprot.readMapEnd()
304 ashish 8174
        else:
8175
          iprot.skip(ftype)
8176
      else:
8177
        iprot.skip(ftype)
8178
      iprot.readFieldEnd()
8179
    iprot.readStructEnd()
8180
 
8181
  def write(self, oprot):
8182
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8183
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8184
      return
3064 chandransh 8185
    oprot.writeStructBegin('markOrdersAsDelivered_args')
3431 rajveer 8186
    if self.providerId is not None:
3064 chandransh 8187
      oprot.writeFieldBegin('providerId', TType.I64, 1)
8188
      oprot.writeI64(self.providerId)
304 ashish 8189
      oprot.writeFieldEnd()
3431 rajveer 8190
    if self.deliveredOrders is not None:
3064 chandransh 8191
      oprot.writeFieldBegin('deliveredOrders', TType.MAP, 2)
8192
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.deliveredOrders))
3427 chandransh 8193
      for kiter142,viter143 in self.deliveredOrders.items():
8194
        oprot.writeString(kiter142)
8195
        oprot.writeString(viter143)
3064 chandransh 8196
      oprot.writeMapEnd()
304 ashish 8197
      oprot.writeFieldEnd()
8198
    oprot.writeFieldStop()
8199
    oprot.writeStructEnd()
8200
 
3431 rajveer 8201
  def validate(self):
8202
    return
8203
 
8204
 
304 ashish 8205
  def __repr__(self):
8206
    L = ['%s=%r' % (key, value)
8207
      for key, value in self.__dict__.iteritems()]
8208
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8209
 
8210
  def __eq__(self, other):
8211
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8212
 
8213
  def __ne__(self, other):
8214
    return not (self == other)
8215
 
3064 chandransh 8216
class markOrdersAsDelivered_result:
8217
  """
8218
  Attributes:
8219
   - ex
8220
  """
304 ashish 8221
 
8222
  thrift_spec = (
3064 chandransh 8223
    None, # 0
8224
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
304 ashish 8225
  )
8226
 
3064 chandransh 8227
  def __init__(self, ex=None,):
8228
    self.ex = ex
304 ashish 8229
 
1596 ankur.sing 8230
  def read(self, iprot):
8231
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8232
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8233
      return
8234
    iprot.readStructBegin()
8235
    while True:
8236
      (fname, ftype, fid) = iprot.readFieldBegin()
8237
      if ftype == TType.STOP:
8238
        break
3064 chandransh 8239
      if fid == 1:
8240
        if ftype == TType.STRUCT:
8241
          self.ex = TransactionServiceException()
8242
          self.ex.read(iprot)
8243
        else:
8244
          iprot.skip(ftype)
1596 ankur.sing 8245
      else:
8246
        iprot.skip(ftype)
8247
      iprot.readFieldEnd()
8248
    iprot.readStructEnd()
8249
 
8250
  def write(self, oprot):
8251
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8252
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8253
      return
3064 chandransh 8254
    oprot.writeStructBegin('markOrdersAsDelivered_result')
3431 rajveer 8255
    if self.ex is not None:
3064 chandransh 8256
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
8257
      self.ex.write(oprot)
8258
      oprot.writeFieldEnd()
1596 ankur.sing 8259
    oprot.writeFieldStop()
8260
    oprot.writeStructEnd()
8261
 
3431 rajveer 8262
  def validate(self):
8263
    return
8264
 
8265
 
1596 ankur.sing 8266
  def __repr__(self):
8267
    L = ['%s=%r' % (key, value)
8268
      for key, value in self.__dict__.iteritems()]
8269
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8270
 
8271
  def __eq__(self, other):
8272
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8273
 
8274
  def __ne__(self, other):
8275
    return not (self == other)
8276
 
3064 chandransh 8277
class markOrdersAsFailed_args:
1596 ankur.sing 8278
  """
8279
  Attributes:
3064 chandransh 8280
   - providerId
8281
   - returnedOrders
1596 ankur.sing 8282
  """
8283
 
8284
  thrift_spec = (
3064 chandransh 8285
    None, # 0
8286
    (1, TType.I64, 'providerId', None, None, ), # 1
8287
    (2, TType.MAP, 'returnedOrders', (TType.STRING,None,TType.STRING,None), None, ), # 2
1596 ankur.sing 8288
  )
8289
 
3064 chandransh 8290
  def __init__(self, providerId=None, returnedOrders=None,):
8291
    self.providerId = providerId
8292
    self.returnedOrders = returnedOrders
1596 ankur.sing 8293
 
8294
  def read(self, iprot):
8295
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8296
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8297
      return
8298
    iprot.readStructBegin()
8299
    while True:
8300
      (fname, ftype, fid) = iprot.readFieldBegin()
8301
      if ftype == TType.STOP:
8302
        break
3064 chandransh 8303
      if fid == 1:
1596 ankur.sing 8304
        if ftype == TType.I64:
3064 chandransh 8305
          self.providerId = iprot.readI64();
1596 ankur.sing 8306
        else:
8307
          iprot.skip(ftype)
3064 chandransh 8308
      elif fid == 2:
8309
        if ftype == TType.MAP:
8310
          self.returnedOrders = {}
3427 chandransh 8311
          (_ktype145, _vtype146, _size144 ) = iprot.readMapBegin() 
8312
          for _i148 in xrange(_size144):
8313
            _key149 = iprot.readString();
8314
            _val150 = iprot.readString();
8315
            self.returnedOrders[_key149] = _val150
3064 chandransh 8316
          iprot.readMapEnd()
8317
        else:
8318
          iprot.skip(ftype)
1596 ankur.sing 8319
      else:
8320
        iprot.skip(ftype)
8321
      iprot.readFieldEnd()
8322
    iprot.readStructEnd()
8323
 
8324
  def write(self, oprot):
8325
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8326
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8327
      return
3064 chandransh 8328
    oprot.writeStructBegin('markOrdersAsFailed_args')
3431 rajveer 8329
    if self.providerId is not None:
3064 chandransh 8330
      oprot.writeFieldBegin('providerId', TType.I64, 1)
8331
      oprot.writeI64(self.providerId)
1596 ankur.sing 8332
      oprot.writeFieldEnd()
3431 rajveer 8333
    if self.returnedOrders is not None:
3064 chandransh 8334
      oprot.writeFieldBegin('returnedOrders', TType.MAP, 2)
8335
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.returnedOrders))
3427 chandransh 8336
      for kiter151,viter152 in self.returnedOrders.items():
8337
        oprot.writeString(kiter151)
8338
        oprot.writeString(viter152)
3064 chandransh 8339
      oprot.writeMapEnd()
8340
      oprot.writeFieldEnd()
1596 ankur.sing 8341
    oprot.writeFieldStop()
8342
    oprot.writeStructEnd()
8343
 
3431 rajveer 8344
  def validate(self):
8345
    return
8346
 
8347
 
1596 ankur.sing 8348
  def __repr__(self):
8349
    L = ['%s=%r' % (key, value)
8350
      for key, value in self.__dict__.iteritems()]
8351
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8352
 
8353
  def __eq__(self, other):
8354
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8355
 
8356
  def __ne__(self, other):
8357
    return not (self == other)
8358
 
3064 chandransh 8359
class markOrdersAsFailed_result:
8360
  """
8361
  Attributes:
8362
   - ex
8363
  """
1596 ankur.sing 8364
 
1627 ankur.sing 8365
  thrift_spec = (
3064 chandransh 8366
    None, # 0
8367
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
1627 ankur.sing 8368
  )
8369
 
3064 chandransh 8370
  def __init__(self, ex=None,):
8371
    self.ex = ex
8372
 
1627 ankur.sing 8373
  def read(self, iprot):
8374
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8375
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8376
      return
8377
    iprot.readStructBegin()
8378
    while True:
8379
      (fname, ftype, fid) = iprot.readFieldBegin()
8380
      if ftype == TType.STOP:
8381
        break
3064 chandransh 8382
      if fid == 1:
8383
        if ftype == TType.STRUCT:
8384
          self.ex = TransactionServiceException()
8385
          self.ex.read(iprot)
8386
        else:
8387
          iprot.skip(ftype)
1627 ankur.sing 8388
      else:
8389
        iprot.skip(ftype)
8390
      iprot.readFieldEnd()
8391
    iprot.readStructEnd()
8392
 
8393
  def write(self, oprot):
8394
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8395
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8396
      return
3064 chandransh 8397
    oprot.writeStructBegin('markOrdersAsFailed_result')
3431 rajveer 8398
    if self.ex is not None:
3064 chandransh 8399
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
8400
      self.ex.write(oprot)
8401
      oprot.writeFieldEnd()
1627 ankur.sing 8402
    oprot.writeFieldStop()
8403
    oprot.writeStructEnd()
8404
 
3431 rajveer 8405
  def validate(self):
8406
    return
8407
 
8408
 
1627 ankur.sing 8409
  def __repr__(self):
8410
    L = ['%s=%r' % (key, value)
8411
      for key, value in self.__dict__.iteritems()]
8412
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8413
 
8414
  def __eq__(self, other):
8415
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8416
 
8417
  def __ne__(self, other):
8418
    return not (self == other)
8419
 
3064 chandransh 8420
class updateNonDeliveryReason_args:
1627 ankur.sing 8421
  """
8422
  Attributes:
3064 chandransh 8423
   - providerId
8424
   - undeliveredOrders
1627 ankur.sing 8425
  """
8426
 
8427
  thrift_spec = (
3064 chandransh 8428
    None, # 0
8429
    (1, TType.I64, 'providerId', None, None, ), # 1
8430
    (2, TType.MAP, 'undeliveredOrders', (TType.STRING,None,TType.STRING,None), None, ), # 2
1627 ankur.sing 8431
  )
8432
 
3064 chandransh 8433
  def __init__(self, providerId=None, undeliveredOrders=None,):
8434
    self.providerId = providerId
8435
    self.undeliveredOrders = undeliveredOrders
1627 ankur.sing 8436
 
8437
  def read(self, iprot):
8438
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8439
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8440
      return
8441
    iprot.readStructBegin()
8442
    while True:
8443
      (fname, ftype, fid) = iprot.readFieldBegin()
8444
      if ftype == TType.STOP:
8445
        break
3064 chandransh 8446
      if fid == 1:
1627 ankur.sing 8447
        if ftype == TType.I64:
3064 chandransh 8448
          self.providerId = iprot.readI64();
1627 ankur.sing 8449
        else:
8450
          iprot.skip(ftype)
3064 chandransh 8451
      elif fid == 2:
8452
        if ftype == TType.MAP:
8453
          self.undeliveredOrders = {}
3427 chandransh 8454
          (_ktype154, _vtype155, _size153 ) = iprot.readMapBegin() 
8455
          for _i157 in xrange(_size153):
8456
            _key158 = iprot.readString();
8457
            _val159 = iprot.readString();
8458
            self.undeliveredOrders[_key158] = _val159
3064 chandransh 8459
          iprot.readMapEnd()
8460
        else:
8461
          iprot.skip(ftype)
1627 ankur.sing 8462
      else:
8463
        iprot.skip(ftype)
8464
      iprot.readFieldEnd()
8465
    iprot.readStructEnd()
8466
 
8467
  def write(self, oprot):
8468
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8469
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8470
      return
3064 chandransh 8471
    oprot.writeStructBegin('updateNonDeliveryReason_args')
3431 rajveer 8472
    if self.providerId is not None:
3064 chandransh 8473
      oprot.writeFieldBegin('providerId', TType.I64, 1)
8474
      oprot.writeI64(self.providerId)
1627 ankur.sing 8475
      oprot.writeFieldEnd()
3431 rajveer 8476
    if self.undeliveredOrders is not None:
3064 chandransh 8477
      oprot.writeFieldBegin('undeliveredOrders', TType.MAP, 2)
8478
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.undeliveredOrders))
3427 chandransh 8479
      for kiter160,viter161 in self.undeliveredOrders.items():
8480
        oprot.writeString(kiter160)
8481
        oprot.writeString(viter161)
3064 chandransh 8482
      oprot.writeMapEnd()
8483
      oprot.writeFieldEnd()
1627 ankur.sing 8484
    oprot.writeFieldStop()
8485
    oprot.writeStructEnd()
8486
 
3431 rajveer 8487
  def validate(self):
8488
    return
8489
 
8490
 
1627 ankur.sing 8491
  def __repr__(self):
8492
    L = ['%s=%r' % (key, value)
8493
      for key, value in self.__dict__.iteritems()]
8494
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8495
 
8496
  def __eq__(self, other):
8497
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8498
 
8499
  def __ne__(self, other):
8500
    return not (self == other)
8501
 
3064 chandransh 8502
class updateNonDeliveryReason_result:
1627 ankur.sing 8503
  """
8504
  Attributes:
3064 chandransh 8505
   - ex
1627 ankur.sing 8506
  """
8507
 
8508
  thrift_spec = (
3064 chandransh 8509
    None, # 0
8510
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
1627 ankur.sing 8511
  )
8512
 
3064 chandransh 8513
  def __init__(self, ex=None,):
8514
    self.ex = ex
1627 ankur.sing 8515
 
8516
  def read(self, iprot):
8517
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8518
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8519
      return
8520
    iprot.readStructBegin()
8521
    while True:
8522
      (fname, ftype, fid) = iprot.readFieldBegin()
8523
      if ftype == TType.STOP:
8524
        break
3064 chandransh 8525
      if fid == 1:
8526
        if ftype == TType.STRUCT:
8527
          self.ex = TransactionServiceException()
8528
          self.ex.read(iprot)
1627 ankur.sing 8529
        else:
8530
          iprot.skip(ftype)
8531
      else:
8532
        iprot.skip(ftype)
8533
      iprot.readFieldEnd()
8534
    iprot.readStructEnd()
8535
 
8536
  def write(self, oprot):
8537
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8538
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8539
      return
3064 chandransh 8540
    oprot.writeStructBegin('updateNonDeliveryReason_result')
3431 rajveer 8541
    if self.ex is not None:
3064 chandransh 8542
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
8543
      self.ex.write(oprot)
1627 ankur.sing 8544
      oprot.writeFieldEnd()
8545
    oprot.writeFieldStop()
8546
    oprot.writeStructEnd()
8547
 
3431 rajveer 8548
  def validate(self):
8549
    return
8550
 
8551
 
1627 ankur.sing 8552
  def __repr__(self):
8553
    L = ['%s=%r' % (key, value)
8554
      for key, value in self.__dict__.iteritems()]
8555
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8556
 
8557
  def __eq__(self, other):
8558
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8559
 
8560
  def __ne__(self, other):
8561
    return not (self == other)
8562
 
3064 chandransh 8563
class getUndeliveredOrders_args:
1886 ankur.sing 8564
  """
8565
  Attributes:
3064 chandransh 8566
   - providerId
8567
   - warehouseId
1886 ankur.sing 8568
  """
1627 ankur.sing 8569
 
1886 ankur.sing 8570
  thrift_spec = (
8571
    None, # 0
3064 chandransh 8572
    (1, TType.I64, 'providerId', None, None, ), # 1
8573
    (2, TType.I64, 'warehouseId', None, None, ), # 2
1886 ankur.sing 8574
  )
8575
 
3064 chandransh 8576
  def __init__(self, providerId=None, warehouseId=None,):
8577
    self.providerId = providerId
8578
    self.warehouseId = warehouseId
1886 ankur.sing 8579
 
8580
  def read(self, iprot):
8581
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8582
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8583
      return
8584
    iprot.readStructBegin()
8585
    while True:
8586
      (fname, ftype, fid) = iprot.readFieldBegin()
8587
      if ftype == TType.STOP:
8588
        break
8589
      if fid == 1:
8590
        if ftype == TType.I64:
3064 chandransh 8591
          self.providerId = iprot.readI64();
1886 ankur.sing 8592
        else:
8593
          iprot.skip(ftype)
3064 chandransh 8594
      elif fid == 2:
8595
        if ftype == TType.I64:
8596
          self.warehouseId = iprot.readI64();
8597
        else:
8598
          iprot.skip(ftype)
1886 ankur.sing 8599
      else:
8600
        iprot.skip(ftype)
8601
      iprot.readFieldEnd()
8602
    iprot.readStructEnd()
8603
 
8604
  def write(self, oprot):
8605
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8606
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8607
      return
3064 chandransh 8608
    oprot.writeStructBegin('getUndeliveredOrders_args')
3431 rajveer 8609
    if self.providerId is not None:
3064 chandransh 8610
      oprot.writeFieldBegin('providerId', TType.I64, 1)
8611
      oprot.writeI64(self.providerId)
1886 ankur.sing 8612
      oprot.writeFieldEnd()
3431 rajveer 8613
    if self.warehouseId is not None:
3064 chandransh 8614
      oprot.writeFieldBegin('warehouseId', TType.I64, 2)
8615
      oprot.writeI64(self.warehouseId)
8616
      oprot.writeFieldEnd()
1886 ankur.sing 8617
    oprot.writeFieldStop()
8618
    oprot.writeStructEnd()
8619
 
3431 rajveer 8620
  def validate(self):
8621
    return
8622
 
8623
 
1886 ankur.sing 8624
  def __repr__(self):
8625
    L = ['%s=%r' % (key, value)
8626
      for key, value in self.__dict__.iteritems()]
8627
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8628
 
8629
  def __eq__(self, other):
8630
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8631
 
8632
  def __ne__(self, other):
8633
    return not (self == other)
8634
 
3064 chandransh 8635
class getUndeliveredOrders_result:
1886 ankur.sing 8636
  """
8637
  Attributes:
8638
   - success
8639
  """
8640
 
8641
  thrift_spec = (
8642
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
8643
  )
8644
 
8645
  def __init__(self, success=None,):
8646
    self.success = success
8647
 
8648
  def read(self, iprot):
8649
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8650
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8651
      return
8652
    iprot.readStructBegin()
8653
    while True:
8654
      (fname, ftype, fid) = iprot.readFieldBegin()
8655
      if ftype == TType.STOP:
8656
        break
8657
      if fid == 0:
8658
        if ftype == TType.LIST:
8659
          self.success = []
3427 chandransh 8660
          (_etype165, _size162) = iprot.readListBegin()
8661
          for _i166 in xrange(_size162):
8662
            _elem167 = Order()
8663
            _elem167.read(iprot)
8664
            self.success.append(_elem167)
1886 ankur.sing 8665
          iprot.readListEnd()
8666
        else:
8667
          iprot.skip(ftype)
8668
      else:
8669
        iprot.skip(ftype)
8670
      iprot.readFieldEnd()
8671
    iprot.readStructEnd()
8672
 
8673
  def write(self, oprot):
8674
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8675
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8676
      return
3064 chandransh 8677
    oprot.writeStructBegin('getUndeliveredOrders_result')
3431 rajveer 8678
    if self.success is not None:
1886 ankur.sing 8679
      oprot.writeFieldBegin('success', TType.LIST, 0)
8680
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 8681
      for iter168 in self.success:
8682
        iter168.write(oprot)
1886 ankur.sing 8683
      oprot.writeListEnd()
8684
      oprot.writeFieldEnd()
8685
    oprot.writeFieldStop()
8686
    oprot.writeStructEnd()
8687
 
3431 rajveer 8688
  def validate(self):
8689
    return
8690
 
8691
 
1886 ankur.sing 8692
  def __repr__(self):
8693
    L = ['%s=%r' % (key, value)
8694
      for key, value in self.__dict__.iteritems()]
8695
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8696
 
8697
  def __eq__(self, other):
8698
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8699
 
8700
  def __ne__(self, other):
8701
    return not (self == other)
8702
 
2536 chandransh 8703
class toggleDOAFlag_args:
8704
  """
8705
  Attributes:
8706
   - orderId
8707
  """
1886 ankur.sing 8708
 
2536 chandransh 8709
  thrift_spec = (
8710
    None, # 0
8711
    (1, TType.I64, 'orderId', None, None, ), # 1
8712
  )
8713
 
8714
  def __init__(self, orderId=None,):
8715
    self.orderId = orderId
8716
 
8717
  def read(self, iprot):
8718
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8719
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8720
      return
8721
    iprot.readStructBegin()
8722
    while True:
8723
      (fname, ftype, fid) = iprot.readFieldBegin()
8724
      if ftype == TType.STOP:
8725
        break
8726
      if fid == 1:
8727
        if ftype == TType.I64:
8728
          self.orderId = iprot.readI64();
8729
        else:
8730
          iprot.skip(ftype)
8731
      else:
8732
        iprot.skip(ftype)
8733
      iprot.readFieldEnd()
8734
    iprot.readStructEnd()
8735
 
8736
  def write(self, oprot):
8737
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8738
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8739
      return
8740
    oprot.writeStructBegin('toggleDOAFlag_args')
3431 rajveer 8741
    if self.orderId is not None:
2536 chandransh 8742
      oprot.writeFieldBegin('orderId', TType.I64, 1)
8743
      oprot.writeI64(self.orderId)
8744
      oprot.writeFieldEnd()
8745
    oprot.writeFieldStop()
8746
    oprot.writeStructEnd()
8747
 
3431 rajveer 8748
  def validate(self):
8749
    return
8750
 
8751
 
2536 chandransh 8752
  def __repr__(self):
8753
    L = ['%s=%r' % (key, value)
8754
      for key, value in self.__dict__.iteritems()]
8755
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8756
 
8757
  def __eq__(self, other):
8758
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8759
 
8760
  def __ne__(self, other):
8761
    return not (self == other)
8762
 
8763
class toggleDOAFlag_result:
8764
  """
8765
  Attributes:
8766
   - success
8767
   - ex
8768
  """
8769
 
8770
  thrift_spec = (
8771
    (0, TType.BOOL, 'success', None, None, ), # 0
8772
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
8773
  )
8774
 
8775
  def __init__(self, success=None, ex=None,):
8776
    self.success = success
8777
    self.ex = ex
8778
 
8779
  def read(self, iprot):
8780
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8781
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8782
      return
8783
    iprot.readStructBegin()
8784
    while True:
8785
      (fname, ftype, fid) = iprot.readFieldBegin()
8786
      if ftype == TType.STOP:
8787
        break
8788
      if fid == 0:
8789
        if ftype == TType.BOOL:
8790
          self.success = iprot.readBool();
8791
        else:
8792
          iprot.skip(ftype)
8793
      elif fid == 1:
8794
        if ftype == TType.STRUCT:
8795
          self.ex = TransactionServiceException()
8796
          self.ex.read(iprot)
8797
        else:
8798
          iprot.skip(ftype)
8799
      else:
8800
        iprot.skip(ftype)
8801
      iprot.readFieldEnd()
8802
    iprot.readStructEnd()
8803
 
8804
  def write(self, oprot):
8805
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8806
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8807
      return
8808
    oprot.writeStructBegin('toggleDOAFlag_result')
3431 rajveer 8809
    if self.success is not None:
2536 chandransh 8810
      oprot.writeFieldBegin('success', TType.BOOL, 0)
8811
      oprot.writeBool(self.success)
8812
      oprot.writeFieldEnd()
3431 rajveer 8813
    if self.ex is not None:
2536 chandransh 8814
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
8815
      self.ex.write(oprot)
8816
      oprot.writeFieldEnd()
8817
    oprot.writeFieldStop()
8818
    oprot.writeStructEnd()
8819
 
3431 rajveer 8820
  def validate(self):
8821
    return
8822
 
8823
 
2536 chandransh 8824
  def __repr__(self):
8825
    L = ['%s=%r' % (key, value)
8826
      for key, value in self.__dict__.iteritems()]
8827
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8828
 
8829
  def __eq__(self, other):
8830
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8831
 
8832
  def __ne__(self, other):
8833
    return not (self == other)
8834
 
8835
class requestPickupNumber_args:
8836
  """
8837
  Attributes:
8838
   - orderId
8839
  """
8840
 
8841
  thrift_spec = (
8842
    None, # 0
8843
    (1, TType.I64, 'orderId', None, None, ), # 1
8844
  )
8845
 
8846
  def __init__(self, orderId=None,):
8847
    self.orderId = orderId
8848
 
8849
  def read(self, iprot):
8850
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8851
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8852
      return
8853
    iprot.readStructBegin()
8854
    while True:
8855
      (fname, ftype, fid) = iprot.readFieldBegin()
8856
      if ftype == TType.STOP:
8857
        break
8858
      if fid == 1:
8859
        if ftype == TType.I64:
8860
          self.orderId = iprot.readI64();
8861
        else:
8862
          iprot.skip(ftype)
8863
      else:
8864
        iprot.skip(ftype)
8865
      iprot.readFieldEnd()
8866
    iprot.readStructEnd()
8867
 
8868
  def write(self, oprot):
8869
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8870
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8871
      return
8872
    oprot.writeStructBegin('requestPickupNumber_args')
3431 rajveer 8873
    if self.orderId is not None:
2536 chandransh 8874
      oprot.writeFieldBegin('orderId', TType.I64, 1)
8875
      oprot.writeI64(self.orderId)
8876
      oprot.writeFieldEnd()
8877
    oprot.writeFieldStop()
8878
    oprot.writeStructEnd()
8879
 
3431 rajveer 8880
  def validate(self):
8881
    return
8882
 
8883
 
2536 chandransh 8884
  def __repr__(self):
8885
    L = ['%s=%r' % (key, value)
8886
      for key, value in self.__dict__.iteritems()]
8887
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8888
 
8889
  def __eq__(self, other):
8890
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8891
 
8892
  def __ne__(self, other):
8893
    return not (self == other)
8894
 
8895
class requestPickupNumber_result:
8896
  """
8897
  Attributes:
8898
   - success
8899
   - ex
8900
  """
8901
 
8902
  thrift_spec = (
8903
    (0, TType.BOOL, 'success', None, None, ), # 0
8904
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
8905
  )
8906
 
8907
  def __init__(self, success=None, ex=None,):
8908
    self.success = success
8909
    self.ex = ex
8910
 
8911
  def read(self, iprot):
8912
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8913
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8914
      return
8915
    iprot.readStructBegin()
8916
    while True:
8917
      (fname, ftype, fid) = iprot.readFieldBegin()
8918
      if ftype == TType.STOP:
8919
        break
8920
      if fid == 0:
8921
        if ftype == TType.BOOL:
8922
          self.success = iprot.readBool();
8923
        else:
8924
          iprot.skip(ftype)
8925
      elif fid == 1:
8926
        if ftype == TType.STRUCT:
8927
          self.ex = TransactionServiceException()
8928
          self.ex.read(iprot)
8929
        else:
8930
          iprot.skip(ftype)
8931
      else:
8932
        iprot.skip(ftype)
8933
      iprot.readFieldEnd()
8934
    iprot.readStructEnd()
8935
 
8936
  def write(self, oprot):
8937
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
8938
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
8939
      return
8940
    oprot.writeStructBegin('requestPickupNumber_result')
3431 rajveer 8941
    if self.success is not None:
2536 chandransh 8942
      oprot.writeFieldBegin('success', TType.BOOL, 0)
8943
      oprot.writeBool(self.success)
8944
      oprot.writeFieldEnd()
3431 rajveer 8945
    if self.ex is not None:
2536 chandransh 8946
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
8947
      self.ex.write(oprot)
8948
      oprot.writeFieldEnd()
8949
    oprot.writeFieldStop()
8950
    oprot.writeStructEnd()
8951
 
3431 rajveer 8952
  def validate(self):
8953
    return
8954
 
8955
 
2536 chandransh 8956
  def __repr__(self):
8957
    L = ['%s=%r' % (key, value)
8958
      for key, value in self.__dict__.iteritems()]
8959
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
8960
 
8961
  def __eq__(self, other):
8962
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
8963
 
8964
  def __ne__(self, other):
8965
    return not (self == other)
8966
 
8967
class authorizePickup_args:
8968
  """
8969
  Attributes:
8970
   - orderId
8971
   - pickupNumber
8972
  """
8973
 
8974
  thrift_spec = (
8975
    None, # 0
8976
    (1, TType.I64, 'orderId', None, None, ), # 1
8977
    (2, TType.STRING, 'pickupNumber', None, None, ), # 2
8978
  )
8979
 
8980
  def __init__(self, orderId=None, pickupNumber=None,):
8981
    self.orderId = orderId
8982
    self.pickupNumber = pickupNumber
8983
 
8984
  def read(self, iprot):
8985
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
8986
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
8987
      return
8988
    iprot.readStructBegin()
8989
    while True:
8990
      (fname, ftype, fid) = iprot.readFieldBegin()
8991
      if ftype == TType.STOP:
8992
        break
8993
      if fid == 1:
8994
        if ftype == TType.I64:
8995
          self.orderId = iprot.readI64();
8996
        else:
8997
          iprot.skip(ftype)
8998
      elif fid == 2:
8999
        if ftype == TType.STRING:
9000
          self.pickupNumber = iprot.readString();
9001
        else:
9002
          iprot.skip(ftype)
9003
      else:
9004
        iprot.skip(ftype)
9005
      iprot.readFieldEnd()
9006
    iprot.readStructEnd()
9007
 
9008
  def write(self, oprot):
9009
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9010
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9011
      return
9012
    oprot.writeStructBegin('authorizePickup_args')
3431 rajveer 9013
    if self.orderId is not None:
2536 chandransh 9014
      oprot.writeFieldBegin('orderId', TType.I64, 1)
9015
      oprot.writeI64(self.orderId)
9016
      oprot.writeFieldEnd()
3431 rajveer 9017
    if self.pickupNumber is not None:
2536 chandransh 9018
      oprot.writeFieldBegin('pickupNumber', TType.STRING, 2)
9019
      oprot.writeString(self.pickupNumber)
9020
      oprot.writeFieldEnd()
9021
    oprot.writeFieldStop()
9022
    oprot.writeStructEnd()
9023
 
3431 rajveer 9024
  def validate(self):
9025
    return
9026
 
9027
 
2536 chandransh 9028
  def __repr__(self):
9029
    L = ['%s=%r' % (key, value)
9030
      for key, value in self.__dict__.iteritems()]
9031
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9032
 
9033
  def __eq__(self, other):
9034
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9035
 
9036
  def __ne__(self, other):
9037
    return not (self == other)
9038
 
9039
class authorizePickup_result:
9040
  """
9041
  Attributes:
9042
   - success
9043
   - ex
9044
  """
9045
 
9046
  thrift_spec = (
9047
    (0, TType.BOOL, 'success', None, None, ), # 0
9048
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
9049
  )
9050
 
9051
  def __init__(self, success=None, ex=None,):
9052
    self.success = success
9053
    self.ex = ex
9054
 
9055
  def read(self, iprot):
9056
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9057
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9058
      return
9059
    iprot.readStructBegin()
9060
    while True:
9061
      (fname, ftype, fid) = iprot.readFieldBegin()
9062
      if ftype == TType.STOP:
9063
        break
9064
      if fid == 0:
9065
        if ftype == TType.BOOL:
9066
          self.success = iprot.readBool();
9067
        else:
9068
          iprot.skip(ftype)
9069
      elif fid == 1:
9070
        if ftype == TType.STRUCT:
9071
          self.ex = TransactionServiceException()
9072
          self.ex.read(iprot)
9073
        else:
9074
          iprot.skip(ftype)
9075
      else:
9076
        iprot.skip(ftype)
9077
      iprot.readFieldEnd()
9078
    iprot.readStructEnd()
9079
 
9080
  def write(self, oprot):
9081
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9082
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9083
      return
9084
    oprot.writeStructBegin('authorizePickup_result')
3431 rajveer 9085
    if self.success is not None:
2536 chandransh 9086
      oprot.writeFieldBegin('success', TType.BOOL, 0)
9087
      oprot.writeBool(self.success)
9088
      oprot.writeFieldEnd()
3431 rajveer 9089
    if self.ex is not None:
2536 chandransh 9090
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
9091
      self.ex.write(oprot)
9092
      oprot.writeFieldEnd()
9093
    oprot.writeFieldStop()
9094
    oprot.writeStructEnd()
9095
 
3431 rajveer 9096
  def validate(self):
9097
    return
9098
 
9099
 
2536 chandransh 9100
  def __repr__(self):
9101
    L = ['%s=%r' % (key, value)
9102
      for key, value in self.__dict__.iteritems()]
9103
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9104
 
9105
  def __eq__(self, other):
9106
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9107
 
9108
  def __ne__(self, other):
9109
    return not (self == other)
9110
 
2764 chandransh 9111
class markDoasAsPickedUp_args:
9112
  """
9113
  Attributes:
9114
   - providerId
9115
   - pickupDetails
9116
  """
9117
 
9118
  thrift_spec = (
9119
    None, # 0
9120
    (1, TType.I64, 'providerId', None, None, ), # 1
9121
    (2, TType.MAP, 'pickupDetails', (TType.STRING,None,TType.STRING,None), None, ), # 2
9122
  )
9123
 
9124
  def __init__(self, providerId=None, pickupDetails=None,):
9125
    self.providerId = providerId
9126
    self.pickupDetails = pickupDetails
9127
 
9128
  def read(self, iprot):
9129
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9130
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9131
      return
9132
    iprot.readStructBegin()
9133
    while True:
9134
      (fname, ftype, fid) = iprot.readFieldBegin()
9135
      if ftype == TType.STOP:
9136
        break
9137
      if fid == 1:
9138
        if ftype == TType.I64:
9139
          self.providerId = iprot.readI64();
9140
        else:
9141
          iprot.skip(ftype)
9142
      elif fid == 2:
9143
        if ftype == TType.MAP:
9144
          self.pickupDetails = {}
3427 chandransh 9145
          (_ktype170, _vtype171, _size169 ) = iprot.readMapBegin() 
9146
          for _i173 in xrange(_size169):
9147
            _key174 = iprot.readString();
9148
            _val175 = iprot.readString();
9149
            self.pickupDetails[_key174] = _val175
2764 chandransh 9150
          iprot.readMapEnd()
9151
        else:
9152
          iprot.skip(ftype)
9153
      else:
9154
        iprot.skip(ftype)
9155
      iprot.readFieldEnd()
9156
    iprot.readStructEnd()
9157
 
9158
  def write(self, oprot):
9159
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9160
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9161
      return
9162
    oprot.writeStructBegin('markDoasAsPickedUp_args')
3431 rajveer 9163
    if self.providerId is not None:
2764 chandransh 9164
      oprot.writeFieldBegin('providerId', TType.I64, 1)
9165
      oprot.writeI64(self.providerId)
9166
      oprot.writeFieldEnd()
3431 rajveer 9167
    if self.pickupDetails is not None:
2764 chandransh 9168
      oprot.writeFieldBegin('pickupDetails', TType.MAP, 2)
9169
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.pickupDetails))
3427 chandransh 9170
      for kiter176,viter177 in self.pickupDetails.items():
9171
        oprot.writeString(kiter176)
9172
        oprot.writeString(viter177)
2764 chandransh 9173
      oprot.writeMapEnd()
9174
      oprot.writeFieldEnd()
9175
    oprot.writeFieldStop()
9176
    oprot.writeStructEnd()
9177
 
3431 rajveer 9178
  def validate(self):
9179
    return
9180
 
9181
 
2764 chandransh 9182
  def __repr__(self):
9183
    L = ['%s=%r' % (key, value)
9184
      for key, value in self.__dict__.iteritems()]
9185
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9186
 
9187
  def __eq__(self, other):
9188
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9189
 
9190
  def __ne__(self, other):
9191
    return not (self == other)
9192
 
9193
class markDoasAsPickedUp_result:
9194
  """
9195
  Attributes:
9196
   - success
9197
  """
9198
 
9199
  thrift_spec = (
9200
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
9201
  )
9202
 
9203
  def __init__(self, success=None,):
9204
    self.success = success
9205
 
9206
  def read(self, iprot):
9207
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9208
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9209
      return
9210
    iprot.readStructBegin()
9211
    while True:
9212
      (fname, ftype, fid) = iprot.readFieldBegin()
9213
      if ftype == TType.STOP:
9214
        break
9215
      if fid == 0:
9216
        if ftype == TType.LIST:
9217
          self.success = []
3427 chandransh 9218
          (_etype181, _size178) = iprot.readListBegin()
9219
          for _i182 in xrange(_size178):
9220
            _elem183 = Order()
9221
            _elem183.read(iprot)
9222
            self.success.append(_elem183)
2764 chandransh 9223
          iprot.readListEnd()
9224
        else:
9225
          iprot.skip(ftype)
9226
      else:
9227
        iprot.skip(ftype)
9228
      iprot.readFieldEnd()
9229
    iprot.readStructEnd()
9230
 
9231
  def write(self, oprot):
9232
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9233
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9234
      return
9235
    oprot.writeStructBegin('markDoasAsPickedUp_result')
3431 rajveer 9236
    if self.success is not None:
2764 chandransh 9237
      oprot.writeFieldBegin('success', TType.LIST, 0)
9238
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 9239
      for iter184 in self.success:
9240
        iter184.write(oprot)
2764 chandransh 9241
      oprot.writeListEnd()
9242
      oprot.writeFieldEnd()
9243
    oprot.writeFieldStop()
9244
    oprot.writeStructEnd()
9245
 
3431 rajveer 9246
  def validate(self):
9247
    return
9248
 
9249
 
2764 chandransh 9250
  def __repr__(self):
9251
    L = ['%s=%r' % (key, value)
9252
      for key, value in self.__dict__.iteritems()]
9253
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9254
 
9255
  def __eq__(self, other):
9256
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9257
 
9258
  def __ne__(self, other):
9259
    return not (self == other)
9260
 
2616 chandransh 9261
class receiveReturn_args:
2591 chandransh 9262
  """
9263
  Attributes:
9264
   - orderId
9265
  """
2536 chandransh 9266
 
2591 chandransh 9267
  thrift_spec = (
9268
    None, # 0
9269
    (1, TType.I64, 'orderId', None, None, ), # 1
9270
  )
9271
 
9272
  def __init__(self, orderId=None,):
9273
    self.orderId = orderId
9274
 
9275
  def read(self, iprot):
9276
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9277
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9278
      return
9279
    iprot.readStructBegin()
9280
    while True:
9281
      (fname, ftype, fid) = iprot.readFieldBegin()
9282
      if ftype == TType.STOP:
9283
        break
9284
      if fid == 1:
9285
        if ftype == TType.I64:
9286
          self.orderId = iprot.readI64();
9287
        else:
9288
          iprot.skip(ftype)
9289
      else:
9290
        iprot.skip(ftype)
9291
      iprot.readFieldEnd()
9292
    iprot.readStructEnd()
9293
 
9294
  def write(self, oprot):
9295
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9296
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9297
      return
2616 chandransh 9298
    oprot.writeStructBegin('receiveReturn_args')
3431 rajveer 9299
    if self.orderId is not None:
2591 chandransh 9300
      oprot.writeFieldBegin('orderId', TType.I64, 1)
9301
      oprot.writeI64(self.orderId)
9302
      oprot.writeFieldEnd()
9303
    oprot.writeFieldStop()
9304
    oprot.writeStructEnd()
9305
 
3431 rajveer 9306
  def validate(self):
9307
    return
9308
 
9309
 
2591 chandransh 9310
  def __repr__(self):
9311
    L = ['%s=%r' % (key, value)
9312
      for key, value in self.__dict__.iteritems()]
9313
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9314
 
9315
  def __eq__(self, other):
9316
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9317
 
9318
  def __ne__(self, other):
9319
    return not (self == other)
9320
 
2616 chandransh 9321
class receiveReturn_result:
2591 chandransh 9322
  """
9323
  Attributes:
9324
   - success
9325
   - ex
9326
  """
9327
 
9328
  thrift_spec = (
9329
    (0, TType.BOOL, 'success', None, None, ), # 0
9330
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
9331
  )
9332
 
9333
  def __init__(self, success=None, ex=None,):
9334
    self.success = success
9335
    self.ex = ex
9336
 
9337
  def read(self, iprot):
9338
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9339
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9340
      return
9341
    iprot.readStructBegin()
9342
    while True:
9343
      (fname, ftype, fid) = iprot.readFieldBegin()
9344
      if ftype == TType.STOP:
9345
        break
9346
      if fid == 0:
9347
        if ftype == TType.BOOL:
9348
          self.success = iprot.readBool();
9349
        else:
9350
          iprot.skip(ftype)
9351
      elif fid == 1:
9352
        if ftype == TType.STRUCT:
9353
          self.ex = TransactionServiceException()
9354
          self.ex.read(iprot)
9355
        else:
9356
          iprot.skip(ftype)
9357
      else:
9358
        iprot.skip(ftype)
9359
      iprot.readFieldEnd()
9360
    iprot.readStructEnd()
9361
 
9362
  def write(self, oprot):
9363
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9364
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9365
      return
2616 chandransh 9366
    oprot.writeStructBegin('receiveReturn_result')
3431 rajveer 9367
    if self.success is not None:
2591 chandransh 9368
      oprot.writeFieldBegin('success', TType.BOOL, 0)
9369
      oprot.writeBool(self.success)
9370
      oprot.writeFieldEnd()
3431 rajveer 9371
    if self.ex is not None:
2591 chandransh 9372
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
9373
      self.ex.write(oprot)
9374
      oprot.writeFieldEnd()
9375
    oprot.writeFieldStop()
9376
    oprot.writeStructEnd()
9377
 
3431 rajveer 9378
  def validate(self):
9379
    return
9380
 
9381
 
2591 chandransh 9382
  def __repr__(self):
9383
    L = ['%s=%r' % (key, value)
9384
      for key, value in self.__dict__.iteritems()]
9385
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9386
 
9387
  def __eq__(self, other):
9388
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9389
 
9390
  def __ne__(self, other):
9391
    return not (self == other)
9392
 
9393
class validateDoa_args:
9394
  """
9395
  Attributes:
9396
   - orderId
9397
   - isValid
9398
  """
9399
 
9400
  thrift_spec = (
9401
    None, # 0
9402
    (1, TType.I64, 'orderId', None, None, ), # 1
9403
    (2, TType.BOOL, 'isValid', None, None, ), # 2
9404
  )
9405
 
9406
  def __init__(self, orderId=None, isValid=None,):
9407
    self.orderId = orderId
9408
    self.isValid = isValid
9409
 
9410
  def read(self, iprot):
9411
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9412
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9413
      return
9414
    iprot.readStructBegin()
9415
    while True:
9416
      (fname, ftype, fid) = iprot.readFieldBegin()
9417
      if ftype == TType.STOP:
9418
        break
9419
      if fid == 1:
9420
        if ftype == TType.I64:
9421
          self.orderId = iprot.readI64();
9422
        else:
9423
          iprot.skip(ftype)
9424
      elif fid == 2:
9425
        if ftype == TType.BOOL:
9426
          self.isValid = iprot.readBool();
9427
        else:
9428
          iprot.skip(ftype)
9429
      else:
9430
        iprot.skip(ftype)
9431
      iprot.readFieldEnd()
9432
    iprot.readStructEnd()
9433
 
9434
  def write(self, oprot):
9435
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9436
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9437
      return
9438
    oprot.writeStructBegin('validateDoa_args')
3431 rajveer 9439
    if self.orderId is not None:
2591 chandransh 9440
      oprot.writeFieldBegin('orderId', TType.I64, 1)
9441
      oprot.writeI64(self.orderId)
9442
      oprot.writeFieldEnd()
3431 rajveer 9443
    if self.isValid is not None:
2591 chandransh 9444
      oprot.writeFieldBegin('isValid', TType.BOOL, 2)
9445
      oprot.writeBool(self.isValid)
9446
      oprot.writeFieldEnd()
9447
    oprot.writeFieldStop()
9448
    oprot.writeStructEnd()
9449
 
3431 rajveer 9450
  def validate(self):
9451
    return
9452
 
9453
 
2591 chandransh 9454
  def __repr__(self):
9455
    L = ['%s=%r' % (key, value)
9456
      for key, value in self.__dict__.iteritems()]
9457
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9458
 
9459
  def __eq__(self, other):
9460
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9461
 
9462
  def __ne__(self, other):
9463
    return not (self == other)
9464
 
9465
class validateDoa_result:
9466
  """
9467
  Attributes:
9468
   - success
9469
   - ex
9470
  """
9471
 
9472
  thrift_spec = (
9473
    (0, TType.BOOL, 'success', None, None, ), # 0
9474
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
9475
  )
9476
 
9477
  def __init__(self, success=None, ex=None,):
9478
    self.success = success
9479
    self.ex = ex
9480
 
9481
  def read(self, iprot):
9482
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9483
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9484
      return
9485
    iprot.readStructBegin()
9486
    while True:
9487
      (fname, ftype, fid) = iprot.readFieldBegin()
9488
      if ftype == TType.STOP:
9489
        break
9490
      if fid == 0:
9491
        if ftype == TType.BOOL:
9492
          self.success = iprot.readBool();
9493
        else:
9494
          iprot.skip(ftype)
9495
      elif fid == 1:
9496
        if ftype == TType.STRUCT:
9497
          self.ex = TransactionServiceException()
9498
          self.ex.read(iprot)
9499
        else:
9500
          iprot.skip(ftype)
9501
      else:
9502
        iprot.skip(ftype)
9503
      iprot.readFieldEnd()
9504
    iprot.readStructEnd()
9505
 
9506
  def write(self, oprot):
9507
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9508
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9509
      return
9510
    oprot.writeStructBegin('validateDoa_result')
3431 rajveer 9511
    if self.success is not None:
2591 chandransh 9512
      oprot.writeFieldBegin('success', TType.BOOL, 0)
9513
      oprot.writeBool(self.success)
9514
      oprot.writeFieldEnd()
3431 rajveer 9515
    if self.ex is not None:
2591 chandransh 9516
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
9517
      self.ex.write(oprot)
9518
      oprot.writeFieldEnd()
9519
    oprot.writeFieldStop()
9520
    oprot.writeStructEnd()
9521
 
3431 rajveer 9522
  def validate(self):
9523
    return
9524
 
9525
 
2591 chandransh 9526
  def __repr__(self):
9527
    L = ['%s=%r' % (key, value)
9528
      for key, value in self.__dict__.iteritems()]
9529
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9530
 
9531
  def __eq__(self, other):
9532
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9533
 
9534
  def __ne__(self, other):
9535
    return not (self == other)
9536
 
2616 chandransh 9537
class reshipOrder_args:
9538
  """
9539
  Attributes:
9540
   - orderId
9541
  """
2591 chandransh 9542
 
2616 chandransh 9543
  thrift_spec = (
9544
    None, # 0
9545
    (1, TType.I64, 'orderId', None, None, ), # 1
9546
  )
9547
 
9548
  def __init__(self, orderId=None,):
9549
    self.orderId = orderId
9550
 
9551
  def read(self, iprot):
9552
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9553
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9554
      return
9555
    iprot.readStructBegin()
9556
    while True:
9557
      (fname, ftype, fid) = iprot.readFieldBegin()
9558
      if ftype == TType.STOP:
9559
        break
9560
      if fid == 1:
9561
        if ftype == TType.I64:
9562
          self.orderId = iprot.readI64();
9563
        else:
9564
          iprot.skip(ftype)
9565
      else:
9566
        iprot.skip(ftype)
9567
      iprot.readFieldEnd()
9568
    iprot.readStructEnd()
9569
 
9570
  def write(self, oprot):
9571
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9572
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9573
      return
9574
    oprot.writeStructBegin('reshipOrder_args')
3431 rajveer 9575
    if self.orderId is not None:
2616 chandransh 9576
      oprot.writeFieldBegin('orderId', TType.I64, 1)
9577
      oprot.writeI64(self.orderId)
9578
      oprot.writeFieldEnd()
9579
    oprot.writeFieldStop()
9580
    oprot.writeStructEnd()
9581
 
3431 rajveer 9582
  def validate(self):
9583
    return
9584
 
9585
 
2616 chandransh 9586
  def __repr__(self):
9587
    L = ['%s=%r' % (key, value)
9588
      for key, value in self.__dict__.iteritems()]
9589
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9590
 
9591
  def __eq__(self, other):
9592
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9593
 
9594
  def __ne__(self, other):
9595
    return not (self == other)
9596
 
9597
class reshipOrder_result:
9598
  """
9599
  Attributes:
9600
   - success
9601
   - ex
9602
  """
9603
 
9604
  thrift_spec = (
9605
    (0, TType.I64, 'success', None, None, ), # 0
9606
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
9607
  )
9608
 
9609
  def __init__(self, success=None, ex=None,):
9610
    self.success = success
9611
    self.ex = ex
9612
 
9613
  def read(self, iprot):
9614
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9615
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9616
      return
9617
    iprot.readStructBegin()
9618
    while True:
9619
      (fname, ftype, fid) = iprot.readFieldBegin()
9620
      if ftype == TType.STOP:
9621
        break
9622
      if fid == 0:
9623
        if ftype == TType.I64:
9624
          self.success = iprot.readI64();
9625
        else:
9626
          iprot.skip(ftype)
9627
      elif fid == 1:
9628
        if ftype == TType.STRUCT:
9629
          self.ex = TransactionServiceException()
9630
          self.ex.read(iprot)
9631
        else:
9632
          iprot.skip(ftype)
9633
      else:
9634
        iprot.skip(ftype)
9635
      iprot.readFieldEnd()
9636
    iprot.readStructEnd()
9637
 
9638
  def write(self, oprot):
9639
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9640
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9641
      return
9642
    oprot.writeStructBegin('reshipOrder_result')
3431 rajveer 9643
    if self.success is not None:
2616 chandransh 9644
      oprot.writeFieldBegin('success', TType.I64, 0)
9645
      oprot.writeI64(self.success)
9646
      oprot.writeFieldEnd()
3431 rajveer 9647
    if self.ex is not None:
2616 chandransh 9648
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
9649
      self.ex.write(oprot)
9650
      oprot.writeFieldEnd()
9651
    oprot.writeFieldStop()
9652
    oprot.writeStructEnd()
9653
 
3431 rajveer 9654
  def validate(self):
9655
    return
9656
 
9657
 
2616 chandransh 9658
  def __repr__(self):
9659
    L = ['%s=%r' % (key, value)
9660
      for key, value in self.__dict__.iteritems()]
9661
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9662
 
9663
  def __eq__(self, other):
9664
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9665
 
9666
  def __ne__(self, other):
9667
    return not (self == other)
9668
 
9669
class refundOrder_args:
9670
  """
9671
  Attributes:
9672
   - orderId
3226 chandransh 9673
   - refundedBy
9674
   - reason
2616 chandransh 9675
  """
9676
 
9677
  thrift_spec = (
9678
    None, # 0
9679
    (1, TType.I64, 'orderId', None, None, ), # 1
3226 chandransh 9680
    (2, TType.STRING, 'refundedBy', None, None, ), # 2
9681
    (3, TType.STRING, 'reason', None, None, ), # 3
2616 chandransh 9682
  )
9683
 
3226 chandransh 9684
  def __init__(self, orderId=None, refundedBy=None, reason=None,):
2616 chandransh 9685
    self.orderId = orderId
3226 chandransh 9686
    self.refundedBy = refundedBy
9687
    self.reason = reason
2616 chandransh 9688
 
9689
  def read(self, iprot):
9690
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9691
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9692
      return
9693
    iprot.readStructBegin()
9694
    while True:
9695
      (fname, ftype, fid) = iprot.readFieldBegin()
9696
      if ftype == TType.STOP:
9697
        break
9698
      if fid == 1:
9699
        if ftype == TType.I64:
9700
          self.orderId = iprot.readI64();
9701
        else:
9702
          iprot.skip(ftype)
3226 chandransh 9703
      elif fid == 2:
9704
        if ftype == TType.STRING:
9705
          self.refundedBy = iprot.readString();
9706
        else:
9707
          iprot.skip(ftype)
9708
      elif fid == 3:
9709
        if ftype == TType.STRING:
9710
          self.reason = iprot.readString();
9711
        else:
9712
          iprot.skip(ftype)
2616 chandransh 9713
      else:
9714
        iprot.skip(ftype)
9715
      iprot.readFieldEnd()
9716
    iprot.readStructEnd()
9717
 
9718
  def write(self, oprot):
9719
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9720
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9721
      return
9722
    oprot.writeStructBegin('refundOrder_args')
3431 rajveer 9723
    if self.orderId is not None:
2616 chandransh 9724
      oprot.writeFieldBegin('orderId', TType.I64, 1)
9725
      oprot.writeI64(self.orderId)
9726
      oprot.writeFieldEnd()
3431 rajveer 9727
    if self.refundedBy is not None:
3226 chandransh 9728
      oprot.writeFieldBegin('refundedBy', TType.STRING, 2)
9729
      oprot.writeString(self.refundedBy)
9730
      oprot.writeFieldEnd()
3431 rajveer 9731
    if self.reason is not None:
3226 chandransh 9732
      oprot.writeFieldBegin('reason', TType.STRING, 3)
9733
      oprot.writeString(self.reason)
9734
      oprot.writeFieldEnd()
2616 chandransh 9735
    oprot.writeFieldStop()
9736
    oprot.writeStructEnd()
9737
 
3431 rajveer 9738
  def validate(self):
9739
    return
9740
 
9741
 
2616 chandransh 9742
  def __repr__(self):
9743
    L = ['%s=%r' % (key, value)
9744
      for key, value in self.__dict__.iteritems()]
9745
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9746
 
9747
  def __eq__(self, other):
9748
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9749
 
9750
  def __ne__(self, other):
9751
    return not (self == other)
9752
 
9753
class refundOrder_result:
9754
  """
9755
  Attributes:
9756
   - success
9757
   - ex
9758
  """
9759
 
9760
  thrift_spec = (
9761
    (0, TType.BOOL, 'success', None, None, ), # 0
9762
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
9763
  )
9764
 
9765
  def __init__(self, success=None, ex=None,):
9766
    self.success = success
9767
    self.ex = ex
9768
 
9769
  def read(self, iprot):
9770
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9771
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9772
      return
9773
    iprot.readStructBegin()
9774
    while True:
9775
      (fname, ftype, fid) = iprot.readFieldBegin()
9776
      if ftype == TType.STOP:
9777
        break
9778
      if fid == 0:
9779
        if ftype == TType.BOOL:
9780
          self.success = iprot.readBool();
9781
        else:
9782
          iprot.skip(ftype)
9783
      elif fid == 1:
9784
        if ftype == TType.STRUCT:
9785
          self.ex = TransactionServiceException()
9786
          self.ex.read(iprot)
9787
        else:
9788
          iprot.skip(ftype)
9789
      else:
9790
        iprot.skip(ftype)
9791
      iprot.readFieldEnd()
9792
    iprot.readStructEnd()
9793
 
9794
  def write(self, oprot):
9795
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9796
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9797
      return
9798
    oprot.writeStructBegin('refundOrder_result')
3431 rajveer 9799
    if self.success is not None:
2616 chandransh 9800
      oprot.writeFieldBegin('success', TType.BOOL, 0)
9801
      oprot.writeBool(self.success)
9802
      oprot.writeFieldEnd()
3431 rajveer 9803
    if self.ex is not None:
2616 chandransh 9804
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
9805
      self.ex.write(oprot)
9806
      oprot.writeFieldEnd()
9807
    oprot.writeFieldStop()
9808
    oprot.writeStructEnd()
9809
 
3431 rajveer 9810
  def validate(self):
9811
    return
9812
 
9813
 
2616 chandransh 9814
  def __repr__(self):
9815
    L = ['%s=%r' % (key, value)
9816
      for key, value in self.__dict__.iteritems()]
9817
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9818
 
9819
  def __eq__(self, other):
9820
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9821
 
9822
  def __ne__(self, other):
9823
    return not (self == other)
9824
 
2690 chandransh 9825
class getReturnOrders_args:
9826
  """
9827
  Attributes:
9828
   - warehouseId
9829
   - fromDate
9830
   - toDate
9831
  """
2616 chandransh 9832
 
2690 chandransh 9833
  thrift_spec = (
9834
    None, # 0
9835
    (1, TType.I64, 'warehouseId', None, None, ), # 1
9836
    (2, TType.I64, 'fromDate', None, None, ), # 2
9837
    (3, TType.I64, 'toDate', None, None, ), # 3
9838
  )
9839
 
9840
  def __init__(self, warehouseId=None, fromDate=None, toDate=None,):
9841
    self.warehouseId = warehouseId
9842
    self.fromDate = fromDate
9843
    self.toDate = toDate
9844
 
9845
  def read(self, iprot):
9846
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9847
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9848
      return
9849
    iprot.readStructBegin()
9850
    while True:
9851
      (fname, ftype, fid) = iprot.readFieldBegin()
9852
      if ftype == TType.STOP:
9853
        break
9854
      if fid == 1:
9855
        if ftype == TType.I64:
9856
          self.warehouseId = iprot.readI64();
9857
        else:
9858
          iprot.skip(ftype)
9859
      elif fid == 2:
9860
        if ftype == TType.I64:
9861
          self.fromDate = iprot.readI64();
9862
        else:
9863
          iprot.skip(ftype)
9864
      elif fid == 3:
9865
        if ftype == TType.I64:
9866
          self.toDate = iprot.readI64();
9867
        else:
9868
          iprot.skip(ftype)
9869
      else:
9870
        iprot.skip(ftype)
9871
      iprot.readFieldEnd()
9872
    iprot.readStructEnd()
9873
 
9874
  def write(self, oprot):
9875
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9876
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9877
      return
9878
    oprot.writeStructBegin('getReturnOrders_args')
3431 rajveer 9879
    if self.warehouseId is not None:
2690 chandransh 9880
      oprot.writeFieldBegin('warehouseId', TType.I64, 1)
9881
      oprot.writeI64(self.warehouseId)
9882
      oprot.writeFieldEnd()
3431 rajveer 9883
    if self.fromDate is not None:
2690 chandransh 9884
      oprot.writeFieldBegin('fromDate', TType.I64, 2)
9885
      oprot.writeI64(self.fromDate)
9886
      oprot.writeFieldEnd()
3431 rajveer 9887
    if self.toDate is not None:
2690 chandransh 9888
      oprot.writeFieldBegin('toDate', TType.I64, 3)
9889
      oprot.writeI64(self.toDate)
9890
      oprot.writeFieldEnd()
9891
    oprot.writeFieldStop()
9892
    oprot.writeStructEnd()
9893
 
3431 rajveer 9894
  def validate(self):
9895
    return
9896
 
9897
 
2690 chandransh 9898
  def __repr__(self):
9899
    L = ['%s=%r' % (key, value)
9900
      for key, value in self.__dict__.iteritems()]
9901
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9902
 
9903
  def __eq__(self, other):
9904
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9905
 
9906
  def __ne__(self, other):
9907
    return not (self == other)
9908
 
9909
class getReturnOrders_result:
9910
  """
9911
  Attributes:
9912
   - success
9913
  """
9914
 
9915
  thrift_spec = (
9916
    (0, TType.LIST, 'success', (TType.STRUCT,(ReturnOrder, ReturnOrder.thrift_spec)), None, ), # 0
9917
  )
9918
 
9919
  def __init__(self, success=None,):
9920
    self.success = success
9921
 
9922
  def read(self, iprot):
9923
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9924
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9925
      return
9926
    iprot.readStructBegin()
9927
    while True:
9928
      (fname, ftype, fid) = iprot.readFieldBegin()
9929
      if ftype == TType.STOP:
9930
        break
9931
      if fid == 0:
9932
        if ftype == TType.LIST:
9933
          self.success = []
3427 chandransh 9934
          (_etype188, _size185) = iprot.readListBegin()
9935
          for _i189 in xrange(_size185):
9936
            _elem190 = ReturnOrder()
9937
            _elem190.read(iprot)
9938
            self.success.append(_elem190)
2690 chandransh 9939
          iprot.readListEnd()
9940
        else:
9941
          iprot.skip(ftype)
9942
      else:
9943
        iprot.skip(ftype)
9944
      iprot.readFieldEnd()
9945
    iprot.readStructEnd()
9946
 
9947
  def write(self, oprot):
9948
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
9949
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
9950
      return
9951
    oprot.writeStructBegin('getReturnOrders_result')
3431 rajveer 9952
    if self.success is not None:
2690 chandransh 9953
      oprot.writeFieldBegin('success', TType.LIST, 0)
9954
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3427 chandransh 9955
      for iter191 in self.success:
9956
        iter191.write(oprot)
2690 chandransh 9957
      oprot.writeListEnd()
9958
      oprot.writeFieldEnd()
9959
    oprot.writeFieldStop()
9960
    oprot.writeStructEnd()
9961
 
3431 rajveer 9962
  def validate(self):
9963
    return
9964
 
9965
 
2690 chandransh 9966
  def __repr__(self):
9967
    L = ['%s=%r' % (key, value)
9968
      for key, value in self.__dict__.iteritems()]
9969
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
9970
 
9971
  def __eq__(self, other):
9972
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
9973
 
9974
  def __ne__(self, other):
9975
    return not (self == other)
9976
 
2700 chandransh 9977
class getReturnOrder_args:
9978
  """
9979
  Attributes:
9980
   - id
9981
  """
9982
 
9983
  thrift_spec = (
9984
    None, # 0
9985
    (1, TType.I64, 'id', None, None, ), # 1
9986
  )
9987
 
9988
  def __init__(self, id=None,):
9989
    self.id = id
9990
 
9991
  def read(self, iprot):
9992
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
9993
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
9994
      return
9995
    iprot.readStructBegin()
9996
    while True:
9997
      (fname, ftype, fid) = iprot.readFieldBegin()
9998
      if ftype == TType.STOP:
9999
        break
10000
      if fid == 1:
10001
        if ftype == TType.I64:
10002
          self.id = iprot.readI64();
10003
        else:
10004
          iprot.skip(ftype)
10005
      else:
10006
        iprot.skip(ftype)
10007
      iprot.readFieldEnd()
10008
    iprot.readStructEnd()
10009
 
10010
  def write(self, oprot):
10011
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10012
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10013
      return
10014
    oprot.writeStructBegin('getReturnOrder_args')
3431 rajveer 10015
    if self.id is not None:
2700 chandransh 10016
      oprot.writeFieldBegin('id', TType.I64, 1)
10017
      oprot.writeI64(self.id)
10018
      oprot.writeFieldEnd()
10019
    oprot.writeFieldStop()
10020
    oprot.writeStructEnd()
10021
 
3431 rajveer 10022
  def validate(self):
10023
    return
10024
 
10025
 
2700 chandransh 10026
  def __repr__(self):
10027
    L = ['%s=%r' % (key, value)
10028
      for key, value in self.__dict__.iteritems()]
10029
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10030
 
10031
  def __eq__(self, other):
10032
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10033
 
10034
  def __ne__(self, other):
10035
    return not (self == other)
10036
 
10037
class getReturnOrder_result:
10038
  """
10039
  Attributes:
10040
   - success
10041
   - ex
10042
  """
10043
 
10044
  thrift_spec = (
10045
    (0, TType.STRUCT, 'success', (ReturnOrder, ReturnOrder.thrift_spec), None, ), # 0
10046
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
10047
  )
10048
 
10049
  def __init__(self, success=None, ex=None,):
10050
    self.success = success
10051
    self.ex = ex
10052
 
10053
  def read(self, iprot):
10054
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
10055
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
10056
      return
10057
    iprot.readStructBegin()
10058
    while True:
10059
      (fname, ftype, fid) = iprot.readFieldBegin()
10060
      if ftype == TType.STOP:
10061
        break
10062
      if fid == 0:
10063
        if ftype == TType.STRUCT:
10064
          self.success = ReturnOrder()
10065
          self.success.read(iprot)
10066
        else:
10067
          iprot.skip(ftype)
10068
      elif fid == 1:
10069
        if ftype == TType.STRUCT:
10070
          self.ex = TransactionServiceException()
10071
          self.ex.read(iprot)
10072
        else:
10073
          iprot.skip(ftype)
10074
      else:
10075
        iprot.skip(ftype)
10076
      iprot.readFieldEnd()
10077
    iprot.readStructEnd()
10078
 
10079
  def write(self, oprot):
10080
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10081
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10082
      return
10083
    oprot.writeStructBegin('getReturnOrder_result')
3431 rajveer 10084
    if self.success is not None:
2700 chandransh 10085
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
10086
      self.success.write(oprot)
10087
      oprot.writeFieldEnd()
3431 rajveer 10088
    if self.ex is not None:
2700 chandransh 10089
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
10090
      self.ex.write(oprot)
10091
      oprot.writeFieldEnd()
10092
    oprot.writeFieldStop()
10093
    oprot.writeStructEnd()
10094
 
3431 rajveer 10095
  def validate(self):
10096
    return
10097
 
10098
 
2700 chandransh 10099
  def __repr__(self):
10100
    L = ['%s=%r' % (key, value)
10101
      for key, value in self.__dict__.iteritems()]
10102
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10103
 
10104
  def __eq__(self, other):
10105
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10106
 
10107
  def __ne__(self, other):
10108
    return not (self == other)
10109
 
2690 chandransh 10110
class processReturn_args:
10111
  """
10112
  Attributes:
10113
   - returnOrderId
10114
  """
10115
 
10116
  thrift_spec = (
10117
    None, # 0
10118
    (1, TType.I64, 'returnOrderId', None, None, ), # 1
10119
  )
10120
 
10121
  def __init__(self, returnOrderId=None,):
10122
    self.returnOrderId = returnOrderId
10123
 
10124
  def read(self, iprot):
10125
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
10126
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
10127
      return
10128
    iprot.readStructBegin()
10129
    while True:
10130
      (fname, ftype, fid) = iprot.readFieldBegin()
10131
      if ftype == TType.STOP:
10132
        break
10133
      if fid == 1:
10134
        if ftype == TType.I64:
10135
          self.returnOrderId = iprot.readI64();
10136
        else:
10137
          iprot.skip(ftype)
10138
      else:
10139
        iprot.skip(ftype)
10140
      iprot.readFieldEnd()
10141
    iprot.readStructEnd()
10142
 
10143
  def write(self, oprot):
10144
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10145
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10146
      return
10147
    oprot.writeStructBegin('processReturn_args')
3431 rajveer 10148
    if self.returnOrderId is not None:
2690 chandransh 10149
      oprot.writeFieldBegin('returnOrderId', TType.I64, 1)
10150
      oprot.writeI64(self.returnOrderId)
10151
      oprot.writeFieldEnd()
10152
    oprot.writeFieldStop()
10153
    oprot.writeStructEnd()
10154
 
3431 rajveer 10155
  def validate(self):
10156
    return
10157
 
10158
 
2690 chandransh 10159
  def __repr__(self):
10160
    L = ['%s=%r' % (key, value)
10161
      for key, value in self.__dict__.iteritems()]
10162
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10163
 
10164
  def __eq__(self, other):
10165
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10166
 
10167
  def __ne__(self, other):
10168
    return not (self == other)
10169
 
10170
class processReturn_result:
10171
  """
10172
  Attributes:
10173
   - ex
10174
  """
10175
 
10176
  thrift_spec = (
10177
    None, # 0
10178
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
10179
  )
10180
 
10181
  def __init__(self, ex=None,):
10182
    self.ex = ex
10183
 
10184
  def read(self, iprot):
10185
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
10186
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
10187
      return
10188
    iprot.readStructBegin()
10189
    while True:
10190
      (fname, ftype, fid) = iprot.readFieldBegin()
10191
      if ftype == TType.STOP:
10192
        break
10193
      if fid == 1:
10194
        if ftype == TType.STRUCT:
10195
          self.ex = TransactionServiceException()
10196
          self.ex.read(iprot)
10197
        else:
10198
          iprot.skip(ftype)
10199
      else:
10200
        iprot.skip(ftype)
10201
      iprot.readFieldEnd()
10202
    iprot.readStructEnd()
10203
 
10204
  def write(self, oprot):
10205
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10206
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10207
      return
10208
    oprot.writeStructBegin('processReturn_result')
3431 rajveer 10209
    if self.ex is not None:
2690 chandransh 10210
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
10211
      self.ex.write(oprot)
10212
      oprot.writeFieldEnd()
10213
    oprot.writeFieldStop()
10214
    oprot.writeStructEnd()
10215
 
3431 rajveer 10216
  def validate(self):
10217
    return
10218
 
10219
 
2690 chandransh 10220
  def __repr__(self):
10221
    L = ['%s=%r' % (key, value)
10222
      for key, value in self.__dict__.iteritems()]
10223
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10224
 
10225
  def __eq__(self, other):
10226
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10227
 
10228
  def __ne__(self, other):
10229
    return not (self == other)
10230
 
2819 chandransh 10231
class createPurchaseOrder_args:
10232
  """
10233
  Attributes:
10234
   - warehouseId
10235
  """
2690 chandransh 10236
 
2819 chandransh 10237
  thrift_spec = (
10238
    None, # 0
10239
    (1, TType.I64, 'warehouseId', None, None, ), # 1
10240
  )
10241
 
10242
  def __init__(self, warehouseId=None,):
10243
    self.warehouseId = warehouseId
10244
 
10245
  def read(self, iprot):
10246
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
10247
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
10248
      return
10249
    iprot.readStructBegin()
10250
    while True:
10251
      (fname, ftype, fid) = iprot.readFieldBegin()
10252
      if ftype == TType.STOP:
10253
        break
10254
      if fid == 1:
10255
        if ftype == TType.I64:
10256
          self.warehouseId = iprot.readI64();
10257
        else:
10258
          iprot.skip(ftype)
10259
      else:
10260
        iprot.skip(ftype)
10261
      iprot.readFieldEnd()
10262
    iprot.readStructEnd()
10263
 
10264
  def write(self, oprot):
10265
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10266
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10267
      return
10268
    oprot.writeStructBegin('createPurchaseOrder_args')
3431 rajveer 10269
    if self.warehouseId is not None:
2819 chandransh 10270
      oprot.writeFieldBegin('warehouseId', TType.I64, 1)
10271
      oprot.writeI64(self.warehouseId)
10272
      oprot.writeFieldEnd()
10273
    oprot.writeFieldStop()
10274
    oprot.writeStructEnd()
10275
 
3431 rajveer 10276
  def validate(self):
10277
    return
10278
 
10279
 
2819 chandransh 10280
  def __repr__(self):
10281
    L = ['%s=%r' % (key, value)
10282
      for key, value in self.__dict__.iteritems()]
10283
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10284
 
10285
  def __eq__(self, other):
10286
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10287
 
10288
  def __ne__(self, other):
10289
    return not (self == other)
10290
 
10291
class createPurchaseOrder_result:
10292
  """
10293
  Attributes:
10294
   - success
10295
   - ex
10296
  """
10297
 
10298
  thrift_spec = (
10299
    (0, TType.I64, 'success', None, None, ), # 0
10300
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
10301
  )
10302
 
10303
  def __init__(self, success=None, ex=None,):
10304
    self.success = success
10305
    self.ex = ex
10306
 
10307
  def read(self, iprot):
10308
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
10309
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
10310
      return
10311
    iprot.readStructBegin()
10312
    while True:
10313
      (fname, ftype, fid) = iprot.readFieldBegin()
10314
      if ftype == TType.STOP:
10315
        break
10316
      if fid == 0:
10317
        if ftype == TType.I64:
10318
          self.success = iprot.readI64();
10319
        else:
10320
          iprot.skip(ftype)
10321
      elif fid == 1:
10322
        if ftype == TType.STRUCT:
10323
          self.ex = TransactionServiceException()
10324
          self.ex.read(iprot)
10325
        else:
10326
          iprot.skip(ftype)
10327
      else:
10328
        iprot.skip(ftype)
10329
      iprot.readFieldEnd()
10330
    iprot.readStructEnd()
10331
 
10332
  def write(self, oprot):
10333
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10334
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10335
      return
10336
    oprot.writeStructBegin('createPurchaseOrder_result')
3431 rajveer 10337
    if self.success is not None:
2819 chandransh 10338
      oprot.writeFieldBegin('success', TType.I64, 0)
10339
      oprot.writeI64(self.success)
10340
      oprot.writeFieldEnd()
3431 rajveer 10341
    if self.ex is not None:
2819 chandransh 10342
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
10343
      self.ex.write(oprot)
10344
      oprot.writeFieldEnd()
10345
    oprot.writeFieldStop()
10346
    oprot.writeStructEnd()
10347
 
3431 rajveer 10348
  def validate(self):
10349
    return
10350
 
10351
 
2819 chandransh 10352
  def __repr__(self):
10353
    L = ['%s=%r' % (key, value)
10354
      for key, value in self.__dict__.iteritems()]
10355
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10356
 
10357
  def __eq__(self, other):
10358
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10359
 
10360
  def __ne__(self, other):
10361
    return not (self == other)
3451 chandransh 10362
 
10363
class updateWeight_args:
10364
  """
10365
  Attributes:
10366
   - orderId
10367
   - weight
10368
  """
10369
 
10370
  thrift_spec = (
10371
    None, # 0
10372
    (1, TType.I64, 'orderId', None, None, ), # 1
10373
    (2, TType.DOUBLE, 'weight', None, None, ), # 2
10374
  )
10375
 
10376
  def __init__(self, orderId=None, weight=None,):
10377
    self.orderId = orderId
10378
    self.weight = weight
10379
 
10380
  def read(self, iprot):
10381
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
10382
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
10383
      return
10384
    iprot.readStructBegin()
10385
    while True:
10386
      (fname, ftype, fid) = iprot.readFieldBegin()
10387
      if ftype == TType.STOP:
10388
        break
10389
      if fid == 1:
10390
        if ftype == TType.I64:
10391
          self.orderId = iprot.readI64();
10392
        else:
10393
          iprot.skip(ftype)
10394
      elif fid == 2:
10395
        if ftype == TType.DOUBLE:
10396
          self.weight = iprot.readDouble();
10397
        else:
10398
          iprot.skip(ftype)
10399
      else:
10400
        iprot.skip(ftype)
10401
      iprot.readFieldEnd()
10402
    iprot.readStructEnd()
10403
 
10404
  def write(self, oprot):
10405
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10406
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10407
      return
10408
    oprot.writeStructBegin('updateWeight_args')
10409
    if self.orderId is not None:
10410
      oprot.writeFieldBegin('orderId', TType.I64, 1)
10411
      oprot.writeI64(self.orderId)
10412
      oprot.writeFieldEnd()
10413
    if self.weight is not None:
10414
      oprot.writeFieldBegin('weight', TType.DOUBLE, 2)
10415
      oprot.writeDouble(self.weight)
10416
      oprot.writeFieldEnd()
10417
    oprot.writeFieldStop()
10418
    oprot.writeStructEnd()
10419
 
10420
  def validate(self):
10421
    return
10422
 
10423
 
10424
  def __repr__(self):
10425
    L = ['%s=%r' % (key, value)
10426
      for key, value in self.__dict__.iteritems()]
10427
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10428
 
10429
  def __eq__(self, other):
10430
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10431
 
10432
  def __ne__(self, other):
10433
    return not (self == other)
10434
 
10435
class updateWeight_result:
10436
  """
10437
  Attributes:
10438
   - success
10439
   - ex
10440
  """
10441
 
10442
  thrift_spec = (
10443
    (0, TType.STRUCT, 'success', (Order, Order.thrift_spec), None, ), # 0
10444
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
10445
  )
10446
 
10447
  def __init__(self, success=None, ex=None,):
10448
    self.success = success
10449
    self.ex = ex
10450
 
10451
  def read(self, iprot):
10452
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
10453
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
10454
      return
10455
    iprot.readStructBegin()
10456
    while True:
10457
      (fname, ftype, fid) = iprot.readFieldBegin()
10458
      if ftype == TType.STOP:
10459
        break
10460
      if fid == 0:
10461
        if ftype == TType.STRUCT:
10462
          self.success = Order()
10463
          self.success.read(iprot)
10464
        else:
10465
          iprot.skip(ftype)
10466
      elif fid == 1:
10467
        if ftype == TType.STRUCT:
10468
          self.ex = TransactionServiceException()
10469
          self.ex.read(iprot)
10470
        else:
10471
          iprot.skip(ftype)
10472
      else:
10473
        iprot.skip(ftype)
10474
      iprot.readFieldEnd()
10475
    iprot.readStructEnd()
10476
 
10477
  def write(self, oprot):
10478
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
10479
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
10480
      return
10481
    oprot.writeStructBegin('updateWeight_result')
10482
    if self.success is not None:
10483
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
10484
      self.success.write(oprot)
10485
      oprot.writeFieldEnd()
10486
    if self.ex is not None:
10487
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
10488
      self.ex.write(oprot)
10489
      oprot.writeFieldEnd()
10490
    oprot.writeFieldStop()
10491
    oprot.writeStructEnd()
10492
 
10493
  def validate(self):
10494
    return
10495
 
10496
 
10497
  def __repr__(self):
10498
    L = ['%s=%r' % (key, value)
10499
      for key, value in self.__dict__.iteritems()]
10500
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
10501
 
10502
  def __eq__(self, other):
10503
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
10504
 
10505
  def __ne__(self, other):
10506
    return not (self == other)