Subversion Repositories SmartDukaan

Rev

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

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