Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
420 ashish 1
#
3431 rajveer 2
# Autogenerated by Thrift Compiler (0.7.0)
420 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
420 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
420 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):
6050 anupam.sin 20
  def createPayment(self, userId, amount, gatewayId, txnId, isDigital):
420 ashish 21
    """
696 rajveer 22
    create a new payment and return payment id, throws an exception if gateway is not active
3431 rajveer 23
 
420 ashish 24
    Parameters:
696 rajveer 25
     - userId
420 ashish 26
     - amount
696 rajveer 27
     - gatewayId
28
     - txnId
6050 anupam.sin 29
     - isDigital
420 ashish 30
    """
31
    pass
32
 
696 rajveer 33
  def getPaymentsForUser(self, userId, fromTime, toTime, status, gatewayId):
420 ashish 34
    """
4141 chandransh 35
    Get all payments for user. If status and gateway are null, they are ignored. Same for times as well.
3431 rajveer 36
 
420 ashish 37
    Parameters:
38
     - userId
696 rajveer 39
     - fromTime
40
     - toTime
420 ashish 41
     - status
696 rajveer 42
     - gatewayId
420 ashish 43
    """
44
    pass
45
 
696 rajveer 46
  def getPayments(self, fromTime, toTime, status, gatewayId):
420 ashish 47
    """
4141 chandransh 48
    Get all payments in the given status for the given gateway. If gatewayId is 0, then it is ignored.
3431 rajveer 49
 
420 ashish 50
    Parameters:
696 rajveer 51
     - fromTime
52
     - toTime
420 ashish 53
     - status
696 rajveer 54
     - gatewayId
420 ashish 55
    """
56
    pass
57
 
4141 chandransh 58
  def getPaymentsByCapturedDate(self, fromTime, toTime, gatewayId):
59
    """
60
    Get all payments for the given gateway which were captured between the given dates. If the gatewayId is 0, it's ignored.
61
 
62
    Parameters:
63
     - fromTime
64
     - toTime
65
     - gatewayId
66
    """
67
    pass
68
 
420 ashish 69
  def getPaymentGateway(self, id):
70
    """
4141 chandransh 71
    Get the gateway for the given id.
3431 rajveer 72
 
420 ashish 73
    Parameters:
74
     - id
75
    """
76
    pass
77
 
4600 varun.gupt 78
  def getActivePaymentGateways(self, ):
79
    """
80
    Get all active Payment Gateways
81
 
82
    """
83
    pass
84
 
696 rajveer 85
  def getPayment(self, id):
420 ashish 86
    """
696 rajveer 87
    Get a particular payment info
3431 rajveer 88
 
89
 
420 ashish 90
    Parameters:
91
     - id
92
    """
93
    pass
94
 
696 rajveer 95
  def getPaymentForTxnId(self, txnId):
420 ashish 96
    """
4600 varun.gupt 97
    Get payments for a transaction. Will raise exception.
3431 rajveer 98
 
99
 
420 ashish 100
    Parameters:
696 rajveer 101
     - txnId
420 ashish 102
    """
103
    pass
104
 
4600 varun.gupt 105
  def getSuccessfulPaymentForTxnId(self, txnId):
106
    """
107
    Get successful payment for a transaction. Will raise exception.
108
 
109
 
110
    Parameters:
111
     - txnId
112
    """
113
    pass
114
 
1120 rajveer 115
  def updatePaymentDetails(self, id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes):
420 ashish 116
    """
696 rajveer 117
    mark payment successful and store parameters
3431 rajveer 118
 
119
 
420 ashish 120
    Parameters:
121
     - id
696 rajveer 122
     - gatewayPaymentId
123
     - sessionId
124
     - gatewayTxnStatus
125
     - description
126
     - gatewayTxnId
127
     - authCode
128
     - referenceCode
129
     - errorCode
130
     - status
1120 rajveer 131
     - gatewayTxnDate
696 rajveer 132
     - attributes
420 ashish 133
    """
134
    pass
135
 
1731 ankur.sing 136
  def getSuccessfulPaymentsAmountRange(self, ):
1627 ankur.sing 137
    """
1731 ankur.sing 138
    Returns the minimum and maximum amounts among successful payments.
139
    List contains two double values, first minimum and second maximum amount.
1627 ankur.sing 140
    """
141
    pass
420 ashish 142
 
2559 chandransh 143
  def initializeHdfcPayment(self, merchantPaymentId):
144
    """
145
    Initialize the payment pipe for a HDFC payment. The URL the user should be redirected to is returned.
146
    In case of any processing error, an exception is raised.
3431 rajveer 147
 
2559 chandransh 148
    Parameters:
149
     - merchantPaymentId
150
    """
151
    pass
152
 
6228 anupam.sin 153
  def doHdfcPaymentForDigitalOrder(self, merchantPaymentId, rechargeOrderId, phone):
6050 anupam.sin 154
    """
155
    Initialize the payment pipe for a HDFC payment in case of a digital order. The URL the user should be redirected to is returned.
6228 anupam.sin 156
    In case of any processing error, an exception is raised. The phone is a madatory field and is required in case of dth payments.
6050 anupam.sin 157
 
158
    Parameters:
159
     - merchantPaymentId
160
     - rechargeOrderId
6228 anupam.sin 161
     - phone
6050 anupam.sin 162
    """
163
    pass
164
 
3616 chandransh 165
  def initializeHdfcEmiPayment(self, merchantPaymentId):
166
    """
167
    Initialize the payment pipe for a HDFC EMI payment. The URL the user should be redirected to is returned.
168
    In case of any processing error, an exception is raised.
169
 
170
    Parameters:
171
     - merchantPaymentId
172
    """
173
    pass
174
 
2685 chandransh 175
  def createRefund(self, orderId, merchantTxnId, amount):
176
    """
177
    Create a refund of the given amount corresponding to the given order to be processed through the same
178
    payment gateway which processed the payment for the corresponding transaction.
2687 chandransh 179
    Returns the id of the newly created Refund.
3431 rajveer 180
 
2685 chandransh 181
    Parameters:
182
     - orderId
183
     - merchantTxnId
184
     - amount
185
    """
186
    pass
2559 chandransh 187
 
3010 chandransh 188
  def capturePayment(self, merchantTxnId):
189
    """
190
    Capture the payment for the given merchant transaction id. It processes the last payment for the given
4421 mandeep.dh 191
    transaction. If the capture attempt failed, the payment is marked as failed. PaymentException with error
192
    code 104 is	thrown in case no payments are found for the transaction id passed.
193
    PaymentException is also thrown with error code 106 in case capture was not possible due to connection
194
    issue. Here, we	payment also gets updated to CAPTURE_INPROCESS state
3431 rajveer 195
 
3010 chandransh 196
    Parameters:
197
     - merchantTxnId
198
    """
199
    pass
2685 chandransh 200
 
3956 chandransh 201
  def partiallyCapturePayment(self, merchantTxnId, amount, xferBy, xferTxnId, xferDate):
202
    """
203
    Adds the given amount to the captured amount of a COD payment.
204
    Updates the captured amount for the corresponding payment and marks it as PARTIALLY CAPTURED.
205
    If the captured amount becomes equal to total amount, then the payment status is set as SUCCESS.
206
    Also sets the name of the entity which transferred the money, the date on which it was transferred
207
    and the corresponding transaction id.
3010 chandransh 208
 
3956 chandransh 209
    Returns false if the payment couldn't be captured.
210
    Throws exception if no such payment could be found or if the captured amount will exceed the total amount after capturing.
211
 
212
    Parameters:
213
     - merchantTxnId
214
     - amount
215
     - xferBy
216
     - xferTxnId
217
     - xferDate
218
    """
219
    pass
220
 
4008 mandeep.dh 221
  def getPaymentsRequiringExtraProcessing(self, category):
222
    """
223
    Returns the list of payments that require some extra processing and
224
    which belong to a particular category. This is currently used by CRM
225
    application.
3956 chandransh 226
 
4008 mandeep.dh 227
    Parameters:
228
     - category
229
    """
230
    pass
231
 
232
  def markPaymentAsProcessed(self, paymentId, category):
233
    """
234
    Marks a particular payment as processed for a particular cateogory.
235
    It essentially deletes the payment if it is processed for a particular
236
    category. This is currently used by CRM application.
237
 
238
    Parameters:
239
     - paymentId
240
     - category
241
    """
242
    pass
243
 
244
 
3376 rajveer 245
class Client(shop2020.thriftpy.generic.GenericService.Client, Iface):
420 ashish 246
  def __init__(self, iprot, oprot=None):
3376 rajveer 247
    shop2020.thriftpy.generic.GenericService.Client.__init__(self, iprot, oprot)
420 ashish 248
 
6050 anupam.sin 249
  def createPayment(self, userId, amount, gatewayId, txnId, isDigital):
420 ashish 250
    """
696 rajveer 251
    create a new payment and return payment id, throws an exception if gateway is not active
3431 rajveer 252
 
420 ashish 253
    Parameters:
696 rajveer 254
     - userId
420 ashish 255
     - amount
696 rajveer 256
     - gatewayId
257
     - txnId
6050 anupam.sin 258
     - isDigital
420 ashish 259
    """
6050 anupam.sin 260
    self.send_createPayment(userId, amount, gatewayId, txnId, isDigital)
420 ashish 261
    return self.recv_createPayment()
262
 
6050 anupam.sin 263
  def send_createPayment(self, userId, amount, gatewayId, txnId, isDigital):
420 ashish 264
    self._oprot.writeMessageBegin('createPayment', TMessageType.CALL, self._seqid)
265
    args = createPayment_args()
696 rajveer 266
    args.userId = userId
420 ashish 267
    args.amount = amount
696 rajveer 268
    args.gatewayId = gatewayId
269
    args.txnId = txnId
6050 anupam.sin 270
    args.isDigital = isDigital
420 ashish 271
    args.write(self._oprot)
272
    self._oprot.writeMessageEnd()
273
    self._oprot.trans.flush()
274
 
275
  def recv_createPayment(self, ):
276
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
277
    if mtype == TMessageType.EXCEPTION:
278
      x = TApplicationException()
279
      x.read(self._iprot)
280
      self._iprot.readMessageEnd()
281
      raise x
282
    result = createPayment_result()
283
    result.read(self._iprot)
284
    self._iprot.readMessageEnd()
3431 rajveer 285
    if result.success is not None:
420 ashish 286
      return result.success
3431 rajveer 287
    if result.pe is not None:
420 ashish 288
      raise result.pe
289
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createPayment failed: unknown result");
290
 
696 rajveer 291
  def getPaymentsForUser(self, userId, fromTime, toTime, status, gatewayId):
420 ashish 292
    """
4141 chandransh 293
    Get all payments for user. If status and gateway are null, they are ignored. Same for times as well.
3431 rajveer 294
 
420 ashish 295
    Parameters:
296
     - userId
696 rajveer 297
     - fromTime
298
     - toTime
420 ashish 299
     - status
696 rajveer 300
     - gatewayId
420 ashish 301
    """
696 rajveer 302
    self.send_getPaymentsForUser(userId, fromTime, toTime, status, gatewayId)
420 ashish 303
    return self.recv_getPaymentsForUser()
304
 
696 rajveer 305
  def send_getPaymentsForUser(self, userId, fromTime, toTime, status, gatewayId):
420 ashish 306
    self._oprot.writeMessageBegin('getPaymentsForUser', TMessageType.CALL, self._seqid)
307
    args = getPaymentsForUser_args()
308
    args.userId = userId
696 rajveer 309
    args.fromTime = fromTime
310
    args.toTime = toTime
420 ashish 311
    args.status = status
696 rajveer 312
    args.gatewayId = gatewayId
420 ashish 313
    args.write(self._oprot)
314
    self._oprot.writeMessageEnd()
315
    self._oprot.trans.flush()
316
 
317
  def recv_getPaymentsForUser(self, ):
318
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
319
    if mtype == TMessageType.EXCEPTION:
320
      x = TApplicationException()
321
      x.read(self._iprot)
322
      self._iprot.readMessageEnd()
323
      raise x
324
    result = getPaymentsForUser_result()
325
    result.read(self._iprot)
326
    self._iprot.readMessageEnd()
3431 rajveer 327
    if result.success is not None:
420 ashish 328
      return result.success
3431 rajveer 329
    if result.pe is not None:
420 ashish 330
      raise result.pe
331
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPaymentsForUser failed: unknown result");
332
 
696 rajveer 333
  def getPayments(self, fromTime, toTime, status, gatewayId):
420 ashish 334
    """
4141 chandransh 335
    Get all payments in the given status for the given gateway. If gatewayId is 0, then it is ignored.
3431 rajveer 336
 
420 ashish 337
    Parameters:
696 rajveer 338
     - fromTime
339
     - toTime
420 ashish 340
     - status
696 rajveer 341
     - gatewayId
420 ashish 342
    """
696 rajveer 343
    self.send_getPayments(fromTime, toTime, status, gatewayId)
420 ashish 344
    return self.recv_getPayments()
345
 
696 rajveer 346
  def send_getPayments(self, fromTime, toTime, status, gatewayId):
420 ashish 347
    self._oprot.writeMessageBegin('getPayments', TMessageType.CALL, self._seqid)
348
    args = getPayments_args()
696 rajveer 349
    args.fromTime = fromTime
350
    args.toTime = toTime
420 ashish 351
    args.status = status
696 rajveer 352
    args.gatewayId = gatewayId
420 ashish 353
    args.write(self._oprot)
354
    self._oprot.writeMessageEnd()
355
    self._oprot.trans.flush()
356
 
357
  def recv_getPayments(self, ):
358
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
359
    if mtype == TMessageType.EXCEPTION:
360
      x = TApplicationException()
361
      x.read(self._iprot)
362
      self._iprot.readMessageEnd()
363
      raise x
364
    result = getPayments_result()
365
    result.read(self._iprot)
366
    self._iprot.readMessageEnd()
3431 rajveer 367
    if result.success is not None:
420 ashish 368
      return result.success
3431 rajveer 369
    if result.pe is not None:
420 ashish 370
      raise result.pe
371
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPayments failed: unknown result");
372
 
4141 chandransh 373
  def getPaymentsByCapturedDate(self, fromTime, toTime, gatewayId):
374
    """
375
    Get all payments for the given gateway which were captured between the given dates. If the gatewayId is 0, it's ignored.
376
 
377
    Parameters:
378
     - fromTime
379
     - toTime
380
     - gatewayId
381
    """
382
    self.send_getPaymentsByCapturedDate(fromTime, toTime, gatewayId)
383
    return self.recv_getPaymentsByCapturedDate()
384
 
385
  def send_getPaymentsByCapturedDate(self, fromTime, toTime, gatewayId):
386
    self._oprot.writeMessageBegin('getPaymentsByCapturedDate', TMessageType.CALL, self._seqid)
387
    args = getPaymentsByCapturedDate_args()
388
    args.fromTime = fromTime
389
    args.toTime = toTime
390
    args.gatewayId = gatewayId
391
    args.write(self._oprot)
392
    self._oprot.writeMessageEnd()
393
    self._oprot.trans.flush()
394
 
395
  def recv_getPaymentsByCapturedDate(self, ):
396
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
397
    if mtype == TMessageType.EXCEPTION:
398
      x = TApplicationException()
399
      x.read(self._iprot)
400
      self._iprot.readMessageEnd()
401
      raise x
402
    result = getPaymentsByCapturedDate_result()
403
    result.read(self._iprot)
404
    self._iprot.readMessageEnd()
405
    if result.success is not None:
406
      return result.success
407
    if result.pe is not None:
408
      raise result.pe
409
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPaymentsByCapturedDate failed: unknown result");
410
 
420 ashish 411
  def getPaymentGateway(self, id):
412
    """
4141 chandransh 413
    Get the gateway for the given id.
3431 rajveer 414
 
420 ashish 415
    Parameters:
416
     - id
417
    """
418
    self.send_getPaymentGateway(id)
419
    return self.recv_getPaymentGateway()
420
 
421
  def send_getPaymentGateway(self, id):
422
    self._oprot.writeMessageBegin('getPaymentGateway', TMessageType.CALL, self._seqid)
423
    args = getPaymentGateway_args()
424
    args.id = id
425
    args.write(self._oprot)
426
    self._oprot.writeMessageEnd()
427
    self._oprot.trans.flush()
428
 
429
  def recv_getPaymentGateway(self, ):
430
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
431
    if mtype == TMessageType.EXCEPTION:
432
      x = TApplicationException()
433
      x.read(self._iprot)
434
      self._iprot.readMessageEnd()
435
      raise x
436
    result = getPaymentGateway_result()
437
    result.read(self._iprot)
438
    self._iprot.readMessageEnd()
3431 rajveer 439
    if result.success is not None:
420 ashish 440
      return result.success
3431 rajveer 441
    if result.pe is not None:
420 ashish 442
      raise result.pe
443
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPaymentGateway failed: unknown result");
444
 
4600 varun.gupt 445
  def getActivePaymentGateways(self, ):
446
    """
447
    Get all active Payment Gateways
448
 
449
    """
450
    self.send_getActivePaymentGateways()
451
    return self.recv_getActivePaymentGateways()
452
 
453
  def send_getActivePaymentGateways(self, ):
454
    self._oprot.writeMessageBegin('getActivePaymentGateways', TMessageType.CALL, self._seqid)
455
    args = getActivePaymentGateways_args()
456
    args.write(self._oprot)
457
    self._oprot.writeMessageEnd()
458
    self._oprot.trans.flush()
459
 
460
  def recv_getActivePaymentGateways(self, ):
461
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
462
    if mtype == TMessageType.EXCEPTION:
463
      x = TApplicationException()
464
      x.read(self._iprot)
465
      self._iprot.readMessageEnd()
466
      raise x
467
    result = getActivePaymentGateways_result()
468
    result.read(self._iprot)
469
    self._iprot.readMessageEnd()
470
    if result.success is not None:
471
      return result.success
472
    if result.pe is not None:
473
      raise result.pe
474
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getActivePaymentGateways failed: unknown result");
475
 
696 rajveer 476
  def getPayment(self, id):
420 ashish 477
    """
696 rajveer 478
    Get a particular payment info
3431 rajveer 479
 
480
 
420 ashish 481
    Parameters:
482
     - id
483
    """
696 rajveer 484
    self.send_getPayment(id)
485
    return self.recv_getPayment()
420 ashish 486
 
696 rajveer 487
  def send_getPayment(self, id):
488
    self._oprot.writeMessageBegin('getPayment', TMessageType.CALL, self._seqid)
489
    args = getPayment_args()
420 ashish 490
    args.id = id
491
    args.write(self._oprot)
492
    self._oprot.writeMessageEnd()
493
    self._oprot.trans.flush()
494
 
696 rajveer 495
  def recv_getPayment(self, ):
420 ashish 496
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
497
    if mtype == TMessageType.EXCEPTION:
498
      x = TApplicationException()
499
      x.read(self._iprot)
500
      self._iprot.readMessageEnd()
501
      raise x
696 rajveer 502
    result = getPayment_result()
420 ashish 503
    result.read(self._iprot)
504
    self._iprot.readMessageEnd()
3431 rajveer 505
    if result.success is not None:
696 rajveer 506
      return result.success
3431 rajveer 507
    if result.pe is not None:
420 ashish 508
      raise result.pe
696 rajveer 509
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPayment failed: unknown result");
420 ashish 510
 
696 rajveer 511
  def getPaymentForTxnId(self, txnId):
420 ashish 512
    """
4600 varun.gupt 513
    Get payments for a transaction. Will raise exception.
3431 rajveer 514
 
515
 
420 ashish 516
    Parameters:
696 rajveer 517
     - txnId
420 ashish 518
    """
696 rajveer 519
    self.send_getPaymentForTxnId(txnId)
520
    return self.recv_getPaymentForTxnId()
420 ashish 521
 
696 rajveer 522
  def send_getPaymentForTxnId(self, txnId):
523
    self._oprot.writeMessageBegin('getPaymentForTxnId', TMessageType.CALL, self._seqid)
524
    args = getPaymentForTxnId_args()
525
    args.txnId = txnId
420 ashish 526
    args.write(self._oprot)
527
    self._oprot.writeMessageEnd()
528
    self._oprot.trans.flush()
529
 
696 rajveer 530
  def recv_getPaymentForTxnId(self, ):
420 ashish 531
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
532
    if mtype == TMessageType.EXCEPTION:
533
      x = TApplicationException()
534
      x.read(self._iprot)
535
      self._iprot.readMessageEnd()
536
      raise x
696 rajveer 537
    result = getPaymentForTxnId_result()
420 ashish 538
    result.read(self._iprot)
539
    self._iprot.readMessageEnd()
3431 rajveer 540
    if result.success is not None:
420 ashish 541
      return result.success
3431 rajveer 542
    if result.pe is not None:
420 ashish 543
      raise result.pe
696 rajveer 544
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPaymentForTxnId failed: unknown result");
420 ashish 545
 
4600 varun.gupt 546
  def getSuccessfulPaymentForTxnId(self, txnId):
547
    """
548
    Get successful payment for a transaction. Will raise exception.
549
 
550
 
551
    Parameters:
552
     - txnId
553
    """
554
    self.send_getSuccessfulPaymentForTxnId(txnId)
555
    return self.recv_getSuccessfulPaymentForTxnId()
556
 
557
  def send_getSuccessfulPaymentForTxnId(self, txnId):
558
    self._oprot.writeMessageBegin('getSuccessfulPaymentForTxnId', TMessageType.CALL, self._seqid)
559
    args = getSuccessfulPaymentForTxnId_args()
560
    args.txnId = txnId
561
    args.write(self._oprot)
562
    self._oprot.writeMessageEnd()
563
    self._oprot.trans.flush()
564
 
565
  def recv_getSuccessfulPaymentForTxnId(self, ):
566
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
567
    if mtype == TMessageType.EXCEPTION:
568
      x = TApplicationException()
569
      x.read(self._iprot)
570
      self._iprot.readMessageEnd()
571
      raise x
572
    result = getSuccessfulPaymentForTxnId_result()
573
    result.read(self._iprot)
574
    self._iprot.readMessageEnd()
575
    if result.success is not None:
576
      return result.success
577
    if result.pe is not None:
578
      raise result.pe
579
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getSuccessfulPaymentForTxnId failed: unknown result");
580
 
1120 rajveer 581
  def updatePaymentDetails(self, id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes):
420 ashish 582
    """
696 rajveer 583
    mark payment successful and store parameters
3431 rajveer 584
 
585
 
420 ashish 586
    Parameters:
587
     - id
696 rajveer 588
     - gatewayPaymentId
589
     - sessionId
590
     - gatewayTxnStatus
591
     - description
592
     - gatewayTxnId
593
     - authCode
594
     - referenceCode
595
     - errorCode
596
     - status
1120 rajveer 597
     - gatewayTxnDate
696 rajveer 598
     - attributes
420 ashish 599
    """
1120 rajveer 600
    self.send_updatePaymentDetails(id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes)
696 rajveer 601
    return self.recv_updatePaymentDetails()
420 ashish 602
 
1120 rajveer 603
  def send_updatePaymentDetails(self, id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes):
696 rajveer 604
    self._oprot.writeMessageBegin('updatePaymentDetails', TMessageType.CALL, self._seqid)
605
    args = updatePaymentDetails_args()
420 ashish 606
    args.id = id
696 rajveer 607
    args.gatewayPaymentId = gatewayPaymentId
608
    args.sessionId = sessionId
609
    args.gatewayTxnStatus = gatewayTxnStatus
610
    args.description = description
611
    args.gatewayTxnId = gatewayTxnId
612
    args.authCode = authCode
613
    args.referenceCode = referenceCode
614
    args.errorCode = errorCode
615
    args.status = status
1120 rajveer 616
    args.gatewayTxnDate = gatewayTxnDate
696 rajveer 617
    args.attributes = attributes
420 ashish 618
    args.write(self._oprot)
619
    self._oprot.writeMessageEnd()
620
    self._oprot.trans.flush()
621
 
696 rajveer 622
  def recv_updatePaymentDetails(self, ):
420 ashish 623
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
624
    if mtype == TMessageType.EXCEPTION:
625
      x = TApplicationException()
626
      x.read(self._iprot)
627
      self._iprot.readMessageEnd()
628
      raise x
696 rajveer 629
    result = updatePaymentDetails_result()
420 ashish 630
    result.read(self._iprot)
631
    self._iprot.readMessageEnd()
3431 rajveer 632
    if result.success is not None:
696 rajveer 633
      return result.success
3431 rajveer 634
    if result.pe is not None:
420 ashish 635
      raise result.pe
696 rajveer 636
    raise TApplicationException(TApplicationException.MISSING_RESULT, "updatePaymentDetails failed: unknown result");
420 ashish 637
 
1731 ankur.sing 638
  def getSuccessfulPaymentsAmountRange(self, ):
1627 ankur.sing 639
    """
1731 ankur.sing 640
    Returns the minimum and maximum amounts among successful payments.
641
    List contains two double values, first minimum and second maximum amount.
1627 ankur.sing 642
    """
1731 ankur.sing 643
    self.send_getSuccessfulPaymentsAmountRange()
644
    return self.recv_getSuccessfulPaymentsAmountRange()
420 ashish 645
 
1731 ankur.sing 646
  def send_getSuccessfulPaymentsAmountRange(self, ):
647
    self._oprot.writeMessageBegin('getSuccessfulPaymentsAmountRange', TMessageType.CALL, self._seqid)
648
    args = getSuccessfulPaymentsAmountRange_args()
1627 ankur.sing 649
    args.write(self._oprot)
650
    self._oprot.writeMessageEnd()
651
    self._oprot.trans.flush()
652
 
1731 ankur.sing 653
  def recv_getSuccessfulPaymentsAmountRange(self, ):
1627 ankur.sing 654
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
655
    if mtype == TMessageType.EXCEPTION:
656
      x = TApplicationException()
657
      x.read(self._iprot)
658
      self._iprot.readMessageEnd()
659
      raise x
1731 ankur.sing 660
    result = getSuccessfulPaymentsAmountRange_result()
1627 ankur.sing 661
    result.read(self._iprot)
662
    self._iprot.readMessageEnd()
3431 rajveer 663
    if result.success is not None:
1627 ankur.sing 664
      return result.success
1731 ankur.sing 665
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getSuccessfulPaymentsAmountRange failed: unknown result");
1627 ankur.sing 666
 
2559 chandransh 667
  def initializeHdfcPayment(self, merchantPaymentId):
668
    """
669
    Initialize the payment pipe for a HDFC payment. The URL the user should be redirected to is returned.
670
    In case of any processing error, an exception is raised.
3431 rajveer 671
 
2559 chandransh 672
    Parameters:
673
     - merchantPaymentId
674
    """
675
    self.send_initializeHdfcPayment(merchantPaymentId)
676
    return self.recv_initializeHdfcPayment()
677
 
678
  def send_initializeHdfcPayment(self, merchantPaymentId):
679
    self._oprot.writeMessageBegin('initializeHdfcPayment', TMessageType.CALL, self._seqid)
680
    args = initializeHdfcPayment_args()
681
    args.merchantPaymentId = merchantPaymentId
682
    args.write(self._oprot)
683
    self._oprot.writeMessageEnd()
684
    self._oprot.trans.flush()
685
 
686
  def recv_initializeHdfcPayment(self, ):
687
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
688
    if mtype == TMessageType.EXCEPTION:
689
      x = TApplicationException()
690
      x.read(self._iprot)
691
      self._iprot.readMessageEnd()
692
      raise x
693
    result = initializeHdfcPayment_result()
694
    result.read(self._iprot)
695
    self._iprot.readMessageEnd()
3431 rajveer 696
    if result.success is not None:
2559 chandransh 697
      return result.success
3431 rajveer 698
    if result.pe is not None:
2559 chandransh 699
      raise result.pe
700
    raise TApplicationException(TApplicationException.MISSING_RESULT, "initializeHdfcPayment failed: unknown result");
701
 
6228 anupam.sin 702
  def doHdfcPaymentForDigitalOrder(self, merchantPaymentId, rechargeOrderId, phone):
6050 anupam.sin 703
    """
704
    Initialize the payment pipe for a HDFC payment in case of a digital order. The URL the user should be redirected to is returned.
6228 anupam.sin 705
    In case of any processing error, an exception is raised. The phone is a madatory field and is required in case of dth payments.
6050 anupam.sin 706
 
707
    Parameters:
708
     - merchantPaymentId
709
     - rechargeOrderId
6228 anupam.sin 710
     - phone
6050 anupam.sin 711
    """
6228 anupam.sin 712
    self.send_doHdfcPaymentForDigitalOrder(merchantPaymentId, rechargeOrderId, phone)
6050 anupam.sin 713
    return self.recv_doHdfcPaymentForDigitalOrder()
714
 
6228 anupam.sin 715
  def send_doHdfcPaymentForDigitalOrder(self, merchantPaymentId, rechargeOrderId, phone):
6050 anupam.sin 716
    self._oprot.writeMessageBegin('doHdfcPaymentForDigitalOrder', TMessageType.CALL, self._seqid)
717
    args = doHdfcPaymentForDigitalOrder_args()
718
    args.merchantPaymentId = merchantPaymentId
719
    args.rechargeOrderId = rechargeOrderId
6228 anupam.sin 720
    args.phone = phone
6050 anupam.sin 721
    args.write(self._oprot)
722
    self._oprot.writeMessageEnd()
723
    self._oprot.trans.flush()
724
 
725
  def recv_doHdfcPaymentForDigitalOrder(self, ):
726
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
727
    if mtype == TMessageType.EXCEPTION:
728
      x = TApplicationException()
729
      x.read(self._iprot)
730
      self._iprot.readMessageEnd()
731
      raise x
732
    result = doHdfcPaymentForDigitalOrder_result()
733
    result.read(self._iprot)
734
    self._iprot.readMessageEnd()
735
    if result.success is not None:
736
      return result.success
737
    if result.pe is not None:
738
      raise result.pe
739
    raise TApplicationException(TApplicationException.MISSING_RESULT, "doHdfcPaymentForDigitalOrder failed: unknown result");
740
 
3616 chandransh 741
  def initializeHdfcEmiPayment(self, merchantPaymentId):
742
    """
743
    Initialize the payment pipe for a HDFC EMI payment. The URL the user should be redirected to is returned.
744
    In case of any processing error, an exception is raised.
745
 
746
    Parameters:
747
     - merchantPaymentId
748
    """
749
    self.send_initializeHdfcEmiPayment(merchantPaymentId)
750
    return self.recv_initializeHdfcEmiPayment()
751
 
752
  def send_initializeHdfcEmiPayment(self, merchantPaymentId):
753
    self._oprot.writeMessageBegin('initializeHdfcEmiPayment', TMessageType.CALL, self._seqid)
754
    args = initializeHdfcEmiPayment_args()
755
    args.merchantPaymentId = merchantPaymentId
756
    args.write(self._oprot)
757
    self._oprot.writeMessageEnd()
758
    self._oprot.trans.flush()
759
 
760
  def recv_initializeHdfcEmiPayment(self, ):
761
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
762
    if mtype == TMessageType.EXCEPTION:
763
      x = TApplicationException()
764
      x.read(self._iprot)
765
      self._iprot.readMessageEnd()
766
      raise x
767
    result = initializeHdfcEmiPayment_result()
768
    result.read(self._iprot)
769
    self._iprot.readMessageEnd()
770
    if result.success is not None:
771
      return result.success
772
    if result.pe is not None:
773
      raise result.pe
774
    raise TApplicationException(TApplicationException.MISSING_RESULT, "initializeHdfcEmiPayment failed: unknown result");
775
 
2685 chandransh 776
  def createRefund(self, orderId, merchantTxnId, amount):
777
    """
778
    Create a refund of the given amount corresponding to the given order to be processed through the same
779
    payment gateway which processed the payment for the corresponding transaction.
2687 chandransh 780
    Returns the id of the newly created Refund.
3431 rajveer 781
 
2685 chandransh 782
    Parameters:
783
     - orderId
784
     - merchantTxnId
785
     - amount
786
    """
787
    self.send_createRefund(orderId, merchantTxnId, amount)
788
    return self.recv_createRefund()
2559 chandransh 789
 
2685 chandransh 790
  def send_createRefund(self, orderId, merchantTxnId, amount):
791
    self._oprot.writeMessageBegin('createRefund', TMessageType.CALL, self._seqid)
792
    args = createRefund_args()
793
    args.orderId = orderId
794
    args.merchantTxnId = merchantTxnId
795
    args.amount = amount
796
    args.write(self._oprot)
797
    self._oprot.writeMessageEnd()
798
    self._oprot.trans.flush()
799
 
800
  def recv_createRefund(self, ):
801
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
802
    if mtype == TMessageType.EXCEPTION:
803
      x = TApplicationException()
804
      x.read(self._iprot)
805
      self._iprot.readMessageEnd()
806
      raise x
807
    result = createRefund_result()
808
    result.read(self._iprot)
809
    self._iprot.readMessageEnd()
3431 rajveer 810
    if result.success is not None:
2685 chandransh 811
      return result.success
3431 rajveer 812
    if result.pe is not None:
2685 chandransh 813
      raise result.pe
814
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createRefund failed: unknown result");
815
 
3010 chandransh 816
  def capturePayment(self, merchantTxnId):
817
    """
818
    Capture the payment for the given merchant transaction id. It processes the last payment for the given
4421 mandeep.dh 819
    transaction. If the capture attempt failed, the payment is marked as failed. PaymentException with error
820
    code 104 is	thrown in case no payments are found for the transaction id passed.
821
    PaymentException is also thrown with error code 106 in case capture was not possible due to connection
822
    issue. Here, we	payment also gets updated to CAPTURE_INPROCESS state
3431 rajveer 823
 
3010 chandransh 824
    Parameters:
825
     - merchantTxnId
826
    """
827
    self.send_capturePayment(merchantTxnId)
828
    return self.recv_capturePayment()
2685 chandransh 829
 
3010 chandransh 830
  def send_capturePayment(self, merchantTxnId):
831
    self._oprot.writeMessageBegin('capturePayment', TMessageType.CALL, self._seqid)
832
    args = capturePayment_args()
833
    args.merchantTxnId = merchantTxnId
834
    args.write(self._oprot)
835
    self._oprot.writeMessageEnd()
836
    self._oprot.trans.flush()
837
 
838
  def recv_capturePayment(self, ):
839
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
840
    if mtype == TMessageType.EXCEPTION:
841
      x = TApplicationException()
842
      x.read(self._iprot)
843
      self._iprot.readMessageEnd()
844
      raise x
845
    result = capturePayment_result()
846
    result.read(self._iprot)
847
    self._iprot.readMessageEnd()
3431 rajveer 848
    if result.success is not None:
3010 chandransh 849
      return result.success
3431 rajveer 850
    if result.pe is not None:
3010 chandransh 851
      raise result.pe
852
    raise TApplicationException(TApplicationException.MISSING_RESULT, "capturePayment failed: unknown result");
853
 
3956 chandransh 854
  def partiallyCapturePayment(self, merchantTxnId, amount, xferBy, xferTxnId, xferDate):
855
    """
856
    Adds the given amount to the captured amount of a COD payment.
857
    Updates the captured amount for the corresponding payment and marks it as PARTIALLY CAPTURED.
858
    If the captured amount becomes equal to total amount, then the payment status is set as SUCCESS.
859
    Also sets the name of the entity which transferred the money, the date on which it was transferred
860
    and the corresponding transaction id.
3010 chandransh 861
 
3956 chandransh 862
    Returns false if the payment couldn't be captured.
863
    Throws exception if no such payment could be found or if the captured amount will exceed the total amount after capturing.
864
 
865
    Parameters:
866
     - merchantTxnId
867
     - amount
868
     - xferBy
869
     - xferTxnId
870
     - xferDate
871
    """
872
    self.send_partiallyCapturePayment(merchantTxnId, amount, xferBy, xferTxnId, xferDate)
873
    return self.recv_partiallyCapturePayment()
874
 
875
  def send_partiallyCapturePayment(self, merchantTxnId, amount, xferBy, xferTxnId, xferDate):
876
    self._oprot.writeMessageBegin('partiallyCapturePayment', TMessageType.CALL, self._seqid)
877
    args = partiallyCapturePayment_args()
878
    args.merchantTxnId = merchantTxnId
879
    args.amount = amount
880
    args.xferBy = xferBy
881
    args.xferTxnId = xferTxnId
882
    args.xferDate = xferDate
883
    args.write(self._oprot)
884
    self._oprot.writeMessageEnd()
885
    self._oprot.trans.flush()
886
 
887
  def recv_partiallyCapturePayment(self, ):
888
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
889
    if mtype == TMessageType.EXCEPTION:
890
      x = TApplicationException()
891
      x.read(self._iprot)
892
      self._iprot.readMessageEnd()
893
      raise x
894
    result = partiallyCapturePayment_result()
895
    result.read(self._iprot)
896
    self._iprot.readMessageEnd()
897
    if result.success is not None:
898
      return result.success
899
    if result.pe is not None:
900
      raise result.pe
901
    raise TApplicationException(TApplicationException.MISSING_RESULT, "partiallyCapturePayment failed: unknown result");
902
 
4008 mandeep.dh 903
  def getPaymentsRequiringExtraProcessing(self, category):
904
    """
905
    Returns the list of payments that require some extra processing and
906
    which belong to a particular category. This is currently used by CRM
907
    application.
3956 chandransh 908
 
4008 mandeep.dh 909
    Parameters:
910
     - category
911
    """
912
    self.send_getPaymentsRequiringExtraProcessing(category)
913
    return self.recv_getPaymentsRequiringExtraProcessing()
914
 
915
  def send_getPaymentsRequiringExtraProcessing(self, category):
916
    self._oprot.writeMessageBegin('getPaymentsRequiringExtraProcessing', TMessageType.CALL, self._seqid)
917
    args = getPaymentsRequiringExtraProcessing_args()
918
    args.category = category
919
    args.write(self._oprot)
920
    self._oprot.writeMessageEnd()
921
    self._oprot.trans.flush()
922
 
923
  def recv_getPaymentsRequiringExtraProcessing(self, ):
924
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
925
    if mtype == TMessageType.EXCEPTION:
926
      x = TApplicationException()
927
      x.read(self._iprot)
928
      self._iprot.readMessageEnd()
929
      raise x
930
    result = getPaymentsRequiringExtraProcessing_result()
931
    result.read(self._iprot)
932
    self._iprot.readMessageEnd()
933
    if result.success is not None:
934
      return result.success
935
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getPaymentsRequiringExtraProcessing failed: unknown result");
936
 
937
  def markPaymentAsProcessed(self, paymentId, category):
938
    """
939
    Marks a particular payment as processed for a particular cateogory.
940
    It essentially deletes the payment if it is processed for a particular
941
    category. This is currently used by CRM application.
942
 
943
    Parameters:
944
     - paymentId
945
     - category
946
    """
947
    self.send_markPaymentAsProcessed(paymentId, category)
948
    self.recv_markPaymentAsProcessed()
949
 
950
  def send_markPaymentAsProcessed(self, paymentId, category):
951
    self._oprot.writeMessageBegin('markPaymentAsProcessed', TMessageType.CALL, self._seqid)
952
    args = markPaymentAsProcessed_args()
953
    args.paymentId = paymentId
954
    args.category = category
955
    args.write(self._oprot)
956
    self._oprot.writeMessageEnd()
957
    self._oprot.trans.flush()
958
 
959
  def recv_markPaymentAsProcessed(self, ):
960
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
961
    if mtype == TMessageType.EXCEPTION:
962
      x = TApplicationException()
963
      x.read(self._iprot)
964
      self._iprot.readMessageEnd()
965
      raise x
966
    result = markPaymentAsProcessed_result()
967
    result.read(self._iprot)
968
    self._iprot.readMessageEnd()
969
    return
970
 
971
 
3376 rajveer 972
class Processor(shop2020.thriftpy.generic.GenericService.Processor, Iface, TProcessor):
420 ashish 973
  def __init__(self, handler):
3376 rajveer 974
    shop2020.thriftpy.generic.GenericService.Processor.__init__(self, handler)
420 ashish 975
    self._processMap["createPayment"] = Processor.process_createPayment
976
    self._processMap["getPaymentsForUser"] = Processor.process_getPaymentsForUser
977
    self._processMap["getPayments"] = Processor.process_getPayments
4141 chandransh 978
    self._processMap["getPaymentsByCapturedDate"] = Processor.process_getPaymentsByCapturedDate
420 ashish 979
    self._processMap["getPaymentGateway"] = Processor.process_getPaymentGateway
4600 varun.gupt 980
    self._processMap["getActivePaymentGateways"] = Processor.process_getActivePaymentGateways
420 ashish 981
    self._processMap["getPayment"] = Processor.process_getPayment
696 rajveer 982
    self._processMap["getPaymentForTxnId"] = Processor.process_getPaymentForTxnId
4600 varun.gupt 983
    self._processMap["getSuccessfulPaymentForTxnId"] = Processor.process_getSuccessfulPaymentForTxnId
696 rajveer 984
    self._processMap["updatePaymentDetails"] = Processor.process_updatePaymentDetails
1731 ankur.sing 985
    self._processMap["getSuccessfulPaymentsAmountRange"] = Processor.process_getSuccessfulPaymentsAmountRange
2559 chandransh 986
    self._processMap["initializeHdfcPayment"] = Processor.process_initializeHdfcPayment
6050 anupam.sin 987
    self._processMap["doHdfcPaymentForDigitalOrder"] = Processor.process_doHdfcPaymentForDigitalOrder
3616 chandransh 988
    self._processMap["initializeHdfcEmiPayment"] = Processor.process_initializeHdfcEmiPayment
2685 chandransh 989
    self._processMap["createRefund"] = Processor.process_createRefund
3010 chandransh 990
    self._processMap["capturePayment"] = Processor.process_capturePayment
3956 chandransh 991
    self._processMap["partiallyCapturePayment"] = Processor.process_partiallyCapturePayment
4008 mandeep.dh 992
    self._processMap["getPaymentsRequiringExtraProcessing"] = Processor.process_getPaymentsRequiringExtraProcessing
993
    self._processMap["markPaymentAsProcessed"] = Processor.process_markPaymentAsProcessed
420 ashish 994
 
995
  def process(self, iprot, oprot):
996
    (name, type, seqid) = iprot.readMessageBegin()
997
    if name not in self._processMap:
998
      iprot.skip(TType.STRUCT)
999
      iprot.readMessageEnd()
1000
      x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
1001
      oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
1002
      x.write(oprot)
1003
      oprot.writeMessageEnd()
1004
      oprot.trans.flush()
1005
      return
1006
    else:
1007
      self._processMap[name](self, seqid, iprot, oprot)
1008
    return True
1009
 
1010
  def process_createPayment(self, seqid, iprot, oprot):
1011
    args = createPayment_args()
1012
    args.read(iprot)
1013
    iprot.readMessageEnd()
1014
    result = createPayment_result()
1015
    try:
6050 anupam.sin 1016
      result.success = self._handler.createPayment(args.userId, args.amount, args.gatewayId, args.txnId, args.isDigital)
420 ashish 1017
    except PaymentException, pe:
1018
      result.pe = pe
1019
    oprot.writeMessageBegin("createPayment", TMessageType.REPLY, seqid)
1020
    result.write(oprot)
1021
    oprot.writeMessageEnd()
1022
    oprot.trans.flush()
1023
 
1024
  def process_getPaymentsForUser(self, seqid, iprot, oprot):
1025
    args = getPaymentsForUser_args()
1026
    args.read(iprot)
1027
    iprot.readMessageEnd()
1028
    result = getPaymentsForUser_result()
1029
    try:
696 rajveer 1030
      result.success = self._handler.getPaymentsForUser(args.userId, args.fromTime, args.toTime, args.status, args.gatewayId)
420 ashish 1031
    except PaymentException, pe:
1032
      result.pe = pe
1033
    oprot.writeMessageBegin("getPaymentsForUser", TMessageType.REPLY, seqid)
1034
    result.write(oprot)
1035
    oprot.writeMessageEnd()
1036
    oprot.trans.flush()
1037
 
1038
  def process_getPayments(self, seqid, iprot, oprot):
1039
    args = getPayments_args()
1040
    args.read(iprot)
1041
    iprot.readMessageEnd()
1042
    result = getPayments_result()
1043
    try:
696 rajveer 1044
      result.success = self._handler.getPayments(args.fromTime, args.toTime, args.status, args.gatewayId)
420 ashish 1045
    except PaymentException, pe:
1046
      result.pe = pe
1047
    oprot.writeMessageBegin("getPayments", TMessageType.REPLY, seqid)
1048
    result.write(oprot)
1049
    oprot.writeMessageEnd()
1050
    oprot.trans.flush()
1051
 
4141 chandransh 1052
  def process_getPaymentsByCapturedDate(self, seqid, iprot, oprot):
1053
    args = getPaymentsByCapturedDate_args()
1054
    args.read(iprot)
1055
    iprot.readMessageEnd()
1056
    result = getPaymentsByCapturedDate_result()
1057
    try:
1058
      result.success = self._handler.getPaymentsByCapturedDate(args.fromTime, args.toTime, args.gatewayId)
1059
    except PaymentException, pe:
1060
      result.pe = pe
1061
    oprot.writeMessageBegin("getPaymentsByCapturedDate", TMessageType.REPLY, seqid)
1062
    result.write(oprot)
1063
    oprot.writeMessageEnd()
1064
    oprot.trans.flush()
1065
 
420 ashish 1066
  def process_getPaymentGateway(self, seqid, iprot, oprot):
1067
    args = getPaymentGateway_args()
1068
    args.read(iprot)
1069
    iprot.readMessageEnd()
1070
    result = getPaymentGateway_result()
1071
    try:
1072
      result.success = self._handler.getPaymentGateway(args.id)
1073
    except PaymentException, pe:
1074
      result.pe = pe
1075
    oprot.writeMessageBegin("getPaymentGateway", TMessageType.REPLY, seqid)
1076
    result.write(oprot)
1077
    oprot.writeMessageEnd()
1078
    oprot.trans.flush()
1079
 
4600 varun.gupt 1080
  def process_getActivePaymentGateways(self, seqid, iprot, oprot):
1081
    args = getActivePaymentGateways_args()
1082
    args.read(iprot)
1083
    iprot.readMessageEnd()
1084
    result = getActivePaymentGateways_result()
1085
    try:
1086
      result.success = self._handler.getActivePaymentGateways()
1087
    except PaymentException, pe:
1088
      result.pe = pe
1089
    oprot.writeMessageBegin("getActivePaymentGateways", TMessageType.REPLY, seqid)
1090
    result.write(oprot)
1091
    oprot.writeMessageEnd()
1092
    oprot.trans.flush()
1093
 
696 rajveer 1094
  def process_getPayment(self, seqid, iprot, oprot):
1095
    args = getPayment_args()
420 ashish 1096
    args.read(iprot)
1097
    iprot.readMessageEnd()
696 rajveer 1098
    result = getPayment_result()
420 ashish 1099
    try:
696 rajveer 1100
      result.success = self._handler.getPayment(args.id)
420 ashish 1101
    except PaymentException, pe:
1102
      result.pe = pe
696 rajveer 1103
    oprot.writeMessageBegin("getPayment", TMessageType.REPLY, seqid)
420 ashish 1104
    result.write(oprot)
1105
    oprot.writeMessageEnd()
1106
    oprot.trans.flush()
1107
 
696 rajveer 1108
  def process_getPaymentForTxnId(self, seqid, iprot, oprot):
1109
    args = getPaymentForTxnId_args()
420 ashish 1110
    args.read(iprot)
1111
    iprot.readMessageEnd()
696 rajveer 1112
    result = getPaymentForTxnId_result()
420 ashish 1113
    try:
696 rajveer 1114
      result.success = self._handler.getPaymentForTxnId(args.txnId)
420 ashish 1115
    except PaymentException, pe:
1116
      result.pe = pe
696 rajveer 1117
    oprot.writeMessageBegin("getPaymentForTxnId", TMessageType.REPLY, seqid)
420 ashish 1118
    result.write(oprot)
1119
    oprot.writeMessageEnd()
1120
    oprot.trans.flush()
1121
 
4600 varun.gupt 1122
  def process_getSuccessfulPaymentForTxnId(self, seqid, iprot, oprot):
1123
    args = getSuccessfulPaymentForTxnId_args()
1124
    args.read(iprot)
1125
    iprot.readMessageEnd()
1126
    result = getSuccessfulPaymentForTxnId_result()
1127
    try:
1128
      result.success = self._handler.getSuccessfulPaymentForTxnId(args.txnId)
1129
    except PaymentException, pe:
1130
      result.pe = pe
1131
    oprot.writeMessageBegin("getSuccessfulPaymentForTxnId", TMessageType.REPLY, seqid)
1132
    result.write(oprot)
1133
    oprot.writeMessageEnd()
1134
    oprot.trans.flush()
1135
 
696 rajveer 1136
  def process_updatePaymentDetails(self, seqid, iprot, oprot):
1137
    args = updatePaymentDetails_args()
420 ashish 1138
    args.read(iprot)
1139
    iprot.readMessageEnd()
696 rajveer 1140
    result = updatePaymentDetails_result()
420 ashish 1141
    try:
1120 rajveer 1142
      result.success = self._handler.updatePaymentDetails(args.id, args.gatewayPaymentId, args.sessionId, args.gatewayTxnStatus, args.description, args.gatewayTxnId, args.authCode, args.referenceCode, args.errorCode, args.status, args.gatewayTxnDate, args.attributes)
420 ashish 1143
    except PaymentException, pe:
1144
      result.pe = pe
696 rajveer 1145
    oprot.writeMessageBegin("updatePaymentDetails", TMessageType.REPLY, seqid)
420 ashish 1146
    result.write(oprot)
1147
    oprot.writeMessageEnd()
1148
    oprot.trans.flush()
1149
 
1731 ankur.sing 1150
  def process_getSuccessfulPaymentsAmountRange(self, seqid, iprot, oprot):
1151
    args = getSuccessfulPaymentsAmountRange_args()
1627 ankur.sing 1152
    args.read(iprot)
1153
    iprot.readMessageEnd()
1731 ankur.sing 1154
    result = getSuccessfulPaymentsAmountRange_result()
1155
    result.success = self._handler.getSuccessfulPaymentsAmountRange()
1156
    oprot.writeMessageBegin("getSuccessfulPaymentsAmountRange", TMessageType.REPLY, seqid)
1627 ankur.sing 1157
    result.write(oprot)
1158
    oprot.writeMessageEnd()
1159
    oprot.trans.flush()
420 ashish 1160
 
2559 chandransh 1161
  def process_initializeHdfcPayment(self, seqid, iprot, oprot):
1162
    args = initializeHdfcPayment_args()
1163
    args.read(iprot)
1164
    iprot.readMessageEnd()
1165
    result = initializeHdfcPayment_result()
1166
    try:
1167
      result.success = self._handler.initializeHdfcPayment(args.merchantPaymentId)
1168
    except PaymentException, pe:
1169
      result.pe = pe
1170
    oprot.writeMessageBegin("initializeHdfcPayment", TMessageType.REPLY, seqid)
1171
    result.write(oprot)
1172
    oprot.writeMessageEnd()
1173
    oprot.trans.flush()
1174
 
6050 anupam.sin 1175
  def process_doHdfcPaymentForDigitalOrder(self, seqid, iprot, oprot):
1176
    args = doHdfcPaymentForDigitalOrder_args()
1177
    args.read(iprot)
1178
    iprot.readMessageEnd()
1179
    result = doHdfcPaymentForDigitalOrder_result()
1180
    try:
6228 anupam.sin 1181
      result.success = self._handler.doHdfcPaymentForDigitalOrder(args.merchantPaymentId, args.rechargeOrderId, args.phone)
6050 anupam.sin 1182
    except PaymentException, pe:
1183
      result.pe = pe
1184
    oprot.writeMessageBegin("doHdfcPaymentForDigitalOrder", TMessageType.REPLY, seqid)
1185
    result.write(oprot)
1186
    oprot.writeMessageEnd()
1187
    oprot.trans.flush()
1188
 
3616 chandransh 1189
  def process_initializeHdfcEmiPayment(self, seqid, iprot, oprot):
1190
    args = initializeHdfcEmiPayment_args()
1191
    args.read(iprot)
1192
    iprot.readMessageEnd()
1193
    result = initializeHdfcEmiPayment_result()
1194
    try:
1195
      result.success = self._handler.initializeHdfcEmiPayment(args.merchantPaymentId)
1196
    except PaymentException, pe:
1197
      result.pe = pe
1198
    oprot.writeMessageBegin("initializeHdfcEmiPayment", TMessageType.REPLY, seqid)
1199
    result.write(oprot)
1200
    oprot.writeMessageEnd()
1201
    oprot.trans.flush()
1202
 
2685 chandransh 1203
  def process_createRefund(self, seqid, iprot, oprot):
1204
    args = createRefund_args()
1205
    args.read(iprot)
1206
    iprot.readMessageEnd()
1207
    result = createRefund_result()
1208
    try:
1209
      result.success = self._handler.createRefund(args.orderId, args.merchantTxnId, args.amount)
1210
    except PaymentException, pe:
1211
      result.pe = pe
1212
    oprot.writeMessageBegin("createRefund", TMessageType.REPLY, seqid)
1213
    result.write(oprot)
1214
    oprot.writeMessageEnd()
1215
    oprot.trans.flush()
2559 chandransh 1216
 
3010 chandransh 1217
  def process_capturePayment(self, seqid, iprot, oprot):
1218
    args = capturePayment_args()
1219
    args.read(iprot)
1220
    iprot.readMessageEnd()
1221
    result = capturePayment_result()
1222
    try:
1223
      result.success = self._handler.capturePayment(args.merchantTxnId)
1224
    except PaymentException, pe:
1225
      result.pe = pe
1226
    oprot.writeMessageBegin("capturePayment", TMessageType.REPLY, seqid)
1227
    result.write(oprot)
1228
    oprot.writeMessageEnd()
1229
    oprot.trans.flush()
2685 chandransh 1230
 
3956 chandransh 1231
  def process_partiallyCapturePayment(self, seqid, iprot, oprot):
1232
    args = partiallyCapturePayment_args()
1233
    args.read(iprot)
1234
    iprot.readMessageEnd()
1235
    result = partiallyCapturePayment_result()
1236
    try:
1237
      result.success = self._handler.partiallyCapturePayment(args.merchantTxnId, args.amount, args.xferBy, args.xferTxnId, args.xferDate)
1238
    except PaymentException, pe:
1239
      result.pe = pe
1240
    oprot.writeMessageBegin("partiallyCapturePayment", TMessageType.REPLY, seqid)
1241
    result.write(oprot)
1242
    oprot.writeMessageEnd()
1243
    oprot.trans.flush()
3010 chandransh 1244
 
4008 mandeep.dh 1245
  def process_getPaymentsRequiringExtraProcessing(self, seqid, iprot, oprot):
1246
    args = getPaymentsRequiringExtraProcessing_args()
1247
    args.read(iprot)
1248
    iprot.readMessageEnd()
1249
    result = getPaymentsRequiringExtraProcessing_result()
1250
    result.success = self._handler.getPaymentsRequiringExtraProcessing(args.category)
1251
    oprot.writeMessageBegin("getPaymentsRequiringExtraProcessing", TMessageType.REPLY, seqid)
1252
    result.write(oprot)
1253
    oprot.writeMessageEnd()
1254
    oprot.trans.flush()
3956 chandransh 1255
 
4008 mandeep.dh 1256
  def process_markPaymentAsProcessed(self, seqid, iprot, oprot):
1257
    args = markPaymentAsProcessed_args()
1258
    args.read(iprot)
1259
    iprot.readMessageEnd()
1260
    result = markPaymentAsProcessed_result()
1261
    self._handler.markPaymentAsProcessed(args.paymentId, args.category)
1262
    oprot.writeMessageBegin("markPaymentAsProcessed", TMessageType.REPLY, seqid)
1263
    result.write(oprot)
1264
    oprot.writeMessageEnd()
1265
    oprot.trans.flush()
1266
 
1267
 
420 ashish 1268
# HELPER FUNCTIONS AND STRUCTURES
1269
 
1270
class createPayment_args:
1271
  """
1272
  Attributes:
696 rajveer 1273
   - userId
420 ashish 1274
   - amount
696 rajveer 1275
   - gatewayId
1276
   - txnId
6050 anupam.sin 1277
   - isDigital
420 ashish 1278
  """
1279
 
1280
  thrift_spec = (
1281
    None, # 0
696 rajveer 1282
    (1, TType.I64, 'userId', None, None, ), # 1
1283
    (2, TType.DOUBLE, 'amount', None, None, ), # 2
1284
    (3, TType.I64, 'gatewayId', None, None, ), # 3
1285
    (4, TType.I64, 'txnId', None, None, ), # 4
6050 anupam.sin 1286
    (5, TType.BOOL, 'isDigital', None, None, ), # 5
420 ashish 1287
  )
1288
 
6050 anupam.sin 1289
  def __init__(self, userId=None, amount=None, gatewayId=None, txnId=None, isDigital=None,):
696 rajveer 1290
    self.userId = userId
420 ashish 1291
    self.amount = amount
696 rajveer 1292
    self.gatewayId = gatewayId
1293
    self.txnId = txnId
6050 anupam.sin 1294
    self.isDigital = isDigital
420 ashish 1295
 
1296
  def read(self, iprot):
1297
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1298
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1299
      return
1300
    iprot.readStructBegin()
1301
    while True:
1302
      (fname, ftype, fid) = iprot.readFieldBegin()
1303
      if ftype == TType.STOP:
1304
        break
1305
      if fid == 1:
1306
        if ftype == TType.I64:
696 rajveer 1307
          self.userId = iprot.readI64();
420 ashish 1308
        else:
1309
          iprot.skip(ftype)
1310
      elif fid == 2:
696 rajveer 1311
        if ftype == TType.DOUBLE:
1312
          self.amount = iprot.readDouble();
420 ashish 1313
        else:
1314
          iprot.skip(ftype)
1315
      elif fid == 3:
696 rajveer 1316
        if ftype == TType.I64:
1317
          self.gatewayId = iprot.readI64();
420 ashish 1318
        else:
1319
          iprot.skip(ftype)
1320
      elif fid == 4:
1321
        if ftype == TType.I64:
696 rajveer 1322
          self.txnId = iprot.readI64();
420 ashish 1323
        else:
1324
          iprot.skip(ftype)
6050 anupam.sin 1325
      elif fid == 5:
1326
        if ftype == TType.BOOL:
1327
          self.isDigital = iprot.readBool();
1328
        else:
1329
          iprot.skip(ftype)
420 ashish 1330
      else:
1331
        iprot.skip(ftype)
1332
      iprot.readFieldEnd()
1333
    iprot.readStructEnd()
1334
 
1335
  def write(self, oprot):
1336
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1337
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1338
      return
1339
    oprot.writeStructBegin('createPayment_args')
3431 rajveer 1340
    if self.userId is not None:
696 rajveer 1341
      oprot.writeFieldBegin('userId', TType.I64, 1)
1342
      oprot.writeI64(self.userId)
420 ashish 1343
      oprot.writeFieldEnd()
3431 rajveer 1344
    if self.amount is not None:
696 rajveer 1345
      oprot.writeFieldBegin('amount', TType.DOUBLE, 2)
420 ashish 1346
      oprot.writeDouble(self.amount)
1347
      oprot.writeFieldEnd()
3431 rajveer 1348
    if self.gatewayId is not None:
696 rajveer 1349
      oprot.writeFieldBegin('gatewayId', TType.I64, 3)
1350
      oprot.writeI64(self.gatewayId)
420 ashish 1351
      oprot.writeFieldEnd()
3431 rajveer 1352
    if self.txnId is not None:
696 rajveer 1353
      oprot.writeFieldBegin('txnId', TType.I64, 4)
1354
      oprot.writeI64(self.txnId)
1355
      oprot.writeFieldEnd()
6050 anupam.sin 1356
    if self.isDigital is not None:
1357
      oprot.writeFieldBegin('isDigital', TType.BOOL, 5)
1358
      oprot.writeBool(self.isDigital)
1359
      oprot.writeFieldEnd()
420 ashish 1360
    oprot.writeFieldStop()
1361
    oprot.writeStructEnd()
1362
 
3431 rajveer 1363
  def validate(self):
1364
    return
1365
 
1366
 
420 ashish 1367
  def __repr__(self):
1368
    L = ['%s=%r' % (key, value)
1369
      for key, value in self.__dict__.iteritems()]
1370
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1371
 
1372
  def __eq__(self, other):
1373
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1374
 
1375
  def __ne__(self, other):
1376
    return not (self == other)
1377
 
1378
class createPayment_result:
1379
  """
1380
  Attributes:
1381
   - success
1382
   - pe
1383
  """
1384
 
1385
  thrift_spec = (
1386
    (0, TType.I64, 'success', None, None, ), # 0
1387
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
1388
  )
1389
 
1390
  def __init__(self, success=None, pe=None,):
1391
    self.success = success
1392
    self.pe = pe
1393
 
1394
  def read(self, iprot):
1395
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1396
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1397
      return
1398
    iprot.readStructBegin()
1399
    while True:
1400
      (fname, ftype, fid) = iprot.readFieldBegin()
1401
      if ftype == TType.STOP:
1402
        break
1403
      if fid == 0:
1404
        if ftype == TType.I64:
1405
          self.success = iprot.readI64();
1406
        else:
1407
          iprot.skip(ftype)
1408
      elif fid == 1:
1409
        if ftype == TType.STRUCT:
1410
          self.pe = PaymentException()
1411
          self.pe.read(iprot)
1412
        else:
1413
          iprot.skip(ftype)
1414
      else:
1415
        iprot.skip(ftype)
1416
      iprot.readFieldEnd()
1417
    iprot.readStructEnd()
1418
 
1419
  def write(self, oprot):
1420
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1421
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1422
      return
1423
    oprot.writeStructBegin('createPayment_result')
3431 rajveer 1424
    if self.success is not None:
420 ashish 1425
      oprot.writeFieldBegin('success', TType.I64, 0)
1426
      oprot.writeI64(self.success)
1427
      oprot.writeFieldEnd()
3431 rajveer 1428
    if self.pe is not None:
420 ashish 1429
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
1430
      self.pe.write(oprot)
1431
      oprot.writeFieldEnd()
1432
    oprot.writeFieldStop()
1433
    oprot.writeStructEnd()
1434
 
3431 rajveer 1435
  def validate(self):
1436
    return
1437
 
1438
 
420 ashish 1439
  def __repr__(self):
1440
    L = ['%s=%r' % (key, value)
1441
      for key, value in self.__dict__.iteritems()]
1442
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1443
 
1444
  def __eq__(self, other):
1445
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1446
 
1447
  def __ne__(self, other):
1448
    return not (self == other)
1449
 
1450
class getPaymentsForUser_args:
1451
  """
1452
  Attributes:
1453
   - userId
696 rajveer 1454
   - fromTime
1455
   - toTime
420 ashish 1456
   - status
696 rajveer 1457
   - gatewayId
420 ashish 1458
  """
1459
 
1460
  thrift_spec = (
1461
    None, # 0
1462
    (1, TType.I64, 'userId', None, None, ), # 1
696 rajveer 1463
    (2, TType.I64, 'fromTime', None, None, ), # 2
1464
    (3, TType.I64, 'toTime', None, None, ), # 3
420 ashish 1465
    (4, TType.I32, 'status', None, None, ), # 4
696 rajveer 1466
    (5, TType.I64, 'gatewayId', None, None, ), # 5
420 ashish 1467
  )
1468
 
696 rajveer 1469
  def __init__(self, userId=None, fromTime=None, toTime=None, status=None, gatewayId=None,):
420 ashish 1470
    self.userId = userId
696 rajveer 1471
    self.fromTime = fromTime
1472
    self.toTime = toTime
420 ashish 1473
    self.status = status
696 rajveer 1474
    self.gatewayId = gatewayId
420 ashish 1475
 
1476
  def read(self, iprot):
1477
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1478
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1479
      return
1480
    iprot.readStructBegin()
1481
    while True:
1482
      (fname, ftype, fid) = iprot.readFieldBegin()
1483
      if ftype == TType.STOP:
1484
        break
1485
      if fid == 1:
1486
        if ftype == TType.I64:
1487
          self.userId = iprot.readI64();
1488
        else:
1489
          iprot.skip(ftype)
1490
      elif fid == 2:
1491
        if ftype == TType.I64:
696 rajveer 1492
          self.fromTime = iprot.readI64();
420 ashish 1493
        else:
1494
          iprot.skip(ftype)
1495
      elif fid == 3:
1496
        if ftype == TType.I64:
696 rajveer 1497
          self.toTime = iprot.readI64();
420 ashish 1498
        else:
1499
          iprot.skip(ftype)
1500
      elif fid == 4:
1501
        if ftype == TType.I32:
1502
          self.status = iprot.readI32();
1503
        else:
1504
          iprot.skip(ftype)
1505
      elif fid == 5:
1506
        if ftype == TType.I64:
696 rajveer 1507
          self.gatewayId = iprot.readI64();
420 ashish 1508
        else:
1509
          iprot.skip(ftype)
1510
      else:
1511
        iprot.skip(ftype)
1512
      iprot.readFieldEnd()
1513
    iprot.readStructEnd()
1514
 
1515
  def write(self, oprot):
1516
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1517
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1518
      return
1519
    oprot.writeStructBegin('getPaymentsForUser_args')
3431 rajveer 1520
    if self.userId is not None:
420 ashish 1521
      oprot.writeFieldBegin('userId', TType.I64, 1)
1522
      oprot.writeI64(self.userId)
1523
      oprot.writeFieldEnd()
3431 rajveer 1524
    if self.fromTime is not None:
696 rajveer 1525
      oprot.writeFieldBegin('fromTime', TType.I64, 2)
1526
      oprot.writeI64(self.fromTime)
420 ashish 1527
      oprot.writeFieldEnd()
3431 rajveer 1528
    if self.toTime is not None:
696 rajveer 1529
      oprot.writeFieldBegin('toTime', TType.I64, 3)
1530
      oprot.writeI64(self.toTime)
420 ashish 1531
      oprot.writeFieldEnd()
3431 rajveer 1532
    if self.status is not None:
420 ashish 1533
      oprot.writeFieldBegin('status', TType.I32, 4)
1534
      oprot.writeI32(self.status)
1535
      oprot.writeFieldEnd()
3431 rajveer 1536
    if self.gatewayId is not None:
696 rajveer 1537
      oprot.writeFieldBegin('gatewayId', TType.I64, 5)
1538
      oprot.writeI64(self.gatewayId)
420 ashish 1539
      oprot.writeFieldEnd()
1540
    oprot.writeFieldStop()
1541
    oprot.writeStructEnd()
1542
 
3431 rajveer 1543
  def validate(self):
1544
    return
1545
 
1546
 
420 ashish 1547
  def __repr__(self):
1548
    L = ['%s=%r' % (key, value)
1549
      for key, value in self.__dict__.iteritems()]
1550
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1551
 
1552
  def __eq__(self, other):
1553
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1554
 
1555
  def __ne__(self, other):
1556
    return not (self == other)
1557
 
1558
class getPaymentsForUser_result:
1559
  """
1560
  Attributes:
1561
   - success
1562
   - pe
1563
  """
1564
 
1565
  thrift_spec = (
1566
    (0, TType.LIST, 'success', (TType.STRUCT,(Payment, Payment.thrift_spec)), None, ), # 0
1567
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
1568
  )
1569
 
1570
  def __init__(self, success=None, pe=None,):
1571
    self.success = success
1572
    self.pe = pe
1573
 
1574
  def read(self, iprot):
1575
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1576
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1577
      return
1578
    iprot.readStructBegin()
1579
    while True:
1580
      (fname, ftype, fid) = iprot.readFieldBegin()
1581
      if ftype == TType.STOP:
1582
        break
1583
      if fid == 0:
1584
        if ftype == TType.LIST:
1585
          self.success = []
2747 chandransh 1586
          (_etype24, _size21) = iprot.readListBegin()
1587
          for _i25 in xrange(_size21):
1588
            _elem26 = Payment()
1589
            _elem26.read(iprot)
1590
            self.success.append(_elem26)
420 ashish 1591
          iprot.readListEnd()
1592
        else:
1593
          iprot.skip(ftype)
1594
      elif fid == 1:
1595
        if ftype == TType.STRUCT:
1596
          self.pe = PaymentException()
1597
          self.pe.read(iprot)
1598
        else:
1599
          iprot.skip(ftype)
1600
      else:
1601
        iprot.skip(ftype)
1602
      iprot.readFieldEnd()
1603
    iprot.readStructEnd()
1604
 
1605
  def write(self, oprot):
1606
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1607
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1608
      return
1609
    oprot.writeStructBegin('getPaymentsForUser_result')
3431 rajveer 1610
    if self.success is not None:
420 ashish 1611
      oprot.writeFieldBegin('success', TType.LIST, 0)
1612
      oprot.writeListBegin(TType.STRUCT, len(self.success))
2747 chandransh 1613
      for iter27 in self.success:
1614
        iter27.write(oprot)
420 ashish 1615
      oprot.writeListEnd()
1616
      oprot.writeFieldEnd()
3431 rajveer 1617
    if self.pe is not None:
420 ashish 1618
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
1619
      self.pe.write(oprot)
1620
      oprot.writeFieldEnd()
1621
    oprot.writeFieldStop()
1622
    oprot.writeStructEnd()
1623
 
3431 rajveer 1624
  def validate(self):
1625
    return
1626
 
1627
 
420 ashish 1628
  def __repr__(self):
1629
    L = ['%s=%r' % (key, value)
1630
      for key, value in self.__dict__.iteritems()]
1631
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1632
 
1633
  def __eq__(self, other):
1634
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1635
 
1636
  def __ne__(self, other):
1637
    return not (self == other)
1638
 
1639
class getPayments_args:
1640
  """
1641
  Attributes:
696 rajveer 1642
   - fromTime
1643
   - toTime
420 ashish 1644
   - status
696 rajveer 1645
   - gatewayId
420 ashish 1646
  """
1647
 
1648
  thrift_spec = (
1649
    None, # 0
696 rajveer 1650
    (1, TType.I64, 'fromTime', None, None, ), # 1
1651
    (2, TType.I64, 'toTime', None, None, ), # 2
420 ashish 1652
    (3, TType.I32, 'status', None, None, ), # 3
696 rajveer 1653
    (4, TType.I64, 'gatewayId', None, None, ), # 4
420 ashish 1654
  )
1655
 
696 rajveer 1656
  def __init__(self, fromTime=None, toTime=None, status=None, gatewayId=None,):
1657
    self.fromTime = fromTime
1658
    self.toTime = toTime
420 ashish 1659
    self.status = status
696 rajveer 1660
    self.gatewayId = gatewayId
420 ashish 1661
 
1662
  def read(self, iprot):
1663
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1664
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1665
      return
1666
    iprot.readStructBegin()
1667
    while True:
1668
      (fname, ftype, fid) = iprot.readFieldBegin()
1669
      if ftype == TType.STOP:
1670
        break
1671
      if fid == 1:
1672
        if ftype == TType.I64:
696 rajveer 1673
          self.fromTime = iprot.readI64();
420 ashish 1674
        else:
1675
          iprot.skip(ftype)
1676
      elif fid == 2:
1677
        if ftype == TType.I64:
696 rajveer 1678
          self.toTime = iprot.readI64();
420 ashish 1679
        else:
1680
          iprot.skip(ftype)
1681
      elif fid == 3:
1682
        if ftype == TType.I32:
1683
          self.status = iprot.readI32();
1684
        else:
1685
          iprot.skip(ftype)
1686
      elif fid == 4:
1687
        if ftype == TType.I64:
696 rajveer 1688
          self.gatewayId = iprot.readI64();
420 ashish 1689
        else:
1690
          iprot.skip(ftype)
1691
      else:
1692
        iprot.skip(ftype)
1693
      iprot.readFieldEnd()
1694
    iprot.readStructEnd()
1695
 
1696
  def write(self, oprot):
1697
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1698
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1699
      return
1700
    oprot.writeStructBegin('getPayments_args')
3431 rajveer 1701
    if self.fromTime is not None:
696 rajveer 1702
      oprot.writeFieldBegin('fromTime', TType.I64, 1)
1703
      oprot.writeI64(self.fromTime)
420 ashish 1704
      oprot.writeFieldEnd()
3431 rajveer 1705
    if self.toTime is not None:
696 rajveer 1706
      oprot.writeFieldBegin('toTime', TType.I64, 2)
1707
      oprot.writeI64(self.toTime)
420 ashish 1708
      oprot.writeFieldEnd()
3431 rajveer 1709
    if self.status is not None:
420 ashish 1710
      oprot.writeFieldBegin('status', TType.I32, 3)
1711
      oprot.writeI32(self.status)
1712
      oprot.writeFieldEnd()
3431 rajveer 1713
    if self.gatewayId is not None:
696 rajveer 1714
      oprot.writeFieldBegin('gatewayId', TType.I64, 4)
1715
      oprot.writeI64(self.gatewayId)
420 ashish 1716
      oprot.writeFieldEnd()
1717
    oprot.writeFieldStop()
1718
    oprot.writeStructEnd()
1719
 
3431 rajveer 1720
  def validate(self):
1721
    return
1722
 
1723
 
420 ashish 1724
  def __repr__(self):
1725
    L = ['%s=%r' % (key, value)
1726
      for key, value in self.__dict__.iteritems()]
1727
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1728
 
1729
  def __eq__(self, other):
1730
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1731
 
1732
  def __ne__(self, other):
1733
    return not (self == other)
1734
 
1735
class getPayments_result:
1736
  """
1737
  Attributes:
1738
   - success
1739
   - pe
1740
  """
1741
 
1742
  thrift_spec = (
1743
    (0, TType.LIST, 'success', (TType.STRUCT,(Payment, Payment.thrift_spec)), None, ), # 0
1744
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
1745
  )
1746
 
1747
  def __init__(self, success=None, pe=None,):
1748
    self.success = success
1749
    self.pe = pe
1750
 
1751
  def read(self, iprot):
1752
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1753
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1754
      return
1755
    iprot.readStructBegin()
1756
    while True:
1757
      (fname, ftype, fid) = iprot.readFieldBegin()
1758
      if ftype == TType.STOP:
1759
        break
1760
      if fid == 0:
1761
        if ftype == TType.LIST:
1762
          self.success = []
2747 chandransh 1763
          (_etype31, _size28) = iprot.readListBegin()
1764
          for _i32 in xrange(_size28):
1765
            _elem33 = Payment()
1766
            _elem33.read(iprot)
1767
            self.success.append(_elem33)
420 ashish 1768
          iprot.readListEnd()
1769
        else:
1770
          iprot.skip(ftype)
1771
      elif fid == 1:
1772
        if ftype == TType.STRUCT:
1773
          self.pe = PaymentException()
1774
          self.pe.read(iprot)
1775
        else:
1776
          iprot.skip(ftype)
1777
      else:
1778
        iprot.skip(ftype)
1779
      iprot.readFieldEnd()
1780
    iprot.readStructEnd()
1781
 
1782
  def write(self, oprot):
1783
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1784
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1785
      return
1786
    oprot.writeStructBegin('getPayments_result')
3431 rajveer 1787
    if self.success is not None:
420 ashish 1788
      oprot.writeFieldBegin('success', TType.LIST, 0)
1789
      oprot.writeListBegin(TType.STRUCT, len(self.success))
2747 chandransh 1790
      for iter34 in self.success:
1791
        iter34.write(oprot)
420 ashish 1792
      oprot.writeListEnd()
1793
      oprot.writeFieldEnd()
3431 rajveer 1794
    if self.pe is not None:
420 ashish 1795
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
1796
      self.pe.write(oprot)
1797
      oprot.writeFieldEnd()
1798
    oprot.writeFieldStop()
1799
    oprot.writeStructEnd()
1800
 
3431 rajveer 1801
  def validate(self):
1802
    return
1803
 
1804
 
420 ashish 1805
  def __repr__(self):
1806
    L = ['%s=%r' % (key, value)
1807
      for key, value in self.__dict__.iteritems()]
1808
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1809
 
1810
  def __eq__(self, other):
1811
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1812
 
1813
  def __ne__(self, other):
1814
    return not (self == other)
1815
 
4141 chandransh 1816
class getPaymentsByCapturedDate_args:
1817
  """
1818
  Attributes:
1819
   - fromTime
1820
   - toTime
1821
   - gatewayId
1822
  """
1823
 
1824
  thrift_spec = (
1825
    None, # 0
1826
    (1, TType.I64, 'fromTime', None, None, ), # 1
1827
    (2, TType.I64, 'toTime', None, None, ), # 2
1828
    (3, TType.I64, 'gatewayId', None, None, ), # 3
1829
  )
1830
 
1831
  def __init__(self, fromTime=None, toTime=None, gatewayId=None,):
1832
    self.fromTime = fromTime
1833
    self.toTime = toTime
1834
    self.gatewayId = gatewayId
1835
 
1836
  def read(self, iprot):
1837
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1838
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1839
      return
1840
    iprot.readStructBegin()
1841
    while True:
1842
      (fname, ftype, fid) = iprot.readFieldBegin()
1843
      if ftype == TType.STOP:
1844
        break
1845
      if fid == 1:
1846
        if ftype == TType.I64:
1847
          self.fromTime = iprot.readI64();
1848
        else:
1849
          iprot.skip(ftype)
1850
      elif fid == 2:
1851
        if ftype == TType.I64:
1852
          self.toTime = iprot.readI64();
1853
        else:
1854
          iprot.skip(ftype)
1855
      elif fid == 3:
1856
        if ftype == TType.I64:
1857
          self.gatewayId = iprot.readI64();
1858
        else:
1859
          iprot.skip(ftype)
1860
      else:
1861
        iprot.skip(ftype)
1862
      iprot.readFieldEnd()
1863
    iprot.readStructEnd()
1864
 
1865
  def write(self, oprot):
1866
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1867
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1868
      return
1869
    oprot.writeStructBegin('getPaymentsByCapturedDate_args')
1870
    if self.fromTime is not None:
1871
      oprot.writeFieldBegin('fromTime', TType.I64, 1)
1872
      oprot.writeI64(self.fromTime)
1873
      oprot.writeFieldEnd()
1874
    if self.toTime is not None:
1875
      oprot.writeFieldBegin('toTime', TType.I64, 2)
1876
      oprot.writeI64(self.toTime)
1877
      oprot.writeFieldEnd()
1878
    if self.gatewayId is not None:
1879
      oprot.writeFieldBegin('gatewayId', TType.I64, 3)
1880
      oprot.writeI64(self.gatewayId)
1881
      oprot.writeFieldEnd()
1882
    oprot.writeFieldStop()
1883
    oprot.writeStructEnd()
1884
 
1885
  def validate(self):
1886
    return
1887
 
1888
 
1889
  def __repr__(self):
1890
    L = ['%s=%r' % (key, value)
1891
      for key, value in self.__dict__.iteritems()]
1892
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1893
 
1894
  def __eq__(self, other):
1895
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1896
 
1897
  def __ne__(self, other):
1898
    return not (self == other)
1899
 
1900
class getPaymentsByCapturedDate_result:
1901
  """
1902
  Attributes:
1903
   - success
1904
   - pe
1905
  """
1906
 
1907
  thrift_spec = (
1908
    (0, TType.LIST, 'success', (TType.STRUCT,(Payment, Payment.thrift_spec)), None, ), # 0
1909
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
1910
  )
1911
 
1912
  def __init__(self, success=None, pe=None,):
1913
    self.success = success
1914
    self.pe = pe
1915
 
1916
  def read(self, iprot):
1917
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1918
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1919
      return
1920
    iprot.readStructBegin()
1921
    while True:
1922
      (fname, ftype, fid) = iprot.readFieldBegin()
1923
      if ftype == TType.STOP:
1924
        break
1925
      if fid == 0:
1926
        if ftype == TType.LIST:
1927
          self.success = []
1928
          (_etype38, _size35) = iprot.readListBegin()
1929
          for _i39 in xrange(_size35):
1930
            _elem40 = Payment()
1931
            _elem40.read(iprot)
1932
            self.success.append(_elem40)
1933
          iprot.readListEnd()
1934
        else:
1935
          iprot.skip(ftype)
1936
      elif fid == 1:
1937
        if ftype == TType.STRUCT:
1938
          self.pe = PaymentException()
1939
          self.pe.read(iprot)
1940
        else:
1941
          iprot.skip(ftype)
1942
      else:
1943
        iprot.skip(ftype)
1944
      iprot.readFieldEnd()
1945
    iprot.readStructEnd()
1946
 
1947
  def write(self, oprot):
1948
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1949
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1950
      return
1951
    oprot.writeStructBegin('getPaymentsByCapturedDate_result')
1952
    if self.success is not None:
1953
      oprot.writeFieldBegin('success', TType.LIST, 0)
1954
      oprot.writeListBegin(TType.STRUCT, len(self.success))
1955
      for iter41 in self.success:
1956
        iter41.write(oprot)
1957
      oprot.writeListEnd()
1958
      oprot.writeFieldEnd()
1959
    if self.pe is not None:
1960
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
1961
      self.pe.write(oprot)
1962
      oprot.writeFieldEnd()
1963
    oprot.writeFieldStop()
1964
    oprot.writeStructEnd()
1965
 
1966
  def validate(self):
1967
    return
1968
 
1969
 
1970
  def __repr__(self):
1971
    L = ['%s=%r' % (key, value)
1972
      for key, value in self.__dict__.iteritems()]
1973
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1974
 
1975
  def __eq__(self, other):
1976
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1977
 
1978
  def __ne__(self, other):
1979
    return not (self == other)
1980
 
696 rajveer 1981
class getPaymentGateway_args:
420 ashish 1982
  """
1983
  Attributes:
1984
   - id
1985
  """
1986
 
1987
  thrift_spec = (
1988
    None, # 0
1989
    (1, TType.I64, 'id', None, None, ), # 1
1990
  )
1991
 
696 rajveer 1992
  def __init__(self, id=None,):
420 ashish 1993
    self.id = id
1994
 
1995
  def read(self, iprot):
1996
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1997
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1998
      return
1999
    iprot.readStructBegin()
2000
    while True:
2001
      (fname, ftype, fid) = iprot.readFieldBegin()
2002
      if ftype == TType.STOP:
2003
        break
2004
      if fid == 1:
2005
        if ftype == TType.I64:
2006
          self.id = iprot.readI64();
2007
        else:
2008
          iprot.skip(ftype)
2009
      else:
2010
        iprot.skip(ftype)
2011
      iprot.readFieldEnd()
2012
    iprot.readStructEnd()
2013
 
2014
  def write(self, oprot):
2015
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2016
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2017
      return
696 rajveer 2018
    oprot.writeStructBegin('getPaymentGateway_args')
3431 rajveer 2019
    if self.id is not None:
420 ashish 2020
      oprot.writeFieldBegin('id', TType.I64, 1)
2021
      oprot.writeI64(self.id)
2022
      oprot.writeFieldEnd()
2023
    oprot.writeFieldStop()
2024
    oprot.writeStructEnd()
2025
 
3431 rajveer 2026
  def validate(self):
2027
    return
2028
 
2029
 
420 ashish 2030
  def __repr__(self):
2031
    L = ['%s=%r' % (key, value)
2032
      for key, value in self.__dict__.iteritems()]
2033
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2034
 
2035
  def __eq__(self, other):
2036
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2037
 
2038
  def __ne__(self, other):
2039
    return not (self == other)
2040
 
696 rajveer 2041
class getPaymentGateway_result:
420 ashish 2042
  """
2043
  Attributes:
2044
   - success
2045
   - pe
2046
  """
2047
 
2048
  thrift_spec = (
696 rajveer 2049
    (0, TType.STRUCT, 'success', (PaymentGateway, PaymentGateway.thrift_spec), None, ), # 0
420 ashish 2050
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
2051
  )
2052
 
2053
  def __init__(self, success=None, pe=None,):
2054
    self.success = success
2055
    self.pe = pe
2056
 
2057
  def read(self, iprot):
2058
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2059
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2060
      return
2061
    iprot.readStructBegin()
2062
    while True:
2063
      (fname, ftype, fid) = iprot.readFieldBegin()
2064
      if ftype == TType.STOP:
2065
        break
2066
      if fid == 0:
696 rajveer 2067
        if ftype == TType.STRUCT:
2068
          self.success = PaymentGateway()
2069
          self.success.read(iprot)
420 ashish 2070
        else:
2071
          iprot.skip(ftype)
2072
      elif fid == 1:
2073
        if ftype == TType.STRUCT:
2074
          self.pe = PaymentException()
2075
          self.pe.read(iprot)
2076
        else:
2077
          iprot.skip(ftype)
2078
      else:
2079
        iprot.skip(ftype)
2080
      iprot.readFieldEnd()
2081
    iprot.readStructEnd()
2082
 
2083
  def write(self, oprot):
2084
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2085
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2086
      return
696 rajveer 2087
    oprot.writeStructBegin('getPaymentGateway_result')
3431 rajveer 2088
    if self.success is not None:
696 rajveer 2089
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
2090
      self.success.write(oprot)
420 ashish 2091
      oprot.writeFieldEnd()
3431 rajveer 2092
    if self.pe is not None:
420 ashish 2093
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
2094
      self.pe.write(oprot)
2095
      oprot.writeFieldEnd()
2096
    oprot.writeFieldStop()
2097
    oprot.writeStructEnd()
2098
 
3431 rajveer 2099
  def validate(self):
2100
    return
2101
 
2102
 
420 ashish 2103
  def __repr__(self):
2104
    L = ['%s=%r' % (key, value)
2105
      for key, value in self.__dict__.iteritems()]
2106
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2107
 
2108
  def __eq__(self, other):
2109
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2110
 
2111
  def __ne__(self, other):
2112
    return not (self == other)
2113
 
4600 varun.gupt 2114
class getActivePaymentGateways_args:
2115
 
2116
  thrift_spec = (
2117
  )
2118
 
2119
  def read(self, iprot):
2120
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2121
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2122
      return
2123
    iprot.readStructBegin()
2124
    while True:
2125
      (fname, ftype, fid) = iprot.readFieldBegin()
2126
      if ftype == TType.STOP:
2127
        break
2128
      else:
2129
        iprot.skip(ftype)
2130
      iprot.readFieldEnd()
2131
    iprot.readStructEnd()
2132
 
2133
  def write(self, oprot):
2134
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2135
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2136
      return
2137
    oprot.writeStructBegin('getActivePaymentGateways_args')
2138
    oprot.writeFieldStop()
2139
    oprot.writeStructEnd()
2140
 
2141
  def validate(self):
2142
    return
2143
 
2144
 
2145
  def __repr__(self):
2146
    L = ['%s=%r' % (key, value)
2147
      for key, value in self.__dict__.iteritems()]
2148
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2149
 
2150
  def __eq__(self, other):
2151
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2152
 
2153
  def __ne__(self, other):
2154
    return not (self == other)
2155
 
2156
class getActivePaymentGateways_result:
2157
  """
2158
  Attributes:
2159
   - success
2160
   - pe
2161
  """
2162
 
2163
  thrift_spec = (
2164
    (0, TType.LIST, 'success', (TType.STRUCT,(PaymentGateway, PaymentGateway.thrift_spec)), None, ), # 0
2165
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
2166
  )
2167
 
2168
  def __init__(self, success=None, pe=None,):
2169
    self.success = success
2170
    self.pe = pe
2171
 
2172
  def read(self, iprot):
2173
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2174
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2175
      return
2176
    iprot.readStructBegin()
2177
    while True:
2178
      (fname, ftype, fid) = iprot.readFieldBegin()
2179
      if ftype == TType.STOP:
2180
        break
2181
      if fid == 0:
2182
        if ftype == TType.LIST:
2183
          self.success = []
2184
          (_etype45, _size42) = iprot.readListBegin()
2185
          for _i46 in xrange(_size42):
2186
            _elem47 = PaymentGateway()
2187
            _elem47.read(iprot)
2188
            self.success.append(_elem47)
2189
          iprot.readListEnd()
2190
        else:
2191
          iprot.skip(ftype)
2192
      elif fid == 1:
2193
        if ftype == TType.STRUCT:
2194
          self.pe = PaymentException()
2195
          self.pe.read(iprot)
2196
        else:
2197
          iprot.skip(ftype)
2198
      else:
2199
        iprot.skip(ftype)
2200
      iprot.readFieldEnd()
2201
    iprot.readStructEnd()
2202
 
2203
  def write(self, oprot):
2204
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2205
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2206
      return
2207
    oprot.writeStructBegin('getActivePaymentGateways_result')
2208
    if self.success is not None:
2209
      oprot.writeFieldBegin('success', TType.LIST, 0)
2210
      oprot.writeListBegin(TType.STRUCT, len(self.success))
2211
      for iter48 in self.success:
2212
        iter48.write(oprot)
2213
      oprot.writeListEnd()
2214
      oprot.writeFieldEnd()
2215
    if self.pe is not None:
2216
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
2217
      self.pe.write(oprot)
2218
      oprot.writeFieldEnd()
2219
    oprot.writeFieldStop()
2220
    oprot.writeStructEnd()
2221
 
2222
  def validate(self):
2223
    return
2224
 
2225
 
2226
  def __repr__(self):
2227
    L = ['%s=%r' % (key, value)
2228
      for key, value in self.__dict__.iteritems()]
2229
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2230
 
2231
  def __eq__(self, other):
2232
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2233
 
2234
  def __ne__(self, other):
2235
    return not (self == other)
2236
 
696 rajveer 2237
class getPayment_args:
420 ashish 2238
  """
2239
  Attributes:
2240
   - id
2241
  """
2242
 
2243
  thrift_spec = (
2244
    None, # 0
2245
    (1, TType.I64, 'id', None, None, ), # 1
2246
  )
2247
 
2248
  def __init__(self, id=None,):
2249
    self.id = id
2250
 
2251
  def read(self, iprot):
2252
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2253
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2254
      return
2255
    iprot.readStructBegin()
2256
    while True:
2257
      (fname, ftype, fid) = iprot.readFieldBegin()
2258
      if ftype == TType.STOP:
2259
        break
2260
      if fid == 1:
2261
        if ftype == TType.I64:
2262
          self.id = iprot.readI64();
2263
        else:
2264
          iprot.skip(ftype)
2265
      else:
2266
        iprot.skip(ftype)
2267
      iprot.readFieldEnd()
2268
    iprot.readStructEnd()
2269
 
2270
  def write(self, oprot):
2271
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2272
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2273
      return
696 rajveer 2274
    oprot.writeStructBegin('getPayment_args')
3431 rajveer 2275
    if self.id is not None:
420 ashish 2276
      oprot.writeFieldBegin('id', TType.I64, 1)
2277
      oprot.writeI64(self.id)
2278
      oprot.writeFieldEnd()
2279
    oprot.writeFieldStop()
2280
    oprot.writeStructEnd()
2281
 
3431 rajveer 2282
  def validate(self):
2283
    return
2284
 
2285
 
420 ashish 2286
  def __repr__(self):
2287
    L = ['%s=%r' % (key, value)
2288
      for key, value in self.__dict__.iteritems()]
2289
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2290
 
2291
  def __eq__(self, other):
2292
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2293
 
2294
  def __ne__(self, other):
2295
    return not (self == other)
2296
 
696 rajveer 2297
class getPayment_result:
420 ashish 2298
  """
2299
  Attributes:
2300
   - success
2301
   - pe
2302
  """
2303
 
2304
  thrift_spec = (
696 rajveer 2305
    (0, TType.STRUCT, 'success', (Payment, Payment.thrift_spec), None, ), # 0
420 ashish 2306
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
2307
  )
2308
 
2309
  def __init__(self, success=None, pe=None,):
2310
    self.success = success
2311
    self.pe = pe
2312
 
2313
  def read(self, iprot):
2314
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2315
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2316
      return
2317
    iprot.readStructBegin()
2318
    while True:
2319
      (fname, ftype, fid) = iprot.readFieldBegin()
2320
      if ftype == TType.STOP:
2321
        break
2322
      if fid == 0:
2323
        if ftype == TType.STRUCT:
696 rajveer 2324
          self.success = Payment()
420 ashish 2325
          self.success.read(iprot)
2326
        else:
2327
          iprot.skip(ftype)
2328
      elif fid == 1:
2329
        if ftype == TType.STRUCT:
2330
          self.pe = PaymentException()
2331
          self.pe.read(iprot)
2332
        else:
2333
          iprot.skip(ftype)
2334
      else:
2335
        iprot.skip(ftype)
2336
      iprot.readFieldEnd()
2337
    iprot.readStructEnd()
2338
 
2339
  def write(self, oprot):
2340
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2341
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2342
      return
696 rajveer 2343
    oprot.writeStructBegin('getPayment_result')
3431 rajveer 2344
    if self.success is not None:
420 ashish 2345
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
2346
      self.success.write(oprot)
2347
      oprot.writeFieldEnd()
3431 rajveer 2348
    if self.pe is not None:
420 ashish 2349
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
2350
      self.pe.write(oprot)
2351
      oprot.writeFieldEnd()
2352
    oprot.writeFieldStop()
2353
    oprot.writeStructEnd()
2354
 
3431 rajveer 2355
  def validate(self):
2356
    return
2357
 
2358
 
420 ashish 2359
  def __repr__(self):
2360
    L = ['%s=%r' % (key, value)
2361
      for key, value in self.__dict__.iteritems()]
2362
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2363
 
2364
  def __eq__(self, other):
2365
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2366
 
2367
  def __ne__(self, other):
2368
    return not (self == other)
2369
 
696 rajveer 2370
class getPaymentForTxnId_args:
420 ashish 2371
  """
2372
  Attributes:
696 rajveer 2373
   - txnId
420 ashish 2374
  """
2375
 
2376
  thrift_spec = (
2377
    None, # 0
696 rajveer 2378
    (1, TType.I64, 'txnId', None, None, ), # 1
420 ashish 2379
  )
2380
 
696 rajveer 2381
  def __init__(self, txnId=None,):
2382
    self.txnId = txnId
420 ashish 2383
 
2384
  def read(self, iprot):
2385
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2386
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2387
      return
2388
    iprot.readStructBegin()
2389
    while True:
2390
      (fname, ftype, fid) = iprot.readFieldBegin()
2391
      if ftype == TType.STOP:
2392
        break
2393
      if fid == 1:
2394
        if ftype == TType.I64:
696 rajveer 2395
          self.txnId = iprot.readI64();
420 ashish 2396
        else:
2397
          iprot.skip(ftype)
2398
      else:
2399
        iprot.skip(ftype)
2400
      iprot.readFieldEnd()
2401
    iprot.readStructEnd()
2402
 
2403
  def write(self, oprot):
2404
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2405
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2406
      return
696 rajveer 2407
    oprot.writeStructBegin('getPaymentForTxnId_args')
3431 rajveer 2408
    if self.txnId is not None:
696 rajveer 2409
      oprot.writeFieldBegin('txnId', TType.I64, 1)
2410
      oprot.writeI64(self.txnId)
420 ashish 2411
      oprot.writeFieldEnd()
2412
    oprot.writeFieldStop()
2413
    oprot.writeStructEnd()
2414
 
3431 rajveer 2415
  def validate(self):
2416
    return
2417
 
2418
 
420 ashish 2419
  def __repr__(self):
2420
    L = ['%s=%r' % (key, value)
2421
      for key, value in self.__dict__.iteritems()]
2422
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2423
 
2424
  def __eq__(self, other):
2425
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2426
 
2427
  def __ne__(self, other):
2428
    return not (self == other)
2429
 
696 rajveer 2430
class getPaymentForTxnId_result:
420 ashish 2431
  """
2432
  Attributes:
2433
   - success
2434
   - pe
2435
  """
2436
 
2437
  thrift_spec = (
696 rajveer 2438
    (0, TType.LIST, 'success', (TType.STRUCT,(Payment, Payment.thrift_spec)), None, ), # 0
420 ashish 2439
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
2440
  )
2441
 
2442
  def __init__(self, success=None, pe=None,):
2443
    self.success = success
2444
    self.pe = pe
2445
 
2446
  def read(self, iprot):
2447
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2448
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2449
      return
2450
    iprot.readStructBegin()
2451
    while True:
2452
      (fname, ftype, fid) = iprot.readFieldBegin()
2453
      if ftype == TType.STOP:
2454
        break
2455
      if fid == 0:
696 rajveer 2456
        if ftype == TType.LIST:
2457
          self.success = []
4600 varun.gupt 2458
          (_etype52, _size49) = iprot.readListBegin()
2459
          for _i53 in xrange(_size49):
2460
            _elem54 = Payment()
2461
            _elem54.read(iprot)
2462
            self.success.append(_elem54)
696 rajveer 2463
          iprot.readListEnd()
420 ashish 2464
        else:
2465
          iprot.skip(ftype)
2466
      elif fid == 1:
2467
        if ftype == TType.STRUCT:
2468
          self.pe = PaymentException()
2469
          self.pe.read(iprot)
2470
        else:
2471
          iprot.skip(ftype)
2472
      else:
2473
        iprot.skip(ftype)
2474
      iprot.readFieldEnd()
2475
    iprot.readStructEnd()
2476
 
2477
  def write(self, oprot):
2478
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2479
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2480
      return
696 rajveer 2481
    oprot.writeStructBegin('getPaymentForTxnId_result')
3431 rajveer 2482
    if self.success is not None:
696 rajveer 2483
      oprot.writeFieldBegin('success', TType.LIST, 0)
2484
      oprot.writeListBegin(TType.STRUCT, len(self.success))
4600 varun.gupt 2485
      for iter55 in self.success:
2486
        iter55.write(oprot)
696 rajveer 2487
      oprot.writeListEnd()
420 ashish 2488
      oprot.writeFieldEnd()
3431 rajveer 2489
    if self.pe is not None:
420 ashish 2490
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
2491
      self.pe.write(oprot)
2492
      oprot.writeFieldEnd()
2493
    oprot.writeFieldStop()
2494
    oprot.writeStructEnd()
2495
 
3431 rajveer 2496
  def validate(self):
2497
    return
2498
 
2499
 
420 ashish 2500
  def __repr__(self):
2501
    L = ['%s=%r' % (key, value)
2502
      for key, value in self.__dict__.iteritems()]
2503
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2504
 
2505
  def __eq__(self, other):
2506
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2507
 
2508
  def __ne__(self, other):
2509
    return not (self == other)
2510
 
4600 varun.gupt 2511
class getSuccessfulPaymentForTxnId_args:
2512
  """
2513
  Attributes:
2514
   - txnId
2515
  """
2516
 
2517
  thrift_spec = (
2518
    None, # 0
2519
    (1, TType.I64, 'txnId', None, None, ), # 1
2520
  )
2521
 
2522
  def __init__(self, txnId=None,):
2523
    self.txnId = txnId
2524
 
2525
  def read(self, iprot):
2526
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2527
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2528
      return
2529
    iprot.readStructBegin()
2530
    while True:
2531
      (fname, ftype, fid) = iprot.readFieldBegin()
2532
      if ftype == TType.STOP:
2533
        break
2534
      if fid == 1:
2535
        if ftype == TType.I64:
2536
          self.txnId = iprot.readI64();
2537
        else:
2538
          iprot.skip(ftype)
2539
      else:
2540
        iprot.skip(ftype)
2541
      iprot.readFieldEnd()
2542
    iprot.readStructEnd()
2543
 
2544
  def write(self, oprot):
2545
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2546
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2547
      return
2548
    oprot.writeStructBegin('getSuccessfulPaymentForTxnId_args')
2549
    if self.txnId is not None:
2550
      oprot.writeFieldBegin('txnId', TType.I64, 1)
2551
      oprot.writeI64(self.txnId)
2552
      oprot.writeFieldEnd()
2553
    oprot.writeFieldStop()
2554
    oprot.writeStructEnd()
2555
 
2556
  def validate(self):
2557
    return
2558
 
2559
 
2560
  def __repr__(self):
2561
    L = ['%s=%r' % (key, value)
2562
      for key, value in self.__dict__.iteritems()]
2563
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2564
 
2565
  def __eq__(self, other):
2566
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2567
 
2568
  def __ne__(self, other):
2569
    return not (self == other)
2570
 
2571
class getSuccessfulPaymentForTxnId_result:
2572
  """
2573
  Attributes:
2574
   - success
2575
   - pe
2576
  """
2577
 
2578
  thrift_spec = (
2579
    (0, TType.STRUCT, 'success', (Payment, Payment.thrift_spec), None, ), # 0
2580
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
2581
  )
2582
 
2583
  def __init__(self, success=None, pe=None,):
2584
    self.success = success
2585
    self.pe = pe
2586
 
2587
  def read(self, iprot):
2588
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2589
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2590
      return
2591
    iprot.readStructBegin()
2592
    while True:
2593
      (fname, ftype, fid) = iprot.readFieldBegin()
2594
      if ftype == TType.STOP:
2595
        break
2596
      if fid == 0:
2597
        if ftype == TType.STRUCT:
2598
          self.success = Payment()
2599
          self.success.read(iprot)
2600
        else:
2601
          iprot.skip(ftype)
2602
      elif fid == 1:
2603
        if ftype == TType.STRUCT:
2604
          self.pe = PaymentException()
2605
          self.pe.read(iprot)
2606
        else:
2607
          iprot.skip(ftype)
2608
      else:
2609
        iprot.skip(ftype)
2610
      iprot.readFieldEnd()
2611
    iprot.readStructEnd()
2612
 
2613
  def write(self, oprot):
2614
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2615
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2616
      return
2617
    oprot.writeStructBegin('getSuccessfulPaymentForTxnId_result')
2618
    if self.success is not None:
2619
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
2620
      self.success.write(oprot)
2621
      oprot.writeFieldEnd()
2622
    if self.pe is not None:
2623
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
2624
      self.pe.write(oprot)
2625
      oprot.writeFieldEnd()
2626
    oprot.writeFieldStop()
2627
    oprot.writeStructEnd()
2628
 
2629
  def validate(self):
2630
    return
2631
 
2632
 
2633
  def __repr__(self):
2634
    L = ['%s=%r' % (key, value)
2635
      for key, value in self.__dict__.iteritems()]
2636
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2637
 
2638
  def __eq__(self, other):
2639
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2640
 
2641
  def __ne__(self, other):
2642
    return not (self == other)
2643
 
696 rajveer 2644
class updatePaymentDetails_args:
420 ashish 2645
  """
2646
  Attributes:
2647
   - id
696 rajveer 2648
   - gatewayPaymentId
2649
   - sessionId
2650
   - gatewayTxnStatus
2651
   - description
2652
   - gatewayTxnId
2653
   - authCode
2654
   - referenceCode
2655
   - errorCode
2656
   - status
1120 rajveer 2657
   - gatewayTxnDate
696 rajveer 2658
   - attributes
420 ashish 2659
  """
2660
 
2661
  thrift_spec = (
2662
    None, # 0
2663
    (1, TType.I64, 'id', None, None, ), # 1
696 rajveer 2664
    (2, TType.STRING, 'gatewayPaymentId', None, None, ), # 2
2665
    (3, TType.STRING, 'sessionId', None, None, ), # 3
2666
    (4, TType.STRING, 'gatewayTxnStatus', None, None, ), # 4
2667
    (5, TType.STRING, 'description', None, None, ), # 5
2668
    (6, TType.STRING, 'gatewayTxnId', None, None, ), # 6
2669
    (7, TType.STRING, 'authCode', None, None, ), # 7
2670
    (8, TType.STRING, 'referenceCode', None, None, ), # 8
2671
    (9, TType.STRING, 'errorCode', None, None, ), # 9
2672
    (10, TType.I32, 'status', None, None, ), # 10
1120 rajveer 2673
    (11, TType.STRING, 'gatewayTxnDate', None, None, ), # 11
2674
    (12, TType.LIST, 'attributes', (TType.STRUCT,(Attribute, Attribute.thrift_spec)), None, ), # 12
420 ashish 2675
  )
2676
 
1120 rajveer 2677
  def __init__(self, id=None, gatewayPaymentId=None, sessionId=None, gatewayTxnStatus=None, description=None, gatewayTxnId=None, authCode=None, referenceCode=None, errorCode=None, status=None, gatewayTxnDate=None, attributes=None,):
420 ashish 2678
    self.id = id
696 rajveer 2679
    self.gatewayPaymentId = gatewayPaymentId
2680
    self.sessionId = sessionId
2681
    self.gatewayTxnStatus = gatewayTxnStatus
2682
    self.description = description
2683
    self.gatewayTxnId = gatewayTxnId
2684
    self.authCode = authCode
2685
    self.referenceCode = referenceCode
2686
    self.errorCode = errorCode
2687
    self.status = status
1120 rajveer 2688
    self.gatewayTxnDate = gatewayTxnDate
696 rajveer 2689
    self.attributes = attributes
420 ashish 2690
 
2691
  def read(self, iprot):
2692
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2693
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2694
      return
2695
    iprot.readStructBegin()
2696
    while True:
2697
      (fname, ftype, fid) = iprot.readFieldBegin()
2698
      if ftype == TType.STOP:
2699
        break
2700
      if fid == 1:
2701
        if ftype == TType.I64:
2702
          self.id = iprot.readI64();
2703
        else:
2704
          iprot.skip(ftype)
2705
      elif fid == 2:
2706
        if ftype == TType.STRING:
696 rajveer 2707
          self.gatewayPaymentId = iprot.readString();
420 ashish 2708
        else:
2709
          iprot.skip(ftype)
2710
      elif fid == 3:
2711
        if ftype == TType.STRING:
696 rajveer 2712
          self.sessionId = iprot.readString();
420 ashish 2713
        else:
2714
          iprot.skip(ftype)
2715
      elif fid == 4:
2716
        if ftype == TType.STRING:
696 rajveer 2717
          self.gatewayTxnStatus = iprot.readString();
420 ashish 2718
        else:
2719
          iprot.skip(ftype)
2720
      elif fid == 5:
2721
        if ftype == TType.STRING:
696 rajveer 2722
          self.description = iprot.readString();
420 ashish 2723
        else:
2724
          iprot.skip(ftype)
2725
      elif fid == 6:
2726
        if ftype == TType.STRING:
696 rajveer 2727
          self.gatewayTxnId = iprot.readString();
420 ashish 2728
        else:
2729
          iprot.skip(ftype)
2730
      elif fid == 7:
2731
        if ftype == TType.STRING:
696 rajveer 2732
          self.authCode = iprot.readString();
420 ashish 2733
        else:
2734
          iprot.skip(ftype)
2735
      elif fid == 8:
2736
        if ftype == TType.STRING:
696 rajveer 2737
          self.referenceCode = iprot.readString();
420 ashish 2738
        else:
2739
          iprot.skip(ftype)
696 rajveer 2740
      elif fid == 9:
2741
        if ftype == TType.STRING:
2742
          self.errorCode = iprot.readString();
2743
        else:
2744
          iprot.skip(ftype)
2745
      elif fid == 10:
2746
        if ftype == TType.I32:
2747
          self.status = iprot.readI32();
2748
        else:
2749
          iprot.skip(ftype)
2750
      elif fid == 11:
1120 rajveer 2751
        if ftype == TType.STRING:
2752
          self.gatewayTxnDate = iprot.readString();
2753
        else:
2754
          iprot.skip(ftype)
2755
      elif fid == 12:
696 rajveer 2756
        if ftype == TType.LIST:
2757
          self.attributes = []
4600 varun.gupt 2758
          (_etype59, _size56) = iprot.readListBegin()
2759
          for _i60 in xrange(_size56):
2760
            _elem61 = Attribute()
2761
            _elem61.read(iprot)
2762
            self.attributes.append(_elem61)
696 rajveer 2763
          iprot.readListEnd()
2764
        else:
2765
          iprot.skip(ftype)
420 ashish 2766
      else:
2767
        iprot.skip(ftype)
2768
      iprot.readFieldEnd()
2769
    iprot.readStructEnd()
2770
 
2771
  def write(self, oprot):
2772
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2773
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2774
      return
696 rajveer 2775
    oprot.writeStructBegin('updatePaymentDetails_args')
3431 rajveer 2776
    if self.id is not None:
420 ashish 2777
      oprot.writeFieldBegin('id', TType.I64, 1)
2778
      oprot.writeI64(self.id)
2779
      oprot.writeFieldEnd()
3431 rajveer 2780
    if self.gatewayPaymentId is not None:
696 rajveer 2781
      oprot.writeFieldBegin('gatewayPaymentId', TType.STRING, 2)
2782
      oprot.writeString(self.gatewayPaymentId)
420 ashish 2783
      oprot.writeFieldEnd()
3431 rajveer 2784
    if self.sessionId is not None:
696 rajveer 2785
      oprot.writeFieldBegin('sessionId', TType.STRING, 3)
2786
      oprot.writeString(self.sessionId)
420 ashish 2787
      oprot.writeFieldEnd()
3431 rajveer 2788
    if self.gatewayTxnStatus is not None:
696 rajveer 2789
      oprot.writeFieldBegin('gatewayTxnStatus', TType.STRING, 4)
2790
      oprot.writeString(self.gatewayTxnStatus)
420 ashish 2791
      oprot.writeFieldEnd()
3431 rajveer 2792
    if self.description is not None:
696 rajveer 2793
      oprot.writeFieldBegin('description', TType.STRING, 5)
2794
      oprot.writeString(self.description)
420 ashish 2795
      oprot.writeFieldEnd()
3431 rajveer 2796
    if self.gatewayTxnId is not None:
696 rajveer 2797
      oprot.writeFieldBegin('gatewayTxnId', TType.STRING, 6)
2798
      oprot.writeString(self.gatewayTxnId)
420 ashish 2799
      oprot.writeFieldEnd()
3431 rajveer 2800
    if self.authCode is not None:
696 rajveer 2801
      oprot.writeFieldBegin('authCode', TType.STRING, 7)
2802
      oprot.writeString(self.authCode)
420 ashish 2803
      oprot.writeFieldEnd()
3431 rajveer 2804
    if self.referenceCode is not None:
696 rajveer 2805
      oprot.writeFieldBegin('referenceCode', TType.STRING, 8)
2806
      oprot.writeString(self.referenceCode)
420 ashish 2807
      oprot.writeFieldEnd()
3431 rajveer 2808
    if self.errorCode is not None:
696 rajveer 2809
      oprot.writeFieldBegin('errorCode', TType.STRING, 9)
2810
      oprot.writeString(self.errorCode)
2811
      oprot.writeFieldEnd()
3431 rajveer 2812
    if self.status is not None:
696 rajveer 2813
      oprot.writeFieldBegin('status', TType.I32, 10)
2814
      oprot.writeI32(self.status)
2815
      oprot.writeFieldEnd()
3431 rajveer 2816
    if self.gatewayTxnDate is not None:
1120 rajveer 2817
      oprot.writeFieldBegin('gatewayTxnDate', TType.STRING, 11)
2818
      oprot.writeString(self.gatewayTxnDate)
2819
      oprot.writeFieldEnd()
3431 rajveer 2820
    if self.attributes is not None:
1120 rajveer 2821
      oprot.writeFieldBegin('attributes', TType.LIST, 12)
696 rajveer 2822
      oprot.writeListBegin(TType.STRUCT, len(self.attributes))
4600 varun.gupt 2823
      for iter62 in self.attributes:
2824
        iter62.write(oprot)
696 rajveer 2825
      oprot.writeListEnd()
2826
      oprot.writeFieldEnd()
420 ashish 2827
    oprot.writeFieldStop()
2828
    oprot.writeStructEnd()
2829
 
3431 rajveer 2830
  def validate(self):
2831
    return
2832
 
2833
 
420 ashish 2834
  def __repr__(self):
2835
    L = ['%s=%r' % (key, value)
2836
      for key, value in self.__dict__.iteritems()]
2837
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2838
 
2839
  def __eq__(self, other):
2840
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2841
 
2842
  def __ne__(self, other):
2843
    return not (self == other)
2844
 
696 rajveer 2845
class updatePaymentDetails_result:
420 ashish 2846
  """
2847
  Attributes:
696 rajveer 2848
   - success
420 ashish 2849
   - pe
2850
  """
2851
 
2852
  thrift_spec = (
696 rajveer 2853
    (0, TType.BOOL, 'success', None, None, ), # 0
420 ashish 2854
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
2855
  )
2856
 
696 rajveer 2857
  def __init__(self, success=None, pe=None,):
2858
    self.success = success
420 ashish 2859
    self.pe = pe
2860
 
2861
  def read(self, iprot):
2862
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2863
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2864
      return
2865
    iprot.readStructBegin()
2866
    while True:
2867
      (fname, ftype, fid) = iprot.readFieldBegin()
2868
      if ftype == TType.STOP:
2869
        break
696 rajveer 2870
      if fid == 0:
2871
        if ftype == TType.BOOL:
2872
          self.success = iprot.readBool();
2873
        else:
2874
          iprot.skip(ftype)
2875
      elif fid == 1:
420 ashish 2876
        if ftype == TType.STRUCT:
2877
          self.pe = PaymentException()
2878
          self.pe.read(iprot)
2879
        else:
2880
          iprot.skip(ftype)
2881
      else:
2882
        iprot.skip(ftype)
2883
      iprot.readFieldEnd()
2884
    iprot.readStructEnd()
2885
 
2886
  def write(self, oprot):
2887
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2888
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2889
      return
696 rajveer 2890
    oprot.writeStructBegin('updatePaymentDetails_result')
3431 rajveer 2891
    if self.success is not None:
696 rajveer 2892
      oprot.writeFieldBegin('success', TType.BOOL, 0)
2893
      oprot.writeBool(self.success)
2894
      oprot.writeFieldEnd()
3431 rajveer 2895
    if self.pe is not None:
420 ashish 2896
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
2897
      self.pe.write(oprot)
2898
      oprot.writeFieldEnd()
2899
    oprot.writeFieldStop()
2900
    oprot.writeStructEnd()
2901
 
3431 rajveer 2902
  def validate(self):
2903
    return
2904
 
2905
 
420 ashish 2906
  def __repr__(self):
2907
    L = ['%s=%r' % (key, value)
2908
      for key, value in self.__dict__.iteritems()]
2909
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2910
 
2911
  def __eq__(self, other):
2912
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2913
 
2914
  def __ne__(self, other):
2915
    return not (self == other)
2916
 
1731 ankur.sing 2917
class getSuccessfulPaymentsAmountRange_args:
420 ashish 2918
 
1627 ankur.sing 2919
  thrift_spec = (
2920
  )
2921
 
2922
  def read(self, iprot):
2923
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2924
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2925
      return
2926
    iprot.readStructBegin()
2927
    while True:
2928
      (fname, ftype, fid) = iprot.readFieldBegin()
2929
      if ftype == TType.STOP:
2930
        break
2931
      else:
2932
        iprot.skip(ftype)
2933
      iprot.readFieldEnd()
2934
    iprot.readStructEnd()
2935
 
2936
  def write(self, oprot):
2937
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2938
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2939
      return
1731 ankur.sing 2940
    oprot.writeStructBegin('getSuccessfulPaymentsAmountRange_args')
1627 ankur.sing 2941
    oprot.writeFieldStop()
2942
    oprot.writeStructEnd()
2943
 
3431 rajveer 2944
  def validate(self):
2945
    return
2946
 
2947
 
1627 ankur.sing 2948
  def __repr__(self):
2949
    L = ['%s=%r' % (key, value)
2950
      for key, value in self.__dict__.iteritems()]
2951
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2952
 
2953
  def __eq__(self, other):
2954
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2955
 
2956
  def __ne__(self, other):
2957
    return not (self == other)
2958
 
1731 ankur.sing 2959
class getSuccessfulPaymentsAmountRange_result:
1627 ankur.sing 2960
  """
2961
  Attributes:
2962
   - success
2963
  """
2964
 
2965
  thrift_spec = (
1731 ankur.sing 2966
    (0, TType.LIST, 'success', (TType.DOUBLE,None), None, ), # 0
1627 ankur.sing 2967
  )
2968
 
2969
  def __init__(self, success=None,):
2970
    self.success = success
2971
 
2972
  def read(self, iprot):
2973
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2974
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2975
      return
2976
    iprot.readStructBegin()
2977
    while True:
2978
      (fname, ftype, fid) = iprot.readFieldBegin()
2979
      if ftype == TType.STOP:
2980
        break
2981
      if fid == 0:
1731 ankur.sing 2982
        if ftype == TType.LIST:
2983
          self.success = []
4600 varun.gupt 2984
          (_etype66, _size63) = iprot.readListBegin()
2985
          for _i67 in xrange(_size63):
2986
            _elem68 = iprot.readDouble();
2987
            self.success.append(_elem68)
1731 ankur.sing 2988
          iprot.readListEnd()
1627 ankur.sing 2989
        else:
2990
          iprot.skip(ftype)
2991
      else:
2992
        iprot.skip(ftype)
2993
      iprot.readFieldEnd()
2994
    iprot.readStructEnd()
2995
 
2996
  def write(self, oprot):
2997
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2998
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2999
      return
1731 ankur.sing 3000
    oprot.writeStructBegin('getSuccessfulPaymentsAmountRange_result')
3431 rajveer 3001
    if self.success is not None:
1731 ankur.sing 3002
      oprot.writeFieldBegin('success', TType.LIST, 0)
3003
      oprot.writeListBegin(TType.DOUBLE, len(self.success))
4600 varun.gupt 3004
      for iter69 in self.success:
3005
        oprot.writeDouble(iter69)
1731 ankur.sing 3006
      oprot.writeListEnd()
1627 ankur.sing 3007
      oprot.writeFieldEnd()
3008
    oprot.writeFieldStop()
3009
    oprot.writeStructEnd()
3010
 
3431 rajveer 3011
  def validate(self):
3012
    return
3013
 
3014
 
1627 ankur.sing 3015
  def __repr__(self):
3016
    L = ['%s=%r' % (key, value)
3017
      for key, value in self.__dict__.iteritems()]
3018
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3019
 
3020
  def __eq__(self, other):
3021
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3022
 
3023
  def __ne__(self, other):
3024
    return not (self == other)
3025
 
3010 chandransh 3026
class initializeHdfcPayment_args:
2708 chandransh 3027
  """
3028
  Attributes:
3029
   - merchantPaymentId
3030
  """
3031
 
3032
  thrift_spec = (
3033
    None, # 0
3034
    (1, TType.I64, 'merchantPaymentId', None, None, ), # 1
3035
  )
3036
 
3037
  def __init__(self, merchantPaymentId=None,):
3038
    self.merchantPaymentId = merchantPaymentId
3039
 
3040
  def read(self, iprot):
3041
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3042
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3043
      return
3044
    iprot.readStructBegin()
3045
    while True:
3046
      (fname, ftype, fid) = iprot.readFieldBegin()
3047
      if ftype == TType.STOP:
3048
        break
3049
      if fid == 1:
3050
        if ftype == TType.I64:
3051
          self.merchantPaymentId = iprot.readI64();
3052
        else:
3053
          iprot.skip(ftype)
3054
      else:
3055
        iprot.skip(ftype)
3056
      iprot.readFieldEnd()
3057
    iprot.readStructEnd()
3058
 
3059
  def write(self, oprot):
3060
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3061
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3062
      return
3010 chandransh 3063
    oprot.writeStructBegin('initializeHdfcPayment_args')
3431 rajveer 3064
    if self.merchantPaymentId is not None:
2708 chandransh 3065
      oprot.writeFieldBegin('merchantPaymentId', TType.I64, 1)
3066
      oprot.writeI64(self.merchantPaymentId)
3067
      oprot.writeFieldEnd()
3068
    oprot.writeFieldStop()
3069
    oprot.writeStructEnd()
3070
 
3431 rajveer 3071
  def validate(self):
3072
    return
3073
 
3074
 
2708 chandransh 3075
  def __repr__(self):
3076
    L = ['%s=%r' % (key, value)
3077
      for key, value in self.__dict__.iteritems()]
3078
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3079
 
3080
  def __eq__(self, other):
3081
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3082
 
3083
  def __ne__(self, other):
3084
    return not (self == other)
3085
 
3010 chandransh 3086
class initializeHdfcPayment_result:
2708 chandransh 3087
  """
3088
  Attributes:
3089
   - success
3090
   - pe
3091
  """
3092
 
3093
  thrift_spec = (
3010 chandransh 3094
    (0, TType.STRING, 'success', None, None, ), # 0
2708 chandransh 3095
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
3096
  )
3097
 
3098
  def __init__(self, success=None, pe=None,):
3099
    self.success = success
3100
    self.pe = pe
3101
 
3102
  def read(self, iprot):
3103
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3104
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3105
      return
3106
    iprot.readStructBegin()
3107
    while True:
3108
      (fname, ftype, fid) = iprot.readFieldBegin()
3109
      if ftype == TType.STOP:
3110
        break
3111
      if fid == 0:
3010 chandransh 3112
        if ftype == TType.STRING:
3113
          self.success = iprot.readString();
2708 chandransh 3114
        else:
3115
          iprot.skip(ftype)
3116
      elif fid == 1:
3117
        if ftype == TType.STRUCT:
3118
          self.pe = PaymentException()
3119
          self.pe.read(iprot)
3120
        else:
3121
          iprot.skip(ftype)
3122
      else:
3123
        iprot.skip(ftype)
3124
      iprot.readFieldEnd()
3125
    iprot.readStructEnd()
3126
 
3127
  def write(self, oprot):
3128
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3129
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3130
      return
3010 chandransh 3131
    oprot.writeStructBegin('initializeHdfcPayment_result')
3431 rajveer 3132
    if self.success is not None:
3010 chandransh 3133
      oprot.writeFieldBegin('success', TType.STRING, 0)
3134
      oprot.writeString(self.success)
2708 chandransh 3135
      oprot.writeFieldEnd()
3431 rajveer 3136
    if self.pe is not None:
2708 chandransh 3137
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
3138
      self.pe.write(oprot)
3139
      oprot.writeFieldEnd()
3140
    oprot.writeFieldStop()
3141
    oprot.writeStructEnd()
3142
 
3431 rajveer 3143
  def validate(self):
3144
    return
3145
 
3146
 
2708 chandransh 3147
  def __repr__(self):
3148
    L = ['%s=%r' % (key, value)
3149
      for key, value in self.__dict__.iteritems()]
3150
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3151
 
3152
  def __eq__(self, other):
3153
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3154
 
3155
  def __ne__(self, other):
3156
    return not (self == other)
3157
 
6050 anupam.sin 3158
class doHdfcPaymentForDigitalOrder_args:
3159
  """
3160
  Attributes:
3161
   - merchantPaymentId
3162
   - rechargeOrderId
6228 anupam.sin 3163
   - phone
6050 anupam.sin 3164
  """
3165
 
6228 anupam.sin 3166
  thrift_spec = None
3167
  def __init__(self, merchantPaymentId=None, rechargeOrderId=None, phone=None,):
6050 anupam.sin 3168
    self.merchantPaymentId = merchantPaymentId
3169
    self.rechargeOrderId = rechargeOrderId
6228 anupam.sin 3170
    self.phone = phone
6050 anupam.sin 3171
 
3172
  def read(self, iprot):
3173
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3174
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3175
      return
3176
    iprot.readStructBegin()
3177
    while True:
3178
      (fname, ftype, fid) = iprot.readFieldBegin()
3179
      if ftype == TType.STOP:
3180
        break
3181
      if fid == 1:
3182
        if ftype == TType.I64:
3183
          self.merchantPaymentId = iprot.readI64();
3184
        else:
3185
          iprot.skip(ftype)
3186
      elif fid == 2:
3187
        if ftype == TType.I64:
3188
          self.rechargeOrderId = iprot.readI64();
3189
        else:
3190
          iprot.skip(ftype)
6228 anupam.sin 3191
      elif fid == -1:
3192
        if ftype == TType.STRING:
3193
          self.phone = iprot.readString();
3194
        else:
3195
          iprot.skip(ftype)
6050 anupam.sin 3196
      else:
3197
        iprot.skip(ftype)
3198
      iprot.readFieldEnd()
3199
    iprot.readStructEnd()
3200
 
3201
  def write(self, oprot):
3202
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3203
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3204
      return
3205
    oprot.writeStructBegin('doHdfcPaymentForDigitalOrder_args')
6228 anupam.sin 3206
    if self.phone is not None:
3207
      oprot.writeFieldBegin('phone', TType.STRING, -1)
3208
      oprot.writeString(self.phone)
3209
      oprot.writeFieldEnd()
6050 anupam.sin 3210
    if self.merchantPaymentId is not None:
3211
      oprot.writeFieldBegin('merchantPaymentId', TType.I64, 1)
3212
      oprot.writeI64(self.merchantPaymentId)
3213
      oprot.writeFieldEnd()
3214
    if self.rechargeOrderId is not None:
3215
      oprot.writeFieldBegin('rechargeOrderId', TType.I64, 2)
3216
      oprot.writeI64(self.rechargeOrderId)
3217
      oprot.writeFieldEnd()
3218
    oprot.writeFieldStop()
3219
    oprot.writeStructEnd()
3220
 
3221
  def validate(self):
3222
    return
3223
 
3224
 
3225
  def __repr__(self):
3226
    L = ['%s=%r' % (key, value)
3227
      for key, value in self.__dict__.iteritems()]
3228
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3229
 
3230
  def __eq__(self, other):
3231
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3232
 
3233
  def __ne__(self, other):
3234
    return not (self == other)
3235
 
3236
class doHdfcPaymentForDigitalOrder_result:
3237
  """
3238
  Attributes:
3239
   - success
3240
   - pe
3241
  """
3242
 
3243
  thrift_spec = (
3244
    (0, TType.STRING, 'success', None, None, ), # 0
3245
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
3246
  )
3247
 
3248
  def __init__(self, success=None, pe=None,):
3249
    self.success = success
3250
    self.pe = pe
3251
 
3252
  def read(self, iprot):
3253
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3254
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3255
      return
3256
    iprot.readStructBegin()
3257
    while True:
3258
      (fname, ftype, fid) = iprot.readFieldBegin()
3259
      if ftype == TType.STOP:
3260
        break
3261
      if fid == 0:
3262
        if ftype == TType.STRING:
3263
          self.success = iprot.readString();
3264
        else:
3265
          iprot.skip(ftype)
3266
      elif fid == 1:
3267
        if ftype == TType.STRUCT:
3268
          self.pe = PaymentException()
3269
          self.pe.read(iprot)
3270
        else:
3271
          iprot.skip(ftype)
3272
      else:
3273
        iprot.skip(ftype)
3274
      iprot.readFieldEnd()
3275
    iprot.readStructEnd()
3276
 
3277
  def write(self, oprot):
3278
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3279
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3280
      return
3281
    oprot.writeStructBegin('doHdfcPaymentForDigitalOrder_result')
3282
    if self.success is not None:
3283
      oprot.writeFieldBegin('success', TType.STRING, 0)
3284
      oprot.writeString(self.success)
3285
      oprot.writeFieldEnd()
3286
    if self.pe is not None:
3287
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
3288
      self.pe.write(oprot)
3289
      oprot.writeFieldEnd()
3290
    oprot.writeFieldStop()
3291
    oprot.writeStructEnd()
3292
 
3293
  def validate(self):
3294
    return
3295
 
3296
 
3297
  def __repr__(self):
3298
    L = ['%s=%r' % (key, value)
3299
      for key, value in self.__dict__.iteritems()]
3300
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3301
 
3302
  def __eq__(self, other):
3303
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3304
 
3305
  def __ne__(self, other):
3306
    return not (self == other)
3307
 
3616 chandransh 3308
class initializeHdfcEmiPayment_args:
3309
  """
3310
  Attributes:
3311
   - merchantPaymentId
3312
  """
3313
 
3314
  thrift_spec = (
3315
    None, # 0
3316
    (1, TType.I64, 'merchantPaymentId', None, None, ), # 1
3317
  )
3318
 
3319
  def __init__(self, merchantPaymentId=None,):
3320
    self.merchantPaymentId = merchantPaymentId
3321
 
3322
  def read(self, iprot):
3323
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3324
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3325
      return
3326
    iprot.readStructBegin()
3327
    while True:
3328
      (fname, ftype, fid) = iprot.readFieldBegin()
3329
      if ftype == TType.STOP:
3330
        break
3331
      if fid == 1:
3332
        if ftype == TType.I64:
3333
          self.merchantPaymentId = iprot.readI64();
3334
        else:
3335
          iprot.skip(ftype)
3336
      else:
3337
        iprot.skip(ftype)
3338
      iprot.readFieldEnd()
3339
    iprot.readStructEnd()
3340
 
3341
  def write(self, oprot):
3342
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3343
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3344
      return
3345
    oprot.writeStructBegin('initializeHdfcEmiPayment_args')
3346
    if self.merchantPaymentId is not None:
3347
      oprot.writeFieldBegin('merchantPaymentId', TType.I64, 1)
3348
      oprot.writeI64(self.merchantPaymentId)
3349
      oprot.writeFieldEnd()
3350
    oprot.writeFieldStop()
3351
    oprot.writeStructEnd()
3352
 
3353
  def validate(self):
3354
    return
3355
 
3356
 
3357
  def __repr__(self):
3358
    L = ['%s=%r' % (key, value)
3359
      for key, value in self.__dict__.iteritems()]
3360
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3361
 
3362
  def __eq__(self, other):
3363
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3364
 
3365
  def __ne__(self, other):
3366
    return not (self == other)
3367
 
3368
class initializeHdfcEmiPayment_result:
3369
  """
3370
  Attributes:
3371
   - success
3372
   - pe
3373
  """
3374
 
3375
  thrift_spec = (
3376
    (0, TType.STRING, 'success', None, None, ), # 0
3377
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
3378
  )
3379
 
3380
  def __init__(self, success=None, pe=None,):
3381
    self.success = success
3382
    self.pe = pe
3383
 
3384
  def read(self, iprot):
3385
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3386
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3387
      return
3388
    iprot.readStructBegin()
3389
    while True:
3390
      (fname, ftype, fid) = iprot.readFieldBegin()
3391
      if ftype == TType.STOP:
3392
        break
3393
      if fid == 0:
3394
        if ftype == TType.STRING:
3395
          self.success = iprot.readString();
3396
        else:
3397
          iprot.skip(ftype)
3398
      elif fid == 1:
3399
        if ftype == TType.STRUCT:
3400
          self.pe = PaymentException()
3401
          self.pe.read(iprot)
3402
        else:
3403
          iprot.skip(ftype)
3404
      else:
3405
        iprot.skip(ftype)
3406
      iprot.readFieldEnd()
3407
    iprot.readStructEnd()
3408
 
3409
  def write(self, oprot):
3410
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3411
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3412
      return
3413
    oprot.writeStructBegin('initializeHdfcEmiPayment_result')
3414
    if self.success is not None:
3415
      oprot.writeFieldBegin('success', TType.STRING, 0)
3416
      oprot.writeString(self.success)
3417
      oprot.writeFieldEnd()
3418
    if self.pe is not None:
3419
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
3420
      self.pe.write(oprot)
3421
      oprot.writeFieldEnd()
3422
    oprot.writeFieldStop()
3423
    oprot.writeStructEnd()
3424
 
3425
  def validate(self):
3426
    return
3427
 
3428
 
3429
  def __repr__(self):
3430
    L = ['%s=%r' % (key, value)
3431
      for key, value in self.__dict__.iteritems()]
3432
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3433
 
3434
  def __eq__(self, other):
3435
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3436
 
3437
  def __ne__(self, other):
3438
    return not (self == other)
3439
 
3010 chandransh 3440
class createRefund_args:
2559 chandransh 3441
  """
3442
  Attributes:
3010 chandransh 3443
   - orderId
3444
   - merchantTxnId
3445
   - amount
2559 chandransh 3446
  """
3447
 
3448
  thrift_spec = (
3449
    None, # 0
3010 chandransh 3450
    (1, TType.I64, 'orderId', None, None, ), # 1
3451
    (2, TType.I64, 'merchantTxnId', None, None, ), # 2
3452
    (3, TType.DOUBLE, 'amount', None, None, ), # 3
2559 chandransh 3453
  )
3454
 
3010 chandransh 3455
  def __init__(self, orderId=None, merchantTxnId=None, amount=None,):
3456
    self.orderId = orderId
3457
    self.merchantTxnId = merchantTxnId
3458
    self.amount = amount
2559 chandransh 3459
 
3460
  def read(self, iprot):
3461
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3462
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3463
      return
3464
    iprot.readStructBegin()
3465
    while True:
3466
      (fname, ftype, fid) = iprot.readFieldBegin()
3467
      if ftype == TType.STOP:
3468
        break
3469
      if fid == 1:
3470
        if ftype == TType.I64:
3010 chandransh 3471
          self.orderId = iprot.readI64();
2559 chandransh 3472
        else:
3473
          iprot.skip(ftype)
3010 chandransh 3474
      elif fid == 2:
3475
        if ftype == TType.I64:
3476
          self.merchantTxnId = iprot.readI64();
3477
        else:
3478
          iprot.skip(ftype)
3479
      elif fid == 3:
3480
        if ftype == TType.DOUBLE:
3481
          self.amount = iprot.readDouble();
3482
        else:
3483
          iprot.skip(ftype)
2559 chandransh 3484
      else:
3485
        iprot.skip(ftype)
3486
      iprot.readFieldEnd()
3487
    iprot.readStructEnd()
3488
 
3489
  def write(self, oprot):
3490
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3491
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3492
      return
3010 chandransh 3493
    oprot.writeStructBegin('createRefund_args')
3431 rajveer 3494
    if self.orderId is not None:
3010 chandransh 3495
      oprot.writeFieldBegin('orderId', TType.I64, 1)
3496
      oprot.writeI64(self.orderId)
2559 chandransh 3497
      oprot.writeFieldEnd()
3431 rajveer 3498
    if self.merchantTxnId is not None:
3010 chandransh 3499
      oprot.writeFieldBegin('merchantTxnId', TType.I64, 2)
3500
      oprot.writeI64(self.merchantTxnId)
3501
      oprot.writeFieldEnd()
3431 rajveer 3502
    if self.amount is not None:
3010 chandransh 3503
      oprot.writeFieldBegin('amount', TType.DOUBLE, 3)
3504
      oprot.writeDouble(self.amount)
3505
      oprot.writeFieldEnd()
2559 chandransh 3506
    oprot.writeFieldStop()
3507
    oprot.writeStructEnd()
3508
 
3431 rajveer 3509
  def validate(self):
3510
    return
3511
 
3512
 
2559 chandransh 3513
  def __repr__(self):
3514
    L = ['%s=%r' % (key, value)
3515
      for key, value in self.__dict__.iteritems()]
3516
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3517
 
3518
  def __eq__(self, other):
3519
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3520
 
3521
  def __ne__(self, other):
3522
    return not (self == other)
3523
 
3010 chandransh 3524
class createRefund_result:
2559 chandransh 3525
  """
3526
  Attributes:
3527
   - success
3528
   - pe
3529
  """
3530
 
3531
  thrift_spec = (
3010 chandransh 3532
    (0, TType.I64, 'success', None, None, ), # 0
2559 chandransh 3533
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
3534
  )
3535
 
3536
  def __init__(self, success=None, pe=None,):
3537
    self.success = success
3538
    self.pe = pe
3539
 
3540
  def read(self, iprot):
3541
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3542
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3543
      return
3544
    iprot.readStructBegin()
3545
    while True:
3546
      (fname, ftype, fid) = iprot.readFieldBegin()
3547
      if ftype == TType.STOP:
3548
        break
3549
      if fid == 0:
3010 chandransh 3550
        if ftype == TType.I64:
3551
          self.success = iprot.readI64();
2559 chandransh 3552
        else:
3553
          iprot.skip(ftype)
3554
      elif fid == 1:
3555
        if ftype == TType.STRUCT:
3556
          self.pe = PaymentException()
3557
          self.pe.read(iprot)
3558
        else:
3559
          iprot.skip(ftype)
3560
      else:
3561
        iprot.skip(ftype)
3562
      iprot.readFieldEnd()
3563
    iprot.readStructEnd()
3564
 
3565
  def write(self, oprot):
3566
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3567
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3568
      return
3010 chandransh 3569
    oprot.writeStructBegin('createRefund_result')
3431 rajveer 3570
    if self.success is not None:
3010 chandransh 3571
      oprot.writeFieldBegin('success', TType.I64, 0)
3572
      oprot.writeI64(self.success)
2559 chandransh 3573
      oprot.writeFieldEnd()
3431 rajveer 3574
    if self.pe is not None:
2559 chandransh 3575
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
3576
      self.pe.write(oprot)
3577
      oprot.writeFieldEnd()
3578
    oprot.writeFieldStop()
3579
    oprot.writeStructEnd()
3580
 
3431 rajveer 3581
  def validate(self):
3582
    return
3583
 
3584
 
2559 chandransh 3585
  def __repr__(self):
3586
    L = ['%s=%r' % (key, value)
3587
      for key, value in self.__dict__.iteritems()]
3588
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3589
 
3590
  def __eq__(self, other):
3591
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3592
 
3593
  def __ne__(self, other):
3594
    return not (self == other)
3595
 
3010 chandransh 3596
class capturePayment_args:
2685 chandransh 3597
  """
3598
  Attributes:
3599
   - merchantTxnId
3600
  """
2559 chandransh 3601
 
2685 chandransh 3602
  thrift_spec = (
3603
    None, # 0
3010 chandransh 3604
    (1, TType.I64, 'merchantTxnId', None, None, ), # 1
2685 chandransh 3605
  )
3606
 
3010 chandransh 3607
  def __init__(self, merchantTxnId=None,):
2685 chandransh 3608
    self.merchantTxnId = merchantTxnId
3609
 
3610
  def read(self, iprot):
3611
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3612
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3613
      return
3614
    iprot.readStructBegin()
3615
    while True:
3616
      (fname, ftype, fid) = iprot.readFieldBegin()
3617
      if ftype == TType.STOP:
3618
        break
3619
      if fid == 1:
3620
        if ftype == TType.I64:
3621
          self.merchantTxnId = iprot.readI64();
3622
        else:
3623
          iprot.skip(ftype)
3624
      else:
3625
        iprot.skip(ftype)
3626
      iprot.readFieldEnd()
3627
    iprot.readStructEnd()
3628
 
3629
  def write(self, oprot):
3630
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3631
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3632
      return
3010 chandransh 3633
    oprot.writeStructBegin('capturePayment_args')
3431 rajveer 3634
    if self.merchantTxnId is not None:
3010 chandransh 3635
      oprot.writeFieldBegin('merchantTxnId', TType.I64, 1)
2685 chandransh 3636
      oprot.writeI64(self.merchantTxnId)
3637
      oprot.writeFieldEnd()
3638
    oprot.writeFieldStop()
3639
    oprot.writeStructEnd()
3640
 
3431 rajveer 3641
  def validate(self):
3642
    return
3643
 
3644
 
2685 chandransh 3645
  def __repr__(self):
3646
    L = ['%s=%r' % (key, value)
3647
      for key, value in self.__dict__.iteritems()]
3648
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3649
 
3650
  def __eq__(self, other):
3651
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3652
 
3653
  def __ne__(self, other):
3654
    return not (self == other)
3655
 
3010 chandransh 3656
class capturePayment_result:
2685 chandransh 3657
  """
3658
  Attributes:
3659
   - success
3660
   - pe
3661
  """
3662
 
3663
  thrift_spec = (
3010 chandransh 3664
    (0, TType.BOOL, 'success', None, None, ), # 0
2685 chandransh 3665
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
3666
  )
3667
 
3668
  def __init__(self, success=None, pe=None,):
3669
    self.success = success
3670
    self.pe = pe
3671
 
3672
  def read(self, iprot):
3673
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3674
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3675
      return
3676
    iprot.readStructBegin()
3677
    while True:
3678
      (fname, ftype, fid) = iprot.readFieldBegin()
3679
      if ftype == TType.STOP:
3680
        break
3681
      if fid == 0:
3010 chandransh 3682
        if ftype == TType.BOOL:
3683
          self.success = iprot.readBool();
2685 chandransh 3684
        else:
3685
          iprot.skip(ftype)
3686
      elif fid == 1:
3687
        if ftype == TType.STRUCT:
3688
          self.pe = PaymentException()
3689
          self.pe.read(iprot)
3690
        else:
3691
          iprot.skip(ftype)
3692
      else:
3693
        iprot.skip(ftype)
3694
      iprot.readFieldEnd()
3695
    iprot.readStructEnd()
3696
 
3697
  def write(self, oprot):
3698
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3699
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3700
      return
3010 chandransh 3701
    oprot.writeStructBegin('capturePayment_result')
3431 rajveer 3702
    if self.success is not None:
3010 chandransh 3703
      oprot.writeFieldBegin('success', TType.BOOL, 0)
3704
      oprot.writeBool(self.success)
2685 chandransh 3705
      oprot.writeFieldEnd()
3431 rajveer 3706
    if self.pe is not None:
2685 chandransh 3707
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
3708
      self.pe.write(oprot)
3709
      oprot.writeFieldEnd()
3710
    oprot.writeFieldStop()
3711
    oprot.writeStructEnd()
3712
 
3431 rajveer 3713
  def validate(self):
3714
    return
3715
 
3716
 
2685 chandransh 3717
  def __repr__(self):
3718
    L = ['%s=%r' % (key, value)
3719
      for key, value in self.__dict__.iteritems()]
3720
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3721
 
3722
  def __eq__(self, other):
3723
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3724
 
3725
  def __ne__(self, other):
3726
    return not (self == other)
3956 chandransh 3727
 
3728
class partiallyCapturePayment_args:
3729
  """
3730
  Attributes:
3731
   - merchantTxnId
3732
   - amount
3733
   - xferBy
3734
   - xferTxnId
3735
   - xferDate
3736
  """
3737
 
3738
  thrift_spec = (
3739
    None, # 0
3740
    (1, TType.I64, 'merchantTxnId', None, None, ), # 1
3741
    (2, TType.DOUBLE, 'amount', None, None, ), # 2
3742
    (3, TType.STRING, 'xferBy', None, None, ), # 3
3743
    (4, TType.STRING, 'xferTxnId', None, None, ), # 4
3744
    (5, TType.I64, 'xferDate', None, None, ), # 5
3745
  )
3746
 
3747
  def __init__(self, merchantTxnId=None, amount=None, xferBy=None, xferTxnId=None, xferDate=None,):
3748
    self.merchantTxnId = merchantTxnId
3749
    self.amount = amount
3750
    self.xferBy = xferBy
3751
    self.xferTxnId = xferTxnId
3752
    self.xferDate = xferDate
3753
 
3754
  def read(self, iprot):
3755
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3756
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3757
      return
3758
    iprot.readStructBegin()
3759
    while True:
3760
      (fname, ftype, fid) = iprot.readFieldBegin()
3761
      if ftype == TType.STOP:
3762
        break
3763
      if fid == 1:
3764
        if ftype == TType.I64:
3765
          self.merchantTxnId = iprot.readI64();
3766
        else:
3767
          iprot.skip(ftype)
3768
      elif fid == 2:
3769
        if ftype == TType.DOUBLE:
3770
          self.amount = iprot.readDouble();
3771
        else:
3772
          iprot.skip(ftype)
3773
      elif fid == 3:
3774
        if ftype == TType.STRING:
3775
          self.xferBy = iprot.readString();
3776
        else:
3777
          iprot.skip(ftype)
3778
      elif fid == 4:
3779
        if ftype == TType.STRING:
3780
          self.xferTxnId = iprot.readString();
3781
        else:
3782
          iprot.skip(ftype)
3783
      elif fid == 5:
3784
        if ftype == TType.I64:
3785
          self.xferDate = iprot.readI64();
3786
        else:
3787
          iprot.skip(ftype)
3788
      else:
3789
        iprot.skip(ftype)
3790
      iprot.readFieldEnd()
3791
    iprot.readStructEnd()
3792
 
3793
  def write(self, oprot):
3794
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3795
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3796
      return
3797
    oprot.writeStructBegin('partiallyCapturePayment_args')
3798
    if self.merchantTxnId is not None:
3799
      oprot.writeFieldBegin('merchantTxnId', TType.I64, 1)
3800
      oprot.writeI64(self.merchantTxnId)
3801
      oprot.writeFieldEnd()
3802
    if self.amount is not None:
3803
      oprot.writeFieldBegin('amount', TType.DOUBLE, 2)
3804
      oprot.writeDouble(self.amount)
3805
      oprot.writeFieldEnd()
3806
    if self.xferBy is not None:
3807
      oprot.writeFieldBegin('xferBy', TType.STRING, 3)
3808
      oprot.writeString(self.xferBy)
3809
      oprot.writeFieldEnd()
3810
    if self.xferTxnId is not None:
3811
      oprot.writeFieldBegin('xferTxnId', TType.STRING, 4)
3812
      oprot.writeString(self.xferTxnId)
3813
      oprot.writeFieldEnd()
3814
    if self.xferDate is not None:
3815
      oprot.writeFieldBegin('xferDate', TType.I64, 5)
3816
      oprot.writeI64(self.xferDate)
3817
      oprot.writeFieldEnd()
3818
    oprot.writeFieldStop()
3819
    oprot.writeStructEnd()
3820
 
3821
  def validate(self):
3822
    return
3823
 
3824
 
3825
  def __repr__(self):
3826
    L = ['%s=%r' % (key, value)
3827
      for key, value in self.__dict__.iteritems()]
3828
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3829
 
3830
  def __eq__(self, other):
3831
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3832
 
3833
  def __ne__(self, other):
3834
    return not (self == other)
3835
 
3836
class partiallyCapturePayment_result:
3837
  """
3838
  Attributes:
3839
   - success
3840
   - pe
3841
  """
3842
 
3843
  thrift_spec = (
3844
    (0, TType.BOOL, 'success', None, None, ), # 0
3845
    (1, TType.STRUCT, 'pe', (PaymentException, PaymentException.thrift_spec), None, ), # 1
3846
  )
3847
 
3848
  def __init__(self, success=None, pe=None,):
3849
    self.success = success
3850
    self.pe = pe
3851
 
3852
  def read(self, iprot):
3853
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3854
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3855
      return
3856
    iprot.readStructBegin()
3857
    while True:
3858
      (fname, ftype, fid) = iprot.readFieldBegin()
3859
      if ftype == TType.STOP:
3860
        break
3861
      if fid == 0:
3862
        if ftype == TType.BOOL:
3863
          self.success = iprot.readBool();
3864
        else:
3865
          iprot.skip(ftype)
3866
      elif fid == 1:
3867
        if ftype == TType.STRUCT:
3868
          self.pe = PaymentException()
3869
          self.pe.read(iprot)
3870
        else:
3871
          iprot.skip(ftype)
3872
      else:
3873
        iprot.skip(ftype)
3874
      iprot.readFieldEnd()
3875
    iprot.readStructEnd()
3876
 
3877
  def write(self, oprot):
3878
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3879
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3880
      return
3881
    oprot.writeStructBegin('partiallyCapturePayment_result')
3882
    if self.success is not None:
3883
      oprot.writeFieldBegin('success', TType.BOOL, 0)
3884
      oprot.writeBool(self.success)
3885
      oprot.writeFieldEnd()
3886
    if self.pe is not None:
3887
      oprot.writeFieldBegin('pe', TType.STRUCT, 1)
3888
      self.pe.write(oprot)
3889
      oprot.writeFieldEnd()
3890
    oprot.writeFieldStop()
3891
    oprot.writeStructEnd()
3892
 
3893
  def validate(self):
3894
    return
3895
 
3896
 
3897
  def __repr__(self):
3898
    L = ['%s=%r' % (key, value)
3899
      for key, value in self.__dict__.iteritems()]
3900
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3901
 
3902
  def __eq__(self, other):
3903
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3904
 
3905
  def __ne__(self, other):
3906
    return not (self == other)
4008 mandeep.dh 3907
 
3908
class getPaymentsRequiringExtraProcessing_args:
3909
  """
3910
  Attributes:
3911
   - category
3912
  """
3913
 
3914
  thrift_spec = (
3915
    None, # 0
3916
    (1, TType.I32, 'category', None, None, ), # 1
3917
  )
3918
 
3919
  def __init__(self, category=None,):
3920
    self.category = category
3921
 
3922
  def read(self, iprot):
3923
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3924
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3925
      return
3926
    iprot.readStructBegin()
3927
    while True:
3928
      (fname, ftype, fid) = iprot.readFieldBegin()
3929
      if ftype == TType.STOP:
3930
        break
3931
      if fid == 1:
3932
        if ftype == TType.I32:
3933
          self.category = iprot.readI32();
3934
        else:
3935
          iprot.skip(ftype)
3936
      else:
3937
        iprot.skip(ftype)
3938
      iprot.readFieldEnd()
3939
    iprot.readStructEnd()
3940
 
3941
  def write(self, oprot):
3942
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3943
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3944
      return
3945
    oprot.writeStructBegin('getPaymentsRequiringExtraProcessing_args')
3946
    if self.category is not None:
3947
      oprot.writeFieldBegin('category', TType.I32, 1)
3948
      oprot.writeI32(self.category)
3949
      oprot.writeFieldEnd()
3950
    oprot.writeFieldStop()
3951
    oprot.writeStructEnd()
3952
 
3953
  def validate(self):
3954
    return
3955
 
3956
 
3957
  def __repr__(self):
3958
    L = ['%s=%r' % (key, value)
3959
      for key, value in self.__dict__.iteritems()]
3960
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3961
 
3962
  def __eq__(self, other):
3963
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3964
 
3965
  def __ne__(self, other):
3966
    return not (self == other)
3967
 
3968
class getPaymentsRequiringExtraProcessing_result:
3969
  """
3970
  Attributes:
3971
   - success
3972
  """
3973
 
3974
  thrift_spec = (
3975
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
3976
  )
3977
 
3978
  def __init__(self, success=None,):
3979
    self.success = success
3980
 
3981
  def read(self, iprot):
3982
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3983
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3984
      return
3985
    iprot.readStructBegin()
3986
    while True:
3987
      (fname, ftype, fid) = iprot.readFieldBegin()
3988
      if ftype == TType.STOP:
3989
        break
3990
      if fid == 0:
3991
        if ftype == TType.LIST:
3992
          self.success = []
4600 varun.gupt 3993
          (_etype73, _size70) = iprot.readListBegin()
3994
          for _i74 in xrange(_size70):
3995
            _elem75 = iprot.readI64();
3996
            self.success.append(_elem75)
4008 mandeep.dh 3997
          iprot.readListEnd()
3998
        else:
3999
          iprot.skip(ftype)
4000
      else:
4001
        iprot.skip(ftype)
4002
      iprot.readFieldEnd()
4003
    iprot.readStructEnd()
4004
 
4005
  def write(self, oprot):
4006
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4007
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4008
      return
4009
    oprot.writeStructBegin('getPaymentsRequiringExtraProcessing_result')
4010
    if self.success is not None:
4011
      oprot.writeFieldBegin('success', TType.LIST, 0)
4012
      oprot.writeListBegin(TType.I64, len(self.success))
4600 varun.gupt 4013
      for iter76 in self.success:
4014
        oprot.writeI64(iter76)
4008 mandeep.dh 4015
      oprot.writeListEnd()
4016
      oprot.writeFieldEnd()
4017
    oprot.writeFieldStop()
4018
    oprot.writeStructEnd()
4019
 
4020
  def validate(self):
4021
    return
4022
 
4023
 
4024
  def __repr__(self):
4025
    L = ['%s=%r' % (key, value)
4026
      for key, value in self.__dict__.iteritems()]
4027
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4028
 
4029
  def __eq__(self, other):
4030
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4031
 
4032
  def __ne__(self, other):
4033
    return not (self == other)
4034
 
4035
class markPaymentAsProcessed_args:
4036
  """
4037
  Attributes:
4038
   - paymentId
4039
   - category
4040
  """
4041
 
4042
  thrift_spec = (
4043
    None, # 0
4044
    (1, TType.I64, 'paymentId', None, None, ), # 1
4045
    (2, TType.I32, 'category', None, None, ), # 2
4046
  )
4047
 
4048
  def __init__(self, paymentId=None, category=None,):
4049
    self.paymentId = paymentId
4050
    self.category = category
4051
 
4052
  def read(self, iprot):
4053
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4054
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4055
      return
4056
    iprot.readStructBegin()
4057
    while True:
4058
      (fname, ftype, fid) = iprot.readFieldBegin()
4059
      if ftype == TType.STOP:
4060
        break
4061
      if fid == 1:
4062
        if ftype == TType.I64:
4063
          self.paymentId = iprot.readI64();
4064
        else:
4065
          iprot.skip(ftype)
4066
      elif fid == 2:
4067
        if ftype == TType.I32:
4068
          self.category = iprot.readI32();
4069
        else:
4070
          iprot.skip(ftype)
4071
      else:
4072
        iprot.skip(ftype)
4073
      iprot.readFieldEnd()
4074
    iprot.readStructEnd()
4075
 
4076
  def write(self, oprot):
4077
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4078
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4079
      return
4080
    oprot.writeStructBegin('markPaymentAsProcessed_args')
4081
    if self.paymentId is not None:
4082
      oprot.writeFieldBegin('paymentId', TType.I64, 1)
4083
      oprot.writeI64(self.paymentId)
4084
      oprot.writeFieldEnd()
4085
    if self.category is not None:
4086
      oprot.writeFieldBegin('category', TType.I32, 2)
4087
      oprot.writeI32(self.category)
4088
      oprot.writeFieldEnd()
4089
    oprot.writeFieldStop()
4090
    oprot.writeStructEnd()
4091
 
4092
  def validate(self):
4093
    return
4094
 
4095
 
4096
  def __repr__(self):
4097
    L = ['%s=%r' % (key, value)
4098
      for key, value in self.__dict__.iteritems()]
4099
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4100
 
4101
  def __eq__(self, other):
4102
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4103
 
4104
  def __ne__(self, other):
4105
    return not (self == other)
4106
 
4107
class markPaymentAsProcessed_result:
4108
 
4109
  thrift_spec = (
4110
  )
4111
 
4112
  def read(self, iprot):
4113
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4114
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4115
      return
4116
    iprot.readStructBegin()
4117
    while True:
4118
      (fname, ftype, fid) = iprot.readFieldBegin()
4119
      if ftype == TType.STOP:
4120
        break
4121
      else:
4122
        iprot.skip(ftype)
4123
      iprot.readFieldEnd()
4124
    iprot.readStructEnd()
4125
 
4126
  def write(self, oprot):
4127
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4128
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4129
      return
4130
    oprot.writeStructBegin('markPaymentAsProcessed_result')
4131
    oprot.writeFieldStop()
4132
    oprot.writeStructEnd()
4133
 
4134
  def validate(self):
4135
    return
4136
 
4137
 
4138
  def __repr__(self):
4139
    L = ['%s=%r' % (key, value)
4140
      for key, value in self.__dict__.iteritems()]
4141
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4142
 
4143
  def __eq__(self, other):
4144
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4145
 
4146
  def __ne__(self, other):
4147
    return not (self == other)