Subversion Repositories SmartDukaan

Rev

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