Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
123 ashish 1
/**
3430 rajveer 2
 * Autogenerated by Thrift Compiler (0.7.0)
123 ashish 3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.payments;
7
 
8
import java.util.List;
9
import java.util.ArrayList;
10
import java.util.Map;
11
import java.util.HashMap;
12
import java.util.EnumMap;
13
import java.util.Set;
14
import java.util.HashSet;
15
import java.util.EnumSet;
16
import java.util.Collections;
17
import java.util.BitSet;
3430 rajveer 18
import java.nio.ByteBuffer;
123 ashish 19
import java.util.Arrays;
20
import org.slf4j.Logger;
21
import org.slf4j.LoggerFactory;
22
 
23
public class PaymentService {
24
 
3374 rajveer 25
  public interface Iface extends in.shop2020.generic.GenericService.Iface {
123 ashish 26
 
695 rajveer 27
    /**
28
     * create a new payment and return payment id, throws an exception if gateway is not active
29
     * 
30
     * @param userId
31
     * @param amount
32
     * @param gatewayId
33
     * @param txnId
6050 anupam.sin 34
     * @param isDigital
695 rajveer 35
     */
6050 anupam.sin 36
    public long createPayment(long userId, double amount, long gatewayId, long txnId, boolean isDigital) throws PaymentException, org.apache.thrift.TException;
123 ashish 37
 
695 rajveer 38
    /**
4141 chandransh 39
     * Get all payments for user. If status and gateway are null, they are ignored. Same for times as well.
695 rajveer 40
     * 
41
     * @param userId
42
     * @param fromTime
43
     * @param toTime
44
     * @param status
45
     * @param gatewayId
46
     */
3430 rajveer 47
    public List<Payment> getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException;
123 ashish 48
 
695 rajveer 49
    /**
4141 chandransh 50
     * Get all payments in the given status for the given gateway. If gatewayId is 0, then it is ignored.
695 rajveer 51
     * 
52
     * @param fromTime
53
     * @param toTime
54
     * @param status
55
     * @param gatewayId
56
     */
3430 rajveer 57
    public List<Payment> getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException;
123 ashish 58
 
695 rajveer 59
    /**
4141 chandransh 60
     * Get all payments for the given gateway which were captured between the given dates. If the gatewayId is 0, it's ignored.
695 rajveer 61
     * 
4141 chandransh 62
     * @param fromTime
63
     * @param toTime
64
     * @param gatewayId
65
     */
66
    public List<Payment> getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws PaymentException, org.apache.thrift.TException;
67
 
68
    /**
69
     * Get the gateway for the given id.
695 rajveer 70
     * 
71
     * @param id
72
     */
3430 rajveer 73
    public PaymentGateway getPaymentGateway(long id) throws PaymentException, org.apache.thrift.TException;
420 ashish 74
 
695 rajveer 75
    /**
4600 varun.gupt 76
     * Get all active Payment Gateways
77
     * 
78
     */
79
    public List<PaymentGateway> getActivePaymentGateways() throws PaymentException, org.apache.thrift.TException;
80
 
81
    /**
695 rajveer 82
     * Get a particular payment info
83
     * 
84
     * 
85
     * @param id
86
     */
3430 rajveer 87
    public Payment getPayment(long id) throws PaymentException, org.apache.thrift.TException;
420 ashish 88
 
695 rajveer 89
    /**
4600 varun.gupt 90
     * Get payments for a transaction. Will raise exception.
695 rajveer 91
     * 
92
     * 
93
     * @param txnId
94
     */
3430 rajveer 95
    public List<Payment> getPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException;
420 ashish 96
 
695 rajveer 97
    /**
4600 varun.gupt 98
     * Get successful payment for a transaction. Will raise exception.
99
     * 
100
     * 
101
     * @param txnId
102
     */
103
    public Payment getSuccessfulPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException;
104
 
105
    /**
695 rajveer 106
     * mark payment successful and store parameters
107
     * 
108
     * 
109
     * @param id
110
     * @param gatewayPaymentId
111
     * @param sessionId
112
     * @param gatewayTxnStatus
113
     * @param description
114
     * @param gatewayTxnId
115
     * @param authCode
116
     * @param referenceCode
117
     * @param errorCode
118
     * @param status
1119 rajveer 119
     * @param gatewayTxnDate
695 rajveer 120
     * @param attributes
121
     */
3430 rajveer 122
    public boolean updatePaymentDetails(long id, String gatewayPaymentId, String sessionId, String gatewayTxnStatus, String description, String gatewayTxnId, String authCode, String referenceCode, String errorCode, PaymentStatus status, String gatewayTxnDate, List<Attribute> attributes) throws PaymentException, org.apache.thrift.TException;
695 rajveer 123
 
1629 ankur.sing 124
    /**
1731 ankur.sing 125
     * Returns the minimum and maximum amounts among successful payments.
126
     * List contains two double values, first minimum and second maximum amount.
1629 ankur.sing 127
     */
3430 rajveer 128
    public List<Double> getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException;
1629 ankur.sing 129
 
2462 chandransh 130
    /**
131
     * Initialize the payment pipe for a HDFC payment. The URL the user should be redirected to is returned.
132
     * In case of any processing error, an exception is raised.
133
     * 
134
     * @param merchantPaymentId
135
     */
3430 rajveer 136
    public String initializeHdfcPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException;
2462 chandransh 137
 
2690 chandransh 138
    /**
6050 anupam.sin 139
     * Initialize the payment pipe for a HDFC payment in case of a digital order. The URL the user should be redirected to is returned.
6228 anupam.sin 140
     * In case of any processing error, an exception is raised. The phone is a madatory field and is required in case of dth payments.
6050 anupam.sin 141
     * 
142
     * @param merchantPaymentId
143
     * @param rechargeOrderId
6228 anupam.sin 144
     * @param phone
6050 anupam.sin 145
     */
6228 anupam.sin 146
    public String doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone) throws PaymentException, org.apache.thrift.TException;
6050 anupam.sin 147
 
148
    /**
3616 chandransh 149
     * Initialize the payment pipe for a HDFC EMI payment. The URL the user should be redirected to is returned.
150
     * In case of any processing error, an exception is raised.
151
     * 
152
     * @param merchantPaymentId
153
     */
154
    public String initializeHdfcEmiPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException;
155
 
156
    /**
2690 chandransh 157
     * Create a refund of the given amount corresponding to the given order to be processed through the same
158
     * payment gateway which processed the payment for the corresponding transaction.
159
     * Returns the id of the newly created Refund.
160
     * 
161
     * @param orderId
162
     * @param merchantTxnId
163
     * @param amount
164
     */
3430 rajveer 165
    public long createRefund(long orderId, long merchantTxnId, double amount) throws PaymentException, org.apache.thrift.TException;
2690 chandransh 166
 
3010 chandransh 167
    /**
168
     * Capture the payment for the given merchant transaction id. It processes the last payment for the given
6503 rajveer 169
     * transaction. If the capture attempt failed, the payment is marked as failed. PaymentException with error
170
     * code 104 is	thrown in case no payments are found for the transaction id passed. PaymentException is also
171
     * thrown with error code 106 in case capture was not possible due to connection
172
     * issue.
3010 chandransh 173
     * 
174
     * @param merchantTxnId
175
     */
3430 rajveer 176
    public boolean capturePayment(long merchantTxnId) throws PaymentException, org.apache.thrift.TException;
3010 chandransh 177
 
3956 chandransh 178
    /**
6503 rajveer 179
     * Refund the payment for the given merchant transaction id. It processes the last payment for the given
180
     * transaction. If refund will be failed nothing will be updated in database.
6486 rajveer 181
     * 
182
     * @param merchantTxnId
183
     * @param amount
184
     * @param isDigital
185
     */
186
    public boolean refundPayment(long merchantTxnId, double amount, boolean isDigital) throws PaymentException, org.apache.thrift.TException;
187
 
188
    /**
3956 chandransh 189
     * Adds the given amount to the captured amount of a COD payment.
190
     * Updates the captured amount for the corresponding payment and marks it as PARTIALLY CAPTURED.
191
     * If the captured amount becomes equal to total amount, then the payment status is set as SUCCESS.
192
     * Also sets the name of the entity which transferred the money, the date on which it was transferred
193
     * and the corresponding transaction id.
194
     * 
195
     * Returns false if the payment couldn't be captured.
196
     * Throws exception if no such payment could be found or if the captured amount will exceed the total amount after capturing.
197
     * 
198
     * @param merchantTxnId
199
     * @param amount
200
     * @param xferBy
201
     * @param xferTxnId
202
     * @param xferDate
203
     */
204
    public boolean partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws PaymentException, org.apache.thrift.TException;
205
 
4008 mandeep.dh 206
    /**
207
     * Returns the list of payments that require some extra processing and
208
     * which belong to a particular category. This is currently used by CRM
209
     * application.
210
     * 
211
     * @param category
212
     */
213
    public List<Long> getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException;
214
 
215
    /**
216
     * Marks a particular payment as processed for a particular cateogory.
217
     * It essentially deletes the payment if it is processed for a particular
218
     * category. This is currently used by CRM application.
219
     * 
220
     * @param paymentId
221
     * @param category
222
     */
223
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException;
224
 
123 ashish 225
  }
226
 
3430 rajveer 227
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
228
 
6050 anupam.sin 229
    public void createPayment(long userId, double amount, long gatewayId, long txnId, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPayment_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 230
 
231
    public void getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentsForUser_call> resultHandler) throws org.apache.thrift.TException;
232
 
233
    public void getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPayments_call> resultHandler) throws org.apache.thrift.TException;
234
 
4141 chandransh 235
    public void getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentsByCapturedDate_call> resultHandler) throws org.apache.thrift.TException;
236
 
3430 rajveer 237
    public void getPaymentGateway(long id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentGateway_call> resultHandler) throws org.apache.thrift.TException;
238
 
4600 varun.gupt 239
    public void getActivePaymentGateways(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getActivePaymentGateways_call> resultHandler) throws org.apache.thrift.TException;
240
 
3430 rajveer 241
    public void getPayment(long id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPayment_call> resultHandler) throws org.apache.thrift.TException;
242
 
243
    public void getPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException;
244
 
4600 varun.gupt 245
    public void getSuccessfulPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSuccessfulPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException;
246
 
3430 rajveer 247
    public void updatePaymentDetails(long id, String gatewayPaymentId, String sessionId, String gatewayTxnStatus, String description, String gatewayTxnId, String authCode, String referenceCode, String errorCode, PaymentStatus status, String gatewayTxnDate, List<Attribute> attributes, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updatePaymentDetails_call> resultHandler) throws org.apache.thrift.TException;
248
 
249
    public void getSuccessfulPaymentsAmountRange(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSuccessfulPaymentsAmountRange_call> resultHandler) throws org.apache.thrift.TException;
250
 
251
    public void initializeHdfcPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.initializeHdfcPayment_call> resultHandler) throws org.apache.thrift.TException;
252
 
6228 anupam.sin 253
    public void doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.doHdfcPaymentForDigitalOrder_call> resultHandler) throws org.apache.thrift.TException;
6050 anupam.sin 254
 
3616 chandransh 255
    public void initializeHdfcEmiPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.initializeHdfcEmiPayment_call> resultHandler) throws org.apache.thrift.TException;
256
 
3430 rajveer 257
    public void createRefund(long orderId, long merchantTxnId, double amount, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createRefund_call> resultHandler) throws org.apache.thrift.TException;
258
 
259
    public void capturePayment(long merchantTxnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.capturePayment_call> resultHandler) throws org.apache.thrift.TException;
260
 
6486 rajveer 261
    public void refundPayment(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.refundPayment_call> resultHandler) throws org.apache.thrift.TException;
262
 
3956 chandransh 263
    public void partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.partiallyCapturePayment_call> resultHandler) throws org.apache.thrift.TException;
264
 
4008 mandeep.dh 265
    public void getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentsRequiringExtraProcessing_call> resultHandler) throws org.apache.thrift.TException;
266
 
267
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.markPaymentAsProcessed_call> resultHandler) throws org.apache.thrift.TException;
268
 
3430 rajveer 269
  }
270
 
3374 rajveer 271
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
3430 rajveer 272
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
273
      public Factory() {}
274
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
275
        return new Client(prot);
276
      }
277
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
278
        return new Client(iprot, oprot);
279
      }
280
    }
281
 
282
    public Client(org.apache.thrift.protocol.TProtocol prot)
123 ashish 283
    {
3430 rajveer 284
      super(prot, prot);
123 ashish 285
    }
286
 
3430 rajveer 287
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
3374 rajveer 288
      super(iprot, oprot);
123 ashish 289
    }
290
 
6050 anupam.sin 291
    public long createPayment(long userId, double amount, long gatewayId, long txnId, boolean isDigital) throws PaymentException, org.apache.thrift.TException
123 ashish 292
    {
6050 anupam.sin 293
      send_createPayment(userId, amount, gatewayId, txnId, isDigital);
123 ashish 294
      return recv_createPayment();
295
    }
296
 
6050 anupam.sin 297
    public void send_createPayment(long userId, double amount, long gatewayId, long txnId, boolean isDigital) throws org.apache.thrift.TException
123 ashish 298
    {
299
      createPayment_args args = new createPayment_args();
3430 rajveer 300
      args.setUserId(userId);
301
      args.setAmount(amount);
302
      args.setGatewayId(gatewayId);
303
      args.setTxnId(txnId);
6050 anupam.sin 304
      args.setIsDigital(isDigital);
3430 rajveer 305
      sendBase("createPayment", args);
123 ashish 306
    }
307
 
3430 rajveer 308
    public long recv_createPayment() throws PaymentException, org.apache.thrift.TException
123 ashish 309
    {
310
      createPayment_result result = new createPayment_result();
3430 rajveer 311
      receiveBase(result, "createPayment");
123 ashish 312
      if (result.isSetSuccess()) {
313
        return result.success;
314
      }
315
      if (result.pe != null) {
316
        throw result.pe;
317
      }
3430 rajveer 318
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createPayment failed: unknown result");
123 ashish 319
    }
320
 
3430 rajveer 321
    public List<Payment> getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException
123 ashish 322
    {
695 rajveer 323
      send_getPaymentsForUser(userId, fromTime, toTime, status, gatewayId);
123 ashish 324
      return recv_getPaymentsForUser();
325
    }
326
 
3430 rajveer 327
    public void send_getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws org.apache.thrift.TException
123 ashish 328
    {
329
      getPaymentsForUser_args args = new getPaymentsForUser_args();
3430 rajveer 330
      args.setUserId(userId);
331
      args.setFromTime(fromTime);
332
      args.setToTime(toTime);
333
      args.setStatus(status);
334
      args.setGatewayId(gatewayId);
335
      sendBase("getPaymentsForUser", args);
123 ashish 336
    }
337
 
3430 rajveer 338
    public List<Payment> recv_getPaymentsForUser() throws PaymentException, org.apache.thrift.TException
123 ashish 339
    {
340
      getPaymentsForUser_result result = new getPaymentsForUser_result();
3430 rajveer 341
      receiveBase(result, "getPaymentsForUser");
123 ashish 342
      if (result.isSetSuccess()) {
343
        return result.success;
344
      }
345
      if (result.pe != null) {
346
        throw result.pe;
347
      }
3430 rajveer 348
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsForUser failed: unknown result");
123 ashish 349
    }
350
 
3430 rajveer 351
    public List<Payment> getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException
123 ashish 352
    {
695 rajveer 353
      send_getPayments(fromTime, toTime, status, gatewayId);
123 ashish 354
      return recv_getPayments();
355
    }
356
 
3430 rajveer 357
    public void send_getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws org.apache.thrift.TException
123 ashish 358
    {
359
      getPayments_args args = new getPayments_args();
3430 rajveer 360
      args.setFromTime(fromTime);
361
      args.setToTime(toTime);
362
      args.setStatus(status);
363
      args.setGatewayId(gatewayId);
364
      sendBase("getPayments", args);
123 ashish 365
    }
366
 
3430 rajveer 367
    public List<Payment> recv_getPayments() throws PaymentException, org.apache.thrift.TException
123 ashish 368
    {
369
      getPayments_result result = new getPayments_result();
3430 rajveer 370
      receiveBase(result, "getPayments");
123 ashish 371
      if (result.isSetSuccess()) {
372
        return result.success;
373
      }
374
      if (result.pe != null) {
375
        throw result.pe;
376
      }
3430 rajveer 377
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPayments failed: unknown result");
123 ashish 378
    }
379
 
4141 chandransh 380
    public List<Payment> getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws PaymentException, org.apache.thrift.TException
381
    {
382
      send_getPaymentsByCapturedDate(fromTime, toTime, gatewayId);
383
      return recv_getPaymentsByCapturedDate();
384
    }
385
 
386
    public void send_getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws org.apache.thrift.TException
387
    {
388
      getPaymentsByCapturedDate_args args = new getPaymentsByCapturedDate_args();
389
      args.setFromTime(fromTime);
390
      args.setToTime(toTime);
391
      args.setGatewayId(gatewayId);
392
      sendBase("getPaymentsByCapturedDate", args);
393
    }
394
 
395
    public List<Payment> recv_getPaymentsByCapturedDate() throws PaymentException, org.apache.thrift.TException
396
    {
397
      getPaymentsByCapturedDate_result result = new getPaymentsByCapturedDate_result();
398
      receiveBase(result, "getPaymentsByCapturedDate");
399
      if (result.isSetSuccess()) {
400
        return result.success;
401
      }
402
      if (result.pe != null) {
403
        throw result.pe;
404
      }
405
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsByCapturedDate failed: unknown result");
406
    }
407
 
3430 rajveer 408
    public PaymentGateway getPaymentGateway(long id) throws PaymentException, org.apache.thrift.TException
420 ashish 409
    {
410
      send_getPaymentGateway(id);
411
      return recv_getPaymentGateway();
412
    }
413
 
3430 rajveer 414
    public void send_getPaymentGateway(long id) throws org.apache.thrift.TException
420 ashish 415
    {
416
      getPaymentGateway_args args = new getPaymentGateway_args();
3430 rajveer 417
      args.setId(id);
418
      sendBase("getPaymentGateway", args);
420 ashish 419
    }
420
 
3430 rajveer 421
    public PaymentGateway recv_getPaymentGateway() throws PaymentException, org.apache.thrift.TException
420 ashish 422
    {
423
      getPaymentGateway_result result = new getPaymentGateway_result();
3430 rajveer 424
      receiveBase(result, "getPaymentGateway");
420 ashish 425
      if (result.isSetSuccess()) {
426
        return result.success;
427
      }
428
      if (result.pe != null) {
429
        throw result.pe;
430
      }
3430 rajveer 431
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentGateway failed: unknown result");
420 ashish 432
    }
433
 
4600 varun.gupt 434
    public List<PaymentGateway> getActivePaymentGateways() throws PaymentException, org.apache.thrift.TException
435
    {
436
      send_getActivePaymentGateways();
437
      return recv_getActivePaymentGateways();
438
    }
439
 
440
    public void send_getActivePaymentGateways() throws org.apache.thrift.TException
441
    {
442
      getActivePaymentGateways_args args = new getActivePaymentGateways_args();
443
      sendBase("getActivePaymentGateways", args);
444
    }
445
 
446
    public List<PaymentGateway> recv_getActivePaymentGateways() throws PaymentException, org.apache.thrift.TException
447
    {
448
      getActivePaymentGateways_result result = new getActivePaymentGateways_result();
449
      receiveBase(result, "getActivePaymentGateways");
450
      if (result.isSetSuccess()) {
451
        return result.success;
452
      }
453
      if (result.pe != null) {
454
        throw result.pe;
455
      }
456
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getActivePaymentGateways failed: unknown result");
457
    }
458
 
3430 rajveer 459
    public Payment getPayment(long id) throws PaymentException, org.apache.thrift.TException
420 ashish 460
    {
695 rajveer 461
      send_getPayment(id);
462
      return recv_getPayment();
420 ashish 463
    }
464
 
3430 rajveer 465
    public void send_getPayment(long id) throws org.apache.thrift.TException
420 ashish 466
    {
695 rajveer 467
      getPayment_args args = new getPayment_args();
3430 rajveer 468
      args.setId(id);
469
      sendBase("getPayment", args);
420 ashish 470
    }
471
 
3430 rajveer 472
    public Payment recv_getPayment() throws PaymentException, org.apache.thrift.TException
420 ashish 473
    {
695 rajveer 474
      getPayment_result result = new getPayment_result();
3430 rajveer 475
      receiveBase(result, "getPayment");
695 rajveer 476
      if (result.isSetSuccess()) {
477
        return result.success;
478
      }
420 ashish 479
      if (result.pe != null) {
480
        throw result.pe;
481
      }
3430 rajveer 482
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPayment failed: unknown result");
420 ashish 483
    }
484
 
3430 rajveer 485
    public List<Payment> getPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException
420 ashish 486
    {
695 rajveer 487
      send_getPaymentForTxnId(txnId);
488
      return recv_getPaymentForTxnId();
420 ashish 489
    }
490
 
3430 rajveer 491
    public void send_getPaymentForTxnId(long txnId) throws org.apache.thrift.TException
420 ashish 492
    {
695 rajveer 493
      getPaymentForTxnId_args args = new getPaymentForTxnId_args();
3430 rajveer 494
      args.setTxnId(txnId);
495
      sendBase("getPaymentForTxnId", args);
420 ashish 496
    }
497
 
3430 rajveer 498
    public List<Payment> recv_getPaymentForTxnId() throws PaymentException, org.apache.thrift.TException
420 ashish 499
    {
695 rajveer 500
      getPaymentForTxnId_result result = new getPaymentForTxnId_result();
3430 rajveer 501
      receiveBase(result, "getPaymentForTxnId");
420 ashish 502
      if (result.isSetSuccess()) {
503
        return result.success;
504
      }
505
      if (result.pe != null) {
506
        throw result.pe;
507
      }
3430 rajveer 508
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentForTxnId failed: unknown result");
420 ashish 509
    }
510
 
4600 varun.gupt 511
    public Payment getSuccessfulPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException
512
    {
513
      send_getSuccessfulPaymentForTxnId(txnId);
514
      return recv_getSuccessfulPaymentForTxnId();
515
    }
516
 
517
    public void send_getSuccessfulPaymentForTxnId(long txnId) throws org.apache.thrift.TException
518
    {
519
      getSuccessfulPaymentForTxnId_args args = new getSuccessfulPaymentForTxnId_args();
520
      args.setTxnId(txnId);
521
      sendBase("getSuccessfulPaymentForTxnId", args);
522
    }
523
 
524
    public Payment recv_getSuccessfulPaymentForTxnId() throws PaymentException, org.apache.thrift.TException
525
    {
526
      getSuccessfulPaymentForTxnId_result result = new getSuccessfulPaymentForTxnId_result();
527
      receiveBase(result, "getSuccessfulPaymentForTxnId");
528
      if (result.isSetSuccess()) {
529
        return result.success;
530
      }
531
      if (result.pe != null) {
532
        throw result.pe;
533
      }
534
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getSuccessfulPaymentForTxnId failed: unknown result");
535
    }
536
 
3430 rajveer 537
    public boolean updatePaymentDetails(long id, String gatewayPaymentId, String sessionId, String gatewayTxnStatus, String description, String gatewayTxnId, String authCode, String referenceCode, String errorCode, PaymentStatus status, String gatewayTxnDate, List<Attribute> attributes) throws PaymentException, org.apache.thrift.TException
420 ashish 538
    {
1119 rajveer 539
      send_updatePaymentDetails(id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes);
695 rajveer 540
      return recv_updatePaymentDetails();
420 ashish 541
    }
542
 
3430 rajveer 543
    public void send_updatePaymentDetails(long id, String gatewayPaymentId, String sessionId, String gatewayTxnStatus, String description, String gatewayTxnId, String authCode, String referenceCode, String errorCode, PaymentStatus status, String gatewayTxnDate, List<Attribute> attributes) throws org.apache.thrift.TException
420 ashish 544
    {
695 rajveer 545
      updatePaymentDetails_args args = new updatePaymentDetails_args();
3430 rajveer 546
      args.setId(id);
547
      args.setGatewayPaymentId(gatewayPaymentId);
548
      args.setSessionId(sessionId);
549
      args.setGatewayTxnStatus(gatewayTxnStatus);
550
      args.setDescription(description);
551
      args.setGatewayTxnId(gatewayTxnId);
552
      args.setAuthCode(authCode);
553
      args.setReferenceCode(referenceCode);
554
      args.setErrorCode(errorCode);
555
      args.setStatus(status);
556
      args.setGatewayTxnDate(gatewayTxnDate);
557
      args.setAttributes(attributes);
558
      sendBase("updatePaymentDetails", args);
420 ashish 559
    }
560
 
3430 rajveer 561
    public boolean recv_updatePaymentDetails() throws PaymentException, org.apache.thrift.TException
420 ashish 562
    {
695 rajveer 563
      updatePaymentDetails_result result = new updatePaymentDetails_result();
3430 rajveer 564
      receiveBase(result, "updatePaymentDetails");
695 rajveer 565
      if (result.isSetSuccess()) {
566
        return result.success;
567
      }
420 ashish 568
      if (result.pe != null) {
569
        throw result.pe;
570
      }
3430 rajveer 571
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "updatePaymentDetails failed: unknown result");
420 ashish 572
    }
573
 
3430 rajveer 574
    public List<Double> getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 575
    {
1731 ankur.sing 576
      send_getSuccessfulPaymentsAmountRange();
577
      return recv_getSuccessfulPaymentsAmountRange();
1629 ankur.sing 578
    }
579
 
3430 rajveer 580
    public void send_getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 581
    {
1731 ankur.sing 582
      getSuccessfulPaymentsAmountRange_args args = new getSuccessfulPaymentsAmountRange_args();
3430 rajveer 583
      sendBase("getSuccessfulPaymentsAmountRange", args);
1629 ankur.sing 584
    }
585
 
3430 rajveer 586
    public List<Double> recv_getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 587
    {
1731 ankur.sing 588
      getSuccessfulPaymentsAmountRange_result result = new getSuccessfulPaymentsAmountRange_result();
3430 rajveer 589
      receiveBase(result, "getSuccessfulPaymentsAmountRange");
1629 ankur.sing 590
      if (result.isSetSuccess()) {
591
        return result.success;
592
      }
3430 rajveer 593
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getSuccessfulPaymentsAmountRange failed: unknown result");
1629 ankur.sing 594
    }
595
 
3430 rajveer 596
    public String initializeHdfcPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException
2462 chandransh 597
    {
598
      send_initializeHdfcPayment(merchantPaymentId);
599
      return recv_initializeHdfcPayment();
600
    }
601
 
3430 rajveer 602
    public void send_initializeHdfcPayment(long merchantPaymentId) throws org.apache.thrift.TException
2462 chandransh 603
    {
604
      initializeHdfcPayment_args args = new initializeHdfcPayment_args();
3430 rajveer 605
      args.setMerchantPaymentId(merchantPaymentId);
606
      sendBase("initializeHdfcPayment", args);
2462 chandransh 607
    }
608
 
3430 rajveer 609
    public String recv_initializeHdfcPayment() throws PaymentException, org.apache.thrift.TException
2462 chandransh 610
    {
611
      initializeHdfcPayment_result result = new initializeHdfcPayment_result();
3430 rajveer 612
      receiveBase(result, "initializeHdfcPayment");
2462 chandransh 613
      if (result.isSetSuccess()) {
614
        return result.success;
615
      }
616
      if (result.pe != null) {
617
        throw result.pe;
618
      }
3430 rajveer 619
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "initializeHdfcPayment failed: unknown result");
2462 chandransh 620
    }
621
 
6228 anupam.sin 622
    public String doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone) throws PaymentException, org.apache.thrift.TException
6050 anupam.sin 623
    {
6228 anupam.sin 624
      send_doHdfcPaymentForDigitalOrder(merchantPaymentId, rechargeOrderId, phone);
6050 anupam.sin 625
      return recv_doHdfcPaymentForDigitalOrder();
626
    }
627
 
6228 anupam.sin 628
    public void send_doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone) throws org.apache.thrift.TException
6050 anupam.sin 629
    {
630
      doHdfcPaymentForDigitalOrder_args args = new doHdfcPaymentForDigitalOrder_args();
631
      args.setMerchantPaymentId(merchantPaymentId);
632
      args.setRechargeOrderId(rechargeOrderId);
6228 anupam.sin 633
      args.setPhone(phone);
6050 anupam.sin 634
      sendBase("doHdfcPaymentForDigitalOrder", args);
635
    }
636
 
637
    public String recv_doHdfcPaymentForDigitalOrder() throws PaymentException, org.apache.thrift.TException
638
    {
639
      doHdfcPaymentForDigitalOrder_result result = new doHdfcPaymentForDigitalOrder_result();
640
      receiveBase(result, "doHdfcPaymentForDigitalOrder");
641
      if (result.isSetSuccess()) {
642
        return result.success;
643
      }
644
      if (result.pe != null) {
645
        throw result.pe;
646
      }
647
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "doHdfcPaymentForDigitalOrder failed: unknown result");
648
    }
649
 
3616 chandransh 650
    public String initializeHdfcEmiPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException
651
    {
652
      send_initializeHdfcEmiPayment(merchantPaymentId);
653
      return recv_initializeHdfcEmiPayment();
654
    }
655
 
656
    public void send_initializeHdfcEmiPayment(long merchantPaymentId) throws org.apache.thrift.TException
657
    {
658
      initializeHdfcEmiPayment_args args = new initializeHdfcEmiPayment_args();
659
      args.setMerchantPaymentId(merchantPaymentId);
660
      sendBase("initializeHdfcEmiPayment", args);
661
    }
662
 
663
    public String recv_initializeHdfcEmiPayment() throws PaymentException, org.apache.thrift.TException
664
    {
665
      initializeHdfcEmiPayment_result result = new initializeHdfcEmiPayment_result();
666
      receiveBase(result, "initializeHdfcEmiPayment");
667
      if (result.isSetSuccess()) {
668
        return result.success;
669
      }
670
      if (result.pe != null) {
671
        throw result.pe;
672
      }
673
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "initializeHdfcEmiPayment failed: unknown result");
674
    }
675
 
3430 rajveer 676
    public long createRefund(long orderId, long merchantTxnId, double amount) throws PaymentException, org.apache.thrift.TException
2690 chandransh 677
    {
678
      send_createRefund(orderId, merchantTxnId, amount);
679
      return recv_createRefund();
680
    }
681
 
3430 rajveer 682
    public void send_createRefund(long orderId, long merchantTxnId, double amount) throws org.apache.thrift.TException
2690 chandransh 683
    {
684
      createRefund_args args = new createRefund_args();
3430 rajveer 685
      args.setOrderId(orderId);
686
      args.setMerchantTxnId(merchantTxnId);
687
      args.setAmount(amount);
688
      sendBase("createRefund", args);
2690 chandransh 689
    }
690
 
3430 rajveer 691
    public long recv_createRefund() throws PaymentException, org.apache.thrift.TException
2690 chandransh 692
    {
693
      createRefund_result result = new createRefund_result();
3430 rajveer 694
      receiveBase(result, "createRefund");
2690 chandransh 695
      if (result.isSetSuccess()) {
696
        return result.success;
697
      }
698
      if (result.pe != null) {
699
        throw result.pe;
700
      }
3430 rajveer 701
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createRefund failed: unknown result");
2690 chandransh 702
    }
703
 
3430 rajveer 704
    public boolean capturePayment(long merchantTxnId) throws PaymentException, org.apache.thrift.TException
3010 chandransh 705
    {
706
      send_capturePayment(merchantTxnId);
707
      return recv_capturePayment();
708
    }
709
 
3430 rajveer 710
    public void send_capturePayment(long merchantTxnId) throws org.apache.thrift.TException
3010 chandransh 711
    {
712
      capturePayment_args args = new capturePayment_args();
3430 rajveer 713
      args.setMerchantTxnId(merchantTxnId);
714
      sendBase("capturePayment", args);
3010 chandransh 715
    }
716
 
3430 rajveer 717
    public boolean recv_capturePayment() throws PaymentException, org.apache.thrift.TException
3010 chandransh 718
    {
719
      capturePayment_result result = new capturePayment_result();
3430 rajveer 720
      receiveBase(result, "capturePayment");
3010 chandransh 721
      if (result.isSetSuccess()) {
722
        return result.success;
723
      }
724
      if (result.pe != null) {
725
        throw result.pe;
726
      }
3430 rajveer 727
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "capturePayment failed: unknown result");
3010 chandransh 728
    }
729
 
6486 rajveer 730
    public boolean refundPayment(long merchantTxnId, double amount, boolean isDigital) throws PaymentException, org.apache.thrift.TException
731
    {
732
      send_refundPayment(merchantTxnId, amount, isDigital);
733
      return recv_refundPayment();
734
    }
735
 
736
    public void send_refundPayment(long merchantTxnId, double amount, boolean isDigital) throws org.apache.thrift.TException
737
    {
738
      refundPayment_args args = new refundPayment_args();
739
      args.setMerchantTxnId(merchantTxnId);
740
      args.setAmount(amount);
741
      args.setIsDigital(isDigital);
742
      sendBase("refundPayment", args);
743
    }
744
 
745
    public boolean recv_refundPayment() throws PaymentException, org.apache.thrift.TException
746
    {
747
      refundPayment_result result = new refundPayment_result();
748
      receiveBase(result, "refundPayment");
749
      if (result.isSetSuccess()) {
750
        return result.success;
751
      }
752
      if (result.pe != null) {
753
        throw result.pe;
754
      }
755
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "refundPayment failed: unknown result");
756
    }
757
 
3956 chandransh 758
    public boolean partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws PaymentException, org.apache.thrift.TException
759
    {
760
      send_partiallyCapturePayment(merchantTxnId, amount, xferBy, xferTxnId, xferDate);
761
      return recv_partiallyCapturePayment();
762
    }
763
 
764
    public void send_partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws org.apache.thrift.TException
765
    {
766
      partiallyCapturePayment_args args = new partiallyCapturePayment_args();
767
      args.setMerchantTxnId(merchantTxnId);
768
      args.setAmount(amount);
769
      args.setXferBy(xferBy);
770
      args.setXferTxnId(xferTxnId);
771
      args.setXferDate(xferDate);
772
      sendBase("partiallyCapturePayment", args);
773
    }
774
 
775
    public boolean recv_partiallyCapturePayment() throws PaymentException, org.apache.thrift.TException
776
    {
777
      partiallyCapturePayment_result result = new partiallyCapturePayment_result();
778
      receiveBase(result, "partiallyCapturePayment");
779
      if (result.isSetSuccess()) {
780
        return result.success;
781
      }
782
      if (result.pe != null) {
783
        throw result.pe;
784
      }
785
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "partiallyCapturePayment failed: unknown result");
786
    }
787
 
4008 mandeep.dh 788
    public List<Long> getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException
789
    {
790
      send_getPaymentsRequiringExtraProcessing(category);
791
      return recv_getPaymentsRequiringExtraProcessing();
792
    }
793
 
794
    public void send_getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException
795
    {
796
      getPaymentsRequiringExtraProcessing_args args = new getPaymentsRequiringExtraProcessing_args();
797
      args.setCategory(category);
798
      sendBase("getPaymentsRequiringExtraProcessing", args);
799
    }
800
 
801
    public List<Long> recv_getPaymentsRequiringExtraProcessing() throws org.apache.thrift.TException
802
    {
803
      getPaymentsRequiringExtraProcessing_result result = new getPaymentsRequiringExtraProcessing_result();
804
      receiveBase(result, "getPaymentsRequiringExtraProcessing");
805
      if (result.isSetSuccess()) {
806
        return result.success;
807
      }
808
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsRequiringExtraProcessing failed: unknown result");
809
    }
810
 
811
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException
812
    {
813
      send_markPaymentAsProcessed(paymentId, category);
814
      recv_markPaymentAsProcessed();
815
    }
816
 
817
    public void send_markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException
818
    {
819
      markPaymentAsProcessed_args args = new markPaymentAsProcessed_args();
820
      args.setPaymentId(paymentId);
821
      args.setCategory(category);
822
      sendBase("markPaymentAsProcessed", args);
823
    }
824
 
825
    public void recv_markPaymentAsProcessed() throws org.apache.thrift.TException
826
    {
827
      markPaymentAsProcessed_result result = new markPaymentAsProcessed_result();
828
      receiveBase(result, "markPaymentAsProcessed");
829
      return;
830
    }
831
 
123 ashish 832
  }
3430 rajveer 833
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
834
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
835
      private org.apache.thrift.async.TAsyncClientManager clientManager;
836
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
837
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
838
        this.clientManager = clientManager;
839
        this.protocolFactory = protocolFactory;
840
      }
841
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
842
        return new AsyncClient(protocolFactory, clientManager, transport);
843
      }
123 ashish 844
    }
845
 
3430 rajveer 846
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
847
      super(protocolFactory, clientManager, transport);
848
    }
123 ashish 849
 
6050 anupam.sin 850
    public void createPayment(long userId, double amount, long gatewayId, long txnId, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<createPayment_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 851
      checkReady();
6050 anupam.sin 852
      createPayment_call method_call = new createPayment_call(userId, amount, gatewayId, txnId, isDigital, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 853
      this.___currentMethod = method_call;
854
      ___manager.call(method_call);
855
    }
856
 
857
    public static class createPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
858
      private long userId;
859
      private double amount;
860
      private long gatewayId;
861
      private long txnId;
6050 anupam.sin 862
      private boolean isDigital;
863
      public createPayment_call(long userId, double amount, long gatewayId, long txnId, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<createPayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
3430 rajveer 864
        super(client, protocolFactory, transport, resultHandler, false);
865
        this.userId = userId;
866
        this.amount = amount;
867
        this.gatewayId = gatewayId;
868
        this.txnId = txnId;
6050 anupam.sin 869
        this.isDigital = isDigital;
123 ashish 870
      }
3430 rajveer 871
 
872
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
873
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
874
        createPayment_args args = new createPayment_args();
875
        args.setUserId(userId);
876
        args.setAmount(amount);
877
        args.setGatewayId(gatewayId);
878
        args.setTxnId(txnId);
6050 anupam.sin 879
        args.setIsDigital(isDigital);
3430 rajveer 880
        args.write(prot);
881
        prot.writeMessageEnd();
882
      }
883
 
884
      public long getResult() throws PaymentException, org.apache.thrift.TException {
885
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
886
          throw new IllegalStateException("Method call not finished!");
887
        }
888
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
889
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
890
        return (new Client(prot)).recv_createPayment();
891
      }
123 ashish 892
    }
893
 
3430 rajveer 894
    public void getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPaymentsForUser_call> resultHandler) throws org.apache.thrift.TException {
895
      checkReady();
896
      getPaymentsForUser_call method_call = new getPaymentsForUser_call(userId, fromTime, toTime, status, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
897
      this.___currentMethod = method_call;
898
      ___manager.call(method_call);
899
    }
900
 
901
    public static class getPaymentsForUser_call extends org.apache.thrift.async.TAsyncMethodCall {
902
      private long userId;
903
      private long fromTime;
904
      private long toTime;
905
      private PaymentStatus status;
906
      private long gatewayId;
907
      public getPaymentsForUser_call(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPaymentsForUser_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
908
        super(client, protocolFactory, transport, resultHandler, false);
909
        this.userId = userId;
910
        this.fromTime = fromTime;
911
        this.toTime = toTime;
912
        this.status = status;
913
        this.gatewayId = gatewayId;
914
      }
915
 
916
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
917
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsForUser", org.apache.thrift.protocol.TMessageType.CALL, 0));
918
        getPaymentsForUser_args args = new getPaymentsForUser_args();
919
        args.setUserId(userId);
920
        args.setFromTime(fromTime);
921
        args.setToTime(toTime);
922
        args.setStatus(status);
923
        args.setGatewayId(gatewayId);
924
        args.write(prot);
925
        prot.writeMessageEnd();
926
      }
927
 
928
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
929
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
930
          throw new IllegalStateException("Method call not finished!");
931
        }
932
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
933
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
934
        return (new Client(prot)).recv_getPaymentsForUser();
935
      }
936
    }
937
 
938
    public void getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPayments_call> resultHandler) throws org.apache.thrift.TException {
939
      checkReady();
940
      getPayments_call method_call = new getPayments_call(fromTime, toTime, status, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
941
      this.___currentMethod = method_call;
942
      ___manager.call(method_call);
943
    }
944
 
945
    public static class getPayments_call extends org.apache.thrift.async.TAsyncMethodCall {
946
      private long fromTime;
947
      private long toTime;
948
      private PaymentStatus status;
949
      private long gatewayId;
950
      public getPayments_call(long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPayments_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
951
        super(client, protocolFactory, transport, resultHandler, false);
952
        this.fromTime = fromTime;
953
        this.toTime = toTime;
954
        this.status = status;
955
        this.gatewayId = gatewayId;
956
      }
957
 
958
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
959
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPayments", org.apache.thrift.protocol.TMessageType.CALL, 0));
960
        getPayments_args args = new getPayments_args();
961
        args.setFromTime(fromTime);
962
        args.setToTime(toTime);
963
        args.setStatus(status);
964
        args.setGatewayId(gatewayId);
965
        args.write(prot);
966
        prot.writeMessageEnd();
967
      }
968
 
969
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
970
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
971
          throw new IllegalStateException("Method call not finished!");
972
        }
973
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
974
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
975
        return (new Client(prot)).recv_getPayments();
976
      }
977
    }
978
 
4141 chandransh 979
    public void getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPaymentsByCapturedDate_call> resultHandler) throws org.apache.thrift.TException {
980
      checkReady();
981
      getPaymentsByCapturedDate_call method_call = new getPaymentsByCapturedDate_call(fromTime, toTime, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
982
      this.___currentMethod = method_call;
983
      ___manager.call(method_call);
984
    }
985
 
986
    public static class getPaymentsByCapturedDate_call extends org.apache.thrift.async.TAsyncMethodCall {
987
      private long fromTime;
988
      private long toTime;
989
      private long gatewayId;
990
      public getPaymentsByCapturedDate_call(long fromTime, long toTime, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPaymentsByCapturedDate_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
991
        super(client, protocolFactory, transport, resultHandler, false);
992
        this.fromTime = fromTime;
993
        this.toTime = toTime;
994
        this.gatewayId = gatewayId;
995
      }
996
 
997
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
998
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsByCapturedDate", org.apache.thrift.protocol.TMessageType.CALL, 0));
999
        getPaymentsByCapturedDate_args args = new getPaymentsByCapturedDate_args();
1000
        args.setFromTime(fromTime);
1001
        args.setToTime(toTime);
1002
        args.setGatewayId(gatewayId);
1003
        args.write(prot);
1004
        prot.writeMessageEnd();
1005
      }
1006
 
1007
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
1008
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1009
          throw new IllegalStateException("Method call not finished!");
1010
        }
1011
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1012
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1013
        return (new Client(prot)).recv_getPaymentsByCapturedDate();
1014
      }
1015
    }
1016
 
3430 rajveer 1017
    public void getPaymentGateway(long id, org.apache.thrift.async.AsyncMethodCallback<getPaymentGateway_call> resultHandler) throws org.apache.thrift.TException {
1018
      checkReady();
1019
      getPaymentGateway_call method_call = new getPaymentGateway_call(id, resultHandler, this, ___protocolFactory, ___transport);
1020
      this.___currentMethod = method_call;
1021
      ___manager.call(method_call);
1022
    }
1023
 
1024
    public static class getPaymentGateway_call extends org.apache.thrift.async.TAsyncMethodCall {
1025
      private long id;
1026
      public getPaymentGateway_call(long id, org.apache.thrift.async.AsyncMethodCallback<getPaymentGateway_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1027
        super(client, protocolFactory, transport, resultHandler, false);
1028
        this.id = id;
1029
      }
1030
 
1031
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1032
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentGateway", org.apache.thrift.protocol.TMessageType.CALL, 0));
1033
        getPaymentGateway_args args = new getPaymentGateway_args();
1034
        args.setId(id);
1035
        args.write(prot);
1036
        prot.writeMessageEnd();
1037
      }
1038
 
1039
      public PaymentGateway getResult() throws PaymentException, org.apache.thrift.TException {
1040
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1041
          throw new IllegalStateException("Method call not finished!");
1042
        }
1043
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1044
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1045
        return (new Client(prot)).recv_getPaymentGateway();
1046
      }
1047
    }
1048
 
4600 varun.gupt 1049
    public void getActivePaymentGateways(org.apache.thrift.async.AsyncMethodCallback<getActivePaymentGateways_call> resultHandler) throws org.apache.thrift.TException {
1050
      checkReady();
1051
      getActivePaymentGateways_call method_call = new getActivePaymentGateways_call(resultHandler, this, ___protocolFactory, ___transport);
1052
      this.___currentMethod = method_call;
1053
      ___manager.call(method_call);
1054
    }
1055
 
1056
    public static class getActivePaymentGateways_call extends org.apache.thrift.async.TAsyncMethodCall {
1057
      public getActivePaymentGateways_call(org.apache.thrift.async.AsyncMethodCallback<getActivePaymentGateways_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1058
        super(client, protocolFactory, transport, resultHandler, false);
1059
      }
1060
 
1061
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1062
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getActivePaymentGateways", org.apache.thrift.protocol.TMessageType.CALL, 0));
1063
        getActivePaymentGateways_args args = new getActivePaymentGateways_args();
1064
        args.write(prot);
1065
        prot.writeMessageEnd();
1066
      }
1067
 
1068
      public List<PaymentGateway> getResult() throws PaymentException, org.apache.thrift.TException {
1069
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1070
          throw new IllegalStateException("Method call not finished!");
1071
        }
1072
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1073
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1074
        return (new Client(prot)).recv_getActivePaymentGateways();
1075
      }
1076
    }
1077
 
3430 rajveer 1078
    public void getPayment(long id, org.apache.thrift.async.AsyncMethodCallback<getPayment_call> resultHandler) throws org.apache.thrift.TException {
1079
      checkReady();
1080
      getPayment_call method_call = new getPayment_call(id, resultHandler, this, ___protocolFactory, ___transport);
1081
      this.___currentMethod = method_call;
1082
      ___manager.call(method_call);
1083
    }
1084
 
1085
    public static class getPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1086
      private long id;
1087
      public getPayment_call(long id, org.apache.thrift.async.AsyncMethodCallback<getPayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1088
        super(client, protocolFactory, transport, resultHandler, false);
1089
        this.id = id;
1090
      }
1091
 
1092
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1093
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1094
        getPayment_args args = new getPayment_args();
1095
        args.setId(id);
1096
        args.write(prot);
1097
        prot.writeMessageEnd();
1098
      }
1099
 
1100
      public Payment getResult() throws PaymentException, org.apache.thrift.TException {
1101
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1102
          throw new IllegalStateException("Method call not finished!");
1103
        }
1104
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1105
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1106
        return (new Client(prot)).recv_getPayment();
1107
      }
1108
    }
1109
 
1110
    public void getPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<getPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException {
1111
      checkReady();
1112
      getPaymentForTxnId_call method_call = new getPaymentForTxnId_call(txnId, resultHandler, this, ___protocolFactory, ___transport);
1113
      this.___currentMethod = method_call;
1114
      ___manager.call(method_call);
1115
    }
1116
 
1117
    public static class getPaymentForTxnId_call extends org.apache.thrift.async.TAsyncMethodCall {
1118
      private long txnId;
1119
      public getPaymentForTxnId_call(long txnId, org.apache.thrift.async.AsyncMethodCallback<getPaymentForTxnId_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1120
        super(client, protocolFactory, transport, resultHandler, false);
1121
        this.txnId = txnId;
1122
      }
1123
 
1124
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1125
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentForTxnId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1126
        getPaymentForTxnId_args args = new getPaymentForTxnId_args();
1127
        args.setTxnId(txnId);
1128
        args.write(prot);
1129
        prot.writeMessageEnd();
1130
      }
1131
 
1132
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
1133
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1134
          throw new IllegalStateException("Method call not finished!");
1135
        }
1136
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1137
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1138
        return (new Client(prot)).recv_getPaymentForTxnId();
1139
      }
1140
    }
1141
 
4600 varun.gupt 1142
    public void getSuccessfulPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<getSuccessfulPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException {
1143
      checkReady();
1144
      getSuccessfulPaymentForTxnId_call method_call = new getSuccessfulPaymentForTxnId_call(txnId, resultHandler, this, ___protocolFactory, ___transport);
1145
      this.___currentMethod = method_call;
1146
      ___manager.call(method_call);
1147
    }
1148
 
1149
    public static class getSuccessfulPaymentForTxnId_call extends org.apache.thrift.async.TAsyncMethodCall {
1150
      private long txnId;
1151
      public getSuccessfulPaymentForTxnId_call(long txnId, org.apache.thrift.async.AsyncMethodCallback<getSuccessfulPaymentForTxnId_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1152
        super(client, protocolFactory, transport, resultHandler, false);
1153
        this.txnId = txnId;
1154
      }
1155
 
1156
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1157
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getSuccessfulPaymentForTxnId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1158
        getSuccessfulPaymentForTxnId_args args = new getSuccessfulPaymentForTxnId_args();
1159
        args.setTxnId(txnId);
1160
        args.write(prot);
1161
        prot.writeMessageEnd();
1162
      }
1163
 
1164
      public Payment getResult() throws PaymentException, org.apache.thrift.TException {
1165
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1166
          throw new IllegalStateException("Method call not finished!");
1167
        }
1168
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1169
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1170
        return (new Client(prot)).recv_getSuccessfulPaymentForTxnId();
1171
      }
1172
    }
1173
 
3430 rajveer 1174
    public void updatePaymentDetails(long id, String gatewayPaymentId, String sessionId, String gatewayTxnStatus, String description, String gatewayTxnId, String authCode, String referenceCode, String errorCode, PaymentStatus status, String gatewayTxnDate, List<Attribute> attributes, org.apache.thrift.async.AsyncMethodCallback<updatePaymentDetails_call> resultHandler) throws org.apache.thrift.TException {
1175
      checkReady();
1176
      updatePaymentDetails_call method_call = new updatePaymentDetails_call(id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes, resultHandler, this, ___protocolFactory, ___transport);
1177
      this.___currentMethod = method_call;
1178
      ___manager.call(method_call);
1179
    }
1180
 
1181
    public static class updatePaymentDetails_call extends org.apache.thrift.async.TAsyncMethodCall {
1182
      private long id;
1183
      private String gatewayPaymentId;
1184
      private String sessionId;
1185
      private String gatewayTxnStatus;
1186
      private String description;
1187
      private String gatewayTxnId;
1188
      private String authCode;
1189
      private String referenceCode;
1190
      private String errorCode;
1191
      private PaymentStatus status;
1192
      private String gatewayTxnDate;
1193
      private List<Attribute> attributes;
1194
      public updatePaymentDetails_call(long id, String gatewayPaymentId, String sessionId, String gatewayTxnStatus, String description, String gatewayTxnId, String authCode, String referenceCode, String errorCode, PaymentStatus status, String gatewayTxnDate, List<Attribute> attributes, org.apache.thrift.async.AsyncMethodCallback<updatePaymentDetails_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1195
        super(client, protocolFactory, transport, resultHandler, false);
1196
        this.id = id;
1197
        this.gatewayPaymentId = gatewayPaymentId;
1198
        this.sessionId = sessionId;
1199
        this.gatewayTxnStatus = gatewayTxnStatus;
1200
        this.description = description;
1201
        this.gatewayTxnId = gatewayTxnId;
1202
        this.authCode = authCode;
1203
        this.referenceCode = referenceCode;
1204
        this.errorCode = errorCode;
1205
        this.status = status;
1206
        this.gatewayTxnDate = gatewayTxnDate;
1207
        this.attributes = attributes;
1208
      }
1209
 
1210
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1211
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updatePaymentDetails", org.apache.thrift.protocol.TMessageType.CALL, 0));
1212
        updatePaymentDetails_args args = new updatePaymentDetails_args();
1213
        args.setId(id);
1214
        args.setGatewayPaymentId(gatewayPaymentId);
1215
        args.setSessionId(sessionId);
1216
        args.setGatewayTxnStatus(gatewayTxnStatus);
1217
        args.setDescription(description);
1218
        args.setGatewayTxnId(gatewayTxnId);
1219
        args.setAuthCode(authCode);
1220
        args.setReferenceCode(referenceCode);
1221
        args.setErrorCode(errorCode);
1222
        args.setStatus(status);
1223
        args.setGatewayTxnDate(gatewayTxnDate);
1224
        args.setAttributes(attributes);
1225
        args.write(prot);
1226
        prot.writeMessageEnd();
1227
      }
1228
 
1229
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1230
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1231
          throw new IllegalStateException("Method call not finished!");
1232
        }
1233
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1234
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1235
        return (new Client(prot)).recv_updatePaymentDetails();
1236
      }
1237
    }
1238
 
1239
    public void getSuccessfulPaymentsAmountRange(org.apache.thrift.async.AsyncMethodCallback<getSuccessfulPaymentsAmountRange_call> resultHandler) throws org.apache.thrift.TException {
1240
      checkReady();
1241
      getSuccessfulPaymentsAmountRange_call method_call = new getSuccessfulPaymentsAmountRange_call(resultHandler, this, ___protocolFactory, ___transport);
1242
      this.___currentMethod = method_call;
1243
      ___manager.call(method_call);
1244
    }
1245
 
1246
    public static class getSuccessfulPaymentsAmountRange_call extends org.apache.thrift.async.TAsyncMethodCall {
1247
      public getSuccessfulPaymentsAmountRange_call(org.apache.thrift.async.AsyncMethodCallback<getSuccessfulPaymentsAmountRange_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1248
        super(client, protocolFactory, transport, resultHandler, false);
1249
      }
1250
 
1251
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1252
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getSuccessfulPaymentsAmountRange", org.apache.thrift.protocol.TMessageType.CALL, 0));
1253
        getSuccessfulPaymentsAmountRange_args args = new getSuccessfulPaymentsAmountRange_args();
1254
        args.write(prot);
1255
        prot.writeMessageEnd();
1256
      }
1257
 
1258
      public List<Double> getResult() throws org.apache.thrift.TException {
1259
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1260
          throw new IllegalStateException("Method call not finished!");
1261
        }
1262
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1263
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1264
        return (new Client(prot)).recv_getSuccessfulPaymentsAmountRange();
1265
      }
1266
    }
1267
 
1268
    public void initializeHdfcPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcPayment_call> resultHandler) throws org.apache.thrift.TException {
1269
      checkReady();
1270
      initializeHdfcPayment_call method_call = new initializeHdfcPayment_call(merchantPaymentId, resultHandler, this, ___protocolFactory, ___transport);
1271
      this.___currentMethod = method_call;
1272
      ___manager.call(method_call);
1273
    }
1274
 
1275
    public static class initializeHdfcPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1276
      private long merchantPaymentId;
1277
      public initializeHdfcPayment_call(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcPayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1278
        super(client, protocolFactory, transport, resultHandler, false);
1279
        this.merchantPaymentId = merchantPaymentId;
1280
      }
1281
 
1282
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1283
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("initializeHdfcPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1284
        initializeHdfcPayment_args args = new initializeHdfcPayment_args();
1285
        args.setMerchantPaymentId(merchantPaymentId);
1286
        args.write(prot);
1287
        prot.writeMessageEnd();
1288
      }
1289
 
1290
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1291
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1292
          throw new IllegalStateException("Method call not finished!");
1293
        }
1294
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1295
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1296
        return (new Client(prot)).recv_initializeHdfcPayment();
1297
      }
1298
    }
1299
 
6228 anupam.sin 1300
    public void doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone, org.apache.thrift.async.AsyncMethodCallback<doHdfcPaymentForDigitalOrder_call> resultHandler) throws org.apache.thrift.TException {
6050 anupam.sin 1301
      checkReady();
6228 anupam.sin 1302
      doHdfcPaymentForDigitalOrder_call method_call = new doHdfcPaymentForDigitalOrder_call(merchantPaymentId, rechargeOrderId, phone, resultHandler, this, ___protocolFactory, ___transport);
6050 anupam.sin 1303
      this.___currentMethod = method_call;
1304
      ___manager.call(method_call);
1305
    }
1306
 
1307
    public static class doHdfcPaymentForDigitalOrder_call extends org.apache.thrift.async.TAsyncMethodCall {
1308
      private long merchantPaymentId;
1309
      private long rechargeOrderId;
6228 anupam.sin 1310
      private String phone;
1311
      public doHdfcPaymentForDigitalOrder_call(long merchantPaymentId, long rechargeOrderId, String phone, org.apache.thrift.async.AsyncMethodCallback<doHdfcPaymentForDigitalOrder_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
6050 anupam.sin 1312
        super(client, protocolFactory, transport, resultHandler, false);
1313
        this.merchantPaymentId = merchantPaymentId;
1314
        this.rechargeOrderId = rechargeOrderId;
6228 anupam.sin 1315
        this.phone = phone;
6050 anupam.sin 1316
      }
1317
 
1318
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1319
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("doHdfcPaymentForDigitalOrder", org.apache.thrift.protocol.TMessageType.CALL, 0));
1320
        doHdfcPaymentForDigitalOrder_args args = new doHdfcPaymentForDigitalOrder_args();
1321
        args.setMerchantPaymentId(merchantPaymentId);
1322
        args.setRechargeOrderId(rechargeOrderId);
6228 anupam.sin 1323
        args.setPhone(phone);
6050 anupam.sin 1324
        args.write(prot);
1325
        prot.writeMessageEnd();
1326
      }
1327
 
1328
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1329
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1330
          throw new IllegalStateException("Method call not finished!");
1331
        }
1332
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1333
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1334
        return (new Client(prot)).recv_doHdfcPaymentForDigitalOrder();
1335
      }
1336
    }
1337
 
3616 chandransh 1338
    public void initializeHdfcEmiPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcEmiPayment_call> resultHandler) throws org.apache.thrift.TException {
1339
      checkReady();
1340
      initializeHdfcEmiPayment_call method_call = new initializeHdfcEmiPayment_call(merchantPaymentId, resultHandler, this, ___protocolFactory, ___transport);
1341
      this.___currentMethod = method_call;
1342
      ___manager.call(method_call);
1343
    }
1344
 
1345
    public static class initializeHdfcEmiPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1346
      private long merchantPaymentId;
1347
      public initializeHdfcEmiPayment_call(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcEmiPayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1348
        super(client, protocolFactory, transport, resultHandler, false);
1349
        this.merchantPaymentId = merchantPaymentId;
1350
      }
1351
 
1352
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1353
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("initializeHdfcEmiPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1354
        initializeHdfcEmiPayment_args args = new initializeHdfcEmiPayment_args();
1355
        args.setMerchantPaymentId(merchantPaymentId);
1356
        args.write(prot);
1357
        prot.writeMessageEnd();
1358
      }
1359
 
1360
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1361
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1362
          throw new IllegalStateException("Method call not finished!");
1363
        }
1364
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1365
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1366
        return (new Client(prot)).recv_initializeHdfcEmiPayment();
1367
      }
1368
    }
1369
 
3430 rajveer 1370
    public void createRefund(long orderId, long merchantTxnId, double amount, org.apache.thrift.async.AsyncMethodCallback<createRefund_call> resultHandler) throws org.apache.thrift.TException {
1371
      checkReady();
1372
      createRefund_call method_call = new createRefund_call(orderId, merchantTxnId, amount, resultHandler, this, ___protocolFactory, ___transport);
1373
      this.___currentMethod = method_call;
1374
      ___manager.call(method_call);
1375
    }
1376
 
1377
    public static class createRefund_call extends org.apache.thrift.async.TAsyncMethodCall {
1378
      private long orderId;
1379
      private long merchantTxnId;
1380
      private double amount;
1381
      public createRefund_call(long orderId, long merchantTxnId, double amount, org.apache.thrift.async.AsyncMethodCallback<createRefund_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1382
        super(client, protocolFactory, transport, resultHandler, false);
1383
        this.orderId = orderId;
1384
        this.merchantTxnId = merchantTxnId;
1385
        this.amount = amount;
1386
      }
1387
 
1388
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1389
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createRefund", org.apache.thrift.protocol.TMessageType.CALL, 0));
1390
        createRefund_args args = new createRefund_args();
1391
        args.setOrderId(orderId);
1392
        args.setMerchantTxnId(merchantTxnId);
1393
        args.setAmount(amount);
1394
        args.write(prot);
1395
        prot.writeMessageEnd();
1396
      }
1397
 
1398
      public long getResult() throws PaymentException, org.apache.thrift.TException {
1399
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1400
          throw new IllegalStateException("Method call not finished!");
1401
        }
1402
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1403
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1404
        return (new Client(prot)).recv_createRefund();
1405
      }
1406
    }
1407
 
1408
    public void capturePayment(long merchantTxnId, org.apache.thrift.async.AsyncMethodCallback<capturePayment_call> resultHandler) throws org.apache.thrift.TException {
1409
      checkReady();
1410
      capturePayment_call method_call = new capturePayment_call(merchantTxnId, resultHandler, this, ___protocolFactory, ___transport);
1411
      this.___currentMethod = method_call;
1412
      ___manager.call(method_call);
1413
    }
1414
 
1415
    public static class capturePayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1416
      private long merchantTxnId;
1417
      public capturePayment_call(long merchantTxnId, org.apache.thrift.async.AsyncMethodCallback<capturePayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1418
        super(client, protocolFactory, transport, resultHandler, false);
1419
        this.merchantTxnId = merchantTxnId;
1420
      }
1421
 
1422
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1423
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("capturePayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1424
        capturePayment_args args = new capturePayment_args();
1425
        args.setMerchantTxnId(merchantTxnId);
1426
        args.write(prot);
1427
        prot.writeMessageEnd();
1428
      }
1429
 
1430
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1431
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1432
          throw new IllegalStateException("Method call not finished!");
1433
        }
1434
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1435
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1436
        return (new Client(prot)).recv_capturePayment();
1437
      }
1438
    }
1439
 
6486 rajveer 1440
    public void refundPayment(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<refundPayment_call> resultHandler) throws org.apache.thrift.TException {
1441
      checkReady();
1442
      refundPayment_call method_call = new refundPayment_call(merchantTxnId, amount, isDigital, resultHandler, this, ___protocolFactory, ___transport);
1443
      this.___currentMethod = method_call;
1444
      ___manager.call(method_call);
1445
    }
1446
 
1447
    public static class refundPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1448
      private long merchantTxnId;
1449
      private double amount;
1450
      private boolean isDigital;
1451
      public refundPayment_call(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<refundPayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1452
        super(client, protocolFactory, transport, resultHandler, false);
1453
        this.merchantTxnId = merchantTxnId;
1454
        this.amount = amount;
1455
        this.isDigital = isDigital;
1456
      }
1457
 
1458
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1459
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("refundPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1460
        refundPayment_args args = new refundPayment_args();
1461
        args.setMerchantTxnId(merchantTxnId);
1462
        args.setAmount(amount);
1463
        args.setIsDigital(isDigital);
1464
        args.write(prot);
1465
        prot.writeMessageEnd();
1466
      }
1467
 
1468
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1469
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1470
          throw new IllegalStateException("Method call not finished!");
1471
        }
1472
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1473
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1474
        return (new Client(prot)).recv_refundPayment();
1475
      }
1476
    }
1477
 
3956 chandransh 1478
    public void partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate, org.apache.thrift.async.AsyncMethodCallback<partiallyCapturePayment_call> resultHandler) throws org.apache.thrift.TException {
1479
      checkReady();
1480
      partiallyCapturePayment_call method_call = new partiallyCapturePayment_call(merchantTxnId, amount, xferBy, xferTxnId, xferDate, resultHandler, this, ___protocolFactory, ___transport);
1481
      this.___currentMethod = method_call;
1482
      ___manager.call(method_call);
1483
    }
1484
 
1485
    public static class partiallyCapturePayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1486
      private long merchantTxnId;
1487
      private double amount;
1488
      private String xferBy;
1489
      private String xferTxnId;
1490
      private long xferDate;
1491
      public partiallyCapturePayment_call(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate, org.apache.thrift.async.AsyncMethodCallback<partiallyCapturePayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1492
        super(client, protocolFactory, transport, resultHandler, false);
1493
        this.merchantTxnId = merchantTxnId;
1494
        this.amount = amount;
1495
        this.xferBy = xferBy;
1496
        this.xferTxnId = xferTxnId;
1497
        this.xferDate = xferDate;
1498
      }
1499
 
1500
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1501
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("partiallyCapturePayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1502
        partiallyCapturePayment_args args = new partiallyCapturePayment_args();
1503
        args.setMerchantTxnId(merchantTxnId);
1504
        args.setAmount(amount);
1505
        args.setXferBy(xferBy);
1506
        args.setXferTxnId(xferTxnId);
1507
        args.setXferDate(xferDate);
1508
        args.write(prot);
1509
        prot.writeMessageEnd();
1510
      }
1511
 
1512
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1513
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1514
          throw new IllegalStateException("Method call not finished!");
1515
        }
1516
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1517
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1518
        return (new Client(prot)).recv_partiallyCapturePayment();
1519
      }
1520
    }
1521
 
4008 mandeep.dh 1522
    public void getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<getPaymentsRequiringExtraProcessing_call> resultHandler) throws org.apache.thrift.TException {
1523
      checkReady();
1524
      getPaymentsRequiringExtraProcessing_call method_call = new getPaymentsRequiringExtraProcessing_call(category, resultHandler, this, ___protocolFactory, ___transport);
1525
      this.___currentMethod = method_call;
1526
      ___manager.call(method_call);
1527
    }
1528
 
1529
    public static class getPaymentsRequiringExtraProcessing_call extends org.apache.thrift.async.TAsyncMethodCall {
1530
      private ExtraPaymentProcessingType category;
1531
      public getPaymentsRequiringExtraProcessing_call(ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<getPaymentsRequiringExtraProcessing_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1532
        super(client, protocolFactory, transport, resultHandler, false);
1533
        this.category = category;
1534
      }
1535
 
1536
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1537
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsRequiringExtraProcessing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1538
        getPaymentsRequiringExtraProcessing_args args = new getPaymentsRequiringExtraProcessing_args();
1539
        args.setCategory(category);
1540
        args.write(prot);
1541
        prot.writeMessageEnd();
1542
      }
1543
 
1544
      public List<Long> getResult() throws org.apache.thrift.TException {
1545
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1546
          throw new IllegalStateException("Method call not finished!");
1547
        }
1548
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1549
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1550
        return (new Client(prot)).recv_getPaymentsRequiringExtraProcessing();
1551
      }
1552
    }
1553
 
1554
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<markPaymentAsProcessed_call> resultHandler) throws org.apache.thrift.TException {
1555
      checkReady();
1556
      markPaymentAsProcessed_call method_call = new markPaymentAsProcessed_call(paymentId, category, resultHandler, this, ___protocolFactory, ___transport);
1557
      this.___currentMethod = method_call;
1558
      ___manager.call(method_call);
1559
    }
1560
 
1561
    public static class markPaymentAsProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
1562
      private long paymentId;
1563
      private ExtraPaymentProcessingType category;
1564
      public markPaymentAsProcessed_call(long paymentId, ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<markPaymentAsProcessed_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1565
        super(client, protocolFactory, transport, resultHandler, false);
1566
        this.paymentId = paymentId;
1567
        this.category = category;
1568
      }
1569
 
1570
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1571
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("markPaymentAsProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
1572
        markPaymentAsProcessed_args args = new markPaymentAsProcessed_args();
1573
        args.setPaymentId(paymentId);
1574
        args.setCategory(category);
1575
        args.write(prot);
1576
        prot.writeMessageEnd();
1577
      }
1578
 
1579
      public void getResult() throws org.apache.thrift.TException {
1580
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1581
          throw new IllegalStateException("Method call not finished!");
1582
        }
1583
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1584
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1585
        (new Client(prot)).recv_markPaymentAsProcessed();
1586
      }
1587
    }
1588
 
3430 rajveer 1589
  }
1590
 
1591
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
1592
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
1593
    public Processor(I iface) {
1594
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
1595
    }
1596
 
1597
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
1598
      super(iface, getProcessMap(processMap));
1599
    }
1600
 
1601
    private static <I extends Iface> Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> getProcessMap(Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
1602
      processMap.put("createPayment", new createPayment());
1603
      processMap.put("getPaymentsForUser", new getPaymentsForUser());
1604
      processMap.put("getPayments", new getPayments());
4141 chandransh 1605
      processMap.put("getPaymentsByCapturedDate", new getPaymentsByCapturedDate());
3430 rajveer 1606
      processMap.put("getPaymentGateway", new getPaymentGateway());
4600 varun.gupt 1607
      processMap.put("getActivePaymentGateways", new getActivePaymentGateways());
3430 rajveer 1608
      processMap.put("getPayment", new getPayment());
1609
      processMap.put("getPaymentForTxnId", new getPaymentForTxnId());
4600 varun.gupt 1610
      processMap.put("getSuccessfulPaymentForTxnId", new getSuccessfulPaymentForTxnId());
3430 rajveer 1611
      processMap.put("updatePaymentDetails", new updatePaymentDetails());
1612
      processMap.put("getSuccessfulPaymentsAmountRange", new getSuccessfulPaymentsAmountRange());
1613
      processMap.put("initializeHdfcPayment", new initializeHdfcPayment());
6050 anupam.sin 1614
      processMap.put("doHdfcPaymentForDigitalOrder", new doHdfcPaymentForDigitalOrder());
3616 chandransh 1615
      processMap.put("initializeHdfcEmiPayment", new initializeHdfcEmiPayment());
3430 rajveer 1616
      processMap.put("createRefund", new createRefund());
1617
      processMap.put("capturePayment", new capturePayment());
6486 rajveer 1618
      processMap.put("refundPayment", new refundPayment());
3956 chandransh 1619
      processMap.put("partiallyCapturePayment", new partiallyCapturePayment());
4008 mandeep.dh 1620
      processMap.put("getPaymentsRequiringExtraProcessing", new getPaymentsRequiringExtraProcessing());
1621
      processMap.put("markPaymentAsProcessed", new markPaymentAsProcessed());
3430 rajveer 1622
      return processMap;
1623
    }
1624
 
1625
    private static class createPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createPayment_args> {
1626
      public createPayment() {
1627
        super("createPayment");
1628
      }
1629
 
1630
      protected createPayment_args getEmptyArgsInstance() {
1631
        return new createPayment_args();
1632
      }
1633
 
1634
      protected createPayment_result getResult(I iface, createPayment_args args) throws org.apache.thrift.TException {
123 ashish 1635
        createPayment_result result = new createPayment_result();
1636
        try {
6050 anupam.sin 1637
          result.success = iface.createPayment(args.userId, args.amount, args.gatewayId, args.txnId, args.isDigital);
420 ashish 1638
          result.setSuccessIsSet(true);
123 ashish 1639
        } catch (PaymentException pe) {
1640
          result.pe = pe;
1641
        }
3430 rajveer 1642
        return result;
123 ashish 1643
      }
1644
    }
1645
 
3430 rajveer 1646
    private static class getPaymentsForUser<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsForUser_args> {
1647
      public getPaymentsForUser() {
1648
        super("getPaymentsForUser");
1649
      }
1650
 
1651
      protected getPaymentsForUser_args getEmptyArgsInstance() {
1652
        return new getPaymentsForUser_args();
1653
      }
1654
 
1655
      protected getPaymentsForUser_result getResult(I iface, getPaymentsForUser_args args) throws org.apache.thrift.TException {
123 ashish 1656
        getPaymentsForUser_result result = new getPaymentsForUser_result();
1657
        try {
3430 rajveer 1658
          result.success = iface.getPaymentsForUser(args.userId, args.fromTime, args.toTime, args.status, args.gatewayId);
123 ashish 1659
        } catch (PaymentException pe) {
1660
          result.pe = pe;
1661
        }
3430 rajveer 1662
        return result;
123 ashish 1663
      }
1664
    }
1665
 
3430 rajveer 1666
    private static class getPayments<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPayments_args> {
1667
      public getPayments() {
1668
        super("getPayments");
1669
      }
1670
 
1671
      protected getPayments_args getEmptyArgsInstance() {
1672
        return new getPayments_args();
1673
      }
1674
 
1675
      protected getPayments_result getResult(I iface, getPayments_args args) throws org.apache.thrift.TException {
123 ashish 1676
        getPayments_result result = new getPayments_result();
1677
        try {
3430 rajveer 1678
          result.success = iface.getPayments(args.fromTime, args.toTime, args.status, args.gatewayId);
123 ashish 1679
        } catch (PaymentException pe) {
1680
          result.pe = pe;
1681
        }
3430 rajveer 1682
        return result;
123 ashish 1683
      }
1684
    }
1685
 
4141 chandransh 1686
    private static class getPaymentsByCapturedDate<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsByCapturedDate_args> {
1687
      public getPaymentsByCapturedDate() {
1688
        super("getPaymentsByCapturedDate");
1689
      }
1690
 
1691
      protected getPaymentsByCapturedDate_args getEmptyArgsInstance() {
1692
        return new getPaymentsByCapturedDate_args();
1693
      }
1694
 
1695
      protected getPaymentsByCapturedDate_result getResult(I iface, getPaymentsByCapturedDate_args args) throws org.apache.thrift.TException {
1696
        getPaymentsByCapturedDate_result result = new getPaymentsByCapturedDate_result();
1697
        try {
1698
          result.success = iface.getPaymentsByCapturedDate(args.fromTime, args.toTime, args.gatewayId);
1699
        } catch (PaymentException pe) {
1700
          result.pe = pe;
1701
        }
1702
        return result;
1703
      }
1704
    }
1705
 
3430 rajveer 1706
    private static class getPaymentGateway<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentGateway_args> {
1707
      public getPaymentGateway() {
1708
        super("getPaymentGateway");
1709
      }
1710
 
1711
      protected getPaymentGateway_args getEmptyArgsInstance() {
1712
        return new getPaymentGateway_args();
1713
      }
1714
 
1715
      protected getPaymentGateway_result getResult(I iface, getPaymentGateway_args args) throws org.apache.thrift.TException {
420 ashish 1716
        getPaymentGateway_result result = new getPaymentGateway_result();
1717
        try {
3430 rajveer 1718
          result.success = iface.getPaymentGateway(args.id);
420 ashish 1719
        } catch (PaymentException pe) {
1720
          result.pe = pe;
1721
        }
3430 rajveer 1722
        return result;
420 ashish 1723
      }
1724
    }
1725
 
4600 varun.gupt 1726
    private static class getActivePaymentGateways<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getActivePaymentGateways_args> {
1727
      public getActivePaymentGateways() {
1728
        super("getActivePaymentGateways");
1729
      }
1730
 
1731
      protected getActivePaymentGateways_args getEmptyArgsInstance() {
1732
        return new getActivePaymentGateways_args();
1733
      }
1734
 
1735
      protected getActivePaymentGateways_result getResult(I iface, getActivePaymentGateways_args args) throws org.apache.thrift.TException {
1736
        getActivePaymentGateways_result result = new getActivePaymentGateways_result();
1737
        try {
1738
          result.success = iface.getActivePaymentGateways();
1739
        } catch (PaymentException pe) {
1740
          result.pe = pe;
1741
        }
1742
        return result;
1743
      }
1744
    }
1745
 
3430 rajveer 1746
    private static class getPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPayment_args> {
1747
      public getPayment() {
1748
        super("getPayment");
1749
      }
1750
 
1751
      protected getPayment_args getEmptyArgsInstance() {
1752
        return new getPayment_args();
1753
      }
1754
 
1755
      protected getPayment_result getResult(I iface, getPayment_args args) throws org.apache.thrift.TException {
695 rajveer 1756
        getPayment_result result = new getPayment_result();
420 ashish 1757
        try {
3430 rajveer 1758
          result.success = iface.getPayment(args.id);
420 ashish 1759
        } catch (PaymentException pe) {
1760
          result.pe = pe;
1761
        }
3430 rajveer 1762
        return result;
420 ashish 1763
      }
1764
    }
1765
 
3430 rajveer 1766
    private static class getPaymentForTxnId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentForTxnId_args> {
1767
      public getPaymentForTxnId() {
1768
        super("getPaymentForTxnId");
1769
      }
1770
 
1771
      protected getPaymentForTxnId_args getEmptyArgsInstance() {
1772
        return new getPaymentForTxnId_args();
1773
      }
1774
 
1775
      protected getPaymentForTxnId_result getResult(I iface, getPaymentForTxnId_args args) throws org.apache.thrift.TException {
695 rajveer 1776
        getPaymentForTxnId_result result = new getPaymentForTxnId_result();
420 ashish 1777
        try {
3430 rajveer 1778
          result.success = iface.getPaymentForTxnId(args.txnId);
420 ashish 1779
        } catch (PaymentException pe) {
1780
          result.pe = pe;
1781
        }
3430 rajveer 1782
        return result;
420 ashish 1783
      }
1784
    }
1785
 
4600 varun.gupt 1786
    private static class getSuccessfulPaymentForTxnId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getSuccessfulPaymentForTxnId_args> {
1787
      public getSuccessfulPaymentForTxnId() {
1788
        super("getSuccessfulPaymentForTxnId");
1789
      }
1790
 
1791
      protected getSuccessfulPaymentForTxnId_args getEmptyArgsInstance() {
1792
        return new getSuccessfulPaymentForTxnId_args();
1793
      }
1794
 
1795
      protected getSuccessfulPaymentForTxnId_result getResult(I iface, getSuccessfulPaymentForTxnId_args args) throws org.apache.thrift.TException {
1796
        getSuccessfulPaymentForTxnId_result result = new getSuccessfulPaymentForTxnId_result();
1797
        try {
1798
          result.success = iface.getSuccessfulPaymentForTxnId(args.txnId);
1799
        } catch (PaymentException pe) {
1800
          result.pe = pe;
1801
        }
1802
        return result;
1803
      }
1804
    }
1805
 
3430 rajveer 1806
    private static class updatePaymentDetails<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updatePaymentDetails_args> {
1807
      public updatePaymentDetails() {
1808
        super("updatePaymentDetails");
1809
      }
1810
 
1811
      protected updatePaymentDetails_args getEmptyArgsInstance() {
1812
        return new updatePaymentDetails_args();
1813
      }
1814
 
1815
      protected updatePaymentDetails_result getResult(I iface, updatePaymentDetails_args args) throws org.apache.thrift.TException {
695 rajveer 1816
        updatePaymentDetails_result result = new updatePaymentDetails_result();
420 ashish 1817
        try {
3430 rajveer 1818
          result.success = iface.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);
695 rajveer 1819
          result.setSuccessIsSet(true);
420 ashish 1820
        } catch (PaymentException pe) {
1821
          result.pe = pe;
1822
        }
3430 rajveer 1823
        return result;
420 ashish 1824
      }
1825
    }
1826
 
3430 rajveer 1827
    private static class getSuccessfulPaymentsAmountRange<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getSuccessfulPaymentsAmountRange_args> {
1828
      public getSuccessfulPaymentsAmountRange() {
1829
        super("getSuccessfulPaymentsAmountRange");
1830
      }
1831
 
1832
      protected getSuccessfulPaymentsAmountRange_args getEmptyArgsInstance() {
1833
        return new getSuccessfulPaymentsAmountRange_args();
1834
      }
1835
 
1836
      protected getSuccessfulPaymentsAmountRange_result getResult(I iface, getSuccessfulPaymentsAmountRange_args args) throws org.apache.thrift.TException {
1731 ankur.sing 1837
        getSuccessfulPaymentsAmountRange_result result = new getSuccessfulPaymentsAmountRange_result();
3430 rajveer 1838
        result.success = iface.getSuccessfulPaymentsAmountRange();
1839
        return result;
1629 ankur.sing 1840
      }
1841
    }
1842
 
3430 rajveer 1843
    private static class initializeHdfcPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, initializeHdfcPayment_args> {
1844
      public initializeHdfcPayment() {
1845
        super("initializeHdfcPayment");
1846
      }
1847
 
1848
      protected initializeHdfcPayment_args getEmptyArgsInstance() {
1849
        return new initializeHdfcPayment_args();
1850
      }
1851
 
1852
      protected initializeHdfcPayment_result getResult(I iface, initializeHdfcPayment_args args) throws org.apache.thrift.TException {
2462 chandransh 1853
        initializeHdfcPayment_result result = new initializeHdfcPayment_result();
1854
        try {
3430 rajveer 1855
          result.success = iface.initializeHdfcPayment(args.merchantPaymentId);
2462 chandransh 1856
        } catch (PaymentException pe) {
1857
          result.pe = pe;
1858
        }
3430 rajveer 1859
        return result;
2462 chandransh 1860
      }
1861
    }
1862
 
6050 anupam.sin 1863
    private static class doHdfcPaymentForDigitalOrder<I extends Iface> extends org.apache.thrift.ProcessFunction<I, doHdfcPaymentForDigitalOrder_args> {
1864
      public doHdfcPaymentForDigitalOrder() {
1865
        super("doHdfcPaymentForDigitalOrder");
1866
      }
1867
 
1868
      protected doHdfcPaymentForDigitalOrder_args getEmptyArgsInstance() {
1869
        return new doHdfcPaymentForDigitalOrder_args();
1870
      }
1871
 
1872
      protected doHdfcPaymentForDigitalOrder_result getResult(I iface, doHdfcPaymentForDigitalOrder_args args) throws org.apache.thrift.TException {
1873
        doHdfcPaymentForDigitalOrder_result result = new doHdfcPaymentForDigitalOrder_result();
1874
        try {
6228 anupam.sin 1875
          result.success = iface.doHdfcPaymentForDigitalOrder(args.merchantPaymentId, args.rechargeOrderId, args.phone);
6050 anupam.sin 1876
        } catch (PaymentException pe) {
1877
          result.pe = pe;
1878
        }
1879
        return result;
1880
      }
1881
    }
1882
 
3616 chandransh 1883
    private static class initializeHdfcEmiPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, initializeHdfcEmiPayment_args> {
1884
      public initializeHdfcEmiPayment() {
1885
        super("initializeHdfcEmiPayment");
1886
      }
1887
 
1888
      protected initializeHdfcEmiPayment_args getEmptyArgsInstance() {
1889
        return new initializeHdfcEmiPayment_args();
1890
      }
1891
 
1892
      protected initializeHdfcEmiPayment_result getResult(I iface, initializeHdfcEmiPayment_args args) throws org.apache.thrift.TException {
1893
        initializeHdfcEmiPayment_result result = new initializeHdfcEmiPayment_result();
1894
        try {
1895
          result.success = iface.initializeHdfcEmiPayment(args.merchantPaymentId);
1896
        } catch (PaymentException pe) {
1897
          result.pe = pe;
1898
        }
1899
        return result;
1900
      }
1901
    }
1902
 
3430 rajveer 1903
    private static class createRefund<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createRefund_args> {
1904
      public createRefund() {
1905
        super("createRefund");
1906
      }
1907
 
1908
      protected createRefund_args getEmptyArgsInstance() {
1909
        return new createRefund_args();
1910
      }
1911
 
1912
      protected createRefund_result getResult(I iface, createRefund_args args) throws org.apache.thrift.TException {
2690 chandransh 1913
        createRefund_result result = new createRefund_result();
1914
        try {
3430 rajveer 1915
          result.success = iface.createRefund(args.orderId, args.merchantTxnId, args.amount);
2690 chandransh 1916
          result.setSuccessIsSet(true);
1917
        } catch (PaymentException pe) {
1918
          result.pe = pe;
1919
        }
3430 rajveer 1920
        return result;
2690 chandransh 1921
      }
1922
    }
1923
 
3430 rajveer 1924
    private static class capturePayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, capturePayment_args> {
1925
      public capturePayment() {
1926
        super("capturePayment");
1927
      }
1928
 
1929
      protected capturePayment_args getEmptyArgsInstance() {
1930
        return new capturePayment_args();
1931
      }
1932
 
1933
      protected capturePayment_result getResult(I iface, capturePayment_args args) throws org.apache.thrift.TException {
3010 chandransh 1934
        capturePayment_result result = new capturePayment_result();
1935
        try {
3430 rajveer 1936
          result.success = iface.capturePayment(args.merchantTxnId);
3010 chandransh 1937
          result.setSuccessIsSet(true);
1938
        } catch (PaymentException pe) {
1939
          result.pe = pe;
1940
        }
3430 rajveer 1941
        return result;
3010 chandransh 1942
      }
1943
    }
1944
 
6486 rajveer 1945
    private static class refundPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, refundPayment_args> {
1946
      public refundPayment() {
1947
        super("refundPayment");
1948
      }
1949
 
1950
      protected refundPayment_args getEmptyArgsInstance() {
1951
        return new refundPayment_args();
1952
      }
1953
 
1954
      protected refundPayment_result getResult(I iface, refundPayment_args args) throws org.apache.thrift.TException {
1955
        refundPayment_result result = new refundPayment_result();
1956
        try {
1957
          result.success = iface.refundPayment(args.merchantTxnId, args.amount, args.isDigital);
1958
          result.setSuccessIsSet(true);
1959
        } catch (PaymentException pe) {
1960
          result.pe = pe;
1961
        }
1962
        return result;
1963
      }
1964
    }
1965
 
3956 chandransh 1966
    private static class partiallyCapturePayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, partiallyCapturePayment_args> {
1967
      public partiallyCapturePayment() {
1968
        super("partiallyCapturePayment");
1969
      }
1970
 
1971
      protected partiallyCapturePayment_args getEmptyArgsInstance() {
1972
        return new partiallyCapturePayment_args();
1973
      }
1974
 
1975
      protected partiallyCapturePayment_result getResult(I iface, partiallyCapturePayment_args args) throws org.apache.thrift.TException {
1976
        partiallyCapturePayment_result result = new partiallyCapturePayment_result();
1977
        try {
1978
          result.success = iface.partiallyCapturePayment(args.merchantTxnId, args.amount, args.xferBy, args.xferTxnId, args.xferDate);
1979
          result.setSuccessIsSet(true);
1980
        } catch (PaymentException pe) {
1981
          result.pe = pe;
1982
        }
1983
        return result;
1984
      }
1985
    }
1986
 
4008 mandeep.dh 1987
    private static class getPaymentsRequiringExtraProcessing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsRequiringExtraProcessing_args> {
1988
      public getPaymentsRequiringExtraProcessing() {
1989
        super("getPaymentsRequiringExtraProcessing");
1990
      }
1991
 
1992
      protected getPaymentsRequiringExtraProcessing_args getEmptyArgsInstance() {
1993
        return new getPaymentsRequiringExtraProcessing_args();
1994
      }
1995
 
1996
      protected getPaymentsRequiringExtraProcessing_result getResult(I iface, getPaymentsRequiringExtraProcessing_args args) throws org.apache.thrift.TException {
1997
        getPaymentsRequiringExtraProcessing_result result = new getPaymentsRequiringExtraProcessing_result();
1998
        result.success = iface.getPaymentsRequiringExtraProcessing(args.category);
1999
        return result;
2000
      }
2001
    }
2002
 
2003
    private static class markPaymentAsProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, markPaymentAsProcessed_args> {
2004
      public markPaymentAsProcessed() {
2005
        super("markPaymentAsProcessed");
2006
      }
2007
 
2008
      protected markPaymentAsProcessed_args getEmptyArgsInstance() {
2009
        return new markPaymentAsProcessed_args();
2010
      }
2011
 
2012
      protected markPaymentAsProcessed_result getResult(I iface, markPaymentAsProcessed_args args) throws org.apache.thrift.TException {
2013
        markPaymentAsProcessed_result result = new markPaymentAsProcessed_result();
2014
        iface.markPaymentAsProcessed(args.paymentId, args.category);
2015
        return result;
2016
      }
2017
    }
2018
 
123 ashish 2019
  }
2020
 
3430 rajveer 2021
  public static class createPayment_args implements org.apache.thrift.TBase<createPayment_args, createPayment_args._Fields>, java.io.Serializable, Cloneable   {
2022
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPayment_args");
123 ashish 2023
 
3430 rajveer 2024
    private static final org.apache.thrift.protocol.TField USER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("userId", org.apache.thrift.protocol.TType.I64, (short)1);
2025
    private static final org.apache.thrift.protocol.TField AMOUNT_FIELD_DESC = new org.apache.thrift.protocol.TField("amount", org.apache.thrift.protocol.TType.DOUBLE, (short)2);
2026
    private static final org.apache.thrift.protocol.TField GATEWAY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayId", org.apache.thrift.protocol.TType.I64, (short)3);
2027
    private static final org.apache.thrift.protocol.TField TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("txnId", org.apache.thrift.protocol.TType.I64, (short)4);
6050 anupam.sin 2028
    private static final org.apache.thrift.protocol.TField IS_DIGITAL_FIELD_DESC = new org.apache.thrift.protocol.TField("isDigital", org.apache.thrift.protocol.TType.BOOL, (short)5);
123 ashish 2029
 
3430 rajveer 2030
    private long userId; // required
2031
    private double amount; // required
2032
    private long gatewayId; // required
2033
    private long txnId; // required
6050 anupam.sin 2034
    private boolean isDigital; // required
123 ashish 2035
 
2036
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2037
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 2038
      USER_ID((short)1, "userId"),
2039
      AMOUNT((short)2, "amount"),
2040
      GATEWAY_ID((short)3, "gatewayId"),
6050 anupam.sin 2041
      TXN_ID((short)4, "txnId"),
2042
      IS_DIGITAL((short)5, "isDigital");
123 ashish 2043
 
2044
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2045
 
2046
      static {
2047
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2048
          byName.put(field.getFieldName(), field);
2049
        }
2050
      }
2051
 
2052
      /**
2053
       * Find the _Fields constant that matches fieldId, or null if its not found.
2054
       */
2055
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2056
        switch(fieldId) {
2057
          case 1: // USER_ID
2058
            return USER_ID;
2059
          case 2: // AMOUNT
2060
            return AMOUNT;
2061
          case 3: // GATEWAY_ID
2062
            return GATEWAY_ID;
2063
          case 4: // TXN_ID
2064
            return TXN_ID;
6050 anupam.sin 2065
          case 5: // IS_DIGITAL
2066
            return IS_DIGITAL;
3430 rajveer 2067
          default:
2068
            return null;
2069
        }
123 ashish 2070
      }
2071
 
2072
      /**
2073
       * Find the _Fields constant that matches fieldId, throwing an exception
2074
       * if it is not found.
2075
       */
2076
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2077
        _Fields fields = findByThriftId(fieldId);
2078
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2079
        return fields;
2080
      }
2081
 
2082
      /**
2083
       * Find the _Fields constant that matches name, or null if its not found.
2084
       */
2085
      public static _Fields findByName(String name) {
2086
        return byName.get(name);
2087
      }
2088
 
2089
      private final short _thriftId;
2090
      private final String _fieldName;
2091
 
2092
      _Fields(short thriftId, String fieldName) {
2093
        _thriftId = thriftId;
2094
        _fieldName = fieldName;
2095
      }
2096
 
2097
      public short getThriftFieldId() {
2098
        return _thriftId;
2099
      }
2100
 
2101
      public String getFieldName() {
2102
        return _fieldName;
2103
      }
2104
    }
2105
 
2106
    // isset id assignments
695 rajveer 2107
    private static final int __USERID_ISSET_ID = 0;
2108
    private static final int __AMOUNT_ISSET_ID = 1;
2109
    private static final int __GATEWAYID_ISSET_ID = 2;
2110
    private static final int __TXNID_ISSET_ID = 3;
6050 anupam.sin 2111
    private static final int __ISDIGITAL_ISSET_ID = 4;
2112
    private BitSet __isset_bit_vector = new BitSet(5);
123 ashish 2113
 
3430 rajveer 2114
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 2115
    static {
3430 rajveer 2116
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2117
      tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2118
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2119
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2120
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
2121
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2122
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2123
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2124
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6050 anupam.sin 2125
      tmpMap.put(_Fields.IS_DIGITAL, new org.apache.thrift.meta_data.FieldMetaData("isDigital", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2126
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
3430 rajveer 2127
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2128
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createPayment_args.class, metaDataMap);
123 ashish 2129
    }
2130
 
2131
    public createPayment_args() {
2132
    }
2133
 
2134
    public createPayment_args(
695 rajveer 2135
      long userId,
123 ashish 2136
      double amount,
695 rajveer 2137
      long gatewayId,
6050 anupam.sin 2138
      long txnId,
2139
      boolean isDigital)
123 ashish 2140
    {
2141
      this();
695 rajveer 2142
      this.userId = userId;
2143
      setUserIdIsSet(true);
123 ashish 2144
      this.amount = amount;
2145
      setAmountIsSet(true);
695 rajveer 2146
      this.gatewayId = gatewayId;
2147
      setGatewayIdIsSet(true);
2148
      this.txnId = txnId;
2149
      setTxnIdIsSet(true);
6050 anupam.sin 2150
      this.isDigital = isDigital;
2151
      setIsDigitalIsSet(true);
123 ashish 2152
    }
2153
 
2154
    /**
2155
     * Performs a deep copy on <i>other</i>.
2156
     */
2157
    public createPayment_args(createPayment_args other) {
2158
      __isset_bit_vector.clear();
2159
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 2160
      this.userId = other.userId;
123 ashish 2161
      this.amount = other.amount;
695 rajveer 2162
      this.gatewayId = other.gatewayId;
2163
      this.txnId = other.txnId;
6050 anupam.sin 2164
      this.isDigital = other.isDigital;
123 ashish 2165
    }
2166
 
2167
    public createPayment_args deepCopy() {
2168
      return new createPayment_args(this);
2169
    }
2170
 
3430 rajveer 2171
    @Override
2172
    public void clear() {
2173
      setUserIdIsSet(false);
2174
      this.userId = 0;
2175
      setAmountIsSet(false);
2176
      this.amount = 0.0;
2177
      setGatewayIdIsSet(false);
2178
      this.gatewayId = 0;
2179
      setTxnIdIsSet(false);
2180
      this.txnId = 0;
6050 anupam.sin 2181
      setIsDigitalIsSet(false);
2182
      this.isDigital = false;
123 ashish 2183
    }
2184
 
695 rajveer 2185
    public long getUserId() {
2186
      return this.userId;
123 ashish 2187
    }
2188
 
3430 rajveer 2189
    public void setUserId(long userId) {
695 rajveer 2190
      this.userId = userId;
2191
      setUserIdIsSet(true);
123 ashish 2192
    }
2193
 
695 rajveer 2194
    public void unsetUserId() {
2195
      __isset_bit_vector.clear(__USERID_ISSET_ID);
123 ashish 2196
    }
2197
 
3430 rajveer 2198
    /** Returns true if field userId is set (has been assigned a value) and false otherwise */
695 rajveer 2199
    public boolean isSetUserId() {
2200
      return __isset_bit_vector.get(__USERID_ISSET_ID);
123 ashish 2201
    }
2202
 
695 rajveer 2203
    public void setUserIdIsSet(boolean value) {
2204
      __isset_bit_vector.set(__USERID_ISSET_ID, value);
123 ashish 2205
    }
2206
 
2207
    public double getAmount() {
2208
      return this.amount;
2209
    }
2210
 
3430 rajveer 2211
    public void setAmount(double amount) {
123 ashish 2212
      this.amount = amount;
2213
      setAmountIsSet(true);
2214
    }
2215
 
2216
    public void unsetAmount() {
2217
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
2218
    }
2219
 
3430 rajveer 2220
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
123 ashish 2221
    public boolean isSetAmount() {
2222
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
2223
    }
2224
 
2225
    public void setAmountIsSet(boolean value) {
2226
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
2227
    }
2228
 
695 rajveer 2229
    public long getGatewayId() {
2230
      return this.gatewayId;
123 ashish 2231
    }
2232
 
3430 rajveer 2233
    public void setGatewayId(long gatewayId) {
695 rajveer 2234
      this.gatewayId = gatewayId;
2235
      setGatewayIdIsSet(true);
123 ashish 2236
    }
2237
 
695 rajveer 2238
    public void unsetGatewayId() {
2239
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 2240
    }
2241
 
3430 rajveer 2242
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 2243
    public boolean isSetGatewayId() {
2244
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 2245
    }
2246
 
695 rajveer 2247
    public void setGatewayIdIsSet(boolean value) {
2248
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 2249
    }
2250
 
695 rajveer 2251
    public long getTxnId() {
2252
      return this.txnId;
2253
    }
2254
 
3430 rajveer 2255
    public void setTxnId(long txnId) {
695 rajveer 2256
      this.txnId = txnId;
2257
      setTxnIdIsSet(true);
2258
    }
2259
 
2260
    public void unsetTxnId() {
2261
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
2262
    }
2263
 
3430 rajveer 2264
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
695 rajveer 2265
    public boolean isSetTxnId() {
2266
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
2267
    }
2268
 
2269
    public void setTxnIdIsSet(boolean value) {
2270
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
2271
    }
2272
 
6050 anupam.sin 2273
    public boolean isIsDigital() {
2274
      return this.isDigital;
2275
    }
2276
 
2277
    public void setIsDigital(boolean isDigital) {
2278
      this.isDigital = isDigital;
2279
      setIsDigitalIsSet(true);
2280
    }
2281
 
2282
    public void unsetIsDigital() {
2283
      __isset_bit_vector.clear(__ISDIGITAL_ISSET_ID);
2284
    }
2285
 
2286
    /** Returns true if field isDigital is set (has been assigned a value) and false otherwise */
2287
    public boolean isSetIsDigital() {
2288
      return __isset_bit_vector.get(__ISDIGITAL_ISSET_ID);
2289
    }
2290
 
2291
    public void setIsDigitalIsSet(boolean value) {
2292
      __isset_bit_vector.set(__ISDIGITAL_ISSET_ID, value);
2293
    }
2294
 
123 ashish 2295
    public void setFieldValue(_Fields field, Object value) {
2296
      switch (field) {
2297
      case USER_ID:
2298
        if (value == null) {
695 rajveer 2299
          unsetUserId();
123 ashish 2300
        } else {
695 rajveer 2301
          setUserId((Long)value);
123 ashish 2302
        }
2303
        break;
2304
 
695 rajveer 2305
      case AMOUNT:
123 ashish 2306
        if (value == null) {
695 rajveer 2307
          unsetAmount();
123 ashish 2308
        } else {
695 rajveer 2309
          setAmount((Double)value);
123 ashish 2310
        }
2311
        break;
2312
 
695 rajveer 2313
      case GATEWAY_ID:
123 ashish 2314
        if (value == null) {
695 rajveer 2315
          unsetGatewayId();
123 ashish 2316
        } else {
695 rajveer 2317
          setGatewayId((Long)value);
123 ashish 2318
        }
2319
        break;
2320
 
695 rajveer 2321
      case TXN_ID:
123 ashish 2322
        if (value == null) {
695 rajveer 2323
          unsetTxnId();
123 ashish 2324
        } else {
695 rajveer 2325
          setTxnId((Long)value);
123 ashish 2326
        }
2327
        break;
2328
 
6050 anupam.sin 2329
      case IS_DIGITAL:
2330
        if (value == null) {
2331
          unsetIsDigital();
2332
        } else {
2333
          setIsDigital((Boolean)value);
2334
        }
2335
        break;
2336
 
123 ashish 2337
      }
2338
    }
2339
 
2340
    public Object getFieldValue(_Fields field) {
2341
      switch (field) {
2342
      case USER_ID:
3430 rajveer 2343
        return Long.valueOf(getUserId());
123 ashish 2344
 
2345
      case AMOUNT:
3430 rajveer 2346
        return Double.valueOf(getAmount());
123 ashish 2347
 
420 ashish 2348
      case GATEWAY_ID:
3430 rajveer 2349
        return Long.valueOf(getGatewayId());
123 ashish 2350
 
695 rajveer 2351
      case TXN_ID:
3430 rajveer 2352
        return Long.valueOf(getTxnId());
695 rajveer 2353
 
6050 anupam.sin 2354
      case IS_DIGITAL:
2355
        return Boolean.valueOf(isIsDigital());
2356
 
123 ashish 2357
      }
2358
      throw new IllegalStateException();
2359
    }
2360
 
3430 rajveer 2361
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2362
    public boolean isSet(_Fields field) {
2363
      if (field == null) {
2364
        throw new IllegalArgumentException();
2365
      }
123 ashish 2366
 
2367
      switch (field) {
2368
      case USER_ID:
695 rajveer 2369
        return isSetUserId();
123 ashish 2370
      case AMOUNT:
2371
        return isSetAmount();
420 ashish 2372
      case GATEWAY_ID:
695 rajveer 2373
        return isSetGatewayId();
2374
      case TXN_ID:
2375
        return isSetTxnId();
6050 anupam.sin 2376
      case IS_DIGITAL:
2377
        return isSetIsDigital();
123 ashish 2378
      }
2379
      throw new IllegalStateException();
2380
    }
2381
 
2382
    @Override
2383
    public boolean equals(Object that) {
2384
      if (that == null)
2385
        return false;
2386
      if (that instanceof createPayment_args)
2387
        return this.equals((createPayment_args)that);
2388
      return false;
2389
    }
2390
 
2391
    public boolean equals(createPayment_args that) {
2392
      if (that == null)
2393
        return false;
2394
 
695 rajveer 2395
      boolean this_present_userId = true;
2396
      boolean that_present_userId = true;
2397
      if (this_present_userId || that_present_userId) {
2398
        if (!(this_present_userId && that_present_userId))
123 ashish 2399
          return false;
695 rajveer 2400
        if (this.userId != that.userId)
123 ashish 2401
          return false;
2402
      }
2403
 
2404
      boolean this_present_amount = true;
2405
      boolean that_present_amount = true;
2406
      if (this_present_amount || that_present_amount) {
2407
        if (!(this_present_amount && that_present_amount))
2408
          return false;
2409
        if (this.amount != that.amount)
2410
          return false;
2411
      }
2412
 
695 rajveer 2413
      boolean this_present_gatewayId = true;
2414
      boolean that_present_gatewayId = true;
2415
      if (this_present_gatewayId || that_present_gatewayId) {
2416
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 2417
          return false;
695 rajveer 2418
        if (this.gatewayId != that.gatewayId)
123 ashish 2419
          return false;
2420
      }
2421
 
695 rajveer 2422
      boolean this_present_txnId = true;
2423
      boolean that_present_txnId = true;
2424
      if (this_present_txnId || that_present_txnId) {
2425
        if (!(this_present_txnId && that_present_txnId))
2426
          return false;
2427
        if (this.txnId != that.txnId)
2428
          return false;
2429
      }
2430
 
6050 anupam.sin 2431
      boolean this_present_isDigital = true;
2432
      boolean that_present_isDigital = true;
2433
      if (this_present_isDigital || that_present_isDigital) {
2434
        if (!(this_present_isDigital && that_present_isDigital))
2435
          return false;
2436
        if (this.isDigital != that.isDigital)
2437
          return false;
2438
      }
2439
 
123 ashish 2440
      return true;
2441
    }
2442
 
2443
    @Override
2444
    public int hashCode() {
2445
      return 0;
2446
    }
2447
 
2448
    public int compareTo(createPayment_args other) {
2449
      if (!getClass().equals(other.getClass())) {
2450
        return getClass().getName().compareTo(other.getClass().getName());
2451
      }
2452
 
2453
      int lastComparison = 0;
2454
      createPayment_args typedOther = (createPayment_args)other;
2455
 
3430 rajveer 2456
      lastComparison = Boolean.valueOf(isSetUserId()).compareTo(typedOther.isSetUserId());
123 ashish 2457
      if (lastComparison != 0) {
2458
        return lastComparison;
2459
      }
3430 rajveer 2460
      if (isSetUserId()) {
2461
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userId, typedOther.userId);
2462
        if (lastComparison != 0) {
2463
          return lastComparison;
2464
        }
123 ashish 2465
      }
3430 rajveer 2466
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
123 ashish 2467
      if (lastComparison != 0) {
2468
        return lastComparison;
2469
      }
3430 rajveer 2470
      if (isSetAmount()) {
2471
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
2472
        if (lastComparison != 0) {
2473
          return lastComparison;
2474
        }
123 ashish 2475
      }
3430 rajveer 2476
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 2477
      if (lastComparison != 0) {
2478
        return lastComparison;
2479
      }
3430 rajveer 2480
      if (isSetGatewayId()) {
2481
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
2482
        if (lastComparison != 0) {
2483
          return lastComparison;
2484
        }
123 ashish 2485
      }
3430 rajveer 2486
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
123 ashish 2487
      if (lastComparison != 0) {
2488
        return lastComparison;
2489
      }
3430 rajveer 2490
      if (isSetTxnId()) {
2491
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
2492
        if (lastComparison != 0) {
2493
          return lastComparison;
2494
        }
123 ashish 2495
      }
6050 anupam.sin 2496
      lastComparison = Boolean.valueOf(isSetIsDigital()).compareTo(typedOther.isSetIsDigital());
2497
      if (lastComparison != 0) {
2498
        return lastComparison;
2499
      }
2500
      if (isSetIsDigital()) {
2501
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isDigital, typedOther.isDigital);
2502
        if (lastComparison != 0) {
2503
          return lastComparison;
2504
        }
2505
      }
123 ashish 2506
      return 0;
2507
    }
2508
 
3430 rajveer 2509
    public _Fields fieldForId(int fieldId) {
2510
      return _Fields.findByThriftId(fieldId);
2511
    }
2512
 
2513
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2514
      org.apache.thrift.protocol.TField field;
123 ashish 2515
      iprot.readStructBegin();
2516
      while (true)
2517
      {
2518
        field = iprot.readFieldBegin();
3430 rajveer 2519
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 2520
          break;
2521
        }
3430 rajveer 2522
        switch (field.id) {
2523
          case 1: // USER_ID
2524
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2525
              this.userId = iprot.readI64();
2526
              setUserIdIsSet(true);
2527
            } else { 
2528
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2529
            }
2530
            break;
2531
          case 2: // AMOUNT
2532
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
2533
              this.amount = iprot.readDouble();
2534
              setAmountIsSet(true);
2535
            } else { 
2536
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2537
            }
2538
            break;
2539
          case 3: // GATEWAY_ID
2540
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2541
              this.gatewayId = iprot.readI64();
2542
              setGatewayIdIsSet(true);
2543
            } else { 
2544
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2545
            }
2546
            break;
2547
          case 4: // TXN_ID
2548
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2549
              this.txnId = iprot.readI64();
2550
              setTxnIdIsSet(true);
2551
            } else { 
2552
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2553
            }
2554
            break;
6050 anupam.sin 2555
          case 5: // IS_DIGITAL
2556
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
2557
              this.isDigital = iprot.readBool();
2558
              setIsDigitalIsSet(true);
2559
            } else { 
2560
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2561
            }
2562
            break;
3430 rajveer 2563
          default:
2564
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 2565
        }
3430 rajveer 2566
        iprot.readFieldEnd();
123 ashish 2567
      }
2568
      iprot.readStructEnd();
2569
      validate();
2570
    }
2571
 
3430 rajveer 2572
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 2573
      validate();
2574
 
2575
      oprot.writeStructBegin(STRUCT_DESC);
2576
      oprot.writeFieldBegin(USER_ID_FIELD_DESC);
695 rajveer 2577
      oprot.writeI64(this.userId);
123 ashish 2578
      oprot.writeFieldEnd();
2579
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
2580
      oprot.writeDouble(this.amount);
2581
      oprot.writeFieldEnd();
420 ashish 2582
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 2583
      oprot.writeI64(this.gatewayId);
420 ashish 2584
      oprot.writeFieldEnd();
695 rajveer 2585
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
2586
      oprot.writeI64(this.txnId);
2587
      oprot.writeFieldEnd();
6050 anupam.sin 2588
      oprot.writeFieldBegin(IS_DIGITAL_FIELD_DESC);
2589
      oprot.writeBool(this.isDigital);
2590
      oprot.writeFieldEnd();
123 ashish 2591
      oprot.writeFieldStop();
2592
      oprot.writeStructEnd();
2593
    }
2594
 
2595
    @Override
2596
    public String toString() {
2597
      StringBuilder sb = new StringBuilder("createPayment_args(");
2598
      boolean first = true;
2599
 
695 rajveer 2600
      sb.append("userId:");
2601
      sb.append(this.userId);
123 ashish 2602
      first = false;
2603
      if (!first) sb.append(", ");
2604
      sb.append("amount:");
2605
      sb.append(this.amount);
2606
      first = false;
2607
      if (!first) sb.append(", ");
695 rajveer 2608
      sb.append("gatewayId:");
2609
      sb.append(this.gatewayId);
123 ashish 2610
      first = false;
695 rajveer 2611
      if (!first) sb.append(", ");
2612
      sb.append("txnId:");
2613
      sb.append(this.txnId);
2614
      first = false;
6050 anupam.sin 2615
      if (!first) sb.append(", ");
2616
      sb.append("isDigital:");
2617
      sb.append(this.isDigital);
2618
      first = false;
123 ashish 2619
      sb.append(")");
2620
      return sb.toString();
2621
    }
2622
 
3430 rajveer 2623
    public void validate() throws org.apache.thrift.TException {
123 ashish 2624
      // check for required fields
2625
    }
2626
 
3430 rajveer 2627
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2628
      try {
2629
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2630
      } catch (org.apache.thrift.TException te) {
2631
        throw new java.io.IOException(te);
2632
      }
2633
    }
2634
 
2635
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2636
      try {
2637
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2638
      } catch (org.apache.thrift.TException te) {
2639
        throw new java.io.IOException(te);
2640
      }
2641
    }
2642
 
123 ashish 2643
  }
2644
 
3430 rajveer 2645
  public static class createPayment_result implements org.apache.thrift.TBase<createPayment_result, createPayment_result._Fields>, java.io.Serializable, Cloneable   {
2646
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPayment_result");
123 ashish 2647
 
3430 rajveer 2648
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I64, (short)0);
2649
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
123 ashish 2650
 
3430 rajveer 2651
    private long success; // required
2652
    private PaymentException pe; // required
123 ashish 2653
 
2654
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2655
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 2656
      SUCCESS((short)0, "success"),
2657
      PE((short)1, "pe");
2658
 
2659
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2660
 
2661
      static {
2662
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2663
          byName.put(field.getFieldName(), field);
2664
        }
2665
      }
2666
 
2667
      /**
2668
       * Find the _Fields constant that matches fieldId, or null if its not found.
2669
       */
2670
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2671
        switch(fieldId) {
2672
          case 0: // SUCCESS
2673
            return SUCCESS;
2674
          case 1: // PE
2675
            return PE;
2676
          default:
2677
            return null;
2678
        }
123 ashish 2679
      }
2680
 
2681
      /**
2682
       * Find the _Fields constant that matches fieldId, throwing an exception
2683
       * if it is not found.
2684
       */
2685
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2686
        _Fields fields = findByThriftId(fieldId);
2687
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2688
        return fields;
2689
      }
2690
 
2691
      /**
2692
       * Find the _Fields constant that matches name, or null if its not found.
2693
       */
2694
      public static _Fields findByName(String name) {
2695
        return byName.get(name);
2696
      }
2697
 
2698
      private final short _thriftId;
2699
      private final String _fieldName;
2700
 
2701
      _Fields(short thriftId, String fieldName) {
2702
        _thriftId = thriftId;
2703
        _fieldName = fieldName;
2704
      }
2705
 
2706
      public short getThriftFieldId() {
2707
        return _thriftId;
2708
      }
2709
 
2710
      public String getFieldName() {
2711
        return _fieldName;
2712
      }
2713
    }
2714
 
2715
    // isset id assignments
420 ashish 2716
    private static final int __SUCCESS_ISSET_ID = 0;
2717
    private BitSet __isset_bit_vector = new BitSet(1);
123 ashish 2718
 
3430 rajveer 2719
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 2720
    static {
3430 rajveer 2721
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2722
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2723
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2724
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2725
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
2726
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2727
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createPayment_result.class, metaDataMap);
123 ashish 2728
    }
2729
 
2730
    public createPayment_result() {
2731
    }
2732
 
2733
    public createPayment_result(
420 ashish 2734
      long success,
123 ashish 2735
      PaymentException pe)
2736
    {
2737
      this();
2738
      this.success = success;
420 ashish 2739
      setSuccessIsSet(true);
123 ashish 2740
      this.pe = pe;
2741
    }
2742
 
2743
    /**
2744
     * Performs a deep copy on <i>other</i>.
2745
     */
2746
    public createPayment_result(createPayment_result other) {
420 ashish 2747
      __isset_bit_vector.clear();
2748
      __isset_bit_vector.or(other.__isset_bit_vector);
2749
      this.success = other.success;
123 ashish 2750
      if (other.isSetPe()) {
2751
        this.pe = new PaymentException(other.pe);
2752
      }
2753
    }
2754
 
2755
    public createPayment_result deepCopy() {
2756
      return new createPayment_result(this);
2757
    }
2758
 
3430 rajveer 2759
    @Override
2760
    public void clear() {
2761
      setSuccessIsSet(false);
2762
      this.success = 0;
2763
      this.pe = null;
123 ashish 2764
    }
2765
 
420 ashish 2766
    public long getSuccess() {
123 ashish 2767
      return this.success;
2768
    }
2769
 
3430 rajveer 2770
    public void setSuccess(long success) {
123 ashish 2771
      this.success = success;
420 ashish 2772
      setSuccessIsSet(true);
123 ashish 2773
    }
2774
 
2775
    public void unsetSuccess() {
420 ashish 2776
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
123 ashish 2777
    }
2778
 
3430 rajveer 2779
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 2780
    public boolean isSetSuccess() {
420 ashish 2781
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
123 ashish 2782
    }
2783
 
2784
    public void setSuccessIsSet(boolean value) {
420 ashish 2785
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
123 ashish 2786
    }
2787
 
2788
    public PaymentException getPe() {
2789
      return this.pe;
2790
    }
2791
 
3430 rajveer 2792
    public void setPe(PaymentException pe) {
123 ashish 2793
      this.pe = pe;
2794
    }
2795
 
2796
    public void unsetPe() {
2797
      this.pe = null;
2798
    }
2799
 
3430 rajveer 2800
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 2801
    public boolean isSetPe() {
2802
      return this.pe != null;
2803
    }
2804
 
2805
    public void setPeIsSet(boolean value) {
2806
      if (!value) {
2807
        this.pe = null;
2808
      }
2809
    }
2810
 
2811
    public void setFieldValue(_Fields field, Object value) {
2812
      switch (field) {
2813
      case SUCCESS:
2814
        if (value == null) {
2815
          unsetSuccess();
2816
        } else {
420 ashish 2817
          setSuccess((Long)value);
123 ashish 2818
        }
2819
        break;
2820
 
2821
      case PE:
2822
        if (value == null) {
2823
          unsetPe();
2824
        } else {
2825
          setPe((PaymentException)value);
2826
        }
2827
        break;
2828
 
2829
      }
2830
    }
2831
 
2832
    public Object getFieldValue(_Fields field) {
2833
      switch (field) {
2834
      case SUCCESS:
3430 rajveer 2835
        return Long.valueOf(getSuccess());
123 ashish 2836
 
2837
      case PE:
2838
        return getPe();
2839
 
2840
      }
2841
      throw new IllegalStateException();
2842
    }
2843
 
3430 rajveer 2844
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2845
    public boolean isSet(_Fields field) {
2846
      if (field == null) {
2847
        throw new IllegalArgumentException();
2848
      }
123 ashish 2849
 
2850
      switch (field) {
2851
      case SUCCESS:
2852
        return isSetSuccess();
2853
      case PE:
2854
        return isSetPe();
2855
      }
2856
      throw new IllegalStateException();
2857
    }
2858
 
2859
    @Override
2860
    public boolean equals(Object that) {
2861
      if (that == null)
2862
        return false;
2863
      if (that instanceof createPayment_result)
2864
        return this.equals((createPayment_result)that);
2865
      return false;
2866
    }
2867
 
2868
    public boolean equals(createPayment_result that) {
2869
      if (that == null)
2870
        return false;
2871
 
420 ashish 2872
      boolean this_present_success = true;
2873
      boolean that_present_success = true;
123 ashish 2874
      if (this_present_success || that_present_success) {
2875
        if (!(this_present_success && that_present_success))
2876
          return false;
420 ashish 2877
        if (this.success != that.success)
123 ashish 2878
          return false;
2879
      }
2880
 
2881
      boolean this_present_pe = true && this.isSetPe();
2882
      boolean that_present_pe = true && that.isSetPe();
2883
      if (this_present_pe || that_present_pe) {
2884
        if (!(this_present_pe && that_present_pe))
2885
          return false;
2886
        if (!this.pe.equals(that.pe))
2887
          return false;
2888
      }
2889
 
2890
      return true;
2891
    }
2892
 
2893
    @Override
2894
    public int hashCode() {
2895
      return 0;
2896
    }
2897
 
420 ashish 2898
    public int compareTo(createPayment_result other) {
2899
      if (!getClass().equals(other.getClass())) {
2900
        return getClass().getName().compareTo(other.getClass().getName());
2901
      }
2902
 
2903
      int lastComparison = 0;
2904
      createPayment_result typedOther = (createPayment_result)other;
2905
 
3430 rajveer 2906
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
420 ashish 2907
      if (lastComparison != 0) {
2908
        return lastComparison;
2909
      }
3430 rajveer 2910
      if (isSetSuccess()) {
2911
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
2912
        if (lastComparison != 0) {
2913
          return lastComparison;
2914
        }
420 ashish 2915
      }
3430 rajveer 2916
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 2917
      if (lastComparison != 0) {
2918
        return lastComparison;
2919
      }
3430 rajveer 2920
      if (isSetPe()) {
2921
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
2922
        if (lastComparison != 0) {
2923
          return lastComparison;
2924
        }
420 ashish 2925
      }
2926
      return 0;
2927
    }
2928
 
3430 rajveer 2929
    public _Fields fieldForId(int fieldId) {
2930
      return _Fields.findByThriftId(fieldId);
2931
    }
2932
 
2933
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2934
      org.apache.thrift.protocol.TField field;
123 ashish 2935
      iprot.readStructBegin();
2936
      while (true)
2937
      {
2938
        field = iprot.readFieldBegin();
3430 rajveer 2939
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 2940
          break;
2941
        }
3430 rajveer 2942
        switch (field.id) {
2943
          case 0: // SUCCESS
2944
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2945
              this.success = iprot.readI64();
2946
              setSuccessIsSet(true);
2947
            } else { 
2948
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2949
            }
2950
            break;
2951
          case 1: // PE
2952
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
2953
              this.pe = new PaymentException();
2954
              this.pe.read(iprot);
2955
            } else { 
2956
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2957
            }
2958
            break;
2959
          default:
2960
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 2961
        }
3430 rajveer 2962
        iprot.readFieldEnd();
123 ashish 2963
      }
2964
      iprot.readStructEnd();
2965
      validate();
2966
    }
2967
 
3430 rajveer 2968
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 2969
      oprot.writeStructBegin(STRUCT_DESC);
2970
 
2971
      if (this.isSetSuccess()) {
2972
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
420 ashish 2973
        oprot.writeI64(this.success);
123 ashish 2974
        oprot.writeFieldEnd();
2975
      } else if (this.isSetPe()) {
2976
        oprot.writeFieldBegin(PE_FIELD_DESC);
2977
        this.pe.write(oprot);
2978
        oprot.writeFieldEnd();
2979
      }
2980
      oprot.writeFieldStop();
2981
      oprot.writeStructEnd();
2982
    }
2983
 
2984
    @Override
2985
    public String toString() {
2986
      StringBuilder sb = new StringBuilder("createPayment_result(");
2987
      boolean first = true;
2988
 
2989
      sb.append("success:");
420 ashish 2990
      sb.append(this.success);
123 ashish 2991
      first = false;
2992
      if (!first) sb.append(", ");
2993
      sb.append("pe:");
2994
      if (this.pe == null) {
2995
        sb.append("null");
2996
      } else {
2997
        sb.append(this.pe);
2998
      }
2999
      first = false;
3000
      sb.append(")");
3001
      return sb.toString();
3002
    }
3003
 
3430 rajveer 3004
    public void validate() throws org.apache.thrift.TException {
123 ashish 3005
      // check for required fields
3006
    }
3007
 
3430 rajveer 3008
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3009
      try {
3010
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3011
      } catch (org.apache.thrift.TException te) {
3012
        throw new java.io.IOException(te);
3013
      }
3014
    }
3015
 
3016
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3017
      try {
3018
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3019
      } catch (org.apache.thrift.TException te) {
3020
        throw new java.io.IOException(te);
3021
      }
3022
    }
3023
 
123 ashish 3024
  }
3025
 
3430 rajveer 3026
  public static class getPaymentsForUser_args implements org.apache.thrift.TBase<getPaymentsForUser_args, getPaymentsForUser_args._Fields>, java.io.Serializable, Cloneable   {
3027
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsForUser_args");
123 ashish 3028
 
3430 rajveer 3029
    private static final org.apache.thrift.protocol.TField USER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("userId", org.apache.thrift.protocol.TType.I64, (short)1);
3030
    private static final org.apache.thrift.protocol.TField FROM_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("fromTime", org.apache.thrift.protocol.TType.I64, (short)2);
3031
    private static final org.apache.thrift.protocol.TField TO_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("toTime", org.apache.thrift.protocol.TType.I64, (short)3);
3032
    private static final org.apache.thrift.protocol.TField STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("status", org.apache.thrift.protocol.TType.I32, (short)4);
3033
    private static final org.apache.thrift.protocol.TField GATEWAY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayId", org.apache.thrift.protocol.TType.I64, (short)5);
123 ashish 3034
 
3430 rajveer 3035
    private long userId; // required
3036
    private long fromTime; // required
3037
    private long toTime; // required
3038
    private PaymentStatus status; // required
3039
    private long gatewayId; // required
123 ashish 3040
 
3041
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3042
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 3043
      USER_ID((short)1, "userId"),
695 rajveer 3044
      FROM_TIME((short)2, "fromTime"),
3045
      TO_TIME((short)3, "toTime"),
123 ashish 3046
      /**
3047
       * 
3048
       * @see PaymentStatus
3049
       */
3050
      STATUS((short)4, "status"),
695 rajveer 3051
      GATEWAY_ID((short)5, "gatewayId");
123 ashish 3052
 
3053
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3054
 
3055
      static {
3056
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3057
          byName.put(field.getFieldName(), field);
3058
        }
3059
      }
3060
 
3061
      /**
3062
       * Find the _Fields constant that matches fieldId, or null if its not found.
3063
       */
3064
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3065
        switch(fieldId) {
3066
          case 1: // USER_ID
3067
            return USER_ID;
3068
          case 2: // FROM_TIME
3069
            return FROM_TIME;
3070
          case 3: // TO_TIME
3071
            return TO_TIME;
3072
          case 4: // STATUS
3073
            return STATUS;
3074
          case 5: // GATEWAY_ID
3075
            return GATEWAY_ID;
3076
          default:
3077
            return null;
3078
        }
123 ashish 3079
      }
3080
 
3081
      /**
3082
       * Find the _Fields constant that matches fieldId, throwing an exception
3083
       * if it is not found.
3084
       */
3085
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3086
        _Fields fields = findByThriftId(fieldId);
3087
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3088
        return fields;
3089
      }
3090
 
3091
      /**
3092
       * Find the _Fields constant that matches name, or null if its not found.
3093
       */
3094
      public static _Fields findByName(String name) {
3095
        return byName.get(name);
3096
      }
3097
 
3098
      private final short _thriftId;
3099
      private final String _fieldName;
3100
 
3101
      _Fields(short thriftId, String fieldName) {
3102
        _thriftId = thriftId;
3103
        _fieldName = fieldName;
3104
      }
3105
 
3106
      public short getThriftFieldId() {
3107
        return _thriftId;
3108
      }
3109
 
3110
      public String getFieldName() {
3111
        return _fieldName;
3112
      }
3113
    }
3114
 
3115
    // isset id assignments
3116
    private static final int __USERID_ISSET_ID = 0;
695 rajveer 3117
    private static final int __FROMTIME_ISSET_ID = 1;
3118
    private static final int __TOTIME_ISSET_ID = 2;
3119
    private static final int __GATEWAYID_ISSET_ID = 3;
420 ashish 3120
    private BitSet __isset_bit_vector = new BitSet(4);
123 ashish 3121
 
3430 rajveer 3122
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 3123
    static {
3430 rajveer 3124
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3125
      tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3126
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3127
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3128
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3129
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3130
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3131
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3132
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
3133
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3134
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3135
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3136
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsForUser_args.class, metaDataMap);
123 ashish 3137
    }
3138
 
3139
    public getPaymentsForUser_args() {
3140
    }
3141
 
3142
    public getPaymentsForUser_args(
3143
      long userId,
695 rajveer 3144
      long fromTime,
3145
      long toTime,
123 ashish 3146
      PaymentStatus status,
695 rajveer 3147
      long gatewayId)
123 ashish 3148
    {
3149
      this();
3150
      this.userId = userId;
3151
      setUserIdIsSet(true);
695 rajveer 3152
      this.fromTime = fromTime;
3153
      setFromTimeIsSet(true);
3154
      this.toTime = toTime;
3155
      setToTimeIsSet(true);
123 ashish 3156
      this.status = status;
695 rajveer 3157
      this.gatewayId = gatewayId;
3158
      setGatewayIdIsSet(true);
123 ashish 3159
    }
3160
 
3161
    /**
3162
     * Performs a deep copy on <i>other</i>.
3163
     */
3164
    public getPaymentsForUser_args(getPaymentsForUser_args other) {
3165
      __isset_bit_vector.clear();
3166
      __isset_bit_vector.or(other.__isset_bit_vector);
3167
      this.userId = other.userId;
695 rajveer 3168
      this.fromTime = other.fromTime;
3169
      this.toTime = other.toTime;
123 ashish 3170
      if (other.isSetStatus()) {
3171
        this.status = other.status;
3172
      }
695 rajveer 3173
      this.gatewayId = other.gatewayId;
123 ashish 3174
    }
3175
 
3176
    public getPaymentsForUser_args deepCopy() {
3177
      return new getPaymentsForUser_args(this);
3178
    }
3179
 
3430 rajveer 3180
    @Override
3181
    public void clear() {
3182
      setUserIdIsSet(false);
3183
      this.userId = 0;
3184
      setFromTimeIsSet(false);
3185
      this.fromTime = 0;
3186
      setToTimeIsSet(false);
3187
      this.toTime = 0;
3188
      this.status = null;
3189
      setGatewayIdIsSet(false);
3190
      this.gatewayId = 0;
123 ashish 3191
    }
3192
 
3193
    public long getUserId() {
3194
      return this.userId;
3195
    }
3196
 
3430 rajveer 3197
    public void setUserId(long userId) {
123 ashish 3198
      this.userId = userId;
3199
      setUserIdIsSet(true);
3200
    }
3201
 
3202
    public void unsetUserId() {
3203
      __isset_bit_vector.clear(__USERID_ISSET_ID);
3204
    }
3205
 
3430 rajveer 3206
    /** Returns true if field userId is set (has been assigned a value) and false otherwise */
123 ashish 3207
    public boolean isSetUserId() {
3208
      return __isset_bit_vector.get(__USERID_ISSET_ID);
3209
    }
3210
 
3211
    public void setUserIdIsSet(boolean value) {
3212
      __isset_bit_vector.set(__USERID_ISSET_ID, value);
3213
    }
3214
 
695 rajveer 3215
    public long getFromTime() {
3216
      return this.fromTime;
123 ashish 3217
    }
3218
 
3430 rajveer 3219
    public void setFromTime(long fromTime) {
695 rajveer 3220
      this.fromTime = fromTime;
3221
      setFromTimeIsSet(true);
123 ashish 3222
    }
3223
 
695 rajveer 3224
    public void unsetFromTime() {
3225
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
123 ashish 3226
    }
3227
 
3430 rajveer 3228
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
695 rajveer 3229
    public boolean isSetFromTime() {
3230
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
123 ashish 3231
    }
3232
 
695 rajveer 3233
    public void setFromTimeIsSet(boolean value) {
3234
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
123 ashish 3235
    }
3236
 
695 rajveer 3237
    public long getToTime() {
3238
      return this.toTime;
123 ashish 3239
    }
3240
 
3430 rajveer 3241
    public void setToTime(long toTime) {
695 rajveer 3242
      this.toTime = toTime;
3243
      setToTimeIsSet(true);
123 ashish 3244
    }
3245
 
695 rajveer 3246
    public void unsetToTime() {
3247
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
123 ashish 3248
    }
3249
 
3430 rajveer 3250
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
695 rajveer 3251
    public boolean isSetToTime() {
3252
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
123 ashish 3253
    }
3254
 
695 rajveer 3255
    public void setToTimeIsSet(boolean value) {
3256
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
123 ashish 3257
    }
3258
 
3259
    /**
3260
     * 
3261
     * @see PaymentStatus
3262
     */
3263
    public PaymentStatus getStatus() {
3264
      return this.status;
3265
    }
3266
 
3267
    /**
3268
     * 
3269
     * @see PaymentStatus
3270
     */
3430 rajveer 3271
    public void setStatus(PaymentStatus status) {
123 ashish 3272
      this.status = status;
3273
    }
3274
 
3275
    public void unsetStatus() {
3276
      this.status = null;
3277
    }
3278
 
3430 rajveer 3279
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
123 ashish 3280
    public boolean isSetStatus() {
3281
      return this.status != null;
3282
    }
3283
 
3284
    public void setStatusIsSet(boolean value) {
3285
      if (!value) {
3286
        this.status = null;
3287
      }
3288
    }
3289
 
695 rajveer 3290
    public long getGatewayId() {
3291
      return this.gatewayId;
123 ashish 3292
    }
3293
 
3430 rajveer 3294
    public void setGatewayId(long gatewayId) {
695 rajveer 3295
      this.gatewayId = gatewayId;
3296
      setGatewayIdIsSet(true);
123 ashish 3297
    }
3298
 
695 rajveer 3299
    public void unsetGatewayId() {
3300
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 3301
    }
3302
 
3430 rajveer 3303
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 3304
    public boolean isSetGatewayId() {
3305
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 3306
    }
3307
 
695 rajveer 3308
    public void setGatewayIdIsSet(boolean value) {
3309
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 3310
    }
3311
 
3312
    public void setFieldValue(_Fields field, Object value) {
3313
      switch (field) {
3314
      case USER_ID:
3315
        if (value == null) {
3316
          unsetUserId();
3317
        } else {
3318
          setUserId((Long)value);
3319
        }
3320
        break;
3321
 
3322
      case FROM_TIME:
3323
        if (value == null) {
695 rajveer 3324
          unsetFromTime();
123 ashish 3325
        } else {
695 rajveer 3326
          setFromTime((Long)value);
123 ashish 3327
        }
3328
        break;
3329
 
3330
      case TO_TIME:
3331
        if (value == null) {
695 rajveer 3332
          unsetToTime();
123 ashish 3333
        } else {
695 rajveer 3334
          setToTime((Long)value);
123 ashish 3335
        }
3336
        break;
3337
 
3338
      case STATUS:
3339
        if (value == null) {
3340
          unsetStatus();
3341
        } else {
3342
          setStatus((PaymentStatus)value);
3343
        }
3344
        break;
3345
 
420 ashish 3346
      case GATEWAY_ID:
123 ashish 3347
        if (value == null) {
695 rajveer 3348
          unsetGatewayId();
123 ashish 3349
        } else {
695 rajveer 3350
          setGatewayId((Long)value);
123 ashish 3351
        }
3352
        break;
3353
 
3354
      }
3355
    }
3356
 
3357
    public Object getFieldValue(_Fields field) {
3358
      switch (field) {
3359
      case USER_ID:
3430 rajveer 3360
        return Long.valueOf(getUserId());
123 ashish 3361
 
3362
      case FROM_TIME:
3430 rajveer 3363
        return Long.valueOf(getFromTime());
123 ashish 3364
 
3365
      case TO_TIME:
3430 rajveer 3366
        return Long.valueOf(getToTime());
123 ashish 3367
 
3368
      case STATUS:
3369
        return getStatus();
3370
 
420 ashish 3371
      case GATEWAY_ID:
3430 rajveer 3372
        return Long.valueOf(getGatewayId());
123 ashish 3373
 
3374
      }
3375
      throw new IllegalStateException();
3376
    }
3377
 
3430 rajveer 3378
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3379
    public boolean isSet(_Fields field) {
3380
      if (field == null) {
3381
        throw new IllegalArgumentException();
3382
      }
123 ashish 3383
 
3384
      switch (field) {
3385
      case USER_ID:
3386
        return isSetUserId();
3387
      case FROM_TIME:
695 rajveer 3388
        return isSetFromTime();
123 ashish 3389
      case TO_TIME:
695 rajveer 3390
        return isSetToTime();
123 ashish 3391
      case STATUS:
3392
        return isSetStatus();
420 ashish 3393
      case GATEWAY_ID:
695 rajveer 3394
        return isSetGatewayId();
123 ashish 3395
      }
3396
      throw new IllegalStateException();
3397
    }
3398
 
3399
    @Override
3400
    public boolean equals(Object that) {
3401
      if (that == null)
3402
        return false;
3403
      if (that instanceof getPaymentsForUser_args)
3404
        return this.equals((getPaymentsForUser_args)that);
3405
      return false;
3406
    }
3407
 
3408
    public boolean equals(getPaymentsForUser_args that) {
3409
      if (that == null)
3410
        return false;
3411
 
3412
      boolean this_present_userId = true;
3413
      boolean that_present_userId = true;
3414
      if (this_present_userId || that_present_userId) {
3415
        if (!(this_present_userId && that_present_userId))
3416
          return false;
3417
        if (this.userId != that.userId)
3418
          return false;
3419
      }
3420
 
695 rajveer 3421
      boolean this_present_fromTime = true;
3422
      boolean that_present_fromTime = true;
3423
      if (this_present_fromTime || that_present_fromTime) {
3424
        if (!(this_present_fromTime && that_present_fromTime))
123 ashish 3425
          return false;
695 rajveer 3426
        if (this.fromTime != that.fromTime)
123 ashish 3427
          return false;
3428
      }
3429
 
695 rajveer 3430
      boolean this_present_toTime = true;
3431
      boolean that_present_toTime = true;
3432
      if (this_present_toTime || that_present_toTime) {
3433
        if (!(this_present_toTime && that_present_toTime))
123 ashish 3434
          return false;
695 rajveer 3435
        if (this.toTime != that.toTime)
123 ashish 3436
          return false;
3437
      }
3438
 
3439
      boolean this_present_status = true && this.isSetStatus();
3440
      boolean that_present_status = true && that.isSetStatus();
3441
      if (this_present_status || that_present_status) {
3442
        if (!(this_present_status && that_present_status))
3443
          return false;
3444
        if (!this.status.equals(that.status))
3445
          return false;
3446
      }
3447
 
695 rajveer 3448
      boolean this_present_gatewayId = true;
3449
      boolean that_present_gatewayId = true;
3450
      if (this_present_gatewayId || that_present_gatewayId) {
3451
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 3452
          return false;
695 rajveer 3453
        if (this.gatewayId != that.gatewayId)
123 ashish 3454
          return false;
3455
      }
3456
 
3457
      return true;
3458
    }
3459
 
3460
    @Override
3461
    public int hashCode() {
3462
      return 0;
3463
    }
3464
 
3465
    public int compareTo(getPaymentsForUser_args other) {
3466
      if (!getClass().equals(other.getClass())) {
3467
        return getClass().getName().compareTo(other.getClass().getName());
3468
      }
3469
 
3470
      int lastComparison = 0;
3471
      getPaymentsForUser_args typedOther = (getPaymentsForUser_args)other;
3472
 
3430 rajveer 3473
      lastComparison = Boolean.valueOf(isSetUserId()).compareTo(typedOther.isSetUserId());
123 ashish 3474
      if (lastComparison != 0) {
3475
        return lastComparison;
3476
      }
3430 rajveer 3477
      if (isSetUserId()) {
3478
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userId, typedOther.userId);
3479
        if (lastComparison != 0) {
3480
          return lastComparison;
3481
        }
123 ashish 3482
      }
3430 rajveer 3483
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
123 ashish 3484
      if (lastComparison != 0) {
3485
        return lastComparison;
3486
      }
3430 rajveer 3487
      if (isSetFromTime()) {
3488
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
3489
        if (lastComparison != 0) {
3490
          return lastComparison;
3491
        }
123 ashish 3492
      }
3430 rajveer 3493
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
123 ashish 3494
      if (lastComparison != 0) {
3495
        return lastComparison;
3496
      }
3430 rajveer 3497
      if (isSetToTime()) {
3498
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
3499
        if (lastComparison != 0) {
3500
          return lastComparison;
3501
        }
123 ashish 3502
      }
3430 rajveer 3503
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
123 ashish 3504
      if (lastComparison != 0) {
3505
        return lastComparison;
3506
      }
3430 rajveer 3507
      if (isSetStatus()) {
3508
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
3509
        if (lastComparison != 0) {
3510
          return lastComparison;
3511
        }
123 ashish 3512
      }
3430 rajveer 3513
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 3514
      if (lastComparison != 0) {
3515
        return lastComparison;
3516
      }
3430 rajveer 3517
      if (isSetGatewayId()) {
3518
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
3519
        if (lastComparison != 0) {
3520
          return lastComparison;
3521
        }
123 ashish 3522
      }
3523
      return 0;
3524
    }
3525
 
3430 rajveer 3526
    public _Fields fieldForId(int fieldId) {
3527
      return _Fields.findByThriftId(fieldId);
3528
    }
3529
 
3530
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3531
      org.apache.thrift.protocol.TField field;
123 ashish 3532
      iprot.readStructBegin();
3533
      while (true)
3534
      {
3535
        field = iprot.readFieldBegin();
3430 rajveer 3536
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 3537
          break;
3538
        }
3430 rajveer 3539
        switch (field.id) {
3540
          case 1: // USER_ID
3541
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3542
              this.userId = iprot.readI64();
3543
              setUserIdIsSet(true);
3544
            } else { 
3545
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3546
            }
3547
            break;
3548
          case 2: // FROM_TIME
3549
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3550
              this.fromTime = iprot.readI64();
3551
              setFromTimeIsSet(true);
3552
            } else { 
3553
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3554
            }
3555
            break;
3556
          case 3: // TO_TIME
3557
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3558
              this.toTime = iprot.readI64();
3559
              setToTimeIsSet(true);
3560
            } else { 
3561
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3562
            }
3563
            break;
3564
          case 4: // STATUS
3565
            if (field.type == org.apache.thrift.protocol.TType.I32) {
3566
              this.status = PaymentStatus.findByValue(iprot.readI32());
3567
            } else { 
3568
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3569
            }
3570
            break;
3571
          case 5: // GATEWAY_ID
3572
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3573
              this.gatewayId = iprot.readI64();
3574
              setGatewayIdIsSet(true);
3575
            } else { 
3576
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3577
            }
3578
            break;
3579
          default:
3580
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 3581
        }
3430 rajveer 3582
        iprot.readFieldEnd();
123 ashish 3583
      }
3584
      iprot.readStructEnd();
3585
      validate();
3586
    }
3587
 
3430 rajveer 3588
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 3589
      validate();
3590
 
3591
      oprot.writeStructBegin(STRUCT_DESC);
3592
      oprot.writeFieldBegin(USER_ID_FIELD_DESC);
3593
      oprot.writeI64(this.userId);
3594
      oprot.writeFieldEnd();
3595
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
695 rajveer 3596
      oprot.writeI64(this.fromTime);
123 ashish 3597
      oprot.writeFieldEnd();
3598
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
695 rajveer 3599
      oprot.writeI64(this.toTime);
123 ashish 3600
      oprot.writeFieldEnd();
3601
      if (this.status != null) {
3602
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
3603
        oprot.writeI32(this.status.getValue());
3604
        oprot.writeFieldEnd();
3605
      }
420 ashish 3606
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 3607
      oprot.writeI64(this.gatewayId);
420 ashish 3608
      oprot.writeFieldEnd();
123 ashish 3609
      oprot.writeFieldStop();
3610
      oprot.writeStructEnd();
3611
    }
3612
 
3613
    @Override
3614
    public String toString() {
3615
      StringBuilder sb = new StringBuilder("getPaymentsForUser_args(");
3616
      boolean first = true;
3617
 
3618
      sb.append("userId:");
3619
      sb.append(this.userId);
3620
      first = false;
3621
      if (!first) sb.append(", ");
695 rajveer 3622
      sb.append("fromTime:");
3623
      sb.append(this.fromTime);
123 ashish 3624
      first = false;
3625
      if (!first) sb.append(", ");
695 rajveer 3626
      sb.append("toTime:");
3627
      sb.append(this.toTime);
123 ashish 3628
      first = false;
3629
      if (!first) sb.append(", ");
3630
      sb.append("status:");
3631
      if (this.status == null) {
3632
        sb.append("null");
3633
      } else {
3634
        sb.append(this.status);
3635
      }
3636
      first = false;
3637
      if (!first) sb.append(", ");
695 rajveer 3638
      sb.append("gatewayId:");
3639
      sb.append(this.gatewayId);
123 ashish 3640
      first = false;
3641
      sb.append(")");
3642
      return sb.toString();
3643
    }
3644
 
3430 rajveer 3645
    public void validate() throws org.apache.thrift.TException {
123 ashish 3646
      // check for required fields
3647
    }
3648
 
3430 rajveer 3649
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3650
      try {
3651
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3652
      } catch (org.apache.thrift.TException te) {
3653
        throw new java.io.IOException(te);
3654
      }
3655
    }
3656
 
3657
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3658
      try {
3659
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3660
      } catch (org.apache.thrift.TException te) {
3661
        throw new java.io.IOException(te);
3662
      }
3663
    }
3664
 
123 ashish 3665
  }
3666
 
3430 rajveer 3667
  public static class getPaymentsForUser_result implements org.apache.thrift.TBase<getPaymentsForUser_result, getPaymentsForUser_result._Fields>, java.io.Serializable, Cloneable   {
3668
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsForUser_result");
123 ashish 3669
 
3430 rajveer 3670
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
3671
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
123 ashish 3672
 
3430 rajveer 3673
    private List<Payment> success; // required
3674
    private PaymentException pe; // required
123 ashish 3675
 
3676
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3677
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 3678
      SUCCESS((short)0, "success"),
3679
      PE((short)1, "pe");
3680
 
3681
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3682
 
3683
      static {
3684
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3685
          byName.put(field.getFieldName(), field);
3686
        }
3687
      }
3688
 
3689
      /**
3690
       * Find the _Fields constant that matches fieldId, or null if its not found.
3691
       */
3692
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3693
        switch(fieldId) {
3694
          case 0: // SUCCESS
3695
            return SUCCESS;
3696
          case 1: // PE
3697
            return PE;
3698
          default:
3699
            return null;
3700
        }
123 ashish 3701
      }
3702
 
3703
      /**
3704
       * Find the _Fields constant that matches fieldId, throwing an exception
3705
       * if it is not found.
3706
       */
3707
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3708
        _Fields fields = findByThriftId(fieldId);
3709
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3710
        return fields;
3711
      }
3712
 
3713
      /**
3714
       * Find the _Fields constant that matches name, or null if its not found.
3715
       */
3716
      public static _Fields findByName(String name) {
3717
        return byName.get(name);
3718
      }
3719
 
3720
      private final short _thriftId;
3721
      private final String _fieldName;
3722
 
3723
      _Fields(short thriftId, String fieldName) {
3724
        _thriftId = thriftId;
3725
        _fieldName = fieldName;
3726
      }
3727
 
3728
      public short getThriftFieldId() {
3729
        return _thriftId;
3730
      }
3731
 
3732
      public String getFieldName() {
3733
        return _fieldName;
3734
      }
3735
    }
3736
 
3737
    // isset id assignments
3738
 
3430 rajveer 3739
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 3740
    static {
3430 rajveer 3741
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3742
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3743
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
3744
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
3745
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3746
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3747
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3748
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsForUser_result.class, metaDataMap);
123 ashish 3749
    }
3750
 
3751
    public getPaymentsForUser_result() {
3752
    }
3753
 
3754
    public getPaymentsForUser_result(
3755
      List<Payment> success,
3756
      PaymentException pe)
3757
    {
3758
      this();
3759
      this.success = success;
3760
      this.pe = pe;
3761
    }
3762
 
3763
    /**
3764
     * Performs a deep copy on <i>other</i>.
3765
     */
3766
    public getPaymentsForUser_result(getPaymentsForUser_result other) {
3767
      if (other.isSetSuccess()) {
3768
        List<Payment> __this__success = new ArrayList<Payment>();
3769
        for (Payment other_element : other.success) {
3770
          __this__success.add(new Payment(other_element));
3771
        }
3772
        this.success = __this__success;
3773
      }
3774
      if (other.isSetPe()) {
3775
        this.pe = new PaymentException(other.pe);
3776
      }
3777
    }
3778
 
3779
    public getPaymentsForUser_result deepCopy() {
3780
      return new getPaymentsForUser_result(this);
3781
    }
3782
 
3430 rajveer 3783
    @Override
3784
    public void clear() {
3785
      this.success = null;
3786
      this.pe = null;
123 ashish 3787
    }
3788
 
3789
    public int getSuccessSize() {
3790
      return (this.success == null) ? 0 : this.success.size();
3791
    }
3792
 
3793
    public java.util.Iterator<Payment> getSuccessIterator() {
3794
      return (this.success == null) ? null : this.success.iterator();
3795
    }
3796
 
3797
    public void addToSuccess(Payment elem) {
3798
      if (this.success == null) {
3799
        this.success = new ArrayList<Payment>();
3800
      }
3801
      this.success.add(elem);
3802
    }
3803
 
3804
    public List<Payment> getSuccess() {
3805
      return this.success;
3806
    }
3807
 
3430 rajveer 3808
    public void setSuccess(List<Payment> success) {
123 ashish 3809
      this.success = success;
3810
    }
3811
 
3812
    public void unsetSuccess() {
3813
      this.success = null;
3814
    }
3815
 
3430 rajveer 3816
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 3817
    public boolean isSetSuccess() {
3818
      return this.success != null;
3819
    }
3820
 
3821
    public void setSuccessIsSet(boolean value) {
3822
      if (!value) {
3823
        this.success = null;
3824
      }
3825
    }
3826
 
3827
    public PaymentException getPe() {
3828
      return this.pe;
3829
    }
3830
 
3430 rajveer 3831
    public void setPe(PaymentException pe) {
123 ashish 3832
      this.pe = pe;
3833
    }
3834
 
3835
    public void unsetPe() {
3836
      this.pe = null;
3837
    }
3838
 
3430 rajveer 3839
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 3840
    public boolean isSetPe() {
3841
      return this.pe != null;
3842
    }
3843
 
3844
    public void setPeIsSet(boolean value) {
3845
      if (!value) {
3846
        this.pe = null;
3847
      }
3848
    }
3849
 
3850
    public void setFieldValue(_Fields field, Object value) {
3851
      switch (field) {
3852
      case SUCCESS:
3853
        if (value == null) {
3854
          unsetSuccess();
3855
        } else {
3856
          setSuccess((List<Payment>)value);
3857
        }
3858
        break;
3859
 
3860
      case PE:
3861
        if (value == null) {
3862
          unsetPe();
3863
        } else {
3864
          setPe((PaymentException)value);
3865
        }
3866
        break;
3867
 
3868
      }
3869
    }
3870
 
3871
    public Object getFieldValue(_Fields field) {
3872
      switch (field) {
3873
      case SUCCESS:
3874
        return getSuccess();
3875
 
3876
      case PE:
3877
        return getPe();
3878
 
3879
      }
3880
      throw new IllegalStateException();
3881
    }
3882
 
3430 rajveer 3883
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3884
    public boolean isSet(_Fields field) {
3885
      if (field == null) {
3886
        throw new IllegalArgumentException();
3887
      }
123 ashish 3888
 
3889
      switch (field) {
3890
      case SUCCESS:
3891
        return isSetSuccess();
3892
      case PE:
3893
        return isSetPe();
3894
      }
3895
      throw new IllegalStateException();
3896
    }
3897
 
3898
    @Override
3899
    public boolean equals(Object that) {
3900
      if (that == null)
3901
        return false;
3902
      if (that instanceof getPaymentsForUser_result)
3903
        return this.equals((getPaymentsForUser_result)that);
3904
      return false;
3905
    }
3906
 
3907
    public boolean equals(getPaymentsForUser_result that) {
3908
      if (that == null)
3909
        return false;
3910
 
3911
      boolean this_present_success = true && this.isSetSuccess();
3912
      boolean that_present_success = true && that.isSetSuccess();
3913
      if (this_present_success || that_present_success) {
3914
        if (!(this_present_success && that_present_success))
3915
          return false;
3916
        if (!this.success.equals(that.success))
3917
          return false;
3918
      }
3919
 
3920
      boolean this_present_pe = true && this.isSetPe();
3921
      boolean that_present_pe = true && that.isSetPe();
3922
      if (this_present_pe || that_present_pe) {
3923
        if (!(this_present_pe && that_present_pe))
3924
          return false;
3925
        if (!this.pe.equals(that.pe))
3926
          return false;
3927
      }
3928
 
3929
      return true;
3930
    }
3931
 
3932
    @Override
3933
    public int hashCode() {
3934
      return 0;
3935
    }
3936
 
695 rajveer 3937
    public int compareTo(getPaymentsForUser_result other) {
123 ashish 3938
      if (!getClass().equals(other.getClass())) {
3939
        return getClass().getName().compareTo(other.getClass().getName());
3940
      }
3941
 
3942
      int lastComparison = 0;
695 rajveer 3943
      getPaymentsForUser_result typedOther = (getPaymentsForUser_result)other;
123 ashish 3944
 
3430 rajveer 3945
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
123 ashish 3946
      if (lastComparison != 0) {
3947
        return lastComparison;
3948
      }
3430 rajveer 3949
      if (isSetSuccess()) {
3950
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3951
        if (lastComparison != 0) {
3952
          return lastComparison;
3953
        }
123 ashish 3954
      }
3430 rajveer 3955
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
123 ashish 3956
      if (lastComparison != 0) {
3957
        return lastComparison;
3958
      }
3430 rajveer 3959
      if (isSetPe()) {
3960
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
3961
        if (lastComparison != 0) {
3962
          return lastComparison;
3963
        }
123 ashish 3964
      }
3965
      return 0;
3966
    }
3967
 
3430 rajveer 3968
    public _Fields fieldForId(int fieldId) {
3969
      return _Fields.findByThriftId(fieldId);
3970
    }
3971
 
3972
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3973
      org.apache.thrift.protocol.TField field;
123 ashish 3974
      iprot.readStructBegin();
3975
      while (true)
3976
      {
3977
        field = iprot.readFieldBegin();
3430 rajveer 3978
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 3979
          break;
3980
        }
3430 rajveer 3981
        switch (field.id) {
3982
          case 0: // SUCCESS
3983
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
3984
              {
3985
                org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
3986
                this.success = new ArrayList<Payment>(_list12.size);
3987
                for (int _i13 = 0; _i13 < _list12.size; ++_i13)
123 ashish 3988
                {
3430 rajveer 3989
                  Payment _elem14; // required
3990
                  _elem14 = new Payment();
3991
                  _elem14.read(iprot);
3992
                  this.success.add(_elem14);
123 ashish 3993
                }
3430 rajveer 3994
                iprot.readListEnd();
123 ashish 3995
              }
3430 rajveer 3996
            } else { 
3997
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3998
            }
3999
            break;
4000
          case 1: // PE
4001
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4002
              this.pe = new PaymentException();
4003
              this.pe.read(iprot);
4004
            } else { 
4005
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4006
            }
4007
            break;
4008
          default:
4009
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 4010
        }
3430 rajveer 4011
        iprot.readFieldEnd();
123 ashish 4012
      }
4013
      iprot.readStructEnd();
4014
      validate();
4015
    }
4016
 
3430 rajveer 4017
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 4018
      oprot.writeStructBegin(STRUCT_DESC);
4019
 
4020
      if (this.isSetSuccess()) {
4021
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4022
        {
3430 rajveer 4023
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
2747 chandransh 4024
          for (Payment _iter15 : this.success)
123 ashish 4025
          {
2747 chandransh 4026
            _iter15.write(oprot);
123 ashish 4027
          }
4028
          oprot.writeListEnd();
4029
        }
4030
        oprot.writeFieldEnd();
4031
      } else if (this.isSetPe()) {
4032
        oprot.writeFieldBegin(PE_FIELD_DESC);
4033
        this.pe.write(oprot);
4034
        oprot.writeFieldEnd();
4035
      }
4036
      oprot.writeFieldStop();
4037
      oprot.writeStructEnd();
4038
    }
4039
 
4040
    @Override
4041
    public String toString() {
695 rajveer 4042
      StringBuilder sb = new StringBuilder("getPaymentsForUser_result(");
123 ashish 4043
      boolean first = true;
4044
 
4045
      sb.append("success:");
4046
      if (this.success == null) {
4047
        sb.append("null");
4048
      } else {
4049
        sb.append(this.success);
4050
      }
4051
      first = false;
4052
      if (!first) sb.append(", ");
4053
      sb.append("pe:");
4054
      if (this.pe == null) {
4055
        sb.append("null");
4056
      } else {
4057
        sb.append(this.pe);
4058
      }
4059
      first = false;
4060
      sb.append(")");
4061
      return sb.toString();
4062
    }
4063
 
3430 rajveer 4064
    public void validate() throws org.apache.thrift.TException {
123 ashish 4065
      // check for required fields
4066
    }
4067
 
3430 rajveer 4068
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4069
      try {
4070
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4071
      } catch (org.apache.thrift.TException te) {
4072
        throw new java.io.IOException(te);
4073
      }
4074
    }
4075
 
4076
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4077
      try {
4078
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4079
      } catch (org.apache.thrift.TException te) {
4080
        throw new java.io.IOException(te);
4081
      }
4082
    }
4083
 
123 ashish 4084
  }
4085
 
3430 rajveer 4086
  public static class getPayments_args implements org.apache.thrift.TBase<getPayments_args, getPayments_args._Fields>, java.io.Serializable, Cloneable   {
4087
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayments_args");
123 ashish 4088
 
3430 rajveer 4089
    private static final org.apache.thrift.protocol.TField FROM_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("fromTime", org.apache.thrift.protocol.TType.I64, (short)1);
4090
    private static final org.apache.thrift.protocol.TField TO_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("toTime", org.apache.thrift.protocol.TType.I64, (short)2);
4091
    private static final org.apache.thrift.protocol.TField STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("status", org.apache.thrift.protocol.TType.I32, (short)3);
4092
    private static final org.apache.thrift.protocol.TField GATEWAY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayId", org.apache.thrift.protocol.TType.I64, (short)4);
123 ashish 4093
 
3430 rajveer 4094
    private long fromTime; // required
4095
    private long toTime; // required
4096
    private PaymentStatus status; // required
4097
    private long gatewayId; // required
123 ashish 4098
 
4099
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4100
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 4101
      FROM_TIME((short)1, "fromTime"),
4102
      TO_TIME((short)2, "toTime"),
123 ashish 4103
      /**
4104
       * 
4105
       * @see PaymentStatus
4106
       */
4107
      STATUS((short)3, "status"),
695 rajveer 4108
      GATEWAY_ID((short)4, "gatewayId");
123 ashish 4109
 
4110
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4111
 
4112
      static {
4113
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4114
          byName.put(field.getFieldName(), field);
4115
        }
4116
      }
4117
 
4118
      /**
4119
       * Find the _Fields constant that matches fieldId, or null if its not found.
4120
       */
4121
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4122
        switch(fieldId) {
4123
          case 1: // FROM_TIME
4124
            return FROM_TIME;
4125
          case 2: // TO_TIME
4126
            return TO_TIME;
4127
          case 3: // STATUS
4128
            return STATUS;
4129
          case 4: // GATEWAY_ID
4130
            return GATEWAY_ID;
4131
          default:
4132
            return null;
4133
        }
123 ashish 4134
      }
4135
 
4136
      /**
4137
       * Find the _Fields constant that matches fieldId, throwing an exception
4138
       * if it is not found.
4139
       */
4140
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4141
        _Fields fields = findByThriftId(fieldId);
4142
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4143
        return fields;
4144
      }
4145
 
4146
      /**
4147
       * Find the _Fields constant that matches name, or null if its not found.
4148
       */
4149
      public static _Fields findByName(String name) {
4150
        return byName.get(name);
4151
      }
4152
 
4153
      private final short _thriftId;
4154
      private final String _fieldName;
4155
 
4156
      _Fields(short thriftId, String fieldName) {
4157
        _thriftId = thriftId;
4158
        _fieldName = fieldName;
4159
      }
4160
 
4161
      public short getThriftFieldId() {
4162
        return _thriftId;
4163
      }
4164
 
4165
      public String getFieldName() {
4166
        return _fieldName;
4167
      }
4168
    }
4169
 
4170
    // isset id assignments
695 rajveer 4171
    private static final int __FROMTIME_ISSET_ID = 0;
4172
    private static final int __TOTIME_ISSET_ID = 1;
4173
    private static final int __GATEWAYID_ISSET_ID = 2;
420 ashish 4174
    private BitSet __isset_bit_vector = new BitSet(3);
123 ashish 4175
 
3430 rajveer 4176
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 4177
    static {
3430 rajveer 4178
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4179
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4180
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4181
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4182
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4183
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4184
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
4185
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4186
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4187
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4188
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayments_args.class, metaDataMap);
123 ashish 4189
    }
4190
 
4191
    public getPayments_args() {
4192
    }
4193
 
4194
    public getPayments_args(
695 rajveer 4195
      long fromTime,
4196
      long toTime,
123 ashish 4197
      PaymentStatus status,
695 rajveer 4198
      long gatewayId)
123 ashish 4199
    {
4200
      this();
695 rajveer 4201
      this.fromTime = fromTime;
4202
      setFromTimeIsSet(true);
4203
      this.toTime = toTime;
4204
      setToTimeIsSet(true);
123 ashish 4205
      this.status = status;
695 rajveer 4206
      this.gatewayId = gatewayId;
4207
      setGatewayIdIsSet(true);
123 ashish 4208
    }
4209
 
4210
    /**
4211
     * Performs a deep copy on <i>other</i>.
4212
     */
4213
    public getPayments_args(getPayments_args other) {
4214
      __isset_bit_vector.clear();
4215
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 4216
      this.fromTime = other.fromTime;
4217
      this.toTime = other.toTime;
123 ashish 4218
      if (other.isSetStatus()) {
4219
        this.status = other.status;
4220
      }
695 rajveer 4221
      this.gatewayId = other.gatewayId;
123 ashish 4222
    }
4223
 
4224
    public getPayments_args deepCopy() {
4225
      return new getPayments_args(this);
4226
    }
4227
 
3430 rajveer 4228
    @Override
4229
    public void clear() {
4230
      setFromTimeIsSet(false);
4231
      this.fromTime = 0;
4232
      setToTimeIsSet(false);
4233
      this.toTime = 0;
4234
      this.status = null;
4235
      setGatewayIdIsSet(false);
4236
      this.gatewayId = 0;
123 ashish 4237
    }
4238
 
695 rajveer 4239
    public long getFromTime() {
4240
      return this.fromTime;
123 ashish 4241
    }
4242
 
3430 rajveer 4243
    public void setFromTime(long fromTime) {
695 rajveer 4244
      this.fromTime = fromTime;
4245
      setFromTimeIsSet(true);
123 ashish 4246
    }
4247
 
695 rajveer 4248
    public void unsetFromTime() {
4249
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
123 ashish 4250
    }
4251
 
3430 rajveer 4252
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
695 rajveer 4253
    public boolean isSetFromTime() {
4254
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
123 ashish 4255
    }
4256
 
695 rajveer 4257
    public void setFromTimeIsSet(boolean value) {
4258
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
123 ashish 4259
    }
4260
 
695 rajveer 4261
    public long getToTime() {
4262
      return this.toTime;
123 ashish 4263
    }
4264
 
3430 rajveer 4265
    public void setToTime(long toTime) {
695 rajveer 4266
      this.toTime = toTime;
4267
      setToTimeIsSet(true);
123 ashish 4268
    }
4269
 
695 rajveer 4270
    public void unsetToTime() {
4271
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
123 ashish 4272
    }
4273
 
3430 rajveer 4274
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
695 rajveer 4275
    public boolean isSetToTime() {
4276
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
123 ashish 4277
    }
4278
 
695 rajveer 4279
    public void setToTimeIsSet(boolean value) {
4280
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
123 ashish 4281
    }
4282
 
4283
    /**
4284
     * 
4285
     * @see PaymentStatus
4286
     */
4287
    public PaymentStatus getStatus() {
4288
      return this.status;
4289
    }
4290
 
4291
    /**
4292
     * 
4293
     * @see PaymentStatus
4294
     */
3430 rajveer 4295
    public void setStatus(PaymentStatus status) {
123 ashish 4296
      this.status = status;
4297
    }
4298
 
4299
    public void unsetStatus() {
4300
      this.status = null;
4301
    }
4302
 
3430 rajveer 4303
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
123 ashish 4304
    public boolean isSetStatus() {
4305
      return this.status != null;
4306
    }
4307
 
4308
    public void setStatusIsSet(boolean value) {
4309
      if (!value) {
4310
        this.status = null;
4311
      }
4312
    }
4313
 
695 rajveer 4314
    public long getGatewayId() {
4315
      return this.gatewayId;
123 ashish 4316
    }
4317
 
3430 rajveer 4318
    public void setGatewayId(long gatewayId) {
695 rajveer 4319
      this.gatewayId = gatewayId;
4320
      setGatewayIdIsSet(true);
123 ashish 4321
    }
4322
 
695 rajveer 4323
    public void unsetGatewayId() {
4324
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 4325
    }
4326
 
3430 rajveer 4327
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 4328
    public boolean isSetGatewayId() {
4329
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 4330
    }
4331
 
695 rajveer 4332
    public void setGatewayIdIsSet(boolean value) {
4333
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 4334
    }
4335
 
4336
    public void setFieldValue(_Fields field, Object value) {
4337
      switch (field) {
4338
      case FROM_TIME:
4339
        if (value == null) {
695 rajveer 4340
          unsetFromTime();
123 ashish 4341
        } else {
695 rajveer 4342
          setFromTime((Long)value);
123 ashish 4343
        }
4344
        break;
4345
 
4346
      case TO_TIME:
4347
        if (value == null) {
695 rajveer 4348
          unsetToTime();
123 ashish 4349
        } else {
695 rajveer 4350
          setToTime((Long)value);
123 ashish 4351
        }
4352
        break;
4353
 
4354
      case STATUS:
4355
        if (value == null) {
4356
          unsetStatus();
4357
        } else {
4358
          setStatus((PaymentStatus)value);
4359
        }
4360
        break;
4361
 
420 ashish 4362
      case GATEWAY_ID:
123 ashish 4363
        if (value == null) {
695 rajveer 4364
          unsetGatewayId();
123 ashish 4365
        } else {
695 rajveer 4366
          setGatewayId((Long)value);
123 ashish 4367
        }
4368
        break;
4369
 
4370
      }
4371
    }
4372
 
4373
    public Object getFieldValue(_Fields field) {
4374
      switch (field) {
4375
      case FROM_TIME:
3430 rajveer 4376
        return Long.valueOf(getFromTime());
123 ashish 4377
 
4378
      case TO_TIME:
3430 rajveer 4379
        return Long.valueOf(getToTime());
123 ashish 4380
 
4381
      case STATUS:
4382
        return getStatus();
4383
 
420 ashish 4384
      case GATEWAY_ID:
3430 rajveer 4385
        return Long.valueOf(getGatewayId());
123 ashish 4386
 
4387
      }
4388
      throw new IllegalStateException();
4389
    }
4390
 
3430 rajveer 4391
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4392
    public boolean isSet(_Fields field) {
4393
      if (field == null) {
4394
        throw new IllegalArgumentException();
4395
      }
123 ashish 4396
 
4397
      switch (field) {
4398
      case FROM_TIME:
695 rajveer 4399
        return isSetFromTime();
123 ashish 4400
      case TO_TIME:
695 rajveer 4401
        return isSetToTime();
123 ashish 4402
      case STATUS:
4403
        return isSetStatus();
420 ashish 4404
      case GATEWAY_ID:
695 rajveer 4405
        return isSetGatewayId();
123 ashish 4406
      }
4407
      throw new IllegalStateException();
4408
    }
4409
 
4410
    @Override
4411
    public boolean equals(Object that) {
4412
      if (that == null)
4413
        return false;
4414
      if (that instanceof getPayments_args)
4415
        return this.equals((getPayments_args)that);
4416
      return false;
4417
    }
4418
 
4419
    public boolean equals(getPayments_args that) {
4420
      if (that == null)
4421
        return false;
4422
 
695 rajveer 4423
      boolean this_present_fromTime = true;
4424
      boolean that_present_fromTime = true;
4425
      if (this_present_fromTime || that_present_fromTime) {
4426
        if (!(this_present_fromTime && that_present_fromTime))
123 ashish 4427
          return false;
695 rajveer 4428
        if (this.fromTime != that.fromTime)
123 ashish 4429
          return false;
4430
      }
4431
 
695 rajveer 4432
      boolean this_present_toTime = true;
4433
      boolean that_present_toTime = true;
4434
      if (this_present_toTime || that_present_toTime) {
4435
        if (!(this_present_toTime && that_present_toTime))
123 ashish 4436
          return false;
695 rajveer 4437
        if (this.toTime != that.toTime)
123 ashish 4438
          return false;
4439
      }
4440
 
4441
      boolean this_present_status = true && this.isSetStatus();
4442
      boolean that_present_status = true && that.isSetStatus();
4443
      if (this_present_status || that_present_status) {
4444
        if (!(this_present_status && that_present_status))
4445
          return false;
4446
        if (!this.status.equals(that.status))
4447
          return false;
4448
      }
4449
 
695 rajveer 4450
      boolean this_present_gatewayId = true;
4451
      boolean that_present_gatewayId = true;
4452
      if (this_present_gatewayId || that_present_gatewayId) {
4453
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 4454
          return false;
695 rajveer 4455
        if (this.gatewayId != that.gatewayId)
123 ashish 4456
          return false;
4457
      }
4458
 
4459
      return true;
4460
    }
4461
 
4462
    @Override
4463
    public int hashCode() {
4464
      return 0;
4465
    }
4466
 
4467
    public int compareTo(getPayments_args other) {
4468
      if (!getClass().equals(other.getClass())) {
4469
        return getClass().getName().compareTo(other.getClass().getName());
4470
      }
4471
 
4472
      int lastComparison = 0;
4473
      getPayments_args typedOther = (getPayments_args)other;
4474
 
3430 rajveer 4475
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
123 ashish 4476
      if (lastComparison != 0) {
4477
        return lastComparison;
4478
      }
3430 rajveer 4479
      if (isSetFromTime()) {
4480
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
4481
        if (lastComparison != 0) {
4482
          return lastComparison;
4483
        }
123 ashish 4484
      }
3430 rajveer 4485
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
123 ashish 4486
      if (lastComparison != 0) {
4487
        return lastComparison;
4488
      }
3430 rajveer 4489
      if (isSetToTime()) {
4490
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
4491
        if (lastComparison != 0) {
4492
          return lastComparison;
4493
        }
123 ashish 4494
      }
3430 rajveer 4495
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
123 ashish 4496
      if (lastComparison != 0) {
4497
        return lastComparison;
4498
      }
3430 rajveer 4499
      if (isSetStatus()) {
4500
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
4501
        if (lastComparison != 0) {
4502
          return lastComparison;
4503
        }
123 ashish 4504
      }
3430 rajveer 4505
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 4506
      if (lastComparison != 0) {
4507
        return lastComparison;
4508
      }
3430 rajveer 4509
      if (isSetGatewayId()) {
4510
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
4511
        if (lastComparison != 0) {
4512
          return lastComparison;
4513
        }
123 ashish 4514
      }
4515
      return 0;
4516
    }
4517
 
3430 rajveer 4518
    public _Fields fieldForId(int fieldId) {
4519
      return _Fields.findByThriftId(fieldId);
4520
    }
4521
 
4522
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4523
      org.apache.thrift.protocol.TField field;
123 ashish 4524
      iprot.readStructBegin();
4525
      while (true)
4526
      {
4527
        field = iprot.readFieldBegin();
3430 rajveer 4528
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 4529
          break;
4530
        }
3430 rajveer 4531
        switch (field.id) {
4532
          case 1: // FROM_TIME
4533
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4534
              this.fromTime = iprot.readI64();
4535
              setFromTimeIsSet(true);
4536
            } else { 
4537
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4538
            }
4539
            break;
4540
          case 2: // TO_TIME
4541
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4542
              this.toTime = iprot.readI64();
4543
              setToTimeIsSet(true);
4544
            } else { 
4545
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4546
            }
4547
            break;
4548
          case 3: // STATUS
4549
            if (field.type == org.apache.thrift.protocol.TType.I32) {
4550
              this.status = PaymentStatus.findByValue(iprot.readI32());
4551
            } else { 
4552
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4553
            }
4554
            break;
4555
          case 4: // GATEWAY_ID
4556
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4557
              this.gatewayId = iprot.readI64();
4558
              setGatewayIdIsSet(true);
4559
            } else { 
4560
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4561
            }
4562
            break;
4563
          default:
4564
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 4565
        }
3430 rajveer 4566
        iprot.readFieldEnd();
123 ashish 4567
      }
4568
      iprot.readStructEnd();
4569
      validate();
4570
    }
4571
 
3430 rajveer 4572
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 4573
      validate();
4574
 
4575
      oprot.writeStructBegin(STRUCT_DESC);
4576
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
695 rajveer 4577
      oprot.writeI64(this.fromTime);
123 ashish 4578
      oprot.writeFieldEnd();
4579
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
695 rajveer 4580
      oprot.writeI64(this.toTime);
123 ashish 4581
      oprot.writeFieldEnd();
4582
      if (this.status != null) {
4583
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
4584
        oprot.writeI32(this.status.getValue());
4585
        oprot.writeFieldEnd();
4586
      }
420 ashish 4587
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 4588
      oprot.writeI64(this.gatewayId);
420 ashish 4589
      oprot.writeFieldEnd();
123 ashish 4590
      oprot.writeFieldStop();
4591
      oprot.writeStructEnd();
4592
    }
4593
 
4594
    @Override
4595
    public String toString() {
4596
      StringBuilder sb = new StringBuilder("getPayments_args(");
4597
      boolean first = true;
4598
 
695 rajveer 4599
      sb.append("fromTime:");
4600
      sb.append(this.fromTime);
123 ashish 4601
      first = false;
4602
      if (!first) sb.append(", ");
695 rajveer 4603
      sb.append("toTime:");
4604
      sb.append(this.toTime);
123 ashish 4605
      first = false;
4606
      if (!first) sb.append(", ");
4607
      sb.append("status:");
4608
      if (this.status == null) {
4609
        sb.append("null");
4610
      } else {
4611
        sb.append(this.status);
4612
      }
4613
      first = false;
4614
      if (!first) sb.append(", ");
695 rajveer 4615
      sb.append("gatewayId:");
4616
      sb.append(this.gatewayId);
123 ashish 4617
      first = false;
4618
      sb.append(")");
4619
      return sb.toString();
4620
    }
4621
 
3430 rajveer 4622
    public void validate() throws org.apache.thrift.TException {
123 ashish 4623
      // check for required fields
4624
    }
4625
 
3430 rajveer 4626
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4627
      try {
4628
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4629
      } catch (org.apache.thrift.TException te) {
4630
        throw new java.io.IOException(te);
4631
      }
4632
    }
4633
 
4634
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4635
      try {
4636
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4637
      } catch (org.apache.thrift.TException te) {
4638
        throw new java.io.IOException(te);
4639
      }
4640
    }
4641
 
123 ashish 4642
  }
4643
 
3430 rajveer 4644
  public static class getPayments_result implements org.apache.thrift.TBase<getPayments_result, getPayments_result._Fields>, java.io.Serializable, Cloneable   {
4645
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayments_result");
123 ashish 4646
 
3430 rajveer 4647
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
4648
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
123 ashish 4649
 
3430 rajveer 4650
    private List<Payment> success; // required
4651
    private PaymentException pe; // required
123 ashish 4652
 
4653
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4654
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 4655
      SUCCESS((short)0, "success"),
4656
      PE((short)1, "pe");
4657
 
4658
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4659
 
4660
      static {
4661
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4662
          byName.put(field.getFieldName(), field);
4663
        }
4664
      }
4665
 
4666
      /**
4667
       * Find the _Fields constant that matches fieldId, or null if its not found.
4668
       */
4669
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4670
        switch(fieldId) {
4671
          case 0: // SUCCESS
4672
            return SUCCESS;
4673
          case 1: // PE
4674
            return PE;
4675
          default:
4676
            return null;
4677
        }
123 ashish 4678
      }
4679
 
4680
      /**
4681
       * Find the _Fields constant that matches fieldId, throwing an exception
4682
       * if it is not found.
4683
       */
4684
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4685
        _Fields fields = findByThriftId(fieldId);
4686
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4687
        return fields;
4688
      }
4689
 
4690
      /**
4691
       * Find the _Fields constant that matches name, or null if its not found.
4692
       */
4693
      public static _Fields findByName(String name) {
4694
        return byName.get(name);
4695
      }
4696
 
4697
      private final short _thriftId;
4698
      private final String _fieldName;
4699
 
4700
      _Fields(short thriftId, String fieldName) {
4701
        _thriftId = thriftId;
4702
        _fieldName = fieldName;
4703
      }
4704
 
4705
      public short getThriftFieldId() {
4706
        return _thriftId;
4707
      }
4708
 
4709
      public String getFieldName() {
4710
        return _fieldName;
4711
      }
4712
    }
4713
 
4714
    // isset id assignments
4715
 
3430 rajveer 4716
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 4717
    static {
3430 rajveer 4718
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4719
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4720
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
4721
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
4722
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4723
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4724
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4725
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayments_result.class, metaDataMap);
123 ashish 4726
    }
4727
 
4728
    public getPayments_result() {
4729
    }
4730
 
4731
    public getPayments_result(
4732
      List<Payment> success,
4733
      PaymentException pe)
4734
    {
4735
      this();
4736
      this.success = success;
4737
      this.pe = pe;
4738
    }
4739
 
4740
    /**
4741
     * Performs a deep copy on <i>other</i>.
4742
     */
4743
    public getPayments_result(getPayments_result other) {
4744
      if (other.isSetSuccess()) {
4745
        List<Payment> __this__success = new ArrayList<Payment>();
4746
        for (Payment other_element : other.success) {
4747
          __this__success.add(new Payment(other_element));
4748
        }
4749
        this.success = __this__success;
4750
      }
4751
      if (other.isSetPe()) {
4752
        this.pe = new PaymentException(other.pe);
4753
      }
4754
    }
4755
 
4756
    public getPayments_result deepCopy() {
4757
      return new getPayments_result(this);
4758
    }
4759
 
3430 rajveer 4760
    @Override
4761
    public void clear() {
4762
      this.success = null;
4763
      this.pe = null;
123 ashish 4764
    }
4765
 
4766
    public int getSuccessSize() {
4767
      return (this.success == null) ? 0 : this.success.size();
4768
    }
4769
 
4770
    public java.util.Iterator<Payment> getSuccessIterator() {
4771
      return (this.success == null) ? null : this.success.iterator();
4772
    }
4773
 
4774
    public void addToSuccess(Payment elem) {
4775
      if (this.success == null) {
4776
        this.success = new ArrayList<Payment>();
4777
      }
4778
      this.success.add(elem);
4779
    }
4780
 
4781
    public List<Payment> getSuccess() {
4782
      return this.success;
4783
    }
4784
 
3430 rajveer 4785
    public void setSuccess(List<Payment> success) {
123 ashish 4786
      this.success = success;
4787
    }
4788
 
4789
    public void unsetSuccess() {
4790
      this.success = null;
4791
    }
4792
 
3430 rajveer 4793
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 4794
    public boolean isSetSuccess() {
4795
      return this.success != null;
4796
    }
4797
 
4798
    public void setSuccessIsSet(boolean value) {
4799
      if (!value) {
4800
        this.success = null;
4801
      }
4802
    }
4803
 
4804
    public PaymentException getPe() {
4805
      return this.pe;
4806
    }
4807
 
3430 rajveer 4808
    public void setPe(PaymentException pe) {
123 ashish 4809
      this.pe = pe;
4810
    }
4811
 
4812
    public void unsetPe() {
4813
      this.pe = null;
4814
    }
4815
 
3430 rajveer 4816
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 4817
    public boolean isSetPe() {
4818
      return this.pe != null;
4819
    }
4820
 
4821
    public void setPeIsSet(boolean value) {
4822
      if (!value) {
4823
        this.pe = null;
4824
      }
4825
    }
4826
 
4827
    public void setFieldValue(_Fields field, Object value) {
4828
      switch (field) {
4829
      case SUCCESS:
4830
        if (value == null) {
4831
          unsetSuccess();
4832
        } else {
4833
          setSuccess((List<Payment>)value);
4834
        }
4835
        break;
4836
 
4837
      case PE:
4838
        if (value == null) {
4839
          unsetPe();
4840
        } else {
4841
          setPe((PaymentException)value);
4842
        }
4843
        break;
4844
 
4845
      }
4846
    }
4847
 
4848
    public Object getFieldValue(_Fields field) {
4849
      switch (field) {
4850
      case SUCCESS:
4851
        return getSuccess();
4852
 
4853
      case PE:
4854
        return getPe();
4855
 
4856
      }
4857
      throw new IllegalStateException();
4858
    }
4859
 
3430 rajveer 4860
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4861
    public boolean isSet(_Fields field) {
4862
      if (field == null) {
4863
        throw new IllegalArgumentException();
4864
      }
123 ashish 4865
 
4866
      switch (field) {
4867
      case SUCCESS:
4868
        return isSetSuccess();
4869
      case PE:
4870
        return isSetPe();
4871
      }
4872
      throw new IllegalStateException();
4873
    }
4874
 
4875
    @Override
4876
    public boolean equals(Object that) {
4877
      if (that == null)
4878
        return false;
4879
      if (that instanceof getPayments_result)
4880
        return this.equals((getPayments_result)that);
4881
      return false;
4882
    }
4883
 
4884
    public boolean equals(getPayments_result that) {
4885
      if (that == null)
4886
        return false;
4887
 
4888
      boolean this_present_success = true && this.isSetSuccess();
4889
      boolean that_present_success = true && that.isSetSuccess();
4890
      if (this_present_success || that_present_success) {
4891
        if (!(this_present_success && that_present_success))
4892
          return false;
4893
        if (!this.success.equals(that.success))
4894
          return false;
4895
      }
4896
 
4897
      boolean this_present_pe = true && this.isSetPe();
4898
      boolean that_present_pe = true && that.isSetPe();
4899
      if (this_present_pe || that_present_pe) {
4900
        if (!(this_present_pe && that_present_pe))
4901
          return false;
4902
        if (!this.pe.equals(that.pe))
4903
          return false;
4904
      }
4905
 
4906
      return true;
4907
    }
4908
 
4909
    @Override
4910
    public int hashCode() {
4911
      return 0;
4912
    }
4913
 
695 rajveer 4914
    public int compareTo(getPayments_result other) {
123 ashish 4915
      if (!getClass().equals(other.getClass())) {
4916
        return getClass().getName().compareTo(other.getClass().getName());
4917
      }
4918
 
4919
      int lastComparison = 0;
695 rajveer 4920
      getPayments_result typedOther = (getPayments_result)other;
123 ashish 4921
 
3430 rajveer 4922
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
123 ashish 4923
      if (lastComparison != 0) {
4924
        return lastComparison;
4925
      }
3430 rajveer 4926
      if (isSetSuccess()) {
4927
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4928
        if (lastComparison != 0) {
4929
          return lastComparison;
4930
        }
123 ashish 4931
      }
3430 rajveer 4932
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 4933
      if (lastComparison != 0) {
4934
        return lastComparison;
123 ashish 4935
      }
3430 rajveer 4936
      if (isSetPe()) {
4937
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
4938
        if (lastComparison != 0) {
4939
          return lastComparison;
4940
        }
123 ashish 4941
      }
4942
      return 0;
4943
    }
4944
 
3430 rajveer 4945
    public _Fields fieldForId(int fieldId) {
4946
      return _Fields.findByThriftId(fieldId);
4947
    }
4948
 
4949
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4950
      org.apache.thrift.protocol.TField field;
123 ashish 4951
      iprot.readStructBegin();
4952
      while (true)
4953
      {
4954
        field = iprot.readFieldBegin();
3430 rajveer 4955
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 4956
          break;
4957
        }
3430 rajveer 4958
        switch (field.id) {
4959
          case 0: // SUCCESS
4960
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
4961
              {
4962
                org.apache.thrift.protocol.TList _list16 = iprot.readListBegin();
4963
                this.success = new ArrayList<Payment>(_list16.size);
4964
                for (int _i17 = 0; _i17 < _list16.size; ++_i17)
420 ashish 4965
                {
3430 rajveer 4966
                  Payment _elem18; // required
4967
                  _elem18 = new Payment();
4968
                  _elem18.read(iprot);
4969
                  this.success.add(_elem18);
420 ashish 4970
                }
3430 rajveer 4971
                iprot.readListEnd();
123 ashish 4972
              }
3430 rajveer 4973
            } else { 
4974
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4975
            }
4976
            break;
4977
          case 1: // PE
4978
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4979
              this.pe = new PaymentException();
4980
              this.pe.read(iprot);
4981
            } else { 
4982
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4983
            }
4984
            break;
4985
          default:
4986
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 4987
        }
3430 rajveer 4988
        iprot.readFieldEnd();
123 ashish 4989
      }
4990
      iprot.readStructEnd();
4991
      validate();
4992
    }
4993
 
3430 rajveer 4994
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 4995
      oprot.writeStructBegin(STRUCT_DESC);
4996
 
4997
      if (this.isSetSuccess()) {
4998
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
420 ashish 4999
        {
3430 rajveer 5000
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
2747 chandransh 5001
          for (Payment _iter19 : this.success)
420 ashish 5002
          {
2747 chandransh 5003
            _iter19.write(oprot);
420 ashish 5004
          }
5005
          oprot.writeListEnd();
5006
        }
123 ashish 5007
        oprot.writeFieldEnd();
5008
      } else if (this.isSetPe()) {
5009
        oprot.writeFieldBegin(PE_FIELD_DESC);
5010
        this.pe.write(oprot);
5011
        oprot.writeFieldEnd();
5012
      }
5013
      oprot.writeFieldStop();
5014
      oprot.writeStructEnd();
5015
    }
5016
 
5017
    @Override
5018
    public String toString() {
695 rajveer 5019
      StringBuilder sb = new StringBuilder("getPayments_result(");
123 ashish 5020
      boolean first = true;
5021
 
5022
      sb.append("success:");
5023
      if (this.success == null) {
5024
        sb.append("null");
5025
      } else {
5026
        sb.append(this.success);
5027
      }
5028
      first = false;
5029
      if (!first) sb.append(", ");
5030
      sb.append("pe:");
5031
      if (this.pe == null) {
5032
        sb.append("null");
5033
      } else {
5034
        sb.append(this.pe);
5035
      }
5036
      first = false;
5037
      sb.append(")");
5038
      return sb.toString();
5039
    }
5040
 
3430 rajveer 5041
    public void validate() throws org.apache.thrift.TException {
123 ashish 5042
      // check for required fields
5043
    }
5044
 
3430 rajveer 5045
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5046
      try {
5047
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5048
      } catch (org.apache.thrift.TException te) {
5049
        throw new java.io.IOException(te);
5050
      }
5051
    }
5052
 
5053
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5054
      try {
5055
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5056
      } catch (org.apache.thrift.TException te) {
5057
        throw new java.io.IOException(te);
5058
      }
5059
    }
5060
 
123 ashish 5061
  }
5062
 
4141 chandransh 5063
  public static class getPaymentsByCapturedDate_args implements org.apache.thrift.TBase<getPaymentsByCapturedDate_args, getPaymentsByCapturedDate_args._Fields>, java.io.Serializable, Cloneable   {
5064
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsByCapturedDate_args");
5065
 
5066
    private static final org.apache.thrift.protocol.TField FROM_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("fromTime", org.apache.thrift.protocol.TType.I64, (short)1);
5067
    private static final org.apache.thrift.protocol.TField TO_TIME_FIELD_DESC = new org.apache.thrift.protocol.TField("toTime", org.apache.thrift.protocol.TType.I64, (short)2);
5068
    private static final org.apache.thrift.protocol.TField GATEWAY_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayId", org.apache.thrift.protocol.TType.I64, (short)3);
5069
 
5070
    private long fromTime; // required
5071
    private long toTime; // required
5072
    private long gatewayId; // required
5073
 
5074
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5075
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5076
      FROM_TIME((short)1, "fromTime"),
5077
      TO_TIME((short)2, "toTime"),
5078
      GATEWAY_ID((short)3, "gatewayId");
5079
 
5080
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5081
 
5082
      static {
5083
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5084
          byName.put(field.getFieldName(), field);
5085
        }
5086
      }
5087
 
5088
      /**
5089
       * Find the _Fields constant that matches fieldId, or null if its not found.
5090
       */
5091
      public static _Fields findByThriftId(int fieldId) {
5092
        switch(fieldId) {
5093
          case 1: // FROM_TIME
5094
            return FROM_TIME;
5095
          case 2: // TO_TIME
5096
            return TO_TIME;
5097
          case 3: // GATEWAY_ID
5098
            return GATEWAY_ID;
5099
          default:
5100
            return null;
5101
        }
5102
      }
5103
 
5104
      /**
5105
       * Find the _Fields constant that matches fieldId, throwing an exception
5106
       * if it is not found.
5107
       */
5108
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5109
        _Fields fields = findByThriftId(fieldId);
5110
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5111
        return fields;
5112
      }
5113
 
5114
      /**
5115
       * Find the _Fields constant that matches name, or null if its not found.
5116
       */
5117
      public static _Fields findByName(String name) {
5118
        return byName.get(name);
5119
      }
5120
 
5121
      private final short _thriftId;
5122
      private final String _fieldName;
5123
 
5124
      _Fields(short thriftId, String fieldName) {
5125
        _thriftId = thriftId;
5126
        _fieldName = fieldName;
5127
      }
5128
 
5129
      public short getThriftFieldId() {
5130
        return _thriftId;
5131
      }
5132
 
5133
      public String getFieldName() {
5134
        return _fieldName;
5135
      }
5136
    }
5137
 
5138
    // isset id assignments
5139
    private static final int __FROMTIME_ISSET_ID = 0;
5140
    private static final int __TOTIME_ISSET_ID = 1;
5141
    private static final int __GATEWAYID_ISSET_ID = 2;
5142
    private BitSet __isset_bit_vector = new BitSet(3);
5143
 
5144
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5145
    static {
5146
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5147
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5148
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5149
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5150
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5151
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5152
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5153
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5154
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsByCapturedDate_args.class, metaDataMap);
5155
    }
5156
 
5157
    public getPaymentsByCapturedDate_args() {
5158
    }
5159
 
5160
    public getPaymentsByCapturedDate_args(
5161
      long fromTime,
5162
      long toTime,
5163
      long gatewayId)
5164
    {
5165
      this();
5166
      this.fromTime = fromTime;
5167
      setFromTimeIsSet(true);
5168
      this.toTime = toTime;
5169
      setToTimeIsSet(true);
5170
      this.gatewayId = gatewayId;
5171
      setGatewayIdIsSet(true);
5172
    }
5173
 
5174
    /**
5175
     * Performs a deep copy on <i>other</i>.
5176
     */
5177
    public getPaymentsByCapturedDate_args(getPaymentsByCapturedDate_args other) {
5178
      __isset_bit_vector.clear();
5179
      __isset_bit_vector.or(other.__isset_bit_vector);
5180
      this.fromTime = other.fromTime;
5181
      this.toTime = other.toTime;
5182
      this.gatewayId = other.gatewayId;
5183
    }
5184
 
5185
    public getPaymentsByCapturedDate_args deepCopy() {
5186
      return new getPaymentsByCapturedDate_args(this);
5187
    }
5188
 
5189
    @Override
5190
    public void clear() {
5191
      setFromTimeIsSet(false);
5192
      this.fromTime = 0;
5193
      setToTimeIsSet(false);
5194
      this.toTime = 0;
5195
      setGatewayIdIsSet(false);
5196
      this.gatewayId = 0;
5197
    }
5198
 
5199
    public long getFromTime() {
5200
      return this.fromTime;
5201
    }
5202
 
5203
    public void setFromTime(long fromTime) {
5204
      this.fromTime = fromTime;
5205
      setFromTimeIsSet(true);
5206
    }
5207
 
5208
    public void unsetFromTime() {
5209
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
5210
    }
5211
 
5212
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
5213
    public boolean isSetFromTime() {
5214
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
5215
    }
5216
 
5217
    public void setFromTimeIsSet(boolean value) {
5218
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
5219
    }
5220
 
5221
    public long getToTime() {
5222
      return this.toTime;
5223
    }
5224
 
5225
    public void setToTime(long toTime) {
5226
      this.toTime = toTime;
5227
      setToTimeIsSet(true);
5228
    }
5229
 
5230
    public void unsetToTime() {
5231
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
5232
    }
5233
 
5234
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
5235
    public boolean isSetToTime() {
5236
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
5237
    }
5238
 
5239
    public void setToTimeIsSet(boolean value) {
5240
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
5241
    }
5242
 
5243
    public long getGatewayId() {
5244
      return this.gatewayId;
5245
    }
5246
 
5247
    public void setGatewayId(long gatewayId) {
5248
      this.gatewayId = gatewayId;
5249
      setGatewayIdIsSet(true);
5250
    }
5251
 
5252
    public void unsetGatewayId() {
5253
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
5254
    }
5255
 
5256
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
5257
    public boolean isSetGatewayId() {
5258
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
5259
    }
5260
 
5261
    public void setGatewayIdIsSet(boolean value) {
5262
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
5263
    }
5264
 
5265
    public void setFieldValue(_Fields field, Object value) {
5266
      switch (field) {
5267
      case FROM_TIME:
5268
        if (value == null) {
5269
          unsetFromTime();
5270
        } else {
5271
          setFromTime((Long)value);
5272
        }
5273
        break;
5274
 
5275
      case TO_TIME:
5276
        if (value == null) {
5277
          unsetToTime();
5278
        } else {
5279
          setToTime((Long)value);
5280
        }
5281
        break;
5282
 
5283
      case GATEWAY_ID:
5284
        if (value == null) {
5285
          unsetGatewayId();
5286
        } else {
5287
          setGatewayId((Long)value);
5288
        }
5289
        break;
5290
 
5291
      }
5292
    }
5293
 
5294
    public Object getFieldValue(_Fields field) {
5295
      switch (field) {
5296
      case FROM_TIME:
5297
        return Long.valueOf(getFromTime());
5298
 
5299
      case TO_TIME:
5300
        return Long.valueOf(getToTime());
5301
 
5302
      case GATEWAY_ID:
5303
        return Long.valueOf(getGatewayId());
5304
 
5305
      }
5306
      throw new IllegalStateException();
5307
    }
5308
 
5309
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5310
    public boolean isSet(_Fields field) {
5311
      if (field == null) {
5312
        throw new IllegalArgumentException();
5313
      }
5314
 
5315
      switch (field) {
5316
      case FROM_TIME:
5317
        return isSetFromTime();
5318
      case TO_TIME:
5319
        return isSetToTime();
5320
      case GATEWAY_ID:
5321
        return isSetGatewayId();
5322
      }
5323
      throw new IllegalStateException();
5324
    }
5325
 
5326
    @Override
5327
    public boolean equals(Object that) {
5328
      if (that == null)
5329
        return false;
5330
      if (that instanceof getPaymentsByCapturedDate_args)
5331
        return this.equals((getPaymentsByCapturedDate_args)that);
5332
      return false;
5333
    }
5334
 
5335
    public boolean equals(getPaymentsByCapturedDate_args that) {
5336
      if (that == null)
5337
        return false;
5338
 
5339
      boolean this_present_fromTime = true;
5340
      boolean that_present_fromTime = true;
5341
      if (this_present_fromTime || that_present_fromTime) {
5342
        if (!(this_present_fromTime && that_present_fromTime))
5343
          return false;
5344
        if (this.fromTime != that.fromTime)
5345
          return false;
5346
      }
5347
 
5348
      boolean this_present_toTime = true;
5349
      boolean that_present_toTime = true;
5350
      if (this_present_toTime || that_present_toTime) {
5351
        if (!(this_present_toTime && that_present_toTime))
5352
          return false;
5353
        if (this.toTime != that.toTime)
5354
          return false;
5355
      }
5356
 
5357
      boolean this_present_gatewayId = true;
5358
      boolean that_present_gatewayId = true;
5359
      if (this_present_gatewayId || that_present_gatewayId) {
5360
        if (!(this_present_gatewayId && that_present_gatewayId))
5361
          return false;
5362
        if (this.gatewayId != that.gatewayId)
5363
          return false;
5364
      }
5365
 
5366
      return true;
5367
    }
5368
 
5369
    @Override
5370
    public int hashCode() {
5371
      return 0;
5372
    }
5373
 
5374
    public int compareTo(getPaymentsByCapturedDate_args other) {
5375
      if (!getClass().equals(other.getClass())) {
5376
        return getClass().getName().compareTo(other.getClass().getName());
5377
      }
5378
 
5379
      int lastComparison = 0;
5380
      getPaymentsByCapturedDate_args typedOther = (getPaymentsByCapturedDate_args)other;
5381
 
5382
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
5383
      if (lastComparison != 0) {
5384
        return lastComparison;
5385
      }
5386
      if (isSetFromTime()) {
5387
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
5388
        if (lastComparison != 0) {
5389
          return lastComparison;
5390
        }
5391
      }
5392
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
5393
      if (lastComparison != 0) {
5394
        return lastComparison;
5395
      }
5396
      if (isSetToTime()) {
5397
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
5398
        if (lastComparison != 0) {
5399
          return lastComparison;
5400
        }
5401
      }
5402
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
5403
      if (lastComparison != 0) {
5404
        return lastComparison;
5405
      }
5406
      if (isSetGatewayId()) {
5407
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
5408
        if (lastComparison != 0) {
5409
          return lastComparison;
5410
        }
5411
      }
5412
      return 0;
5413
    }
5414
 
5415
    public _Fields fieldForId(int fieldId) {
5416
      return _Fields.findByThriftId(fieldId);
5417
    }
5418
 
5419
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5420
      org.apache.thrift.protocol.TField field;
5421
      iprot.readStructBegin();
5422
      while (true)
5423
      {
5424
        field = iprot.readFieldBegin();
5425
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5426
          break;
5427
        }
5428
        switch (field.id) {
5429
          case 1: // FROM_TIME
5430
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5431
              this.fromTime = iprot.readI64();
5432
              setFromTimeIsSet(true);
5433
            } else { 
5434
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5435
            }
5436
            break;
5437
          case 2: // TO_TIME
5438
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5439
              this.toTime = iprot.readI64();
5440
              setToTimeIsSet(true);
5441
            } else { 
5442
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5443
            }
5444
            break;
5445
          case 3: // GATEWAY_ID
5446
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5447
              this.gatewayId = iprot.readI64();
5448
              setGatewayIdIsSet(true);
5449
            } else { 
5450
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5451
            }
5452
            break;
5453
          default:
5454
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5455
        }
5456
        iprot.readFieldEnd();
5457
      }
5458
      iprot.readStructEnd();
5459
      validate();
5460
    }
5461
 
5462
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5463
      validate();
5464
 
5465
      oprot.writeStructBegin(STRUCT_DESC);
5466
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
5467
      oprot.writeI64(this.fromTime);
5468
      oprot.writeFieldEnd();
5469
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
5470
      oprot.writeI64(this.toTime);
5471
      oprot.writeFieldEnd();
5472
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
5473
      oprot.writeI64(this.gatewayId);
5474
      oprot.writeFieldEnd();
5475
      oprot.writeFieldStop();
5476
      oprot.writeStructEnd();
5477
    }
5478
 
5479
    @Override
5480
    public String toString() {
5481
      StringBuilder sb = new StringBuilder("getPaymentsByCapturedDate_args(");
5482
      boolean first = true;
5483
 
5484
      sb.append("fromTime:");
5485
      sb.append(this.fromTime);
5486
      first = false;
5487
      if (!first) sb.append(", ");
5488
      sb.append("toTime:");
5489
      sb.append(this.toTime);
5490
      first = false;
5491
      if (!first) sb.append(", ");
5492
      sb.append("gatewayId:");
5493
      sb.append(this.gatewayId);
5494
      first = false;
5495
      sb.append(")");
5496
      return sb.toString();
5497
    }
5498
 
5499
    public void validate() throws org.apache.thrift.TException {
5500
      // check for required fields
5501
    }
5502
 
5503
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5504
      try {
5505
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5506
      } catch (org.apache.thrift.TException te) {
5507
        throw new java.io.IOException(te);
5508
      }
5509
    }
5510
 
5511
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5512
      try {
5513
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5514
      } catch (org.apache.thrift.TException te) {
5515
        throw new java.io.IOException(te);
5516
      }
5517
    }
5518
 
5519
  }
5520
 
5521
  public static class getPaymentsByCapturedDate_result implements org.apache.thrift.TBase<getPaymentsByCapturedDate_result, getPaymentsByCapturedDate_result._Fields>, java.io.Serializable, Cloneable   {
5522
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsByCapturedDate_result");
5523
 
5524
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
5525
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
5526
 
5527
    private List<Payment> success; // required
5528
    private PaymentException pe; // required
5529
 
5530
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5531
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5532
      SUCCESS((short)0, "success"),
5533
      PE((short)1, "pe");
5534
 
5535
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5536
 
5537
      static {
5538
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5539
          byName.put(field.getFieldName(), field);
5540
        }
5541
      }
5542
 
5543
      /**
5544
       * Find the _Fields constant that matches fieldId, or null if its not found.
5545
       */
5546
      public static _Fields findByThriftId(int fieldId) {
5547
        switch(fieldId) {
5548
          case 0: // SUCCESS
5549
            return SUCCESS;
5550
          case 1: // PE
5551
            return PE;
5552
          default:
5553
            return null;
5554
        }
5555
      }
5556
 
5557
      /**
5558
       * Find the _Fields constant that matches fieldId, throwing an exception
5559
       * if it is not found.
5560
       */
5561
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5562
        _Fields fields = findByThriftId(fieldId);
5563
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5564
        return fields;
5565
      }
5566
 
5567
      /**
5568
       * Find the _Fields constant that matches name, or null if its not found.
5569
       */
5570
      public static _Fields findByName(String name) {
5571
        return byName.get(name);
5572
      }
5573
 
5574
      private final short _thriftId;
5575
      private final String _fieldName;
5576
 
5577
      _Fields(short thriftId, String fieldName) {
5578
        _thriftId = thriftId;
5579
        _fieldName = fieldName;
5580
      }
5581
 
5582
      public short getThriftFieldId() {
5583
        return _thriftId;
5584
      }
5585
 
5586
      public String getFieldName() {
5587
        return _fieldName;
5588
      }
5589
    }
5590
 
5591
    // isset id assignments
5592
 
5593
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5594
    static {
5595
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5596
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5597
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
5598
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
5599
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5600
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5601
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5602
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsByCapturedDate_result.class, metaDataMap);
5603
    }
5604
 
5605
    public getPaymentsByCapturedDate_result() {
5606
    }
5607
 
5608
    public getPaymentsByCapturedDate_result(
5609
      List<Payment> success,
5610
      PaymentException pe)
5611
    {
5612
      this();
5613
      this.success = success;
5614
      this.pe = pe;
5615
    }
5616
 
5617
    /**
5618
     * Performs a deep copy on <i>other</i>.
5619
     */
5620
    public getPaymentsByCapturedDate_result(getPaymentsByCapturedDate_result other) {
5621
      if (other.isSetSuccess()) {
5622
        List<Payment> __this__success = new ArrayList<Payment>();
5623
        for (Payment other_element : other.success) {
5624
          __this__success.add(new Payment(other_element));
5625
        }
5626
        this.success = __this__success;
5627
      }
5628
      if (other.isSetPe()) {
5629
        this.pe = new PaymentException(other.pe);
5630
      }
5631
    }
5632
 
5633
    public getPaymentsByCapturedDate_result deepCopy() {
5634
      return new getPaymentsByCapturedDate_result(this);
5635
    }
5636
 
5637
    @Override
5638
    public void clear() {
5639
      this.success = null;
5640
      this.pe = null;
5641
    }
5642
 
5643
    public int getSuccessSize() {
5644
      return (this.success == null) ? 0 : this.success.size();
5645
    }
5646
 
5647
    public java.util.Iterator<Payment> getSuccessIterator() {
5648
      return (this.success == null) ? null : this.success.iterator();
5649
    }
5650
 
5651
    public void addToSuccess(Payment elem) {
5652
      if (this.success == null) {
5653
        this.success = new ArrayList<Payment>();
5654
      }
5655
      this.success.add(elem);
5656
    }
5657
 
5658
    public List<Payment> getSuccess() {
5659
      return this.success;
5660
    }
5661
 
5662
    public void setSuccess(List<Payment> success) {
5663
      this.success = success;
5664
    }
5665
 
5666
    public void unsetSuccess() {
5667
      this.success = null;
5668
    }
5669
 
5670
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
5671
    public boolean isSetSuccess() {
5672
      return this.success != null;
5673
    }
5674
 
5675
    public void setSuccessIsSet(boolean value) {
5676
      if (!value) {
5677
        this.success = null;
5678
      }
5679
    }
5680
 
5681
    public PaymentException getPe() {
5682
      return this.pe;
5683
    }
5684
 
5685
    public void setPe(PaymentException pe) {
5686
      this.pe = pe;
5687
    }
5688
 
5689
    public void unsetPe() {
5690
      this.pe = null;
5691
    }
5692
 
5693
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
5694
    public boolean isSetPe() {
5695
      return this.pe != null;
5696
    }
5697
 
5698
    public void setPeIsSet(boolean value) {
5699
      if (!value) {
5700
        this.pe = null;
5701
      }
5702
    }
5703
 
5704
    public void setFieldValue(_Fields field, Object value) {
5705
      switch (field) {
5706
      case SUCCESS:
5707
        if (value == null) {
5708
          unsetSuccess();
5709
        } else {
5710
          setSuccess((List<Payment>)value);
5711
        }
5712
        break;
5713
 
5714
      case PE:
5715
        if (value == null) {
5716
          unsetPe();
5717
        } else {
5718
          setPe((PaymentException)value);
5719
        }
5720
        break;
5721
 
5722
      }
5723
    }
5724
 
5725
    public Object getFieldValue(_Fields field) {
5726
      switch (field) {
5727
      case SUCCESS:
5728
        return getSuccess();
5729
 
5730
      case PE:
5731
        return getPe();
5732
 
5733
      }
5734
      throw new IllegalStateException();
5735
    }
5736
 
5737
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5738
    public boolean isSet(_Fields field) {
5739
      if (field == null) {
5740
        throw new IllegalArgumentException();
5741
      }
5742
 
5743
      switch (field) {
5744
      case SUCCESS:
5745
        return isSetSuccess();
5746
      case PE:
5747
        return isSetPe();
5748
      }
5749
      throw new IllegalStateException();
5750
    }
5751
 
5752
    @Override
5753
    public boolean equals(Object that) {
5754
      if (that == null)
5755
        return false;
5756
      if (that instanceof getPaymentsByCapturedDate_result)
5757
        return this.equals((getPaymentsByCapturedDate_result)that);
5758
      return false;
5759
    }
5760
 
5761
    public boolean equals(getPaymentsByCapturedDate_result that) {
5762
      if (that == null)
5763
        return false;
5764
 
5765
      boolean this_present_success = true && this.isSetSuccess();
5766
      boolean that_present_success = true && that.isSetSuccess();
5767
      if (this_present_success || that_present_success) {
5768
        if (!(this_present_success && that_present_success))
5769
          return false;
5770
        if (!this.success.equals(that.success))
5771
          return false;
5772
      }
5773
 
5774
      boolean this_present_pe = true && this.isSetPe();
5775
      boolean that_present_pe = true && that.isSetPe();
5776
      if (this_present_pe || that_present_pe) {
5777
        if (!(this_present_pe && that_present_pe))
5778
          return false;
5779
        if (!this.pe.equals(that.pe))
5780
          return false;
5781
      }
5782
 
5783
      return true;
5784
    }
5785
 
5786
    @Override
5787
    public int hashCode() {
5788
      return 0;
5789
    }
5790
 
5791
    public int compareTo(getPaymentsByCapturedDate_result other) {
5792
      if (!getClass().equals(other.getClass())) {
5793
        return getClass().getName().compareTo(other.getClass().getName());
5794
      }
5795
 
5796
      int lastComparison = 0;
5797
      getPaymentsByCapturedDate_result typedOther = (getPaymentsByCapturedDate_result)other;
5798
 
5799
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
5800
      if (lastComparison != 0) {
5801
        return lastComparison;
5802
      }
5803
      if (isSetSuccess()) {
5804
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
5805
        if (lastComparison != 0) {
5806
          return lastComparison;
5807
        }
5808
      }
5809
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
5810
      if (lastComparison != 0) {
5811
        return lastComparison;
5812
      }
5813
      if (isSetPe()) {
5814
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
5815
        if (lastComparison != 0) {
5816
          return lastComparison;
5817
        }
5818
      }
5819
      return 0;
5820
    }
5821
 
5822
    public _Fields fieldForId(int fieldId) {
5823
      return _Fields.findByThriftId(fieldId);
5824
    }
5825
 
5826
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5827
      org.apache.thrift.protocol.TField field;
5828
      iprot.readStructBegin();
5829
      while (true)
5830
      {
5831
        field = iprot.readFieldBegin();
5832
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5833
          break;
5834
        }
5835
        switch (field.id) {
5836
          case 0: // SUCCESS
5837
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
5838
              {
5839
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
5840
                this.success = new ArrayList<Payment>(_list20.size);
5841
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
5842
                {
5843
                  Payment _elem22; // required
5844
                  _elem22 = new Payment();
5845
                  _elem22.read(iprot);
5846
                  this.success.add(_elem22);
5847
                }
5848
                iprot.readListEnd();
5849
              }
5850
            } else { 
5851
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5852
            }
5853
            break;
5854
          case 1: // PE
5855
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5856
              this.pe = new PaymentException();
5857
              this.pe.read(iprot);
5858
            } else { 
5859
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5860
            }
5861
            break;
5862
          default:
5863
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5864
        }
5865
        iprot.readFieldEnd();
5866
      }
5867
      iprot.readStructEnd();
5868
      validate();
5869
    }
5870
 
5871
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5872
      oprot.writeStructBegin(STRUCT_DESC);
5873
 
5874
      if (this.isSetSuccess()) {
5875
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
5876
        {
5877
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
5878
          for (Payment _iter23 : this.success)
5879
          {
5880
            _iter23.write(oprot);
5881
          }
5882
          oprot.writeListEnd();
5883
        }
5884
        oprot.writeFieldEnd();
5885
      } else if (this.isSetPe()) {
5886
        oprot.writeFieldBegin(PE_FIELD_DESC);
5887
        this.pe.write(oprot);
5888
        oprot.writeFieldEnd();
5889
      }
5890
      oprot.writeFieldStop();
5891
      oprot.writeStructEnd();
5892
    }
5893
 
5894
    @Override
5895
    public String toString() {
5896
      StringBuilder sb = new StringBuilder("getPaymentsByCapturedDate_result(");
5897
      boolean first = true;
5898
 
5899
      sb.append("success:");
5900
      if (this.success == null) {
5901
        sb.append("null");
5902
      } else {
5903
        sb.append(this.success);
5904
      }
5905
      first = false;
5906
      if (!first) sb.append(", ");
5907
      sb.append("pe:");
5908
      if (this.pe == null) {
5909
        sb.append("null");
5910
      } else {
5911
        sb.append(this.pe);
5912
      }
5913
      first = false;
5914
      sb.append(")");
5915
      return sb.toString();
5916
    }
5917
 
5918
    public void validate() throws org.apache.thrift.TException {
5919
      // check for required fields
5920
    }
5921
 
5922
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5923
      try {
5924
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5925
      } catch (org.apache.thrift.TException te) {
5926
        throw new java.io.IOException(te);
5927
      }
5928
    }
5929
 
5930
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5931
      try {
5932
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5933
      } catch (org.apache.thrift.TException te) {
5934
        throw new java.io.IOException(te);
5935
      }
5936
    }
5937
 
5938
  }
5939
 
3430 rajveer 5940
  public static class getPaymentGateway_args implements org.apache.thrift.TBase<getPaymentGateway_args, getPaymentGateway_args._Fields>, java.io.Serializable, Cloneable   {
5941
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentGateway_args");
123 ashish 5942
 
3430 rajveer 5943
    private static final org.apache.thrift.protocol.TField ID_FIELD_DESC = new org.apache.thrift.protocol.TField("id", org.apache.thrift.protocol.TType.I64, (short)1);
123 ashish 5944
 
3430 rajveer 5945
    private long id; // required
123 ashish 5946
 
5947
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5948
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 5949
      ID((short)1, "id");
123 ashish 5950
 
5951
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5952
 
5953
      static {
5954
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5955
          byName.put(field.getFieldName(), field);
5956
        }
5957
      }
5958
 
5959
      /**
5960
       * Find the _Fields constant that matches fieldId, or null if its not found.
5961
       */
5962
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 5963
        switch(fieldId) {
5964
          case 1: // ID
5965
            return ID;
5966
          default:
5967
            return null;
5968
        }
123 ashish 5969
      }
5970
 
5971
      /**
5972
       * Find the _Fields constant that matches fieldId, throwing an exception
5973
       * if it is not found.
5974
       */
5975
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5976
        _Fields fields = findByThriftId(fieldId);
5977
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5978
        return fields;
5979
      }
5980
 
5981
      /**
5982
       * Find the _Fields constant that matches name, or null if its not found.
5983
       */
5984
      public static _Fields findByName(String name) {
5985
        return byName.get(name);
5986
      }
5987
 
5988
      private final short _thriftId;
5989
      private final String _fieldName;
5990
 
5991
      _Fields(short thriftId, String fieldName) {
5992
        _thriftId = thriftId;
5993
        _fieldName = fieldName;
5994
      }
5995
 
5996
      public short getThriftFieldId() {
5997
        return _thriftId;
5998
      }
5999
 
6000
      public String getFieldName() {
6001
        return _fieldName;
6002
      }
6003
    }
6004
 
6005
    // isset id assignments
420 ashish 6006
    private static final int __ID_ISSET_ID = 0;
123 ashish 6007
    private BitSet __isset_bit_vector = new BitSet(1);
6008
 
3430 rajveer 6009
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 6010
    static {
3430 rajveer 6011
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6012
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6013
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6014
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6015
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentGateway_args.class, metaDataMap);
123 ashish 6016
    }
6017
 
695 rajveer 6018
    public getPaymentGateway_args() {
123 ashish 6019
    }
6020
 
695 rajveer 6021
    public getPaymentGateway_args(
6022
      long id)
123 ashish 6023
    {
6024
      this();
420 ashish 6025
      this.id = id;
6026
      setIdIsSet(true);
123 ashish 6027
    }
6028
 
6029
    /**
6030
     * Performs a deep copy on <i>other</i>.
6031
     */
695 rajveer 6032
    public getPaymentGateway_args(getPaymentGateway_args other) {
123 ashish 6033
      __isset_bit_vector.clear();
6034
      __isset_bit_vector.or(other.__isset_bit_vector);
420 ashish 6035
      this.id = other.id;
123 ashish 6036
    }
6037
 
695 rajveer 6038
    public getPaymentGateway_args deepCopy() {
6039
      return new getPaymentGateway_args(this);
123 ashish 6040
    }
6041
 
3430 rajveer 6042
    @Override
6043
    public void clear() {
6044
      setIdIsSet(false);
6045
      this.id = 0;
123 ashish 6046
    }
6047
 
420 ashish 6048
    public long getId() {
6049
      return this.id;
123 ashish 6050
    }
6051
 
3430 rajveer 6052
    public void setId(long id) {
420 ashish 6053
      this.id = id;
6054
      setIdIsSet(true);
123 ashish 6055
    }
6056
 
420 ashish 6057
    public void unsetId() {
6058
      __isset_bit_vector.clear(__ID_ISSET_ID);
123 ashish 6059
    }
6060
 
3430 rajveer 6061
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 6062
    public boolean isSetId() {
6063
      return __isset_bit_vector.get(__ID_ISSET_ID);
123 ashish 6064
    }
6065
 
420 ashish 6066
    public void setIdIsSet(boolean value) {
6067
      __isset_bit_vector.set(__ID_ISSET_ID, value);
123 ashish 6068
    }
6069
 
6070
    public void setFieldValue(_Fields field, Object value) {
6071
      switch (field) {
420 ashish 6072
      case ID:
123 ashish 6073
        if (value == null) {
420 ashish 6074
          unsetId();
123 ashish 6075
        } else {
420 ashish 6076
          setId((Long)value);
123 ashish 6077
        }
6078
        break;
6079
 
6080
      }
6081
    }
6082
 
6083
    public Object getFieldValue(_Fields field) {
6084
      switch (field) {
420 ashish 6085
      case ID:
3430 rajveer 6086
        return Long.valueOf(getId());
123 ashish 6087
 
6088
      }
6089
      throw new IllegalStateException();
6090
    }
6091
 
3430 rajveer 6092
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6093
    public boolean isSet(_Fields field) {
6094
      if (field == null) {
6095
        throw new IllegalArgumentException();
6096
      }
123 ashish 6097
 
6098
      switch (field) {
420 ashish 6099
      case ID:
6100
        return isSetId();
123 ashish 6101
      }
6102
      throw new IllegalStateException();
6103
    }
6104
 
6105
    @Override
6106
    public boolean equals(Object that) {
6107
      if (that == null)
6108
        return false;
695 rajveer 6109
      if (that instanceof getPaymentGateway_args)
6110
        return this.equals((getPaymentGateway_args)that);
123 ashish 6111
      return false;
6112
    }
6113
 
695 rajveer 6114
    public boolean equals(getPaymentGateway_args that) {
123 ashish 6115
      if (that == null)
6116
        return false;
6117
 
420 ashish 6118
      boolean this_present_id = true;
6119
      boolean that_present_id = true;
6120
      if (this_present_id || that_present_id) {
6121
        if (!(this_present_id && that_present_id))
123 ashish 6122
          return false;
420 ashish 6123
        if (this.id != that.id)
123 ashish 6124
          return false;
6125
      }
6126
 
6127
      return true;
6128
    }
6129
 
6130
    @Override
6131
    public int hashCode() {
6132
      return 0;
6133
    }
6134
 
695 rajveer 6135
    public int compareTo(getPaymentGateway_args other) {
123 ashish 6136
      if (!getClass().equals(other.getClass())) {
6137
        return getClass().getName().compareTo(other.getClass().getName());
6138
      }
6139
 
6140
      int lastComparison = 0;
695 rajveer 6141
      getPaymentGateway_args typedOther = (getPaymentGateway_args)other;
123 ashish 6142
 
3430 rajveer 6143
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
123 ashish 6144
      if (lastComparison != 0) {
6145
        return lastComparison;
6146
      }
3430 rajveer 6147
      if (isSetId()) {
6148
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
6149
        if (lastComparison != 0) {
6150
          return lastComparison;
6151
        }
123 ashish 6152
      }
6153
      return 0;
6154
    }
6155
 
3430 rajveer 6156
    public _Fields fieldForId(int fieldId) {
6157
      return _Fields.findByThriftId(fieldId);
6158
    }
6159
 
6160
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6161
      org.apache.thrift.protocol.TField field;
123 ashish 6162
      iprot.readStructBegin();
6163
      while (true)
6164
      {
6165
        field = iprot.readFieldBegin();
3430 rajveer 6166
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 6167
          break;
6168
        }
3430 rajveer 6169
        switch (field.id) {
6170
          case 1: // ID
6171
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6172
              this.id = iprot.readI64();
6173
              setIdIsSet(true);
6174
            } else { 
6175
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6176
            }
6177
            break;
6178
          default:
6179
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 6180
        }
3430 rajveer 6181
        iprot.readFieldEnd();
123 ashish 6182
      }
6183
      iprot.readStructEnd();
6184
      validate();
6185
    }
6186
 
3430 rajveer 6187
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 6188
      validate();
6189
 
6190
      oprot.writeStructBegin(STRUCT_DESC);
420 ashish 6191
      oprot.writeFieldBegin(ID_FIELD_DESC);
6192
      oprot.writeI64(this.id);
123 ashish 6193
      oprot.writeFieldEnd();
6194
      oprot.writeFieldStop();
6195
      oprot.writeStructEnd();
6196
    }
6197
 
6198
    @Override
6199
    public String toString() {
695 rajveer 6200
      StringBuilder sb = new StringBuilder("getPaymentGateway_args(");
123 ashish 6201
      boolean first = true;
6202
 
420 ashish 6203
      sb.append("id:");
6204
      sb.append(this.id);
123 ashish 6205
      first = false;
6206
      sb.append(")");
6207
      return sb.toString();
6208
    }
6209
 
3430 rajveer 6210
    public void validate() throws org.apache.thrift.TException {
123 ashish 6211
      // check for required fields
6212
    }
6213
 
3430 rajveer 6214
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6215
      try {
6216
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6217
      } catch (org.apache.thrift.TException te) {
6218
        throw new java.io.IOException(te);
6219
      }
6220
    }
6221
 
6222
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6223
      try {
6224
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6225
        __isset_bit_vector = new BitSet(1);
6226
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6227
      } catch (org.apache.thrift.TException te) {
6228
        throw new java.io.IOException(te);
6229
      }
6230
    }
6231
 
123 ashish 6232
  }
6233
 
3430 rajveer 6234
  public static class getPaymentGateway_result implements org.apache.thrift.TBase<getPaymentGateway_result, getPaymentGateway_result._Fields>, java.io.Serializable, Cloneable   {
6235
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentGateway_result");
123 ashish 6236
 
3430 rajveer 6237
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
6238
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
123 ashish 6239
 
3430 rajveer 6240
    private PaymentGateway success; // required
6241
    private PaymentException pe; // required
123 ashish 6242
 
6243
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6244
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 6245
      SUCCESS((short)0, "success"),
6246
      PE((short)1, "pe");
6247
 
6248
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6249
 
6250
      static {
6251
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6252
          byName.put(field.getFieldName(), field);
6253
        }
6254
      }
6255
 
6256
      /**
6257
       * Find the _Fields constant that matches fieldId, or null if its not found.
6258
       */
6259
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6260
        switch(fieldId) {
6261
          case 0: // SUCCESS
6262
            return SUCCESS;
6263
          case 1: // PE
6264
            return PE;
6265
          default:
6266
            return null;
6267
        }
420 ashish 6268
      }
6269
 
6270
      /**
6271
       * Find the _Fields constant that matches fieldId, throwing an exception
6272
       * if it is not found.
6273
       */
6274
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6275
        _Fields fields = findByThriftId(fieldId);
6276
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6277
        return fields;
6278
      }
6279
 
6280
      /**
6281
       * Find the _Fields constant that matches name, or null if its not found.
6282
       */
6283
      public static _Fields findByName(String name) {
6284
        return byName.get(name);
6285
      }
6286
 
6287
      private final short _thriftId;
6288
      private final String _fieldName;
6289
 
6290
      _Fields(short thriftId, String fieldName) {
6291
        _thriftId = thriftId;
6292
        _fieldName = fieldName;
6293
      }
6294
 
6295
      public short getThriftFieldId() {
6296
        return _thriftId;
6297
      }
6298
 
6299
      public String getFieldName() {
6300
        return _fieldName;
6301
      }
6302
    }
6303
 
6304
    // isset id assignments
6305
 
3430 rajveer 6306
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 6307
    static {
3430 rajveer 6308
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6309
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6310
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PaymentGateway.class)));
6311
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6312
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6313
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6314
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentGateway_result.class, metaDataMap);
420 ashish 6315
    }
6316
 
695 rajveer 6317
    public getPaymentGateway_result() {
420 ashish 6318
    }
6319
 
695 rajveer 6320
    public getPaymentGateway_result(
6321
      PaymentGateway success,
420 ashish 6322
      PaymentException pe)
6323
    {
6324
      this();
6325
      this.success = success;
6326
      this.pe = pe;
6327
    }
6328
 
6329
    /**
6330
     * Performs a deep copy on <i>other</i>.
6331
     */
695 rajveer 6332
    public getPaymentGateway_result(getPaymentGateway_result other) {
420 ashish 6333
      if (other.isSetSuccess()) {
695 rajveer 6334
        this.success = new PaymentGateway(other.success);
420 ashish 6335
      }
6336
      if (other.isSetPe()) {
6337
        this.pe = new PaymentException(other.pe);
6338
      }
6339
    }
6340
 
695 rajveer 6341
    public getPaymentGateway_result deepCopy() {
6342
      return new getPaymentGateway_result(this);
420 ashish 6343
    }
6344
 
3430 rajveer 6345
    @Override
6346
    public void clear() {
6347
      this.success = null;
6348
      this.pe = null;
420 ashish 6349
    }
6350
 
695 rajveer 6351
    public PaymentGateway getSuccess() {
420 ashish 6352
      return this.success;
6353
    }
6354
 
3430 rajveer 6355
    public void setSuccess(PaymentGateway success) {
420 ashish 6356
      this.success = success;
6357
    }
6358
 
6359
    public void unsetSuccess() {
6360
      this.success = null;
6361
    }
6362
 
3430 rajveer 6363
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 6364
    public boolean isSetSuccess() {
6365
      return this.success != null;
6366
    }
6367
 
6368
    public void setSuccessIsSet(boolean value) {
6369
      if (!value) {
6370
        this.success = null;
6371
      }
6372
    }
6373
 
6374
    public PaymentException getPe() {
6375
      return this.pe;
6376
    }
6377
 
3430 rajveer 6378
    public void setPe(PaymentException pe) {
420 ashish 6379
      this.pe = pe;
6380
    }
6381
 
6382
    public void unsetPe() {
6383
      this.pe = null;
6384
    }
6385
 
3430 rajveer 6386
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 6387
    public boolean isSetPe() {
6388
      return this.pe != null;
6389
    }
6390
 
6391
    public void setPeIsSet(boolean value) {
6392
      if (!value) {
6393
        this.pe = null;
6394
      }
6395
    }
6396
 
6397
    public void setFieldValue(_Fields field, Object value) {
6398
      switch (field) {
6399
      case SUCCESS:
6400
        if (value == null) {
6401
          unsetSuccess();
6402
        } else {
695 rajveer 6403
          setSuccess((PaymentGateway)value);
420 ashish 6404
        }
6405
        break;
6406
 
6407
      case PE:
6408
        if (value == null) {
6409
          unsetPe();
6410
        } else {
6411
          setPe((PaymentException)value);
6412
        }
6413
        break;
6414
 
6415
      }
6416
    }
6417
 
6418
    public Object getFieldValue(_Fields field) {
6419
      switch (field) {
6420
      case SUCCESS:
6421
        return getSuccess();
6422
 
6423
      case PE:
6424
        return getPe();
6425
 
6426
      }
6427
      throw new IllegalStateException();
6428
    }
6429
 
3430 rajveer 6430
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6431
    public boolean isSet(_Fields field) {
6432
      if (field == null) {
6433
        throw new IllegalArgumentException();
6434
      }
420 ashish 6435
 
6436
      switch (field) {
6437
      case SUCCESS:
6438
        return isSetSuccess();
6439
      case PE:
6440
        return isSetPe();
6441
      }
6442
      throw new IllegalStateException();
6443
    }
6444
 
6445
    @Override
6446
    public boolean equals(Object that) {
6447
      if (that == null)
6448
        return false;
695 rajveer 6449
      if (that instanceof getPaymentGateway_result)
6450
        return this.equals((getPaymentGateway_result)that);
420 ashish 6451
      return false;
6452
    }
6453
 
695 rajveer 6454
    public boolean equals(getPaymentGateway_result that) {
420 ashish 6455
      if (that == null)
6456
        return false;
6457
 
6458
      boolean this_present_success = true && this.isSetSuccess();
6459
      boolean that_present_success = true && that.isSetSuccess();
6460
      if (this_present_success || that_present_success) {
6461
        if (!(this_present_success && that_present_success))
6462
          return false;
6463
        if (!this.success.equals(that.success))
6464
          return false;
6465
      }
6466
 
6467
      boolean this_present_pe = true && this.isSetPe();
6468
      boolean that_present_pe = true && that.isSetPe();
6469
      if (this_present_pe || that_present_pe) {
6470
        if (!(this_present_pe && that_present_pe))
6471
          return false;
6472
        if (!this.pe.equals(that.pe))
6473
          return false;
6474
      }
6475
 
6476
      return true;
6477
    }
6478
 
6479
    @Override
6480
    public int hashCode() {
6481
      return 0;
6482
    }
6483
 
695 rajveer 6484
    public int compareTo(getPaymentGateway_result other) {
6485
      if (!getClass().equals(other.getClass())) {
6486
        return getClass().getName().compareTo(other.getClass().getName());
6487
      }
6488
 
6489
      int lastComparison = 0;
6490
      getPaymentGateway_result typedOther = (getPaymentGateway_result)other;
6491
 
3430 rajveer 6492
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 6493
      if (lastComparison != 0) {
6494
        return lastComparison;
6495
      }
3430 rajveer 6496
      if (isSetSuccess()) {
6497
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6498
        if (lastComparison != 0) {
6499
          return lastComparison;
6500
        }
695 rajveer 6501
      }
3430 rajveer 6502
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 6503
      if (lastComparison != 0) {
6504
        return lastComparison;
6505
      }
3430 rajveer 6506
      if (isSetPe()) {
6507
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
6508
        if (lastComparison != 0) {
6509
          return lastComparison;
6510
        }
695 rajveer 6511
      }
6512
      return 0;
6513
    }
6514
 
3430 rajveer 6515
    public _Fields fieldForId(int fieldId) {
6516
      return _Fields.findByThriftId(fieldId);
6517
    }
6518
 
6519
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6520
      org.apache.thrift.protocol.TField field;
420 ashish 6521
      iprot.readStructBegin();
6522
      while (true)
6523
      {
6524
        field = iprot.readFieldBegin();
3430 rajveer 6525
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 6526
          break;
6527
        }
3430 rajveer 6528
        switch (field.id) {
6529
          case 0: // SUCCESS
6530
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6531
              this.success = new PaymentGateway();
6532
              this.success.read(iprot);
6533
            } else { 
6534
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6535
            }
6536
            break;
6537
          case 1: // PE
6538
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6539
              this.pe = new PaymentException();
6540
              this.pe.read(iprot);
6541
            } else { 
6542
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6543
            }
6544
            break;
6545
          default:
6546
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 6547
        }
3430 rajveer 6548
        iprot.readFieldEnd();
420 ashish 6549
      }
6550
      iprot.readStructEnd();
6551
      validate();
6552
    }
6553
 
3430 rajveer 6554
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 6555
      oprot.writeStructBegin(STRUCT_DESC);
6556
 
6557
      if (this.isSetSuccess()) {
6558
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
695 rajveer 6559
        this.success.write(oprot);
420 ashish 6560
        oprot.writeFieldEnd();
6561
      } else if (this.isSetPe()) {
6562
        oprot.writeFieldBegin(PE_FIELD_DESC);
6563
        this.pe.write(oprot);
6564
        oprot.writeFieldEnd();
6565
      }
6566
      oprot.writeFieldStop();
6567
      oprot.writeStructEnd();
6568
    }
6569
 
6570
    @Override
6571
    public String toString() {
695 rajveer 6572
      StringBuilder sb = new StringBuilder("getPaymentGateway_result(");
420 ashish 6573
      boolean first = true;
6574
 
6575
      sb.append("success:");
6576
      if (this.success == null) {
6577
        sb.append("null");
6578
      } else {
6579
        sb.append(this.success);
6580
      }
6581
      first = false;
6582
      if (!first) sb.append(", ");
6583
      sb.append("pe:");
6584
      if (this.pe == null) {
6585
        sb.append("null");
6586
      } else {
6587
        sb.append(this.pe);
6588
      }
6589
      first = false;
6590
      sb.append(")");
6591
      return sb.toString();
6592
    }
6593
 
3430 rajveer 6594
    public void validate() throws org.apache.thrift.TException {
420 ashish 6595
      // check for required fields
6596
    }
6597
 
3430 rajveer 6598
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6599
      try {
6600
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6601
      } catch (org.apache.thrift.TException te) {
6602
        throw new java.io.IOException(te);
6603
      }
6604
    }
6605
 
6606
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6607
      try {
6608
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6609
      } catch (org.apache.thrift.TException te) {
6610
        throw new java.io.IOException(te);
6611
      }
6612
    }
6613
 
420 ashish 6614
  }
6615
 
4600 varun.gupt 6616
  public static class getActivePaymentGateways_args implements org.apache.thrift.TBase<getActivePaymentGateways_args, getActivePaymentGateways_args._Fields>, java.io.Serializable, Cloneable   {
6617
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getActivePaymentGateways_args");
6618
 
6619
 
6620
 
6621
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6622
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6623
;
6624
 
6625
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6626
 
6627
      static {
6628
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6629
          byName.put(field.getFieldName(), field);
6630
        }
6631
      }
6632
 
6633
      /**
6634
       * Find the _Fields constant that matches fieldId, or null if its not found.
6635
       */
6636
      public static _Fields findByThriftId(int fieldId) {
6637
        switch(fieldId) {
6638
          default:
6639
            return null;
6640
        }
6641
      }
6642
 
6643
      /**
6644
       * Find the _Fields constant that matches fieldId, throwing an exception
6645
       * if it is not found.
6646
       */
6647
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6648
        _Fields fields = findByThriftId(fieldId);
6649
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6650
        return fields;
6651
      }
6652
 
6653
      /**
6654
       * Find the _Fields constant that matches name, or null if its not found.
6655
       */
6656
      public static _Fields findByName(String name) {
6657
        return byName.get(name);
6658
      }
6659
 
6660
      private final short _thriftId;
6661
      private final String _fieldName;
6662
 
6663
      _Fields(short thriftId, String fieldName) {
6664
        _thriftId = thriftId;
6665
        _fieldName = fieldName;
6666
      }
6667
 
6668
      public short getThriftFieldId() {
6669
        return _thriftId;
6670
      }
6671
 
6672
      public String getFieldName() {
6673
        return _fieldName;
6674
      }
6675
    }
6676
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6677
    static {
6678
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6679
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6680
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getActivePaymentGateways_args.class, metaDataMap);
6681
    }
6682
 
6683
    public getActivePaymentGateways_args() {
6684
    }
6685
 
6686
    /**
6687
     * Performs a deep copy on <i>other</i>.
6688
     */
6689
    public getActivePaymentGateways_args(getActivePaymentGateways_args other) {
6690
    }
6691
 
6692
    public getActivePaymentGateways_args deepCopy() {
6693
      return new getActivePaymentGateways_args(this);
6694
    }
6695
 
6696
    @Override
6697
    public void clear() {
6698
    }
6699
 
6700
    public void setFieldValue(_Fields field, Object value) {
6701
      switch (field) {
6702
      }
6703
    }
6704
 
6705
    public Object getFieldValue(_Fields field) {
6706
      switch (field) {
6707
      }
6708
      throw new IllegalStateException();
6709
    }
6710
 
6711
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6712
    public boolean isSet(_Fields field) {
6713
      if (field == null) {
6714
        throw new IllegalArgumentException();
6715
      }
6716
 
6717
      switch (field) {
6718
      }
6719
      throw new IllegalStateException();
6720
    }
6721
 
6722
    @Override
6723
    public boolean equals(Object that) {
6724
      if (that == null)
6725
        return false;
6726
      if (that instanceof getActivePaymentGateways_args)
6727
        return this.equals((getActivePaymentGateways_args)that);
6728
      return false;
6729
    }
6730
 
6731
    public boolean equals(getActivePaymentGateways_args that) {
6732
      if (that == null)
6733
        return false;
6734
 
6735
      return true;
6736
    }
6737
 
6738
    @Override
6739
    public int hashCode() {
6740
      return 0;
6741
    }
6742
 
6743
    public int compareTo(getActivePaymentGateways_args other) {
6744
      if (!getClass().equals(other.getClass())) {
6745
        return getClass().getName().compareTo(other.getClass().getName());
6746
      }
6747
 
6748
      int lastComparison = 0;
6749
      getActivePaymentGateways_args typedOther = (getActivePaymentGateways_args)other;
6750
 
6751
      return 0;
6752
    }
6753
 
6754
    public _Fields fieldForId(int fieldId) {
6755
      return _Fields.findByThriftId(fieldId);
6756
    }
6757
 
6758
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6759
      org.apache.thrift.protocol.TField field;
6760
      iprot.readStructBegin();
6761
      while (true)
6762
      {
6763
        field = iprot.readFieldBegin();
6764
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6765
          break;
6766
        }
6767
        switch (field.id) {
6768
          default:
6769
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6770
        }
6771
        iprot.readFieldEnd();
6772
      }
6773
      iprot.readStructEnd();
6774
      validate();
6775
    }
6776
 
6777
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6778
      validate();
6779
 
6780
      oprot.writeStructBegin(STRUCT_DESC);
6781
      oprot.writeFieldStop();
6782
      oprot.writeStructEnd();
6783
    }
6784
 
6785
    @Override
6786
    public String toString() {
6787
      StringBuilder sb = new StringBuilder("getActivePaymentGateways_args(");
6788
      boolean first = true;
6789
 
6790
      sb.append(")");
6791
      return sb.toString();
6792
    }
6793
 
6794
    public void validate() throws org.apache.thrift.TException {
6795
      // check for required fields
6796
    }
6797
 
6798
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6799
      try {
6800
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6801
      } catch (org.apache.thrift.TException te) {
6802
        throw new java.io.IOException(te);
6803
      }
6804
    }
6805
 
6806
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6807
      try {
6808
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6809
      } catch (org.apache.thrift.TException te) {
6810
        throw new java.io.IOException(te);
6811
      }
6812
    }
6813
 
6814
  }
6815
 
6816
  public static class getActivePaymentGateways_result implements org.apache.thrift.TBase<getActivePaymentGateways_result, getActivePaymentGateways_result._Fields>, java.io.Serializable, Cloneable   {
6817
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getActivePaymentGateways_result");
6818
 
6819
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
6820
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
6821
 
6822
    private List<PaymentGateway> success; // required
6823
    private PaymentException pe; // required
6824
 
6825
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6826
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6827
      SUCCESS((short)0, "success"),
6828
      PE((short)1, "pe");
6829
 
6830
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6831
 
6832
      static {
6833
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6834
          byName.put(field.getFieldName(), field);
6835
        }
6836
      }
6837
 
6838
      /**
6839
       * Find the _Fields constant that matches fieldId, or null if its not found.
6840
       */
6841
      public static _Fields findByThriftId(int fieldId) {
6842
        switch(fieldId) {
6843
          case 0: // SUCCESS
6844
            return SUCCESS;
6845
          case 1: // PE
6846
            return PE;
6847
          default:
6848
            return null;
6849
        }
6850
      }
6851
 
6852
      /**
6853
       * Find the _Fields constant that matches fieldId, throwing an exception
6854
       * if it is not found.
6855
       */
6856
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6857
        _Fields fields = findByThriftId(fieldId);
6858
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6859
        return fields;
6860
      }
6861
 
6862
      /**
6863
       * Find the _Fields constant that matches name, or null if its not found.
6864
       */
6865
      public static _Fields findByName(String name) {
6866
        return byName.get(name);
6867
      }
6868
 
6869
      private final short _thriftId;
6870
      private final String _fieldName;
6871
 
6872
      _Fields(short thriftId, String fieldName) {
6873
        _thriftId = thriftId;
6874
        _fieldName = fieldName;
6875
      }
6876
 
6877
      public short getThriftFieldId() {
6878
        return _thriftId;
6879
      }
6880
 
6881
      public String getFieldName() {
6882
        return _fieldName;
6883
      }
6884
    }
6885
 
6886
    // isset id assignments
6887
 
6888
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6889
    static {
6890
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6891
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6892
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
6893
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PaymentGateway.class))));
6894
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6895
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6896
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6897
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getActivePaymentGateways_result.class, metaDataMap);
6898
    }
6899
 
6900
    public getActivePaymentGateways_result() {
6901
    }
6902
 
6903
    public getActivePaymentGateways_result(
6904
      List<PaymentGateway> success,
6905
      PaymentException pe)
6906
    {
6907
      this();
6908
      this.success = success;
6909
      this.pe = pe;
6910
    }
6911
 
6912
    /**
6913
     * Performs a deep copy on <i>other</i>.
6914
     */
6915
    public getActivePaymentGateways_result(getActivePaymentGateways_result other) {
6916
      if (other.isSetSuccess()) {
6917
        List<PaymentGateway> __this__success = new ArrayList<PaymentGateway>();
6918
        for (PaymentGateway other_element : other.success) {
6919
          __this__success.add(new PaymentGateway(other_element));
6920
        }
6921
        this.success = __this__success;
6922
      }
6923
      if (other.isSetPe()) {
6924
        this.pe = new PaymentException(other.pe);
6925
      }
6926
    }
6927
 
6928
    public getActivePaymentGateways_result deepCopy() {
6929
      return new getActivePaymentGateways_result(this);
6930
    }
6931
 
6932
    @Override
6933
    public void clear() {
6934
      this.success = null;
6935
      this.pe = null;
6936
    }
6937
 
6938
    public int getSuccessSize() {
6939
      return (this.success == null) ? 0 : this.success.size();
6940
    }
6941
 
6942
    public java.util.Iterator<PaymentGateway> getSuccessIterator() {
6943
      return (this.success == null) ? null : this.success.iterator();
6944
    }
6945
 
6946
    public void addToSuccess(PaymentGateway elem) {
6947
      if (this.success == null) {
6948
        this.success = new ArrayList<PaymentGateway>();
6949
      }
6950
      this.success.add(elem);
6951
    }
6952
 
6953
    public List<PaymentGateway> getSuccess() {
6954
      return this.success;
6955
    }
6956
 
6957
    public void setSuccess(List<PaymentGateway> success) {
6958
      this.success = success;
6959
    }
6960
 
6961
    public void unsetSuccess() {
6962
      this.success = null;
6963
    }
6964
 
6965
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
6966
    public boolean isSetSuccess() {
6967
      return this.success != null;
6968
    }
6969
 
6970
    public void setSuccessIsSet(boolean value) {
6971
      if (!value) {
6972
        this.success = null;
6973
      }
6974
    }
6975
 
6976
    public PaymentException getPe() {
6977
      return this.pe;
6978
    }
6979
 
6980
    public void setPe(PaymentException pe) {
6981
      this.pe = pe;
6982
    }
6983
 
6984
    public void unsetPe() {
6985
      this.pe = null;
6986
    }
6987
 
6988
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
6989
    public boolean isSetPe() {
6990
      return this.pe != null;
6991
    }
6992
 
6993
    public void setPeIsSet(boolean value) {
6994
      if (!value) {
6995
        this.pe = null;
6996
      }
6997
    }
6998
 
6999
    public void setFieldValue(_Fields field, Object value) {
7000
      switch (field) {
7001
      case SUCCESS:
7002
        if (value == null) {
7003
          unsetSuccess();
7004
        } else {
7005
          setSuccess((List<PaymentGateway>)value);
7006
        }
7007
        break;
7008
 
7009
      case PE:
7010
        if (value == null) {
7011
          unsetPe();
7012
        } else {
7013
          setPe((PaymentException)value);
7014
        }
7015
        break;
7016
 
7017
      }
7018
    }
7019
 
7020
    public Object getFieldValue(_Fields field) {
7021
      switch (field) {
7022
      case SUCCESS:
7023
        return getSuccess();
7024
 
7025
      case PE:
7026
        return getPe();
7027
 
7028
      }
7029
      throw new IllegalStateException();
7030
    }
7031
 
7032
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7033
    public boolean isSet(_Fields field) {
7034
      if (field == null) {
7035
        throw new IllegalArgumentException();
7036
      }
7037
 
7038
      switch (field) {
7039
      case SUCCESS:
7040
        return isSetSuccess();
7041
      case PE:
7042
        return isSetPe();
7043
      }
7044
      throw new IllegalStateException();
7045
    }
7046
 
7047
    @Override
7048
    public boolean equals(Object that) {
7049
      if (that == null)
7050
        return false;
7051
      if (that instanceof getActivePaymentGateways_result)
7052
        return this.equals((getActivePaymentGateways_result)that);
7053
      return false;
7054
    }
7055
 
7056
    public boolean equals(getActivePaymentGateways_result that) {
7057
      if (that == null)
7058
        return false;
7059
 
7060
      boolean this_present_success = true && this.isSetSuccess();
7061
      boolean that_present_success = true && that.isSetSuccess();
7062
      if (this_present_success || that_present_success) {
7063
        if (!(this_present_success && that_present_success))
7064
          return false;
7065
        if (!this.success.equals(that.success))
7066
          return false;
7067
      }
7068
 
7069
      boolean this_present_pe = true && this.isSetPe();
7070
      boolean that_present_pe = true && that.isSetPe();
7071
      if (this_present_pe || that_present_pe) {
7072
        if (!(this_present_pe && that_present_pe))
7073
          return false;
7074
        if (!this.pe.equals(that.pe))
7075
          return false;
7076
      }
7077
 
7078
      return true;
7079
    }
7080
 
7081
    @Override
7082
    public int hashCode() {
7083
      return 0;
7084
    }
7085
 
7086
    public int compareTo(getActivePaymentGateways_result other) {
7087
      if (!getClass().equals(other.getClass())) {
7088
        return getClass().getName().compareTo(other.getClass().getName());
7089
      }
7090
 
7091
      int lastComparison = 0;
7092
      getActivePaymentGateways_result typedOther = (getActivePaymentGateways_result)other;
7093
 
7094
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
7095
      if (lastComparison != 0) {
7096
        return lastComparison;
7097
      }
7098
      if (isSetSuccess()) {
7099
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7100
        if (lastComparison != 0) {
7101
          return lastComparison;
7102
        }
7103
      }
7104
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
7105
      if (lastComparison != 0) {
7106
        return lastComparison;
7107
      }
7108
      if (isSetPe()) {
7109
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
7110
        if (lastComparison != 0) {
7111
          return lastComparison;
7112
        }
7113
      }
7114
      return 0;
7115
    }
7116
 
7117
    public _Fields fieldForId(int fieldId) {
7118
      return _Fields.findByThriftId(fieldId);
7119
    }
7120
 
7121
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7122
      org.apache.thrift.protocol.TField field;
7123
      iprot.readStructBegin();
7124
      while (true)
7125
      {
7126
        field = iprot.readFieldBegin();
7127
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7128
          break;
7129
        }
7130
        switch (field.id) {
7131
          case 0: // SUCCESS
7132
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
7133
              {
7134
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
7135
                this.success = new ArrayList<PaymentGateway>(_list24.size);
7136
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
7137
                {
7138
                  PaymentGateway _elem26; // required
7139
                  _elem26 = new PaymentGateway();
7140
                  _elem26.read(iprot);
7141
                  this.success.add(_elem26);
7142
                }
7143
                iprot.readListEnd();
7144
              }
7145
            } else { 
7146
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7147
            }
7148
            break;
7149
          case 1: // PE
7150
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7151
              this.pe = new PaymentException();
7152
              this.pe.read(iprot);
7153
            } else { 
7154
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7155
            }
7156
            break;
7157
          default:
7158
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7159
        }
7160
        iprot.readFieldEnd();
7161
      }
7162
      iprot.readStructEnd();
7163
      validate();
7164
    }
7165
 
7166
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7167
      oprot.writeStructBegin(STRUCT_DESC);
7168
 
7169
      if (this.isSetSuccess()) {
7170
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7171
        {
7172
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
7173
          for (PaymentGateway _iter27 : this.success)
7174
          {
7175
            _iter27.write(oprot);
7176
          }
7177
          oprot.writeListEnd();
7178
        }
7179
        oprot.writeFieldEnd();
7180
      } else if (this.isSetPe()) {
7181
        oprot.writeFieldBegin(PE_FIELD_DESC);
7182
        this.pe.write(oprot);
7183
        oprot.writeFieldEnd();
7184
      }
7185
      oprot.writeFieldStop();
7186
      oprot.writeStructEnd();
7187
    }
7188
 
7189
    @Override
7190
    public String toString() {
7191
      StringBuilder sb = new StringBuilder("getActivePaymentGateways_result(");
7192
      boolean first = true;
7193
 
7194
      sb.append("success:");
7195
      if (this.success == null) {
7196
        sb.append("null");
7197
      } else {
7198
        sb.append(this.success);
7199
      }
7200
      first = false;
7201
      if (!first) sb.append(", ");
7202
      sb.append("pe:");
7203
      if (this.pe == null) {
7204
        sb.append("null");
7205
      } else {
7206
        sb.append(this.pe);
7207
      }
7208
      first = false;
7209
      sb.append(")");
7210
      return sb.toString();
7211
    }
7212
 
7213
    public void validate() throws org.apache.thrift.TException {
7214
      // check for required fields
7215
    }
7216
 
7217
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7218
      try {
7219
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7220
      } catch (org.apache.thrift.TException te) {
7221
        throw new java.io.IOException(te);
7222
      }
7223
    }
7224
 
7225
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7226
      try {
7227
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7228
      } catch (org.apache.thrift.TException te) {
7229
        throw new java.io.IOException(te);
7230
      }
7231
    }
7232
 
7233
  }
7234
 
3430 rajveer 7235
  public static class getPayment_args implements org.apache.thrift.TBase<getPayment_args, getPayment_args._Fields>, java.io.Serializable, Cloneable   {
7236
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayment_args");
420 ashish 7237
 
3430 rajveer 7238
    private static final org.apache.thrift.protocol.TField ID_FIELD_DESC = new org.apache.thrift.protocol.TField("id", org.apache.thrift.protocol.TType.I64, (short)1);
420 ashish 7239
 
3430 rajveer 7240
    private long id; // required
420 ashish 7241
 
7242
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7243
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 7244
      ID((short)1, "id");
7245
 
7246
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7247
 
7248
      static {
7249
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7250
          byName.put(field.getFieldName(), field);
7251
        }
7252
      }
7253
 
7254
      /**
7255
       * Find the _Fields constant that matches fieldId, or null if its not found.
7256
       */
7257
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7258
        switch(fieldId) {
7259
          case 1: // ID
7260
            return ID;
7261
          default:
7262
            return null;
7263
        }
420 ashish 7264
      }
7265
 
7266
      /**
7267
       * Find the _Fields constant that matches fieldId, throwing an exception
7268
       * if it is not found.
7269
       */
7270
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7271
        _Fields fields = findByThriftId(fieldId);
7272
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7273
        return fields;
7274
      }
7275
 
7276
      /**
7277
       * Find the _Fields constant that matches name, or null if its not found.
7278
       */
7279
      public static _Fields findByName(String name) {
7280
        return byName.get(name);
7281
      }
7282
 
7283
      private final short _thriftId;
7284
      private final String _fieldName;
7285
 
7286
      _Fields(short thriftId, String fieldName) {
7287
        _thriftId = thriftId;
7288
        _fieldName = fieldName;
7289
      }
7290
 
7291
      public short getThriftFieldId() {
7292
        return _thriftId;
7293
      }
7294
 
7295
      public String getFieldName() {
7296
        return _fieldName;
7297
      }
7298
    }
7299
 
7300
    // isset id assignments
7301
    private static final int __ID_ISSET_ID = 0;
7302
    private BitSet __isset_bit_vector = new BitSet(1);
7303
 
3430 rajveer 7304
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 7305
    static {
3430 rajveer 7306
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7307
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7308
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7309
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7310
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayment_args.class, metaDataMap);
420 ashish 7311
    }
7312
 
695 rajveer 7313
    public getPayment_args() {
420 ashish 7314
    }
7315
 
695 rajveer 7316
    public getPayment_args(
420 ashish 7317
      long id)
7318
    {
7319
      this();
7320
      this.id = id;
7321
      setIdIsSet(true);
7322
    }
7323
 
7324
    /**
7325
     * Performs a deep copy on <i>other</i>.
7326
     */
695 rajveer 7327
    public getPayment_args(getPayment_args other) {
420 ashish 7328
      __isset_bit_vector.clear();
7329
      __isset_bit_vector.or(other.__isset_bit_vector);
7330
      this.id = other.id;
7331
    }
7332
 
695 rajveer 7333
    public getPayment_args deepCopy() {
7334
      return new getPayment_args(this);
420 ashish 7335
    }
7336
 
3430 rajveer 7337
    @Override
7338
    public void clear() {
7339
      setIdIsSet(false);
7340
      this.id = 0;
420 ashish 7341
    }
7342
 
7343
    public long getId() {
7344
      return this.id;
7345
    }
7346
 
3430 rajveer 7347
    public void setId(long id) {
420 ashish 7348
      this.id = id;
7349
      setIdIsSet(true);
7350
    }
7351
 
7352
    public void unsetId() {
7353
      __isset_bit_vector.clear(__ID_ISSET_ID);
7354
    }
7355
 
3430 rajveer 7356
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 7357
    public boolean isSetId() {
7358
      return __isset_bit_vector.get(__ID_ISSET_ID);
7359
    }
7360
 
7361
    public void setIdIsSet(boolean value) {
7362
      __isset_bit_vector.set(__ID_ISSET_ID, value);
7363
    }
7364
 
7365
    public void setFieldValue(_Fields field, Object value) {
7366
      switch (field) {
7367
      case ID:
7368
        if (value == null) {
7369
          unsetId();
7370
        } else {
7371
          setId((Long)value);
7372
        }
7373
        break;
7374
 
7375
      }
7376
    }
7377
 
7378
    public Object getFieldValue(_Fields field) {
7379
      switch (field) {
7380
      case ID:
3430 rajveer 7381
        return Long.valueOf(getId());
420 ashish 7382
 
7383
      }
7384
      throw new IllegalStateException();
7385
    }
7386
 
3430 rajveer 7387
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7388
    public boolean isSet(_Fields field) {
7389
      if (field == null) {
7390
        throw new IllegalArgumentException();
7391
      }
420 ashish 7392
 
7393
      switch (field) {
7394
      case ID:
7395
        return isSetId();
7396
      }
7397
      throw new IllegalStateException();
7398
    }
7399
 
7400
    @Override
7401
    public boolean equals(Object that) {
7402
      if (that == null)
7403
        return false;
695 rajveer 7404
      if (that instanceof getPayment_args)
7405
        return this.equals((getPayment_args)that);
420 ashish 7406
      return false;
7407
    }
7408
 
695 rajveer 7409
    public boolean equals(getPayment_args that) {
420 ashish 7410
      if (that == null)
7411
        return false;
7412
 
7413
      boolean this_present_id = true;
7414
      boolean that_present_id = true;
7415
      if (this_present_id || that_present_id) {
7416
        if (!(this_present_id && that_present_id))
7417
          return false;
7418
        if (this.id != that.id)
7419
          return false;
7420
      }
7421
 
7422
      return true;
7423
    }
7424
 
7425
    @Override
7426
    public int hashCode() {
7427
      return 0;
7428
    }
7429
 
695 rajveer 7430
    public int compareTo(getPayment_args other) {
420 ashish 7431
      if (!getClass().equals(other.getClass())) {
7432
        return getClass().getName().compareTo(other.getClass().getName());
7433
      }
7434
 
7435
      int lastComparison = 0;
695 rajveer 7436
      getPayment_args typedOther = (getPayment_args)other;
420 ashish 7437
 
3430 rajveer 7438
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
420 ashish 7439
      if (lastComparison != 0) {
7440
        return lastComparison;
7441
      }
3430 rajveer 7442
      if (isSetId()) {
7443
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
7444
        if (lastComparison != 0) {
7445
          return lastComparison;
7446
        }
420 ashish 7447
      }
7448
      return 0;
7449
    }
7450
 
3430 rajveer 7451
    public _Fields fieldForId(int fieldId) {
7452
      return _Fields.findByThriftId(fieldId);
7453
    }
7454
 
7455
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7456
      org.apache.thrift.protocol.TField field;
420 ashish 7457
      iprot.readStructBegin();
7458
      while (true)
7459
      {
7460
        field = iprot.readFieldBegin();
3430 rajveer 7461
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 7462
          break;
7463
        }
3430 rajveer 7464
        switch (field.id) {
7465
          case 1: // ID
7466
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7467
              this.id = iprot.readI64();
7468
              setIdIsSet(true);
7469
            } else { 
7470
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7471
            }
7472
            break;
7473
          default:
7474
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 7475
        }
3430 rajveer 7476
        iprot.readFieldEnd();
420 ashish 7477
      }
7478
      iprot.readStructEnd();
7479
      validate();
7480
    }
7481
 
3430 rajveer 7482
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 7483
      validate();
7484
 
7485
      oprot.writeStructBegin(STRUCT_DESC);
7486
      oprot.writeFieldBegin(ID_FIELD_DESC);
7487
      oprot.writeI64(this.id);
7488
      oprot.writeFieldEnd();
7489
      oprot.writeFieldStop();
7490
      oprot.writeStructEnd();
7491
    }
7492
 
7493
    @Override
7494
    public String toString() {
695 rajveer 7495
      StringBuilder sb = new StringBuilder("getPayment_args(");
420 ashish 7496
      boolean first = true;
7497
 
7498
      sb.append("id:");
7499
      sb.append(this.id);
7500
      first = false;
7501
      sb.append(")");
7502
      return sb.toString();
7503
    }
7504
 
3430 rajveer 7505
    public void validate() throws org.apache.thrift.TException {
420 ashish 7506
      // check for required fields
7507
    }
7508
 
3430 rajveer 7509
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7510
      try {
7511
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7512
      } catch (org.apache.thrift.TException te) {
7513
        throw new java.io.IOException(te);
7514
      }
7515
    }
7516
 
7517
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7518
      try {
7519
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7520
        __isset_bit_vector = new BitSet(1);
7521
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7522
      } catch (org.apache.thrift.TException te) {
7523
        throw new java.io.IOException(te);
7524
      }
7525
    }
7526
 
420 ashish 7527
  }
7528
 
3430 rajveer 7529
  public static class getPayment_result implements org.apache.thrift.TBase<getPayment_result, getPayment_result._Fields>, java.io.Serializable, Cloneable   {
7530
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayment_result");
420 ashish 7531
 
3430 rajveer 7532
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
7533
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
420 ashish 7534
 
3430 rajveer 7535
    private Payment success; // required
7536
    private PaymentException pe; // required
420 ashish 7537
 
7538
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7539
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 7540
      SUCCESS((short)0, "success"),
7541
      PE((short)1, "pe");
7542
 
7543
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7544
 
7545
      static {
7546
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7547
          byName.put(field.getFieldName(), field);
7548
        }
7549
      }
7550
 
7551
      /**
7552
       * Find the _Fields constant that matches fieldId, or null if its not found.
7553
       */
7554
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7555
        switch(fieldId) {
7556
          case 0: // SUCCESS
7557
            return SUCCESS;
7558
          case 1: // PE
7559
            return PE;
7560
          default:
7561
            return null;
7562
        }
420 ashish 7563
      }
7564
 
7565
      /**
7566
       * Find the _Fields constant that matches fieldId, throwing an exception
7567
       * if it is not found.
7568
       */
7569
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7570
        _Fields fields = findByThriftId(fieldId);
7571
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7572
        return fields;
7573
      }
7574
 
7575
      /**
7576
       * Find the _Fields constant that matches name, or null if its not found.
7577
       */
7578
      public static _Fields findByName(String name) {
7579
        return byName.get(name);
7580
      }
7581
 
7582
      private final short _thriftId;
7583
      private final String _fieldName;
7584
 
7585
      _Fields(short thriftId, String fieldName) {
7586
        _thriftId = thriftId;
7587
        _fieldName = fieldName;
7588
      }
7589
 
7590
      public short getThriftFieldId() {
7591
        return _thriftId;
7592
      }
7593
 
7594
      public String getFieldName() {
7595
        return _fieldName;
7596
      }
7597
    }
7598
 
7599
    // isset id assignments
7600
 
3430 rajveer 7601
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 7602
    static {
3430 rajveer 7603
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7604
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7605
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class)));
7606
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7607
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7608
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7609
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayment_result.class, metaDataMap);
420 ashish 7610
    }
7611
 
695 rajveer 7612
    public getPayment_result() {
420 ashish 7613
    }
7614
 
695 rajveer 7615
    public getPayment_result(
7616
      Payment success,
420 ashish 7617
      PaymentException pe)
7618
    {
7619
      this();
7620
      this.success = success;
7621
      this.pe = pe;
7622
    }
7623
 
7624
    /**
7625
     * Performs a deep copy on <i>other</i>.
7626
     */
695 rajveer 7627
    public getPayment_result(getPayment_result other) {
420 ashish 7628
      if (other.isSetSuccess()) {
695 rajveer 7629
        this.success = new Payment(other.success);
420 ashish 7630
      }
7631
      if (other.isSetPe()) {
7632
        this.pe = new PaymentException(other.pe);
7633
      }
7634
    }
7635
 
695 rajveer 7636
    public getPayment_result deepCopy() {
7637
      return new getPayment_result(this);
420 ashish 7638
    }
7639
 
3430 rajveer 7640
    @Override
7641
    public void clear() {
7642
      this.success = null;
7643
      this.pe = null;
420 ashish 7644
    }
7645
 
695 rajveer 7646
    public Payment getSuccess() {
420 ashish 7647
      return this.success;
7648
    }
7649
 
3430 rajveer 7650
    public void setSuccess(Payment success) {
420 ashish 7651
      this.success = success;
7652
    }
7653
 
7654
    public void unsetSuccess() {
7655
      this.success = null;
7656
    }
7657
 
3430 rajveer 7658
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 7659
    public boolean isSetSuccess() {
7660
      return this.success != null;
7661
    }
7662
 
7663
    public void setSuccessIsSet(boolean value) {
7664
      if (!value) {
7665
        this.success = null;
7666
      }
7667
    }
7668
 
7669
    public PaymentException getPe() {
7670
      return this.pe;
7671
    }
7672
 
3430 rajveer 7673
    public void setPe(PaymentException pe) {
420 ashish 7674
      this.pe = pe;
7675
    }
7676
 
7677
    public void unsetPe() {
7678
      this.pe = null;
7679
    }
7680
 
3430 rajveer 7681
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 7682
    public boolean isSetPe() {
7683
      return this.pe != null;
7684
    }
7685
 
7686
    public void setPeIsSet(boolean value) {
7687
      if (!value) {
7688
        this.pe = null;
7689
      }
7690
    }
7691
 
7692
    public void setFieldValue(_Fields field, Object value) {
7693
      switch (field) {
7694
      case SUCCESS:
7695
        if (value == null) {
7696
          unsetSuccess();
7697
        } else {
695 rajveer 7698
          setSuccess((Payment)value);
420 ashish 7699
        }
7700
        break;
7701
 
7702
      case PE:
7703
        if (value == null) {
7704
          unsetPe();
7705
        } else {
7706
          setPe((PaymentException)value);
7707
        }
7708
        break;
7709
 
7710
      }
7711
    }
7712
 
7713
    public Object getFieldValue(_Fields field) {
7714
      switch (field) {
7715
      case SUCCESS:
7716
        return getSuccess();
7717
 
7718
      case PE:
7719
        return getPe();
7720
 
7721
      }
7722
      throw new IllegalStateException();
7723
    }
7724
 
3430 rajveer 7725
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7726
    public boolean isSet(_Fields field) {
7727
      if (field == null) {
7728
        throw new IllegalArgumentException();
7729
      }
420 ashish 7730
 
7731
      switch (field) {
7732
      case SUCCESS:
7733
        return isSetSuccess();
7734
      case PE:
7735
        return isSetPe();
7736
      }
7737
      throw new IllegalStateException();
7738
    }
7739
 
7740
    @Override
7741
    public boolean equals(Object that) {
7742
      if (that == null)
7743
        return false;
695 rajveer 7744
      if (that instanceof getPayment_result)
7745
        return this.equals((getPayment_result)that);
420 ashish 7746
      return false;
7747
    }
7748
 
695 rajveer 7749
    public boolean equals(getPayment_result that) {
420 ashish 7750
      if (that == null)
7751
        return false;
7752
 
7753
      boolean this_present_success = true && this.isSetSuccess();
7754
      boolean that_present_success = true && that.isSetSuccess();
7755
      if (this_present_success || that_present_success) {
7756
        if (!(this_present_success && that_present_success))
7757
          return false;
7758
        if (!this.success.equals(that.success))
7759
          return false;
7760
      }
7761
 
7762
      boolean this_present_pe = true && this.isSetPe();
7763
      boolean that_present_pe = true && that.isSetPe();
7764
      if (this_present_pe || that_present_pe) {
7765
        if (!(this_present_pe && that_present_pe))
7766
          return false;
7767
        if (!this.pe.equals(that.pe))
7768
          return false;
7769
      }
7770
 
7771
      return true;
7772
    }
7773
 
7774
    @Override
7775
    public int hashCode() {
7776
      return 0;
7777
    }
7778
 
695 rajveer 7779
    public int compareTo(getPayment_result other) {
420 ashish 7780
      if (!getClass().equals(other.getClass())) {
7781
        return getClass().getName().compareTo(other.getClass().getName());
7782
      }
7783
 
7784
      int lastComparison = 0;
695 rajveer 7785
      getPayment_result typedOther = (getPayment_result)other;
420 ashish 7786
 
3430 rajveer 7787
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
420 ashish 7788
      if (lastComparison != 0) {
7789
        return lastComparison;
7790
      }
3430 rajveer 7791
      if (isSetSuccess()) {
7792
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7793
        if (lastComparison != 0) {
7794
          return lastComparison;
7795
        }
420 ashish 7796
      }
3430 rajveer 7797
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 7798
      if (lastComparison != 0) {
7799
        return lastComparison;
7800
      }
3430 rajveer 7801
      if (isSetPe()) {
7802
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
7803
        if (lastComparison != 0) {
7804
          return lastComparison;
7805
        }
420 ashish 7806
      }
7807
      return 0;
7808
    }
7809
 
3430 rajveer 7810
    public _Fields fieldForId(int fieldId) {
7811
      return _Fields.findByThriftId(fieldId);
7812
    }
7813
 
7814
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7815
      org.apache.thrift.protocol.TField field;
420 ashish 7816
      iprot.readStructBegin();
7817
      while (true)
7818
      {
7819
        field = iprot.readFieldBegin();
3430 rajveer 7820
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 7821
          break;
7822
        }
3430 rajveer 7823
        switch (field.id) {
7824
          case 0: // SUCCESS
7825
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7826
              this.success = new Payment();
7827
              this.success.read(iprot);
7828
            } else { 
7829
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7830
            }
7831
            break;
7832
          case 1: // PE
7833
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7834
              this.pe = new PaymentException();
7835
              this.pe.read(iprot);
7836
            } else { 
7837
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7838
            }
7839
            break;
7840
          default:
7841
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 7842
        }
3430 rajveer 7843
        iprot.readFieldEnd();
420 ashish 7844
      }
7845
      iprot.readStructEnd();
7846
      validate();
7847
    }
7848
 
3430 rajveer 7849
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 7850
      oprot.writeStructBegin(STRUCT_DESC);
7851
 
695 rajveer 7852
      if (this.isSetSuccess()) {
7853
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7854
        this.success.write(oprot);
7855
        oprot.writeFieldEnd();
7856
      } else if (this.isSetPe()) {
420 ashish 7857
        oprot.writeFieldBegin(PE_FIELD_DESC);
7858
        this.pe.write(oprot);
7859
        oprot.writeFieldEnd();
7860
      }
7861
      oprot.writeFieldStop();
7862
      oprot.writeStructEnd();
7863
    }
7864
 
7865
    @Override
7866
    public String toString() {
695 rajveer 7867
      StringBuilder sb = new StringBuilder("getPayment_result(");
420 ashish 7868
      boolean first = true;
7869
 
695 rajveer 7870
      sb.append("success:");
7871
      if (this.success == null) {
7872
        sb.append("null");
7873
      } else {
7874
        sb.append(this.success);
7875
      }
7876
      first = false;
7877
      if (!first) sb.append(", ");
420 ashish 7878
      sb.append("pe:");
7879
      if (this.pe == null) {
7880
        sb.append("null");
7881
      } else {
7882
        sb.append(this.pe);
7883
      }
7884
      first = false;
7885
      sb.append(")");
7886
      return sb.toString();
7887
    }
7888
 
3430 rajveer 7889
    public void validate() throws org.apache.thrift.TException {
420 ashish 7890
      // check for required fields
7891
    }
7892
 
3430 rajveer 7893
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7894
      try {
7895
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7896
      } catch (org.apache.thrift.TException te) {
7897
        throw new java.io.IOException(te);
7898
      }
7899
    }
7900
 
7901
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7902
      try {
7903
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7904
      } catch (org.apache.thrift.TException te) {
7905
        throw new java.io.IOException(te);
7906
      }
7907
    }
7908
 
420 ashish 7909
  }
7910
 
3430 rajveer 7911
  public static class getPaymentForTxnId_args implements org.apache.thrift.TBase<getPaymentForTxnId_args, getPaymentForTxnId_args._Fields>, java.io.Serializable, Cloneable   {
7912
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForTxnId_args");
420 ashish 7913
 
3430 rajveer 7914
    private static final org.apache.thrift.protocol.TField TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("txnId", org.apache.thrift.protocol.TType.I64, (short)1);
420 ashish 7915
 
3430 rajveer 7916
    private long txnId; // required
420 ashish 7917
 
7918
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7919
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 7920
      TXN_ID((short)1, "txnId");
420 ashish 7921
 
7922
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7923
 
7924
      static {
7925
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7926
          byName.put(field.getFieldName(), field);
7927
        }
7928
      }
7929
 
7930
      /**
7931
       * Find the _Fields constant that matches fieldId, or null if its not found.
7932
       */
7933
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7934
        switch(fieldId) {
7935
          case 1: // TXN_ID
7936
            return TXN_ID;
7937
          default:
7938
            return null;
7939
        }
420 ashish 7940
      }
7941
 
7942
      /**
7943
       * Find the _Fields constant that matches fieldId, throwing an exception
7944
       * if it is not found.
7945
       */
7946
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7947
        _Fields fields = findByThriftId(fieldId);
7948
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7949
        return fields;
7950
      }
7951
 
7952
      /**
7953
       * Find the _Fields constant that matches name, or null if its not found.
7954
       */
7955
      public static _Fields findByName(String name) {
7956
        return byName.get(name);
7957
      }
7958
 
7959
      private final short _thriftId;
7960
      private final String _fieldName;
7961
 
7962
      _Fields(short thriftId, String fieldName) {
7963
        _thriftId = thriftId;
7964
        _fieldName = fieldName;
7965
      }
7966
 
7967
      public short getThriftFieldId() {
7968
        return _thriftId;
7969
      }
7970
 
7971
      public String getFieldName() {
7972
        return _fieldName;
7973
      }
7974
    }
7975
 
7976
    // isset id assignments
695 rajveer 7977
    private static final int __TXNID_ISSET_ID = 0;
420 ashish 7978
    private BitSet __isset_bit_vector = new BitSet(1);
7979
 
3430 rajveer 7980
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 7981
    static {
3430 rajveer 7982
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7983
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7984
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7985
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7986
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForTxnId_args.class, metaDataMap);
420 ashish 7987
    }
7988
 
695 rajveer 7989
    public getPaymentForTxnId_args() {
420 ashish 7990
    }
7991
 
695 rajveer 7992
    public getPaymentForTxnId_args(
7993
      long txnId)
420 ashish 7994
    {
7995
      this();
695 rajveer 7996
      this.txnId = txnId;
7997
      setTxnIdIsSet(true);
420 ashish 7998
    }
7999
 
8000
    /**
8001
     * Performs a deep copy on <i>other</i>.
8002
     */
695 rajveer 8003
    public getPaymentForTxnId_args(getPaymentForTxnId_args other) {
420 ashish 8004
      __isset_bit_vector.clear();
8005
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 8006
      this.txnId = other.txnId;
420 ashish 8007
    }
8008
 
695 rajveer 8009
    public getPaymentForTxnId_args deepCopy() {
8010
      return new getPaymentForTxnId_args(this);
420 ashish 8011
    }
8012
 
3430 rajveer 8013
    @Override
8014
    public void clear() {
8015
      setTxnIdIsSet(false);
8016
      this.txnId = 0;
420 ashish 8017
    }
8018
 
695 rajveer 8019
    public long getTxnId() {
8020
      return this.txnId;
420 ashish 8021
    }
8022
 
3430 rajveer 8023
    public void setTxnId(long txnId) {
695 rajveer 8024
      this.txnId = txnId;
8025
      setTxnIdIsSet(true);
420 ashish 8026
    }
8027
 
695 rajveer 8028
    public void unsetTxnId() {
8029
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
420 ashish 8030
    }
8031
 
3430 rajveer 8032
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
695 rajveer 8033
    public boolean isSetTxnId() {
8034
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
420 ashish 8035
    }
8036
 
695 rajveer 8037
    public void setTxnIdIsSet(boolean value) {
8038
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
420 ashish 8039
    }
8040
 
8041
    public void setFieldValue(_Fields field, Object value) {
8042
      switch (field) {
695 rajveer 8043
      case TXN_ID:
420 ashish 8044
        if (value == null) {
695 rajveer 8045
          unsetTxnId();
420 ashish 8046
        } else {
695 rajveer 8047
          setTxnId((Long)value);
420 ashish 8048
        }
8049
        break;
8050
 
8051
      }
8052
    }
8053
 
8054
    public Object getFieldValue(_Fields field) {
8055
      switch (field) {
695 rajveer 8056
      case TXN_ID:
3430 rajveer 8057
        return Long.valueOf(getTxnId());
420 ashish 8058
 
8059
      }
8060
      throw new IllegalStateException();
8061
    }
8062
 
3430 rajveer 8063
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8064
    public boolean isSet(_Fields field) {
8065
      if (field == null) {
8066
        throw new IllegalArgumentException();
8067
      }
420 ashish 8068
 
8069
      switch (field) {
695 rajveer 8070
      case TXN_ID:
8071
        return isSetTxnId();
420 ashish 8072
      }
8073
      throw new IllegalStateException();
8074
    }
8075
 
8076
    @Override
8077
    public boolean equals(Object that) {
8078
      if (that == null)
8079
        return false;
695 rajveer 8080
      if (that instanceof getPaymentForTxnId_args)
8081
        return this.equals((getPaymentForTxnId_args)that);
420 ashish 8082
      return false;
8083
    }
8084
 
695 rajveer 8085
    public boolean equals(getPaymentForTxnId_args that) {
420 ashish 8086
      if (that == null)
8087
        return false;
8088
 
695 rajveer 8089
      boolean this_present_txnId = true;
8090
      boolean that_present_txnId = true;
8091
      if (this_present_txnId || that_present_txnId) {
8092
        if (!(this_present_txnId && that_present_txnId))
420 ashish 8093
          return false;
695 rajveer 8094
        if (this.txnId != that.txnId)
420 ashish 8095
          return false;
8096
      }
8097
 
8098
      return true;
8099
    }
8100
 
8101
    @Override
8102
    public int hashCode() {
8103
      return 0;
8104
    }
8105
 
695 rajveer 8106
    public int compareTo(getPaymentForTxnId_args other) {
420 ashish 8107
      if (!getClass().equals(other.getClass())) {
8108
        return getClass().getName().compareTo(other.getClass().getName());
8109
      }
8110
 
8111
      int lastComparison = 0;
695 rajveer 8112
      getPaymentForTxnId_args typedOther = (getPaymentForTxnId_args)other;
420 ashish 8113
 
3430 rajveer 8114
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
420 ashish 8115
      if (lastComparison != 0) {
8116
        return lastComparison;
8117
      }
3430 rajveer 8118
      if (isSetTxnId()) {
8119
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
8120
        if (lastComparison != 0) {
8121
          return lastComparison;
8122
        }
420 ashish 8123
      }
8124
      return 0;
8125
    }
8126
 
3430 rajveer 8127
    public _Fields fieldForId(int fieldId) {
8128
      return _Fields.findByThriftId(fieldId);
8129
    }
8130
 
8131
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8132
      org.apache.thrift.protocol.TField field;
420 ashish 8133
      iprot.readStructBegin();
8134
      while (true)
8135
      {
8136
        field = iprot.readFieldBegin();
3430 rajveer 8137
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 8138
          break;
8139
        }
3430 rajveer 8140
        switch (field.id) {
8141
          case 1: // TXN_ID
8142
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8143
              this.txnId = iprot.readI64();
8144
              setTxnIdIsSet(true);
8145
            } else { 
8146
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8147
            }
8148
            break;
8149
          default:
8150
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 8151
        }
3430 rajveer 8152
        iprot.readFieldEnd();
420 ashish 8153
      }
8154
      iprot.readStructEnd();
8155
      validate();
8156
    }
8157
 
3430 rajveer 8158
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 8159
      validate();
8160
 
8161
      oprot.writeStructBegin(STRUCT_DESC);
695 rajveer 8162
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
8163
      oprot.writeI64(this.txnId);
420 ashish 8164
      oprot.writeFieldEnd();
8165
      oprot.writeFieldStop();
8166
      oprot.writeStructEnd();
8167
    }
8168
 
8169
    @Override
8170
    public String toString() {
695 rajveer 8171
      StringBuilder sb = new StringBuilder("getPaymentForTxnId_args(");
420 ashish 8172
      boolean first = true;
8173
 
695 rajveer 8174
      sb.append("txnId:");
8175
      sb.append(this.txnId);
420 ashish 8176
      first = false;
8177
      sb.append(")");
8178
      return sb.toString();
8179
    }
8180
 
3430 rajveer 8181
    public void validate() throws org.apache.thrift.TException {
420 ashish 8182
      // check for required fields
8183
    }
8184
 
3430 rajveer 8185
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8186
      try {
8187
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8188
      } catch (org.apache.thrift.TException te) {
8189
        throw new java.io.IOException(te);
8190
      }
8191
    }
8192
 
8193
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8194
      try {
8195
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8196
        __isset_bit_vector = new BitSet(1);
8197
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8198
      } catch (org.apache.thrift.TException te) {
8199
        throw new java.io.IOException(te);
8200
      }
8201
    }
8202
 
420 ashish 8203
  }
8204
 
3430 rajveer 8205
  public static class getPaymentForTxnId_result implements org.apache.thrift.TBase<getPaymentForTxnId_result, getPaymentForTxnId_result._Fields>, java.io.Serializable, Cloneable   {
8206
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForTxnId_result");
420 ashish 8207
 
3430 rajveer 8208
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
8209
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
420 ashish 8210
 
3430 rajveer 8211
    private List<Payment> success; // required
8212
    private PaymentException pe; // required
420 ashish 8213
 
8214
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 8215
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 8216
      SUCCESS((short)0, "success"),
8217
      PE((short)1, "pe");
8218
 
8219
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8220
 
8221
      static {
8222
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8223
          byName.put(field.getFieldName(), field);
8224
        }
8225
      }
8226
 
8227
      /**
8228
       * Find the _Fields constant that matches fieldId, or null if its not found.
8229
       */
8230
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 8231
        switch(fieldId) {
8232
          case 0: // SUCCESS
8233
            return SUCCESS;
8234
          case 1: // PE
8235
            return PE;
8236
          default:
8237
            return null;
8238
        }
420 ashish 8239
      }
8240
 
8241
      /**
8242
       * Find the _Fields constant that matches fieldId, throwing an exception
8243
       * if it is not found.
8244
       */
8245
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8246
        _Fields fields = findByThriftId(fieldId);
8247
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8248
        return fields;
8249
      }
8250
 
8251
      /**
8252
       * Find the _Fields constant that matches name, or null if its not found.
8253
       */
8254
      public static _Fields findByName(String name) {
8255
        return byName.get(name);
8256
      }
8257
 
8258
      private final short _thriftId;
8259
      private final String _fieldName;
8260
 
8261
      _Fields(short thriftId, String fieldName) {
8262
        _thriftId = thriftId;
8263
        _fieldName = fieldName;
8264
      }
8265
 
8266
      public short getThriftFieldId() {
8267
        return _thriftId;
8268
      }
8269
 
8270
      public String getFieldName() {
8271
        return _fieldName;
8272
      }
8273
    }
8274
 
8275
    // isset id assignments
8276
 
3430 rajveer 8277
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 8278
    static {
3430 rajveer 8279
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8280
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8281
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
8282
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
8283
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8284
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8285
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8286
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForTxnId_result.class, metaDataMap);
420 ashish 8287
    }
8288
 
695 rajveer 8289
    public getPaymentForTxnId_result() {
420 ashish 8290
    }
8291
 
695 rajveer 8292
    public getPaymentForTxnId_result(
8293
      List<Payment> success,
420 ashish 8294
      PaymentException pe)
8295
    {
8296
      this();
8297
      this.success = success;
8298
      this.pe = pe;
8299
    }
8300
 
8301
    /**
8302
     * Performs a deep copy on <i>other</i>.
8303
     */
695 rajveer 8304
    public getPaymentForTxnId_result(getPaymentForTxnId_result other) {
420 ashish 8305
      if (other.isSetSuccess()) {
695 rajveer 8306
        List<Payment> __this__success = new ArrayList<Payment>();
8307
        for (Payment other_element : other.success) {
8308
          __this__success.add(new Payment(other_element));
8309
        }
8310
        this.success = __this__success;
420 ashish 8311
      }
8312
      if (other.isSetPe()) {
8313
        this.pe = new PaymentException(other.pe);
8314
      }
8315
    }
8316
 
695 rajveer 8317
    public getPaymentForTxnId_result deepCopy() {
8318
      return new getPaymentForTxnId_result(this);
420 ashish 8319
    }
8320
 
3430 rajveer 8321
    @Override
8322
    public void clear() {
8323
      this.success = null;
8324
      this.pe = null;
420 ashish 8325
    }
8326
 
695 rajveer 8327
    public int getSuccessSize() {
8328
      return (this.success == null) ? 0 : this.success.size();
8329
    }
8330
 
8331
    public java.util.Iterator<Payment> getSuccessIterator() {
8332
      return (this.success == null) ? null : this.success.iterator();
8333
    }
8334
 
8335
    public void addToSuccess(Payment elem) {
8336
      if (this.success == null) {
8337
        this.success = new ArrayList<Payment>();
8338
      }
8339
      this.success.add(elem);
8340
    }
8341
 
8342
    public List<Payment> getSuccess() {
420 ashish 8343
      return this.success;
8344
    }
8345
 
3430 rajveer 8346
    public void setSuccess(List<Payment> success) {
420 ashish 8347
      this.success = success;
8348
    }
8349
 
8350
    public void unsetSuccess() {
8351
      this.success = null;
8352
    }
8353
 
3430 rajveer 8354
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 8355
    public boolean isSetSuccess() {
8356
      return this.success != null;
8357
    }
8358
 
8359
    public void setSuccessIsSet(boolean value) {
8360
      if (!value) {
8361
        this.success = null;
8362
      }
8363
    }
8364
 
8365
    public PaymentException getPe() {
8366
      return this.pe;
8367
    }
8368
 
3430 rajveer 8369
    public void setPe(PaymentException pe) {
420 ashish 8370
      this.pe = pe;
8371
    }
8372
 
8373
    public void unsetPe() {
8374
      this.pe = null;
8375
    }
8376
 
3430 rajveer 8377
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 8378
    public boolean isSetPe() {
8379
      return this.pe != null;
8380
    }
8381
 
8382
    public void setPeIsSet(boolean value) {
8383
      if (!value) {
8384
        this.pe = null;
8385
      }
8386
    }
8387
 
8388
    public void setFieldValue(_Fields field, Object value) {
8389
      switch (field) {
8390
      case SUCCESS:
8391
        if (value == null) {
8392
          unsetSuccess();
8393
        } else {
695 rajveer 8394
          setSuccess((List<Payment>)value);
420 ashish 8395
        }
8396
        break;
8397
 
8398
      case PE:
8399
        if (value == null) {
8400
          unsetPe();
8401
        } else {
8402
          setPe((PaymentException)value);
8403
        }
8404
        break;
8405
 
8406
      }
8407
    }
8408
 
8409
    public Object getFieldValue(_Fields field) {
8410
      switch (field) {
8411
      case SUCCESS:
8412
        return getSuccess();
8413
 
8414
      case PE:
8415
        return getPe();
8416
 
8417
      }
8418
      throw new IllegalStateException();
8419
    }
8420
 
3430 rajveer 8421
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8422
    public boolean isSet(_Fields field) {
8423
      if (field == null) {
8424
        throw new IllegalArgumentException();
8425
      }
420 ashish 8426
 
8427
      switch (field) {
8428
      case SUCCESS:
8429
        return isSetSuccess();
8430
      case PE:
8431
        return isSetPe();
8432
      }
8433
      throw new IllegalStateException();
8434
    }
8435
 
8436
    @Override
8437
    public boolean equals(Object that) {
8438
      if (that == null)
8439
        return false;
695 rajveer 8440
      if (that instanceof getPaymentForTxnId_result)
8441
        return this.equals((getPaymentForTxnId_result)that);
420 ashish 8442
      return false;
8443
    }
8444
 
695 rajveer 8445
    public boolean equals(getPaymentForTxnId_result that) {
420 ashish 8446
      if (that == null)
8447
        return false;
8448
 
8449
      boolean this_present_success = true && this.isSetSuccess();
8450
      boolean that_present_success = true && that.isSetSuccess();
8451
      if (this_present_success || that_present_success) {
8452
        if (!(this_present_success && that_present_success))
8453
          return false;
8454
        if (!this.success.equals(that.success))
8455
          return false;
8456
      }
8457
 
8458
      boolean this_present_pe = true && this.isSetPe();
8459
      boolean that_present_pe = true && that.isSetPe();
8460
      if (this_present_pe || that_present_pe) {
8461
        if (!(this_present_pe && that_present_pe))
8462
          return false;
8463
        if (!this.pe.equals(that.pe))
8464
          return false;
8465
      }
8466
 
8467
      return true;
8468
    }
8469
 
8470
    @Override
8471
    public int hashCode() {
8472
      return 0;
8473
    }
8474
 
695 rajveer 8475
    public int compareTo(getPaymentForTxnId_result other) {
8476
      if (!getClass().equals(other.getClass())) {
8477
        return getClass().getName().compareTo(other.getClass().getName());
8478
      }
8479
 
8480
      int lastComparison = 0;
8481
      getPaymentForTxnId_result typedOther = (getPaymentForTxnId_result)other;
8482
 
3430 rajveer 8483
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 8484
      if (lastComparison != 0) {
8485
        return lastComparison;
8486
      }
3430 rajveer 8487
      if (isSetSuccess()) {
8488
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8489
        if (lastComparison != 0) {
8490
          return lastComparison;
8491
        }
695 rajveer 8492
      }
3430 rajveer 8493
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 8494
      if (lastComparison != 0) {
8495
        return lastComparison;
8496
      }
3430 rajveer 8497
      if (isSetPe()) {
8498
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
8499
        if (lastComparison != 0) {
8500
          return lastComparison;
8501
        }
695 rajveer 8502
      }
8503
      return 0;
8504
    }
8505
 
3430 rajveer 8506
    public _Fields fieldForId(int fieldId) {
8507
      return _Fields.findByThriftId(fieldId);
8508
    }
8509
 
8510
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8511
      org.apache.thrift.protocol.TField field;
420 ashish 8512
      iprot.readStructBegin();
8513
      while (true)
8514
      {
8515
        field = iprot.readFieldBegin();
3430 rajveer 8516
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 8517
          break;
8518
        }
3430 rajveer 8519
        switch (field.id) {
8520
          case 0: // SUCCESS
8521
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
8522
              {
4600 varun.gupt 8523
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
8524
                this.success = new ArrayList<Payment>(_list28.size);
8525
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
695 rajveer 8526
                {
4600 varun.gupt 8527
                  Payment _elem30; // required
8528
                  _elem30 = new Payment();
8529
                  _elem30.read(iprot);
8530
                  this.success.add(_elem30);
695 rajveer 8531
                }
3430 rajveer 8532
                iprot.readListEnd();
420 ashish 8533
              }
3430 rajveer 8534
            } else { 
8535
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8536
            }
8537
            break;
8538
          case 1: // PE
8539
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8540
              this.pe = new PaymentException();
8541
              this.pe.read(iprot);
8542
            } else { 
8543
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8544
            }
8545
            break;
8546
          default:
8547
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 8548
        }
3430 rajveer 8549
        iprot.readFieldEnd();
420 ashish 8550
      }
8551
      iprot.readStructEnd();
8552
      validate();
8553
    }
8554
 
3430 rajveer 8555
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 8556
      oprot.writeStructBegin(STRUCT_DESC);
8557
 
8558
      if (this.isSetSuccess()) {
8559
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
695 rajveer 8560
        {
3430 rajveer 8561
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
4600 varun.gupt 8562
          for (Payment _iter31 : this.success)
695 rajveer 8563
          {
4600 varun.gupt 8564
            _iter31.write(oprot);
695 rajveer 8565
          }
8566
          oprot.writeListEnd();
8567
        }
420 ashish 8568
        oprot.writeFieldEnd();
8569
      } else if (this.isSetPe()) {
8570
        oprot.writeFieldBegin(PE_FIELD_DESC);
8571
        this.pe.write(oprot);
8572
        oprot.writeFieldEnd();
8573
      }
8574
      oprot.writeFieldStop();
8575
      oprot.writeStructEnd();
8576
    }
8577
 
8578
    @Override
8579
    public String toString() {
695 rajveer 8580
      StringBuilder sb = new StringBuilder("getPaymentForTxnId_result(");
420 ashish 8581
      boolean first = true;
8582
 
8583
      sb.append("success:");
8584
      if (this.success == null) {
8585
        sb.append("null");
8586
      } else {
8587
        sb.append(this.success);
8588
      }
8589
      first = false;
8590
      if (!first) sb.append(", ");
8591
      sb.append("pe:");
8592
      if (this.pe == null) {
8593
        sb.append("null");
8594
      } else {
8595
        sb.append(this.pe);
8596
      }
8597
      first = false;
8598
      sb.append(")");
8599
      return sb.toString();
8600
    }
8601
 
3430 rajveer 8602
    public void validate() throws org.apache.thrift.TException {
420 ashish 8603
      // check for required fields
8604
    }
8605
 
3430 rajveer 8606
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8607
      try {
8608
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8609
      } catch (org.apache.thrift.TException te) {
8610
        throw new java.io.IOException(te);
8611
      }
8612
    }
8613
 
8614
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8615
      try {
8616
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8617
      } catch (org.apache.thrift.TException te) {
8618
        throw new java.io.IOException(te);
8619
      }
8620
    }
8621
 
420 ashish 8622
  }
8623
 
4600 varun.gupt 8624
  public static class getSuccessfulPaymentForTxnId_args implements org.apache.thrift.TBase<getSuccessfulPaymentForTxnId_args, getSuccessfulPaymentForTxnId_args._Fields>, java.io.Serializable, Cloneable   {
8625
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentForTxnId_args");
8626
 
8627
    private static final org.apache.thrift.protocol.TField TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("txnId", org.apache.thrift.protocol.TType.I64, (short)1);
8628
 
8629
    private long txnId; // required
8630
 
8631
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8632
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8633
      TXN_ID((short)1, "txnId");
8634
 
8635
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8636
 
8637
      static {
8638
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8639
          byName.put(field.getFieldName(), field);
8640
        }
8641
      }
8642
 
8643
      /**
8644
       * Find the _Fields constant that matches fieldId, or null if its not found.
8645
       */
8646
      public static _Fields findByThriftId(int fieldId) {
8647
        switch(fieldId) {
8648
          case 1: // TXN_ID
8649
            return TXN_ID;
8650
          default:
8651
            return null;
8652
        }
8653
      }
8654
 
8655
      /**
8656
       * Find the _Fields constant that matches fieldId, throwing an exception
8657
       * if it is not found.
8658
       */
8659
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8660
        _Fields fields = findByThriftId(fieldId);
8661
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8662
        return fields;
8663
      }
8664
 
8665
      /**
8666
       * Find the _Fields constant that matches name, or null if its not found.
8667
       */
8668
      public static _Fields findByName(String name) {
8669
        return byName.get(name);
8670
      }
8671
 
8672
      private final short _thriftId;
8673
      private final String _fieldName;
8674
 
8675
      _Fields(short thriftId, String fieldName) {
8676
        _thriftId = thriftId;
8677
        _fieldName = fieldName;
8678
      }
8679
 
8680
      public short getThriftFieldId() {
8681
        return _thriftId;
8682
      }
8683
 
8684
      public String getFieldName() {
8685
        return _fieldName;
8686
      }
8687
    }
8688
 
8689
    // isset id assignments
8690
    private static final int __TXNID_ISSET_ID = 0;
8691
    private BitSet __isset_bit_vector = new BitSet(1);
8692
 
8693
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8694
    static {
8695
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8696
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8697
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8698
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8699
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentForTxnId_args.class, metaDataMap);
8700
    }
8701
 
8702
    public getSuccessfulPaymentForTxnId_args() {
8703
    }
8704
 
8705
    public getSuccessfulPaymentForTxnId_args(
8706
      long txnId)
8707
    {
8708
      this();
8709
      this.txnId = txnId;
8710
      setTxnIdIsSet(true);
8711
    }
8712
 
8713
    /**
8714
     * Performs a deep copy on <i>other</i>.
8715
     */
8716
    public getSuccessfulPaymentForTxnId_args(getSuccessfulPaymentForTxnId_args other) {
8717
      __isset_bit_vector.clear();
8718
      __isset_bit_vector.or(other.__isset_bit_vector);
8719
      this.txnId = other.txnId;
8720
    }
8721
 
8722
    public getSuccessfulPaymentForTxnId_args deepCopy() {
8723
      return new getSuccessfulPaymentForTxnId_args(this);
8724
    }
8725
 
8726
    @Override
8727
    public void clear() {
8728
      setTxnIdIsSet(false);
8729
      this.txnId = 0;
8730
    }
8731
 
8732
    public long getTxnId() {
8733
      return this.txnId;
8734
    }
8735
 
8736
    public void setTxnId(long txnId) {
8737
      this.txnId = txnId;
8738
      setTxnIdIsSet(true);
8739
    }
8740
 
8741
    public void unsetTxnId() {
8742
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
8743
    }
8744
 
8745
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
8746
    public boolean isSetTxnId() {
8747
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
8748
    }
8749
 
8750
    public void setTxnIdIsSet(boolean value) {
8751
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
8752
    }
8753
 
8754
    public void setFieldValue(_Fields field, Object value) {
8755
      switch (field) {
8756
      case TXN_ID:
8757
        if (value == null) {
8758
          unsetTxnId();
8759
        } else {
8760
          setTxnId((Long)value);
8761
        }
8762
        break;
8763
 
8764
      }
8765
    }
8766
 
8767
    public Object getFieldValue(_Fields field) {
8768
      switch (field) {
8769
      case TXN_ID:
8770
        return Long.valueOf(getTxnId());
8771
 
8772
      }
8773
      throw new IllegalStateException();
8774
    }
8775
 
8776
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8777
    public boolean isSet(_Fields field) {
8778
      if (field == null) {
8779
        throw new IllegalArgumentException();
8780
      }
8781
 
8782
      switch (field) {
8783
      case TXN_ID:
8784
        return isSetTxnId();
8785
      }
8786
      throw new IllegalStateException();
8787
    }
8788
 
8789
    @Override
8790
    public boolean equals(Object that) {
8791
      if (that == null)
8792
        return false;
8793
      if (that instanceof getSuccessfulPaymentForTxnId_args)
8794
        return this.equals((getSuccessfulPaymentForTxnId_args)that);
8795
      return false;
8796
    }
8797
 
8798
    public boolean equals(getSuccessfulPaymentForTxnId_args that) {
8799
      if (that == null)
8800
        return false;
8801
 
8802
      boolean this_present_txnId = true;
8803
      boolean that_present_txnId = true;
8804
      if (this_present_txnId || that_present_txnId) {
8805
        if (!(this_present_txnId && that_present_txnId))
8806
          return false;
8807
        if (this.txnId != that.txnId)
8808
          return false;
8809
      }
8810
 
8811
      return true;
8812
    }
8813
 
8814
    @Override
8815
    public int hashCode() {
8816
      return 0;
8817
    }
8818
 
8819
    public int compareTo(getSuccessfulPaymentForTxnId_args other) {
8820
      if (!getClass().equals(other.getClass())) {
8821
        return getClass().getName().compareTo(other.getClass().getName());
8822
      }
8823
 
8824
      int lastComparison = 0;
8825
      getSuccessfulPaymentForTxnId_args typedOther = (getSuccessfulPaymentForTxnId_args)other;
8826
 
8827
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
8828
      if (lastComparison != 0) {
8829
        return lastComparison;
8830
      }
8831
      if (isSetTxnId()) {
8832
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
8833
        if (lastComparison != 0) {
8834
          return lastComparison;
8835
        }
8836
      }
8837
      return 0;
8838
    }
8839
 
8840
    public _Fields fieldForId(int fieldId) {
8841
      return _Fields.findByThriftId(fieldId);
8842
    }
8843
 
8844
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8845
      org.apache.thrift.protocol.TField field;
8846
      iprot.readStructBegin();
8847
      while (true)
8848
      {
8849
        field = iprot.readFieldBegin();
8850
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8851
          break;
8852
        }
8853
        switch (field.id) {
8854
          case 1: // TXN_ID
8855
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8856
              this.txnId = iprot.readI64();
8857
              setTxnIdIsSet(true);
8858
            } else { 
8859
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8860
            }
8861
            break;
8862
          default:
8863
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8864
        }
8865
        iprot.readFieldEnd();
8866
      }
8867
      iprot.readStructEnd();
8868
      validate();
8869
    }
8870
 
8871
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8872
      validate();
8873
 
8874
      oprot.writeStructBegin(STRUCT_DESC);
8875
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
8876
      oprot.writeI64(this.txnId);
8877
      oprot.writeFieldEnd();
8878
      oprot.writeFieldStop();
8879
      oprot.writeStructEnd();
8880
    }
8881
 
8882
    @Override
8883
    public String toString() {
8884
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentForTxnId_args(");
8885
      boolean first = true;
8886
 
8887
      sb.append("txnId:");
8888
      sb.append(this.txnId);
8889
      first = false;
8890
      sb.append(")");
8891
      return sb.toString();
8892
    }
8893
 
8894
    public void validate() throws org.apache.thrift.TException {
8895
      // check for required fields
8896
    }
8897
 
8898
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8899
      try {
8900
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8901
      } catch (org.apache.thrift.TException te) {
8902
        throw new java.io.IOException(te);
8903
      }
8904
    }
8905
 
8906
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8907
      try {
8908
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8909
        __isset_bit_vector = new BitSet(1);
8910
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8911
      } catch (org.apache.thrift.TException te) {
8912
        throw new java.io.IOException(te);
8913
      }
8914
    }
8915
 
8916
  }
8917
 
8918
  public static class getSuccessfulPaymentForTxnId_result implements org.apache.thrift.TBase<getSuccessfulPaymentForTxnId_result, getSuccessfulPaymentForTxnId_result._Fields>, java.io.Serializable, Cloneable   {
8919
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentForTxnId_result");
8920
 
8921
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
8922
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
8923
 
8924
    private Payment success; // required
8925
    private PaymentException pe; // required
8926
 
8927
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8928
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8929
      SUCCESS((short)0, "success"),
8930
      PE((short)1, "pe");
8931
 
8932
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8933
 
8934
      static {
8935
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8936
          byName.put(field.getFieldName(), field);
8937
        }
8938
      }
8939
 
8940
      /**
8941
       * Find the _Fields constant that matches fieldId, or null if its not found.
8942
       */
8943
      public static _Fields findByThriftId(int fieldId) {
8944
        switch(fieldId) {
8945
          case 0: // SUCCESS
8946
            return SUCCESS;
8947
          case 1: // PE
8948
            return PE;
8949
          default:
8950
            return null;
8951
        }
8952
      }
8953
 
8954
      /**
8955
       * Find the _Fields constant that matches fieldId, throwing an exception
8956
       * if it is not found.
8957
       */
8958
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8959
        _Fields fields = findByThriftId(fieldId);
8960
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8961
        return fields;
8962
      }
8963
 
8964
      /**
8965
       * Find the _Fields constant that matches name, or null if its not found.
8966
       */
8967
      public static _Fields findByName(String name) {
8968
        return byName.get(name);
8969
      }
8970
 
8971
      private final short _thriftId;
8972
      private final String _fieldName;
8973
 
8974
      _Fields(short thriftId, String fieldName) {
8975
        _thriftId = thriftId;
8976
        _fieldName = fieldName;
8977
      }
8978
 
8979
      public short getThriftFieldId() {
8980
        return _thriftId;
8981
      }
8982
 
8983
      public String getFieldName() {
8984
        return _fieldName;
8985
      }
8986
    }
8987
 
8988
    // isset id assignments
8989
 
8990
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8991
    static {
8992
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8993
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8994
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class)));
8995
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8996
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8997
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8998
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentForTxnId_result.class, metaDataMap);
8999
    }
9000
 
9001
    public getSuccessfulPaymentForTxnId_result() {
9002
    }
9003
 
9004
    public getSuccessfulPaymentForTxnId_result(
9005
      Payment success,
9006
      PaymentException pe)
9007
    {
9008
      this();
9009
      this.success = success;
9010
      this.pe = pe;
9011
    }
9012
 
9013
    /**
9014
     * Performs a deep copy on <i>other</i>.
9015
     */
9016
    public getSuccessfulPaymentForTxnId_result(getSuccessfulPaymentForTxnId_result other) {
9017
      if (other.isSetSuccess()) {
9018
        this.success = new Payment(other.success);
9019
      }
9020
      if (other.isSetPe()) {
9021
        this.pe = new PaymentException(other.pe);
9022
      }
9023
    }
9024
 
9025
    public getSuccessfulPaymentForTxnId_result deepCopy() {
9026
      return new getSuccessfulPaymentForTxnId_result(this);
9027
    }
9028
 
9029
    @Override
9030
    public void clear() {
9031
      this.success = null;
9032
      this.pe = null;
9033
    }
9034
 
9035
    public Payment getSuccess() {
9036
      return this.success;
9037
    }
9038
 
9039
    public void setSuccess(Payment success) {
9040
      this.success = success;
9041
    }
9042
 
9043
    public void unsetSuccess() {
9044
      this.success = null;
9045
    }
9046
 
9047
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9048
    public boolean isSetSuccess() {
9049
      return this.success != null;
9050
    }
9051
 
9052
    public void setSuccessIsSet(boolean value) {
9053
      if (!value) {
9054
        this.success = null;
9055
      }
9056
    }
9057
 
9058
    public PaymentException getPe() {
9059
      return this.pe;
9060
    }
9061
 
9062
    public void setPe(PaymentException pe) {
9063
      this.pe = pe;
9064
    }
9065
 
9066
    public void unsetPe() {
9067
      this.pe = null;
9068
    }
9069
 
9070
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
9071
    public boolean isSetPe() {
9072
      return this.pe != null;
9073
    }
9074
 
9075
    public void setPeIsSet(boolean value) {
9076
      if (!value) {
9077
        this.pe = null;
9078
      }
9079
    }
9080
 
9081
    public void setFieldValue(_Fields field, Object value) {
9082
      switch (field) {
9083
      case SUCCESS:
9084
        if (value == null) {
9085
          unsetSuccess();
9086
        } else {
9087
          setSuccess((Payment)value);
9088
        }
9089
        break;
9090
 
9091
      case PE:
9092
        if (value == null) {
9093
          unsetPe();
9094
        } else {
9095
          setPe((PaymentException)value);
9096
        }
9097
        break;
9098
 
9099
      }
9100
    }
9101
 
9102
    public Object getFieldValue(_Fields field) {
9103
      switch (field) {
9104
      case SUCCESS:
9105
        return getSuccess();
9106
 
9107
      case PE:
9108
        return getPe();
9109
 
9110
      }
9111
      throw new IllegalStateException();
9112
    }
9113
 
9114
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9115
    public boolean isSet(_Fields field) {
9116
      if (field == null) {
9117
        throw new IllegalArgumentException();
9118
      }
9119
 
9120
      switch (field) {
9121
      case SUCCESS:
9122
        return isSetSuccess();
9123
      case PE:
9124
        return isSetPe();
9125
      }
9126
      throw new IllegalStateException();
9127
    }
9128
 
9129
    @Override
9130
    public boolean equals(Object that) {
9131
      if (that == null)
9132
        return false;
9133
      if (that instanceof getSuccessfulPaymentForTxnId_result)
9134
        return this.equals((getSuccessfulPaymentForTxnId_result)that);
9135
      return false;
9136
    }
9137
 
9138
    public boolean equals(getSuccessfulPaymentForTxnId_result that) {
9139
      if (that == null)
9140
        return false;
9141
 
9142
      boolean this_present_success = true && this.isSetSuccess();
9143
      boolean that_present_success = true && that.isSetSuccess();
9144
      if (this_present_success || that_present_success) {
9145
        if (!(this_present_success && that_present_success))
9146
          return false;
9147
        if (!this.success.equals(that.success))
9148
          return false;
9149
      }
9150
 
9151
      boolean this_present_pe = true && this.isSetPe();
9152
      boolean that_present_pe = true && that.isSetPe();
9153
      if (this_present_pe || that_present_pe) {
9154
        if (!(this_present_pe && that_present_pe))
9155
          return false;
9156
        if (!this.pe.equals(that.pe))
9157
          return false;
9158
      }
9159
 
9160
      return true;
9161
    }
9162
 
9163
    @Override
9164
    public int hashCode() {
9165
      return 0;
9166
    }
9167
 
9168
    public int compareTo(getSuccessfulPaymentForTxnId_result other) {
9169
      if (!getClass().equals(other.getClass())) {
9170
        return getClass().getName().compareTo(other.getClass().getName());
9171
      }
9172
 
9173
      int lastComparison = 0;
9174
      getSuccessfulPaymentForTxnId_result typedOther = (getSuccessfulPaymentForTxnId_result)other;
9175
 
9176
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9177
      if (lastComparison != 0) {
9178
        return lastComparison;
9179
      }
9180
      if (isSetSuccess()) {
9181
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9182
        if (lastComparison != 0) {
9183
          return lastComparison;
9184
        }
9185
      }
9186
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
9187
      if (lastComparison != 0) {
9188
        return lastComparison;
9189
      }
9190
      if (isSetPe()) {
9191
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
9192
        if (lastComparison != 0) {
9193
          return lastComparison;
9194
        }
9195
      }
9196
      return 0;
9197
    }
9198
 
9199
    public _Fields fieldForId(int fieldId) {
9200
      return _Fields.findByThriftId(fieldId);
9201
    }
9202
 
9203
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9204
      org.apache.thrift.protocol.TField field;
9205
      iprot.readStructBegin();
9206
      while (true)
9207
      {
9208
        field = iprot.readFieldBegin();
9209
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9210
          break;
9211
        }
9212
        switch (field.id) {
9213
          case 0: // SUCCESS
9214
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9215
              this.success = new Payment();
9216
              this.success.read(iprot);
9217
            } else { 
9218
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9219
            }
9220
            break;
9221
          case 1: // PE
9222
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9223
              this.pe = new PaymentException();
9224
              this.pe.read(iprot);
9225
            } else { 
9226
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9227
            }
9228
            break;
9229
          default:
9230
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9231
        }
9232
        iprot.readFieldEnd();
9233
      }
9234
      iprot.readStructEnd();
9235
      validate();
9236
    }
9237
 
9238
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9239
      oprot.writeStructBegin(STRUCT_DESC);
9240
 
9241
      if (this.isSetSuccess()) {
9242
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9243
        this.success.write(oprot);
9244
        oprot.writeFieldEnd();
9245
      } else if (this.isSetPe()) {
9246
        oprot.writeFieldBegin(PE_FIELD_DESC);
9247
        this.pe.write(oprot);
9248
        oprot.writeFieldEnd();
9249
      }
9250
      oprot.writeFieldStop();
9251
      oprot.writeStructEnd();
9252
    }
9253
 
9254
    @Override
9255
    public String toString() {
9256
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentForTxnId_result(");
9257
      boolean first = true;
9258
 
9259
      sb.append("success:");
9260
      if (this.success == null) {
9261
        sb.append("null");
9262
      } else {
9263
        sb.append(this.success);
9264
      }
9265
      first = false;
9266
      if (!first) sb.append(", ");
9267
      sb.append("pe:");
9268
      if (this.pe == null) {
9269
        sb.append("null");
9270
      } else {
9271
        sb.append(this.pe);
9272
      }
9273
      first = false;
9274
      sb.append(")");
9275
      return sb.toString();
9276
    }
9277
 
9278
    public void validate() throws org.apache.thrift.TException {
9279
      // check for required fields
9280
    }
9281
 
9282
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9283
      try {
9284
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9285
      } catch (org.apache.thrift.TException te) {
9286
        throw new java.io.IOException(te);
9287
      }
9288
    }
9289
 
9290
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9291
      try {
9292
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9293
      } catch (org.apache.thrift.TException te) {
9294
        throw new java.io.IOException(te);
9295
      }
9296
    }
9297
 
9298
  }
9299
 
3430 rajveer 9300
  public static class updatePaymentDetails_args implements org.apache.thrift.TBase<updatePaymentDetails_args, updatePaymentDetails_args._Fields>, java.io.Serializable, Cloneable   {
9301
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updatePaymentDetails_args");
420 ashish 9302
 
3430 rajveer 9303
    private static final org.apache.thrift.protocol.TField ID_FIELD_DESC = new org.apache.thrift.protocol.TField("id", org.apache.thrift.protocol.TType.I64, (short)1);
9304
    private static final org.apache.thrift.protocol.TField GATEWAY_PAYMENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayPaymentId", org.apache.thrift.protocol.TType.STRING, (short)2);
9305
    private static final org.apache.thrift.protocol.TField SESSION_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sessionId", org.apache.thrift.protocol.TType.STRING, (short)3);
9306
    private static final org.apache.thrift.protocol.TField GATEWAY_TXN_STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayTxnStatus", org.apache.thrift.protocol.TType.STRING, (short)4);
9307
    private static final org.apache.thrift.protocol.TField DESCRIPTION_FIELD_DESC = new org.apache.thrift.protocol.TField("description", org.apache.thrift.protocol.TType.STRING, (short)5);
9308
    private static final org.apache.thrift.protocol.TField GATEWAY_TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayTxnId", org.apache.thrift.protocol.TType.STRING, (short)6);
9309
    private static final org.apache.thrift.protocol.TField AUTH_CODE_FIELD_DESC = new org.apache.thrift.protocol.TField("authCode", org.apache.thrift.protocol.TType.STRING, (short)7);
9310
    private static final org.apache.thrift.protocol.TField REFERENCE_CODE_FIELD_DESC = new org.apache.thrift.protocol.TField("referenceCode", org.apache.thrift.protocol.TType.STRING, (short)8);
9311
    private static final org.apache.thrift.protocol.TField ERROR_CODE_FIELD_DESC = new org.apache.thrift.protocol.TField("errorCode", org.apache.thrift.protocol.TType.STRING, (short)9);
9312
    private static final org.apache.thrift.protocol.TField STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("status", org.apache.thrift.protocol.TType.I32, (short)10);
9313
    private static final org.apache.thrift.protocol.TField GATEWAY_TXN_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("gatewayTxnDate", org.apache.thrift.protocol.TType.STRING, (short)11);
9314
    private static final org.apache.thrift.protocol.TField ATTRIBUTES_FIELD_DESC = new org.apache.thrift.protocol.TField("attributes", org.apache.thrift.protocol.TType.LIST, (short)12);
420 ashish 9315
 
3430 rajveer 9316
    private long id; // required
9317
    private String gatewayPaymentId; // required
9318
    private String sessionId; // required
9319
    private String gatewayTxnStatus; // required
9320
    private String description; // required
9321
    private String gatewayTxnId; // required
9322
    private String authCode; // required
9323
    private String referenceCode; // required
9324
    private String errorCode; // required
9325
    private PaymentStatus status; // required
9326
    private String gatewayTxnDate; // required
9327
    private List<Attribute> attributes; // required
420 ashish 9328
 
9329
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 9330
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 9331
      ID((short)1, "id"),
695 rajveer 9332
      GATEWAY_PAYMENT_ID((short)2, "gatewayPaymentId"),
9333
      SESSION_ID((short)3, "sessionId"),
9334
      GATEWAY_TXN_STATUS((short)4, "gatewayTxnStatus"),
9335
      DESCRIPTION((short)5, "description"),
9336
      GATEWAY_TXN_ID((short)6, "gatewayTxnId"),
9337
      AUTH_CODE((short)7, "authCode"),
9338
      REFERENCE_CODE((short)8, "referenceCode"),
9339
      ERROR_CODE((short)9, "errorCode"),
9340
      /**
9341
       * 
9342
       * @see PaymentStatus
9343
       */
9344
      STATUS((short)10, "status"),
1119 rajveer 9345
      GATEWAY_TXN_DATE((short)11, "gatewayTxnDate"),
9346
      ATTRIBUTES((short)12, "attributes");
420 ashish 9347
 
9348
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9349
 
9350
      static {
9351
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9352
          byName.put(field.getFieldName(), field);
9353
        }
9354
      }
9355
 
9356
      /**
9357
       * Find the _Fields constant that matches fieldId, or null if its not found.
9358
       */
9359
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 9360
        switch(fieldId) {
9361
          case 1: // ID
9362
            return ID;
9363
          case 2: // GATEWAY_PAYMENT_ID
9364
            return GATEWAY_PAYMENT_ID;
9365
          case 3: // SESSION_ID
9366
            return SESSION_ID;
9367
          case 4: // GATEWAY_TXN_STATUS
9368
            return GATEWAY_TXN_STATUS;
9369
          case 5: // DESCRIPTION
9370
            return DESCRIPTION;
9371
          case 6: // GATEWAY_TXN_ID
9372
            return GATEWAY_TXN_ID;
9373
          case 7: // AUTH_CODE
9374
            return AUTH_CODE;
9375
          case 8: // REFERENCE_CODE
9376
            return REFERENCE_CODE;
9377
          case 9: // ERROR_CODE
9378
            return ERROR_CODE;
9379
          case 10: // STATUS
9380
            return STATUS;
9381
          case 11: // GATEWAY_TXN_DATE
9382
            return GATEWAY_TXN_DATE;
9383
          case 12: // ATTRIBUTES
9384
            return ATTRIBUTES;
9385
          default:
9386
            return null;
9387
        }
420 ashish 9388
      }
9389
 
9390
      /**
9391
       * Find the _Fields constant that matches fieldId, throwing an exception
9392
       * if it is not found.
9393
       */
9394
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9395
        _Fields fields = findByThriftId(fieldId);
9396
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9397
        return fields;
9398
      }
9399
 
9400
      /**
9401
       * Find the _Fields constant that matches name, or null if its not found.
9402
       */
9403
      public static _Fields findByName(String name) {
9404
        return byName.get(name);
9405
      }
9406
 
9407
      private final short _thriftId;
9408
      private final String _fieldName;
9409
 
9410
      _Fields(short thriftId, String fieldName) {
9411
        _thriftId = thriftId;
9412
        _fieldName = fieldName;
9413
      }
9414
 
9415
      public short getThriftFieldId() {
9416
        return _thriftId;
9417
      }
9418
 
9419
      public String getFieldName() {
9420
        return _fieldName;
9421
      }
9422
    }
9423
 
9424
    // isset id assignments
9425
    private static final int __ID_ISSET_ID = 0;
9426
    private BitSet __isset_bit_vector = new BitSet(1);
9427
 
3430 rajveer 9428
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 9429
    static {
3430 rajveer 9430
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9431
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9432
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
9433
      tmpMap.put(_Fields.GATEWAY_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9434
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9435
      tmpMap.put(_Fields.SESSION_ID, new org.apache.thrift.meta_data.FieldMetaData("sessionId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9436
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9437
      tmpMap.put(_Fields.GATEWAY_TXN_STATUS, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnStatus", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9438
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9439
      tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9440
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9441
      tmpMap.put(_Fields.GATEWAY_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9442
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9443
      tmpMap.put(_Fields.AUTH_CODE, new org.apache.thrift.meta_data.FieldMetaData("authCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9444
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9445
      tmpMap.put(_Fields.REFERENCE_CODE, new org.apache.thrift.meta_data.FieldMetaData("referenceCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9446
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9447
      tmpMap.put(_Fields.ERROR_CODE, new org.apache.thrift.meta_data.FieldMetaData("errorCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9448
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9449
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9450
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
9451
      tmpMap.put(_Fields.GATEWAY_TXN_DATE, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9452
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
9453
      tmpMap.put(_Fields.ATTRIBUTES, new org.apache.thrift.meta_data.FieldMetaData("attributes", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9454
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9455
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Attribute.class))));
9456
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9457
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updatePaymentDetails_args.class, metaDataMap);
420 ashish 9458
    }
9459
 
695 rajveer 9460
    public updatePaymentDetails_args() {
420 ashish 9461
    }
9462
 
695 rajveer 9463
    public updatePaymentDetails_args(
420 ashish 9464
      long id,
695 rajveer 9465
      String gatewayPaymentId,
9466
      String sessionId,
9467
      String gatewayTxnStatus,
9468
      String description,
9469
      String gatewayTxnId,
9470
      String authCode,
9471
      String referenceCode,
9472
      String errorCode,
9473
      PaymentStatus status,
1119 rajveer 9474
      String gatewayTxnDate,
695 rajveer 9475
      List<Attribute> attributes)
420 ashish 9476
    {
9477
      this();
9478
      this.id = id;
9479
      setIdIsSet(true);
695 rajveer 9480
      this.gatewayPaymentId = gatewayPaymentId;
9481
      this.sessionId = sessionId;
9482
      this.gatewayTxnStatus = gatewayTxnStatus;
9483
      this.description = description;
9484
      this.gatewayTxnId = gatewayTxnId;
9485
      this.authCode = authCode;
9486
      this.referenceCode = referenceCode;
9487
      this.errorCode = errorCode;
9488
      this.status = status;
1119 rajveer 9489
      this.gatewayTxnDate = gatewayTxnDate;
695 rajveer 9490
      this.attributes = attributes;
420 ashish 9491
    }
9492
 
9493
    /**
9494
     * Performs a deep copy on <i>other</i>.
9495
     */
695 rajveer 9496
    public updatePaymentDetails_args(updatePaymentDetails_args other) {
420 ashish 9497
      __isset_bit_vector.clear();
9498
      __isset_bit_vector.or(other.__isset_bit_vector);
9499
      this.id = other.id;
695 rajveer 9500
      if (other.isSetGatewayPaymentId()) {
9501
        this.gatewayPaymentId = other.gatewayPaymentId;
420 ashish 9502
      }
695 rajveer 9503
      if (other.isSetSessionId()) {
9504
        this.sessionId = other.sessionId;
420 ashish 9505
      }
695 rajveer 9506
      if (other.isSetGatewayTxnStatus()) {
9507
        this.gatewayTxnStatus = other.gatewayTxnStatus;
420 ashish 9508
      }
695 rajveer 9509
      if (other.isSetDescription()) {
9510
        this.description = other.description;
420 ashish 9511
      }
695 rajveer 9512
      if (other.isSetGatewayTxnId()) {
9513
        this.gatewayTxnId = other.gatewayTxnId;
420 ashish 9514
      }
695 rajveer 9515
      if (other.isSetAuthCode()) {
9516
        this.authCode = other.authCode;
420 ashish 9517
      }
695 rajveer 9518
      if (other.isSetReferenceCode()) {
9519
        this.referenceCode = other.referenceCode;
420 ashish 9520
      }
695 rajveer 9521
      if (other.isSetErrorCode()) {
9522
        this.errorCode = other.errorCode;
9523
      }
9524
      if (other.isSetStatus()) {
9525
        this.status = other.status;
9526
      }
1119 rajveer 9527
      if (other.isSetGatewayTxnDate()) {
9528
        this.gatewayTxnDate = other.gatewayTxnDate;
9529
      }
695 rajveer 9530
      if (other.isSetAttributes()) {
9531
        List<Attribute> __this__attributes = new ArrayList<Attribute>();
9532
        for (Attribute other_element : other.attributes) {
9533
          __this__attributes.add(new Attribute(other_element));
9534
        }
9535
        this.attributes = __this__attributes;
9536
      }
420 ashish 9537
    }
9538
 
695 rajveer 9539
    public updatePaymentDetails_args deepCopy() {
9540
      return new updatePaymentDetails_args(this);
420 ashish 9541
    }
9542
 
3430 rajveer 9543
    @Override
9544
    public void clear() {
9545
      setIdIsSet(false);
9546
      this.id = 0;
9547
      this.gatewayPaymentId = null;
9548
      this.sessionId = null;
9549
      this.gatewayTxnStatus = null;
9550
      this.description = null;
9551
      this.gatewayTxnId = null;
9552
      this.authCode = null;
9553
      this.referenceCode = null;
9554
      this.errorCode = null;
9555
      this.status = null;
9556
      this.gatewayTxnDate = null;
9557
      this.attributes = null;
420 ashish 9558
    }
9559
 
9560
    public long getId() {
9561
      return this.id;
9562
    }
9563
 
3430 rajveer 9564
    public void setId(long id) {
420 ashish 9565
      this.id = id;
9566
      setIdIsSet(true);
9567
    }
9568
 
9569
    public void unsetId() {
9570
      __isset_bit_vector.clear(__ID_ISSET_ID);
9571
    }
9572
 
3430 rajveer 9573
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 9574
    public boolean isSetId() {
9575
      return __isset_bit_vector.get(__ID_ISSET_ID);
9576
    }
9577
 
9578
    public void setIdIsSet(boolean value) {
9579
      __isset_bit_vector.set(__ID_ISSET_ID, value);
9580
    }
9581
 
695 rajveer 9582
    public String getGatewayPaymentId() {
9583
      return this.gatewayPaymentId;
420 ashish 9584
    }
9585
 
3430 rajveer 9586
    public void setGatewayPaymentId(String gatewayPaymentId) {
695 rajveer 9587
      this.gatewayPaymentId = gatewayPaymentId;
420 ashish 9588
    }
9589
 
695 rajveer 9590
    public void unsetGatewayPaymentId() {
9591
      this.gatewayPaymentId = null;
420 ashish 9592
    }
9593
 
3430 rajveer 9594
    /** Returns true if field gatewayPaymentId is set (has been assigned a value) and false otherwise */
695 rajveer 9595
    public boolean isSetGatewayPaymentId() {
9596
      return this.gatewayPaymentId != null;
420 ashish 9597
    }
9598
 
695 rajveer 9599
    public void setGatewayPaymentIdIsSet(boolean value) {
420 ashish 9600
      if (!value) {
695 rajveer 9601
        this.gatewayPaymentId = null;
420 ashish 9602
      }
9603
    }
9604
 
695 rajveer 9605
    public String getSessionId() {
9606
      return this.sessionId;
420 ashish 9607
    }
9608
 
3430 rajveer 9609
    public void setSessionId(String sessionId) {
695 rajveer 9610
      this.sessionId = sessionId;
420 ashish 9611
    }
9612
 
695 rajveer 9613
    public void unsetSessionId() {
9614
      this.sessionId = null;
420 ashish 9615
    }
9616
 
3430 rajveer 9617
    /** Returns true if field sessionId is set (has been assigned a value) and false otherwise */
695 rajveer 9618
    public boolean isSetSessionId() {
9619
      return this.sessionId != null;
420 ashish 9620
    }
9621
 
695 rajveer 9622
    public void setSessionIdIsSet(boolean value) {
420 ashish 9623
      if (!value) {
695 rajveer 9624
        this.sessionId = null;
420 ashish 9625
      }
9626
    }
9627
 
695 rajveer 9628
    public String getGatewayTxnStatus() {
9629
      return this.gatewayTxnStatus;
420 ashish 9630
    }
9631
 
3430 rajveer 9632
    public void setGatewayTxnStatus(String gatewayTxnStatus) {
695 rajveer 9633
      this.gatewayTxnStatus = gatewayTxnStatus;
420 ashish 9634
    }
9635
 
695 rajveer 9636
    public void unsetGatewayTxnStatus() {
9637
      this.gatewayTxnStatus = null;
420 ashish 9638
    }
9639
 
3430 rajveer 9640
    /** Returns true if field gatewayTxnStatus is set (has been assigned a value) and false otherwise */
695 rajveer 9641
    public boolean isSetGatewayTxnStatus() {
9642
      return this.gatewayTxnStatus != null;
420 ashish 9643
    }
9644
 
695 rajveer 9645
    public void setGatewayTxnStatusIsSet(boolean value) {
420 ashish 9646
      if (!value) {
695 rajveer 9647
        this.gatewayTxnStatus = null;
420 ashish 9648
      }
9649
    }
9650
 
695 rajveer 9651
    public String getDescription() {
9652
      return this.description;
420 ashish 9653
    }
9654
 
3430 rajveer 9655
    public void setDescription(String description) {
695 rajveer 9656
      this.description = description;
420 ashish 9657
    }
9658
 
695 rajveer 9659
    public void unsetDescription() {
9660
      this.description = null;
420 ashish 9661
    }
9662
 
3430 rajveer 9663
    /** Returns true if field description is set (has been assigned a value) and false otherwise */
695 rajveer 9664
    public boolean isSetDescription() {
9665
      return this.description != null;
420 ashish 9666
    }
9667
 
695 rajveer 9668
    public void setDescriptionIsSet(boolean value) {
420 ashish 9669
      if (!value) {
695 rajveer 9670
        this.description = null;
420 ashish 9671
      }
9672
    }
9673
 
695 rajveer 9674
    public String getGatewayTxnId() {
9675
      return this.gatewayTxnId;
420 ashish 9676
    }
9677
 
3430 rajveer 9678
    public void setGatewayTxnId(String gatewayTxnId) {
695 rajveer 9679
      this.gatewayTxnId = gatewayTxnId;
420 ashish 9680
    }
9681
 
695 rajveer 9682
    public void unsetGatewayTxnId() {
9683
      this.gatewayTxnId = null;
420 ashish 9684
    }
9685
 
3430 rajveer 9686
    /** Returns true if field gatewayTxnId is set (has been assigned a value) and false otherwise */
695 rajveer 9687
    public boolean isSetGatewayTxnId() {
9688
      return this.gatewayTxnId != null;
420 ashish 9689
    }
9690
 
695 rajveer 9691
    public void setGatewayTxnIdIsSet(boolean value) {
420 ashish 9692
      if (!value) {
695 rajveer 9693
        this.gatewayTxnId = null;
420 ashish 9694
      }
9695
    }
9696
 
695 rajveer 9697
    public String getAuthCode() {
9698
      return this.authCode;
420 ashish 9699
    }
9700
 
3430 rajveer 9701
    public void setAuthCode(String authCode) {
695 rajveer 9702
      this.authCode = authCode;
420 ashish 9703
    }
9704
 
695 rajveer 9705
    public void unsetAuthCode() {
9706
      this.authCode = null;
420 ashish 9707
    }
9708
 
3430 rajveer 9709
    /** Returns true if field authCode is set (has been assigned a value) and false otherwise */
695 rajveer 9710
    public boolean isSetAuthCode() {
9711
      return this.authCode != null;
420 ashish 9712
    }
9713
 
695 rajveer 9714
    public void setAuthCodeIsSet(boolean value) {
420 ashish 9715
      if (!value) {
695 rajveer 9716
        this.authCode = null;
420 ashish 9717
      }
9718
    }
9719
 
695 rajveer 9720
    public String getReferenceCode() {
9721
      return this.referenceCode;
420 ashish 9722
    }
9723
 
3430 rajveer 9724
    public void setReferenceCode(String referenceCode) {
695 rajveer 9725
      this.referenceCode = referenceCode;
420 ashish 9726
    }
9727
 
695 rajveer 9728
    public void unsetReferenceCode() {
9729
      this.referenceCode = null;
420 ashish 9730
    }
9731
 
3430 rajveer 9732
    /** Returns true if field referenceCode is set (has been assigned a value) and false otherwise */
695 rajveer 9733
    public boolean isSetReferenceCode() {
9734
      return this.referenceCode != null;
420 ashish 9735
    }
9736
 
695 rajveer 9737
    public void setReferenceCodeIsSet(boolean value) {
420 ashish 9738
      if (!value) {
695 rajveer 9739
        this.referenceCode = null;
420 ashish 9740
      }
9741
    }
9742
 
695 rajveer 9743
    public String getErrorCode() {
9744
      return this.errorCode;
9745
    }
9746
 
3430 rajveer 9747
    public void setErrorCode(String errorCode) {
695 rajveer 9748
      this.errorCode = errorCode;
9749
    }
9750
 
9751
    public void unsetErrorCode() {
9752
      this.errorCode = null;
9753
    }
9754
 
3430 rajveer 9755
    /** Returns true if field errorCode is set (has been assigned a value) and false otherwise */
695 rajveer 9756
    public boolean isSetErrorCode() {
9757
      return this.errorCode != null;
9758
    }
9759
 
9760
    public void setErrorCodeIsSet(boolean value) {
9761
      if (!value) {
9762
        this.errorCode = null;
9763
      }
9764
    }
9765
 
9766
    /**
9767
     * 
9768
     * @see PaymentStatus
9769
     */
9770
    public PaymentStatus getStatus() {
9771
      return this.status;
9772
    }
9773
 
9774
    /**
9775
     * 
9776
     * @see PaymentStatus
9777
     */
3430 rajveer 9778
    public void setStatus(PaymentStatus status) {
695 rajveer 9779
      this.status = status;
9780
    }
9781
 
9782
    public void unsetStatus() {
9783
      this.status = null;
9784
    }
9785
 
3430 rajveer 9786
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
695 rajveer 9787
    public boolean isSetStatus() {
9788
      return this.status != null;
9789
    }
9790
 
9791
    public void setStatusIsSet(boolean value) {
9792
      if (!value) {
9793
        this.status = null;
9794
      }
9795
    }
9796
 
1119 rajveer 9797
    public String getGatewayTxnDate() {
9798
      return this.gatewayTxnDate;
9799
    }
9800
 
3430 rajveer 9801
    public void setGatewayTxnDate(String gatewayTxnDate) {
1119 rajveer 9802
      this.gatewayTxnDate = gatewayTxnDate;
9803
    }
9804
 
9805
    public void unsetGatewayTxnDate() {
9806
      this.gatewayTxnDate = null;
9807
    }
9808
 
3430 rajveer 9809
    /** Returns true if field gatewayTxnDate is set (has been assigned a value) and false otherwise */
1119 rajveer 9810
    public boolean isSetGatewayTxnDate() {
9811
      return this.gatewayTxnDate != null;
9812
    }
9813
 
9814
    public void setGatewayTxnDateIsSet(boolean value) {
9815
      if (!value) {
9816
        this.gatewayTxnDate = null;
9817
      }
9818
    }
9819
 
695 rajveer 9820
    public int getAttributesSize() {
9821
      return (this.attributes == null) ? 0 : this.attributes.size();
9822
    }
9823
 
9824
    public java.util.Iterator<Attribute> getAttributesIterator() {
9825
      return (this.attributes == null) ? null : this.attributes.iterator();
9826
    }
9827
 
9828
    public void addToAttributes(Attribute elem) {
9829
      if (this.attributes == null) {
9830
        this.attributes = new ArrayList<Attribute>();
9831
      }
9832
      this.attributes.add(elem);
9833
    }
9834
 
9835
    public List<Attribute> getAttributes() {
9836
      return this.attributes;
9837
    }
9838
 
3430 rajveer 9839
    public void setAttributes(List<Attribute> attributes) {
695 rajveer 9840
      this.attributes = attributes;
9841
    }
9842
 
9843
    public void unsetAttributes() {
9844
      this.attributes = null;
9845
    }
9846
 
3430 rajveer 9847
    /** Returns true if field attributes is set (has been assigned a value) and false otherwise */
695 rajveer 9848
    public boolean isSetAttributes() {
9849
      return this.attributes != null;
9850
    }
9851
 
9852
    public void setAttributesIsSet(boolean value) {
9853
      if (!value) {
9854
        this.attributes = null;
9855
      }
9856
    }
9857
 
420 ashish 9858
    public void setFieldValue(_Fields field, Object value) {
9859
      switch (field) {
9860
      case ID:
9861
        if (value == null) {
9862
          unsetId();
9863
        } else {
9864
          setId((Long)value);
9865
        }
9866
        break;
9867
 
695 rajveer 9868
      case GATEWAY_PAYMENT_ID:
420 ashish 9869
        if (value == null) {
695 rajveer 9870
          unsetGatewayPaymentId();
420 ashish 9871
        } else {
695 rajveer 9872
          setGatewayPaymentId((String)value);
420 ashish 9873
        }
9874
        break;
9875
 
695 rajveer 9876
      case SESSION_ID:
420 ashish 9877
        if (value == null) {
695 rajveer 9878
          unsetSessionId();
420 ashish 9879
        } else {
695 rajveer 9880
          setSessionId((String)value);
420 ashish 9881
        }
9882
        break;
9883
 
695 rajveer 9884
      case GATEWAY_TXN_STATUS:
420 ashish 9885
        if (value == null) {
695 rajveer 9886
          unsetGatewayTxnStatus();
420 ashish 9887
        } else {
695 rajveer 9888
          setGatewayTxnStatus((String)value);
420 ashish 9889
        }
9890
        break;
9891
 
695 rajveer 9892
      case DESCRIPTION:
420 ashish 9893
        if (value == null) {
695 rajveer 9894
          unsetDescription();
420 ashish 9895
        } else {
695 rajveer 9896
          setDescription((String)value);
420 ashish 9897
        }
9898
        break;
9899
 
695 rajveer 9900
      case GATEWAY_TXN_ID:
420 ashish 9901
        if (value == null) {
695 rajveer 9902
          unsetGatewayTxnId();
420 ashish 9903
        } else {
695 rajveer 9904
          setGatewayTxnId((String)value);
420 ashish 9905
        }
9906
        break;
9907
 
9908
      case AUTH_CODE:
9909
        if (value == null) {
695 rajveer 9910
          unsetAuthCode();
420 ashish 9911
        } else {
695 rajveer 9912
          setAuthCode((String)value);
420 ashish 9913
        }
9914
        break;
9915
 
695 rajveer 9916
      case REFERENCE_CODE:
420 ashish 9917
        if (value == null) {
695 rajveer 9918
          unsetReferenceCode();
420 ashish 9919
        } else {
695 rajveer 9920
          setReferenceCode((String)value);
420 ashish 9921
        }
9922
        break;
9923
 
695 rajveer 9924
      case ERROR_CODE:
9925
        if (value == null) {
9926
          unsetErrorCode();
9927
        } else {
9928
          setErrorCode((String)value);
9929
        }
9930
        break;
9931
 
9932
      case STATUS:
9933
        if (value == null) {
9934
          unsetStatus();
9935
        } else {
9936
          setStatus((PaymentStatus)value);
9937
        }
9938
        break;
9939
 
1119 rajveer 9940
      case GATEWAY_TXN_DATE:
9941
        if (value == null) {
9942
          unsetGatewayTxnDate();
9943
        } else {
9944
          setGatewayTxnDate((String)value);
9945
        }
9946
        break;
9947
 
695 rajveer 9948
      case ATTRIBUTES:
9949
        if (value == null) {
9950
          unsetAttributes();
9951
        } else {
9952
          setAttributes((List<Attribute>)value);
9953
        }
9954
        break;
9955
 
420 ashish 9956
      }
9957
    }
9958
 
9959
    public Object getFieldValue(_Fields field) {
9960
      switch (field) {
9961
      case ID:
3430 rajveer 9962
        return Long.valueOf(getId());
420 ashish 9963
 
695 rajveer 9964
      case GATEWAY_PAYMENT_ID:
9965
        return getGatewayPaymentId();
420 ashish 9966
 
695 rajveer 9967
      case SESSION_ID:
9968
        return getSessionId();
420 ashish 9969
 
695 rajveer 9970
      case GATEWAY_TXN_STATUS:
9971
        return getGatewayTxnStatus();
420 ashish 9972
 
695 rajveer 9973
      case DESCRIPTION:
9974
        return getDescription();
420 ashish 9975
 
695 rajveer 9976
      case GATEWAY_TXN_ID:
9977
        return getGatewayTxnId();
420 ashish 9978
 
9979
      case AUTH_CODE:
695 rajveer 9980
        return getAuthCode();
420 ashish 9981
 
695 rajveer 9982
      case REFERENCE_CODE:
9983
        return getReferenceCode();
420 ashish 9984
 
695 rajveer 9985
      case ERROR_CODE:
9986
        return getErrorCode();
9987
 
9988
      case STATUS:
9989
        return getStatus();
9990
 
1119 rajveer 9991
      case GATEWAY_TXN_DATE:
9992
        return getGatewayTxnDate();
9993
 
695 rajveer 9994
      case ATTRIBUTES:
9995
        return getAttributes();
9996
 
420 ashish 9997
      }
9998
      throw new IllegalStateException();
9999
    }
10000
 
3430 rajveer 10001
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10002
    public boolean isSet(_Fields field) {
10003
      if (field == null) {
10004
        throw new IllegalArgumentException();
10005
      }
420 ashish 10006
 
10007
      switch (field) {
10008
      case ID:
10009
        return isSetId();
695 rajveer 10010
      case GATEWAY_PAYMENT_ID:
10011
        return isSetGatewayPaymentId();
420 ashish 10012
      case SESSION_ID:
695 rajveer 10013
        return isSetSessionId();
10014
      case GATEWAY_TXN_STATUS:
10015
        return isSetGatewayTxnStatus();
10016
      case DESCRIPTION:
10017
        return isSetDescription();
10018
      case GATEWAY_TXN_ID:
10019
        return isSetGatewayTxnId();
420 ashish 10020
      case AUTH_CODE:
695 rajveer 10021
        return isSetAuthCode();
10022
      case REFERENCE_CODE:
10023
        return isSetReferenceCode();
10024
      case ERROR_CODE:
10025
        return isSetErrorCode();
10026
      case STATUS:
10027
        return isSetStatus();
1119 rajveer 10028
      case GATEWAY_TXN_DATE:
10029
        return isSetGatewayTxnDate();
695 rajveer 10030
      case ATTRIBUTES:
10031
        return isSetAttributes();
420 ashish 10032
      }
10033
      throw new IllegalStateException();
10034
    }
10035
 
10036
    @Override
10037
    public boolean equals(Object that) {
10038
      if (that == null)
10039
        return false;
695 rajveer 10040
      if (that instanceof updatePaymentDetails_args)
10041
        return this.equals((updatePaymentDetails_args)that);
420 ashish 10042
      return false;
10043
    }
10044
 
695 rajveer 10045
    public boolean equals(updatePaymentDetails_args that) {
420 ashish 10046
      if (that == null)
10047
        return false;
10048
 
10049
      boolean this_present_id = true;
10050
      boolean that_present_id = true;
10051
      if (this_present_id || that_present_id) {
10052
        if (!(this_present_id && that_present_id))
10053
          return false;
10054
        if (this.id != that.id)
10055
          return false;
10056
      }
10057
 
695 rajveer 10058
      boolean this_present_gatewayPaymentId = true && this.isSetGatewayPaymentId();
10059
      boolean that_present_gatewayPaymentId = true && that.isSetGatewayPaymentId();
10060
      if (this_present_gatewayPaymentId || that_present_gatewayPaymentId) {
10061
        if (!(this_present_gatewayPaymentId && that_present_gatewayPaymentId))
420 ashish 10062
          return false;
695 rajveer 10063
        if (!this.gatewayPaymentId.equals(that.gatewayPaymentId))
420 ashish 10064
          return false;
10065
      }
10066
 
695 rajveer 10067
      boolean this_present_sessionId = true && this.isSetSessionId();
10068
      boolean that_present_sessionId = true && that.isSetSessionId();
10069
      if (this_present_sessionId || that_present_sessionId) {
10070
        if (!(this_present_sessionId && that_present_sessionId))
420 ashish 10071
          return false;
695 rajveer 10072
        if (!this.sessionId.equals(that.sessionId))
420 ashish 10073
          return false;
10074
      }
10075
 
695 rajveer 10076
      boolean this_present_gatewayTxnStatus = true && this.isSetGatewayTxnStatus();
10077
      boolean that_present_gatewayTxnStatus = true && that.isSetGatewayTxnStatus();
10078
      if (this_present_gatewayTxnStatus || that_present_gatewayTxnStatus) {
10079
        if (!(this_present_gatewayTxnStatus && that_present_gatewayTxnStatus))
420 ashish 10080
          return false;
695 rajveer 10081
        if (!this.gatewayTxnStatus.equals(that.gatewayTxnStatus))
420 ashish 10082
          return false;
10083
      }
10084
 
695 rajveer 10085
      boolean this_present_description = true && this.isSetDescription();
10086
      boolean that_present_description = true && that.isSetDescription();
10087
      if (this_present_description || that_present_description) {
10088
        if (!(this_present_description && that_present_description))
420 ashish 10089
          return false;
695 rajveer 10090
        if (!this.description.equals(that.description))
420 ashish 10091
          return false;
10092
      }
10093
 
695 rajveer 10094
      boolean this_present_gatewayTxnId = true && this.isSetGatewayTxnId();
10095
      boolean that_present_gatewayTxnId = true && that.isSetGatewayTxnId();
10096
      if (this_present_gatewayTxnId || that_present_gatewayTxnId) {
10097
        if (!(this_present_gatewayTxnId && that_present_gatewayTxnId))
420 ashish 10098
          return false;
695 rajveer 10099
        if (!this.gatewayTxnId.equals(that.gatewayTxnId))
420 ashish 10100
          return false;
10101
      }
10102
 
695 rajveer 10103
      boolean this_present_authCode = true && this.isSetAuthCode();
10104
      boolean that_present_authCode = true && that.isSetAuthCode();
10105
      if (this_present_authCode || that_present_authCode) {
10106
        if (!(this_present_authCode && that_present_authCode))
420 ashish 10107
          return false;
695 rajveer 10108
        if (!this.authCode.equals(that.authCode))
420 ashish 10109
          return false;
10110
      }
10111
 
695 rajveer 10112
      boolean this_present_referenceCode = true && this.isSetReferenceCode();
10113
      boolean that_present_referenceCode = true && that.isSetReferenceCode();
10114
      if (this_present_referenceCode || that_present_referenceCode) {
10115
        if (!(this_present_referenceCode && that_present_referenceCode))
420 ashish 10116
          return false;
695 rajveer 10117
        if (!this.referenceCode.equals(that.referenceCode))
420 ashish 10118
          return false;
10119
      }
10120
 
695 rajveer 10121
      boolean this_present_errorCode = true && this.isSetErrorCode();
10122
      boolean that_present_errorCode = true && that.isSetErrorCode();
10123
      if (this_present_errorCode || that_present_errorCode) {
10124
        if (!(this_present_errorCode && that_present_errorCode))
10125
          return false;
10126
        if (!this.errorCode.equals(that.errorCode))
10127
          return false;
10128
      }
10129
 
10130
      boolean this_present_status = true && this.isSetStatus();
10131
      boolean that_present_status = true && that.isSetStatus();
10132
      if (this_present_status || that_present_status) {
10133
        if (!(this_present_status && that_present_status))
10134
          return false;
10135
        if (!this.status.equals(that.status))
10136
          return false;
10137
      }
10138
 
1119 rajveer 10139
      boolean this_present_gatewayTxnDate = true && this.isSetGatewayTxnDate();
10140
      boolean that_present_gatewayTxnDate = true && that.isSetGatewayTxnDate();
10141
      if (this_present_gatewayTxnDate || that_present_gatewayTxnDate) {
10142
        if (!(this_present_gatewayTxnDate && that_present_gatewayTxnDate))
10143
          return false;
10144
        if (!this.gatewayTxnDate.equals(that.gatewayTxnDate))
10145
          return false;
10146
      }
10147
 
695 rajveer 10148
      boolean this_present_attributes = true && this.isSetAttributes();
10149
      boolean that_present_attributes = true && that.isSetAttributes();
10150
      if (this_present_attributes || that_present_attributes) {
10151
        if (!(this_present_attributes && that_present_attributes))
10152
          return false;
10153
        if (!this.attributes.equals(that.attributes))
10154
          return false;
10155
      }
10156
 
420 ashish 10157
      return true;
10158
    }
10159
 
10160
    @Override
10161
    public int hashCode() {
10162
      return 0;
10163
    }
10164
 
695 rajveer 10165
    public int compareTo(updatePaymentDetails_args other) {
420 ashish 10166
      if (!getClass().equals(other.getClass())) {
10167
        return getClass().getName().compareTo(other.getClass().getName());
10168
      }
10169
 
10170
      int lastComparison = 0;
695 rajveer 10171
      updatePaymentDetails_args typedOther = (updatePaymentDetails_args)other;
420 ashish 10172
 
3430 rajveer 10173
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
420 ashish 10174
      if (lastComparison != 0) {
10175
        return lastComparison;
10176
      }
3430 rajveer 10177
      if (isSetId()) {
10178
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
10179
        if (lastComparison != 0) {
10180
          return lastComparison;
10181
        }
420 ashish 10182
      }
3430 rajveer 10183
      lastComparison = Boolean.valueOf(isSetGatewayPaymentId()).compareTo(typedOther.isSetGatewayPaymentId());
420 ashish 10184
      if (lastComparison != 0) {
10185
        return lastComparison;
10186
      }
3430 rajveer 10187
      if (isSetGatewayPaymentId()) {
10188
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayPaymentId, typedOther.gatewayPaymentId);
10189
        if (lastComparison != 0) {
10190
          return lastComparison;
10191
        }
420 ashish 10192
      }
3430 rajveer 10193
      lastComparison = Boolean.valueOf(isSetSessionId()).compareTo(typedOther.isSetSessionId());
420 ashish 10194
      if (lastComparison != 0) {
10195
        return lastComparison;
10196
      }
3430 rajveer 10197
      if (isSetSessionId()) {
10198
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sessionId, typedOther.sessionId);
10199
        if (lastComparison != 0) {
10200
          return lastComparison;
10201
        }
420 ashish 10202
      }
3430 rajveer 10203
      lastComparison = Boolean.valueOf(isSetGatewayTxnStatus()).compareTo(typedOther.isSetGatewayTxnStatus());
420 ashish 10204
      if (lastComparison != 0) {
10205
        return lastComparison;
10206
      }
3430 rajveer 10207
      if (isSetGatewayTxnStatus()) {
10208
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnStatus, typedOther.gatewayTxnStatus);
10209
        if (lastComparison != 0) {
10210
          return lastComparison;
10211
        }
420 ashish 10212
      }
3430 rajveer 10213
      lastComparison = Boolean.valueOf(isSetDescription()).compareTo(typedOther.isSetDescription());
420 ashish 10214
      if (lastComparison != 0) {
10215
        return lastComparison;
10216
      }
3430 rajveer 10217
      if (isSetDescription()) {
10218
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.description, typedOther.description);
10219
        if (lastComparison != 0) {
10220
          return lastComparison;
10221
        }
420 ashish 10222
      }
3430 rajveer 10223
      lastComparison = Boolean.valueOf(isSetGatewayTxnId()).compareTo(typedOther.isSetGatewayTxnId());
420 ashish 10224
      if (lastComparison != 0) {
10225
        return lastComparison;
10226
      }
3430 rajveer 10227
      if (isSetGatewayTxnId()) {
10228
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnId, typedOther.gatewayTxnId);
10229
        if (lastComparison != 0) {
10230
          return lastComparison;
10231
        }
420 ashish 10232
      }
3430 rajveer 10233
      lastComparison = Boolean.valueOf(isSetAuthCode()).compareTo(typedOther.isSetAuthCode());
420 ashish 10234
      if (lastComparison != 0) {
10235
        return lastComparison;
10236
      }
3430 rajveer 10237
      if (isSetAuthCode()) {
10238
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.authCode, typedOther.authCode);
10239
        if (lastComparison != 0) {
10240
          return lastComparison;
10241
        }
420 ashish 10242
      }
3430 rajveer 10243
      lastComparison = Boolean.valueOf(isSetReferenceCode()).compareTo(typedOther.isSetReferenceCode());
420 ashish 10244
      if (lastComparison != 0) {
10245
        return lastComparison;
10246
      }
3430 rajveer 10247
      if (isSetReferenceCode()) {
10248
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.referenceCode, typedOther.referenceCode);
10249
        if (lastComparison != 0) {
10250
          return lastComparison;
10251
        }
420 ashish 10252
      }
3430 rajveer 10253
      lastComparison = Boolean.valueOf(isSetErrorCode()).compareTo(typedOther.isSetErrorCode());
695 rajveer 10254
      if (lastComparison != 0) {
10255
        return lastComparison;
10256
      }
3430 rajveer 10257
      if (isSetErrorCode()) {
10258
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errorCode, typedOther.errorCode);
10259
        if (lastComparison != 0) {
10260
          return lastComparison;
10261
        }
695 rajveer 10262
      }
3430 rajveer 10263
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
695 rajveer 10264
      if (lastComparison != 0) {
10265
        return lastComparison;
10266
      }
3430 rajveer 10267
      if (isSetStatus()) {
10268
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
10269
        if (lastComparison != 0) {
10270
          return lastComparison;
10271
        }
695 rajveer 10272
      }
3430 rajveer 10273
      lastComparison = Boolean.valueOf(isSetGatewayTxnDate()).compareTo(typedOther.isSetGatewayTxnDate());
1119 rajveer 10274
      if (lastComparison != 0) {
10275
        return lastComparison;
10276
      }
3430 rajveer 10277
      if (isSetGatewayTxnDate()) {
10278
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnDate, typedOther.gatewayTxnDate);
10279
        if (lastComparison != 0) {
10280
          return lastComparison;
10281
        }
1119 rajveer 10282
      }
3430 rajveer 10283
      lastComparison = Boolean.valueOf(isSetAttributes()).compareTo(typedOther.isSetAttributes());
695 rajveer 10284
      if (lastComparison != 0) {
10285
        return lastComparison;
10286
      }
3430 rajveer 10287
      if (isSetAttributes()) {
10288
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.attributes, typedOther.attributes);
10289
        if (lastComparison != 0) {
10290
          return lastComparison;
10291
        }
695 rajveer 10292
      }
420 ashish 10293
      return 0;
10294
    }
10295
 
3430 rajveer 10296
    public _Fields fieldForId(int fieldId) {
10297
      return _Fields.findByThriftId(fieldId);
10298
    }
10299
 
10300
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10301
      org.apache.thrift.protocol.TField field;
420 ashish 10302
      iprot.readStructBegin();
10303
      while (true)
10304
      {
10305
        field = iprot.readFieldBegin();
3430 rajveer 10306
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 10307
          break;
10308
        }
3430 rajveer 10309
        switch (field.id) {
10310
          case 1: // ID
10311
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10312
              this.id = iprot.readI64();
10313
              setIdIsSet(true);
10314
            } else { 
10315
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10316
            }
10317
            break;
10318
          case 2: // GATEWAY_PAYMENT_ID
10319
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10320
              this.gatewayPaymentId = iprot.readString();
10321
            } else { 
10322
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10323
            }
10324
            break;
10325
          case 3: // SESSION_ID
10326
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10327
              this.sessionId = iprot.readString();
10328
            } else { 
10329
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10330
            }
10331
            break;
10332
          case 4: // GATEWAY_TXN_STATUS
10333
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10334
              this.gatewayTxnStatus = iprot.readString();
10335
            } else { 
10336
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10337
            }
10338
            break;
10339
          case 5: // DESCRIPTION
10340
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10341
              this.description = iprot.readString();
10342
            } else { 
10343
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10344
            }
10345
            break;
10346
          case 6: // GATEWAY_TXN_ID
10347
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10348
              this.gatewayTxnId = iprot.readString();
10349
            } else { 
10350
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10351
            }
10352
            break;
10353
          case 7: // AUTH_CODE
10354
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10355
              this.authCode = iprot.readString();
10356
            } else { 
10357
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10358
            }
10359
            break;
10360
          case 8: // REFERENCE_CODE
10361
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10362
              this.referenceCode = iprot.readString();
10363
            } else { 
10364
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10365
            }
10366
            break;
10367
          case 9: // ERROR_CODE
10368
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10369
              this.errorCode = iprot.readString();
10370
            } else { 
10371
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10372
            }
10373
            break;
10374
          case 10: // STATUS
10375
            if (field.type == org.apache.thrift.protocol.TType.I32) {
10376
              this.status = PaymentStatus.findByValue(iprot.readI32());
10377
            } else { 
10378
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10379
            }
10380
            break;
10381
          case 11: // GATEWAY_TXN_DATE
10382
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10383
              this.gatewayTxnDate = iprot.readString();
10384
            } else { 
10385
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10386
            }
10387
            break;
10388
          case 12: // ATTRIBUTES
10389
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
10390
              {
4600 varun.gupt 10391
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
10392
                this.attributes = new ArrayList<Attribute>(_list32.size);
10393
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
695 rajveer 10394
                {
4600 varun.gupt 10395
                  Attribute _elem34; // required
10396
                  _elem34 = new Attribute();
10397
                  _elem34.read(iprot);
10398
                  this.attributes.add(_elem34);
695 rajveer 10399
                }
3430 rajveer 10400
                iprot.readListEnd();
695 rajveer 10401
              }
3430 rajveer 10402
            } else { 
10403
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10404
            }
10405
            break;
10406
          default:
10407
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 10408
        }
3430 rajveer 10409
        iprot.readFieldEnd();
420 ashish 10410
      }
10411
      iprot.readStructEnd();
10412
      validate();
10413
    }
10414
 
3430 rajveer 10415
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 10416
      validate();
10417
 
10418
      oprot.writeStructBegin(STRUCT_DESC);
10419
      oprot.writeFieldBegin(ID_FIELD_DESC);
10420
      oprot.writeI64(this.id);
10421
      oprot.writeFieldEnd();
695 rajveer 10422
      if (this.gatewayPaymentId != null) {
10423
        oprot.writeFieldBegin(GATEWAY_PAYMENT_ID_FIELD_DESC);
10424
        oprot.writeString(this.gatewayPaymentId);
420 ashish 10425
        oprot.writeFieldEnd();
10426
      }
695 rajveer 10427
      if (this.sessionId != null) {
10428
        oprot.writeFieldBegin(SESSION_ID_FIELD_DESC);
10429
        oprot.writeString(this.sessionId);
420 ashish 10430
        oprot.writeFieldEnd();
10431
      }
695 rajveer 10432
      if (this.gatewayTxnStatus != null) {
10433
        oprot.writeFieldBegin(GATEWAY_TXN_STATUS_FIELD_DESC);
10434
        oprot.writeString(this.gatewayTxnStatus);
420 ashish 10435
        oprot.writeFieldEnd();
10436
      }
695 rajveer 10437
      if (this.description != null) {
10438
        oprot.writeFieldBegin(DESCRIPTION_FIELD_DESC);
10439
        oprot.writeString(this.description);
420 ashish 10440
        oprot.writeFieldEnd();
10441
      }
695 rajveer 10442
      if (this.gatewayTxnId != null) {
10443
        oprot.writeFieldBegin(GATEWAY_TXN_ID_FIELD_DESC);
10444
        oprot.writeString(this.gatewayTxnId);
420 ashish 10445
        oprot.writeFieldEnd();
10446
      }
695 rajveer 10447
      if (this.authCode != null) {
420 ashish 10448
        oprot.writeFieldBegin(AUTH_CODE_FIELD_DESC);
695 rajveer 10449
        oprot.writeString(this.authCode);
420 ashish 10450
        oprot.writeFieldEnd();
10451
      }
695 rajveer 10452
      if (this.referenceCode != null) {
10453
        oprot.writeFieldBegin(REFERENCE_CODE_FIELD_DESC);
10454
        oprot.writeString(this.referenceCode);
420 ashish 10455
        oprot.writeFieldEnd();
10456
      }
695 rajveer 10457
      if (this.errorCode != null) {
10458
        oprot.writeFieldBegin(ERROR_CODE_FIELD_DESC);
10459
        oprot.writeString(this.errorCode);
10460
        oprot.writeFieldEnd();
10461
      }
10462
      if (this.status != null) {
10463
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
10464
        oprot.writeI32(this.status.getValue());
10465
        oprot.writeFieldEnd();
10466
      }
1119 rajveer 10467
      if (this.gatewayTxnDate != null) {
10468
        oprot.writeFieldBegin(GATEWAY_TXN_DATE_FIELD_DESC);
10469
        oprot.writeString(this.gatewayTxnDate);
10470
        oprot.writeFieldEnd();
10471
      }
695 rajveer 10472
      if (this.attributes != null) {
10473
        oprot.writeFieldBegin(ATTRIBUTES_FIELD_DESC);
10474
        {
3430 rajveer 10475
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.attributes.size()));
4600 varun.gupt 10476
          for (Attribute _iter35 : this.attributes)
695 rajveer 10477
          {
4600 varun.gupt 10478
            _iter35.write(oprot);
695 rajveer 10479
          }
10480
          oprot.writeListEnd();
10481
        }
10482
        oprot.writeFieldEnd();
10483
      }
420 ashish 10484
      oprot.writeFieldStop();
10485
      oprot.writeStructEnd();
10486
    }
10487
 
10488
    @Override
10489
    public String toString() {
695 rajveer 10490
      StringBuilder sb = new StringBuilder("updatePaymentDetails_args(");
420 ashish 10491
      boolean first = true;
10492
 
10493
      sb.append("id:");
10494
      sb.append(this.id);
10495
      first = false;
10496
      if (!first) sb.append(", ");
695 rajveer 10497
      sb.append("gatewayPaymentId:");
10498
      if (this.gatewayPaymentId == null) {
420 ashish 10499
        sb.append("null");
10500
      } else {
695 rajveer 10501
        sb.append(this.gatewayPaymentId);
420 ashish 10502
      }
10503
      first = false;
10504
      if (!first) sb.append(", ");
695 rajveer 10505
      sb.append("sessionId:");
10506
      if (this.sessionId == null) {
420 ashish 10507
        sb.append("null");
10508
      } else {
695 rajveer 10509
        sb.append(this.sessionId);
420 ashish 10510
      }
10511
      first = false;
10512
      if (!first) sb.append(", ");
695 rajveer 10513
      sb.append("gatewayTxnStatus:");
10514
      if (this.gatewayTxnStatus == null) {
420 ashish 10515
        sb.append("null");
10516
      } else {
695 rajveer 10517
        sb.append(this.gatewayTxnStatus);
420 ashish 10518
      }
10519
      first = false;
10520
      if (!first) sb.append(", ");
695 rajveer 10521
      sb.append("description:");
10522
      if (this.description == null) {
420 ashish 10523
        sb.append("null");
10524
      } else {
695 rajveer 10525
        sb.append(this.description);
420 ashish 10526
      }
10527
      first = false;
10528
      if (!first) sb.append(", ");
695 rajveer 10529
      sb.append("gatewayTxnId:");
10530
      if (this.gatewayTxnId == null) {
420 ashish 10531
        sb.append("null");
10532
      } else {
695 rajveer 10533
        sb.append(this.gatewayTxnId);
420 ashish 10534
      }
10535
      first = false;
10536
      if (!first) sb.append(", ");
695 rajveer 10537
      sb.append("authCode:");
10538
      if (this.authCode == null) {
420 ashish 10539
        sb.append("null");
10540
      } else {
695 rajveer 10541
        sb.append(this.authCode);
420 ashish 10542
      }
10543
      first = false;
10544
      if (!first) sb.append(", ");
695 rajveer 10545
      sb.append("referenceCode:");
10546
      if (this.referenceCode == null) {
420 ashish 10547
        sb.append("null");
10548
      } else {
695 rajveer 10549
        sb.append(this.referenceCode);
420 ashish 10550
      }
10551
      first = false;
695 rajveer 10552
      if (!first) sb.append(", ");
10553
      sb.append("errorCode:");
10554
      if (this.errorCode == null) {
10555
        sb.append("null");
10556
      } else {
10557
        sb.append(this.errorCode);
10558
      }
10559
      first = false;
10560
      if (!first) sb.append(", ");
10561
      sb.append("status:");
10562
      if (this.status == null) {
10563
        sb.append("null");
10564
      } else {
10565
        sb.append(this.status);
10566
      }
10567
      first = false;
10568
      if (!first) sb.append(", ");
1119 rajveer 10569
      sb.append("gatewayTxnDate:");
10570
      if (this.gatewayTxnDate == null) {
10571
        sb.append("null");
10572
      } else {
10573
        sb.append(this.gatewayTxnDate);
10574
      }
10575
      first = false;
10576
      if (!first) sb.append(", ");
695 rajveer 10577
      sb.append("attributes:");
10578
      if (this.attributes == null) {
10579
        sb.append("null");
10580
      } else {
10581
        sb.append(this.attributes);
10582
      }
10583
      first = false;
420 ashish 10584
      sb.append(")");
10585
      return sb.toString();
10586
    }
10587
 
3430 rajveer 10588
    public void validate() throws org.apache.thrift.TException {
420 ashish 10589
      // check for required fields
10590
    }
10591
 
3430 rajveer 10592
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10593
      try {
10594
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10595
      } catch (org.apache.thrift.TException te) {
10596
        throw new java.io.IOException(te);
10597
      }
10598
    }
10599
 
10600
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10601
      try {
10602
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
10603
        __isset_bit_vector = new BitSet(1);
10604
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10605
      } catch (org.apache.thrift.TException te) {
10606
        throw new java.io.IOException(te);
10607
      }
10608
    }
10609
 
420 ashish 10610
  }
10611
 
3430 rajveer 10612
  public static class updatePaymentDetails_result implements org.apache.thrift.TBase<updatePaymentDetails_result, updatePaymentDetails_result._Fields>, java.io.Serializable, Cloneable   {
10613
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updatePaymentDetails_result");
420 ashish 10614
 
3430 rajveer 10615
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
10616
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
420 ashish 10617
 
3430 rajveer 10618
    private boolean success; // required
10619
    private PaymentException pe; // required
420 ashish 10620
 
10621
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 10622
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 10623
      SUCCESS((short)0, "success"),
420 ashish 10624
      PE((short)1, "pe");
10625
 
10626
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10627
 
10628
      static {
10629
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10630
          byName.put(field.getFieldName(), field);
10631
        }
10632
      }
10633
 
10634
      /**
10635
       * Find the _Fields constant that matches fieldId, or null if its not found.
10636
       */
10637
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 10638
        switch(fieldId) {
10639
          case 0: // SUCCESS
10640
            return SUCCESS;
10641
          case 1: // PE
10642
            return PE;
10643
          default:
10644
            return null;
10645
        }
420 ashish 10646
      }
10647
 
10648
      /**
10649
       * Find the _Fields constant that matches fieldId, throwing an exception
10650
       * if it is not found.
10651
       */
10652
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10653
        _Fields fields = findByThriftId(fieldId);
10654
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10655
        return fields;
10656
      }
10657
 
10658
      /**
10659
       * Find the _Fields constant that matches name, or null if its not found.
10660
       */
10661
      public static _Fields findByName(String name) {
10662
        return byName.get(name);
10663
      }
10664
 
10665
      private final short _thriftId;
10666
      private final String _fieldName;
10667
 
10668
      _Fields(short thriftId, String fieldName) {
10669
        _thriftId = thriftId;
10670
        _fieldName = fieldName;
10671
      }
10672
 
10673
      public short getThriftFieldId() {
10674
        return _thriftId;
10675
      }
10676
 
10677
      public String getFieldName() {
10678
        return _fieldName;
10679
      }
10680
    }
10681
 
10682
    // isset id assignments
695 rajveer 10683
    private static final int __SUCCESS_ISSET_ID = 0;
10684
    private BitSet __isset_bit_vector = new BitSet(1);
420 ashish 10685
 
3430 rajveer 10686
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 10687
    static {
3430 rajveer 10688
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10689
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10690
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
10691
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10692
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10693
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10694
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updatePaymentDetails_result.class, metaDataMap);
420 ashish 10695
    }
10696
 
695 rajveer 10697
    public updatePaymentDetails_result() {
420 ashish 10698
    }
10699
 
695 rajveer 10700
    public updatePaymentDetails_result(
10701
      boolean success,
420 ashish 10702
      PaymentException pe)
10703
    {
10704
      this();
695 rajveer 10705
      this.success = success;
10706
      setSuccessIsSet(true);
420 ashish 10707
      this.pe = pe;
10708
    }
10709
 
10710
    /**
10711
     * Performs a deep copy on <i>other</i>.
10712
     */
695 rajveer 10713
    public updatePaymentDetails_result(updatePaymentDetails_result other) {
10714
      __isset_bit_vector.clear();
10715
      __isset_bit_vector.or(other.__isset_bit_vector);
10716
      this.success = other.success;
420 ashish 10717
      if (other.isSetPe()) {
10718
        this.pe = new PaymentException(other.pe);
10719
      }
10720
    }
10721
 
695 rajveer 10722
    public updatePaymentDetails_result deepCopy() {
10723
      return new updatePaymentDetails_result(this);
420 ashish 10724
    }
10725
 
3430 rajveer 10726
    @Override
10727
    public void clear() {
10728
      setSuccessIsSet(false);
10729
      this.success = false;
10730
      this.pe = null;
420 ashish 10731
    }
10732
 
695 rajveer 10733
    public boolean isSuccess() {
10734
      return this.success;
10735
    }
10736
 
3430 rajveer 10737
    public void setSuccess(boolean success) {
695 rajveer 10738
      this.success = success;
10739
      setSuccessIsSet(true);
10740
    }
10741
 
10742
    public void unsetSuccess() {
10743
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
10744
    }
10745
 
3430 rajveer 10746
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
695 rajveer 10747
    public boolean isSetSuccess() {
10748
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
10749
    }
10750
 
10751
    public void setSuccessIsSet(boolean value) {
10752
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
10753
    }
10754
 
420 ashish 10755
    public PaymentException getPe() {
10756
      return this.pe;
10757
    }
10758
 
3430 rajveer 10759
    public void setPe(PaymentException pe) {
420 ashish 10760
      this.pe = pe;
10761
    }
10762
 
10763
    public void unsetPe() {
10764
      this.pe = null;
10765
    }
10766
 
3430 rajveer 10767
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 10768
    public boolean isSetPe() {
10769
      return this.pe != null;
10770
    }
10771
 
10772
    public void setPeIsSet(boolean value) {
10773
      if (!value) {
10774
        this.pe = null;
10775
      }
10776
    }
10777
 
10778
    public void setFieldValue(_Fields field, Object value) {
10779
      switch (field) {
695 rajveer 10780
      case SUCCESS:
10781
        if (value == null) {
10782
          unsetSuccess();
10783
        } else {
10784
          setSuccess((Boolean)value);
10785
        }
10786
        break;
10787
 
420 ashish 10788
      case PE:
10789
        if (value == null) {
10790
          unsetPe();
10791
        } else {
10792
          setPe((PaymentException)value);
10793
        }
10794
        break;
10795
 
10796
      }
10797
    }
10798
 
10799
    public Object getFieldValue(_Fields field) {
10800
      switch (field) {
695 rajveer 10801
      case SUCCESS:
3430 rajveer 10802
        return Boolean.valueOf(isSuccess());
695 rajveer 10803
 
420 ashish 10804
      case PE:
10805
        return getPe();
10806
 
10807
      }
10808
      throw new IllegalStateException();
10809
    }
10810
 
3430 rajveer 10811
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10812
    public boolean isSet(_Fields field) {
10813
      if (field == null) {
10814
        throw new IllegalArgumentException();
10815
      }
420 ashish 10816
 
10817
      switch (field) {
695 rajveer 10818
      case SUCCESS:
10819
        return isSetSuccess();
420 ashish 10820
      case PE:
10821
        return isSetPe();
10822
      }
10823
      throw new IllegalStateException();
10824
    }
10825
 
10826
    @Override
10827
    public boolean equals(Object that) {
10828
      if (that == null)
10829
        return false;
695 rajveer 10830
      if (that instanceof updatePaymentDetails_result)
10831
        return this.equals((updatePaymentDetails_result)that);
420 ashish 10832
      return false;
10833
    }
10834
 
695 rajveer 10835
    public boolean equals(updatePaymentDetails_result that) {
420 ashish 10836
      if (that == null)
10837
        return false;
10838
 
695 rajveer 10839
      boolean this_present_success = true;
10840
      boolean that_present_success = true;
10841
      if (this_present_success || that_present_success) {
10842
        if (!(this_present_success && that_present_success))
10843
          return false;
10844
        if (this.success != that.success)
10845
          return false;
10846
      }
10847
 
420 ashish 10848
      boolean this_present_pe = true && this.isSetPe();
10849
      boolean that_present_pe = true && that.isSetPe();
10850
      if (this_present_pe || that_present_pe) {
10851
        if (!(this_present_pe && that_present_pe))
10852
          return false;
10853
        if (!this.pe.equals(that.pe))
10854
          return false;
10855
      }
10856
 
10857
      return true;
10858
    }
10859
 
10860
    @Override
10861
    public int hashCode() {
10862
      return 0;
10863
    }
10864
 
695 rajveer 10865
    public int compareTo(updatePaymentDetails_result other) {
420 ashish 10866
      if (!getClass().equals(other.getClass())) {
10867
        return getClass().getName().compareTo(other.getClass().getName());
10868
      }
10869
 
10870
      int lastComparison = 0;
695 rajveer 10871
      updatePaymentDetails_result typedOther = (updatePaymentDetails_result)other;
420 ashish 10872
 
3430 rajveer 10873
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 10874
      if (lastComparison != 0) {
10875
        return lastComparison;
10876
      }
3430 rajveer 10877
      if (isSetSuccess()) {
10878
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10879
        if (lastComparison != 0) {
10880
          return lastComparison;
10881
        }
695 rajveer 10882
      }
3430 rajveer 10883
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 10884
      if (lastComparison != 0) {
10885
        return lastComparison;
10886
      }
3430 rajveer 10887
      if (isSetPe()) {
10888
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
10889
        if (lastComparison != 0) {
10890
          return lastComparison;
10891
        }
420 ashish 10892
      }
10893
      return 0;
10894
    }
10895
 
3430 rajveer 10896
    public _Fields fieldForId(int fieldId) {
10897
      return _Fields.findByThriftId(fieldId);
10898
    }
10899
 
10900
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10901
      org.apache.thrift.protocol.TField field;
420 ashish 10902
      iprot.readStructBegin();
10903
      while (true)
10904
      {
10905
        field = iprot.readFieldBegin();
3430 rajveer 10906
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 10907
          break;
10908
        }
3430 rajveer 10909
        switch (field.id) {
10910
          case 0: // SUCCESS
10911
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
10912
              this.success = iprot.readBool();
10913
              setSuccessIsSet(true);
10914
            } else { 
10915
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10916
            }
10917
            break;
10918
          case 1: // PE
10919
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10920
              this.pe = new PaymentException();
10921
              this.pe.read(iprot);
10922
            } else { 
10923
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10924
            }
10925
            break;
10926
          default:
10927
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 10928
        }
3430 rajveer 10929
        iprot.readFieldEnd();
420 ashish 10930
      }
10931
      iprot.readStructEnd();
10932
      validate();
10933
    }
10934
 
3430 rajveer 10935
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 10936
      oprot.writeStructBegin(STRUCT_DESC);
10937
 
695 rajveer 10938
      if (this.isSetSuccess()) {
10939
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10940
        oprot.writeBool(this.success);
10941
        oprot.writeFieldEnd();
10942
      } else if (this.isSetPe()) {
420 ashish 10943
        oprot.writeFieldBegin(PE_FIELD_DESC);
10944
        this.pe.write(oprot);
10945
        oprot.writeFieldEnd();
10946
      }
10947
      oprot.writeFieldStop();
10948
      oprot.writeStructEnd();
10949
    }
10950
 
10951
    @Override
10952
    public String toString() {
695 rajveer 10953
      StringBuilder sb = new StringBuilder("updatePaymentDetails_result(");
420 ashish 10954
      boolean first = true;
10955
 
695 rajveer 10956
      sb.append("success:");
10957
      sb.append(this.success);
10958
      first = false;
10959
      if (!first) sb.append(", ");
420 ashish 10960
      sb.append("pe:");
10961
      if (this.pe == null) {
10962
        sb.append("null");
10963
      } else {
10964
        sb.append(this.pe);
10965
      }
10966
      first = false;
10967
      sb.append(")");
10968
      return sb.toString();
10969
    }
10970
 
3430 rajveer 10971
    public void validate() throws org.apache.thrift.TException {
420 ashish 10972
      // check for required fields
10973
    }
10974
 
3430 rajveer 10975
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10976
      try {
10977
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10978
      } catch (org.apache.thrift.TException te) {
10979
        throw new java.io.IOException(te);
10980
      }
10981
    }
10982
 
10983
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10984
      try {
10985
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10986
      } catch (org.apache.thrift.TException te) {
10987
        throw new java.io.IOException(te);
10988
      }
10989
    }
10990
 
420 ashish 10991
  }
10992
 
3430 rajveer 10993
  public static class getSuccessfulPaymentsAmountRange_args implements org.apache.thrift.TBase<getSuccessfulPaymentsAmountRange_args, getSuccessfulPaymentsAmountRange_args._Fields>, java.io.Serializable, Cloneable   {
10994
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentsAmountRange_args");
1629 ankur.sing 10995
 
10996
 
10997
 
10998
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 10999
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1629 ankur.sing 11000
;
11001
 
11002
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11003
 
11004
      static {
11005
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11006
          byName.put(field.getFieldName(), field);
11007
        }
11008
      }
11009
 
11010
      /**
11011
       * Find the _Fields constant that matches fieldId, or null if its not found.
11012
       */
11013
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11014
        switch(fieldId) {
11015
          default:
11016
            return null;
11017
        }
1629 ankur.sing 11018
      }
11019
 
11020
      /**
11021
       * Find the _Fields constant that matches fieldId, throwing an exception
11022
       * if it is not found.
11023
       */
11024
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11025
        _Fields fields = findByThriftId(fieldId);
11026
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11027
        return fields;
11028
      }
11029
 
11030
      /**
11031
       * Find the _Fields constant that matches name, or null if its not found.
11032
       */
11033
      public static _Fields findByName(String name) {
11034
        return byName.get(name);
11035
      }
11036
 
11037
      private final short _thriftId;
11038
      private final String _fieldName;
11039
 
11040
      _Fields(short thriftId, String fieldName) {
11041
        _thriftId = thriftId;
11042
        _fieldName = fieldName;
11043
      }
11044
 
11045
      public short getThriftFieldId() {
11046
        return _thriftId;
11047
      }
11048
 
11049
      public String getFieldName() {
11050
        return _fieldName;
11051
      }
11052
    }
3430 rajveer 11053
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1629 ankur.sing 11054
    static {
3430 rajveer 11055
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11056
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11057
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentsAmountRange_args.class, metaDataMap);
1629 ankur.sing 11058
    }
11059
 
1731 ankur.sing 11060
    public getSuccessfulPaymentsAmountRange_args() {
1629 ankur.sing 11061
    }
11062
 
11063
    /**
11064
     * Performs a deep copy on <i>other</i>.
11065
     */
1731 ankur.sing 11066
    public getSuccessfulPaymentsAmountRange_args(getSuccessfulPaymentsAmountRange_args other) {
1629 ankur.sing 11067
    }
11068
 
1731 ankur.sing 11069
    public getSuccessfulPaymentsAmountRange_args deepCopy() {
11070
      return new getSuccessfulPaymentsAmountRange_args(this);
1629 ankur.sing 11071
    }
11072
 
3430 rajveer 11073
    @Override
11074
    public void clear() {
1629 ankur.sing 11075
    }
11076
 
11077
    public void setFieldValue(_Fields field, Object value) {
11078
      switch (field) {
11079
      }
11080
    }
11081
 
11082
    public Object getFieldValue(_Fields field) {
11083
      switch (field) {
11084
      }
11085
      throw new IllegalStateException();
11086
    }
11087
 
3430 rajveer 11088
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11089
    public boolean isSet(_Fields field) {
11090
      if (field == null) {
11091
        throw new IllegalArgumentException();
11092
      }
1629 ankur.sing 11093
 
11094
      switch (field) {
11095
      }
11096
      throw new IllegalStateException();
11097
    }
11098
 
11099
    @Override
11100
    public boolean equals(Object that) {
11101
      if (that == null)
11102
        return false;
1731 ankur.sing 11103
      if (that instanceof getSuccessfulPaymentsAmountRange_args)
11104
        return this.equals((getSuccessfulPaymentsAmountRange_args)that);
1629 ankur.sing 11105
      return false;
11106
    }
11107
 
1731 ankur.sing 11108
    public boolean equals(getSuccessfulPaymentsAmountRange_args that) {
1629 ankur.sing 11109
      if (that == null)
11110
        return false;
11111
 
11112
      return true;
11113
    }
11114
 
11115
    @Override
11116
    public int hashCode() {
11117
      return 0;
11118
    }
11119
 
1731 ankur.sing 11120
    public int compareTo(getSuccessfulPaymentsAmountRange_args other) {
1629 ankur.sing 11121
      if (!getClass().equals(other.getClass())) {
11122
        return getClass().getName().compareTo(other.getClass().getName());
11123
      }
11124
 
11125
      int lastComparison = 0;
1731 ankur.sing 11126
      getSuccessfulPaymentsAmountRange_args typedOther = (getSuccessfulPaymentsAmountRange_args)other;
1629 ankur.sing 11127
 
11128
      return 0;
11129
    }
11130
 
3430 rajveer 11131
    public _Fields fieldForId(int fieldId) {
11132
      return _Fields.findByThriftId(fieldId);
11133
    }
11134
 
11135
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11136
      org.apache.thrift.protocol.TField field;
1629 ankur.sing 11137
      iprot.readStructBegin();
11138
      while (true)
11139
      {
11140
        field = iprot.readFieldBegin();
3430 rajveer 11141
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1629 ankur.sing 11142
          break;
11143
        }
3430 rajveer 11144
        switch (field.id) {
11145
          default:
11146
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1629 ankur.sing 11147
        }
3430 rajveer 11148
        iprot.readFieldEnd();
1629 ankur.sing 11149
      }
11150
      iprot.readStructEnd();
11151
      validate();
11152
    }
11153
 
3430 rajveer 11154
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1629 ankur.sing 11155
      validate();
11156
 
11157
      oprot.writeStructBegin(STRUCT_DESC);
11158
      oprot.writeFieldStop();
11159
      oprot.writeStructEnd();
11160
    }
11161
 
11162
    @Override
11163
    public String toString() {
1731 ankur.sing 11164
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentsAmountRange_args(");
1629 ankur.sing 11165
      boolean first = true;
11166
 
11167
      sb.append(")");
11168
      return sb.toString();
11169
    }
11170
 
3430 rajveer 11171
    public void validate() throws org.apache.thrift.TException {
1629 ankur.sing 11172
      // check for required fields
11173
    }
11174
 
3430 rajveer 11175
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11176
      try {
11177
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11178
      } catch (org.apache.thrift.TException te) {
11179
        throw new java.io.IOException(te);
11180
      }
11181
    }
11182
 
11183
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11184
      try {
11185
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11186
      } catch (org.apache.thrift.TException te) {
11187
        throw new java.io.IOException(te);
11188
      }
11189
    }
11190
 
1629 ankur.sing 11191
  }
11192
 
3430 rajveer 11193
  public static class getSuccessfulPaymentsAmountRange_result implements org.apache.thrift.TBase<getSuccessfulPaymentsAmountRange_result, getSuccessfulPaymentsAmountRange_result._Fields>, java.io.Serializable, Cloneable   {
11194
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentsAmountRange_result");
1629 ankur.sing 11195
 
3430 rajveer 11196
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
1629 ankur.sing 11197
 
3430 rajveer 11198
    private List<Double> success; // required
1629 ankur.sing 11199
 
11200
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11201
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1629 ankur.sing 11202
      SUCCESS((short)0, "success");
11203
 
11204
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11205
 
11206
      static {
11207
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11208
          byName.put(field.getFieldName(), field);
11209
        }
11210
      }
11211
 
11212
      /**
11213
       * Find the _Fields constant that matches fieldId, or null if its not found.
11214
       */
11215
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11216
        switch(fieldId) {
11217
          case 0: // SUCCESS
11218
            return SUCCESS;
11219
          default:
11220
            return null;
11221
        }
1629 ankur.sing 11222
      }
11223
 
11224
      /**
11225
       * Find the _Fields constant that matches fieldId, throwing an exception
11226
       * if it is not found.
11227
       */
11228
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11229
        _Fields fields = findByThriftId(fieldId);
11230
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11231
        return fields;
11232
      }
11233
 
11234
      /**
11235
       * Find the _Fields constant that matches name, or null if its not found.
11236
       */
11237
      public static _Fields findByName(String name) {
11238
        return byName.get(name);
11239
      }
11240
 
11241
      private final short _thriftId;
11242
      private final String _fieldName;
11243
 
11244
      _Fields(short thriftId, String fieldName) {
11245
        _thriftId = thriftId;
11246
        _fieldName = fieldName;
11247
      }
11248
 
11249
      public short getThriftFieldId() {
11250
        return _thriftId;
11251
      }
11252
 
11253
      public String getFieldName() {
11254
        return _fieldName;
11255
      }
11256
    }
11257
 
11258
    // isset id assignments
11259
 
3430 rajveer 11260
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1629 ankur.sing 11261
    static {
3430 rajveer 11262
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11263
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11264
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
11265
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE))));
11266
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11267
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentsAmountRange_result.class, metaDataMap);
1629 ankur.sing 11268
    }
11269
 
1731 ankur.sing 11270
    public getSuccessfulPaymentsAmountRange_result() {
1629 ankur.sing 11271
    }
11272
 
1731 ankur.sing 11273
    public getSuccessfulPaymentsAmountRange_result(
11274
      List<Double> success)
1629 ankur.sing 11275
    {
11276
      this();
11277
      this.success = success;
11278
    }
11279
 
11280
    /**
11281
     * Performs a deep copy on <i>other</i>.
11282
     */
1731 ankur.sing 11283
    public getSuccessfulPaymentsAmountRange_result(getSuccessfulPaymentsAmountRange_result other) {
11284
      if (other.isSetSuccess()) {
11285
        List<Double> __this__success = new ArrayList<Double>();
11286
        for (Double other_element : other.success) {
11287
          __this__success.add(other_element);
1629 ankur.sing 11288
        }
1731 ankur.sing 11289
        this.success = __this__success;
1629 ankur.sing 11290
      }
11291
    }
11292
 
1731 ankur.sing 11293
    public getSuccessfulPaymentsAmountRange_result deepCopy() {
11294
      return new getSuccessfulPaymentsAmountRange_result(this);
1629 ankur.sing 11295
    }
11296
 
3430 rajveer 11297
    @Override
11298
    public void clear() {
11299
      this.success = null;
1629 ankur.sing 11300
    }
11301
 
1731 ankur.sing 11302
    public int getSuccessSize() {
11303
      return (this.success == null) ? 0 : this.success.size();
1629 ankur.sing 11304
    }
11305
 
1731 ankur.sing 11306
    public java.util.Iterator<Double> getSuccessIterator() {
11307
      return (this.success == null) ? null : this.success.iterator();
1629 ankur.sing 11308
    }
11309
 
1731 ankur.sing 11310
    public void addToSuccess(double elem) {
11311
      if (this.success == null) {
11312
        this.success = new ArrayList<Double>();
1629 ankur.sing 11313
      }
1731 ankur.sing 11314
      this.success.add(elem);
1629 ankur.sing 11315
    }
11316
 
1731 ankur.sing 11317
    public List<Double> getSuccess() {
1629 ankur.sing 11318
      return this.success;
11319
    }
11320
 
3430 rajveer 11321
    public void setSuccess(List<Double> success) {
1629 ankur.sing 11322
      this.success = success;
11323
    }
11324
 
11325
    public void unsetSuccess() {
1731 ankur.sing 11326
      this.success = null;
1629 ankur.sing 11327
    }
11328
 
3430 rajveer 11329
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
1629 ankur.sing 11330
    public boolean isSetSuccess() {
1731 ankur.sing 11331
      return this.success != null;
1629 ankur.sing 11332
    }
11333
 
11334
    public void setSuccessIsSet(boolean value) {
1731 ankur.sing 11335
      if (!value) {
11336
        this.success = null;
11337
      }
1629 ankur.sing 11338
    }
11339
 
11340
    public void setFieldValue(_Fields field, Object value) {
11341
      switch (field) {
11342
      case SUCCESS:
11343
        if (value == null) {
11344
          unsetSuccess();
11345
        } else {
1731 ankur.sing 11346
          setSuccess((List<Double>)value);
1629 ankur.sing 11347
        }
11348
        break;
11349
 
11350
      }
11351
    }
11352
 
11353
    public Object getFieldValue(_Fields field) {
11354
      switch (field) {
11355
      case SUCCESS:
1731 ankur.sing 11356
        return getSuccess();
1629 ankur.sing 11357
 
11358
      }
11359
      throw new IllegalStateException();
11360
    }
11361
 
3430 rajveer 11362
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11363
    public boolean isSet(_Fields field) {
11364
      if (field == null) {
11365
        throw new IllegalArgumentException();
11366
      }
1629 ankur.sing 11367
 
11368
      switch (field) {
11369
      case SUCCESS:
11370
        return isSetSuccess();
11371
      }
11372
      throw new IllegalStateException();
11373
    }
11374
 
11375
    @Override
11376
    public boolean equals(Object that) {
11377
      if (that == null)
11378
        return false;
1731 ankur.sing 11379
      if (that instanceof getSuccessfulPaymentsAmountRange_result)
11380
        return this.equals((getSuccessfulPaymentsAmountRange_result)that);
1629 ankur.sing 11381
      return false;
11382
    }
11383
 
1731 ankur.sing 11384
    public boolean equals(getSuccessfulPaymentsAmountRange_result that) {
1629 ankur.sing 11385
      if (that == null)
11386
        return false;
11387
 
1731 ankur.sing 11388
      boolean this_present_success = true && this.isSetSuccess();
11389
      boolean that_present_success = true && that.isSetSuccess();
1629 ankur.sing 11390
      if (this_present_success || that_present_success) {
11391
        if (!(this_present_success && that_present_success))
11392
          return false;
1731 ankur.sing 11393
        if (!this.success.equals(that.success))
1629 ankur.sing 11394
          return false;
11395
      }
11396
 
11397
      return true;
11398
    }
11399
 
11400
    @Override
11401
    public int hashCode() {
11402
      return 0;
11403
    }
11404
 
1731 ankur.sing 11405
    public int compareTo(getSuccessfulPaymentsAmountRange_result other) {
1629 ankur.sing 11406
      if (!getClass().equals(other.getClass())) {
11407
        return getClass().getName().compareTo(other.getClass().getName());
11408
      }
11409
 
11410
      int lastComparison = 0;
1731 ankur.sing 11411
      getSuccessfulPaymentsAmountRange_result typedOther = (getSuccessfulPaymentsAmountRange_result)other;
1629 ankur.sing 11412
 
3430 rajveer 11413
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
1629 ankur.sing 11414
      if (lastComparison != 0) {
11415
        return lastComparison;
11416
      }
3430 rajveer 11417
      if (isSetSuccess()) {
11418
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11419
        if (lastComparison != 0) {
11420
          return lastComparison;
11421
        }
1629 ankur.sing 11422
      }
11423
      return 0;
11424
    }
11425
 
3430 rajveer 11426
    public _Fields fieldForId(int fieldId) {
11427
      return _Fields.findByThriftId(fieldId);
11428
    }
11429
 
11430
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11431
      org.apache.thrift.protocol.TField field;
1629 ankur.sing 11432
      iprot.readStructBegin();
11433
      while (true)
11434
      {
11435
        field = iprot.readFieldBegin();
3430 rajveer 11436
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1629 ankur.sing 11437
          break;
11438
        }
3430 rajveer 11439
        switch (field.id) {
11440
          case 0: // SUCCESS
11441
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11442
              {
4600 varun.gupt 11443
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
11444
                this.success = new ArrayList<Double>(_list36.size);
11445
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
1731 ankur.sing 11446
                {
4600 varun.gupt 11447
                  double _elem38; // required
11448
                  _elem38 = iprot.readDouble();
11449
                  this.success.add(_elem38);
1731 ankur.sing 11450
                }
3430 rajveer 11451
                iprot.readListEnd();
1629 ankur.sing 11452
              }
3430 rajveer 11453
            } else { 
11454
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11455
            }
11456
            break;
11457
          default:
11458
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1629 ankur.sing 11459
        }
3430 rajveer 11460
        iprot.readFieldEnd();
1629 ankur.sing 11461
      }
11462
      iprot.readStructEnd();
11463
      validate();
11464
    }
11465
 
3430 rajveer 11466
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1629 ankur.sing 11467
      oprot.writeStructBegin(STRUCT_DESC);
11468
 
11469
      if (this.isSetSuccess()) {
11470
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
1731 ankur.sing 11471
        {
3430 rajveer 11472
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.DOUBLE, this.success.size()));
4600 varun.gupt 11473
          for (double _iter39 : this.success)
1731 ankur.sing 11474
          {
4600 varun.gupt 11475
            oprot.writeDouble(_iter39);
1731 ankur.sing 11476
          }
11477
          oprot.writeListEnd();
11478
        }
1629 ankur.sing 11479
        oprot.writeFieldEnd();
11480
      }
11481
      oprot.writeFieldStop();
11482
      oprot.writeStructEnd();
11483
    }
11484
 
11485
    @Override
11486
    public String toString() {
1731 ankur.sing 11487
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentsAmountRange_result(");
1629 ankur.sing 11488
      boolean first = true;
11489
 
11490
      sb.append("success:");
1731 ankur.sing 11491
      if (this.success == null) {
11492
        sb.append("null");
11493
      } else {
11494
        sb.append(this.success);
11495
      }
1629 ankur.sing 11496
      first = false;
11497
      sb.append(")");
11498
      return sb.toString();
11499
    }
11500
 
3430 rajveer 11501
    public void validate() throws org.apache.thrift.TException {
1629 ankur.sing 11502
      // check for required fields
11503
    }
11504
 
3430 rajveer 11505
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11506
      try {
11507
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11508
      } catch (org.apache.thrift.TException te) {
11509
        throw new java.io.IOException(te);
11510
      }
11511
    }
11512
 
11513
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11514
      try {
11515
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11516
      } catch (org.apache.thrift.TException te) {
11517
        throw new java.io.IOException(te);
11518
      }
11519
    }
11520
 
1629 ankur.sing 11521
  }
11522
 
3430 rajveer 11523
  public static class initializeHdfcPayment_args implements org.apache.thrift.TBase<initializeHdfcPayment_args, initializeHdfcPayment_args._Fields>, java.io.Serializable, Cloneable   {
11524
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcPayment_args");
2462 chandransh 11525
 
3430 rajveer 11526
    private static final org.apache.thrift.protocol.TField MERCHANT_PAYMENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantPaymentId", org.apache.thrift.protocol.TType.I64, (short)1);
2462 chandransh 11527
 
3430 rajveer 11528
    private long merchantPaymentId; // required
2462 chandransh 11529
 
11530
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11531
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 11532
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId");
11533
 
11534
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11535
 
11536
      static {
11537
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11538
          byName.put(field.getFieldName(), field);
11539
        }
11540
      }
11541
 
11542
      /**
11543
       * Find the _Fields constant that matches fieldId, or null if its not found.
11544
       */
11545
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11546
        switch(fieldId) {
11547
          case 1: // MERCHANT_PAYMENT_ID
11548
            return MERCHANT_PAYMENT_ID;
11549
          default:
11550
            return null;
11551
        }
2462 chandransh 11552
      }
11553
 
11554
      /**
11555
       * Find the _Fields constant that matches fieldId, throwing an exception
11556
       * if it is not found.
11557
       */
11558
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11559
        _Fields fields = findByThriftId(fieldId);
11560
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11561
        return fields;
11562
      }
11563
 
11564
      /**
11565
       * Find the _Fields constant that matches name, or null if its not found.
11566
       */
11567
      public static _Fields findByName(String name) {
11568
        return byName.get(name);
11569
      }
11570
 
11571
      private final short _thriftId;
11572
      private final String _fieldName;
11573
 
11574
      _Fields(short thriftId, String fieldName) {
11575
        _thriftId = thriftId;
11576
        _fieldName = fieldName;
11577
      }
11578
 
11579
      public short getThriftFieldId() {
11580
        return _thriftId;
11581
      }
11582
 
11583
      public String getFieldName() {
11584
        return _fieldName;
11585
      }
11586
    }
11587
 
11588
    // isset id assignments
11589
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
11590
    private BitSet __isset_bit_vector = new BitSet(1);
11591
 
3430 rajveer 11592
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 11593
    static {
3430 rajveer 11594
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11595
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11596
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11597
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11598
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcPayment_args.class, metaDataMap);
2462 chandransh 11599
    }
11600
 
3010 chandransh 11601
    public initializeHdfcPayment_args() {
2462 chandransh 11602
    }
11603
 
3010 chandransh 11604
    public initializeHdfcPayment_args(
2462 chandransh 11605
      long merchantPaymentId)
11606
    {
11607
      this();
11608
      this.merchantPaymentId = merchantPaymentId;
11609
      setMerchantPaymentIdIsSet(true);
11610
    }
11611
 
11612
    /**
11613
     * Performs a deep copy on <i>other</i>.
11614
     */
3010 chandransh 11615
    public initializeHdfcPayment_args(initializeHdfcPayment_args other) {
2462 chandransh 11616
      __isset_bit_vector.clear();
11617
      __isset_bit_vector.or(other.__isset_bit_vector);
11618
      this.merchantPaymentId = other.merchantPaymentId;
11619
    }
11620
 
3010 chandransh 11621
    public initializeHdfcPayment_args deepCopy() {
11622
      return new initializeHdfcPayment_args(this);
2462 chandransh 11623
    }
11624
 
3430 rajveer 11625
    @Override
11626
    public void clear() {
11627
      setMerchantPaymentIdIsSet(false);
11628
      this.merchantPaymentId = 0;
2462 chandransh 11629
    }
11630
 
11631
    public long getMerchantPaymentId() {
11632
      return this.merchantPaymentId;
11633
    }
11634
 
3430 rajveer 11635
    public void setMerchantPaymentId(long merchantPaymentId) {
2462 chandransh 11636
      this.merchantPaymentId = merchantPaymentId;
11637
      setMerchantPaymentIdIsSet(true);
11638
    }
11639
 
11640
    public void unsetMerchantPaymentId() {
11641
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
11642
    }
11643
 
3430 rajveer 11644
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
2462 chandransh 11645
    public boolean isSetMerchantPaymentId() {
11646
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
11647
    }
11648
 
11649
    public void setMerchantPaymentIdIsSet(boolean value) {
11650
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
11651
    }
11652
 
11653
    public void setFieldValue(_Fields field, Object value) {
11654
      switch (field) {
11655
      case MERCHANT_PAYMENT_ID:
11656
        if (value == null) {
11657
          unsetMerchantPaymentId();
11658
        } else {
11659
          setMerchantPaymentId((Long)value);
11660
        }
11661
        break;
11662
 
11663
      }
11664
    }
11665
 
11666
    public Object getFieldValue(_Fields field) {
11667
      switch (field) {
11668
      case MERCHANT_PAYMENT_ID:
3430 rajveer 11669
        return Long.valueOf(getMerchantPaymentId());
2462 chandransh 11670
 
11671
      }
11672
      throw new IllegalStateException();
11673
    }
11674
 
3430 rajveer 11675
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11676
    public boolean isSet(_Fields field) {
11677
      if (field == null) {
11678
        throw new IllegalArgumentException();
11679
      }
2462 chandransh 11680
 
11681
      switch (field) {
11682
      case MERCHANT_PAYMENT_ID:
11683
        return isSetMerchantPaymentId();
11684
      }
11685
      throw new IllegalStateException();
11686
    }
11687
 
11688
    @Override
11689
    public boolean equals(Object that) {
11690
      if (that == null)
11691
        return false;
3010 chandransh 11692
      if (that instanceof initializeHdfcPayment_args)
11693
        return this.equals((initializeHdfcPayment_args)that);
2462 chandransh 11694
      return false;
11695
    }
11696
 
3010 chandransh 11697
    public boolean equals(initializeHdfcPayment_args that) {
2462 chandransh 11698
      if (that == null)
11699
        return false;
11700
 
11701
      boolean this_present_merchantPaymentId = true;
11702
      boolean that_present_merchantPaymentId = true;
11703
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
11704
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
11705
          return false;
11706
        if (this.merchantPaymentId != that.merchantPaymentId)
11707
          return false;
11708
      }
11709
 
11710
      return true;
11711
    }
11712
 
11713
    @Override
11714
    public int hashCode() {
11715
      return 0;
11716
    }
11717
 
3010 chandransh 11718
    public int compareTo(initializeHdfcPayment_args other) {
2462 chandransh 11719
      if (!getClass().equals(other.getClass())) {
11720
        return getClass().getName().compareTo(other.getClass().getName());
11721
      }
11722
 
11723
      int lastComparison = 0;
3010 chandransh 11724
      initializeHdfcPayment_args typedOther = (initializeHdfcPayment_args)other;
2462 chandransh 11725
 
3430 rajveer 11726
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
2462 chandransh 11727
      if (lastComparison != 0) {
11728
        return lastComparison;
11729
      }
3430 rajveer 11730
      if (isSetMerchantPaymentId()) {
11731
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
11732
        if (lastComparison != 0) {
11733
          return lastComparison;
11734
        }
2462 chandransh 11735
      }
11736
      return 0;
11737
    }
11738
 
3430 rajveer 11739
    public _Fields fieldForId(int fieldId) {
11740
      return _Fields.findByThriftId(fieldId);
11741
    }
11742
 
11743
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11744
      org.apache.thrift.protocol.TField field;
2462 chandransh 11745
      iprot.readStructBegin();
11746
      while (true)
11747
      {
11748
        field = iprot.readFieldBegin();
3430 rajveer 11749
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 11750
          break;
11751
        }
3430 rajveer 11752
        switch (field.id) {
11753
          case 1: // MERCHANT_PAYMENT_ID
11754
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11755
              this.merchantPaymentId = iprot.readI64();
11756
              setMerchantPaymentIdIsSet(true);
11757
            } else { 
11758
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11759
            }
11760
            break;
11761
          default:
11762
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 11763
        }
3430 rajveer 11764
        iprot.readFieldEnd();
2462 chandransh 11765
      }
11766
      iprot.readStructEnd();
11767
      validate();
11768
    }
11769
 
3430 rajveer 11770
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 11771
      validate();
11772
 
11773
      oprot.writeStructBegin(STRUCT_DESC);
11774
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
11775
      oprot.writeI64(this.merchantPaymentId);
11776
      oprot.writeFieldEnd();
11777
      oprot.writeFieldStop();
11778
      oprot.writeStructEnd();
11779
    }
11780
 
11781
    @Override
11782
    public String toString() {
3010 chandransh 11783
      StringBuilder sb = new StringBuilder("initializeHdfcPayment_args(");
2462 chandransh 11784
      boolean first = true;
11785
 
11786
      sb.append("merchantPaymentId:");
11787
      sb.append(this.merchantPaymentId);
11788
      first = false;
11789
      sb.append(")");
11790
      return sb.toString();
11791
    }
11792
 
3430 rajveer 11793
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 11794
      // check for required fields
11795
    }
11796
 
3430 rajveer 11797
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11798
      try {
11799
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11800
      } catch (org.apache.thrift.TException te) {
11801
        throw new java.io.IOException(te);
11802
      }
11803
    }
11804
 
11805
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11806
      try {
11807
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11808
      } catch (org.apache.thrift.TException te) {
11809
        throw new java.io.IOException(te);
11810
      }
11811
    }
11812
 
2462 chandransh 11813
  }
11814
 
3430 rajveer 11815
  public static class initializeHdfcPayment_result implements org.apache.thrift.TBase<initializeHdfcPayment_result, initializeHdfcPayment_result._Fields>, java.io.Serializable, Cloneable   {
11816
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcPayment_result");
2462 chandransh 11817
 
3430 rajveer 11818
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRING, (short)0);
11819
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2462 chandransh 11820
 
3430 rajveer 11821
    private String success; // required
11822
    private PaymentException pe; // required
2462 chandransh 11823
 
11824
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11825
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 11826
      SUCCESS((short)0, "success"),
11827
      PE((short)1, "pe");
11828
 
11829
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11830
 
11831
      static {
11832
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11833
          byName.put(field.getFieldName(), field);
11834
        }
11835
      }
11836
 
11837
      /**
11838
       * Find the _Fields constant that matches fieldId, or null if its not found.
11839
       */
11840
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11841
        switch(fieldId) {
11842
          case 0: // SUCCESS
11843
            return SUCCESS;
11844
          case 1: // PE
11845
            return PE;
11846
          default:
11847
            return null;
11848
        }
2462 chandransh 11849
      }
11850
 
11851
      /**
11852
       * Find the _Fields constant that matches fieldId, throwing an exception
11853
       * if it is not found.
11854
       */
11855
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11856
        _Fields fields = findByThriftId(fieldId);
11857
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11858
        return fields;
11859
      }
11860
 
11861
      /**
11862
       * Find the _Fields constant that matches name, or null if its not found.
11863
       */
11864
      public static _Fields findByName(String name) {
11865
        return byName.get(name);
11866
      }
11867
 
11868
      private final short _thriftId;
11869
      private final String _fieldName;
11870
 
11871
      _Fields(short thriftId, String fieldName) {
11872
        _thriftId = thriftId;
11873
        _fieldName = fieldName;
11874
      }
11875
 
11876
      public short getThriftFieldId() {
11877
        return _thriftId;
11878
      }
11879
 
11880
      public String getFieldName() {
11881
        return _fieldName;
11882
      }
11883
    }
11884
 
11885
    // isset id assignments
11886
 
3430 rajveer 11887
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 11888
    static {
3430 rajveer 11889
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11890
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11891
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
11892
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11893
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11894
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11895
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcPayment_result.class, metaDataMap);
2462 chandransh 11896
    }
11897
 
3010 chandransh 11898
    public initializeHdfcPayment_result() {
2462 chandransh 11899
    }
11900
 
3010 chandransh 11901
    public initializeHdfcPayment_result(
11902
      String success,
2462 chandransh 11903
      PaymentException pe)
11904
    {
11905
      this();
11906
      this.success = success;
11907
      this.pe = pe;
11908
    }
11909
 
11910
    /**
11911
     * Performs a deep copy on <i>other</i>.
11912
     */
3010 chandransh 11913
    public initializeHdfcPayment_result(initializeHdfcPayment_result other) {
2462 chandransh 11914
      if (other.isSetSuccess()) {
3010 chandransh 11915
        this.success = other.success;
2462 chandransh 11916
      }
11917
      if (other.isSetPe()) {
11918
        this.pe = new PaymentException(other.pe);
11919
      }
11920
    }
11921
 
3010 chandransh 11922
    public initializeHdfcPayment_result deepCopy() {
11923
      return new initializeHdfcPayment_result(this);
2462 chandransh 11924
    }
11925
 
3430 rajveer 11926
    @Override
11927
    public void clear() {
11928
      this.success = null;
11929
      this.pe = null;
2462 chandransh 11930
    }
11931
 
3010 chandransh 11932
    public String getSuccess() {
2462 chandransh 11933
      return this.success;
11934
    }
11935
 
3430 rajveer 11936
    public void setSuccess(String success) {
2462 chandransh 11937
      this.success = success;
11938
    }
11939
 
11940
    public void unsetSuccess() {
11941
      this.success = null;
11942
    }
11943
 
3430 rajveer 11944
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2462 chandransh 11945
    public boolean isSetSuccess() {
11946
      return this.success != null;
11947
    }
11948
 
11949
    public void setSuccessIsSet(boolean value) {
11950
      if (!value) {
11951
        this.success = null;
11952
      }
11953
    }
11954
 
11955
    public PaymentException getPe() {
11956
      return this.pe;
11957
    }
11958
 
3430 rajveer 11959
    public void setPe(PaymentException pe) {
2462 chandransh 11960
      this.pe = pe;
11961
    }
11962
 
11963
    public void unsetPe() {
11964
      this.pe = null;
11965
    }
11966
 
3430 rajveer 11967
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2462 chandransh 11968
    public boolean isSetPe() {
11969
      return this.pe != null;
11970
    }
11971
 
11972
    public void setPeIsSet(boolean value) {
11973
      if (!value) {
11974
        this.pe = null;
11975
      }
11976
    }
11977
 
11978
    public void setFieldValue(_Fields field, Object value) {
11979
      switch (field) {
11980
      case SUCCESS:
11981
        if (value == null) {
11982
          unsetSuccess();
11983
        } else {
3010 chandransh 11984
          setSuccess((String)value);
2462 chandransh 11985
        }
11986
        break;
11987
 
11988
      case PE:
11989
        if (value == null) {
11990
          unsetPe();
11991
        } else {
11992
          setPe((PaymentException)value);
11993
        }
11994
        break;
11995
 
11996
      }
11997
    }
11998
 
11999
    public Object getFieldValue(_Fields field) {
12000
      switch (field) {
12001
      case SUCCESS:
12002
        return getSuccess();
12003
 
12004
      case PE:
12005
        return getPe();
12006
 
12007
      }
12008
      throw new IllegalStateException();
12009
    }
12010
 
3430 rajveer 12011
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12012
    public boolean isSet(_Fields field) {
12013
      if (field == null) {
12014
        throw new IllegalArgumentException();
12015
      }
2462 chandransh 12016
 
12017
      switch (field) {
12018
      case SUCCESS:
12019
        return isSetSuccess();
12020
      case PE:
12021
        return isSetPe();
12022
      }
12023
      throw new IllegalStateException();
12024
    }
12025
 
12026
    @Override
12027
    public boolean equals(Object that) {
12028
      if (that == null)
12029
        return false;
3010 chandransh 12030
      if (that instanceof initializeHdfcPayment_result)
12031
        return this.equals((initializeHdfcPayment_result)that);
2462 chandransh 12032
      return false;
12033
    }
12034
 
3010 chandransh 12035
    public boolean equals(initializeHdfcPayment_result that) {
2462 chandransh 12036
      if (that == null)
12037
        return false;
12038
 
12039
      boolean this_present_success = true && this.isSetSuccess();
12040
      boolean that_present_success = true && that.isSetSuccess();
12041
      if (this_present_success || that_present_success) {
12042
        if (!(this_present_success && that_present_success))
12043
          return false;
12044
        if (!this.success.equals(that.success))
12045
          return false;
12046
      }
12047
 
12048
      boolean this_present_pe = true && this.isSetPe();
12049
      boolean that_present_pe = true && that.isSetPe();
12050
      if (this_present_pe || that_present_pe) {
12051
        if (!(this_present_pe && that_present_pe))
12052
          return false;
12053
        if (!this.pe.equals(that.pe))
12054
          return false;
12055
      }
12056
 
12057
      return true;
12058
    }
12059
 
12060
    @Override
12061
    public int hashCode() {
12062
      return 0;
12063
    }
12064
 
3010 chandransh 12065
    public int compareTo(initializeHdfcPayment_result other) {
12066
      if (!getClass().equals(other.getClass())) {
12067
        return getClass().getName().compareTo(other.getClass().getName());
12068
      }
12069
 
12070
      int lastComparison = 0;
12071
      initializeHdfcPayment_result typedOther = (initializeHdfcPayment_result)other;
12072
 
3430 rajveer 12073
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3010 chandransh 12074
      if (lastComparison != 0) {
12075
        return lastComparison;
12076
      }
3430 rajveer 12077
      if (isSetSuccess()) {
12078
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12079
        if (lastComparison != 0) {
12080
          return lastComparison;
12081
        }
3010 chandransh 12082
      }
3430 rajveer 12083
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
3010 chandransh 12084
      if (lastComparison != 0) {
12085
        return lastComparison;
12086
      }
3430 rajveer 12087
      if (isSetPe()) {
12088
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
12089
        if (lastComparison != 0) {
12090
          return lastComparison;
12091
        }
3010 chandransh 12092
      }
12093
      return 0;
12094
    }
12095
 
3430 rajveer 12096
    public _Fields fieldForId(int fieldId) {
12097
      return _Fields.findByThriftId(fieldId);
12098
    }
12099
 
12100
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12101
      org.apache.thrift.protocol.TField field;
2462 chandransh 12102
      iprot.readStructBegin();
12103
      while (true)
12104
      {
12105
        field = iprot.readFieldBegin();
3430 rajveer 12106
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 12107
          break;
12108
        }
3430 rajveer 12109
        switch (field.id) {
12110
          case 0: // SUCCESS
12111
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
12112
              this.success = iprot.readString();
12113
            } else { 
12114
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12115
            }
12116
            break;
12117
          case 1: // PE
12118
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
12119
              this.pe = new PaymentException();
12120
              this.pe.read(iprot);
12121
            } else { 
12122
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12123
            }
12124
            break;
12125
          default:
12126
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 12127
        }
3430 rajveer 12128
        iprot.readFieldEnd();
2462 chandransh 12129
      }
12130
      iprot.readStructEnd();
12131
      validate();
12132
    }
12133
 
3430 rajveer 12134
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 12135
      oprot.writeStructBegin(STRUCT_DESC);
12136
 
12137
      if (this.isSetSuccess()) {
12138
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 12139
        oprot.writeString(this.success);
2462 chandransh 12140
        oprot.writeFieldEnd();
12141
      } else if (this.isSetPe()) {
12142
        oprot.writeFieldBegin(PE_FIELD_DESC);
12143
        this.pe.write(oprot);
12144
        oprot.writeFieldEnd();
12145
      }
12146
      oprot.writeFieldStop();
12147
      oprot.writeStructEnd();
12148
    }
12149
 
12150
    @Override
12151
    public String toString() {
3010 chandransh 12152
      StringBuilder sb = new StringBuilder("initializeHdfcPayment_result(");
2462 chandransh 12153
      boolean first = true;
12154
 
12155
      sb.append("success:");
12156
      if (this.success == null) {
12157
        sb.append("null");
12158
      } else {
12159
        sb.append(this.success);
12160
      }
12161
      first = false;
12162
      if (!first) sb.append(", ");
12163
      sb.append("pe:");
12164
      if (this.pe == null) {
12165
        sb.append("null");
12166
      } else {
12167
        sb.append(this.pe);
12168
      }
12169
      first = false;
12170
      sb.append(")");
12171
      return sb.toString();
12172
    }
12173
 
3430 rajveer 12174
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 12175
      // check for required fields
12176
    }
12177
 
3430 rajveer 12178
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12179
      try {
12180
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12181
      } catch (org.apache.thrift.TException te) {
12182
        throw new java.io.IOException(te);
12183
      }
12184
    }
12185
 
12186
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12187
      try {
12188
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12189
      } catch (org.apache.thrift.TException te) {
12190
        throw new java.io.IOException(te);
12191
      }
12192
    }
12193
 
2462 chandransh 12194
  }
12195
 
6050 anupam.sin 12196
  public static class doHdfcPaymentForDigitalOrder_args implements org.apache.thrift.TBase<doHdfcPaymentForDigitalOrder_args, doHdfcPaymentForDigitalOrder_args._Fields>, java.io.Serializable, Cloneable   {
12197
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("doHdfcPaymentForDigitalOrder_args");
12198
 
12199
    private static final org.apache.thrift.protocol.TField MERCHANT_PAYMENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantPaymentId", org.apache.thrift.protocol.TType.I64, (short)1);
12200
    private static final org.apache.thrift.protocol.TField RECHARGE_ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("rechargeOrderId", org.apache.thrift.protocol.TType.I64, (short)2);
6228 anupam.sin 12201
    private static final org.apache.thrift.protocol.TField PHONE_FIELD_DESC = new org.apache.thrift.protocol.TField("phone", org.apache.thrift.protocol.TType.STRING, (short)-1);
6050 anupam.sin 12202
 
12203
    private long merchantPaymentId; // required
12204
    private long rechargeOrderId; // required
6228 anupam.sin 12205
    private String phone; // required
6050 anupam.sin 12206
 
12207
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12208
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12209
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId"),
6228 anupam.sin 12210
      RECHARGE_ORDER_ID((short)2, "rechargeOrderId"),
12211
      PHONE((short)-1, "phone");
6050 anupam.sin 12212
 
12213
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12214
 
12215
      static {
12216
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12217
          byName.put(field.getFieldName(), field);
12218
        }
12219
      }
12220
 
12221
      /**
12222
       * Find the _Fields constant that matches fieldId, or null if its not found.
12223
       */
12224
      public static _Fields findByThriftId(int fieldId) {
12225
        switch(fieldId) {
12226
          case 1: // MERCHANT_PAYMENT_ID
12227
            return MERCHANT_PAYMENT_ID;
12228
          case 2: // RECHARGE_ORDER_ID
12229
            return RECHARGE_ORDER_ID;
6228 anupam.sin 12230
          case -1: // PHONE
12231
            return PHONE;
6050 anupam.sin 12232
          default:
12233
            return null;
12234
        }
12235
      }
12236
 
12237
      /**
12238
       * Find the _Fields constant that matches fieldId, throwing an exception
12239
       * if it is not found.
12240
       */
12241
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12242
        _Fields fields = findByThriftId(fieldId);
12243
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12244
        return fields;
12245
      }
12246
 
12247
      /**
12248
       * Find the _Fields constant that matches name, or null if its not found.
12249
       */
12250
      public static _Fields findByName(String name) {
12251
        return byName.get(name);
12252
      }
12253
 
12254
      private final short _thriftId;
12255
      private final String _fieldName;
12256
 
12257
      _Fields(short thriftId, String fieldName) {
12258
        _thriftId = thriftId;
12259
        _fieldName = fieldName;
12260
      }
12261
 
12262
      public short getThriftFieldId() {
12263
        return _thriftId;
12264
      }
12265
 
12266
      public String getFieldName() {
12267
        return _fieldName;
12268
      }
12269
    }
12270
 
12271
    // isset id assignments
12272
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
12273
    private static final int __RECHARGEORDERID_ISSET_ID = 1;
12274
    private BitSet __isset_bit_vector = new BitSet(2);
12275
 
12276
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12277
    static {
12278
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12279
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12280
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12281
      tmpMap.put(_Fields.RECHARGE_ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("rechargeOrderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12282
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6228 anupam.sin 12283
      tmpMap.put(_Fields.PHONE, new org.apache.thrift.meta_data.FieldMetaData("phone", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12284
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
6050 anupam.sin 12285
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12286
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(doHdfcPaymentForDigitalOrder_args.class, metaDataMap);
12287
    }
12288
 
12289
    public doHdfcPaymentForDigitalOrder_args() {
12290
    }
12291
 
12292
    public doHdfcPaymentForDigitalOrder_args(
12293
      long merchantPaymentId,
6228 anupam.sin 12294
      long rechargeOrderId,
12295
      String phone)
6050 anupam.sin 12296
    {
12297
      this();
12298
      this.merchantPaymentId = merchantPaymentId;
12299
      setMerchantPaymentIdIsSet(true);
12300
      this.rechargeOrderId = rechargeOrderId;
12301
      setRechargeOrderIdIsSet(true);
6228 anupam.sin 12302
      this.phone = phone;
6050 anupam.sin 12303
    }
12304
 
12305
    /**
12306
     * Performs a deep copy on <i>other</i>.
12307
     */
12308
    public doHdfcPaymentForDigitalOrder_args(doHdfcPaymentForDigitalOrder_args other) {
12309
      __isset_bit_vector.clear();
12310
      __isset_bit_vector.or(other.__isset_bit_vector);
12311
      this.merchantPaymentId = other.merchantPaymentId;
12312
      this.rechargeOrderId = other.rechargeOrderId;
6228 anupam.sin 12313
      if (other.isSetPhone()) {
12314
        this.phone = other.phone;
12315
      }
6050 anupam.sin 12316
    }
12317
 
12318
    public doHdfcPaymentForDigitalOrder_args deepCopy() {
12319
      return new doHdfcPaymentForDigitalOrder_args(this);
12320
    }
12321
 
12322
    @Override
12323
    public void clear() {
12324
      setMerchantPaymentIdIsSet(false);
12325
      this.merchantPaymentId = 0;
12326
      setRechargeOrderIdIsSet(false);
12327
      this.rechargeOrderId = 0;
6228 anupam.sin 12328
      this.phone = null;
6050 anupam.sin 12329
    }
12330
 
12331
    public long getMerchantPaymentId() {
12332
      return this.merchantPaymentId;
12333
    }
12334
 
12335
    public void setMerchantPaymentId(long merchantPaymentId) {
12336
      this.merchantPaymentId = merchantPaymentId;
12337
      setMerchantPaymentIdIsSet(true);
12338
    }
12339
 
12340
    public void unsetMerchantPaymentId() {
12341
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
12342
    }
12343
 
12344
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
12345
    public boolean isSetMerchantPaymentId() {
12346
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
12347
    }
12348
 
12349
    public void setMerchantPaymentIdIsSet(boolean value) {
12350
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
12351
    }
12352
 
12353
    public long getRechargeOrderId() {
12354
      return this.rechargeOrderId;
12355
    }
12356
 
12357
    public void setRechargeOrderId(long rechargeOrderId) {
12358
      this.rechargeOrderId = rechargeOrderId;
12359
      setRechargeOrderIdIsSet(true);
12360
    }
12361
 
12362
    public void unsetRechargeOrderId() {
12363
      __isset_bit_vector.clear(__RECHARGEORDERID_ISSET_ID);
12364
    }
12365
 
12366
    /** Returns true if field rechargeOrderId is set (has been assigned a value) and false otherwise */
12367
    public boolean isSetRechargeOrderId() {
12368
      return __isset_bit_vector.get(__RECHARGEORDERID_ISSET_ID);
12369
    }
12370
 
12371
    public void setRechargeOrderIdIsSet(boolean value) {
12372
      __isset_bit_vector.set(__RECHARGEORDERID_ISSET_ID, value);
12373
    }
12374
 
6228 anupam.sin 12375
    public String getPhone() {
12376
      return this.phone;
12377
    }
12378
 
12379
    public void setPhone(String phone) {
12380
      this.phone = phone;
12381
    }
12382
 
12383
    public void unsetPhone() {
12384
      this.phone = null;
12385
    }
12386
 
12387
    /** Returns true if field phone is set (has been assigned a value) and false otherwise */
12388
    public boolean isSetPhone() {
12389
      return this.phone != null;
12390
    }
12391
 
12392
    public void setPhoneIsSet(boolean value) {
12393
      if (!value) {
12394
        this.phone = null;
12395
      }
12396
    }
12397
 
6050 anupam.sin 12398
    public void setFieldValue(_Fields field, Object value) {
12399
      switch (field) {
12400
      case MERCHANT_PAYMENT_ID:
12401
        if (value == null) {
12402
          unsetMerchantPaymentId();
12403
        } else {
12404
          setMerchantPaymentId((Long)value);
12405
        }
12406
        break;
12407
 
12408
      case RECHARGE_ORDER_ID:
12409
        if (value == null) {
12410
          unsetRechargeOrderId();
12411
        } else {
12412
          setRechargeOrderId((Long)value);
12413
        }
12414
        break;
12415
 
6228 anupam.sin 12416
      case PHONE:
12417
        if (value == null) {
12418
          unsetPhone();
12419
        } else {
12420
          setPhone((String)value);
12421
        }
12422
        break;
12423
 
6050 anupam.sin 12424
      }
12425
    }
12426
 
12427
    public Object getFieldValue(_Fields field) {
12428
      switch (field) {
12429
      case MERCHANT_PAYMENT_ID:
12430
        return Long.valueOf(getMerchantPaymentId());
12431
 
12432
      case RECHARGE_ORDER_ID:
12433
        return Long.valueOf(getRechargeOrderId());
12434
 
6228 anupam.sin 12435
      case PHONE:
12436
        return getPhone();
12437
 
6050 anupam.sin 12438
      }
12439
      throw new IllegalStateException();
12440
    }
12441
 
12442
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12443
    public boolean isSet(_Fields field) {
12444
      if (field == null) {
12445
        throw new IllegalArgumentException();
12446
      }
12447
 
12448
      switch (field) {
12449
      case MERCHANT_PAYMENT_ID:
12450
        return isSetMerchantPaymentId();
12451
      case RECHARGE_ORDER_ID:
12452
        return isSetRechargeOrderId();
6228 anupam.sin 12453
      case PHONE:
12454
        return isSetPhone();
6050 anupam.sin 12455
      }
12456
      throw new IllegalStateException();
12457
    }
12458
 
12459
    @Override
12460
    public boolean equals(Object that) {
12461
      if (that == null)
12462
        return false;
12463
      if (that instanceof doHdfcPaymentForDigitalOrder_args)
12464
        return this.equals((doHdfcPaymentForDigitalOrder_args)that);
12465
      return false;
12466
    }
12467
 
12468
    public boolean equals(doHdfcPaymentForDigitalOrder_args that) {
12469
      if (that == null)
12470
        return false;
12471
 
12472
      boolean this_present_merchantPaymentId = true;
12473
      boolean that_present_merchantPaymentId = true;
12474
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
12475
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
12476
          return false;
12477
        if (this.merchantPaymentId != that.merchantPaymentId)
12478
          return false;
12479
      }
12480
 
12481
      boolean this_present_rechargeOrderId = true;
12482
      boolean that_present_rechargeOrderId = true;
12483
      if (this_present_rechargeOrderId || that_present_rechargeOrderId) {
12484
        if (!(this_present_rechargeOrderId && that_present_rechargeOrderId))
12485
          return false;
12486
        if (this.rechargeOrderId != that.rechargeOrderId)
12487
          return false;
12488
      }
12489
 
6228 anupam.sin 12490
      boolean this_present_phone = true && this.isSetPhone();
12491
      boolean that_present_phone = true && that.isSetPhone();
12492
      if (this_present_phone || that_present_phone) {
12493
        if (!(this_present_phone && that_present_phone))
12494
          return false;
12495
        if (!this.phone.equals(that.phone))
12496
          return false;
12497
      }
12498
 
6050 anupam.sin 12499
      return true;
12500
    }
12501
 
12502
    @Override
12503
    public int hashCode() {
12504
      return 0;
12505
    }
12506
 
12507
    public int compareTo(doHdfcPaymentForDigitalOrder_args other) {
12508
      if (!getClass().equals(other.getClass())) {
12509
        return getClass().getName().compareTo(other.getClass().getName());
12510
      }
12511
 
12512
      int lastComparison = 0;
12513
      doHdfcPaymentForDigitalOrder_args typedOther = (doHdfcPaymentForDigitalOrder_args)other;
12514
 
12515
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
12516
      if (lastComparison != 0) {
12517
        return lastComparison;
12518
      }
12519
      if (isSetMerchantPaymentId()) {
12520
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
12521
        if (lastComparison != 0) {
12522
          return lastComparison;
12523
        }
12524
      }
12525
      lastComparison = Boolean.valueOf(isSetRechargeOrderId()).compareTo(typedOther.isSetRechargeOrderId());
12526
      if (lastComparison != 0) {
12527
        return lastComparison;
12528
      }
12529
      if (isSetRechargeOrderId()) {
12530
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rechargeOrderId, typedOther.rechargeOrderId);
12531
        if (lastComparison != 0) {
12532
          return lastComparison;
12533
        }
12534
      }
6228 anupam.sin 12535
      lastComparison = Boolean.valueOf(isSetPhone()).compareTo(typedOther.isSetPhone());
12536
      if (lastComparison != 0) {
12537
        return lastComparison;
12538
      }
12539
      if (isSetPhone()) {
12540
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.phone, typedOther.phone);
12541
        if (lastComparison != 0) {
12542
          return lastComparison;
12543
        }
12544
      }
6050 anupam.sin 12545
      return 0;
12546
    }
12547
 
12548
    public _Fields fieldForId(int fieldId) {
12549
      return _Fields.findByThriftId(fieldId);
12550
    }
12551
 
12552
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12553
      org.apache.thrift.protocol.TField field;
12554
      iprot.readStructBegin();
12555
      while (true)
12556
      {
12557
        field = iprot.readFieldBegin();
12558
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12559
          break;
12560
        }
12561
        switch (field.id) {
12562
          case 1: // MERCHANT_PAYMENT_ID
12563
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12564
              this.merchantPaymentId = iprot.readI64();
12565
              setMerchantPaymentIdIsSet(true);
12566
            } else { 
12567
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12568
            }
12569
            break;
12570
          case 2: // RECHARGE_ORDER_ID
12571
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12572
              this.rechargeOrderId = iprot.readI64();
12573
              setRechargeOrderIdIsSet(true);
12574
            } else { 
12575
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12576
            }
12577
            break;
6228 anupam.sin 12578
          case -1: // PHONE
12579
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
12580
              this.phone = iprot.readString();
12581
            } else { 
12582
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12583
            }
12584
            break;
6050 anupam.sin 12585
          default:
12586
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12587
        }
12588
        iprot.readFieldEnd();
12589
      }
12590
      iprot.readStructEnd();
12591
      validate();
12592
    }
12593
 
12594
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12595
      validate();
12596
 
12597
      oprot.writeStructBegin(STRUCT_DESC);
6228 anupam.sin 12598
      if (this.phone != null) {
12599
        oprot.writeFieldBegin(PHONE_FIELD_DESC);
12600
        oprot.writeString(this.phone);
12601
        oprot.writeFieldEnd();
12602
      }
6050 anupam.sin 12603
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
12604
      oprot.writeI64(this.merchantPaymentId);
12605
      oprot.writeFieldEnd();
12606
      oprot.writeFieldBegin(RECHARGE_ORDER_ID_FIELD_DESC);
12607
      oprot.writeI64(this.rechargeOrderId);
12608
      oprot.writeFieldEnd();
12609
      oprot.writeFieldStop();
12610
      oprot.writeStructEnd();
12611
    }
12612
 
12613
    @Override
12614
    public String toString() {
12615
      StringBuilder sb = new StringBuilder("doHdfcPaymentForDigitalOrder_args(");
12616
      boolean first = true;
12617
 
12618
      sb.append("merchantPaymentId:");
12619
      sb.append(this.merchantPaymentId);
12620
      first = false;
12621
      if (!first) sb.append(", ");
12622
      sb.append("rechargeOrderId:");
12623
      sb.append(this.rechargeOrderId);
12624
      first = false;
6228 anupam.sin 12625
      if (!first) sb.append(", ");
12626
      sb.append("phone:");
12627
      if (this.phone == null) {
12628
        sb.append("null");
12629
      } else {
12630
        sb.append(this.phone);
12631
      }
12632
      first = false;
6050 anupam.sin 12633
      sb.append(")");
12634
      return sb.toString();
12635
    }
12636
 
12637
    public void validate() throws org.apache.thrift.TException {
12638
      // check for required fields
12639
    }
12640
 
12641
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12642
      try {
12643
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12644
      } catch (org.apache.thrift.TException te) {
12645
        throw new java.io.IOException(te);
12646
      }
12647
    }
12648
 
12649
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12650
      try {
12651
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12652
      } catch (org.apache.thrift.TException te) {
12653
        throw new java.io.IOException(te);
12654
      }
12655
    }
12656
 
12657
  }
12658
 
12659
  public static class doHdfcPaymentForDigitalOrder_result implements org.apache.thrift.TBase<doHdfcPaymentForDigitalOrder_result, doHdfcPaymentForDigitalOrder_result._Fields>, java.io.Serializable, Cloneable   {
12660
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("doHdfcPaymentForDigitalOrder_result");
12661
 
12662
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRING, (short)0);
12663
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
12664
 
12665
    private String success; // required
12666
    private PaymentException pe; // required
12667
 
12668
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12669
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12670
      SUCCESS((short)0, "success"),
12671
      PE((short)1, "pe");
12672
 
12673
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12674
 
12675
      static {
12676
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12677
          byName.put(field.getFieldName(), field);
12678
        }
12679
      }
12680
 
12681
      /**
12682
       * Find the _Fields constant that matches fieldId, or null if its not found.
12683
       */
12684
      public static _Fields findByThriftId(int fieldId) {
12685
        switch(fieldId) {
12686
          case 0: // SUCCESS
12687
            return SUCCESS;
12688
          case 1: // PE
12689
            return PE;
12690
          default:
12691
            return null;
12692
        }
12693
      }
12694
 
12695
      /**
12696
       * Find the _Fields constant that matches fieldId, throwing an exception
12697
       * if it is not found.
12698
       */
12699
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12700
        _Fields fields = findByThriftId(fieldId);
12701
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12702
        return fields;
12703
      }
12704
 
12705
      /**
12706
       * Find the _Fields constant that matches name, or null if its not found.
12707
       */
12708
      public static _Fields findByName(String name) {
12709
        return byName.get(name);
12710
      }
12711
 
12712
      private final short _thriftId;
12713
      private final String _fieldName;
12714
 
12715
      _Fields(short thriftId, String fieldName) {
12716
        _thriftId = thriftId;
12717
        _fieldName = fieldName;
12718
      }
12719
 
12720
      public short getThriftFieldId() {
12721
        return _thriftId;
12722
      }
12723
 
12724
      public String getFieldName() {
12725
        return _fieldName;
12726
      }
12727
    }
12728
 
12729
    // isset id assignments
12730
 
12731
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12732
    static {
12733
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12734
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12735
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
12736
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12737
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
12738
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12739
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(doHdfcPaymentForDigitalOrder_result.class, metaDataMap);
12740
    }
12741
 
12742
    public doHdfcPaymentForDigitalOrder_result() {
12743
    }
12744
 
12745
    public doHdfcPaymentForDigitalOrder_result(
12746
      String success,
12747
      PaymentException pe)
12748
    {
12749
      this();
12750
      this.success = success;
12751
      this.pe = pe;
12752
    }
12753
 
12754
    /**
12755
     * Performs a deep copy on <i>other</i>.
12756
     */
12757
    public doHdfcPaymentForDigitalOrder_result(doHdfcPaymentForDigitalOrder_result other) {
12758
      if (other.isSetSuccess()) {
12759
        this.success = other.success;
12760
      }
12761
      if (other.isSetPe()) {
12762
        this.pe = new PaymentException(other.pe);
12763
      }
12764
    }
12765
 
12766
    public doHdfcPaymentForDigitalOrder_result deepCopy() {
12767
      return new doHdfcPaymentForDigitalOrder_result(this);
12768
    }
12769
 
12770
    @Override
12771
    public void clear() {
12772
      this.success = null;
12773
      this.pe = null;
12774
    }
12775
 
12776
    public String getSuccess() {
12777
      return this.success;
12778
    }
12779
 
12780
    public void setSuccess(String success) {
12781
      this.success = success;
12782
    }
12783
 
12784
    public void unsetSuccess() {
12785
      this.success = null;
12786
    }
12787
 
12788
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
12789
    public boolean isSetSuccess() {
12790
      return this.success != null;
12791
    }
12792
 
12793
    public void setSuccessIsSet(boolean value) {
12794
      if (!value) {
12795
        this.success = null;
12796
      }
12797
    }
12798
 
12799
    public PaymentException getPe() {
12800
      return this.pe;
12801
    }
12802
 
12803
    public void setPe(PaymentException pe) {
12804
      this.pe = pe;
12805
    }
12806
 
12807
    public void unsetPe() {
12808
      this.pe = null;
12809
    }
12810
 
12811
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
12812
    public boolean isSetPe() {
12813
      return this.pe != null;
12814
    }
12815
 
12816
    public void setPeIsSet(boolean value) {
12817
      if (!value) {
12818
        this.pe = null;
12819
      }
12820
    }
12821
 
12822
    public void setFieldValue(_Fields field, Object value) {
12823
      switch (field) {
12824
      case SUCCESS:
12825
        if (value == null) {
12826
          unsetSuccess();
12827
        } else {
12828
          setSuccess((String)value);
12829
        }
12830
        break;
12831
 
12832
      case PE:
12833
        if (value == null) {
12834
          unsetPe();
12835
        } else {
12836
          setPe((PaymentException)value);
12837
        }
12838
        break;
12839
 
12840
      }
12841
    }
12842
 
12843
    public Object getFieldValue(_Fields field) {
12844
      switch (field) {
12845
      case SUCCESS:
12846
        return getSuccess();
12847
 
12848
      case PE:
12849
        return getPe();
12850
 
12851
      }
12852
      throw new IllegalStateException();
12853
    }
12854
 
12855
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12856
    public boolean isSet(_Fields field) {
12857
      if (field == null) {
12858
        throw new IllegalArgumentException();
12859
      }
12860
 
12861
      switch (field) {
12862
      case SUCCESS:
12863
        return isSetSuccess();
12864
      case PE:
12865
        return isSetPe();
12866
      }
12867
      throw new IllegalStateException();
12868
    }
12869
 
12870
    @Override
12871
    public boolean equals(Object that) {
12872
      if (that == null)
12873
        return false;
12874
      if (that instanceof doHdfcPaymentForDigitalOrder_result)
12875
        return this.equals((doHdfcPaymentForDigitalOrder_result)that);
12876
      return false;
12877
    }
12878
 
12879
    public boolean equals(doHdfcPaymentForDigitalOrder_result that) {
12880
      if (that == null)
12881
        return false;
12882
 
12883
      boolean this_present_success = true && this.isSetSuccess();
12884
      boolean that_present_success = true && that.isSetSuccess();
12885
      if (this_present_success || that_present_success) {
12886
        if (!(this_present_success && that_present_success))
12887
          return false;
12888
        if (!this.success.equals(that.success))
12889
          return false;
12890
      }
12891
 
12892
      boolean this_present_pe = true && this.isSetPe();
12893
      boolean that_present_pe = true && that.isSetPe();
12894
      if (this_present_pe || that_present_pe) {
12895
        if (!(this_present_pe && that_present_pe))
12896
          return false;
12897
        if (!this.pe.equals(that.pe))
12898
          return false;
12899
      }
12900
 
12901
      return true;
12902
    }
12903
 
12904
    @Override
12905
    public int hashCode() {
12906
      return 0;
12907
    }
12908
 
12909
    public int compareTo(doHdfcPaymentForDigitalOrder_result other) {
12910
      if (!getClass().equals(other.getClass())) {
12911
        return getClass().getName().compareTo(other.getClass().getName());
12912
      }
12913
 
12914
      int lastComparison = 0;
12915
      doHdfcPaymentForDigitalOrder_result typedOther = (doHdfcPaymentForDigitalOrder_result)other;
12916
 
12917
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
12918
      if (lastComparison != 0) {
12919
        return lastComparison;
12920
      }
12921
      if (isSetSuccess()) {
12922
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12923
        if (lastComparison != 0) {
12924
          return lastComparison;
12925
        }
12926
      }
12927
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
12928
      if (lastComparison != 0) {
12929
        return lastComparison;
12930
      }
12931
      if (isSetPe()) {
12932
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
12933
        if (lastComparison != 0) {
12934
          return lastComparison;
12935
        }
12936
      }
12937
      return 0;
12938
    }
12939
 
12940
    public _Fields fieldForId(int fieldId) {
12941
      return _Fields.findByThriftId(fieldId);
12942
    }
12943
 
12944
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12945
      org.apache.thrift.protocol.TField field;
12946
      iprot.readStructBegin();
12947
      while (true)
12948
      {
12949
        field = iprot.readFieldBegin();
12950
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12951
          break;
12952
        }
12953
        switch (field.id) {
12954
          case 0: // SUCCESS
12955
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
12956
              this.success = iprot.readString();
12957
            } else { 
12958
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12959
            }
12960
            break;
12961
          case 1: // PE
12962
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
12963
              this.pe = new PaymentException();
12964
              this.pe.read(iprot);
12965
            } else { 
12966
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12967
            }
12968
            break;
12969
          default:
12970
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12971
        }
12972
        iprot.readFieldEnd();
12973
      }
12974
      iprot.readStructEnd();
12975
      validate();
12976
    }
12977
 
12978
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12979
      oprot.writeStructBegin(STRUCT_DESC);
12980
 
12981
      if (this.isSetSuccess()) {
12982
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12983
        oprot.writeString(this.success);
12984
        oprot.writeFieldEnd();
12985
      } else if (this.isSetPe()) {
12986
        oprot.writeFieldBegin(PE_FIELD_DESC);
12987
        this.pe.write(oprot);
12988
        oprot.writeFieldEnd();
12989
      }
12990
      oprot.writeFieldStop();
12991
      oprot.writeStructEnd();
12992
    }
12993
 
12994
    @Override
12995
    public String toString() {
12996
      StringBuilder sb = new StringBuilder("doHdfcPaymentForDigitalOrder_result(");
12997
      boolean first = true;
12998
 
12999
      sb.append("success:");
13000
      if (this.success == null) {
13001
        sb.append("null");
13002
      } else {
13003
        sb.append(this.success);
13004
      }
13005
      first = false;
13006
      if (!first) sb.append(", ");
13007
      sb.append("pe:");
13008
      if (this.pe == null) {
13009
        sb.append("null");
13010
      } else {
13011
        sb.append(this.pe);
13012
      }
13013
      first = false;
13014
      sb.append(")");
13015
      return sb.toString();
13016
    }
13017
 
13018
    public void validate() throws org.apache.thrift.TException {
13019
      // check for required fields
13020
    }
13021
 
13022
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13023
      try {
13024
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13025
      } catch (org.apache.thrift.TException te) {
13026
        throw new java.io.IOException(te);
13027
      }
13028
    }
13029
 
13030
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13031
      try {
13032
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13033
      } catch (org.apache.thrift.TException te) {
13034
        throw new java.io.IOException(te);
13035
      }
13036
    }
13037
 
13038
  }
13039
 
3616 chandransh 13040
  public static class initializeHdfcEmiPayment_args implements org.apache.thrift.TBase<initializeHdfcEmiPayment_args, initializeHdfcEmiPayment_args._Fields>, java.io.Serializable, Cloneable   {
13041
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcEmiPayment_args");
13042
 
13043
    private static final org.apache.thrift.protocol.TField MERCHANT_PAYMENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantPaymentId", org.apache.thrift.protocol.TType.I64, (short)1);
13044
 
13045
    private long merchantPaymentId; // required
13046
 
13047
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13048
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13049
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId");
13050
 
13051
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13052
 
13053
      static {
13054
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13055
          byName.put(field.getFieldName(), field);
13056
        }
13057
      }
13058
 
13059
      /**
13060
       * Find the _Fields constant that matches fieldId, or null if its not found.
13061
       */
13062
      public static _Fields findByThriftId(int fieldId) {
13063
        switch(fieldId) {
13064
          case 1: // MERCHANT_PAYMENT_ID
13065
            return MERCHANT_PAYMENT_ID;
13066
          default:
13067
            return null;
13068
        }
13069
      }
13070
 
13071
      /**
13072
       * Find the _Fields constant that matches fieldId, throwing an exception
13073
       * if it is not found.
13074
       */
13075
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13076
        _Fields fields = findByThriftId(fieldId);
13077
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13078
        return fields;
13079
      }
13080
 
13081
      /**
13082
       * Find the _Fields constant that matches name, or null if its not found.
13083
       */
13084
      public static _Fields findByName(String name) {
13085
        return byName.get(name);
13086
      }
13087
 
13088
      private final short _thriftId;
13089
      private final String _fieldName;
13090
 
13091
      _Fields(short thriftId, String fieldName) {
13092
        _thriftId = thriftId;
13093
        _fieldName = fieldName;
13094
      }
13095
 
13096
      public short getThriftFieldId() {
13097
        return _thriftId;
13098
      }
13099
 
13100
      public String getFieldName() {
13101
        return _fieldName;
13102
      }
13103
    }
13104
 
13105
    // isset id assignments
13106
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
13107
    private BitSet __isset_bit_vector = new BitSet(1);
13108
 
13109
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13110
    static {
13111
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13112
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13113
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13114
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13115
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcEmiPayment_args.class, metaDataMap);
13116
    }
13117
 
13118
    public initializeHdfcEmiPayment_args() {
13119
    }
13120
 
13121
    public initializeHdfcEmiPayment_args(
13122
      long merchantPaymentId)
13123
    {
13124
      this();
13125
      this.merchantPaymentId = merchantPaymentId;
13126
      setMerchantPaymentIdIsSet(true);
13127
    }
13128
 
13129
    /**
13130
     * Performs a deep copy on <i>other</i>.
13131
     */
13132
    public initializeHdfcEmiPayment_args(initializeHdfcEmiPayment_args other) {
13133
      __isset_bit_vector.clear();
13134
      __isset_bit_vector.or(other.__isset_bit_vector);
13135
      this.merchantPaymentId = other.merchantPaymentId;
13136
    }
13137
 
13138
    public initializeHdfcEmiPayment_args deepCopy() {
13139
      return new initializeHdfcEmiPayment_args(this);
13140
    }
13141
 
13142
    @Override
13143
    public void clear() {
13144
      setMerchantPaymentIdIsSet(false);
13145
      this.merchantPaymentId = 0;
13146
    }
13147
 
13148
    public long getMerchantPaymentId() {
13149
      return this.merchantPaymentId;
13150
    }
13151
 
13152
    public void setMerchantPaymentId(long merchantPaymentId) {
13153
      this.merchantPaymentId = merchantPaymentId;
13154
      setMerchantPaymentIdIsSet(true);
13155
    }
13156
 
13157
    public void unsetMerchantPaymentId() {
13158
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
13159
    }
13160
 
13161
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
13162
    public boolean isSetMerchantPaymentId() {
13163
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
13164
    }
13165
 
13166
    public void setMerchantPaymentIdIsSet(boolean value) {
13167
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
13168
    }
13169
 
13170
    public void setFieldValue(_Fields field, Object value) {
13171
      switch (field) {
13172
      case MERCHANT_PAYMENT_ID:
13173
        if (value == null) {
13174
          unsetMerchantPaymentId();
13175
        } else {
13176
          setMerchantPaymentId((Long)value);
13177
        }
13178
        break;
13179
 
13180
      }
13181
    }
13182
 
13183
    public Object getFieldValue(_Fields field) {
13184
      switch (field) {
13185
      case MERCHANT_PAYMENT_ID:
13186
        return Long.valueOf(getMerchantPaymentId());
13187
 
13188
      }
13189
      throw new IllegalStateException();
13190
    }
13191
 
13192
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13193
    public boolean isSet(_Fields field) {
13194
      if (field == null) {
13195
        throw new IllegalArgumentException();
13196
      }
13197
 
13198
      switch (field) {
13199
      case MERCHANT_PAYMENT_ID:
13200
        return isSetMerchantPaymentId();
13201
      }
13202
      throw new IllegalStateException();
13203
    }
13204
 
13205
    @Override
13206
    public boolean equals(Object that) {
13207
      if (that == null)
13208
        return false;
13209
      if (that instanceof initializeHdfcEmiPayment_args)
13210
        return this.equals((initializeHdfcEmiPayment_args)that);
13211
      return false;
13212
    }
13213
 
13214
    public boolean equals(initializeHdfcEmiPayment_args that) {
13215
      if (that == null)
13216
        return false;
13217
 
13218
      boolean this_present_merchantPaymentId = true;
13219
      boolean that_present_merchantPaymentId = true;
13220
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
13221
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
13222
          return false;
13223
        if (this.merchantPaymentId != that.merchantPaymentId)
13224
          return false;
13225
      }
13226
 
13227
      return true;
13228
    }
13229
 
13230
    @Override
13231
    public int hashCode() {
13232
      return 0;
13233
    }
13234
 
13235
    public int compareTo(initializeHdfcEmiPayment_args other) {
13236
      if (!getClass().equals(other.getClass())) {
13237
        return getClass().getName().compareTo(other.getClass().getName());
13238
      }
13239
 
13240
      int lastComparison = 0;
13241
      initializeHdfcEmiPayment_args typedOther = (initializeHdfcEmiPayment_args)other;
13242
 
13243
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
13244
      if (lastComparison != 0) {
13245
        return lastComparison;
13246
      }
13247
      if (isSetMerchantPaymentId()) {
13248
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
13249
        if (lastComparison != 0) {
13250
          return lastComparison;
13251
        }
13252
      }
13253
      return 0;
13254
    }
13255
 
13256
    public _Fields fieldForId(int fieldId) {
13257
      return _Fields.findByThriftId(fieldId);
13258
    }
13259
 
13260
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13261
      org.apache.thrift.protocol.TField field;
13262
      iprot.readStructBegin();
13263
      while (true)
13264
      {
13265
        field = iprot.readFieldBegin();
13266
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13267
          break;
13268
        }
13269
        switch (field.id) {
13270
          case 1: // MERCHANT_PAYMENT_ID
13271
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13272
              this.merchantPaymentId = iprot.readI64();
13273
              setMerchantPaymentIdIsSet(true);
13274
            } else { 
13275
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13276
            }
13277
            break;
13278
          default:
13279
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13280
        }
13281
        iprot.readFieldEnd();
13282
      }
13283
      iprot.readStructEnd();
13284
      validate();
13285
    }
13286
 
13287
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13288
      validate();
13289
 
13290
      oprot.writeStructBegin(STRUCT_DESC);
13291
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
13292
      oprot.writeI64(this.merchantPaymentId);
13293
      oprot.writeFieldEnd();
13294
      oprot.writeFieldStop();
13295
      oprot.writeStructEnd();
13296
    }
13297
 
13298
    @Override
13299
    public String toString() {
13300
      StringBuilder sb = new StringBuilder("initializeHdfcEmiPayment_args(");
13301
      boolean first = true;
13302
 
13303
      sb.append("merchantPaymentId:");
13304
      sb.append(this.merchantPaymentId);
13305
      first = false;
13306
      sb.append(")");
13307
      return sb.toString();
13308
    }
13309
 
13310
    public void validate() throws org.apache.thrift.TException {
13311
      // check for required fields
13312
    }
13313
 
13314
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13315
      try {
13316
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13317
      } catch (org.apache.thrift.TException te) {
13318
        throw new java.io.IOException(te);
13319
      }
13320
    }
13321
 
13322
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13323
      try {
13324
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13325
      } catch (org.apache.thrift.TException te) {
13326
        throw new java.io.IOException(te);
13327
      }
13328
    }
13329
 
13330
  }
13331
 
13332
  public static class initializeHdfcEmiPayment_result implements org.apache.thrift.TBase<initializeHdfcEmiPayment_result, initializeHdfcEmiPayment_result._Fields>, java.io.Serializable, Cloneable   {
13333
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcEmiPayment_result");
13334
 
13335
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRING, (short)0);
13336
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
13337
 
13338
    private String success; // required
13339
    private PaymentException pe; // required
13340
 
13341
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13342
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13343
      SUCCESS((short)0, "success"),
13344
      PE((short)1, "pe");
13345
 
13346
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13347
 
13348
      static {
13349
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13350
          byName.put(field.getFieldName(), field);
13351
        }
13352
      }
13353
 
13354
      /**
13355
       * Find the _Fields constant that matches fieldId, or null if its not found.
13356
       */
13357
      public static _Fields findByThriftId(int fieldId) {
13358
        switch(fieldId) {
13359
          case 0: // SUCCESS
13360
            return SUCCESS;
13361
          case 1: // PE
13362
            return PE;
13363
          default:
13364
            return null;
13365
        }
13366
      }
13367
 
13368
      /**
13369
       * Find the _Fields constant that matches fieldId, throwing an exception
13370
       * if it is not found.
13371
       */
13372
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13373
        _Fields fields = findByThriftId(fieldId);
13374
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13375
        return fields;
13376
      }
13377
 
13378
      /**
13379
       * Find the _Fields constant that matches name, or null if its not found.
13380
       */
13381
      public static _Fields findByName(String name) {
13382
        return byName.get(name);
13383
      }
13384
 
13385
      private final short _thriftId;
13386
      private final String _fieldName;
13387
 
13388
      _Fields(short thriftId, String fieldName) {
13389
        _thriftId = thriftId;
13390
        _fieldName = fieldName;
13391
      }
13392
 
13393
      public short getThriftFieldId() {
13394
        return _thriftId;
13395
      }
13396
 
13397
      public String getFieldName() {
13398
        return _fieldName;
13399
      }
13400
    }
13401
 
13402
    // isset id assignments
13403
 
13404
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13405
    static {
13406
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13407
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13408
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
13409
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13410
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
13411
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13412
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcEmiPayment_result.class, metaDataMap);
13413
    }
13414
 
13415
    public initializeHdfcEmiPayment_result() {
13416
    }
13417
 
13418
    public initializeHdfcEmiPayment_result(
13419
      String success,
13420
      PaymentException pe)
13421
    {
13422
      this();
13423
      this.success = success;
13424
      this.pe = pe;
13425
    }
13426
 
13427
    /**
13428
     * Performs a deep copy on <i>other</i>.
13429
     */
13430
    public initializeHdfcEmiPayment_result(initializeHdfcEmiPayment_result other) {
13431
      if (other.isSetSuccess()) {
13432
        this.success = other.success;
13433
      }
13434
      if (other.isSetPe()) {
13435
        this.pe = new PaymentException(other.pe);
13436
      }
13437
    }
13438
 
13439
    public initializeHdfcEmiPayment_result deepCopy() {
13440
      return new initializeHdfcEmiPayment_result(this);
13441
    }
13442
 
13443
    @Override
13444
    public void clear() {
13445
      this.success = null;
13446
      this.pe = null;
13447
    }
13448
 
13449
    public String getSuccess() {
13450
      return this.success;
13451
    }
13452
 
13453
    public void setSuccess(String success) {
13454
      this.success = success;
13455
    }
13456
 
13457
    public void unsetSuccess() {
13458
      this.success = null;
13459
    }
13460
 
13461
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13462
    public boolean isSetSuccess() {
13463
      return this.success != null;
13464
    }
13465
 
13466
    public void setSuccessIsSet(boolean value) {
13467
      if (!value) {
13468
        this.success = null;
13469
      }
13470
    }
13471
 
13472
    public PaymentException getPe() {
13473
      return this.pe;
13474
    }
13475
 
13476
    public void setPe(PaymentException pe) {
13477
      this.pe = pe;
13478
    }
13479
 
13480
    public void unsetPe() {
13481
      this.pe = null;
13482
    }
13483
 
13484
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
13485
    public boolean isSetPe() {
13486
      return this.pe != null;
13487
    }
13488
 
13489
    public void setPeIsSet(boolean value) {
13490
      if (!value) {
13491
        this.pe = null;
13492
      }
13493
    }
13494
 
13495
    public void setFieldValue(_Fields field, Object value) {
13496
      switch (field) {
13497
      case SUCCESS:
13498
        if (value == null) {
13499
          unsetSuccess();
13500
        } else {
13501
          setSuccess((String)value);
13502
        }
13503
        break;
13504
 
13505
      case PE:
13506
        if (value == null) {
13507
          unsetPe();
13508
        } else {
13509
          setPe((PaymentException)value);
13510
        }
13511
        break;
13512
 
13513
      }
13514
    }
13515
 
13516
    public Object getFieldValue(_Fields field) {
13517
      switch (field) {
13518
      case SUCCESS:
13519
        return getSuccess();
13520
 
13521
      case PE:
13522
        return getPe();
13523
 
13524
      }
13525
      throw new IllegalStateException();
13526
    }
13527
 
13528
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13529
    public boolean isSet(_Fields field) {
13530
      if (field == null) {
13531
        throw new IllegalArgumentException();
13532
      }
13533
 
13534
      switch (field) {
13535
      case SUCCESS:
13536
        return isSetSuccess();
13537
      case PE:
13538
        return isSetPe();
13539
      }
13540
      throw new IllegalStateException();
13541
    }
13542
 
13543
    @Override
13544
    public boolean equals(Object that) {
13545
      if (that == null)
13546
        return false;
13547
      if (that instanceof initializeHdfcEmiPayment_result)
13548
        return this.equals((initializeHdfcEmiPayment_result)that);
13549
      return false;
13550
    }
13551
 
13552
    public boolean equals(initializeHdfcEmiPayment_result that) {
13553
      if (that == null)
13554
        return false;
13555
 
13556
      boolean this_present_success = true && this.isSetSuccess();
13557
      boolean that_present_success = true && that.isSetSuccess();
13558
      if (this_present_success || that_present_success) {
13559
        if (!(this_present_success && that_present_success))
13560
          return false;
13561
        if (!this.success.equals(that.success))
13562
          return false;
13563
      }
13564
 
13565
      boolean this_present_pe = true && this.isSetPe();
13566
      boolean that_present_pe = true && that.isSetPe();
13567
      if (this_present_pe || that_present_pe) {
13568
        if (!(this_present_pe && that_present_pe))
13569
          return false;
13570
        if (!this.pe.equals(that.pe))
13571
          return false;
13572
      }
13573
 
13574
      return true;
13575
    }
13576
 
13577
    @Override
13578
    public int hashCode() {
13579
      return 0;
13580
    }
13581
 
13582
    public int compareTo(initializeHdfcEmiPayment_result other) {
13583
      if (!getClass().equals(other.getClass())) {
13584
        return getClass().getName().compareTo(other.getClass().getName());
13585
      }
13586
 
13587
      int lastComparison = 0;
13588
      initializeHdfcEmiPayment_result typedOther = (initializeHdfcEmiPayment_result)other;
13589
 
13590
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13591
      if (lastComparison != 0) {
13592
        return lastComparison;
13593
      }
13594
      if (isSetSuccess()) {
13595
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13596
        if (lastComparison != 0) {
13597
          return lastComparison;
13598
        }
13599
      }
13600
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
13601
      if (lastComparison != 0) {
13602
        return lastComparison;
13603
      }
13604
      if (isSetPe()) {
13605
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
13606
        if (lastComparison != 0) {
13607
          return lastComparison;
13608
        }
13609
      }
13610
      return 0;
13611
    }
13612
 
13613
    public _Fields fieldForId(int fieldId) {
13614
      return _Fields.findByThriftId(fieldId);
13615
    }
13616
 
13617
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13618
      org.apache.thrift.protocol.TField field;
13619
      iprot.readStructBegin();
13620
      while (true)
13621
      {
13622
        field = iprot.readFieldBegin();
13623
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13624
          break;
13625
        }
13626
        switch (field.id) {
13627
          case 0: // SUCCESS
13628
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
13629
              this.success = iprot.readString();
13630
            } else { 
13631
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13632
            }
13633
            break;
13634
          case 1: // PE
13635
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13636
              this.pe = new PaymentException();
13637
              this.pe.read(iprot);
13638
            } else { 
13639
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13640
            }
13641
            break;
13642
          default:
13643
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13644
        }
13645
        iprot.readFieldEnd();
13646
      }
13647
      iprot.readStructEnd();
13648
      validate();
13649
    }
13650
 
13651
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13652
      oprot.writeStructBegin(STRUCT_DESC);
13653
 
13654
      if (this.isSetSuccess()) {
13655
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13656
        oprot.writeString(this.success);
13657
        oprot.writeFieldEnd();
13658
      } else if (this.isSetPe()) {
13659
        oprot.writeFieldBegin(PE_FIELD_DESC);
13660
        this.pe.write(oprot);
13661
        oprot.writeFieldEnd();
13662
      }
13663
      oprot.writeFieldStop();
13664
      oprot.writeStructEnd();
13665
    }
13666
 
13667
    @Override
13668
    public String toString() {
13669
      StringBuilder sb = new StringBuilder("initializeHdfcEmiPayment_result(");
13670
      boolean first = true;
13671
 
13672
      sb.append("success:");
13673
      if (this.success == null) {
13674
        sb.append("null");
13675
      } else {
13676
        sb.append(this.success);
13677
      }
13678
      first = false;
13679
      if (!first) sb.append(", ");
13680
      sb.append("pe:");
13681
      if (this.pe == null) {
13682
        sb.append("null");
13683
      } else {
13684
        sb.append(this.pe);
13685
      }
13686
      first = false;
13687
      sb.append(")");
13688
      return sb.toString();
13689
    }
13690
 
13691
    public void validate() throws org.apache.thrift.TException {
13692
      // check for required fields
13693
    }
13694
 
13695
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13696
      try {
13697
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13698
      } catch (org.apache.thrift.TException te) {
13699
        throw new java.io.IOException(te);
13700
      }
13701
    }
13702
 
13703
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13704
      try {
13705
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13706
      } catch (org.apache.thrift.TException te) {
13707
        throw new java.io.IOException(te);
13708
      }
13709
    }
13710
 
13711
  }
13712
 
3430 rajveer 13713
  public static class createRefund_args implements org.apache.thrift.TBase<createRefund_args, createRefund_args._Fields>, java.io.Serializable, Cloneable   {
13714
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createRefund_args");
2462 chandransh 13715
 
3430 rajveer 13716
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)1);
13717
    private static final org.apache.thrift.protocol.TField MERCHANT_TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantTxnId", org.apache.thrift.protocol.TType.I64, (short)2);
13718
    private static final org.apache.thrift.protocol.TField AMOUNT_FIELD_DESC = new org.apache.thrift.protocol.TField("amount", org.apache.thrift.protocol.TType.DOUBLE, (short)3);
2462 chandransh 13719
 
3430 rajveer 13720
    private long orderId; // required
13721
    private long merchantTxnId; // required
13722
    private double amount; // required
2462 chandransh 13723
 
13724
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 13725
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3010 chandransh 13726
      ORDER_ID((short)1, "orderId"),
13727
      MERCHANT_TXN_ID((short)2, "merchantTxnId"),
13728
      AMOUNT((short)3, "amount");
2462 chandransh 13729
 
13730
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13731
 
13732
      static {
13733
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13734
          byName.put(field.getFieldName(), field);
13735
        }
13736
      }
13737
 
13738
      /**
13739
       * Find the _Fields constant that matches fieldId, or null if its not found.
13740
       */
13741
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 13742
        switch(fieldId) {
13743
          case 1: // ORDER_ID
13744
            return ORDER_ID;
13745
          case 2: // MERCHANT_TXN_ID
13746
            return MERCHANT_TXN_ID;
13747
          case 3: // AMOUNT
13748
            return AMOUNT;
13749
          default:
13750
            return null;
13751
        }
2462 chandransh 13752
      }
13753
 
13754
      /**
13755
       * Find the _Fields constant that matches fieldId, throwing an exception
13756
       * if it is not found.
13757
       */
13758
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13759
        _Fields fields = findByThriftId(fieldId);
13760
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13761
        return fields;
13762
      }
13763
 
13764
      /**
13765
       * Find the _Fields constant that matches name, or null if its not found.
13766
       */
13767
      public static _Fields findByName(String name) {
13768
        return byName.get(name);
13769
      }
13770
 
13771
      private final short _thriftId;
13772
      private final String _fieldName;
13773
 
13774
      _Fields(short thriftId, String fieldName) {
13775
        _thriftId = thriftId;
13776
        _fieldName = fieldName;
13777
      }
13778
 
13779
      public short getThriftFieldId() {
13780
        return _thriftId;
13781
      }
13782
 
13783
      public String getFieldName() {
13784
        return _fieldName;
13785
      }
13786
    }
13787
 
13788
    // isset id assignments
3010 chandransh 13789
    private static final int __ORDERID_ISSET_ID = 0;
13790
    private static final int __MERCHANTTXNID_ISSET_ID = 1;
13791
    private static final int __AMOUNT_ISSET_ID = 2;
13792
    private BitSet __isset_bit_vector = new BitSet(3);
2462 chandransh 13793
 
3430 rajveer 13794
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 13795
    static {
3430 rajveer 13796
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13797
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13798
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13799
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13800
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13801
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13802
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
13803
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13804
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createRefund_args.class, metaDataMap);
2462 chandransh 13805
    }
13806
 
3010 chandransh 13807
    public createRefund_args() {
2462 chandransh 13808
    }
13809
 
3010 chandransh 13810
    public createRefund_args(
13811
      long orderId,
13812
      long merchantTxnId,
13813
      double amount)
2462 chandransh 13814
    {
13815
      this();
3010 chandransh 13816
      this.orderId = orderId;
13817
      setOrderIdIsSet(true);
13818
      this.merchantTxnId = merchantTxnId;
13819
      setMerchantTxnIdIsSet(true);
13820
      this.amount = amount;
13821
      setAmountIsSet(true);
2462 chandransh 13822
    }
13823
 
13824
    /**
13825
     * Performs a deep copy on <i>other</i>.
13826
     */
3010 chandransh 13827
    public createRefund_args(createRefund_args other) {
2462 chandransh 13828
      __isset_bit_vector.clear();
13829
      __isset_bit_vector.or(other.__isset_bit_vector);
3010 chandransh 13830
      this.orderId = other.orderId;
13831
      this.merchantTxnId = other.merchantTxnId;
13832
      this.amount = other.amount;
2462 chandransh 13833
    }
13834
 
3010 chandransh 13835
    public createRefund_args deepCopy() {
13836
      return new createRefund_args(this);
2462 chandransh 13837
    }
13838
 
3430 rajveer 13839
    @Override
13840
    public void clear() {
13841
      setOrderIdIsSet(false);
13842
      this.orderId = 0;
13843
      setMerchantTxnIdIsSet(false);
13844
      this.merchantTxnId = 0;
13845
      setAmountIsSet(false);
13846
      this.amount = 0.0;
2462 chandransh 13847
    }
13848
 
3010 chandransh 13849
    public long getOrderId() {
13850
      return this.orderId;
2462 chandransh 13851
    }
13852
 
3430 rajveer 13853
    public void setOrderId(long orderId) {
3010 chandransh 13854
      this.orderId = orderId;
13855
      setOrderIdIsSet(true);
2462 chandransh 13856
    }
13857
 
3010 chandransh 13858
    public void unsetOrderId() {
13859
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
2462 chandransh 13860
    }
13861
 
3430 rajveer 13862
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
3010 chandransh 13863
    public boolean isSetOrderId() {
13864
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
2462 chandransh 13865
    }
13866
 
3010 chandransh 13867
    public void setOrderIdIsSet(boolean value) {
13868
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
2462 chandransh 13869
    }
13870
 
3010 chandransh 13871
    public long getMerchantTxnId() {
13872
      return this.merchantTxnId;
13873
    }
13874
 
3430 rajveer 13875
    public void setMerchantTxnId(long merchantTxnId) {
3010 chandransh 13876
      this.merchantTxnId = merchantTxnId;
13877
      setMerchantTxnIdIsSet(true);
13878
    }
13879
 
13880
    public void unsetMerchantTxnId() {
13881
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
13882
    }
13883
 
3430 rajveer 13884
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
3010 chandransh 13885
    public boolean isSetMerchantTxnId() {
13886
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
13887
    }
13888
 
13889
    public void setMerchantTxnIdIsSet(boolean value) {
13890
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
13891
    }
13892
 
13893
    public double getAmount() {
13894
      return this.amount;
13895
    }
13896
 
3430 rajveer 13897
    public void setAmount(double amount) {
3010 chandransh 13898
      this.amount = amount;
13899
      setAmountIsSet(true);
13900
    }
13901
 
13902
    public void unsetAmount() {
13903
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
13904
    }
13905
 
3430 rajveer 13906
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
3010 chandransh 13907
    public boolean isSetAmount() {
13908
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
13909
    }
13910
 
13911
    public void setAmountIsSet(boolean value) {
13912
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
13913
    }
13914
 
2462 chandransh 13915
    public void setFieldValue(_Fields field, Object value) {
13916
      switch (field) {
3010 chandransh 13917
      case ORDER_ID:
2462 chandransh 13918
        if (value == null) {
3010 chandransh 13919
          unsetOrderId();
2462 chandransh 13920
        } else {
3010 chandransh 13921
          setOrderId((Long)value);
2462 chandransh 13922
        }
13923
        break;
13924
 
3010 chandransh 13925
      case MERCHANT_TXN_ID:
13926
        if (value == null) {
13927
          unsetMerchantTxnId();
13928
        } else {
13929
          setMerchantTxnId((Long)value);
13930
        }
13931
        break;
13932
 
13933
      case AMOUNT:
13934
        if (value == null) {
13935
          unsetAmount();
13936
        } else {
13937
          setAmount((Double)value);
13938
        }
13939
        break;
13940
 
2462 chandransh 13941
      }
13942
    }
13943
 
13944
    public Object getFieldValue(_Fields field) {
13945
      switch (field) {
3010 chandransh 13946
      case ORDER_ID:
3430 rajveer 13947
        return Long.valueOf(getOrderId());
2462 chandransh 13948
 
3010 chandransh 13949
      case MERCHANT_TXN_ID:
3430 rajveer 13950
        return Long.valueOf(getMerchantTxnId());
3010 chandransh 13951
 
13952
      case AMOUNT:
3430 rajveer 13953
        return Double.valueOf(getAmount());
3010 chandransh 13954
 
2462 chandransh 13955
      }
13956
      throw new IllegalStateException();
13957
    }
13958
 
3430 rajveer 13959
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13960
    public boolean isSet(_Fields field) {
13961
      if (field == null) {
13962
        throw new IllegalArgumentException();
13963
      }
2462 chandransh 13964
 
13965
      switch (field) {
3010 chandransh 13966
      case ORDER_ID:
13967
        return isSetOrderId();
13968
      case MERCHANT_TXN_ID:
13969
        return isSetMerchantTxnId();
13970
      case AMOUNT:
13971
        return isSetAmount();
2462 chandransh 13972
      }
13973
      throw new IllegalStateException();
13974
    }
13975
 
13976
    @Override
13977
    public boolean equals(Object that) {
13978
      if (that == null)
13979
        return false;
3010 chandransh 13980
      if (that instanceof createRefund_args)
13981
        return this.equals((createRefund_args)that);
2462 chandransh 13982
      return false;
13983
    }
13984
 
3010 chandransh 13985
    public boolean equals(createRefund_args that) {
2462 chandransh 13986
      if (that == null)
13987
        return false;
13988
 
3010 chandransh 13989
      boolean this_present_orderId = true;
13990
      boolean that_present_orderId = true;
13991
      if (this_present_orderId || that_present_orderId) {
13992
        if (!(this_present_orderId && that_present_orderId))
2462 chandransh 13993
          return false;
3010 chandransh 13994
        if (this.orderId != that.orderId)
2462 chandransh 13995
          return false;
13996
      }
13997
 
3010 chandransh 13998
      boolean this_present_merchantTxnId = true;
13999
      boolean that_present_merchantTxnId = true;
14000
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
14001
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
14002
          return false;
14003
        if (this.merchantTxnId != that.merchantTxnId)
14004
          return false;
14005
      }
14006
 
14007
      boolean this_present_amount = true;
14008
      boolean that_present_amount = true;
14009
      if (this_present_amount || that_present_amount) {
14010
        if (!(this_present_amount && that_present_amount))
14011
          return false;
14012
        if (this.amount != that.amount)
14013
          return false;
14014
      }
14015
 
2462 chandransh 14016
      return true;
14017
    }
14018
 
14019
    @Override
14020
    public int hashCode() {
14021
      return 0;
14022
    }
14023
 
3010 chandransh 14024
    public int compareTo(createRefund_args other) {
2462 chandransh 14025
      if (!getClass().equals(other.getClass())) {
14026
        return getClass().getName().compareTo(other.getClass().getName());
14027
      }
14028
 
14029
      int lastComparison = 0;
3010 chandransh 14030
      createRefund_args typedOther = (createRefund_args)other;
2462 chandransh 14031
 
3430 rajveer 14032
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
2462 chandransh 14033
      if (lastComparison != 0) {
14034
        return lastComparison;
14035
      }
3430 rajveer 14036
      if (isSetOrderId()) {
14037
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
14038
        if (lastComparison != 0) {
14039
          return lastComparison;
14040
        }
2462 chandransh 14041
      }
3430 rajveer 14042
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
3010 chandransh 14043
      if (lastComparison != 0) {
14044
        return lastComparison;
14045
      }
3430 rajveer 14046
      if (isSetMerchantTxnId()) {
14047
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
14048
        if (lastComparison != 0) {
14049
          return lastComparison;
14050
        }
3010 chandransh 14051
      }
3430 rajveer 14052
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
3010 chandransh 14053
      if (lastComparison != 0) {
14054
        return lastComparison;
14055
      }
3430 rajveer 14056
      if (isSetAmount()) {
14057
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
14058
        if (lastComparison != 0) {
14059
          return lastComparison;
14060
        }
3010 chandransh 14061
      }
2462 chandransh 14062
      return 0;
14063
    }
14064
 
3430 rajveer 14065
    public _Fields fieldForId(int fieldId) {
14066
      return _Fields.findByThriftId(fieldId);
14067
    }
14068
 
14069
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14070
      org.apache.thrift.protocol.TField field;
2462 chandransh 14071
      iprot.readStructBegin();
14072
      while (true)
14073
      {
14074
        field = iprot.readFieldBegin();
3430 rajveer 14075
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 14076
          break;
14077
        }
3430 rajveer 14078
        switch (field.id) {
14079
          case 1: // ORDER_ID
14080
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14081
              this.orderId = iprot.readI64();
14082
              setOrderIdIsSet(true);
14083
            } else { 
14084
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14085
            }
14086
            break;
14087
          case 2: // MERCHANT_TXN_ID
14088
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14089
              this.merchantTxnId = iprot.readI64();
14090
              setMerchantTxnIdIsSet(true);
14091
            } else { 
14092
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14093
            }
14094
            break;
14095
          case 3: // AMOUNT
14096
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
14097
              this.amount = iprot.readDouble();
14098
              setAmountIsSet(true);
14099
            } else { 
14100
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14101
            }
14102
            break;
14103
          default:
14104
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 14105
        }
3430 rajveer 14106
        iprot.readFieldEnd();
2462 chandransh 14107
      }
14108
      iprot.readStructEnd();
14109
      validate();
14110
    }
14111
 
3430 rajveer 14112
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 14113
      validate();
14114
 
14115
      oprot.writeStructBegin(STRUCT_DESC);
3010 chandransh 14116
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
14117
      oprot.writeI64(this.orderId);
2462 chandransh 14118
      oprot.writeFieldEnd();
3010 chandransh 14119
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
14120
      oprot.writeI64(this.merchantTxnId);
14121
      oprot.writeFieldEnd();
14122
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
14123
      oprot.writeDouble(this.amount);
14124
      oprot.writeFieldEnd();
2462 chandransh 14125
      oprot.writeFieldStop();
14126
      oprot.writeStructEnd();
14127
    }
14128
 
14129
    @Override
14130
    public String toString() {
3010 chandransh 14131
      StringBuilder sb = new StringBuilder("createRefund_args(");
2462 chandransh 14132
      boolean first = true;
14133
 
3010 chandransh 14134
      sb.append("orderId:");
14135
      sb.append(this.orderId);
2462 chandransh 14136
      first = false;
3010 chandransh 14137
      if (!first) sb.append(", ");
14138
      sb.append("merchantTxnId:");
14139
      sb.append(this.merchantTxnId);
14140
      first = false;
14141
      if (!first) sb.append(", ");
14142
      sb.append("amount:");
14143
      sb.append(this.amount);
14144
      first = false;
2462 chandransh 14145
      sb.append(")");
14146
      return sb.toString();
14147
    }
14148
 
3430 rajveer 14149
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 14150
      // check for required fields
14151
    }
14152
 
3430 rajveer 14153
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14154
      try {
14155
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14156
      } catch (org.apache.thrift.TException te) {
14157
        throw new java.io.IOException(te);
14158
      }
14159
    }
14160
 
14161
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14162
      try {
14163
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14164
      } catch (org.apache.thrift.TException te) {
14165
        throw new java.io.IOException(te);
14166
      }
14167
    }
14168
 
2462 chandransh 14169
  }
14170
 
3430 rajveer 14171
  public static class createRefund_result implements org.apache.thrift.TBase<createRefund_result, createRefund_result._Fields>, java.io.Serializable, Cloneable   {
14172
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createRefund_result");
2462 chandransh 14173
 
3430 rajveer 14174
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I64, (short)0);
14175
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2462 chandransh 14176
 
3430 rajveer 14177
    private long success; // required
14178
    private PaymentException pe; // required
2462 chandransh 14179
 
14180
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 14181
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 14182
      SUCCESS((short)0, "success"),
14183
      PE((short)1, "pe");
14184
 
14185
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14186
 
14187
      static {
14188
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14189
          byName.put(field.getFieldName(), field);
14190
        }
14191
      }
14192
 
14193
      /**
14194
       * Find the _Fields constant that matches fieldId, or null if its not found.
14195
       */
14196
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 14197
        switch(fieldId) {
14198
          case 0: // SUCCESS
14199
            return SUCCESS;
14200
          case 1: // PE
14201
            return PE;
14202
          default:
14203
            return null;
14204
        }
2462 chandransh 14205
      }
14206
 
14207
      /**
14208
       * Find the _Fields constant that matches fieldId, throwing an exception
14209
       * if it is not found.
14210
       */
14211
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14212
        _Fields fields = findByThriftId(fieldId);
14213
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14214
        return fields;
14215
      }
14216
 
14217
      /**
14218
       * Find the _Fields constant that matches name, or null if its not found.
14219
       */
14220
      public static _Fields findByName(String name) {
14221
        return byName.get(name);
14222
      }
14223
 
14224
      private final short _thriftId;
14225
      private final String _fieldName;
14226
 
14227
      _Fields(short thriftId, String fieldName) {
14228
        _thriftId = thriftId;
14229
        _fieldName = fieldName;
14230
      }
14231
 
14232
      public short getThriftFieldId() {
14233
        return _thriftId;
14234
      }
14235
 
14236
      public String getFieldName() {
14237
        return _fieldName;
14238
      }
14239
    }
14240
 
14241
    // isset id assignments
3010 chandransh 14242
    private static final int __SUCCESS_ISSET_ID = 0;
14243
    private BitSet __isset_bit_vector = new BitSet(1);
2462 chandransh 14244
 
3430 rajveer 14245
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 14246
    static {
3430 rajveer 14247
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14248
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14249
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14250
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14251
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14252
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14253
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createRefund_result.class, metaDataMap);
2462 chandransh 14254
    }
14255
 
3010 chandransh 14256
    public createRefund_result() {
2462 chandransh 14257
    }
14258
 
3010 chandransh 14259
    public createRefund_result(
14260
      long success,
2462 chandransh 14261
      PaymentException pe)
14262
    {
14263
      this();
14264
      this.success = success;
3010 chandransh 14265
      setSuccessIsSet(true);
2462 chandransh 14266
      this.pe = pe;
14267
    }
14268
 
14269
    /**
14270
     * Performs a deep copy on <i>other</i>.
14271
     */
3010 chandransh 14272
    public createRefund_result(createRefund_result other) {
14273
      __isset_bit_vector.clear();
14274
      __isset_bit_vector.or(other.__isset_bit_vector);
14275
      this.success = other.success;
2462 chandransh 14276
      if (other.isSetPe()) {
14277
        this.pe = new PaymentException(other.pe);
14278
      }
14279
    }
14280
 
3010 chandransh 14281
    public createRefund_result deepCopy() {
14282
      return new createRefund_result(this);
2462 chandransh 14283
    }
14284
 
3430 rajveer 14285
    @Override
14286
    public void clear() {
14287
      setSuccessIsSet(false);
14288
      this.success = 0;
14289
      this.pe = null;
2462 chandransh 14290
    }
14291
 
3010 chandransh 14292
    public long getSuccess() {
2462 chandransh 14293
      return this.success;
14294
    }
14295
 
3430 rajveer 14296
    public void setSuccess(long success) {
2462 chandransh 14297
      this.success = success;
3010 chandransh 14298
      setSuccessIsSet(true);
2462 chandransh 14299
    }
14300
 
14301
    public void unsetSuccess() {
3010 chandransh 14302
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
2462 chandransh 14303
    }
14304
 
3430 rajveer 14305
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2462 chandransh 14306
    public boolean isSetSuccess() {
3010 chandransh 14307
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
2462 chandransh 14308
    }
14309
 
14310
    public void setSuccessIsSet(boolean value) {
3010 chandransh 14311
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
2462 chandransh 14312
    }
14313
 
14314
    public PaymentException getPe() {
14315
      return this.pe;
14316
    }
14317
 
3430 rajveer 14318
    public void setPe(PaymentException pe) {
2462 chandransh 14319
      this.pe = pe;
14320
    }
14321
 
14322
    public void unsetPe() {
14323
      this.pe = null;
14324
    }
14325
 
3430 rajveer 14326
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2462 chandransh 14327
    public boolean isSetPe() {
14328
      return this.pe != null;
14329
    }
14330
 
14331
    public void setPeIsSet(boolean value) {
14332
      if (!value) {
14333
        this.pe = null;
14334
      }
14335
    }
14336
 
14337
    public void setFieldValue(_Fields field, Object value) {
14338
      switch (field) {
14339
      case SUCCESS:
14340
        if (value == null) {
14341
          unsetSuccess();
14342
        } else {
3010 chandransh 14343
          setSuccess((Long)value);
2462 chandransh 14344
        }
14345
        break;
14346
 
14347
      case PE:
14348
        if (value == null) {
14349
          unsetPe();
14350
        } else {
14351
          setPe((PaymentException)value);
14352
        }
14353
        break;
14354
 
14355
      }
14356
    }
14357
 
14358
    public Object getFieldValue(_Fields field) {
14359
      switch (field) {
14360
      case SUCCESS:
3430 rajveer 14361
        return Long.valueOf(getSuccess());
2462 chandransh 14362
 
14363
      case PE:
14364
        return getPe();
14365
 
14366
      }
14367
      throw new IllegalStateException();
14368
    }
14369
 
3430 rajveer 14370
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14371
    public boolean isSet(_Fields field) {
14372
      if (field == null) {
14373
        throw new IllegalArgumentException();
14374
      }
2462 chandransh 14375
 
14376
      switch (field) {
14377
      case SUCCESS:
14378
        return isSetSuccess();
14379
      case PE:
14380
        return isSetPe();
14381
      }
14382
      throw new IllegalStateException();
14383
    }
14384
 
14385
    @Override
14386
    public boolean equals(Object that) {
14387
      if (that == null)
14388
        return false;
3010 chandransh 14389
      if (that instanceof createRefund_result)
14390
        return this.equals((createRefund_result)that);
2462 chandransh 14391
      return false;
14392
    }
14393
 
3010 chandransh 14394
    public boolean equals(createRefund_result that) {
2462 chandransh 14395
      if (that == null)
14396
        return false;
14397
 
3010 chandransh 14398
      boolean this_present_success = true;
14399
      boolean that_present_success = true;
2462 chandransh 14400
      if (this_present_success || that_present_success) {
14401
        if (!(this_present_success && that_present_success))
14402
          return false;
3010 chandransh 14403
        if (this.success != that.success)
2462 chandransh 14404
          return false;
14405
      }
14406
 
14407
      boolean this_present_pe = true && this.isSetPe();
14408
      boolean that_present_pe = true && that.isSetPe();
14409
      if (this_present_pe || that_present_pe) {
14410
        if (!(this_present_pe && that_present_pe))
14411
          return false;
14412
        if (!this.pe.equals(that.pe))
14413
          return false;
14414
      }
14415
 
14416
      return true;
14417
    }
14418
 
14419
    @Override
14420
    public int hashCode() {
14421
      return 0;
14422
    }
14423
 
3010 chandransh 14424
    public int compareTo(createRefund_result other) {
2462 chandransh 14425
      if (!getClass().equals(other.getClass())) {
14426
        return getClass().getName().compareTo(other.getClass().getName());
14427
      }
14428
 
14429
      int lastComparison = 0;
3010 chandransh 14430
      createRefund_result typedOther = (createRefund_result)other;
2462 chandransh 14431
 
3430 rajveer 14432
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2462 chandransh 14433
      if (lastComparison != 0) {
14434
        return lastComparison;
14435
      }
3430 rajveer 14436
      if (isSetSuccess()) {
14437
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14438
        if (lastComparison != 0) {
14439
          return lastComparison;
14440
        }
2462 chandransh 14441
      }
3430 rajveer 14442
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
2462 chandransh 14443
      if (lastComparison != 0) {
14444
        return lastComparison;
14445
      }
3430 rajveer 14446
      if (isSetPe()) {
14447
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
14448
        if (lastComparison != 0) {
14449
          return lastComparison;
14450
        }
2462 chandransh 14451
      }
14452
      return 0;
14453
    }
14454
 
3430 rajveer 14455
    public _Fields fieldForId(int fieldId) {
14456
      return _Fields.findByThriftId(fieldId);
14457
    }
14458
 
14459
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14460
      org.apache.thrift.protocol.TField field;
2462 chandransh 14461
      iprot.readStructBegin();
14462
      while (true)
14463
      {
14464
        field = iprot.readFieldBegin();
3430 rajveer 14465
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 14466
          break;
14467
        }
3430 rajveer 14468
        switch (field.id) {
14469
          case 0: // SUCCESS
14470
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14471
              this.success = iprot.readI64();
14472
              setSuccessIsSet(true);
14473
            } else { 
14474
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14475
            }
14476
            break;
14477
          case 1: // PE
14478
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14479
              this.pe = new PaymentException();
14480
              this.pe.read(iprot);
14481
            } else { 
14482
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14483
            }
14484
            break;
14485
          default:
14486
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 14487
        }
3430 rajveer 14488
        iprot.readFieldEnd();
2462 chandransh 14489
      }
14490
      iprot.readStructEnd();
14491
      validate();
14492
    }
14493
 
3430 rajveer 14494
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 14495
      oprot.writeStructBegin(STRUCT_DESC);
14496
 
14497
      if (this.isSetSuccess()) {
14498
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 14499
        oprot.writeI64(this.success);
2462 chandransh 14500
        oprot.writeFieldEnd();
14501
      } else if (this.isSetPe()) {
14502
        oprot.writeFieldBegin(PE_FIELD_DESC);
14503
        this.pe.write(oprot);
14504
        oprot.writeFieldEnd();
14505
      }
14506
      oprot.writeFieldStop();
14507
      oprot.writeStructEnd();
14508
    }
14509
 
14510
    @Override
14511
    public String toString() {
3010 chandransh 14512
      StringBuilder sb = new StringBuilder("createRefund_result(");
2462 chandransh 14513
      boolean first = true;
14514
 
14515
      sb.append("success:");
3010 chandransh 14516
      sb.append(this.success);
2462 chandransh 14517
      first = false;
14518
      if (!first) sb.append(", ");
14519
      sb.append("pe:");
14520
      if (this.pe == null) {
14521
        sb.append("null");
14522
      } else {
14523
        sb.append(this.pe);
14524
      }
14525
      first = false;
14526
      sb.append(")");
14527
      return sb.toString();
14528
    }
14529
 
3430 rajveer 14530
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 14531
      // check for required fields
14532
    }
14533
 
3430 rajveer 14534
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14535
      try {
14536
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14537
      } catch (org.apache.thrift.TException te) {
14538
        throw new java.io.IOException(te);
14539
      }
14540
    }
14541
 
14542
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14543
      try {
14544
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14545
      } catch (org.apache.thrift.TException te) {
14546
        throw new java.io.IOException(te);
14547
      }
14548
    }
14549
 
2462 chandransh 14550
  }
14551
 
3430 rajveer 14552
  public static class capturePayment_args implements org.apache.thrift.TBase<capturePayment_args, capturePayment_args._Fields>, java.io.Serializable, Cloneable   {
14553
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("capturePayment_args");
2690 chandransh 14554
 
3430 rajveer 14555
    private static final org.apache.thrift.protocol.TField MERCHANT_TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantTxnId", org.apache.thrift.protocol.TType.I64, (short)1);
2690 chandransh 14556
 
3430 rajveer 14557
    private long merchantTxnId; // required
2690 chandransh 14558
 
14559
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 14560
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3010 chandransh 14561
      MERCHANT_TXN_ID((short)1, "merchantTxnId");
2690 chandransh 14562
 
14563
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14564
 
14565
      static {
14566
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14567
          byName.put(field.getFieldName(), field);
14568
        }
14569
      }
14570
 
14571
      /**
14572
       * Find the _Fields constant that matches fieldId, or null if its not found.
14573
       */
14574
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 14575
        switch(fieldId) {
14576
          case 1: // MERCHANT_TXN_ID
14577
            return MERCHANT_TXN_ID;
14578
          default:
14579
            return null;
14580
        }
2690 chandransh 14581
      }
14582
 
14583
      /**
14584
       * Find the _Fields constant that matches fieldId, throwing an exception
14585
       * if it is not found.
14586
       */
14587
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14588
        _Fields fields = findByThriftId(fieldId);
14589
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14590
        return fields;
14591
      }
14592
 
14593
      /**
14594
       * Find the _Fields constant that matches name, or null if its not found.
14595
       */
14596
      public static _Fields findByName(String name) {
14597
        return byName.get(name);
14598
      }
14599
 
14600
      private final short _thriftId;
14601
      private final String _fieldName;
14602
 
14603
      _Fields(short thriftId, String fieldName) {
14604
        _thriftId = thriftId;
14605
        _fieldName = fieldName;
14606
      }
14607
 
14608
      public short getThriftFieldId() {
14609
        return _thriftId;
14610
      }
14611
 
14612
      public String getFieldName() {
14613
        return _fieldName;
14614
      }
14615
    }
14616
 
14617
    // isset id assignments
3010 chandransh 14618
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
14619
    private BitSet __isset_bit_vector = new BitSet(1);
2690 chandransh 14620
 
3430 rajveer 14621
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2690 chandransh 14622
    static {
3430 rajveer 14623
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14624
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14625
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14626
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14627
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(capturePayment_args.class, metaDataMap);
2690 chandransh 14628
    }
14629
 
3010 chandransh 14630
    public capturePayment_args() {
2690 chandransh 14631
    }
14632
 
3010 chandransh 14633
    public capturePayment_args(
14634
      long merchantTxnId)
2690 chandransh 14635
    {
14636
      this();
14637
      this.merchantTxnId = merchantTxnId;
14638
      setMerchantTxnIdIsSet(true);
14639
    }
14640
 
14641
    /**
14642
     * Performs a deep copy on <i>other</i>.
14643
     */
3010 chandransh 14644
    public capturePayment_args(capturePayment_args other) {
2690 chandransh 14645
      __isset_bit_vector.clear();
14646
      __isset_bit_vector.or(other.__isset_bit_vector);
14647
      this.merchantTxnId = other.merchantTxnId;
14648
    }
14649
 
3010 chandransh 14650
    public capturePayment_args deepCopy() {
14651
      return new capturePayment_args(this);
2690 chandransh 14652
    }
14653
 
3430 rajveer 14654
    @Override
14655
    public void clear() {
14656
      setMerchantTxnIdIsSet(false);
14657
      this.merchantTxnId = 0;
2690 chandransh 14658
    }
14659
 
14660
    public long getMerchantTxnId() {
14661
      return this.merchantTxnId;
14662
    }
14663
 
3430 rajveer 14664
    public void setMerchantTxnId(long merchantTxnId) {
2690 chandransh 14665
      this.merchantTxnId = merchantTxnId;
14666
      setMerchantTxnIdIsSet(true);
14667
    }
14668
 
14669
    public void unsetMerchantTxnId() {
14670
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
14671
    }
14672
 
3430 rajveer 14673
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
2690 chandransh 14674
    public boolean isSetMerchantTxnId() {
14675
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
14676
    }
14677
 
14678
    public void setMerchantTxnIdIsSet(boolean value) {
14679
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
14680
    }
14681
 
14682
    public void setFieldValue(_Fields field, Object value) {
14683
      switch (field) {
14684
      case MERCHANT_TXN_ID:
14685
        if (value == null) {
14686
          unsetMerchantTxnId();
14687
        } else {
14688
          setMerchantTxnId((Long)value);
14689
        }
14690
        break;
14691
 
14692
      }
14693
    }
14694
 
14695
    public Object getFieldValue(_Fields field) {
14696
      switch (field) {
14697
      case MERCHANT_TXN_ID:
3430 rajveer 14698
        return Long.valueOf(getMerchantTxnId());
2690 chandransh 14699
 
14700
      }
14701
      throw new IllegalStateException();
14702
    }
14703
 
3430 rajveer 14704
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14705
    public boolean isSet(_Fields field) {
14706
      if (field == null) {
14707
        throw new IllegalArgumentException();
14708
      }
2690 chandransh 14709
 
14710
      switch (field) {
14711
      case MERCHANT_TXN_ID:
14712
        return isSetMerchantTxnId();
14713
      }
14714
      throw new IllegalStateException();
14715
    }
14716
 
14717
    @Override
14718
    public boolean equals(Object that) {
14719
      if (that == null)
14720
        return false;
3010 chandransh 14721
      if (that instanceof capturePayment_args)
14722
        return this.equals((capturePayment_args)that);
2690 chandransh 14723
      return false;
14724
    }
14725
 
3010 chandransh 14726
    public boolean equals(capturePayment_args that) {
2690 chandransh 14727
      if (that == null)
14728
        return false;
14729
 
14730
      boolean this_present_merchantTxnId = true;
14731
      boolean that_present_merchantTxnId = true;
14732
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
14733
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
14734
          return false;
14735
        if (this.merchantTxnId != that.merchantTxnId)
14736
          return false;
14737
      }
14738
 
14739
      return true;
14740
    }
14741
 
14742
    @Override
14743
    public int hashCode() {
14744
      return 0;
14745
    }
14746
 
3010 chandransh 14747
    public int compareTo(capturePayment_args other) {
2690 chandransh 14748
      if (!getClass().equals(other.getClass())) {
14749
        return getClass().getName().compareTo(other.getClass().getName());
14750
      }
14751
 
14752
      int lastComparison = 0;
3010 chandransh 14753
      capturePayment_args typedOther = (capturePayment_args)other;
2690 chandransh 14754
 
3430 rajveer 14755
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
2690 chandransh 14756
      if (lastComparison != 0) {
14757
        return lastComparison;
14758
      }
3430 rajveer 14759
      if (isSetMerchantTxnId()) {
14760
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
14761
        if (lastComparison != 0) {
14762
          return lastComparison;
14763
        }
2690 chandransh 14764
      }
14765
      return 0;
14766
    }
14767
 
3430 rajveer 14768
    public _Fields fieldForId(int fieldId) {
14769
      return _Fields.findByThriftId(fieldId);
14770
    }
14771
 
14772
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14773
      org.apache.thrift.protocol.TField field;
2690 chandransh 14774
      iprot.readStructBegin();
14775
      while (true)
14776
      {
14777
        field = iprot.readFieldBegin();
3430 rajveer 14778
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2690 chandransh 14779
          break;
14780
        }
3430 rajveer 14781
        switch (field.id) {
14782
          case 1: // MERCHANT_TXN_ID
14783
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14784
              this.merchantTxnId = iprot.readI64();
14785
              setMerchantTxnIdIsSet(true);
14786
            } else { 
14787
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14788
            }
14789
            break;
14790
          default:
14791
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2690 chandransh 14792
        }
3430 rajveer 14793
        iprot.readFieldEnd();
2690 chandransh 14794
      }
14795
      iprot.readStructEnd();
14796
      validate();
14797
    }
14798
 
3430 rajveer 14799
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2690 chandransh 14800
      validate();
14801
 
14802
      oprot.writeStructBegin(STRUCT_DESC);
14803
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
14804
      oprot.writeI64(this.merchantTxnId);
14805
      oprot.writeFieldEnd();
14806
      oprot.writeFieldStop();
14807
      oprot.writeStructEnd();
14808
    }
14809
 
14810
    @Override
14811
    public String toString() {
3010 chandransh 14812
      StringBuilder sb = new StringBuilder("capturePayment_args(");
2690 chandransh 14813
      boolean first = true;
14814
 
14815
      sb.append("merchantTxnId:");
14816
      sb.append(this.merchantTxnId);
14817
      first = false;
14818
      sb.append(")");
14819
      return sb.toString();
14820
    }
14821
 
3430 rajveer 14822
    public void validate() throws org.apache.thrift.TException {
2690 chandransh 14823
      // check for required fields
14824
    }
14825
 
3430 rajveer 14826
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14827
      try {
14828
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14829
      } catch (org.apache.thrift.TException te) {
14830
        throw new java.io.IOException(te);
14831
      }
14832
    }
14833
 
14834
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14835
      try {
14836
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14837
      } catch (org.apache.thrift.TException te) {
14838
        throw new java.io.IOException(te);
14839
      }
14840
    }
14841
 
2690 chandransh 14842
  }
14843
 
3430 rajveer 14844
  public static class capturePayment_result implements org.apache.thrift.TBase<capturePayment_result, capturePayment_result._Fields>, java.io.Serializable, Cloneable   {
14845
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("capturePayment_result");
2690 chandransh 14846
 
3430 rajveer 14847
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
14848
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2690 chandransh 14849
 
3430 rajveer 14850
    private boolean success; // required
14851
    private PaymentException pe; // required
2690 chandransh 14852
 
14853
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 14854
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2690 chandransh 14855
      SUCCESS((short)0, "success"),
14856
      PE((short)1, "pe");
14857
 
14858
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14859
 
14860
      static {
14861
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14862
          byName.put(field.getFieldName(), field);
14863
        }
14864
      }
14865
 
14866
      /**
14867
       * Find the _Fields constant that matches fieldId, or null if its not found.
14868
       */
14869
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 14870
        switch(fieldId) {
14871
          case 0: // SUCCESS
14872
            return SUCCESS;
14873
          case 1: // PE
14874
            return PE;
14875
          default:
14876
            return null;
14877
        }
2690 chandransh 14878
      }
14879
 
14880
      /**
14881
       * Find the _Fields constant that matches fieldId, throwing an exception
14882
       * if it is not found.
14883
       */
14884
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14885
        _Fields fields = findByThriftId(fieldId);
14886
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14887
        return fields;
14888
      }
14889
 
14890
      /**
14891
       * Find the _Fields constant that matches name, or null if its not found.
14892
       */
14893
      public static _Fields findByName(String name) {
14894
        return byName.get(name);
14895
      }
14896
 
14897
      private final short _thriftId;
14898
      private final String _fieldName;
14899
 
14900
      _Fields(short thriftId, String fieldName) {
14901
        _thriftId = thriftId;
14902
        _fieldName = fieldName;
14903
      }
14904
 
14905
      public short getThriftFieldId() {
14906
        return _thriftId;
14907
      }
14908
 
14909
      public String getFieldName() {
14910
        return _fieldName;
14911
      }
14912
    }
14913
 
14914
    // isset id assignments
14915
    private static final int __SUCCESS_ISSET_ID = 0;
14916
    private BitSet __isset_bit_vector = new BitSet(1);
14917
 
3430 rajveer 14918
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2690 chandransh 14919
    static {
3430 rajveer 14920
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14921
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14922
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
14923
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14924
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14925
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14926
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(capturePayment_result.class, metaDataMap);
2690 chandransh 14927
    }
14928
 
3010 chandransh 14929
    public capturePayment_result() {
2690 chandransh 14930
    }
14931
 
3010 chandransh 14932
    public capturePayment_result(
14933
      boolean success,
2690 chandransh 14934
      PaymentException pe)
14935
    {
14936
      this();
14937
      this.success = success;
14938
      setSuccessIsSet(true);
14939
      this.pe = pe;
14940
    }
14941
 
14942
    /**
14943
     * Performs a deep copy on <i>other</i>.
14944
     */
3010 chandransh 14945
    public capturePayment_result(capturePayment_result other) {
2690 chandransh 14946
      __isset_bit_vector.clear();
14947
      __isset_bit_vector.or(other.__isset_bit_vector);
14948
      this.success = other.success;
14949
      if (other.isSetPe()) {
14950
        this.pe = new PaymentException(other.pe);
14951
      }
14952
    }
14953
 
3010 chandransh 14954
    public capturePayment_result deepCopy() {
14955
      return new capturePayment_result(this);
2690 chandransh 14956
    }
14957
 
3430 rajveer 14958
    @Override
14959
    public void clear() {
14960
      setSuccessIsSet(false);
14961
      this.success = false;
14962
      this.pe = null;
2690 chandransh 14963
    }
14964
 
3010 chandransh 14965
    public boolean isSuccess() {
2690 chandransh 14966
      return this.success;
14967
    }
14968
 
3430 rajveer 14969
    public void setSuccess(boolean success) {
2690 chandransh 14970
      this.success = success;
14971
      setSuccessIsSet(true);
14972
    }
14973
 
14974
    public void unsetSuccess() {
14975
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
14976
    }
14977
 
3430 rajveer 14978
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2690 chandransh 14979
    public boolean isSetSuccess() {
14980
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
14981
    }
14982
 
14983
    public void setSuccessIsSet(boolean value) {
14984
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
14985
    }
14986
 
14987
    public PaymentException getPe() {
14988
      return this.pe;
14989
    }
14990
 
3430 rajveer 14991
    public void setPe(PaymentException pe) {
2690 chandransh 14992
      this.pe = pe;
14993
    }
14994
 
14995
    public void unsetPe() {
14996
      this.pe = null;
14997
    }
14998
 
3430 rajveer 14999
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2690 chandransh 15000
    public boolean isSetPe() {
15001
      return this.pe != null;
15002
    }
15003
 
15004
    public void setPeIsSet(boolean value) {
15005
      if (!value) {
15006
        this.pe = null;
15007
      }
15008
    }
15009
 
15010
    public void setFieldValue(_Fields field, Object value) {
15011
      switch (field) {
15012
      case SUCCESS:
15013
        if (value == null) {
15014
          unsetSuccess();
15015
        } else {
3010 chandransh 15016
          setSuccess((Boolean)value);
2690 chandransh 15017
        }
15018
        break;
15019
 
15020
      case PE:
15021
        if (value == null) {
15022
          unsetPe();
15023
        } else {
15024
          setPe((PaymentException)value);
15025
        }
15026
        break;
15027
 
15028
      }
15029
    }
15030
 
15031
    public Object getFieldValue(_Fields field) {
15032
      switch (field) {
15033
      case SUCCESS:
3430 rajveer 15034
        return Boolean.valueOf(isSuccess());
2690 chandransh 15035
 
15036
      case PE:
15037
        return getPe();
15038
 
15039
      }
15040
      throw new IllegalStateException();
15041
    }
15042
 
3430 rajveer 15043
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15044
    public boolean isSet(_Fields field) {
15045
      if (field == null) {
15046
        throw new IllegalArgumentException();
15047
      }
2690 chandransh 15048
 
15049
      switch (field) {
15050
      case SUCCESS:
15051
        return isSetSuccess();
15052
      case PE:
15053
        return isSetPe();
15054
      }
15055
      throw new IllegalStateException();
15056
    }
15057
 
15058
    @Override
15059
    public boolean equals(Object that) {
15060
      if (that == null)
15061
        return false;
3010 chandransh 15062
      if (that instanceof capturePayment_result)
15063
        return this.equals((capturePayment_result)that);
2690 chandransh 15064
      return false;
15065
    }
15066
 
3010 chandransh 15067
    public boolean equals(capturePayment_result that) {
2690 chandransh 15068
      if (that == null)
15069
        return false;
15070
 
15071
      boolean this_present_success = true;
15072
      boolean that_present_success = true;
15073
      if (this_present_success || that_present_success) {
15074
        if (!(this_present_success && that_present_success))
15075
          return false;
15076
        if (this.success != that.success)
15077
          return false;
15078
      }
15079
 
15080
      boolean this_present_pe = true && this.isSetPe();
15081
      boolean that_present_pe = true && that.isSetPe();
15082
      if (this_present_pe || that_present_pe) {
15083
        if (!(this_present_pe && that_present_pe))
15084
          return false;
15085
        if (!this.pe.equals(that.pe))
15086
          return false;
15087
      }
15088
 
15089
      return true;
15090
    }
15091
 
15092
    @Override
15093
    public int hashCode() {
15094
      return 0;
15095
    }
15096
 
3010 chandransh 15097
    public int compareTo(capturePayment_result other) {
2690 chandransh 15098
      if (!getClass().equals(other.getClass())) {
15099
        return getClass().getName().compareTo(other.getClass().getName());
15100
      }
15101
 
15102
      int lastComparison = 0;
3010 chandransh 15103
      capturePayment_result typedOther = (capturePayment_result)other;
2690 chandransh 15104
 
3430 rajveer 15105
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2690 chandransh 15106
      if (lastComparison != 0) {
15107
        return lastComparison;
15108
      }
3430 rajveer 15109
      if (isSetSuccess()) {
15110
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15111
        if (lastComparison != 0) {
15112
          return lastComparison;
15113
        }
2690 chandransh 15114
      }
3430 rajveer 15115
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
2690 chandransh 15116
      if (lastComparison != 0) {
15117
        return lastComparison;
15118
      }
3430 rajveer 15119
      if (isSetPe()) {
15120
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
15121
        if (lastComparison != 0) {
15122
          return lastComparison;
15123
        }
2690 chandransh 15124
      }
15125
      return 0;
15126
    }
15127
 
3430 rajveer 15128
    public _Fields fieldForId(int fieldId) {
15129
      return _Fields.findByThriftId(fieldId);
15130
    }
15131
 
15132
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15133
      org.apache.thrift.protocol.TField field;
2690 chandransh 15134
      iprot.readStructBegin();
15135
      while (true)
15136
      {
15137
        field = iprot.readFieldBegin();
3430 rajveer 15138
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2690 chandransh 15139
          break;
15140
        }
3430 rajveer 15141
        switch (field.id) {
15142
          case 0: // SUCCESS
15143
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
15144
              this.success = iprot.readBool();
15145
              setSuccessIsSet(true);
15146
            } else { 
15147
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15148
            }
15149
            break;
15150
          case 1: // PE
15151
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15152
              this.pe = new PaymentException();
15153
              this.pe.read(iprot);
15154
            } else { 
15155
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15156
            }
15157
            break;
15158
          default:
15159
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2690 chandransh 15160
        }
3430 rajveer 15161
        iprot.readFieldEnd();
2690 chandransh 15162
      }
15163
      iprot.readStructEnd();
15164
      validate();
15165
    }
15166
 
3430 rajveer 15167
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2690 chandransh 15168
      oprot.writeStructBegin(STRUCT_DESC);
15169
 
15170
      if (this.isSetSuccess()) {
15171
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 15172
        oprot.writeBool(this.success);
2690 chandransh 15173
        oprot.writeFieldEnd();
15174
      } else if (this.isSetPe()) {
15175
        oprot.writeFieldBegin(PE_FIELD_DESC);
15176
        this.pe.write(oprot);
15177
        oprot.writeFieldEnd();
15178
      }
15179
      oprot.writeFieldStop();
15180
      oprot.writeStructEnd();
15181
    }
15182
 
15183
    @Override
15184
    public String toString() {
3010 chandransh 15185
      StringBuilder sb = new StringBuilder("capturePayment_result(");
2690 chandransh 15186
      boolean first = true;
15187
 
15188
      sb.append("success:");
15189
      sb.append(this.success);
15190
      first = false;
15191
      if (!first) sb.append(", ");
15192
      sb.append("pe:");
15193
      if (this.pe == null) {
15194
        sb.append("null");
15195
      } else {
15196
        sb.append(this.pe);
15197
      }
15198
      first = false;
15199
      sb.append(")");
15200
      return sb.toString();
15201
    }
15202
 
3430 rajveer 15203
    public void validate() throws org.apache.thrift.TException {
2690 chandransh 15204
      // check for required fields
15205
    }
15206
 
3430 rajveer 15207
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15208
      try {
15209
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15210
      } catch (org.apache.thrift.TException te) {
15211
        throw new java.io.IOException(te);
15212
      }
15213
    }
15214
 
15215
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15216
      try {
15217
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15218
      } catch (org.apache.thrift.TException te) {
15219
        throw new java.io.IOException(te);
15220
      }
15221
    }
15222
 
2690 chandransh 15223
  }
15224
 
6486 rajveer 15225
  public static class refundPayment_args implements org.apache.thrift.TBase<refundPayment_args, refundPayment_args._Fields>, java.io.Serializable, Cloneable   {
15226
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("refundPayment_args");
15227
 
15228
    private static final org.apache.thrift.protocol.TField MERCHANT_TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantTxnId", org.apache.thrift.protocol.TType.I64, (short)1);
15229
    private static final org.apache.thrift.protocol.TField AMOUNT_FIELD_DESC = new org.apache.thrift.protocol.TField("amount", org.apache.thrift.protocol.TType.DOUBLE, (short)2);
15230
    private static final org.apache.thrift.protocol.TField IS_DIGITAL_FIELD_DESC = new org.apache.thrift.protocol.TField("isDigital", org.apache.thrift.protocol.TType.BOOL, (short)3);
15231
 
15232
    private long merchantTxnId; // required
15233
    private double amount; // required
15234
    private boolean isDigital; // required
15235
 
15236
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15237
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15238
      MERCHANT_TXN_ID((short)1, "merchantTxnId"),
15239
      AMOUNT((short)2, "amount"),
15240
      IS_DIGITAL((short)3, "isDigital");
15241
 
15242
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15243
 
15244
      static {
15245
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15246
          byName.put(field.getFieldName(), field);
15247
        }
15248
      }
15249
 
15250
      /**
15251
       * Find the _Fields constant that matches fieldId, or null if its not found.
15252
       */
15253
      public static _Fields findByThriftId(int fieldId) {
15254
        switch(fieldId) {
15255
          case 1: // MERCHANT_TXN_ID
15256
            return MERCHANT_TXN_ID;
15257
          case 2: // AMOUNT
15258
            return AMOUNT;
15259
          case 3: // IS_DIGITAL
15260
            return IS_DIGITAL;
15261
          default:
15262
            return null;
15263
        }
15264
      }
15265
 
15266
      /**
15267
       * Find the _Fields constant that matches fieldId, throwing an exception
15268
       * if it is not found.
15269
       */
15270
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15271
        _Fields fields = findByThriftId(fieldId);
15272
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15273
        return fields;
15274
      }
15275
 
15276
      /**
15277
       * Find the _Fields constant that matches name, or null if its not found.
15278
       */
15279
      public static _Fields findByName(String name) {
15280
        return byName.get(name);
15281
      }
15282
 
15283
      private final short _thriftId;
15284
      private final String _fieldName;
15285
 
15286
      _Fields(short thriftId, String fieldName) {
15287
        _thriftId = thriftId;
15288
        _fieldName = fieldName;
15289
      }
15290
 
15291
      public short getThriftFieldId() {
15292
        return _thriftId;
15293
      }
15294
 
15295
      public String getFieldName() {
15296
        return _fieldName;
15297
      }
15298
    }
15299
 
15300
    // isset id assignments
15301
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
15302
    private static final int __AMOUNT_ISSET_ID = 1;
15303
    private static final int __ISDIGITAL_ISSET_ID = 2;
15304
    private BitSet __isset_bit_vector = new BitSet(3);
15305
 
15306
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15307
    static {
15308
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15309
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15310
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
15311
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15312
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
15313
      tmpMap.put(_Fields.IS_DIGITAL, new org.apache.thrift.meta_data.FieldMetaData("isDigital", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15314
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
15315
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15316
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(refundPayment_args.class, metaDataMap);
15317
    }
15318
 
15319
    public refundPayment_args() {
15320
    }
15321
 
15322
    public refundPayment_args(
15323
      long merchantTxnId,
15324
      double amount,
15325
      boolean isDigital)
15326
    {
15327
      this();
15328
      this.merchantTxnId = merchantTxnId;
15329
      setMerchantTxnIdIsSet(true);
15330
      this.amount = amount;
15331
      setAmountIsSet(true);
15332
      this.isDigital = isDigital;
15333
      setIsDigitalIsSet(true);
15334
    }
15335
 
15336
    /**
15337
     * Performs a deep copy on <i>other</i>.
15338
     */
15339
    public refundPayment_args(refundPayment_args other) {
15340
      __isset_bit_vector.clear();
15341
      __isset_bit_vector.or(other.__isset_bit_vector);
15342
      this.merchantTxnId = other.merchantTxnId;
15343
      this.amount = other.amount;
15344
      this.isDigital = other.isDigital;
15345
    }
15346
 
15347
    public refundPayment_args deepCopy() {
15348
      return new refundPayment_args(this);
15349
    }
15350
 
15351
    @Override
15352
    public void clear() {
15353
      setMerchantTxnIdIsSet(false);
15354
      this.merchantTxnId = 0;
15355
      setAmountIsSet(false);
15356
      this.amount = 0.0;
15357
      setIsDigitalIsSet(false);
15358
      this.isDigital = false;
15359
    }
15360
 
15361
    public long getMerchantTxnId() {
15362
      return this.merchantTxnId;
15363
    }
15364
 
15365
    public void setMerchantTxnId(long merchantTxnId) {
15366
      this.merchantTxnId = merchantTxnId;
15367
      setMerchantTxnIdIsSet(true);
15368
    }
15369
 
15370
    public void unsetMerchantTxnId() {
15371
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
15372
    }
15373
 
15374
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
15375
    public boolean isSetMerchantTxnId() {
15376
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
15377
    }
15378
 
15379
    public void setMerchantTxnIdIsSet(boolean value) {
15380
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
15381
    }
15382
 
15383
    public double getAmount() {
15384
      return this.amount;
15385
    }
15386
 
15387
    public void setAmount(double amount) {
15388
      this.amount = amount;
15389
      setAmountIsSet(true);
15390
    }
15391
 
15392
    public void unsetAmount() {
15393
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
15394
    }
15395
 
15396
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
15397
    public boolean isSetAmount() {
15398
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
15399
    }
15400
 
15401
    public void setAmountIsSet(boolean value) {
15402
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
15403
    }
15404
 
15405
    public boolean isIsDigital() {
15406
      return this.isDigital;
15407
    }
15408
 
15409
    public void setIsDigital(boolean isDigital) {
15410
      this.isDigital = isDigital;
15411
      setIsDigitalIsSet(true);
15412
    }
15413
 
15414
    public void unsetIsDigital() {
15415
      __isset_bit_vector.clear(__ISDIGITAL_ISSET_ID);
15416
    }
15417
 
15418
    /** Returns true if field isDigital is set (has been assigned a value) and false otherwise */
15419
    public boolean isSetIsDigital() {
15420
      return __isset_bit_vector.get(__ISDIGITAL_ISSET_ID);
15421
    }
15422
 
15423
    public void setIsDigitalIsSet(boolean value) {
15424
      __isset_bit_vector.set(__ISDIGITAL_ISSET_ID, value);
15425
    }
15426
 
15427
    public void setFieldValue(_Fields field, Object value) {
15428
      switch (field) {
15429
      case MERCHANT_TXN_ID:
15430
        if (value == null) {
15431
          unsetMerchantTxnId();
15432
        } else {
15433
          setMerchantTxnId((Long)value);
15434
        }
15435
        break;
15436
 
15437
      case AMOUNT:
15438
        if (value == null) {
15439
          unsetAmount();
15440
        } else {
15441
          setAmount((Double)value);
15442
        }
15443
        break;
15444
 
15445
      case IS_DIGITAL:
15446
        if (value == null) {
15447
          unsetIsDigital();
15448
        } else {
15449
          setIsDigital((Boolean)value);
15450
        }
15451
        break;
15452
 
15453
      }
15454
    }
15455
 
15456
    public Object getFieldValue(_Fields field) {
15457
      switch (field) {
15458
      case MERCHANT_TXN_ID:
15459
        return Long.valueOf(getMerchantTxnId());
15460
 
15461
      case AMOUNT:
15462
        return Double.valueOf(getAmount());
15463
 
15464
      case IS_DIGITAL:
15465
        return Boolean.valueOf(isIsDigital());
15466
 
15467
      }
15468
      throw new IllegalStateException();
15469
    }
15470
 
15471
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15472
    public boolean isSet(_Fields field) {
15473
      if (field == null) {
15474
        throw new IllegalArgumentException();
15475
      }
15476
 
15477
      switch (field) {
15478
      case MERCHANT_TXN_ID:
15479
        return isSetMerchantTxnId();
15480
      case AMOUNT:
15481
        return isSetAmount();
15482
      case IS_DIGITAL:
15483
        return isSetIsDigital();
15484
      }
15485
      throw new IllegalStateException();
15486
    }
15487
 
15488
    @Override
15489
    public boolean equals(Object that) {
15490
      if (that == null)
15491
        return false;
15492
      if (that instanceof refundPayment_args)
15493
        return this.equals((refundPayment_args)that);
15494
      return false;
15495
    }
15496
 
15497
    public boolean equals(refundPayment_args that) {
15498
      if (that == null)
15499
        return false;
15500
 
15501
      boolean this_present_merchantTxnId = true;
15502
      boolean that_present_merchantTxnId = true;
15503
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
15504
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
15505
          return false;
15506
        if (this.merchantTxnId != that.merchantTxnId)
15507
          return false;
15508
      }
15509
 
15510
      boolean this_present_amount = true;
15511
      boolean that_present_amount = true;
15512
      if (this_present_amount || that_present_amount) {
15513
        if (!(this_present_amount && that_present_amount))
15514
          return false;
15515
        if (this.amount != that.amount)
15516
          return false;
15517
      }
15518
 
15519
      boolean this_present_isDigital = true;
15520
      boolean that_present_isDigital = true;
15521
      if (this_present_isDigital || that_present_isDigital) {
15522
        if (!(this_present_isDigital && that_present_isDigital))
15523
          return false;
15524
        if (this.isDigital != that.isDigital)
15525
          return false;
15526
      }
15527
 
15528
      return true;
15529
    }
15530
 
15531
    @Override
15532
    public int hashCode() {
15533
      return 0;
15534
    }
15535
 
15536
    public int compareTo(refundPayment_args other) {
15537
      if (!getClass().equals(other.getClass())) {
15538
        return getClass().getName().compareTo(other.getClass().getName());
15539
      }
15540
 
15541
      int lastComparison = 0;
15542
      refundPayment_args typedOther = (refundPayment_args)other;
15543
 
15544
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
15545
      if (lastComparison != 0) {
15546
        return lastComparison;
15547
      }
15548
      if (isSetMerchantTxnId()) {
15549
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
15550
        if (lastComparison != 0) {
15551
          return lastComparison;
15552
        }
15553
      }
15554
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
15555
      if (lastComparison != 0) {
15556
        return lastComparison;
15557
      }
15558
      if (isSetAmount()) {
15559
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
15560
        if (lastComparison != 0) {
15561
          return lastComparison;
15562
        }
15563
      }
15564
      lastComparison = Boolean.valueOf(isSetIsDigital()).compareTo(typedOther.isSetIsDigital());
15565
      if (lastComparison != 0) {
15566
        return lastComparison;
15567
      }
15568
      if (isSetIsDigital()) {
15569
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isDigital, typedOther.isDigital);
15570
        if (lastComparison != 0) {
15571
          return lastComparison;
15572
        }
15573
      }
15574
      return 0;
15575
    }
15576
 
15577
    public _Fields fieldForId(int fieldId) {
15578
      return _Fields.findByThriftId(fieldId);
15579
    }
15580
 
15581
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15582
      org.apache.thrift.protocol.TField field;
15583
      iprot.readStructBegin();
15584
      while (true)
15585
      {
15586
        field = iprot.readFieldBegin();
15587
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15588
          break;
15589
        }
15590
        switch (field.id) {
15591
          case 1: // MERCHANT_TXN_ID
15592
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15593
              this.merchantTxnId = iprot.readI64();
15594
              setMerchantTxnIdIsSet(true);
15595
            } else { 
15596
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15597
            }
15598
            break;
15599
          case 2: // AMOUNT
15600
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
15601
              this.amount = iprot.readDouble();
15602
              setAmountIsSet(true);
15603
            } else { 
15604
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15605
            }
15606
            break;
15607
          case 3: // IS_DIGITAL
15608
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
15609
              this.isDigital = iprot.readBool();
15610
              setIsDigitalIsSet(true);
15611
            } else { 
15612
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15613
            }
15614
            break;
15615
          default:
15616
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15617
        }
15618
        iprot.readFieldEnd();
15619
      }
15620
      iprot.readStructEnd();
15621
      validate();
15622
    }
15623
 
15624
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15625
      validate();
15626
 
15627
      oprot.writeStructBegin(STRUCT_DESC);
15628
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
15629
      oprot.writeI64(this.merchantTxnId);
15630
      oprot.writeFieldEnd();
15631
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
15632
      oprot.writeDouble(this.amount);
15633
      oprot.writeFieldEnd();
15634
      oprot.writeFieldBegin(IS_DIGITAL_FIELD_DESC);
15635
      oprot.writeBool(this.isDigital);
15636
      oprot.writeFieldEnd();
15637
      oprot.writeFieldStop();
15638
      oprot.writeStructEnd();
15639
    }
15640
 
15641
    @Override
15642
    public String toString() {
15643
      StringBuilder sb = new StringBuilder("refundPayment_args(");
15644
      boolean first = true;
15645
 
15646
      sb.append("merchantTxnId:");
15647
      sb.append(this.merchantTxnId);
15648
      first = false;
15649
      if (!first) sb.append(", ");
15650
      sb.append("amount:");
15651
      sb.append(this.amount);
15652
      first = false;
15653
      if (!first) sb.append(", ");
15654
      sb.append("isDigital:");
15655
      sb.append(this.isDigital);
15656
      first = false;
15657
      sb.append(")");
15658
      return sb.toString();
15659
    }
15660
 
15661
    public void validate() throws org.apache.thrift.TException {
15662
      // check for required fields
15663
    }
15664
 
15665
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15666
      try {
15667
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15668
      } catch (org.apache.thrift.TException te) {
15669
        throw new java.io.IOException(te);
15670
      }
15671
    }
15672
 
15673
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15674
      try {
15675
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15676
      } catch (org.apache.thrift.TException te) {
15677
        throw new java.io.IOException(te);
15678
      }
15679
    }
15680
 
15681
  }
15682
 
15683
  public static class refundPayment_result implements org.apache.thrift.TBase<refundPayment_result, refundPayment_result._Fields>, java.io.Serializable, Cloneable   {
15684
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("refundPayment_result");
15685
 
15686
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
15687
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
15688
 
15689
    private boolean success; // required
15690
    private PaymentException pe; // required
15691
 
15692
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15693
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15694
      SUCCESS((short)0, "success"),
15695
      PE((short)1, "pe");
15696
 
15697
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15698
 
15699
      static {
15700
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15701
          byName.put(field.getFieldName(), field);
15702
        }
15703
      }
15704
 
15705
      /**
15706
       * Find the _Fields constant that matches fieldId, or null if its not found.
15707
       */
15708
      public static _Fields findByThriftId(int fieldId) {
15709
        switch(fieldId) {
15710
          case 0: // SUCCESS
15711
            return SUCCESS;
15712
          case 1: // PE
15713
            return PE;
15714
          default:
15715
            return null;
15716
        }
15717
      }
15718
 
15719
      /**
15720
       * Find the _Fields constant that matches fieldId, throwing an exception
15721
       * if it is not found.
15722
       */
15723
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15724
        _Fields fields = findByThriftId(fieldId);
15725
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15726
        return fields;
15727
      }
15728
 
15729
      /**
15730
       * Find the _Fields constant that matches name, or null if its not found.
15731
       */
15732
      public static _Fields findByName(String name) {
15733
        return byName.get(name);
15734
      }
15735
 
15736
      private final short _thriftId;
15737
      private final String _fieldName;
15738
 
15739
      _Fields(short thriftId, String fieldName) {
15740
        _thriftId = thriftId;
15741
        _fieldName = fieldName;
15742
      }
15743
 
15744
      public short getThriftFieldId() {
15745
        return _thriftId;
15746
      }
15747
 
15748
      public String getFieldName() {
15749
        return _fieldName;
15750
      }
15751
    }
15752
 
15753
    // isset id assignments
15754
    private static final int __SUCCESS_ISSET_ID = 0;
15755
    private BitSet __isset_bit_vector = new BitSet(1);
15756
 
15757
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15758
    static {
15759
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15760
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15761
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
15762
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15763
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15764
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15765
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(refundPayment_result.class, metaDataMap);
15766
    }
15767
 
15768
    public refundPayment_result() {
15769
    }
15770
 
15771
    public refundPayment_result(
15772
      boolean success,
15773
      PaymentException pe)
15774
    {
15775
      this();
15776
      this.success = success;
15777
      setSuccessIsSet(true);
15778
      this.pe = pe;
15779
    }
15780
 
15781
    /**
15782
     * Performs a deep copy on <i>other</i>.
15783
     */
15784
    public refundPayment_result(refundPayment_result other) {
15785
      __isset_bit_vector.clear();
15786
      __isset_bit_vector.or(other.__isset_bit_vector);
15787
      this.success = other.success;
15788
      if (other.isSetPe()) {
15789
        this.pe = new PaymentException(other.pe);
15790
      }
15791
    }
15792
 
15793
    public refundPayment_result deepCopy() {
15794
      return new refundPayment_result(this);
15795
    }
15796
 
15797
    @Override
15798
    public void clear() {
15799
      setSuccessIsSet(false);
15800
      this.success = false;
15801
      this.pe = null;
15802
    }
15803
 
15804
    public boolean isSuccess() {
15805
      return this.success;
15806
    }
15807
 
15808
    public void setSuccess(boolean success) {
15809
      this.success = success;
15810
      setSuccessIsSet(true);
15811
    }
15812
 
15813
    public void unsetSuccess() {
15814
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
15815
    }
15816
 
15817
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
15818
    public boolean isSetSuccess() {
15819
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
15820
    }
15821
 
15822
    public void setSuccessIsSet(boolean value) {
15823
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
15824
    }
15825
 
15826
    public PaymentException getPe() {
15827
      return this.pe;
15828
    }
15829
 
15830
    public void setPe(PaymentException pe) {
15831
      this.pe = pe;
15832
    }
15833
 
15834
    public void unsetPe() {
15835
      this.pe = null;
15836
    }
15837
 
15838
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
15839
    public boolean isSetPe() {
15840
      return this.pe != null;
15841
    }
15842
 
15843
    public void setPeIsSet(boolean value) {
15844
      if (!value) {
15845
        this.pe = null;
15846
      }
15847
    }
15848
 
15849
    public void setFieldValue(_Fields field, Object value) {
15850
      switch (field) {
15851
      case SUCCESS:
15852
        if (value == null) {
15853
          unsetSuccess();
15854
        } else {
15855
          setSuccess((Boolean)value);
15856
        }
15857
        break;
15858
 
15859
      case PE:
15860
        if (value == null) {
15861
          unsetPe();
15862
        } else {
15863
          setPe((PaymentException)value);
15864
        }
15865
        break;
15866
 
15867
      }
15868
    }
15869
 
15870
    public Object getFieldValue(_Fields field) {
15871
      switch (field) {
15872
      case SUCCESS:
15873
        return Boolean.valueOf(isSuccess());
15874
 
15875
      case PE:
15876
        return getPe();
15877
 
15878
      }
15879
      throw new IllegalStateException();
15880
    }
15881
 
15882
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15883
    public boolean isSet(_Fields field) {
15884
      if (field == null) {
15885
        throw new IllegalArgumentException();
15886
      }
15887
 
15888
      switch (field) {
15889
      case SUCCESS:
15890
        return isSetSuccess();
15891
      case PE:
15892
        return isSetPe();
15893
      }
15894
      throw new IllegalStateException();
15895
    }
15896
 
15897
    @Override
15898
    public boolean equals(Object that) {
15899
      if (that == null)
15900
        return false;
15901
      if (that instanceof refundPayment_result)
15902
        return this.equals((refundPayment_result)that);
15903
      return false;
15904
    }
15905
 
15906
    public boolean equals(refundPayment_result that) {
15907
      if (that == null)
15908
        return false;
15909
 
15910
      boolean this_present_success = true;
15911
      boolean that_present_success = true;
15912
      if (this_present_success || that_present_success) {
15913
        if (!(this_present_success && that_present_success))
15914
          return false;
15915
        if (this.success != that.success)
15916
          return false;
15917
      }
15918
 
15919
      boolean this_present_pe = true && this.isSetPe();
15920
      boolean that_present_pe = true && that.isSetPe();
15921
      if (this_present_pe || that_present_pe) {
15922
        if (!(this_present_pe && that_present_pe))
15923
          return false;
15924
        if (!this.pe.equals(that.pe))
15925
          return false;
15926
      }
15927
 
15928
      return true;
15929
    }
15930
 
15931
    @Override
15932
    public int hashCode() {
15933
      return 0;
15934
    }
15935
 
15936
    public int compareTo(refundPayment_result other) {
15937
      if (!getClass().equals(other.getClass())) {
15938
        return getClass().getName().compareTo(other.getClass().getName());
15939
      }
15940
 
15941
      int lastComparison = 0;
15942
      refundPayment_result typedOther = (refundPayment_result)other;
15943
 
15944
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
15945
      if (lastComparison != 0) {
15946
        return lastComparison;
15947
      }
15948
      if (isSetSuccess()) {
15949
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15950
        if (lastComparison != 0) {
15951
          return lastComparison;
15952
        }
15953
      }
15954
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
15955
      if (lastComparison != 0) {
15956
        return lastComparison;
15957
      }
15958
      if (isSetPe()) {
15959
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
15960
        if (lastComparison != 0) {
15961
          return lastComparison;
15962
        }
15963
      }
15964
      return 0;
15965
    }
15966
 
15967
    public _Fields fieldForId(int fieldId) {
15968
      return _Fields.findByThriftId(fieldId);
15969
    }
15970
 
15971
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15972
      org.apache.thrift.protocol.TField field;
15973
      iprot.readStructBegin();
15974
      while (true)
15975
      {
15976
        field = iprot.readFieldBegin();
15977
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15978
          break;
15979
        }
15980
        switch (field.id) {
15981
          case 0: // SUCCESS
15982
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
15983
              this.success = iprot.readBool();
15984
              setSuccessIsSet(true);
15985
            } else { 
15986
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15987
            }
15988
            break;
15989
          case 1: // PE
15990
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15991
              this.pe = new PaymentException();
15992
              this.pe.read(iprot);
15993
            } else { 
15994
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15995
            }
15996
            break;
15997
          default:
15998
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15999
        }
16000
        iprot.readFieldEnd();
16001
      }
16002
      iprot.readStructEnd();
16003
      validate();
16004
    }
16005
 
16006
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16007
      oprot.writeStructBegin(STRUCT_DESC);
16008
 
16009
      if (this.isSetSuccess()) {
16010
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
16011
        oprot.writeBool(this.success);
16012
        oprot.writeFieldEnd();
16013
      } else if (this.isSetPe()) {
16014
        oprot.writeFieldBegin(PE_FIELD_DESC);
16015
        this.pe.write(oprot);
16016
        oprot.writeFieldEnd();
16017
      }
16018
      oprot.writeFieldStop();
16019
      oprot.writeStructEnd();
16020
    }
16021
 
16022
    @Override
16023
    public String toString() {
16024
      StringBuilder sb = new StringBuilder("refundPayment_result(");
16025
      boolean first = true;
16026
 
16027
      sb.append("success:");
16028
      sb.append(this.success);
16029
      first = false;
16030
      if (!first) sb.append(", ");
16031
      sb.append("pe:");
16032
      if (this.pe == null) {
16033
        sb.append("null");
16034
      } else {
16035
        sb.append(this.pe);
16036
      }
16037
      first = false;
16038
      sb.append(")");
16039
      return sb.toString();
16040
    }
16041
 
16042
    public void validate() throws org.apache.thrift.TException {
16043
      // check for required fields
16044
    }
16045
 
16046
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16047
      try {
16048
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16049
      } catch (org.apache.thrift.TException te) {
16050
        throw new java.io.IOException(te);
16051
      }
16052
    }
16053
 
16054
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16055
      try {
16056
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16057
      } catch (org.apache.thrift.TException te) {
16058
        throw new java.io.IOException(te);
16059
      }
16060
    }
16061
 
16062
  }
16063
 
3956 chandransh 16064
  public static class partiallyCapturePayment_args implements org.apache.thrift.TBase<partiallyCapturePayment_args, partiallyCapturePayment_args._Fields>, java.io.Serializable, Cloneable   {
16065
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("partiallyCapturePayment_args");
16066
 
16067
    private static final org.apache.thrift.protocol.TField MERCHANT_TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantTxnId", org.apache.thrift.protocol.TType.I64, (short)1);
16068
    private static final org.apache.thrift.protocol.TField AMOUNT_FIELD_DESC = new org.apache.thrift.protocol.TField("amount", org.apache.thrift.protocol.TType.DOUBLE, (short)2);
16069
    private static final org.apache.thrift.protocol.TField XFER_BY_FIELD_DESC = new org.apache.thrift.protocol.TField("xferBy", org.apache.thrift.protocol.TType.STRING, (short)3);
16070
    private static final org.apache.thrift.protocol.TField XFER_TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("xferTxnId", org.apache.thrift.protocol.TType.STRING, (short)4);
16071
    private static final org.apache.thrift.protocol.TField XFER_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("xferDate", org.apache.thrift.protocol.TType.I64, (short)5);
16072
 
16073
    private long merchantTxnId; // required
16074
    private double amount; // required
16075
    private String xferBy; // required
16076
    private String xferTxnId; // required
16077
    private long xferDate; // required
16078
 
16079
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16080
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16081
      MERCHANT_TXN_ID((short)1, "merchantTxnId"),
16082
      AMOUNT((short)2, "amount"),
16083
      XFER_BY((short)3, "xferBy"),
16084
      XFER_TXN_ID((short)4, "xferTxnId"),
16085
      XFER_DATE((short)5, "xferDate");
16086
 
16087
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16088
 
16089
      static {
16090
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16091
          byName.put(field.getFieldName(), field);
16092
        }
16093
      }
16094
 
16095
      /**
16096
       * Find the _Fields constant that matches fieldId, or null if its not found.
16097
       */
16098
      public static _Fields findByThriftId(int fieldId) {
16099
        switch(fieldId) {
16100
          case 1: // MERCHANT_TXN_ID
16101
            return MERCHANT_TXN_ID;
16102
          case 2: // AMOUNT
16103
            return AMOUNT;
16104
          case 3: // XFER_BY
16105
            return XFER_BY;
16106
          case 4: // XFER_TXN_ID
16107
            return XFER_TXN_ID;
16108
          case 5: // XFER_DATE
16109
            return XFER_DATE;
16110
          default:
16111
            return null;
16112
        }
16113
      }
16114
 
16115
      /**
16116
       * Find the _Fields constant that matches fieldId, throwing an exception
16117
       * if it is not found.
16118
       */
16119
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16120
        _Fields fields = findByThriftId(fieldId);
16121
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16122
        return fields;
16123
      }
16124
 
16125
      /**
16126
       * Find the _Fields constant that matches name, or null if its not found.
16127
       */
16128
      public static _Fields findByName(String name) {
16129
        return byName.get(name);
16130
      }
16131
 
16132
      private final short _thriftId;
16133
      private final String _fieldName;
16134
 
16135
      _Fields(short thriftId, String fieldName) {
16136
        _thriftId = thriftId;
16137
        _fieldName = fieldName;
16138
      }
16139
 
16140
      public short getThriftFieldId() {
16141
        return _thriftId;
16142
      }
16143
 
16144
      public String getFieldName() {
16145
        return _fieldName;
16146
      }
16147
    }
16148
 
16149
    // isset id assignments
16150
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
16151
    private static final int __AMOUNT_ISSET_ID = 1;
16152
    private static final int __XFERDATE_ISSET_ID = 2;
16153
    private BitSet __isset_bit_vector = new BitSet(3);
16154
 
16155
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16156
    static {
16157
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16158
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16159
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
16160
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16161
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
16162
      tmpMap.put(_Fields.XFER_BY, new org.apache.thrift.meta_data.FieldMetaData("xferBy", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16163
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
16164
      tmpMap.put(_Fields.XFER_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("xferTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16165
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
16166
      tmpMap.put(_Fields.XFER_DATE, new org.apache.thrift.meta_data.FieldMetaData("xferDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16167
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
16168
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16169
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(partiallyCapturePayment_args.class, metaDataMap);
16170
    }
16171
 
16172
    public partiallyCapturePayment_args() {
16173
    }
16174
 
16175
    public partiallyCapturePayment_args(
16176
      long merchantTxnId,
16177
      double amount,
16178
      String xferBy,
16179
      String xferTxnId,
16180
      long xferDate)
16181
    {
16182
      this();
16183
      this.merchantTxnId = merchantTxnId;
16184
      setMerchantTxnIdIsSet(true);
16185
      this.amount = amount;
16186
      setAmountIsSet(true);
16187
      this.xferBy = xferBy;
16188
      this.xferTxnId = xferTxnId;
16189
      this.xferDate = xferDate;
16190
      setXferDateIsSet(true);
16191
    }
16192
 
16193
    /**
16194
     * Performs a deep copy on <i>other</i>.
16195
     */
16196
    public partiallyCapturePayment_args(partiallyCapturePayment_args other) {
16197
      __isset_bit_vector.clear();
16198
      __isset_bit_vector.or(other.__isset_bit_vector);
16199
      this.merchantTxnId = other.merchantTxnId;
16200
      this.amount = other.amount;
16201
      if (other.isSetXferBy()) {
16202
        this.xferBy = other.xferBy;
16203
      }
16204
      if (other.isSetXferTxnId()) {
16205
        this.xferTxnId = other.xferTxnId;
16206
      }
16207
      this.xferDate = other.xferDate;
16208
    }
16209
 
16210
    public partiallyCapturePayment_args deepCopy() {
16211
      return new partiallyCapturePayment_args(this);
16212
    }
16213
 
16214
    @Override
16215
    public void clear() {
16216
      setMerchantTxnIdIsSet(false);
16217
      this.merchantTxnId = 0;
16218
      setAmountIsSet(false);
16219
      this.amount = 0.0;
16220
      this.xferBy = null;
16221
      this.xferTxnId = null;
16222
      setXferDateIsSet(false);
16223
      this.xferDate = 0;
16224
    }
16225
 
16226
    public long getMerchantTxnId() {
16227
      return this.merchantTxnId;
16228
    }
16229
 
16230
    public void setMerchantTxnId(long merchantTxnId) {
16231
      this.merchantTxnId = merchantTxnId;
16232
      setMerchantTxnIdIsSet(true);
16233
    }
16234
 
16235
    public void unsetMerchantTxnId() {
16236
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
16237
    }
16238
 
16239
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
16240
    public boolean isSetMerchantTxnId() {
16241
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
16242
    }
16243
 
16244
    public void setMerchantTxnIdIsSet(boolean value) {
16245
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
16246
    }
16247
 
16248
    public double getAmount() {
16249
      return this.amount;
16250
    }
16251
 
16252
    public void setAmount(double amount) {
16253
      this.amount = amount;
16254
      setAmountIsSet(true);
16255
    }
16256
 
16257
    public void unsetAmount() {
16258
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
16259
    }
16260
 
16261
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
16262
    public boolean isSetAmount() {
16263
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
16264
    }
16265
 
16266
    public void setAmountIsSet(boolean value) {
16267
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
16268
    }
16269
 
16270
    public String getXferBy() {
16271
      return this.xferBy;
16272
    }
16273
 
16274
    public void setXferBy(String xferBy) {
16275
      this.xferBy = xferBy;
16276
    }
16277
 
16278
    public void unsetXferBy() {
16279
      this.xferBy = null;
16280
    }
16281
 
16282
    /** Returns true if field xferBy is set (has been assigned a value) and false otherwise */
16283
    public boolean isSetXferBy() {
16284
      return this.xferBy != null;
16285
    }
16286
 
16287
    public void setXferByIsSet(boolean value) {
16288
      if (!value) {
16289
        this.xferBy = null;
16290
      }
16291
    }
16292
 
16293
    public String getXferTxnId() {
16294
      return this.xferTxnId;
16295
    }
16296
 
16297
    public void setXferTxnId(String xferTxnId) {
16298
      this.xferTxnId = xferTxnId;
16299
    }
16300
 
16301
    public void unsetXferTxnId() {
16302
      this.xferTxnId = null;
16303
    }
16304
 
16305
    /** Returns true if field xferTxnId is set (has been assigned a value) and false otherwise */
16306
    public boolean isSetXferTxnId() {
16307
      return this.xferTxnId != null;
16308
    }
16309
 
16310
    public void setXferTxnIdIsSet(boolean value) {
16311
      if (!value) {
16312
        this.xferTxnId = null;
16313
      }
16314
    }
16315
 
16316
    public long getXferDate() {
16317
      return this.xferDate;
16318
    }
16319
 
16320
    public void setXferDate(long xferDate) {
16321
      this.xferDate = xferDate;
16322
      setXferDateIsSet(true);
16323
    }
16324
 
16325
    public void unsetXferDate() {
16326
      __isset_bit_vector.clear(__XFERDATE_ISSET_ID);
16327
    }
16328
 
16329
    /** Returns true if field xferDate is set (has been assigned a value) and false otherwise */
16330
    public boolean isSetXferDate() {
16331
      return __isset_bit_vector.get(__XFERDATE_ISSET_ID);
16332
    }
16333
 
16334
    public void setXferDateIsSet(boolean value) {
16335
      __isset_bit_vector.set(__XFERDATE_ISSET_ID, value);
16336
    }
16337
 
16338
    public void setFieldValue(_Fields field, Object value) {
16339
      switch (field) {
16340
      case MERCHANT_TXN_ID:
16341
        if (value == null) {
16342
          unsetMerchantTxnId();
16343
        } else {
16344
          setMerchantTxnId((Long)value);
16345
        }
16346
        break;
16347
 
16348
      case AMOUNT:
16349
        if (value == null) {
16350
          unsetAmount();
16351
        } else {
16352
          setAmount((Double)value);
16353
        }
16354
        break;
16355
 
16356
      case XFER_BY:
16357
        if (value == null) {
16358
          unsetXferBy();
16359
        } else {
16360
          setXferBy((String)value);
16361
        }
16362
        break;
16363
 
16364
      case XFER_TXN_ID:
16365
        if (value == null) {
16366
          unsetXferTxnId();
16367
        } else {
16368
          setXferTxnId((String)value);
16369
        }
16370
        break;
16371
 
16372
      case XFER_DATE:
16373
        if (value == null) {
16374
          unsetXferDate();
16375
        } else {
16376
          setXferDate((Long)value);
16377
        }
16378
        break;
16379
 
16380
      }
16381
    }
16382
 
16383
    public Object getFieldValue(_Fields field) {
16384
      switch (field) {
16385
      case MERCHANT_TXN_ID:
16386
        return Long.valueOf(getMerchantTxnId());
16387
 
16388
      case AMOUNT:
16389
        return Double.valueOf(getAmount());
16390
 
16391
      case XFER_BY:
16392
        return getXferBy();
16393
 
16394
      case XFER_TXN_ID:
16395
        return getXferTxnId();
16396
 
16397
      case XFER_DATE:
16398
        return Long.valueOf(getXferDate());
16399
 
16400
      }
16401
      throw new IllegalStateException();
16402
    }
16403
 
16404
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16405
    public boolean isSet(_Fields field) {
16406
      if (field == null) {
16407
        throw new IllegalArgumentException();
16408
      }
16409
 
16410
      switch (field) {
16411
      case MERCHANT_TXN_ID:
16412
        return isSetMerchantTxnId();
16413
      case AMOUNT:
16414
        return isSetAmount();
16415
      case XFER_BY:
16416
        return isSetXferBy();
16417
      case XFER_TXN_ID:
16418
        return isSetXferTxnId();
16419
      case XFER_DATE:
16420
        return isSetXferDate();
16421
      }
16422
      throw new IllegalStateException();
16423
    }
16424
 
16425
    @Override
16426
    public boolean equals(Object that) {
16427
      if (that == null)
16428
        return false;
16429
      if (that instanceof partiallyCapturePayment_args)
16430
        return this.equals((partiallyCapturePayment_args)that);
16431
      return false;
16432
    }
16433
 
16434
    public boolean equals(partiallyCapturePayment_args that) {
16435
      if (that == null)
16436
        return false;
16437
 
16438
      boolean this_present_merchantTxnId = true;
16439
      boolean that_present_merchantTxnId = true;
16440
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
16441
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
16442
          return false;
16443
        if (this.merchantTxnId != that.merchantTxnId)
16444
          return false;
16445
      }
16446
 
16447
      boolean this_present_amount = true;
16448
      boolean that_present_amount = true;
16449
      if (this_present_amount || that_present_amount) {
16450
        if (!(this_present_amount && that_present_amount))
16451
          return false;
16452
        if (this.amount != that.amount)
16453
          return false;
16454
      }
16455
 
16456
      boolean this_present_xferBy = true && this.isSetXferBy();
16457
      boolean that_present_xferBy = true && that.isSetXferBy();
16458
      if (this_present_xferBy || that_present_xferBy) {
16459
        if (!(this_present_xferBy && that_present_xferBy))
16460
          return false;
16461
        if (!this.xferBy.equals(that.xferBy))
16462
          return false;
16463
      }
16464
 
16465
      boolean this_present_xferTxnId = true && this.isSetXferTxnId();
16466
      boolean that_present_xferTxnId = true && that.isSetXferTxnId();
16467
      if (this_present_xferTxnId || that_present_xferTxnId) {
16468
        if (!(this_present_xferTxnId && that_present_xferTxnId))
16469
          return false;
16470
        if (!this.xferTxnId.equals(that.xferTxnId))
16471
          return false;
16472
      }
16473
 
16474
      boolean this_present_xferDate = true;
16475
      boolean that_present_xferDate = true;
16476
      if (this_present_xferDate || that_present_xferDate) {
16477
        if (!(this_present_xferDate && that_present_xferDate))
16478
          return false;
16479
        if (this.xferDate != that.xferDate)
16480
          return false;
16481
      }
16482
 
16483
      return true;
16484
    }
16485
 
16486
    @Override
16487
    public int hashCode() {
16488
      return 0;
16489
    }
16490
 
16491
    public int compareTo(partiallyCapturePayment_args other) {
16492
      if (!getClass().equals(other.getClass())) {
16493
        return getClass().getName().compareTo(other.getClass().getName());
16494
      }
16495
 
16496
      int lastComparison = 0;
16497
      partiallyCapturePayment_args typedOther = (partiallyCapturePayment_args)other;
16498
 
16499
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
16500
      if (lastComparison != 0) {
16501
        return lastComparison;
16502
      }
16503
      if (isSetMerchantTxnId()) {
16504
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
16505
        if (lastComparison != 0) {
16506
          return lastComparison;
16507
        }
16508
      }
16509
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
16510
      if (lastComparison != 0) {
16511
        return lastComparison;
16512
      }
16513
      if (isSetAmount()) {
16514
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
16515
        if (lastComparison != 0) {
16516
          return lastComparison;
16517
        }
16518
      }
16519
      lastComparison = Boolean.valueOf(isSetXferBy()).compareTo(typedOther.isSetXferBy());
16520
      if (lastComparison != 0) {
16521
        return lastComparison;
16522
      }
16523
      if (isSetXferBy()) {
16524
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferBy, typedOther.xferBy);
16525
        if (lastComparison != 0) {
16526
          return lastComparison;
16527
        }
16528
      }
16529
      lastComparison = Boolean.valueOf(isSetXferTxnId()).compareTo(typedOther.isSetXferTxnId());
16530
      if (lastComparison != 0) {
16531
        return lastComparison;
16532
      }
16533
      if (isSetXferTxnId()) {
16534
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferTxnId, typedOther.xferTxnId);
16535
        if (lastComparison != 0) {
16536
          return lastComparison;
16537
        }
16538
      }
16539
      lastComparison = Boolean.valueOf(isSetXferDate()).compareTo(typedOther.isSetXferDate());
16540
      if (lastComparison != 0) {
16541
        return lastComparison;
16542
      }
16543
      if (isSetXferDate()) {
16544
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferDate, typedOther.xferDate);
16545
        if (lastComparison != 0) {
16546
          return lastComparison;
16547
        }
16548
      }
16549
      return 0;
16550
    }
16551
 
16552
    public _Fields fieldForId(int fieldId) {
16553
      return _Fields.findByThriftId(fieldId);
16554
    }
16555
 
16556
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16557
      org.apache.thrift.protocol.TField field;
16558
      iprot.readStructBegin();
16559
      while (true)
16560
      {
16561
        field = iprot.readFieldBegin();
16562
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16563
          break;
16564
        }
16565
        switch (field.id) {
16566
          case 1: // MERCHANT_TXN_ID
16567
            if (field.type == org.apache.thrift.protocol.TType.I64) {
16568
              this.merchantTxnId = iprot.readI64();
16569
              setMerchantTxnIdIsSet(true);
16570
            } else { 
16571
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16572
            }
16573
            break;
16574
          case 2: // AMOUNT
16575
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
16576
              this.amount = iprot.readDouble();
16577
              setAmountIsSet(true);
16578
            } else { 
16579
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16580
            }
16581
            break;
16582
          case 3: // XFER_BY
16583
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
16584
              this.xferBy = iprot.readString();
16585
            } else { 
16586
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16587
            }
16588
            break;
16589
          case 4: // XFER_TXN_ID
16590
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
16591
              this.xferTxnId = iprot.readString();
16592
            } else { 
16593
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16594
            }
16595
            break;
16596
          case 5: // XFER_DATE
16597
            if (field.type == org.apache.thrift.protocol.TType.I64) {
16598
              this.xferDate = iprot.readI64();
16599
              setXferDateIsSet(true);
16600
            } else { 
16601
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16602
            }
16603
            break;
16604
          default:
16605
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16606
        }
16607
        iprot.readFieldEnd();
16608
      }
16609
      iprot.readStructEnd();
16610
      validate();
16611
    }
16612
 
16613
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16614
      validate();
16615
 
16616
      oprot.writeStructBegin(STRUCT_DESC);
16617
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
16618
      oprot.writeI64(this.merchantTxnId);
16619
      oprot.writeFieldEnd();
16620
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
16621
      oprot.writeDouble(this.amount);
16622
      oprot.writeFieldEnd();
16623
      if (this.xferBy != null) {
16624
        oprot.writeFieldBegin(XFER_BY_FIELD_DESC);
16625
        oprot.writeString(this.xferBy);
16626
        oprot.writeFieldEnd();
16627
      }
16628
      if (this.xferTxnId != null) {
16629
        oprot.writeFieldBegin(XFER_TXN_ID_FIELD_DESC);
16630
        oprot.writeString(this.xferTxnId);
16631
        oprot.writeFieldEnd();
16632
      }
16633
      oprot.writeFieldBegin(XFER_DATE_FIELD_DESC);
16634
      oprot.writeI64(this.xferDate);
16635
      oprot.writeFieldEnd();
16636
      oprot.writeFieldStop();
16637
      oprot.writeStructEnd();
16638
    }
16639
 
16640
    @Override
16641
    public String toString() {
16642
      StringBuilder sb = new StringBuilder("partiallyCapturePayment_args(");
16643
      boolean first = true;
16644
 
16645
      sb.append("merchantTxnId:");
16646
      sb.append(this.merchantTxnId);
16647
      first = false;
16648
      if (!first) sb.append(", ");
16649
      sb.append("amount:");
16650
      sb.append(this.amount);
16651
      first = false;
16652
      if (!first) sb.append(", ");
16653
      sb.append("xferBy:");
16654
      if (this.xferBy == null) {
16655
        sb.append("null");
16656
      } else {
16657
        sb.append(this.xferBy);
16658
      }
16659
      first = false;
16660
      if (!first) sb.append(", ");
16661
      sb.append("xferTxnId:");
16662
      if (this.xferTxnId == null) {
16663
        sb.append("null");
16664
      } else {
16665
        sb.append(this.xferTxnId);
16666
      }
16667
      first = false;
16668
      if (!first) sb.append(", ");
16669
      sb.append("xferDate:");
16670
      sb.append(this.xferDate);
16671
      first = false;
16672
      sb.append(")");
16673
      return sb.toString();
16674
    }
16675
 
16676
    public void validate() throws org.apache.thrift.TException {
16677
      // check for required fields
16678
    }
16679
 
16680
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16681
      try {
16682
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16683
      } catch (org.apache.thrift.TException te) {
16684
        throw new java.io.IOException(te);
16685
      }
16686
    }
16687
 
16688
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16689
      try {
16690
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16691
      } catch (org.apache.thrift.TException te) {
16692
        throw new java.io.IOException(te);
16693
      }
16694
    }
16695
 
16696
  }
16697
 
16698
  public static class partiallyCapturePayment_result implements org.apache.thrift.TBase<partiallyCapturePayment_result, partiallyCapturePayment_result._Fields>, java.io.Serializable, Cloneable   {
16699
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("partiallyCapturePayment_result");
16700
 
16701
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
16702
    private static final org.apache.thrift.protocol.TField PE_FIELD_DESC = new org.apache.thrift.protocol.TField("pe", org.apache.thrift.protocol.TType.STRUCT, (short)1);
16703
 
16704
    private boolean success; // required
16705
    private PaymentException pe; // required
16706
 
16707
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16708
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16709
      SUCCESS((short)0, "success"),
16710
      PE((short)1, "pe");
16711
 
16712
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16713
 
16714
      static {
16715
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16716
          byName.put(field.getFieldName(), field);
16717
        }
16718
      }
16719
 
16720
      /**
16721
       * Find the _Fields constant that matches fieldId, or null if its not found.
16722
       */
16723
      public static _Fields findByThriftId(int fieldId) {
16724
        switch(fieldId) {
16725
          case 0: // SUCCESS
16726
            return SUCCESS;
16727
          case 1: // PE
16728
            return PE;
16729
          default:
16730
            return null;
16731
        }
16732
      }
16733
 
16734
      /**
16735
       * Find the _Fields constant that matches fieldId, throwing an exception
16736
       * if it is not found.
16737
       */
16738
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16739
        _Fields fields = findByThriftId(fieldId);
16740
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16741
        return fields;
16742
      }
16743
 
16744
      /**
16745
       * Find the _Fields constant that matches name, or null if its not found.
16746
       */
16747
      public static _Fields findByName(String name) {
16748
        return byName.get(name);
16749
      }
16750
 
16751
      private final short _thriftId;
16752
      private final String _fieldName;
16753
 
16754
      _Fields(short thriftId, String fieldName) {
16755
        _thriftId = thriftId;
16756
        _fieldName = fieldName;
16757
      }
16758
 
16759
      public short getThriftFieldId() {
16760
        return _thriftId;
16761
      }
16762
 
16763
      public String getFieldName() {
16764
        return _fieldName;
16765
      }
16766
    }
16767
 
16768
    // isset id assignments
16769
    private static final int __SUCCESS_ISSET_ID = 0;
16770
    private BitSet __isset_bit_vector = new BitSet(1);
16771
 
16772
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16773
    static {
16774
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16775
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16776
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
16777
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16778
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
16779
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16780
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(partiallyCapturePayment_result.class, metaDataMap);
16781
    }
16782
 
16783
    public partiallyCapturePayment_result() {
16784
    }
16785
 
16786
    public partiallyCapturePayment_result(
16787
      boolean success,
16788
      PaymentException pe)
16789
    {
16790
      this();
16791
      this.success = success;
16792
      setSuccessIsSet(true);
16793
      this.pe = pe;
16794
    }
16795
 
16796
    /**
16797
     * Performs a deep copy on <i>other</i>.
16798
     */
16799
    public partiallyCapturePayment_result(partiallyCapturePayment_result other) {
16800
      __isset_bit_vector.clear();
16801
      __isset_bit_vector.or(other.__isset_bit_vector);
16802
      this.success = other.success;
16803
      if (other.isSetPe()) {
16804
        this.pe = new PaymentException(other.pe);
16805
      }
16806
    }
16807
 
16808
    public partiallyCapturePayment_result deepCopy() {
16809
      return new partiallyCapturePayment_result(this);
16810
    }
16811
 
16812
    @Override
16813
    public void clear() {
16814
      setSuccessIsSet(false);
16815
      this.success = false;
16816
      this.pe = null;
16817
    }
16818
 
16819
    public boolean isSuccess() {
16820
      return this.success;
16821
    }
16822
 
16823
    public void setSuccess(boolean success) {
16824
      this.success = success;
16825
      setSuccessIsSet(true);
16826
    }
16827
 
16828
    public void unsetSuccess() {
16829
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
16830
    }
16831
 
16832
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
16833
    public boolean isSetSuccess() {
16834
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
16835
    }
16836
 
16837
    public void setSuccessIsSet(boolean value) {
16838
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
16839
    }
16840
 
16841
    public PaymentException getPe() {
16842
      return this.pe;
16843
    }
16844
 
16845
    public void setPe(PaymentException pe) {
16846
      this.pe = pe;
16847
    }
16848
 
16849
    public void unsetPe() {
16850
      this.pe = null;
16851
    }
16852
 
16853
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
16854
    public boolean isSetPe() {
16855
      return this.pe != null;
16856
    }
16857
 
16858
    public void setPeIsSet(boolean value) {
16859
      if (!value) {
16860
        this.pe = null;
16861
      }
16862
    }
16863
 
16864
    public void setFieldValue(_Fields field, Object value) {
16865
      switch (field) {
16866
      case SUCCESS:
16867
        if (value == null) {
16868
          unsetSuccess();
16869
        } else {
16870
          setSuccess((Boolean)value);
16871
        }
16872
        break;
16873
 
16874
      case PE:
16875
        if (value == null) {
16876
          unsetPe();
16877
        } else {
16878
          setPe((PaymentException)value);
16879
        }
16880
        break;
16881
 
16882
      }
16883
    }
16884
 
16885
    public Object getFieldValue(_Fields field) {
16886
      switch (field) {
16887
      case SUCCESS:
16888
        return Boolean.valueOf(isSuccess());
16889
 
16890
      case PE:
16891
        return getPe();
16892
 
16893
      }
16894
      throw new IllegalStateException();
16895
    }
16896
 
16897
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16898
    public boolean isSet(_Fields field) {
16899
      if (field == null) {
16900
        throw new IllegalArgumentException();
16901
      }
16902
 
16903
      switch (field) {
16904
      case SUCCESS:
16905
        return isSetSuccess();
16906
      case PE:
16907
        return isSetPe();
16908
      }
16909
      throw new IllegalStateException();
16910
    }
16911
 
16912
    @Override
16913
    public boolean equals(Object that) {
16914
      if (that == null)
16915
        return false;
16916
      if (that instanceof partiallyCapturePayment_result)
16917
        return this.equals((partiallyCapturePayment_result)that);
16918
      return false;
16919
    }
16920
 
16921
    public boolean equals(partiallyCapturePayment_result that) {
16922
      if (that == null)
16923
        return false;
16924
 
16925
      boolean this_present_success = true;
16926
      boolean that_present_success = true;
16927
      if (this_present_success || that_present_success) {
16928
        if (!(this_present_success && that_present_success))
16929
          return false;
16930
        if (this.success != that.success)
16931
          return false;
16932
      }
16933
 
16934
      boolean this_present_pe = true && this.isSetPe();
16935
      boolean that_present_pe = true && that.isSetPe();
16936
      if (this_present_pe || that_present_pe) {
16937
        if (!(this_present_pe && that_present_pe))
16938
          return false;
16939
        if (!this.pe.equals(that.pe))
16940
          return false;
16941
      }
16942
 
16943
      return true;
16944
    }
16945
 
16946
    @Override
16947
    public int hashCode() {
16948
      return 0;
16949
    }
16950
 
16951
    public int compareTo(partiallyCapturePayment_result other) {
16952
      if (!getClass().equals(other.getClass())) {
16953
        return getClass().getName().compareTo(other.getClass().getName());
16954
      }
16955
 
16956
      int lastComparison = 0;
16957
      partiallyCapturePayment_result typedOther = (partiallyCapturePayment_result)other;
16958
 
16959
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
16960
      if (lastComparison != 0) {
16961
        return lastComparison;
16962
      }
16963
      if (isSetSuccess()) {
16964
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
16965
        if (lastComparison != 0) {
16966
          return lastComparison;
16967
        }
16968
      }
16969
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
16970
      if (lastComparison != 0) {
16971
        return lastComparison;
16972
      }
16973
      if (isSetPe()) {
16974
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
16975
        if (lastComparison != 0) {
16976
          return lastComparison;
16977
        }
16978
      }
16979
      return 0;
16980
    }
16981
 
16982
    public _Fields fieldForId(int fieldId) {
16983
      return _Fields.findByThriftId(fieldId);
16984
    }
16985
 
16986
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16987
      org.apache.thrift.protocol.TField field;
16988
      iprot.readStructBegin();
16989
      while (true)
16990
      {
16991
        field = iprot.readFieldBegin();
16992
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16993
          break;
16994
        }
16995
        switch (field.id) {
16996
          case 0: // SUCCESS
16997
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
16998
              this.success = iprot.readBool();
16999
              setSuccessIsSet(true);
17000
            } else { 
17001
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17002
            }
17003
            break;
17004
          case 1: // PE
17005
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
17006
              this.pe = new PaymentException();
17007
              this.pe.read(iprot);
17008
            } else { 
17009
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17010
            }
17011
            break;
17012
          default:
17013
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17014
        }
17015
        iprot.readFieldEnd();
17016
      }
17017
      iprot.readStructEnd();
17018
      validate();
17019
    }
17020
 
17021
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17022
      oprot.writeStructBegin(STRUCT_DESC);
17023
 
17024
      if (this.isSetSuccess()) {
17025
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17026
        oprot.writeBool(this.success);
17027
        oprot.writeFieldEnd();
17028
      } else if (this.isSetPe()) {
17029
        oprot.writeFieldBegin(PE_FIELD_DESC);
17030
        this.pe.write(oprot);
17031
        oprot.writeFieldEnd();
17032
      }
17033
      oprot.writeFieldStop();
17034
      oprot.writeStructEnd();
17035
    }
17036
 
17037
    @Override
17038
    public String toString() {
17039
      StringBuilder sb = new StringBuilder("partiallyCapturePayment_result(");
17040
      boolean first = true;
17041
 
17042
      sb.append("success:");
17043
      sb.append(this.success);
17044
      first = false;
17045
      if (!first) sb.append(", ");
17046
      sb.append("pe:");
17047
      if (this.pe == null) {
17048
        sb.append("null");
17049
      } else {
17050
        sb.append(this.pe);
17051
      }
17052
      first = false;
17053
      sb.append(")");
17054
      return sb.toString();
17055
    }
17056
 
17057
    public void validate() throws org.apache.thrift.TException {
17058
      // check for required fields
17059
    }
17060
 
17061
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17062
      try {
17063
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17064
      } catch (org.apache.thrift.TException te) {
17065
        throw new java.io.IOException(te);
17066
      }
17067
    }
17068
 
17069
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17070
      try {
17071
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17072
      } catch (org.apache.thrift.TException te) {
17073
        throw new java.io.IOException(te);
17074
      }
17075
    }
17076
 
17077
  }
17078
 
4008 mandeep.dh 17079
  public static class getPaymentsRequiringExtraProcessing_args implements org.apache.thrift.TBase<getPaymentsRequiringExtraProcessing_args, getPaymentsRequiringExtraProcessing_args._Fields>, java.io.Serializable, Cloneable   {
17080
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsRequiringExtraProcessing_args");
17081
 
17082
    private static final org.apache.thrift.protocol.TField CATEGORY_FIELD_DESC = new org.apache.thrift.protocol.TField("category", org.apache.thrift.protocol.TType.I32, (short)1);
17083
 
17084
    private ExtraPaymentProcessingType category; // required
17085
 
17086
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17087
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17088
      /**
17089
       * 
17090
       * @see ExtraPaymentProcessingType
17091
       */
17092
      CATEGORY((short)1, "category");
17093
 
17094
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17095
 
17096
      static {
17097
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17098
          byName.put(field.getFieldName(), field);
17099
        }
17100
      }
17101
 
17102
      /**
17103
       * Find the _Fields constant that matches fieldId, or null if its not found.
17104
       */
17105
      public static _Fields findByThriftId(int fieldId) {
17106
        switch(fieldId) {
17107
          case 1: // CATEGORY
17108
            return CATEGORY;
17109
          default:
17110
            return null;
17111
        }
17112
      }
17113
 
17114
      /**
17115
       * Find the _Fields constant that matches fieldId, throwing an exception
17116
       * if it is not found.
17117
       */
17118
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17119
        _Fields fields = findByThriftId(fieldId);
17120
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17121
        return fields;
17122
      }
17123
 
17124
      /**
17125
       * Find the _Fields constant that matches name, or null if its not found.
17126
       */
17127
      public static _Fields findByName(String name) {
17128
        return byName.get(name);
17129
      }
17130
 
17131
      private final short _thriftId;
17132
      private final String _fieldName;
17133
 
17134
      _Fields(short thriftId, String fieldName) {
17135
        _thriftId = thriftId;
17136
        _fieldName = fieldName;
17137
      }
17138
 
17139
      public short getThriftFieldId() {
17140
        return _thriftId;
17141
      }
17142
 
17143
      public String getFieldName() {
17144
        return _fieldName;
17145
      }
17146
    }
17147
 
17148
    // isset id assignments
17149
 
17150
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17151
    static {
17152
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17153
      tmpMap.put(_Fields.CATEGORY, new org.apache.thrift.meta_data.FieldMetaData("category", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17154
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ExtraPaymentProcessingType.class)));
17155
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17156
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsRequiringExtraProcessing_args.class, metaDataMap);
17157
    }
17158
 
17159
    public getPaymentsRequiringExtraProcessing_args() {
17160
    }
17161
 
17162
    public getPaymentsRequiringExtraProcessing_args(
17163
      ExtraPaymentProcessingType category)
17164
    {
17165
      this();
17166
      this.category = category;
17167
    }
17168
 
17169
    /**
17170
     * Performs a deep copy on <i>other</i>.
17171
     */
17172
    public getPaymentsRequiringExtraProcessing_args(getPaymentsRequiringExtraProcessing_args other) {
17173
      if (other.isSetCategory()) {
17174
        this.category = other.category;
17175
      }
17176
    }
17177
 
17178
    public getPaymentsRequiringExtraProcessing_args deepCopy() {
17179
      return new getPaymentsRequiringExtraProcessing_args(this);
17180
    }
17181
 
17182
    @Override
17183
    public void clear() {
17184
      this.category = null;
17185
    }
17186
 
17187
    /**
17188
     * 
17189
     * @see ExtraPaymentProcessingType
17190
     */
17191
    public ExtraPaymentProcessingType getCategory() {
17192
      return this.category;
17193
    }
17194
 
17195
    /**
17196
     * 
17197
     * @see ExtraPaymentProcessingType
17198
     */
17199
    public void setCategory(ExtraPaymentProcessingType category) {
17200
      this.category = category;
17201
    }
17202
 
17203
    public void unsetCategory() {
17204
      this.category = null;
17205
    }
17206
 
17207
    /** Returns true if field category is set (has been assigned a value) and false otherwise */
17208
    public boolean isSetCategory() {
17209
      return this.category != null;
17210
    }
17211
 
17212
    public void setCategoryIsSet(boolean value) {
17213
      if (!value) {
17214
        this.category = null;
17215
      }
17216
    }
17217
 
17218
    public void setFieldValue(_Fields field, Object value) {
17219
      switch (field) {
17220
      case CATEGORY:
17221
        if (value == null) {
17222
          unsetCategory();
17223
        } else {
17224
          setCategory((ExtraPaymentProcessingType)value);
17225
        }
17226
        break;
17227
 
17228
      }
17229
    }
17230
 
17231
    public Object getFieldValue(_Fields field) {
17232
      switch (field) {
17233
      case CATEGORY:
17234
        return getCategory();
17235
 
17236
      }
17237
      throw new IllegalStateException();
17238
    }
17239
 
17240
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17241
    public boolean isSet(_Fields field) {
17242
      if (field == null) {
17243
        throw new IllegalArgumentException();
17244
      }
17245
 
17246
      switch (field) {
17247
      case CATEGORY:
17248
        return isSetCategory();
17249
      }
17250
      throw new IllegalStateException();
17251
    }
17252
 
17253
    @Override
17254
    public boolean equals(Object that) {
17255
      if (that == null)
17256
        return false;
17257
      if (that instanceof getPaymentsRequiringExtraProcessing_args)
17258
        return this.equals((getPaymentsRequiringExtraProcessing_args)that);
17259
      return false;
17260
    }
17261
 
17262
    public boolean equals(getPaymentsRequiringExtraProcessing_args that) {
17263
      if (that == null)
17264
        return false;
17265
 
17266
      boolean this_present_category = true && this.isSetCategory();
17267
      boolean that_present_category = true && that.isSetCategory();
17268
      if (this_present_category || that_present_category) {
17269
        if (!(this_present_category && that_present_category))
17270
          return false;
17271
        if (!this.category.equals(that.category))
17272
          return false;
17273
      }
17274
 
17275
      return true;
17276
    }
17277
 
17278
    @Override
17279
    public int hashCode() {
17280
      return 0;
17281
    }
17282
 
17283
    public int compareTo(getPaymentsRequiringExtraProcessing_args other) {
17284
      if (!getClass().equals(other.getClass())) {
17285
        return getClass().getName().compareTo(other.getClass().getName());
17286
      }
17287
 
17288
      int lastComparison = 0;
17289
      getPaymentsRequiringExtraProcessing_args typedOther = (getPaymentsRequiringExtraProcessing_args)other;
17290
 
17291
      lastComparison = Boolean.valueOf(isSetCategory()).compareTo(typedOther.isSetCategory());
17292
      if (lastComparison != 0) {
17293
        return lastComparison;
17294
      }
17295
      if (isSetCategory()) {
17296
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.category, typedOther.category);
17297
        if (lastComparison != 0) {
17298
          return lastComparison;
17299
        }
17300
      }
17301
      return 0;
17302
    }
17303
 
17304
    public _Fields fieldForId(int fieldId) {
17305
      return _Fields.findByThriftId(fieldId);
17306
    }
17307
 
17308
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17309
      org.apache.thrift.protocol.TField field;
17310
      iprot.readStructBegin();
17311
      while (true)
17312
      {
17313
        field = iprot.readFieldBegin();
17314
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17315
          break;
17316
        }
17317
        switch (field.id) {
17318
          case 1: // CATEGORY
17319
            if (field.type == org.apache.thrift.protocol.TType.I32) {
17320
              this.category = ExtraPaymentProcessingType.findByValue(iprot.readI32());
17321
            } else { 
17322
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17323
            }
17324
            break;
17325
          default:
17326
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17327
        }
17328
        iprot.readFieldEnd();
17329
      }
17330
      iprot.readStructEnd();
17331
      validate();
17332
    }
17333
 
17334
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17335
      validate();
17336
 
17337
      oprot.writeStructBegin(STRUCT_DESC);
17338
      if (this.category != null) {
17339
        oprot.writeFieldBegin(CATEGORY_FIELD_DESC);
17340
        oprot.writeI32(this.category.getValue());
17341
        oprot.writeFieldEnd();
17342
      }
17343
      oprot.writeFieldStop();
17344
      oprot.writeStructEnd();
17345
    }
17346
 
17347
    @Override
17348
    public String toString() {
17349
      StringBuilder sb = new StringBuilder("getPaymentsRequiringExtraProcessing_args(");
17350
      boolean first = true;
17351
 
17352
      sb.append("category:");
17353
      if (this.category == null) {
17354
        sb.append("null");
17355
      } else {
17356
        sb.append(this.category);
17357
      }
17358
      first = false;
17359
      sb.append(")");
17360
      return sb.toString();
17361
    }
17362
 
17363
    public void validate() throws org.apache.thrift.TException {
17364
      // check for required fields
17365
    }
17366
 
17367
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17368
      try {
17369
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17370
      } catch (org.apache.thrift.TException te) {
17371
        throw new java.io.IOException(te);
17372
      }
17373
    }
17374
 
17375
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17376
      try {
17377
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17378
      } catch (org.apache.thrift.TException te) {
17379
        throw new java.io.IOException(te);
17380
      }
17381
    }
17382
 
17383
  }
17384
 
17385
  public static class getPaymentsRequiringExtraProcessing_result implements org.apache.thrift.TBase<getPaymentsRequiringExtraProcessing_result, getPaymentsRequiringExtraProcessing_result._Fields>, java.io.Serializable, Cloneable   {
17386
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsRequiringExtraProcessing_result");
17387
 
17388
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
17389
 
17390
    private List<Long> success; // required
17391
 
17392
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17393
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17394
      SUCCESS((short)0, "success");
17395
 
17396
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17397
 
17398
      static {
17399
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17400
          byName.put(field.getFieldName(), field);
17401
        }
17402
      }
17403
 
17404
      /**
17405
       * Find the _Fields constant that matches fieldId, or null if its not found.
17406
       */
17407
      public static _Fields findByThriftId(int fieldId) {
17408
        switch(fieldId) {
17409
          case 0: // SUCCESS
17410
            return SUCCESS;
17411
          default:
17412
            return null;
17413
        }
17414
      }
17415
 
17416
      /**
17417
       * Find the _Fields constant that matches fieldId, throwing an exception
17418
       * if it is not found.
17419
       */
17420
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17421
        _Fields fields = findByThriftId(fieldId);
17422
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17423
        return fields;
17424
      }
17425
 
17426
      /**
17427
       * Find the _Fields constant that matches name, or null if its not found.
17428
       */
17429
      public static _Fields findByName(String name) {
17430
        return byName.get(name);
17431
      }
17432
 
17433
      private final short _thriftId;
17434
      private final String _fieldName;
17435
 
17436
      _Fields(short thriftId, String fieldName) {
17437
        _thriftId = thriftId;
17438
        _fieldName = fieldName;
17439
      }
17440
 
17441
      public short getThriftFieldId() {
17442
        return _thriftId;
17443
      }
17444
 
17445
      public String getFieldName() {
17446
        return _fieldName;
17447
      }
17448
    }
17449
 
17450
    // isset id assignments
17451
 
17452
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17453
    static {
17454
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17455
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17456
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
17457
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
17458
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17459
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsRequiringExtraProcessing_result.class, metaDataMap);
17460
    }
17461
 
17462
    public getPaymentsRequiringExtraProcessing_result() {
17463
    }
17464
 
17465
    public getPaymentsRequiringExtraProcessing_result(
17466
      List<Long> success)
17467
    {
17468
      this();
17469
      this.success = success;
17470
    }
17471
 
17472
    /**
17473
     * Performs a deep copy on <i>other</i>.
17474
     */
17475
    public getPaymentsRequiringExtraProcessing_result(getPaymentsRequiringExtraProcessing_result other) {
17476
      if (other.isSetSuccess()) {
17477
        List<Long> __this__success = new ArrayList<Long>();
17478
        for (Long other_element : other.success) {
17479
          __this__success.add(other_element);
17480
        }
17481
        this.success = __this__success;
17482
      }
17483
    }
17484
 
17485
    public getPaymentsRequiringExtraProcessing_result deepCopy() {
17486
      return new getPaymentsRequiringExtraProcessing_result(this);
17487
    }
17488
 
17489
    @Override
17490
    public void clear() {
17491
      this.success = null;
17492
    }
17493
 
17494
    public int getSuccessSize() {
17495
      return (this.success == null) ? 0 : this.success.size();
17496
    }
17497
 
17498
    public java.util.Iterator<Long> getSuccessIterator() {
17499
      return (this.success == null) ? null : this.success.iterator();
17500
    }
17501
 
17502
    public void addToSuccess(long elem) {
17503
      if (this.success == null) {
17504
        this.success = new ArrayList<Long>();
17505
      }
17506
      this.success.add(elem);
17507
    }
17508
 
17509
    public List<Long> getSuccess() {
17510
      return this.success;
17511
    }
17512
 
17513
    public void setSuccess(List<Long> success) {
17514
      this.success = success;
17515
    }
17516
 
17517
    public void unsetSuccess() {
17518
      this.success = null;
17519
    }
17520
 
17521
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17522
    public boolean isSetSuccess() {
17523
      return this.success != null;
17524
    }
17525
 
17526
    public void setSuccessIsSet(boolean value) {
17527
      if (!value) {
17528
        this.success = null;
17529
      }
17530
    }
17531
 
17532
    public void setFieldValue(_Fields field, Object value) {
17533
      switch (field) {
17534
      case SUCCESS:
17535
        if (value == null) {
17536
          unsetSuccess();
17537
        } else {
17538
          setSuccess((List<Long>)value);
17539
        }
17540
        break;
17541
 
17542
      }
17543
    }
17544
 
17545
    public Object getFieldValue(_Fields field) {
17546
      switch (field) {
17547
      case SUCCESS:
17548
        return getSuccess();
17549
 
17550
      }
17551
      throw new IllegalStateException();
17552
    }
17553
 
17554
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17555
    public boolean isSet(_Fields field) {
17556
      if (field == null) {
17557
        throw new IllegalArgumentException();
17558
      }
17559
 
17560
      switch (field) {
17561
      case SUCCESS:
17562
        return isSetSuccess();
17563
      }
17564
      throw new IllegalStateException();
17565
    }
17566
 
17567
    @Override
17568
    public boolean equals(Object that) {
17569
      if (that == null)
17570
        return false;
17571
      if (that instanceof getPaymentsRequiringExtraProcessing_result)
17572
        return this.equals((getPaymentsRequiringExtraProcessing_result)that);
17573
      return false;
17574
    }
17575
 
17576
    public boolean equals(getPaymentsRequiringExtraProcessing_result that) {
17577
      if (that == null)
17578
        return false;
17579
 
17580
      boolean this_present_success = true && this.isSetSuccess();
17581
      boolean that_present_success = true && that.isSetSuccess();
17582
      if (this_present_success || that_present_success) {
17583
        if (!(this_present_success && that_present_success))
17584
          return false;
17585
        if (!this.success.equals(that.success))
17586
          return false;
17587
      }
17588
 
17589
      return true;
17590
    }
17591
 
17592
    @Override
17593
    public int hashCode() {
17594
      return 0;
17595
    }
17596
 
17597
    public int compareTo(getPaymentsRequiringExtraProcessing_result other) {
17598
      if (!getClass().equals(other.getClass())) {
17599
        return getClass().getName().compareTo(other.getClass().getName());
17600
      }
17601
 
17602
      int lastComparison = 0;
17603
      getPaymentsRequiringExtraProcessing_result typedOther = (getPaymentsRequiringExtraProcessing_result)other;
17604
 
17605
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17606
      if (lastComparison != 0) {
17607
        return lastComparison;
17608
      }
17609
      if (isSetSuccess()) {
17610
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17611
        if (lastComparison != 0) {
17612
          return lastComparison;
17613
        }
17614
      }
17615
      return 0;
17616
    }
17617
 
17618
    public _Fields fieldForId(int fieldId) {
17619
      return _Fields.findByThriftId(fieldId);
17620
    }
17621
 
17622
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17623
      org.apache.thrift.protocol.TField field;
17624
      iprot.readStructBegin();
17625
      while (true)
17626
      {
17627
        field = iprot.readFieldBegin();
17628
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17629
          break;
17630
        }
17631
        switch (field.id) {
17632
          case 0: // SUCCESS
17633
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
17634
              {
4600 varun.gupt 17635
                org.apache.thrift.protocol.TList _list40 = iprot.readListBegin();
17636
                this.success = new ArrayList<Long>(_list40.size);
17637
                for (int _i41 = 0; _i41 < _list40.size; ++_i41)
4008 mandeep.dh 17638
                {
4600 varun.gupt 17639
                  long _elem42; // required
17640
                  _elem42 = iprot.readI64();
17641
                  this.success.add(_elem42);
4008 mandeep.dh 17642
                }
17643
                iprot.readListEnd();
17644
              }
17645
            } else { 
17646
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17647
            }
17648
            break;
17649
          default:
17650
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17651
        }
17652
        iprot.readFieldEnd();
17653
      }
17654
      iprot.readStructEnd();
17655
      validate();
17656
    }
17657
 
17658
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17659
      oprot.writeStructBegin(STRUCT_DESC);
17660
 
17661
      if (this.isSetSuccess()) {
17662
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17663
        {
17664
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
4600 varun.gupt 17665
          for (long _iter43 : this.success)
4008 mandeep.dh 17666
          {
4600 varun.gupt 17667
            oprot.writeI64(_iter43);
4008 mandeep.dh 17668
          }
17669
          oprot.writeListEnd();
17670
        }
17671
        oprot.writeFieldEnd();
17672
      }
17673
      oprot.writeFieldStop();
17674
      oprot.writeStructEnd();
17675
    }
17676
 
17677
    @Override
17678
    public String toString() {
17679
      StringBuilder sb = new StringBuilder("getPaymentsRequiringExtraProcessing_result(");
17680
      boolean first = true;
17681
 
17682
      sb.append("success:");
17683
      if (this.success == null) {
17684
        sb.append("null");
17685
      } else {
17686
        sb.append(this.success);
17687
      }
17688
      first = false;
17689
      sb.append(")");
17690
      return sb.toString();
17691
    }
17692
 
17693
    public void validate() throws org.apache.thrift.TException {
17694
      // check for required fields
17695
    }
17696
 
17697
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17698
      try {
17699
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17700
      } catch (org.apache.thrift.TException te) {
17701
        throw new java.io.IOException(te);
17702
      }
17703
    }
17704
 
17705
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17706
      try {
17707
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17708
      } catch (org.apache.thrift.TException te) {
17709
        throw new java.io.IOException(te);
17710
      }
17711
    }
17712
 
17713
  }
17714
 
17715
  public static class markPaymentAsProcessed_args implements org.apache.thrift.TBase<markPaymentAsProcessed_args, markPaymentAsProcessed_args._Fields>, java.io.Serializable, Cloneable   {
17716
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markPaymentAsProcessed_args");
17717
 
17718
    private static final org.apache.thrift.protocol.TField PAYMENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("paymentId", org.apache.thrift.protocol.TType.I64, (short)1);
17719
    private static final org.apache.thrift.protocol.TField CATEGORY_FIELD_DESC = new org.apache.thrift.protocol.TField("category", org.apache.thrift.protocol.TType.I32, (short)2);
17720
 
17721
    private long paymentId; // required
17722
    private ExtraPaymentProcessingType category; // required
17723
 
17724
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17725
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17726
      PAYMENT_ID((short)1, "paymentId"),
17727
      /**
17728
       * 
17729
       * @see ExtraPaymentProcessingType
17730
       */
17731
      CATEGORY((short)2, "category");
17732
 
17733
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17734
 
17735
      static {
17736
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17737
          byName.put(field.getFieldName(), field);
17738
        }
17739
      }
17740
 
17741
      /**
17742
       * Find the _Fields constant that matches fieldId, or null if its not found.
17743
       */
17744
      public static _Fields findByThriftId(int fieldId) {
17745
        switch(fieldId) {
17746
          case 1: // PAYMENT_ID
17747
            return PAYMENT_ID;
17748
          case 2: // CATEGORY
17749
            return CATEGORY;
17750
          default:
17751
            return null;
17752
        }
17753
      }
17754
 
17755
      /**
17756
       * Find the _Fields constant that matches fieldId, throwing an exception
17757
       * if it is not found.
17758
       */
17759
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17760
        _Fields fields = findByThriftId(fieldId);
17761
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17762
        return fields;
17763
      }
17764
 
17765
      /**
17766
       * Find the _Fields constant that matches name, or null if its not found.
17767
       */
17768
      public static _Fields findByName(String name) {
17769
        return byName.get(name);
17770
      }
17771
 
17772
      private final short _thriftId;
17773
      private final String _fieldName;
17774
 
17775
      _Fields(short thriftId, String fieldName) {
17776
        _thriftId = thriftId;
17777
        _fieldName = fieldName;
17778
      }
17779
 
17780
      public short getThriftFieldId() {
17781
        return _thriftId;
17782
      }
17783
 
17784
      public String getFieldName() {
17785
        return _fieldName;
17786
      }
17787
    }
17788
 
17789
    // isset id assignments
17790
    private static final int __PAYMENTID_ISSET_ID = 0;
17791
    private BitSet __isset_bit_vector = new BitSet(1);
17792
 
17793
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17794
    static {
17795
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17796
      tmpMap.put(_Fields.PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("paymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17797
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17798
      tmpMap.put(_Fields.CATEGORY, new org.apache.thrift.meta_data.FieldMetaData("category", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17799
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ExtraPaymentProcessingType.class)));
17800
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17801
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markPaymentAsProcessed_args.class, metaDataMap);
17802
    }
17803
 
17804
    public markPaymentAsProcessed_args() {
17805
    }
17806
 
17807
    public markPaymentAsProcessed_args(
17808
      long paymentId,
17809
      ExtraPaymentProcessingType category)
17810
    {
17811
      this();
17812
      this.paymentId = paymentId;
17813
      setPaymentIdIsSet(true);
17814
      this.category = category;
17815
    }
17816
 
17817
    /**
17818
     * Performs a deep copy on <i>other</i>.
17819
     */
17820
    public markPaymentAsProcessed_args(markPaymentAsProcessed_args other) {
17821
      __isset_bit_vector.clear();
17822
      __isset_bit_vector.or(other.__isset_bit_vector);
17823
      this.paymentId = other.paymentId;
17824
      if (other.isSetCategory()) {
17825
        this.category = other.category;
17826
      }
17827
    }
17828
 
17829
    public markPaymentAsProcessed_args deepCopy() {
17830
      return new markPaymentAsProcessed_args(this);
17831
    }
17832
 
17833
    @Override
17834
    public void clear() {
17835
      setPaymentIdIsSet(false);
17836
      this.paymentId = 0;
17837
      this.category = null;
17838
    }
17839
 
17840
    public long getPaymentId() {
17841
      return this.paymentId;
17842
    }
17843
 
17844
    public void setPaymentId(long paymentId) {
17845
      this.paymentId = paymentId;
17846
      setPaymentIdIsSet(true);
17847
    }
17848
 
17849
    public void unsetPaymentId() {
17850
      __isset_bit_vector.clear(__PAYMENTID_ISSET_ID);
17851
    }
17852
 
17853
    /** Returns true if field paymentId is set (has been assigned a value) and false otherwise */
17854
    public boolean isSetPaymentId() {
17855
      return __isset_bit_vector.get(__PAYMENTID_ISSET_ID);
17856
    }
17857
 
17858
    public void setPaymentIdIsSet(boolean value) {
17859
      __isset_bit_vector.set(__PAYMENTID_ISSET_ID, value);
17860
    }
17861
 
17862
    /**
17863
     * 
17864
     * @see ExtraPaymentProcessingType
17865
     */
17866
    public ExtraPaymentProcessingType getCategory() {
17867
      return this.category;
17868
    }
17869
 
17870
    /**
17871
     * 
17872
     * @see ExtraPaymentProcessingType
17873
     */
17874
    public void setCategory(ExtraPaymentProcessingType category) {
17875
      this.category = category;
17876
    }
17877
 
17878
    public void unsetCategory() {
17879
      this.category = null;
17880
    }
17881
 
17882
    /** Returns true if field category is set (has been assigned a value) and false otherwise */
17883
    public boolean isSetCategory() {
17884
      return this.category != null;
17885
    }
17886
 
17887
    public void setCategoryIsSet(boolean value) {
17888
      if (!value) {
17889
        this.category = null;
17890
      }
17891
    }
17892
 
17893
    public void setFieldValue(_Fields field, Object value) {
17894
      switch (field) {
17895
      case PAYMENT_ID:
17896
        if (value == null) {
17897
          unsetPaymentId();
17898
        } else {
17899
          setPaymentId((Long)value);
17900
        }
17901
        break;
17902
 
17903
      case CATEGORY:
17904
        if (value == null) {
17905
          unsetCategory();
17906
        } else {
17907
          setCategory((ExtraPaymentProcessingType)value);
17908
        }
17909
        break;
17910
 
17911
      }
17912
    }
17913
 
17914
    public Object getFieldValue(_Fields field) {
17915
      switch (field) {
17916
      case PAYMENT_ID:
17917
        return Long.valueOf(getPaymentId());
17918
 
17919
      case CATEGORY:
17920
        return getCategory();
17921
 
17922
      }
17923
      throw new IllegalStateException();
17924
    }
17925
 
17926
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17927
    public boolean isSet(_Fields field) {
17928
      if (field == null) {
17929
        throw new IllegalArgumentException();
17930
      }
17931
 
17932
      switch (field) {
17933
      case PAYMENT_ID:
17934
        return isSetPaymentId();
17935
      case CATEGORY:
17936
        return isSetCategory();
17937
      }
17938
      throw new IllegalStateException();
17939
    }
17940
 
17941
    @Override
17942
    public boolean equals(Object that) {
17943
      if (that == null)
17944
        return false;
17945
      if (that instanceof markPaymentAsProcessed_args)
17946
        return this.equals((markPaymentAsProcessed_args)that);
17947
      return false;
17948
    }
17949
 
17950
    public boolean equals(markPaymentAsProcessed_args that) {
17951
      if (that == null)
17952
        return false;
17953
 
17954
      boolean this_present_paymentId = true;
17955
      boolean that_present_paymentId = true;
17956
      if (this_present_paymentId || that_present_paymentId) {
17957
        if (!(this_present_paymentId && that_present_paymentId))
17958
          return false;
17959
        if (this.paymentId != that.paymentId)
17960
          return false;
17961
      }
17962
 
17963
      boolean this_present_category = true && this.isSetCategory();
17964
      boolean that_present_category = true && that.isSetCategory();
17965
      if (this_present_category || that_present_category) {
17966
        if (!(this_present_category && that_present_category))
17967
          return false;
17968
        if (!this.category.equals(that.category))
17969
          return false;
17970
      }
17971
 
17972
      return true;
17973
    }
17974
 
17975
    @Override
17976
    public int hashCode() {
17977
      return 0;
17978
    }
17979
 
17980
    public int compareTo(markPaymentAsProcessed_args other) {
17981
      if (!getClass().equals(other.getClass())) {
17982
        return getClass().getName().compareTo(other.getClass().getName());
17983
      }
17984
 
17985
      int lastComparison = 0;
17986
      markPaymentAsProcessed_args typedOther = (markPaymentAsProcessed_args)other;
17987
 
17988
      lastComparison = Boolean.valueOf(isSetPaymentId()).compareTo(typedOther.isSetPaymentId());
17989
      if (lastComparison != 0) {
17990
        return lastComparison;
17991
      }
17992
      if (isSetPaymentId()) {
17993
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.paymentId, typedOther.paymentId);
17994
        if (lastComparison != 0) {
17995
          return lastComparison;
17996
        }
17997
      }
17998
      lastComparison = Boolean.valueOf(isSetCategory()).compareTo(typedOther.isSetCategory());
17999
      if (lastComparison != 0) {
18000
        return lastComparison;
18001
      }
18002
      if (isSetCategory()) {
18003
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.category, typedOther.category);
18004
        if (lastComparison != 0) {
18005
          return lastComparison;
18006
        }
18007
      }
18008
      return 0;
18009
    }
18010
 
18011
    public _Fields fieldForId(int fieldId) {
18012
      return _Fields.findByThriftId(fieldId);
18013
    }
18014
 
18015
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18016
      org.apache.thrift.protocol.TField field;
18017
      iprot.readStructBegin();
18018
      while (true)
18019
      {
18020
        field = iprot.readFieldBegin();
18021
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18022
          break;
18023
        }
18024
        switch (field.id) {
18025
          case 1: // PAYMENT_ID
18026
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18027
              this.paymentId = iprot.readI64();
18028
              setPaymentIdIsSet(true);
18029
            } else { 
18030
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18031
            }
18032
            break;
18033
          case 2: // CATEGORY
18034
            if (field.type == org.apache.thrift.protocol.TType.I32) {
18035
              this.category = ExtraPaymentProcessingType.findByValue(iprot.readI32());
18036
            } else { 
18037
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18038
            }
18039
            break;
18040
          default:
18041
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18042
        }
18043
        iprot.readFieldEnd();
18044
      }
18045
      iprot.readStructEnd();
18046
      validate();
18047
    }
18048
 
18049
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18050
      validate();
18051
 
18052
      oprot.writeStructBegin(STRUCT_DESC);
18053
      oprot.writeFieldBegin(PAYMENT_ID_FIELD_DESC);
18054
      oprot.writeI64(this.paymentId);
18055
      oprot.writeFieldEnd();
18056
      if (this.category != null) {
18057
        oprot.writeFieldBegin(CATEGORY_FIELD_DESC);
18058
        oprot.writeI32(this.category.getValue());
18059
        oprot.writeFieldEnd();
18060
      }
18061
      oprot.writeFieldStop();
18062
      oprot.writeStructEnd();
18063
    }
18064
 
18065
    @Override
18066
    public String toString() {
18067
      StringBuilder sb = new StringBuilder("markPaymentAsProcessed_args(");
18068
      boolean first = true;
18069
 
18070
      sb.append("paymentId:");
18071
      sb.append(this.paymentId);
18072
      first = false;
18073
      if (!first) sb.append(", ");
18074
      sb.append("category:");
18075
      if (this.category == null) {
18076
        sb.append("null");
18077
      } else {
18078
        sb.append(this.category);
18079
      }
18080
      first = false;
18081
      sb.append(")");
18082
      return sb.toString();
18083
    }
18084
 
18085
    public void validate() throws org.apache.thrift.TException {
18086
      // check for required fields
18087
    }
18088
 
18089
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18090
      try {
18091
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18092
      } catch (org.apache.thrift.TException te) {
18093
        throw new java.io.IOException(te);
18094
      }
18095
    }
18096
 
18097
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18098
      try {
18099
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18100
      } catch (org.apache.thrift.TException te) {
18101
        throw new java.io.IOException(te);
18102
      }
18103
    }
18104
 
18105
  }
18106
 
18107
  public static class markPaymentAsProcessed_result implements org.apache.thrift.TBase<markPaymentAsProcessed_result, markPaymentAsProcessed_result._Fields>, java.io.Serializable, Cloneable   {
18108
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markPaymentAsProcessed_result");
18109
 
18110
 
18111
 
18112
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18113
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18114
;
18115
 
18116
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18117
 
18118
      static {
18119
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18120
          byName.put(field.getFieldName(), field);
18121
        }
18122
      }
18123
 
18124
      /**
18125
       * Find the _Fields constant that matches fieldId, or null if its not found.
18126
       */
18127
      public static _Fields findByThriftId(int fieldId) {
18128
        switch(fieldId) {
18129
          default:
18130
            return null;
18131
        }
18132
      }
18133
 
18134
      /**
18135
       * Find the _Fields constant that matches fieldId, throwing an exception
18136
       * if it is not found.
18137
       */
18138
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18139
        _Fields fields = findByThriftId(fieldId);
18140
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18141
        return fields;
18142
      }
18143
 
18144
      /**
18145
       * Find the _Fields constant that matches name, or null if its not found.
18146
       */
18147
      public static _Fields findByName(String name) {
18148
        return byName.get(name);
18149
      }
18150
 
18151
      private final short _thriftId;
18152
      private final String _fieldName;
18153
 
18154
      _Fields(short thriftId, String fieldName) {
18155
        _thriftId = thriftId;
18156
        _fieldName = fieldName;
18157
      }
18158
 
18159
      public short getThriftFieldId() {
18160
        return _thriftId;
18161
      }
18162
 
18163
      public String getFieldName() {
18164
        return _fieldName;
18165
      }
18166
    }
18167
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18168
    static {
18169
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18170
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18171
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markPaymentAsProcessed_result.class, metaDataMap);
18172
    }
18173
 
18174
    public markPaymentAsProcessed_result() {
18175
    }
18176
 
18177
    /**
18178
     * Performs a deep copy on <i>other</i>.
18179
     */
18180
    public markPaymentAsProcessed_result(markPaymentAsProcessed_result other) {
18181
    }
18182
 
18183
    public markPaymentAsProcessed_result deepCopy() {
18184
      return new markPaymentAsProcessed_result(this);
18185
    }
18186
 
18187
    @Override
18188
    public void clear() {
18189
    }
18190
 
18191
    public void setFieldValue(_Fields field, Object value) {
18192
      switch (field) {
18193
      }
18194
    }
18195
 
18196
    public Object getFieldValue(_Fields field) {
18197
      switch (field) {
18198
      }
18199
      throw new IllegalStateException();
18200
    }
18201
 
18202
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18203
    public boolean isSet(_Fields field) {
18204
      if (field == null) {
18205
        throw new IllegalArgumentException();
18206
      }
18207
 
18208
      switch (field) {
18209
      }
18210
      throw new IllegalStateException();
18211
    }
18212
 
18213
    @Override
18214
    public boolean equals(Object that) {
18215
      if (that == null)
18216
        return false;
18217
      if (that instanceof markPaymentAsProcessed_result)
18218
        return this.equals((markPaymentAsProcessed_result)that);
18219
      return false;
18220
    }
18221
 
18222
    public boolean equals(markPaymentAsProcessed_result that) {
18223
      if (that == null)
18224
        return false;
18225
 
18226
      return true;
18227
    }
18228
 
18229
    @Override
18230
    public int hashCode() {
18231
      return 0;
18232
    }
18233
 
18234
    public int compareTo(markPaymentAsProcessed_result other) {
18235
      if (!getClass().equals(other.getClass())) {
18236
        return getClass().getName().compareTo(other.getClass().getName());
18237
      }
18238
 
18239
      int lastComparison = 0;
18240
      markPaymentAsProcessed_result typedOther = (markPaymentAsProcessed_result)other;
18241
 
18242
      return 0;
18243
    }
18244
 
18245
    public _Fields fieldForId(int fieldId) {
18246
      return _Fields.findByThriftId(fieldId);
18247
    }
18248
 
18249
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18250
      org.apache.thrift.protocol.TField field;
18251
      iprot.readStructBegin();
18252
      while (true)
18253
      {
18254
        field = iprot.readFieldBegin();
18255
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18256
          break;
18257
        }
18258
        switch (field.id) {
18259
          default:
18260
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18261
        }
18262
        iprot.readFieldEnd();
18263
      }
18264
      iprot.readStructEnd();
18265
      validate();
18266
    }
18267
 
18268
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18269
      oprot.writeStructBegin(STRUCT_DESC);
18270
 
18271
      oprot.writeFieldStop();
18272
      oprot.writeStructEnd();
18273
    }
18274
 
18275
    @Override
18276
    public String toString() {
18277
      StringBuilder sb = new StringBuilder("markPaymentAsProcessed_result(");
18278
      boolean first = true;
18279
 
18280
      sb.append(")");
18281
      return sb.toString();
18282
    }
18283
 
18284
    public void validate() throws org.apache.thrift.TException {
18285
      // check for required fields
18286
    }
18287
 
18288
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18289
      try {
18290
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18291
      } catch (org.apache.thrift.TException te) {
18292
        throw new java.io.IOException(te);
18293
      }
18294
    }
18295
 
18296
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18297
      try {
18298
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18299
      } catch (org.apache.thrift.TException te) {
18300
        throw new java.io.IOException(te);
18301
      }
18302
    }
18303
 
18304
  }
18305
 
123 ashish 18306
}