Subversion Repositories SmartDukaan

Rev

Rev 9506 | Rev 18577 | 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
    /**
7049 anupam.sin 98
     * Get payments for a recharge transaction id. Will raise exception.
99
     * 
100
     * 
101
     * @param txnId
102
     */
103
    public List<Payment> getPaymentForRechargeTxnId(long txnId) throws PaymentException, org.apache.thrift.TException;
104
 
105
    /**
4600 varun.gupt 106
     * Get successful payment for a transaction. Will raise exception.
107
     * 
108
     * 
109
     * @param txnId
110
     */
111
    public Payment getSuccessfulPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException;
112
 
113
    /**
695 rajveer 114
     * mark payment successful and store parameters
115
     * 
116
     * 
117
     * @param id
118
     * @param gatewayPaymentId
119
     * @param sessionId
120
     * @param gatewayTxnStatus
121
     * @param description
122
     * @param gatewayTxnId
123
     * @param authCode
124
     * @param referenceCode
125
     * @param errorCode
126
     * @param status
1119 rajveer 127
     * @param gatewayTxnDate
695 rajveer 128
     * @param attributes
129
     */
3430 rajveer 130
    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 131
 
1629 ankur.sing 132
    /**
1731 ankur.sing 133
     * Returns the minimum and maximum amounts among successful payments.
134
     * List contains two double values, first minimum and second maximum amount.
1629 ankur.sing 135
     */
3430 rajveer 136
    public List<Double> getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException;
1629 ankur.sing 137
 
2462 chandransh 138
    /**
139
     * Initialize the payment pipe for a HDFC payment. The URL the user should be redirected to is returned.
140
     * In case of any processing error, an exception is raised.
141
     * 
142
     * @param merchantPaymentId
10269 amit.gupta 143
     * @param isMobile
2462 chandransh 144
     */
10269 amit.gupta 145
    public String initializeHdfcPayment(long merchantPaymentId, boolean isMobile) throws PaymentException, org.apache.thrift.TException;
2462 chandransh 146
 
2690 chandransh 147
    /**
6050 anupam.sin 148
     * 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 149
     * 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 150
     * 
151
     * @param merchantPaymentId
152
     * @param rechargeOrderId
6228 anupam.sin 153
     * @param phone
10269 amit.gupta 154
     * @param isMobile
6050 anupam.sin 155
     */
10269 amit.gupta 156
    public String doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone, boolean isMobile) throws PaymentException, org.apache.thrift.TException;
6050 anupam.sin 157
 
158
    /**
3616 chandransh 159
     * Initialize the payment pipe for a HDFC EMI payment. The URL the user should be redirected to is returned.
160
     * In case of any processing error, an exception is raised.
161
     * 
162
     * @param merchantPaymentId
10269 amit.gupta 163
     * @param isMobile
3616 chandransh 164
     */
10269 amit.gupta 165
    public String initializeHdfcEmiPayment(long merchantPaymentId, boolean isMobile) throws PaymentException, org.apache.thrift.TException;
3616 chandransh 166
 
167
    /**
2690 chandransh 168
     * Create a refund of the given amount corresponding to the given order to be processed through the same
169
     * payment gateway which processed the payment for the corresponding transaction.
170
     * Returns the id of the newly created Refund.
171
     * 
172
     * @param orderId
173
     * @param merchantTxnId
174
     * @param amount
175
     */
3430 rajveer 176
    public long createRefund(long orderId, long merchantTxnId, double amount) throws PaymentException, org.apache.thrift.TException;
2690 chandransh 177
 
3010 chandransh 178
    /**
179
     * Capture the payment for the given merchant transaction id. It processes the last payment for the given
6503 rajveer 180
     * transaction. If the capture attempt failed, the payment is marked as failed. PaymentException with error
181
     * code 104 is	thrown in case no payments are found for the transaction id passed. PaymentException is also
182
     * thrown with error code 106 in case capture was not possible due to connection
183
     * issue.
3010 chandransh 184
     * 
185
     * @param merchantTxnId
8618 rajveer 186
     * @param isDigital
3010 chandransh 187
     */
8618 rajveer 188
    public boolean capturePayment(long merchantTxnId, boolean isDigital) throws PaymentException, org.apache.thrift.TException;
3010 chandransh 189
 
3956 chandransh 190
    /**
6503 rajveer 191
     * Refund the payment for the given merchant transaction id. It processes the last payment for the given
192
     * transaction. If refund will be failed nothing will be updated in database.
6486 rajveer 193
     * 
194
     * @param merchantTxnId
195
     * @param amount
196
     * @param isDigital
197
     */
198
    public boolean refundPayment(long merchantTxnId, double amount, boolean isDigital) throws PaymentException, org.apache.thrift.TException;
199
 
200
    /**
3956 chandransh 201
     * Adds the given amount to the captured amount of a COD payment.
202
     * Updates the captured amount for the corresponding payment and marks it as PARTIALLY CAPTURED.
203
     * If the captured amount becomes equal to total amount, then the payment status is set as SUCCESS.
204
     * Also sets the name of the entity which transferred the money, the date on which it was transferred
205
     * and the corresponding transaction id.
206
     * 
207
     * Returns false if the payment couldn't be captured.
208
     * Throws exception if no such payment could be found or if the captured amount will exceed the total amount after capturing.
209
     * 
210
     * @param merchantTxnId
211
     * @param amount
212
     * @param xferBy
213
     * @param xferTxnId
214
     * @param xferDate
215
     */
216
    public boolean partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws PaymentException, org.apache.thrift.TException;
217
 
4008 mandeep.dh 218
    /**
219
     * Returns the list of payments that require some extra processing and
220
     * which belong to a particular category. This is currently used by CRM
221
     * application.
222
     * 
223
     * @param category
224
     */
225
    public List<Long> getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException;
226
 
227
    /**
228
     * Marks a particular payment as processed for a particular cateogory.
229
     * It essentially deletes the payment if it is processed for a particular
230
     * category. This is currently used by CRM application.
231
     * 
232
     * @param paymentId
233
     * @param category
234
     */
235
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException;
236
 
8914 rajveer 237
    public PaymentStatus getPaymentStatusAtGateway(long merchantTxnId, double amount, boolean isDigital) throws PaymentException, org.apache.thrift.TException;
8907 rajveer 238
 
123 ashish 239
  }
240
 
3430 rajveer 241
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
242
 
6050 anupam.sin 243
    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 244
 
245
    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;
246
 
247
    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;
248
 
4141 chandransh 249
    public void getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentsByCapturedDate_call> resultHandler) throws org.apache.thrift.TException;
250
 
3430 rajveer 251
    public void getPaymentGateway(long id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentGateway_call> resultHandler) throws org.apache.thrift.TException;
252
 
4600 varun.gupt 253
    public void getActivePaymentGateways(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getActivePaymentGateways_call> resultHandler) throws org.apache.thrift.TException;
254
 
3430 rajveer 255
    public void getPayment(long id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPayment_call> resultHandler) throws org.apache.thrift.TException;
256
 
257
    public void getPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException;
258
 
7049 anupam.sin 259
    public void getPaymentForRechargeTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentForRechargeTxnId_call> resultHandler) throws org.apache.thrift.TException;
260
 
4600 varun.gupt 261
    public void getSuccessfulPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSuccessfulPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException;
262
 
3430 rajveer 263
    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;
264
 
265
    public void getSuccessfulPaymentsAmountRange(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSuccessfulPaymentsAmountRange_call> resultHandler) throws org.apache.thrift.TException;
266
 
10269 amit.gupta 267
    public void initializeHdfcPayment(long merchantPaymentId, boolean isMobile, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.initializeHdfcPayment_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 268
 
10269 amit.gupta 269
    public void doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone, boolean isMobile, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.doHdfcPaymentForDigitalOrder_call> resultHandler) throws org.apache.thrift.TException;
6050 anupam.sin 270
 
10269 amit.gupta 271
    public void initializeHdfcEmiPayment(long merchantPaymentId, boolean isMobile, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.initializeHdfcEmiPayment_call> resultHandler) throws org.apache.thrift.TException;
3616 chandransh 272
 
3430 rajveer 273
    public void createRefund(long orderId, long merchantTxnId, double amount, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createRefund_call> resultHandler) throws org.apache.thrift.TException;
274
 
8618 rajveer 275
    public void capturePayment(long merchantTxnId, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.capturePayment_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 276
 
6486 rajveer 277
    public void refundPayment(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.refundPayment_call> resultHandler) throws org.apache.thrift.TException;
278
 
3956 chandransh 279
    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;
280
 
4008 mandeep.dh 281
    public void getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentsRequiringExtraProcessing_call> resultHandler) throws org.apache.thrift.TException;
282
 
283
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.markPaymentAsProcessed_call> resultHandler) throws org.apache.thrift.TException;
284
 
8914 rajveer 285
    public void getPaymentStatusAtGateway(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentStatusAtGateway_call> resultHandler) throws org.apache.thrift.TException;
8907 rajveer 286
 
3430 rajveer 287
  }
288
 
3374 rajveer 289
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
3430 rajveer 290
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
291
      public Factory() {}
292
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
293
        return new Client(prot);
294
      }
295
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
296
        return new Client(iprot, oprot);
297
      }
298
    }
299
 
300
    public Client(org.apache.thrift.protocol.TProtocol prot)
123 ashish 301
    {
3430 rajveer 302
      super(prot, prot);
123 ashish 303
    }
304
 
3430 rajveer 305
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
3374 rajveer 306
      super(iprot, oprot);
123 ashish 307
    }
308
 
6050 anupam.sin 309
    public long createPayment(long userId, double amount, long gatewayId, long txnId, boolean isDigital) throws PaymentException, org.apache.thrift.TException
123 ashish 310
    {
6050 anupam.sin 311
      send_createPayment(userId, amount, gatewayId, txnId, isDigital);
123 ashish 312
      return recv_createPayment();
313
    }
314
 
6050 anupam.sin 315
    public void send_createPayment(long userId, double amount, long gatewayId, long txnId, boolean isDigital) throws org.apache.thrift.TException
123 ashish 316
    {
317
      createPayment_args args = new createPayment_args();
3430 rajveer 318
      args.setUserId(userId);
319
      args.setAmount(amount);
320
      args.setGatewayId(gatewayId);
321
      args.setTxnId(txnId);
6050 anupam.sin 322
      args.setIsDigital(isDigital);
3430 rajveer 323
      sendBase("createPayment", args);
123 ashish 324
    }
325
 
3430 rajveer 326
    public long recv_createPayment() throws PaymentException, org.apache.thrift.TException
123 ashish 327
    {
328
      createPayment_result result = new createPayment_result();
3430 rajveer 329
      receiveBase(result, "createPayment");
123 ashish 330
      if (result.isSetSuccess()) {
331
        return result.success;
332
      }
333
      if (result.pe != null) {
334
        throw result.pe;
335
      }
3430 rajveer 336
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createPayment failed: unknown result");
123 ashish 337
    }
338
 
3430 rajveer 339
    public List<Payment> getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException
123 ashish 340
    {
695 rajveer 341
      send_getPaymentsForUser(userId, fromTime, toTime, status, gatewayId);
123 ashish 342
      return recv_getPaymentsForUser();
343
    }
344
 
3430 rajveer 345
    public void send_getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws org.apache.thrift.TException
123 ashish 346
    {
347
      getPaymentsForUser_args args = new getPaymentsForUser_args();
3430 rajveer 348
      args.setUserId(userId);
349
      args.setFromTime(fromTime);
350
      args.setToTime(toTime);
351
      args.setStatus(status);
352
      args.setGatewayId(gatewayId);
353
      sendBase("getPaymentsForUser", args);
123 ashish 354
    }
355
 
3430 rajveer 356
    public List<Payment> recv_getPaymentsForUser() throws PaymentException, org.apache.thrift.TException
123 ashish 357
    {
358
      getPaymentsForUser_result result = new getPaymentsForUser_result();
3430 rajveer 359
      receiveBase(result, "getPaymentsForUser");
123 ashish 360
      if (result.isSetSuccess()) {
361
        return result.success;
362
      }
363
      if (result.pe != null) {
364
        throw result.pe;
365
      }
3430 rajveer 366
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsForUser failed: unknown result");
123 ashish 367
    }
368
 
3430 rajveer 369
    public List<Payment> getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException
123 ashish 370
    {
695 rajveer 371
      send_getPayments(fromTime, toTime, status, gatewayId);
123 ashish 372
      return recv_getPayments();
373
    }
374
 
3430 rajveer 375
    public void send_getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws org.apache.thrift.TException
123 ashish 376
    {
377
      getPayments_args args = new getPayments_args();
3430 rajveer 378
      args.setFromTime(fromTime);
379
      args.setToTime(toTime);
380
      args.setStatus(status);
381
      args.setGatewayId(gatewayId);
382
      sendBase("getPayments", args);
123 ashish 383
    }
384
 
3430 rajveer 385
    public List<Payment> recv_getPayments() throws PaymentException, org.apache.thrift.TException
123 ashish 386
    {
387
      getPayments_result result = new getPayments_result();
3430 rajveer 388
      receiveBase(result, "getPayments");
123 ashish 389
      if (result.isSetSuccess()) {
390
        return result.success;
391
      }
392
      if (result.pe != null) {
393
        throw result.pe;
394
      }
3430 rajveer 395
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPayments failed: unknown result");
123 ashish 396
    }
397
 
4141 chandransh 398
    public List<Payment> getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws PaymentException, org.apache.thrift.TException
399
    {
400
      send_getPaymentsByCapturedDate(fromTime, toTime, gatewayId);
401
      return recv_getPaymentsByCapturedDate();
402
    }
403
 
404
    public void send_getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws org.apache.thrift.TException
405
    {
406
      getPaymentsByCapturedDate_args args = new getPaymentsByCapturedDate_args();
407
      args.setFromTime(fromTime);
408
      args.setToTime(toTime);
409
      args.setGatewayId(gatewayId);
410
      sendBase("getPaymentsByCapturedDate", args);
411
    }
412
 
413
    public List<Payment> recv_getPaymentsByCapturedDate() throws PaymentException, org.apache.thrift.TException
414
    {
415
      getPaymentsByCapturedDate_result result = new getPaymentsByCapturedDate_result();
416
      receiveBase(result, "getPaymentsByCapturedDate");
417
      if (result.isSetSuccess()) {
418
        return result.success;
419
      }
420
      if (result.pe != null) {
421
        throw result.pe;
422
      }
423
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsByCapturedDate failed: unknown result");
424
    }
425
 
3430 rajveer 426
    public PaymentGateway getPaymentGateway(long id) throws PaymentException, org.apache.thrift.TException
420 ashish 427
    {
428
      send_getPaymentGateway(id);
429
      return recv_getPaymentGateway();
430
    }
431
 
3430 rajveer 432
    public void send_getPaymentGateway(long id) throws org.apache.thrift.TException
420 ashish 433
    {
434
      getPaymentGateway_args args = new getPaymentGateway_args();
3430 rajveer 435
      args.setId(id);
436
      sendBase("getPaymentGateway", args);
420 ashish 437
    }
438
 
3430 rajveer 439
    public PaymentGateway recv_getPaymentGateway() throws PaymentException, org.apache.thrift.TException
420 ashish 440
    {
441
      getPaymentGateway_result result = new getPaymentGateway_result();
3430 rajveer 442
      receiveBase(result, "getPaymentGateway");
420 ashish 443
      if (result.isSetSuccess()) {
444
        return result.success;
445
      }
446
      if (result.pe != null) {
447
        throw result.pe;
448
      }
3430 rajveer 449
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentGateway failed: unknown result");
420 ashish 450
    }
451
 
4600 varun.gupt 452
    public List<PaymentGateway> getActivePaymentGateways() throws PaymentException, org.apache.thrift.TException
453
    {
454
      send_getActivePaymentGateways();
455
      return recv_getActivePaymentGateways();
456
    }
457
 
458
    public void send_getActivePaymentGateways() throws org.apache.thrift.TException
459
    {
460
      getActivePaymentGateways_args args = new getActivePaymentGateways_args();
461
      sendBase("getActivePaymentGateways", args);
462
    }
463
 
464
    public List<PaymentGateway> recv_getActivePaymentGateways() throws PaymentException, org.apache.thrift.TException
465
    {
466
      getActivePaymentGateways_result result = new getActivePaymentGateways_result();
467
      receiveBase(result, "getActivePaymentGateways");
468
      if (result.isSetSuccess()) {
469
        return result.success;
470
      }
471
      if (result.pe != null) {
472
        throw result.pe;
473
      }
474
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getActivePaymentGateways failed: unknown result");
475
    }
476
 
3430 rajveer 477
    public Payment getPayment(long id) throws PaymentException, org.apache.thrift.TException
420 ashish 478
    {
695 rajveer 479
      send_getPayment(id);
480
      return recv_getPayment();
420 ashish 481
    }
482
 
3430 rajveer 483
    public void send_getPayment(long id) throws org.apache.thrift.TException
420 ashish 484
    {
695 rajveer 485
      getPayment_args args = new getPayment_args();
3430 rajveer 486
      args.setId(id);
487
      sendBase("getPayment", args);
420 ashish 488
    }
489
 
3430 rajveer 490
    public Payment recv_getPayment() throws PaymentException, org.apache.thrift.TException
420 ashish 491
    {
695 rajveer 492
      getPayment_result result = new getPayment_result();
3430 rajveer 493
      receiveBase(result, "getPayment");
695 rajveer 494
      if (result.isSetSuccess()) {
495
        return result.success;
496
      }
420 ashish 497
      if (result.pe != null) {
498
        throw result.pe;
499
      }
3430 rajveer 500
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPayment failed: unknown result");
420 ashish 501
    }
502
 
3430 rajveer 503
    public List<Payment> getPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException
420 ashish 504
    {
695 rajveer 505
      send_getPaymentForTxnId(txnId);
506
      return recv_getPaymentForTxnId();
420 ashish 507
    }
508
 
3430 rajveer 509
    public void send_getPaymentForTxnId(long txnId) throws org.apache.thrift.TException
420 ashish 510
    {
695 rajveer 511
      getPaymentForTxnId_args args = new getPaymentForTxnId_args();
3430 rajveer 512
      args.setTxnId(txnId);
513
      sendBase("getPaymentForTxnId", args);
420 ashish 514
    }
515
 
3430 rajveer 516
    public List<Payment> recv_getPaymentForTxnId() throws PaymentException, org.apache.thrift.TException
420 ashish 517
    {
695 rajveer 518
      getPaymentForTxnId_result result = new getPaymentForTxnId_result();
3430 rajveer 519
      receiveBase(result, "getPaymentForTxnId");
420 ashish 520
      if (result.isSetSuccess()) {
521
        return result.success;
522
      }
523
      if (result.pe != null) {
524
        throw result.pe;
525
      }
3430 rajveer 526
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentForTxnId failed: unknown result");
420 ashish 527
    }
528
 
7049 anupam.sin 529
    public List<Payment> getPaymentForRechargeTxnId(long txnId) throws PaymentException, org.apache.thrift.TException
530
    {
531
      send_getPaymentForRechargeTxnId(txnId);
532
      return recv_getPaymentForRechargeTxnId();
533
    }
534
 
535
    public void send_getPaymentForRechargeTxnId(long txnId) throws org.apache.thrift.TException
536
    {
537
      getPaymentForRechargeTxnId_args args = new getPaymentForRechargeTxnId_args();
538
      args.setTxnId(txnId);
539
      sendBase("getPaymentForRechargeTxnId", args);
540
    }
541
 
542
    public List<Payment> recv_getPaymentForRechargeTxnId() throws PaymentException, org.apache.thrift.TException
543
    {
544
      getPaymentForRechargeTxnId_result result = new getPaymentForRechargeTxnId_result();
545
      receiveBase(result, "getPaymentForRechargeTxnId");
546
      if (result.isSetSuccess()) {
547
        return result.success;
548
      }
549
      if (result.pe != null) {
550
        throw result.pe;
551
      }
552
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentForRechargeTxnId failed: unknown result");
553
    }
554
 
4600 varun.gupt 555
    public Payment getSuccessfulPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException
556
    {
557
      send_getSuccessfulPaymentForTxnId(txnId);
558
      return recv_getSuccessfulPaymentForTxnId();
559
    }
560
 
561
    public void send_getSuccessfulPaymentForTxnId(long txnId) throws org.apache.thrift.TException
562
    {
563
      getSuccessfulPaymentForTxnId_args args = new getSuccessfulPaymentForTxnId_args();
564
      args.setTxnId(txnId);
565
      sendBase("getSuccessfulPaymentForTxnId", args);
566
    }
567
 
568
    public Payment recv_getSuccessfulPaymentForTxnId() throws PaymentException, org.apache.thrift.TException
569
    {
570
      getSuccessfulPaymentForTxnId_result result = new getSuccessfulPaymentForTxnId_result();
571
      receiveBase(result, "getSuccessfulPaymentForTxnId");
572
      if (result.isSetSuccess()) {
573
        return result.success;
574
      }
575
      if (result.pe != null) {
576
        throw result.pe;
577
      }
578
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getSuccessfulPaymentForTxnId failed: unknown result");
579
    }
580
 
3430 rajveer 581
    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 582
    {
1119 rajveer 583
      send_updatePaymentDetails(id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes);
695 rajveer 584
      return recv_updatePaymentDetails();
420 ashish 585
    }
586
 
3430 rajveer 587
    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 588
    {
695 rajveer 589
      updatePaymentDetails_args args = new updatePaymentDetails_args();
3430 rajveer 590
      args.setId(id);
591
      args.setGatewayPaymentId(gatewayPaymentId);
592
      args.setSessionId(sessionId);
593
      args.setGatewayTxnStatus(gatewayTxnStatus);
594
      args.setDescription(description);
595
      args.setGatewayTxnId(gatewayTxnId);
596
      args.setAuthCode(authCode);
597
      args.setReferenceCode(referenceCode);
598
      args.setErrorCode(errorCode);
599
      args.setStatus(status);
600
      args.setGatewayTxnDate(gatewayTxnDate);
601
      args.setAttributes(attributes);
602
      sendBase("updatePaymentDetails", args);
420 ashish 603
    }
604
 
3430 rajveer 605
    public boolean recv_updatePaymentDetails() throws PaymentException, org.apache.thrift.TException
420 ashish 606
    {
695 rajveer 607
      updatePaymentDetails_result result = new updatePaymentDetails_result();
3430 rajveer 608
      receiveBase(result, "updatePaymentDetails");
695 rajveer 609
      if (result.isSetSuccess()) {
610
        return result.success;
611
      }
420 ashish 612
      if (result.pe != null) {
613
        throw result.pe;
614
      }
3430 rajveer 615
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "updatePaymentDetails failed: unknown result");
420 ashish 616
    }
617
 
3430 rajveer 618
    public List<Double> getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 619
    {
1731 ankur.sing 620
      send_getSuccessfulPaymentsAmountRange();
621
      return recv_getSuccessfulPaymentsAmountRange();
1629 ankur.sing 622
    }
623
 
3430 rajveer 624
    public void send_getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 625
    {
1731 ankur.sing 626
      getSuccessfulPaymentsAmountRange_args args = new getSuccessfulPaymentsAmountRange_args();
3430 rajveer 627
      sendBase("getSuccessfulPaymentsAmountRange", args);
1629 ankur.sing 628
    }
629
 
3430 rajveer 630
    public List<Double> recv_getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 631
    {
1731 ankur.sing 632
      getSuccessfulPaymentsAmountRange_result result = new getSuccessfulPaymentsAmountRange_result();
3430 rajveer 633
      receiveBase(result, "getSuccessfulPaymentsAmountRange");
1629 ankur.sing 634
      if (result.isSetSuccess()) {
635
        return result.success;
636
      }
3430 rajveer 637
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getSuccessfulPaymentsAmountRange failed: unknown result");
1629 ankur.sing 638
    }
639
 
10269 amit.gupta 640
    public String initializeHdfcPayment(long merchantPaymentId, boolean isMobile) throws PaymentException, org.apache.thrift.TException
2462 chandransh 641
    {
10269 amit.gupta 642
      send_initializeHdfcPayment(merchantPaymentId, isMobile);
2462 chandransh 643
      return recv_initializeHdfcPayment();
644
    }
645
 
10269 amit.gupta 646
    public void send_initializeHdfcPayment(long merchantPaymentId, boolean isMobile) throws org.apache.thrift.TException
2462 chandransh 647
    {
648
      initializeHdfcPayment_args args = new initializeHdfcPayment_args();
3430 rajveer 649
      args.setMerchantPaymentId(merchantPaymentId);
10269 amit.gupta 650
      args.setIsMobile(isMobile);
3430 rajveer 651
      sendBase("initializeHdfcPayment", args);
2462 chandransh 652
    }
653
 
3430 rajveer 654
    public String recv_initializeHdfcPayment() throws PaymentException, org.apache.thrift.TException
2462 chandransh 655
    {
656
      initializeHdfcPayment_result result = new initializeHdfcPayment_result();
3430 rajveer 657
      receiveBase(result, "initializeHdfcPayment");
2462 chandransh 658
      if (result.isSetSuccess()) {
659
        return result.success;
660
      }
661
      if (result.pe != null) {
662
        throw result.pe;
663
      }
3430 rajveer 664
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "initializeHdfcPayment failed: unknown result");
2462 chandransh 665
    }
666
 
10269 amit.gupta 667
    public String doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone, boolean isMobile) throws PaymentException, org.apache.thrift.TException
6050 anupam.sin 668
    {
10269 amit.gupta 669
      send_doHdfcPaymentForDigitalOrder(merchantPaymentId, rechargeOrderId, phone, isMobile);
6050 anupam.sin 670
      return recv_doHdfcPaymentForDigitalOrder();
671
    }
672
 
10269 amit.gupta 673
    public void send_doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone, boolean isMobile) throws org.apache.thrift.TException
6050 anupam.sin 674
    {
675
      doHdfcPaymentForDigitalOrder_args args = new doHdfcPaymentForDigitalOrder_args();
676
      args.setMerchantPaymentId(merchantPaymentId);
677
      args.setRechargeOrderId(rechargeOrderId);
6228 anupam.sin 678
      args.setPhone(phone);
10269 amit.gupta 679
      args.setIsMobile(isMobile);
6050 anupam.sin 680
      sendBase("doHdfcPaymentForDigitalOrder", args);
681
    }
682
 
683
    public String recv_doHdfcPaymentForDigitalOrder() throws PaymentException, org.apache.thrift.TException
684
    {
685
      doHdfcPaymentForDigitalOrder_result result = new doHdfcPaymentForDigitalOrder_result();
686
      receiveBase(result, "doHdfcPaymentForDigitalOrder");
687
      if (result.isSetSuccess()) {
688
        return result.success;
689
      }
690
      if (result.pe != null) {
691
        throw result.pe;
692
      }
693
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "doHdfcPaymentForDigitalOrder failed: unknown result");
694
    }
695
 
10269 amit.gupta 696
    public String initializeHdfcEmiPayment(long merchantPaymentId, boolean isMobile) throws PaymentException, org.apache.thrift.TException
3616 chandransh 697
    {
10269 amit.gupta 698
      send_initializeHdfcEmiPayment(merchantPaymentId, isMobile);
3616 chandransh 699
      return recv_initializeHdfcEmiPayment();
700
    }
701
 
10269 amit.gupta 702
    public void send_initializeHdfcEmiPayment(long merchantPaymentId, boolean isMobile) throws org.apache.thrift.TException
3616 chandransh 703
    {
704
      initializeHdfcEmiPayment_args args = new initializeHdfcEmiPayment_args();
705
      args.setMerchantPaymentId(merchantPaymentId);
10269 amit.gupta 706
      args.setIsMobile(isMobile);
3616 chandransh 707
      sendBase("initializeHdfcEmiPayment", args);
708
    }
709
 
710
    public String recv_initializeHdfcEmiPayment() throws PaymentException, org.apache.thrift.TException
711
    {
712
      initializeHdfcEmiPayment_result result = new initializeHdfcEmiPayment_result();
713
      receiveBase(result, "initializeHdfcEmiPayment");
714
      if (result.isSetSuccess()) {
715
        return result.success;
716
      }
717
      if (result.pe != null) {
718
        throw result.pe;
719
      }
720
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "initializeHdfcEmiPayment failed: unknown result");
721
    }
722
 
3430 rajveer 723
    public long createRefund(long orderId, long merchantTxnId, double amount) throws PaymentException, org.apache.thrift.TException
2690 chandransh 724
    {
725
      send_createRefund(orderId, merchantTxnId, amount);
726
      return recv_createRefund();
727
    }
728
 
3430 rajveer 729
    public void send_createRefund(long orderId, long merchantTxnId, double amount) throws org.apache.thrift.TException
2690 chandransh 730
    {
731
      createRefund_args args = new createRefund_args();
3430 rajveer 732
      args.setOrderId(orderId);
733
      args.setMerchantTxnId(merchantTxnId);
734
      args.setAmount(amount);
735
      sendBase("createRefund", args);
2690 chandransh 736
    }
737
 
3430 rajveer 738
    public long recv_createRefund() throws PaymentException, org.apache.thrift.TException
2690 chandransh 739
    {
740
      createRefund_result result = new createRefund_result();
3430 rajveer 741
      receiveBase(result, "createRefund");
2690 chandransh 742
      if (result.isSetSuccess()) {
743
        return result.success;
744
      }
745
      if (result.pe != null) {
746
        throw result.pe;
747
      }
3430 rajveer 748
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createRefund failed: unknown result");
2690 chandransh 749
    }
750
 
8618 rajveer 751
    public boolean capturePayment(long merchantTxnId, boolean isDigital) throws PaymentException, org.apache.thrift.TException
3010 chandransh 752
    {
8618 rajveer 753
      send_capturePayment(merchantTxnId, isDigital);
3010 chandransh 754
      return recv_capturePayment();
755
    }
756
 
8618 rajveer 757
    public void send_capturePayment(long merchantTxnId, boolean isDigital) throws org.apache.thrift.TException
3010 chandransh 758
    {
759
      capturePayment_args args = new capturePayment_args();
3430 rajveer 760
      args.setMerchantTxnId(merchantTxnId);
8618 rajveer 761
      args.setIsDigital(isDigital);
3430 rajveer 762
      sendBase("capturePayment", args);
3010 chandransh 763
    }
764
 
3430 rajveer 765
    public boolean recv_capturePayment() throws PaymentException, org.apache.thrift.TException
3010 chandransh 766
    {
767
      capturePayment_result result = new capturePayment_result();
3430 rajveer 768
      receiveBase(result, "capturePayment");
3010 chandransh 769
      if (result.isSetSuccess()) {
770
        return result.success;
771
      }
772
      if (result.pe != null) {
773
        throw result.pe;
774
      }
3430 rajveer 775
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "capturePayment failed: unknown result");
3010 chandransh 776
    }
777
 
6486 rajveer 778
    public boolean refundPayment(long merchantTxnId, double amount, boolean isDigital) throws PaymentException, org.apache.thrift.TException
779
    {
780
      send_refundPayment(merchantTxnId, amount, isDigital);
781
      return recv_refundPayment();
782
    }
783
 
784
    public void send_refundPayment(long merchantTxnId, double amount, boolean isDigital) throws org.apache.thrift.TException
785
    {
786
      refundPayment_args args = new refundPayment_args();
787
      args.setMerchantTxnId(merchantTxnId);
788
      args.setAmount(amount);
789
      args.setIsDigital(isDigital);
790
      sendBase("refundPayment", args);
791
    }
792
 
793
    public boolean recv_refundPayment() throws PaymentException, org.apache.thrift.TException
794
    {
795
      refundPayment_result result = new refundPayment_result();
796
      receiveBase(result, "refundPayment");
797
      if (result.isSetSuccess()) {
798
        return result.success;
799
      }
800
      if (result.pe != null) {
801
        throw result.pe;
802
      }
803
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "refundPayment failed: unknown result");
804
    }
805
 
3956 chandransh 806
    public boolean partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws PaymentException, org.apache.thrift.TException
807
    {
808
      send_partiallyCapturePayment(merchantTxnId, amount, xferBy, xferTxnId, xferDate);
809
      return recv_partiallyCapturePayment();
810
    }
811
 
812
    public void send_partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws org.apache.thrift.TException
813
    {
814
      partiallyCapturePayment_args args = new partiallyCapturePayment_args();
815
      args.setMerchantTxnId(merchantTxnId);
816
      args.setAmount(amount);
817
      args.setXferBy(xferBy);
818
      args.setXferTxnId(xferTxnId);
819
      args.setXferDate(xferDate);
820
      sendBase("partiallyCapturePayment", args);
821
    }
822
 
823
    public boolean recv_partiallyCapturePayment() throws PaymentException, org.apache.thrift.TException
824
    {
825
      partiallyCapturePayment_result result = new partiallyCapturePayment_result();
826
      receiveBase(result, "partiallyCapturePayment");
827
      if (result.isSetSuccess()) {
828
        return result.success;
829
      }
830
      if (result.pe != null) {
831
        throw result.pe;
832
      }
833
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "partiallyCapturePayment failed: unknown result");
834
    }
835
 
4008 mandeep.dh 836
    public List<Long> getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException
837
    {
838
      send_getPaymentsRequiringExtraProcessing(category);
839
      return recv_getPaymentsRequiringExtraProcessing();
840
    }
841
 
842
    public void send_getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException
843
    {
844
      getPaymentsRequiringExtraProcessing_args args = new getPaymentsRequiringExtraProcessing_args();
845
      args.setCategory(category);
846
      sendBase("getPaymentsRequiringExtraProcessing", args);
847
    }
848
 
849
    public List<Long> recv_getPaymentsRequiringExtraProcessing() throws org.apache.thrift.TException
850
    {
851
      getPaymentsRequiringExtraProcessing_result result = new getPaymentsRequiringExtraProcessing_result();
852
      receiveBase(result, "getPaymentsRequiringExtraProcessing");
853
      if (result.isSetSuccess()) {
854
        return result.success;
855
      }
856
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsRequiringExtraProcessing failed: unknown result");
857
    }
858
 
859
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException
860
    {
861
      send_markPaymentAsProcessed(paymentId, category);
862
      recv_markPaymentAsProcessed();
863
    }
864
 
865
    public void send_markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException
866
    {
867
      markPaymentAsProcessed_args args = new markPaymentAsProcessed_args();
868
      args.setPaymentId(paymentId);
869
      args.setCategory(category);
870
      sendBase("markPaymentAsProcessed", args);
871
    }
872
 
873
    public void recv_markPaymentAsProcessed() throws org.apache.thrift.TException
874
    {
875
      markPaymentAsProcessed_result result = new markPaymentAsProcessed_result();
876
      receiveBase(result, "markPaymentAsProcessed");
877
      return;
878
    }
879
 
8914 rajveer 880
    public PaymentStatus getPaymentStatusAtGateway(long merchantTxnId, double amount, boolean isDigital) throws PaymentException, org.apache.thrift.TException
8907 rajveer 881
    {
8914 rajveer 882
      send_getPaymentStatusAtGateway(merchantTxnId, amount, isDigital);
883
      return recv_getPaymentStatusAtGateway();
8907 rajveer 884
    }
885
 
8914 rajveer 886
    public void send_getPaymentStatusAtGateway(long merchantTxnId, double amount, boolean isDigital) throws org.apache.thrift.TException
8907 rajveer 887
    {
8914 rajveer 888
      getPaymentStatusAtGateway_args args = new getPaymentStatusAtGateway_args();
8907 rajveer 889
      args.setMerchantTxnId(merchantTxnId);
890
      args.setAmount(amount);
891
      args.setIsDigital(isDigital);
8914 rajveer 892
      sendBase("getPaymentStatusAtGateway", args);
8907 rajveer 893
    }
894
 
8914 rajveer 895
    public PaymentStatus recv_getPaymentStatusAtGateway() throws PaymentException, org.apache.thrift.TException
8907 rajveer 896
    {
8914 rajveer 897
      getPaymentStatusAtGateway_result result = new getPaymentStatusAtGateway_result();
898
      receiveBase(result, "getPaymentStatusAtGateway");
8907 rajveer 899
      if (result.isSetSuccess()) {
900
        return result.success;
901
      }
902
      if (result.pe != null) {
903
        throw result.pe;
904
      }
8914 rajveer 905
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentStatusAtGateway failed: unknown result");
8907 rajveer 906
    }
907
 
123 ashish 908
  }
3430 rajveer 909
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
910
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
911
      private org.apache.thrift.async.TAsyncClientManager clientManager;
912
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
913
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
914
        this.clientManager = clientManager;
915
        this.protocolFactory = protocolFactory;
916
      }
917
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
918
        return new AsyncClient(protocolFactory, clientManager, transport);
919
      }
123 ashish 920
    }
921
 
3430 rajveer 922
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
923
      super(protocolFactory, clientManager, transport);
924
    }
123 ashish 925
 
6050 anupam.sin 926
    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 927
      checkReady();
6050 anupam.sin 928
      createPayment_call method_call = new createPayment_call(userId, amount, gatewayId, txnId, isDigital, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 929
      this.___currentMethod = method_call;
930
      ___manager.call(method_call);
931
    }
932
 
933
    public static class createPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
934
      private long userId;
935
      private double amount;
936
      private long gatewayId;
937
      private long txnId;
6050 anupam.sin 938
      private boolean isDigital;
939
      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 940
        super(client, protocolFactory, transport, resultHandler, false);
941
        this.userId = userId;
942
        this.amount = amount;
943
        this.gatewayId = gatewayId;
944
        this.txnId = txnId;
6050 anupam.sin 945
        this.isDigital = isDigital;
123 ashish 946
      }
3430 rajveer 947
 
948
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
949
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
950
        createPayment_args args = new createPayment_args();
951
        args.setUserId(userId);
952
        args.setAmount(amount);
953
        args.setGatewayId(gatewayId);
954
        args.setTxnId(txnId);
6050 anupam.sin 955
        args.setIsDigital(isDigital);
3430 rajveer 956
        args.write(prot);
957
        prot.writeMessageEnd();
958
      }
959
 
960
      public long getResult() throws PaymentException, org.apache.thrift.TException {
961
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
962
          throw new IllegalStateException("Method call not finished!");
963
        }
964
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
965
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
966
        return (new Client(prot)).recv_createPayment();
967
      }
123 ashish 968
    }
969
 
3430 rajveer 970
    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 {
971
      checkReady();
972
      getPaymentsForUser_call method_call = new getPaymentsForUser_call(userId, fromTime, toTime, status, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
973
      this.___currentMethod = method_call;
974
      ___manager.call(method_call);
975
    }
976
 
977
    public static class getPaymentsForUser_call extends org.apache.thrift.async.TAsyncMethodCall {
978
      private long userId;
979
      private long fromTime;
980
      private long toTime;
981
      private PaymentStatus status;
982
      private long gatewayId;
983
      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 {
984
        super(client, protocolFactory, transport, resultHandler, false);
985
        this.userId = userId;
986
        this.fromTime = fromTime;
987
        this.toTime = toTime;
988
        this.status = status;
989
        this.gatewayId = gatewayId;
990
      }
991
 
992
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
993
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsForUser", org.apache.thrift.protocol.TMessageType.CALL, 0));
994
        getPaymentsForUser_args args = new getPaymentsForUser_args();
995
        args.setUserId(userId);
996
        args.setFromTime(fromTime);
997
        args.setToTime(toTime);
998
        args.setStatus(status);
999
        args.setGatewayId(gatewayId);
1000
        args.write(prot);
1001
        prot.writeMessageEnd();
1002
      }
1003
 
1004
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
1005
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1006
          throw new IllegalStateException("Method call not finished!");
1007
        }
1008
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1009
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1010
        return (new Client(prot)).recv_getPaymentsForUser();
1011
      }
1012
    }
1013
 
1014
    public void getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPayments_call> resultHandler) throws org.apache.thrift.TException {
1015
      checkReady();
1016
      getPayments_call method_call = new getPayments_call(fromTime, toTime, status, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
1017
      this.___currentMethod = method_call;
1018
      ___manager.call(method_call);
1019
    }
1020
 
1021
    public static class getPayments_call extends org.apache.thrift.async.TAsyncMethodCall {
1022
      private long fromTime;
1023
      private long toTime;
1024
      private PaymentStatus status;
1025
      private long gatewayId;
1026
      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 {
1027
        super(client, protocolFactory, transport, resultHandler, false);
1028
        this.fromTime = fromTime;
1029
        this.toTime = toTime;
1030
        this.status = status;
1031
        this.gatewayId = gatewayId;
1032
      }
1033
 
1034
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1035
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPayments", org.apache.thrift.protocol.TMessageType.CALL, 0));
1036
        getPayments_args args = new getPayments_args();
1037
        args.setFromTime(fromTime);
1038
        args.setToTime(toTime);
1039
        args.setStatus(status);
1040
        args.setGatewayId(gatewayId);
1041
        args.write(prot);
1042
        prot.writeMessageEnd();
1043
      }
1044
 
1045
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
1046
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1047
          throw new IllegalStateException("Method call not finished!");
1048
        }
1049
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1050
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1051
        return (new Client(prot)).recv_getPayments();
1052
      }
1053
    }
1054
 
4141 chandransh 1055
    public void getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPaymentsByCapturedDate_call> resultHandler) throws org.apache.thrift.TException {
1056
      checkReady();
1057
      getPaymentsByCapturedDate_call method_call = new getPaymentsByCapturedDate_call(fromTime, toTime, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
1058
      this.___currentMethod = method_call;
1059
      ___manager.call(method_call);
1060
    }
1061
 
1062
    public static class getPaymentsByCapturedDate_call extends org.apache.thrift.async.TAsyncMethodCall {
1063
      private long fromTime;
1064
      private long toTime;
1065
      private long gatewayId;
1066
      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 {
1067
        super(client, protocolFactory, transport, resultHandler, false);
1068
        this.fromTime = fromTime;
1069
        this.toTime = toTime;
1070
        this.gatewayId = gatewayId;
1071
      }
1072
 
1073
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1074
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsByCapturedDate", org.apache.thrift.protocol.TMessageType.CALL, 0));
1075
        getPaymentsByCapturedDate_args args = new getPaymentsByCapturedDate_args();
1076
        args.setFromTime(fromTime);
1077
        args.setToTime(toTime);
1078
        args.setGatewayId(gatewayId);
1079
        args.write(prot);
1080
        prot.writeMessageEnd();
1081
      }
1082
 
1083
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
1084
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1085
          throw new IllegalStateException("Method call not finished!");
1086
        }
1087
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1088
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1089
        return (new Client(prot)).recv_getPaymentsByCapturedDate();
1090
      }
1091
    }
1092
 
3430 rajveer 1093
    public void getPaymentGateway(long id, org.apache.thrift.async.AsyncMethodCallback<getPaymentGateway_call> resultHandler) throws org.apache.thrift.TException {
1094
      checkReady();
1095
      getPaymentGateway_call method_call = new getPaymentGateway_call(id, resultHandler, this, ___protocolFactory, ___transport);
1096
      this.___currentMethod = method_call;
1097
      ___manager.call(method_call);
1098
    }
1099
 
1100
    public static class getPaymentGateway_call extends org.apache.thrift.async.TAsyncMethodCall {
1101
      private long id;
1102
      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 {
1103
        super(client, protocolFactory, transport, resultHandler, false);
1104
        this.id = id;
1105
      }
1106
 
1107
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1108
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentGateway", org.apache.thrift.protocol.TMessageType.CALL, 0));
1109
        getPaymentGateway_args args = new getPaymentGateway_args();
1110
        args.setId(id);
1111
        args.write(prot);
1112
        prot.writeMessageEnd();
1113
      }
1114
 
1115
      public PaymentGateway getResult() throws PaymentException, org.apache.thrift.TException {
1116
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1117
          throw new IllegalStateException("Method call not finished!");
1118
        }
1119
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1120
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1121
        return (new Client(prot)).recv_getPaymentGateway();
1122
      }
1123
    }
1124
 
4600 varun.gupt 1125
    public void getActivePaymentGateways(org.apache.thrift.async.AsyncMethodCallback<getActivePaymentGateways_call> resultHandler) throws org.apache.thrift.TException {
1126
      checkReady();
1127
      getActivePaymentGateways_call method_call = new getActivePaymentGateways_call(resultHandler, this, ___protocolFactory, ___transport);
1128
      this.___currentMethod = method_call;
1129
      ___manager.call(method_call);
1130
    }
1131
 
1132
    public static class getActivePaymentGateways_call extends org.apache.thrift.async.TAsyncMethodCall {
1133
      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 {
1134
        super(client, protocolFactory, transport, resultHandler, false);
1135
      }
1136
 
1137
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1138
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getActivePaymentGateways", org.apache.thrift.protocol.TMessageType.CALL, 0));
1139
        getActivePaymentGateways_args args = new getActivePaymentGateways_args();
1140
        args.write(prot);
1141
        prot.writeMessageEnd();
1142
      }
1143
 
1144
      public List<PaymentGateway> getResult() throws PaymentException, org.apache.thrift.TException {
1145
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1146
          throw new IllegalStateException("Method call not finished!");
1147
        }
1148
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1149
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1150
        return (new Client(prot)).recv_getActivePaymentGateways();
1151
      }
1152
    }
1153
 
3430 rajveer 1154
    public void getPayment(long id, org.apache.thrift.async.AsyncMethodCallback<getPayment_call> resultHandler) throws org.apache.thrift.TException {
1155
      checkReady();
1156
      getPayment_call method_call = new getPayment_call(id, resultHandler, this, ___protocolFactory, ___transport);
1157
      this.___currentMethod = method_call;
1158
      ___manager.call(method_call);
1159
    }
1160
 
1161
    public static class getPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1162
      private long id;
1163
      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 {
1164
        super(client, protocolFactory, transport, resultHandler, false);
1165
        this.id = id;
1166
      }
1167
 
1168
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1169
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1170
        getPayment_args args = new getPayment_args();
1171
        args.setId(id);
1172
        args.write(prot);
1173
        prot.writeMessageEnd();
1174
      }
1175
 
1176
      public Payment getResult() throws PaymentException, org.apache.thrift.TException {
1177
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1178
          throw new IllegalStateException("Method call not finished!");
1179
        }
1180
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1181
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1182
        return (new Client(prot)).recv_getPayment();
1183
      }
1184
    }
1185
 
1186
    public void getPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<getPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException {
1187
      checkReady();
1188
      getPaymentForTxnId_call method_call = new getPaymentForTxnId_call(txnId, resultHandler, this, ___protocolFactory, ___transport);
1189
      this.___currentMethod = method_call;
1190
      ___manager.call(method_call);
1191
    }
1192
 
1193
    public static class getPaymentForTxnId_call extends org.apache.thrift.async.TAsyncMethodCall {
1194
      private long txnId;
1195
      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 {
1196
        super(client, protocolFactory, transport, resultHandler, false);
1197
        this.txnId = txnId;
1198
      }
1199
 
1200
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1201
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentForTxnId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1202
        getPaymentForTxnId_args args = new getPaymentForTxnId_args();
1203
        args.setTxnId(txnId);
1204
        args.write(prot);
1205
        prot.writeMessageEnd();
1206
      }
1207
 
1208
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
1209
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1210
          throw new IllegalStateException("Method call not finished!");
1211
        }
1212
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1213
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1214
        return (new Client(prot)).recv_getPaymentForTxnId();
1215
      }
1216
    }
1217
 
7049 anupam.sin 1218
    public void getPaymentForRechargeTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<getPaymentForRechargeTxnId_call> resultHandler) throws org.apache.thrift.TException {
1219
      checkReady();
1220
      getPaymentForRechargeTxnId_call method_call = new getPaymentForRechargeTxnId_call(txnId, resultHandler, this, ___protocolFactory, ___transport);
1221
      this.___currentMethod = method_call;
1222
      ___manager.call(method_call);
1223
    }
1224
 
1225
    public static class getPaymentForRechargeTxnId_call extends org.apache.thrift.async.TAsyncMethodCall {
1226
      private long txnId;
1227
      public getPaymentForRechargeTxnId_call(long txnId, org.apache.thrift.async.AsyncMethodCallback<getPaymentForRechargeTxnId_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 {
1228
        super(client, protocolFactory, transport, resultHandler, false);
1229
        this.txnId = txnId;
1230
      }
1231
 
1232
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1233
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentForRechargeTxnId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1234
        getPaymentForRechargeTxnId_args args = new getPaymentForRechargeTxnId_args();
1235
        args.setTxnId(txnId);
1236
        args.write(prot);
1237
        prot.writeMessageEnd();
1238
      }
1239
 
1240
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
1241
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1242
          throw new IllegalStateException("Method call not finished!");
1243
        }
1244
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1245
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1246
        return (new Client(prot)).recv_getPaymentForRechargeTxnId();
1247
      }
1248
    }
1249
 
4600 varun.gupt 1250
    public void getSuccessfulPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<getSuccessfulPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException {
1251
      checkReady();
1252
      getSuccessfulPaymentForTxnId_call method_call = new getSuccessfulPaymentForTxnId_call(txnId, resultHandler, this, ___protocolFactory, ___transport);
1253
      this.___currentMethod = method_call;
1254
      ___manager.call(method_call);
1255
    }
1256
 
1257
    public static class getSuccessfulPaymentForTxnId_call extends org.apache.thrift.async.TAsyncMethodCall {
1258
      private long txnId;
1259
      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 {
1260
        super(client, protocolFactory, transport, resultHandler, false);
1261
        this.txnId = txnId;
1262
      }
1263
 
1264
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1265
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getSuccessfulPaymentForTxnId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1266
        getSuccessfulPaymentForTxnId_args args = new getSuccessfulPaymentForTxnId_args();
1267
        args.setTxnId(txnId);
1268
        args.write(prot);
1269
        prot.writeMessageEnd();
1270
      }
1271
 
1272
      public Payment getResult() throws PaymentException, org.apache.thrift.TException {
1273
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1274
          throw new IllegalStateException("Method call not finished!");
1275
        }
1276
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1277
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1278
        return (new Client(prot)).recv_getSuccessfulPaymentForTxnId();
1279
      }
1280
    }
1281
 
3430 rajveer 1282
    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 {
1283
      checkReady();
1284
      updatePaymentDetails_call method_call = new updatePaymentDetails_call(id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes, resultHandler, this, ___protocolFactory, ___transport);
1285
      this.___currentMethod = method_call;
1286
      ___manager.call(method_call);
1287
    }
1288
 
1289
    public static class updatePaymentDetails_call extends org.apache.thrift.async.TAsyncMethodCall {
1290
      private long id;
1291
      private String gatewayPaymentId;
1292
      private String sessionId;
1293
      private String gatewayTxnStatus;
1294
      private String description;
1295
      private String gatewayTxnId;
1296
      private String authCode;
1297
      private String referenceCode;
1298
      private String errorCode;
1299
      private PaymentStatus status;
1300
      private String gatewayTxnDate;
1301
      private List<Attribute> attributes;
1302
      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 {
1303
        super(client, protocolFactory, transport, resultHandler, false);
1304
        this.id = id;
1305
        this.gatewayPaymentId = gatewayPaymentId;
1306
        this.sessionId = sessionId;
1307
        this.gatewayTxnStatus = gatewayTxnStatus;
1308
        this.description = description;
1309
        this.gatewayTxnId = gatewayTxnId;
1310
        this.authCode = authCode;
1311
        this.referenceCode = referenceCode;
1312
        this.errorCode = errorCode;
1313
        this.status = status;
1314
        this.gatewayTxnDate = gatewayTxnDate;
1315
        this.attributes = attributes;
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("updatePaymentDetails", org.apache.thrift.protocol.TMessageType.CALL, 0));
1320
        updatePaymentDetails_args args = new updatePaymentDetails_args();
1321
        args.setId(id);
1322
        args.setGatewayPaymentId(gatewayPaymentId);
1323
        args.setSessionId(sessionId);
1324
        args.setGatewayTxnStatus(gatewayTxnStatus);
1325
        args.setDescription(description);
1326
        args.setGatewayTxnId(gatewayTxnId);
1327
        args.setAuthCode(authCode);
1328
        args.setReferenceCode(referenceCode);
1329
        args.setErrorCode(errorCode);
1330
        args.setStatus(status);
1331
        args.setGatewayTxnDate(gatewayTxnDate);
1332
        args.setAttributes(attributes);
1333
        args.write(prot);
1334
        prot.writeMessageEnd();
1335
      }
1336
 
1337
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1338
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1339
          throw new IllegalStateException("Method call not finished!");
1340
        }
1341
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1342
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1343
        return (new Client(prot)).recv_updatePaymentDetails();
1344
      }
1345
    }
1346
 
1347
    public void getSuccessfulPaymentsAmountRange(org.apache.thrift.async.AsyncMethodCallback<getSuccessfulPaymentsAmountRange_call> resultHandler) throws org.apache.thrift.TException {
1348
      checkReady();
1349
      getSuccessfulPaymentsAmountRange_call method_call = new getSuccessfulPaymentsAmountRange_call(resultHandler, this, ___protocolFactory, ___transport);
1350
      this.___currentMethod = method_call;
1351
      ___manager.call(method_call);
1352
    }
1353
 
1354
    public static class getSuccessfulPaymentsAmountRange_call extends org.apache.thrift.async.TAsyncMethodCall {
1355
      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 {
1356
        super(client, protocolFactory, transport, resultHandler, false);
1357
      }
1358
 
1359
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1360
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getSuccessfulPaymentsAmountRange", org.apache.thrift.protocol.TMessageType.CALL, 0));
1361
        getSuccessfulPaymentsAmountRange_args args = new getSuccessfulPaymentsAmountRange_args();
1362
        args.write(prot);
1363
        prot.writeMessageEnd();
1364
      }
1365
 
1366
      public List<Double> getResult() throws org.apache.thrift.TException {
1367
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1368
          throw new IllegalStateException("Method call not finished!");
1369
        }
1370
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1371
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1372
        return (new Client(prot)).recv_getSuccessfulPaymentsAmountRange();
1373
      }
1374
    }
1375
 
10269 amit.gupta 1376
    public void initializeHdfcPayment(long merchantPaymentId, boolean isMobile, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcPayment_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 1377
      checkReady();
10269 amit.gupta 1378
      initializeHdfcPayment_call method_call = new initializeHdfcPayment_call(merchantPaymentId, isMobile, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 1379
      this.___currentMethod = method_call;
1380
      ___manager.call(method_call);
1381
    }
1382
 
1383
    public static class initializeHdfcPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1384
      private long merchantPaymentId;
10269 amit.gupta 1385
      private boolean isMobile;
1386
      public initializeHdfcPayment_call(long merchantPaymentId, boolean isMobile, 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 {
3430 rajveer 1387
        super(client, protocolFactory, transport, resultHandler, false);
1388
        this.merchantPaymentId = merchantPaymentId;
10269 amit.gupta 1389
        this.isMobile = isMobile;
3430 rajveer 1390
      }
1391
 
1392
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1393
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("initializeHdfcPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1394
        initializeHdfcPayment_args args = new initializeHdfcPayment_args();
1395
        args.setMerchantPaymentId(merchantPaymentId);
10269 amit.gupta 1396
        args.setIsMobile(isMobile);
3430 rajveer 1397
        args.write(prot);
1398
        prot.writeMessageEnd();
1399
      }
1400
 
1401
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1402
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1403
          throw new IllegalStateException("Method call not finished!");
1404
        }
1405
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1406
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1407
        return (new Client(prot)).recv_initializeHdfcPayment();
1408
      }
1409
    }
1410
 
10269 amit.gupta 1411
    public void doHdfcPaymentForDigitalOrder(long merchantPaymentId, long rechargeOrderId, String phone, boolean isMobile, org.apache.thrift.async.AsyncMethodCallback<doHdfcPaymentForDigitalOrder_call> resultHandler) throws org.apache.thrift.TException {
6050 anupam.sin 1412
      checkReady();
10269 amit.gupta 1413
      doHdfcPaymentForDigitalOrder_call method_call = new doHdfcPaymentForDigitalOrder_call(merchantPaymentId, rechargeOrderId, phone, isMobile, resultHandler, this, ___protocolFactory, ___transport);
6050 anupam.sin 1414
      this.___currentMethod = method_call;
1415
      ___manager.call(method_call);
1416
    }
1417
 
1418
    public static class doHdfcPaymentForDigitalOrder_call extends org.apache.thrift.async.TAsyncMethodCall {
1419
      private long merchantPaymentId;
1420
      private long rechargeOrderId;
6228 anupam.sin 1421
      private String phone;
10269 amit.gupta 1422
      private boolean isMobile;
1423
      public doHdfcPaymentForDigitalOrder_call(long merchantPaymentId, long rechargeOrderId, String phone, boolean isMobile, 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 1424
        super(client, protocolFactory, transport, resultHandler, false);
1425
        this.merchantPaymentId = merchantPaymentId;
1426
        this.rechargeOrderId = rechargeOrderId;
6228 anupam.sin 1427
        this.phone = phone;
10269 amit.gupta 1428
        this.isMobile = isMobile;
6050 anupam.sin 1429
      }
1430
 
1431
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1432
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("doHdfcPaymentForDigitalOrder", org.apache.thrift.protocol.TMessageType.CALL, 0));
1433
        doHdfcPaymentForDigitalOrder_args args = new doHdfcPaymentForDigitalOrder_args();
1434
        args.setMerchantPaymentId(merchantPaymentId);
1435
        args.setRechargeOrderId(rechargeOrderId);
6228 anupam.sin 1436
        args.setPhone(phone);
10269 amit.gupta 1437
        args.setIsMobile(isMobile);
6050 anupam.sin 1438
        args.write(prot);
1439
        prot.writeMessageEnd();
1440
      }
1441
 
1442
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1443
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1444
          throw new IllegalStateException("Method call not finished!");
1445
        }
1446
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1447
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1448
        return (new Client(prot)).recv_doHdfcPaymentForDigitalOrder();
1449
      }
1450
    }
1451
 
10269 amit.gupta 1452
    public void initializeHdfcEmiPayment(long merchantPaymentId, boolean isMobile, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcEmiPayment_call> resultHandler) throws org.apache.thrift.TException {
3616 chandransh 1453
      checkReady();
10269 amit.gupta 1454
      initializeHdfcEmiPayment_call method_call = new initializeHdfcEmiPayment_call(merchantPaymentId, isMobile, resultHandler, this, ___protocolFactory, ___transport);
3616 chandransh 1455
      this.___currentMethod = method_call;
1456
      ___manager.call(method_call);
1457
    }
1458
 
1459
    public static class initializeHdfcEmiPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1460
      private long merchantPaymentId;
10269 amit.gupta 1461
      private boolean isMobile;
1462
      public initializeHdfcEmiPayment_call(long merchantPaymentId, boolean isMobile, 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 {
3616 chandransh 1463
        super(client, protocolFactory, transport, resultHandler, false);
1464
        this.merchantPaymentId = merchantPaymentId;
10269 amit.gupta 1465
        this.isMobile = isMobile;
3616 chandransh 1466
      }
1467
 
1468
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1469
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("initializeHdfcEmiPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1470
        initializeHdfcEmiPayment_args args = new initializeHdfcEmiPayment_args();
1471
        args.setMerchantPaymentId(merchantPaymentId);
10269 amit.gupta 1472
        args.setIsMobile(isMobile);
3616 chandransh 1473
        args.write(prot);
1474
        prot.writeMessageEnd();
1475
      }
1476
 
1477
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1478
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1479
          throw new IllegalStateException("Method call not finished!");
1480
        }
1481
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1482
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1483
        return (new Client(prot)).recv_initializeHdfcEmiPayment();
1484
      }
1485
    }
1486
 
3430 rajveer 1487
    public void createRefund(long orderId, long merchantTxnId, double amount, org.apache.thrift.async.AsyncMethodCallback<createRefund_call> resultHandler) throws org.apache.thrift.TException {
1488
      checkReady();
1489
      createRefund_call method_call = new createRefund_call(orderId, merchantTxnId, amount, resultHandler, this, ___protocolFactory, ___transport);
1490
      this.___currentMethod = method_call;
1491
      ___manager.call(method_call);
1492
    }
1493
 
1494
    public static class createRefund_call extends org.apache.thrift.async.TAsyncMethodCall {
1495
      private long orderId;
1496
      private long merchantTxnId;
1497
      private double amount;
1498
      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 {
1499
        super(client, protocolFactory, transport, resultHandler, false);
1500
        this.orderId = orderId;
1501
        this.merchantTxnId = merchantTxnId;
1502
        this.amount = amount;
1503
      }
1504
 
1505
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1506
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createRefund", org.apache.thrift.protocol.TMessageType.CALL, 0));
1507
        createRefund_args args = new createRefund_args();
1508
        args.setOrderId(orderId);
1509
        args.setMerchantTxnId(merchantTxnId);
1510
        args.setAmount(amount);
1511
        args.write(prot);
1512
        prot.writeMessageEnd();
1513
      }
1514
 
1515
      public long getResult() throws PaymentException, org.apache.thrift.TException {
1516
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1517
          throw new IllegalStateException("Method call not finished!");
1518
        }
1519
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1520
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1521
        return (new Client(prot)).recv_createRefund();
1522
      }
1523
    }
1524
 
8618 rajveer 1525
    public void capturePayment(long merchantTxnId, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<capturePayment_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 1526
      checkReady();
8618 rajveer 1527
      capturePayment_call method_call = new capturePayment_call(merchantTxnId, isDigital, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 1528
      this.___currentMethod = method_call;
1529
      ___manager.call(method_call);
1530
    }
1531
 
1532
    public static class capturePayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1533
      private long merchantTxnId;
8618 rajveer 1534
      private boolean isDigital;
1535
      public capturePayment_call(long merchantTxnId, boolean isDigital, 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 {
3430 rajveer 1536
        super(client, protocolFactory, transport, resultHandler, false);
1537
        this.merchantTxnId = merchantTxnId;
8618 rajveer 1538
        this.isDigital = isDigital;
3430 rajveer 1539
      }
1540
 
1541
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1542
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("capturePayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1543
        capturePayment_args args = new capturePayment_args();
1544
        args.setMerchantTxnId(merchantTxnId);
8618 rajveer 1545
        args.setIsDigital(isDigital);
3430 rajveer 1546
        args.write(prot);
1547
        prot.writeMessageEnd();
1548
      }
1549
 
1550
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1551
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1552
          throw new IllegalStateException("Method call not finished!");
1553
        }
1554
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1555
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1556
        return (new Client(prot)).recv_capturePayment();
1557
      }
1558
    }
1559
 
6486 rajveer 1560
    public void refundPayment(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<refundPayment_call> resultHandler) throws org.apache.thrift.TException {
1561
      checkReady();
1562
      refundPayment_call method_call = new refundPayment_call(merchantTxnId, amount, isDigital, resultHandler, this, ___protocolFactory, ___transport);
1563
      this.___currentMethod = method_call;
1564
      ___manager.call(method_call);
1565
    }
1566
 
1567
    public static class refundPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1568
      private long merchantTxnId;
1569
      private double amount;
1570
      private boolean isDigital;
1571
      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 {
1572
        super(client, protocolFactory, transport, resultHandler, false);
1573
        this.merchantTxnId = merchantTxnId;
1574
        this.amount = amount;
1575
        this.isDigital = isDigital;
1576
      }
1577
 
1578
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1579
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("refundPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1580
        refundPayment_args args = new refundPayment_args();
1581
        args.setMerchantTxnId(merchantTxnId);
1582
        args.setAmount(amount);
1583
        args.setIsDigital(isDigital);
1584
        args.write(prot);
1585
        prot.writeMessageEnd();
1586
      }
1587
 
1588
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1589
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1590
          throw new IllegalStateException("Method call not finished!");
1591
        }
1592
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1593
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1594
        return (new Client(prot)).recv_refundPayment();
1595
      }
1596
    }
1597
 
3956 chandransh 1598
    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 {
1599
      checkReady();
1600
      partiallyCapturePayment_call method_call = new partiallyCapturePayment_call(merchantTxnId, amount, xferBy, xferTxnId, xferDate, resultHandler, this, ___protocolFactory, ___transport);
1601
      this.___currentMethod = method_call;
1602
      ___manager.call(method_call);
1603
    }
1604
 
1605
    public static class partiallyCapturePayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1606
      private long merchantTxnId;
1607
      private double amount;
1608
      private String xferBy;
1609
      private String xferTxnId;
1610
      private long xferDate;
1611
      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 {
1612
        super(client, protocolFactory, transport, resultHandler, false);
1613
        this.merchantTxnId = merchantTxnId;
1614
        this.amount = amount;
1615
        this.xferBy = xferBy;
1616
        this.xferTxnId = xferTxnId;
1617
        this.xferDate = xferDate;
1618
      }
1619
 
1620
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1621
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("partiallyCapturePayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1622
        partiallyCapturePayment_args args = new partiallyCapturePayment_args();
1623
        args.setMerchantTxnId(merchantTxnId);
1624
        args.setAmount(amount);
1625
        args.setXferBy(xferBy);
1626
        args.setXferTxnId(xferTxnId);
1627
        args.setXferDate(xferDate);
1628
        args.write(prot);
1629
        prot.writeMessageEnd();
1630
      }
1631
 
1632
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1633
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1634
          throw new IllegalStateException("Method call not finished!");
1635
        }
1636
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1637
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1638
        return (new Client(prot)).recv_partiallyCapturePayment();
1639
      }
1640
    }
1641
 
4008 mandeep.dh 1642
    public void getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<getPaymentsRequiringExtraProcessing_call> resultHandler) throws org.apache.thrift.TException {
1643
      checkReady();
1644
      getPaymentsRequiringExtraProcessing_call method_call = new getPaymentsRequiringExtraProcessing_call(category, resultHandler, this, ___protocolFactory, ___transport);
1645
      this.___currentMethod = method_call;
1646
      ___manager.call(method_call);
1647
    }
1648
 
1649
    public static class getPaymentsRequiringExtraProcessing_call extends org.apache.thrift.async.TAsyncMethodCall {
1650
      private ExtraPaymentProcessingType category;
1651
      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 {
1652
        super(client, protocolFactory, transport, resultHandler, false);
1653
        this.category = category;
1654
      }
1655
 
1656
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1657
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsRequiringExtraProcessing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1658
        getPaymentsRequiringExtraProcessing_args args = new getPaymentsRequiringExtraProcessing_args();
1659
        args.setCategory(category);
1660
        args.write(prot);
1661
        prot.writeMessageEnd();
1662
      }
1663
 
1664
      public List<Long> getResult() throws org.apache.thrift.TException {
1665
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1666
          throw new IllegalStateException("Method call not finished!");
1667
        }
1668
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1669
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1670
        return (new Client(prot)).recv_getPaymentsRequiringExtraProcessing();
1671
      }
1672
    }
1673
 
1674
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<markPaymentAsProcessed_call> resultHandler) throws org.apache.thrift.TException {
1675
      checkReady();
1676
      markPaymentAsProcessed_call method_call = new markPaymentAsProcessed_call(paymentId, category, resultHandler, this, ___protocolFactory, ___transport);
1677
      this.___currentMethod = method_call;
1678
      ___manager.call(method_call);
1679
    }
1680
 
1681
    public static class markPaymentAsProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
1682
      private long paymentId;
1683
      private ExtraPaymentProcessingType category;
1684
      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 {
1685
        super(client, protocolFactory, transport, resultHandler, false);
1686
        this.paymentId = paymentId;
1687
        this.category = category;
1688
      }
1689
 
1690
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1691
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("markPaymentAsProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
1692
        markPaymentAsProcessed_args args = new markPaymentAsProcessed_args();
1693
        args.setPaymentId(paymentId);
1694
        args.setCategory(category);
1695
        args.write(prot);
1696
        prot.writeMessageEnd();
1697
      }
1698
 
1699
      public void getResult() throws org.apache.thrift.TException {
1700
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1701
          throw new IllegalStateException("Method call not finished!");
1702
        }
1703
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1704
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1705
        (new Client(prot)).recv_markPaymentAsProcessed();
1706
      }
1707
    }
1708
 
8914 rajveer 1709
    public void getPaymentStatusAtGateway(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<getPaymentStatusAtGateway_call> resultHandler) throws org.apache.thrift.TException {
8907 rajveer 1710
      checkReady();
8914 rajveer 1711
      getPaymentStatusAtGateway_call method_call = new getPaymentStatusAtGateway_call(merchantTxnId, amount, isDigital, resultHandler, this, ___protocolFactory, ___transport);
8907 rajveer 1712
      this.___currentMethod = method_call;
1713
      ___manager.call(method_call);
1714
    }
1715
 
8914 rajveer 1716
    public static class getPaymentStatusAtGateway_call extends org.apache.thrift.async.TAsyncMethodCall {
8907 rajveer 1717
      private long merchantTxnId;
1718
      private double amount;
1719
      private boolean isDigital;
8914 rajveer 1720
      public getPaymentStatusAtGateway_call(long merchantTxnId, double amount, boolean isDigital, org.apache.thrift.async.AsyncMethodCallback<getPaymentStatusAtGateway_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 {
8907 rajveer 1721
        super(client, protocolFactory, transport, resultHandler, false);
1722
        this.merchantTxnId = merchantTxnId;
1723
        this.amount = amount;
1724
        this.isDigital = isDigital;
1725
      }
1726
 
1727
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
8914 rajveer 1728
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentStatusAtGateway", org.apache.thrift.protocol.TMessageType.CALL, 0));
1729
        getPaymentStatusAtGateway_args args = new getPaymentStatusAtGateway_args();
8907 rajveer 1730
        args.setMerchantTxnId(merchantTxnId);
1731
        args.setAmount(amount);
1732
        args.setIsDigital(isDigital);
1733
        args.write(prot);
1734
        prot.writeMessageEnd();
1735
      }
1736
 
8914 rajveer 1737
      public PaymentStatus getResult() throws PaymentException, org.apache.thrift.TException {
8907 rajveer 1738
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1739
          throw new IllegalStateException("Method call not finished!");
1740
        }
1741
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1742
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
8914 rajveer 1743
        return (new Client(prot)).recv_getPaymentStatusAtGateway();
8907 rajveer 1744
      }
1745
    }
1746
 
3430 rajveer 1747
  }
1748
 
1749
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
1750
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
1751
    public Processor(I iface) {
1752
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
1753
    }
1754
 
1755
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
1756
      super(iface, getProcessMap(processMap));
1757
    }
1758
 
1759
    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) {
1760
      processMap.put("createPayment", new createPayment());
1761
      processMap.put("getPaymentsForUser", new getPaymentsForUser());
1762
      processMap.put("getPayments", new getPayments());
4141 chandransh 1763
      processMap.put("getPaymentsByCapturedDate", new getPaymentsByCapturedDate());
3430 rajveer 1764
      processMap.put("getPaymentGateway", new getPaymentGateway());
4600 varun.gupt 1765
      processMap.put("getActivePaymentGateways", new getActivePaymentGateways());
3430 rajveer 1766
      processMap.put("getPayment", new getPayment());
1767
      processMap.put("getPaymentForTxnId", new getPaymentForTxnId());
7049 anupam.sin 1768
      processMap.put("getPaymentForRechargeTxnId", new getPaymentForRechargeTxnId());
4600 varun.gupt 1769
      processMap.put("getSuccessfulPaymentForTxnId", new getSuccessfulPaymentForTxnId());
3430 rajveer 1770
      processMap.put("updatePaymentDetails", new updatePaymentDetails());
1771
      processMap.put("getSuccessfulPaymentsAmountRange", new getSuccessfulPaymentsAmountRange());
1772
      processMap.put("initializeHdfcPayment", new initializeHdfcPayment());
6050 anupam.sin 1773
      processMap.put("doHdfcPaymentForDigitalOrder", new doHdfcPaymentForDigitalOrder());
3616 chandransh 1774
      processMap.put("initializeHdfcEmiPayment", new initializeHdfcEmiPayment());
3430 rajveer 1775
      processMap.put("createRefund", new createRefund());
1776
      processMap.put("capturePayment", new capturePayment());
6486 rajveer 1777
      processMap.put("refundPayment", new refundPayment());
3956 chandransh 1778
      processMap.put("partiallyCapturePayment", new partiallyCapturePayment());
4008 mandeep.dh 1779
      processMap.put("getPaymentsRequiringExtraProcessing", new getPaymentsRequiringExtraProcessing());
1780
      processMap.put("markPaymentAsProcessed", new markPaymentAsProcessed());
8914 rajveer 1781
      processMap.put("getPaymentStatusAtGateway", new getPaymentStatusAtGateway());
3430 rajveer 1782
      return processMap;
1783
    }
1784
 
1785
    private static class createPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createPayment_args> {
1786
      public createPayment() {
1787
        super("createPayment");
1788
      }
1789
 
1790
      protected createPayment_args getEmptyArgsInstance() {
1791
        return new createPayment_args();
1792
      }
1793
 
1794
      protected createPayment_result getResult(I iface, createPayment_args args) throws org.apache.thrift.TException {
123 ashish 1795
        createPayment_result result = new createPayment_result();
1796
        try {
6050 anupam.sin 1797
          result.success = iface.createPayment(args.userId, args.amount, args.gatewayId, args.txnId, args.isDigital);
420 ashish 1798
          result.setSuccessIsSet(true);
123 ashish 1799
        } catch (PaymentException pe) {
1800
          result.pe = pe;
1801
        }
3430 rajveer 1802
        return result;
123 ashish 1803
      }
1804
    }
1805
 
3430 rajveer 1806
    private static class getPaymentsForUser<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsForUser_args> {
1807
      public getPaymentsForUser() {
1808
        super("getPaymentsForUser");
1809
      }
1810
 
1811
      protected getPaymentsForUser_args getEmptyArgsInstance() {
1812
        return new getPaymentsForUser_args();
1813
      }
1814
 
1815
      protected getPaymentsForUser_result getResult(I iface, getPaymentsForUser_args args) throws org.apache.thrift.TException {
123 ashish 1816
        getPaymentsForUser_result result = new getPaymentsForUser_result();
1817
        try {
3430 rajveer 1818
          result.success = iface.getPaymentsForUser(args.userId, args.fromTime, args.toTime, args.status, args.gatewayId);
123 ashish 1819
        } catch (PaymentException pe) {
1820
          result.pe = pe;
1821
        }
3430 rajveer 1822
        return result;
123 ashish 1823
      }
1824
    }
1825
 
3430 rajveer 1826
    private static class getPayments<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPayments_args> {
1827
      public getPayments() {
1828
        super("getPayments");
1829
      }
1830
 
1831
      protected getPayments_args getEmptyArgsInstance() {
1832
        return new getPayments_args();
1833
      }
1834
 
1835
      protected getPayments_result getResult(I iface, getPayments_args args) throws org.apache.thrift.TException {
123 ashish 1836
        getPayments_result result = new getPayments_result();
1837
        try {
3430 rajveer 1838
          result.success = iface.getPayments(args.fromTime, args.toTime, args.status, args.gatewayId);
123 ashish 1839
        } catch (PaymentException pe) {
1840
          result.pe = pe;
1841
        }
3430 rajveer 1842
        return result;
123 ashish 1843
      }
1844
    }
1845
 
4141 chandransh 1846
    private static class getPaymentsByCapturedDate<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsByCapturedDate_args> {
1847
      public getPaymentsByCapturedDate() {
1848
        super("getPaymentsByCapturedDate");
1849
      }
1850
 
1851
      protected getPaymentsByCapturedDate_args getEmptyArgsInstance() {
1852
        return new getPaymentsByCapturedDate_args();
1853
      }
1854
 
1855
      protected getPaymentsByCapturedDate_result getResult(I iface, getPaymentsByCapturedDate_args args) throws org.apache.thrift.TException {
1856
        getPaymentsByCapturedDate_result result = new getPaymentsByCapturedDate_result();
1857
        try {
1858
          result.success = iface.getPaymentsByCapturedDate(args.fromTime, args.toTime, args.gatewayId);
1859
        } catch (PaymentException pe) {
1860
          result.pe = pe;
1861
        }
1862
        return result;
1863
      }
1864
    }
1865
 
3430 rajveer 1866
    private static class getPaymentGateway<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentGateway_args> {
1867
      public getPaymentGateway() {
1868
        super("getPaymentGateway");
1869
      }
1870
 
1871
      protected getPaymentGateway_args getEmptyArgsInstance() {
1872
        return new getPaymentGateway_args();
1873
      }
1874
 
1875
      protected getPaymentGateway_result getResult(I iface, getPaymentGateway_args args) throws org.apache.thrift.TException {
420 ashish 1876
        getPaymentGateway_result result = new getPaymentGateway_result();
1877
        try {
3430 rajveer 1878
          result.success = iface.getPaymentGateway(args.id);
420 ashish 1879
        } catch (PaymentException pe) {
1880
          result.pe = pe;
1881
        }
3430 rajveer 1882
        return result;
420 ashish 1883
      }
1884
    }
1885
 
4600 varun.gupt 1886
    private static class getActivePaymentGateways<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getActivePaymentGateways_args> {
1887
      public getActivePaymentGateways() {
1888
        super("getActivePaymentGateways");
1889
      }
1890
 
1891
      protected getActivePaymentGateways_args getEmptyArgsInstance() {
1892
        return new getActivePaymentGateways_args();
1893
      }
1894
 
1895
      protected getActivePaymentGateways_result getResult(I iface, getActivePaymentGateways_args args) throws org.apache.thrift.TException {
1896
        getActivePaymentGateways_result result = new getActivePaymentGateways_result();
1897
        try {
1898
          result.success = iface.getActivePaymentGateways();
1899
        } catch (PaymentException pe) {
1900
          result.pe = pe;
1901
        }
1902
        return result;
1903
      }
1904
    }
1905
 
3430 rajveer 1906
    private static class getPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPayment_args> {
1907
      public getPayment() {
1908
        super("getPayment");
1909
      }
1910
 
1911
      protected getPayment_args getEmptyArgsInstance() {
1912
        return new getPayment_args();
1913
      }
1914
 
1915
      protected getPayment_result getResult(I iface, getPayment_args args) throws org.apache.thrift.TException {
695 rajveer 1916
        getPayment_result result = new getPayment_result();
420 ashish 1917
        try {
3430 rajveer 1918
          result.success = iface.getPayment(args.id);
420 ashish 1919
        } catch (PaymentException pe) {
1920
          result.pe = pe;
1921
        }
3430 rajveer 1922
        return result;
420 ashish 1923
      }
1924
    }
1925
 
3430 rajveer 1926
    private static class getPaymentForTxnId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentForTxnId_args> {
1927
      public getPaymentForTxnId() {
1928
        super("getPaymentForTxnId");
1929
      }
1930
 
1931
      protected getPaymentForTxnId_args getEmptyArgsInstance() {
1932
        return new getPaymentForTxnId_args();
1933
      }
1934
 
1935
      protected getPaymentForTxnId_result getResult(I iface, getPaymentForTxnId_args args) throws org.apache.thrift.TException {
695 rajveer 1936
        getPaymentForTxnId_result result = new getPaymentForTxnId_result();
420 ashish 1937
        try {
3430 rajveer 1938
          result.success = iface.getPaymentForTxnId(args.txnId);
420 ashish 1939
        } catch (PaymentException pe) {
1940
          result.pe = pe;
1941
        }
3430 rajveer 1942
        return result;
420 ashish 1943
      }
1944
    }
1945
 
7049 anupam.sin 1946
    private static class getPaymentForRechargeTxnId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentForRechargeTxnId_args> {
1947
      public getPaymentForRechargeTxnId() {
1948
        super("getPaymentForRechargeTxnId");
1949
      }
1950
 
1951
      protected getPaymentForRechargeTxnId_args getEmptyArgsInstance() {
1952
        return new getPaymentForRechargeTxnId_args();
1953
      }
1954
 
1955
      protected getPaymentForRechargeTxnId_result getResult(I iface, getPaymentForRechargeTxnId_args args) throws org.apache.thrift.TException {
1956
        getPaymentForRechargeTxnId_result result = new getPaymentForRechargeTxnId_result();
1957
        try {
1958
          result.success = iface.getPaymentForRechargeTxnId(args.txnId);
1959
        } catch (PaymentException pe) {
1960
          result.pe = pe;
1961
        }
1962
        return result;
1963
      }
1964
    }
1965
 
4600 varun.gupt 1966
    private static class getSuccessfulPaymentForTxnId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getSuccessfulPaymentForTxnId_args> {
1967
      public getSuccessfulPaymentForTxnId() {
1968
        super("getSuccessfulPaymentForTxnId");
1969
      }
1970
 
1971
      protected getSuccessfulPaymentForTxnId_args getEmptyArgsInstance() {
1972
        return new getSuccessfulPaymentForTxnId_args();
1973
      }
1974
 
1975
      protected getSuccessfulPaymentForTxnId_result getResult(I iface, getSuccessfulPaymentForTxnId_args args) throws org.apache.thrift.TException {
1976
        getSuccessfulPaymentForTxnId_result result = new getSuccessfulPaymentForTxnId_result();
1977
        try {
1978
          result.success = iface.getSuccessfulPaymentForTxnId(args.txnId);
1979
        } catch (PaymentException pe) {
1980
          result.pe = pe;
1981
        }
1982
        return result;
1983
      }
1984
    }
1985
 
3430 rajveer 1986
    private static class updatePaymentDetails<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updatePaymentDetails_args> {
1987
      public updatePaymentDetails() {
1988
        super("updatePaymentDetails");
1989
      }
1990
 
1991
      protected updatePaymentDetails_args getEmptyArgsInstance() {
1992
        return new updatePaymentDetails_args();
1993
      }
1994
 
1995
      protected updatePaymentDetails_result getResult(I iface, updatePaymentDetails_args args) throws org.apache.thrift.TException {
695 rajveer 1996
        updatePaymentDetails_result result = new updatePaymentDetails_result();
420 ashish 1997
        try {
3430 rajveer 1998
          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 1999
          result.setSuccessIsSet(true);
420 ashish 2000
        } catch (PaymentException pe) {
2001
          result.pe = pe;
2002
        }
3430 rajveer 2003
        return result;
420 ashish 2004
      }
2005
    }
2006
 
3430 rajveer 2007
    private static class getSuccessfulPaymentsAmountRange<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getSuccessfulPaymentsAmountRange_args> {
2008
      public getSuccessfulPaymentsAmountRange() {
2009
        super("getSuccessfulPaymentsAmountRange");
2010
      }
2011
 
2012
      protected getSuccessfulPaymentsAmountRange_args getEmptyArgsInstance() {
2013
        return new getSuccessfulPaymentsAmountRange_args();
2014
      }
2015
 
2016
      protected getSuccessfulPaymentsAmountRange_result getResult(I iface, getSuccessfulPaymentsAmountRange_args args) throws org.apache.thrift.TException {
1731 ankur.sing 2017
        getSuccessfulPaymentsAmountRange_result result = new getSuccessfulPaymentsAmountRange_result();
3430 rajveer 2018
        result.success = iface.getSuccessfulPaymentsAmountRange();
2019
        return result;
1629 ankur.sing 2020
      }
2021
    }
2022
 
3430 rajveer 2023
    private static class initializeHdfcPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, initializeHdfcPayment_args> {
2024
      public initializeHdfcPayment() {
2025
        super("initializeHdfcPayment");
2026
      }
2027
 
2028
      protected initializeHdfcPayment_args getEmptyArgsInstance() {
2029
        return new initializeHdfcPayment_args();
2030
      }
2031
 
2032
      protected initializeHdfcPayment_result getResult(I iface, initializeHdfcPayment_args args) throws org.apache.thrift.TException {
2462 chandransh 2033
        initializeHdfcPayment_result result = new initializeHdfcPayment_result();
2034
        try {
10269 amit.gupta 2035
          result.success = iface.initializeHdfcPayment(args.merchantPaymentId, args.isMobile);
2462 chandransh 2036
        } catch (PaymentException pe) {
2037
          result.pe = pe;
2038
        }
3430 rajveer 2039
        return result;
2462 chandransh 2040
      }
2041
    }
2042
 
6050 anupam.sin 2043
    private static class doHdfcPaymentForDigitalOrder<I extends Iface> extends org.apache.thrift.ProcessFunction<I, doHdfcPaymentForDigitalOrder_args> {
2044
      public doHdfcPaymentForDigitalOrder() {
2045
        super("doHdfcPaymentForDigitalOrder");
2046
      }
2047
 
2048
      protected doHdfcPaymentForDigitalOrder_args getEmptyArgsInstance() {
2049
        return new doHdfcPaymentForDigitalOrder_args();
2050
      }
2051
 
2052
      protected doHdfcPaymentForDigitalOrder_result getResult(I iface, doHdfcPaymentForDigitalOrder_args args) throws org.apache.thrift.TException {
2053
        doHdfcPaymentForDigitalOrder_result result = new doHdfcPaymentForDigitalOrder_result();
2054
        try {
10269 amit.gupta 2055
          result.success = iface.doHdfcPaymentForDigitalOrder(args.merchantPaymentId, args.rechargeOrderId, args.phone, args.isMobile);
6050 anupam.sin 2056
        } catch (PaymentException pe) {
2057
          result.pe = pe;
2058
        }
2059
        return result;
2060
      }
2061
    }
2062
 
3616 chandransh 2063
    private static class initializeHdfcEmiPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, initializeHdfcEmiPayment_args> {
2064
      public initializeHdfcEmiPayment() {
2065
        super("initializeHdfcEmiPayment");
2066
      }
2067
 
2068
      protected initializeHdfcEmiPayment_args getEmptyArgsInstance() {
2069
        return new initializeHdfcEmiPayment_args();
2070
      }
2071
 
2072
      protected initializeHdfcEmiPayment_result getResult(I iface, initializeHdfcEmiPayment_args args) throws org.apache.thrift.TException {
2073
        initializeHdfcEmiPayment_result result = new initializeHdfcEmiPayment_result();
2074
        try {
10269 amit.gupta 2075
          result.success = iface.initializeHdfcEmiPayment(args.merchantPaymentId, args.isMobile);
3616 chandransh 2076
        } catch (PaymentException pe) {
2077
          result.pe = pe;
2078
        }
2079
        return result;
2080
      }
2081
    }
2082
 
3430 rajveer 2083
    private static class createRefund<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createRefund_args> {
2084
      public createRefund() {
2085
        super("createRefund");
2086
      }
2087
 
2088
      protected createRefund_args getEmptyArgsInstance() {
2089
        return new createRefund_args();
2090
      }
2091
 
2092
      protected createRefund_result getResult(I iface, createRefund_args args) throws org.apache.thrift.TException {
2690 chandransh 2093
        createRefund_result result = new createRefund_result();
2094
        try {
3430 rajveer 2095
          result.success = iface.createRefund(args.orderId, args.merchantTxnId, args.amount);
2690 chandransh 2096
          result.setSuccessIsSet(true);
2097
        } catch (PaymentException pe) {
2098
          result.pe = pe;
2099
        }
3430 rajveer 2100
        return result;
2690 chandransh 2101
      }
2102
    }
2103
 
3430 rajveer 2104
    private static class capturePayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, capturePayment_args> {
2105
      public capturePayment() {
2106
        super("capturePayment");
2107
      }
2108
 
2109
      protected capturePayment_args getEmptyArgsInstance() {
2110
        return new capturePayment_args();
2111
      }
2112
 
2113
      protected capturePayment_result getResult(I iface, capturePayment_args args) throws org.apache.thrift.TException {
3010 chandransh 2114
        capturePayment_result result = new capturePayment_result();
2115
        try {
8618 rajveer 2116
          result.success = iface.capturePayment(args.merchantTxnId, args.isDigital);
3010 chandransh 2117
          result.setSuccessIsSet(true);
2118
        } catch (PaymentException pe) {
2119
          result.pe = pe;
2120
        }
3430 rajveer 2121
        return result;
3010 chandransh 2122
      }
2123
    }
2124
 
6486 rajveer 2125
    private static class refundPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, refundPayment_args> {
2126
      public refundPayment() {
2127
        super("refundPayment");
2128
      }
2129
 
2130
      protected refundPayment_args getEmptyArgsInstance() {
2131
        return new refundPayment_args();
2132
      }
2133
 
2134
      protected refundPayment_result getResult(I iface, refundPayment_args args) throws org.apache.thrift.TException {
2135
        refundPayment_result result = new refundPayment_result();
2136
        try {
2137
          result.success = iface.refundPayment(args.merchantTxnId, args.amount, args.isDigital);
2138
          result.setSuccessIsSet(true);
2139
        } catch (PaymentException pe) {
2140
          result.pe = pe;
2141
        }
2142
        return result;
2143
      }
2144
    }
2145
 
3956 chandransh 2146
    private static class partiallyCapturePayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, partiallyCapturePayment_args> {
2147
      public partiallyCapturePayment() {
2148
        super("partiallyCapturePayment");
2149
      }
2150
 
2151
      protected partiallyCapturePayment_args getEmptyArgsInstance() {
2152
        return new partiallyCapturePayment_args();
2153
      }
2154
 
2155
      protected partiallyCapturePayment_result getResult(I iface, partiallyCapturePayment_args args) throws org.apache.thrift.TException {
2156
        partiallyCapturePayment_result result = new partiallyCapturePayment_result();
2157
        try {
2158
          result.success = iface.partiallyCapturePayment(args.merchantTxnId, args.amount, args.xferBy, args.xferTxnId, args.xferDate);
2159
          result.setSuccessIsSet(true);
2160
        } catch (PaymentException pe) {
2161
          result.pe = pe;
2162
        }
2163
        return result;
2164
      }
2165
    }
2166
 
4008 mandeep.dh 2167
    private static class getPaymentsRequiringExtraProcessing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsRequiringExtraProcessing_args> {
2168
      public getPaymentsRequiringExtraProcessing() {
2169
        super("getPaymentsRequiringExtraProcessing");
2170
      }
2171
 
2172
      protected getPaymentsRequiringExtraProcessing_args getEmptyArgsInstance() {
2173
        return new getPaymentsRequiringExtraProcessing_args();
2174
      }
2175
 
2176
      protected getPaymentsRequiringExtraProcessing_result getResult(I iface, getPaymentsRequiringExtraProcessing_args args) throws org.apache.thrift.TException {
2177
        getPaymentsRequiringExtraProcessing_result result = new getPaymentsRequiringExtraProcessing_result();
2178
        result.success = iface.getPaymentsRequiringExtraProcessing(args.category);
2179
        return result;
2180
      }
2181
    }
2182
 
2183
    private static class markPaymentAsProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, markPaymentAsProcessed_args> {
2184
      public markPaymentAsProcessed() {
2185
        super("markPaymentAsProcessed");
2186
      }
2187
 
2188
      protected markPaymentAsProcessed_args getEmptyArgsInstance() {
2189
        return new markPaymentAsProcessed_args();
2190
      }
2191
 
2192
      protected markPaymentAsProcessed_result getResult(I iface, markPaymentAsProcessed_args args) throws org.apache.thrift.TException {
2193
        markPaymentAsProcessed_result result = new markPaymentAsProcessed_result();
2194
        iface.markPaymentAsProcessed(args.paymentId, args.category);
2195
        return result;
2196
      }
2197
    }
2198
 
8914 rajveer 2199
    private static class getPaymentStatusAtGateway<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentStatusAtGateway_args> {
2200
      public getPaymentStatusAtGateway() {
2201
        super("getPaymentStatusAtGateway");
8907 rajveer 2202
      }
2203
 
8914 rajveer 2204
      protected getPaymentStatusAtGateway_args getEmptyArgsInstance() {
2205
        return new getPaymentStatusAtGateway_args();
8907 rajveer 2206
      }
2207
 
8914 rajveer 2208
      protected getPaymentStatusAtGateway_result getResult(I iface, getPaymentStatusAtGateway_args args) throws org.apache.thrift.TException {
2209
        getPaymentStatusAtGateway_result result = new getPaymentStatusAtGateway_result();
8907 rajveer 2210
        try {
8914 rajveer 2211
          result.success = iface.getPaymentStatusAtGateway(args.merchantTxnId, args.amount, args.isDigital);
8907 rajveer 2212
        } catch (PaymentException pe) {
2213
          result.pe = pe;
2214
        }
2215
        return result;
2216
      }
2217
    }
2218
 
123 ashish 2219
  }
2220
 
3430 rajveer 2221
  public static class createPayment_args implements org.apache.thrift.TBase<createPayment_args, createPayment_args._Fields>, java.io.Serializable, Cloneable   {
2222
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPayment_args");
123 ashish 2223
 
3430 rajveer 2224
    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);
2225
    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);
2226
    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);
2227
    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 2228
    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 2229
 
3430 rajveer 2230
    private long userId; // required
2231
    private double amount; // required
2232
    private long gatewayId; // required
2233
    private long txnId; // required
6050 anupam.sin 2234
    private boolean isDigital; // required
123 ashish 2235
 
2236
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2237
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 2238
      USER_ID((short)1, "userId"),
2239
      AMOUNT((short)2, "amount"),
2240
      GATEWAY_ID((short)3, "gatewayId"),
6050 anupam.sin 2241
      TXN_ID((short)4, "txnId"),
2242
      IS_DIGITAL((short)5, "isDigital");
123 ashish 2243
 
2244
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2245
 
2246
      static {
2247
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2248
          byName.put(field.getFieldName(), field);
2249
        }
2250
      }
2251
 
2252
      /**
2253
       * Find the _Fields constant that matches fieldId, or null if its not found.
2254
       */
2255
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2256
        switch(fieldId) {
2257
          case 1: // USER_ID
2258
            return USER_ID;
2259
          case 2: // AMOUNT
2260
            return AMOUNT;
2261
          case 3: // GATEWAY_ID
2262
            return GATEWAY_ID;
2263
          case 4: // TXN_ID
2264
            return TXN_ID;
6050 anupam.sin 2265
          case 5: // IS_DIGITAL
2266
            return IS_DIGITAL;
3430 rajveer 2267
          default:
2268
            return null;
2269
        }
123 ashish 2270
      }
2271
 
2272
      /**
2273
       * Find the _Fields constant that matches fieldId, throwing an exception
2274
       * if it is not found.
2275
       */
2276
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2277
        _Fields fields = findByThriftId(fieldId);
2278
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2279
        return fields;
2280
      }
2281
 
2282
      /**
2283
       * Find the _Fields constant that matches name, or null if its not found.
2284
       */
2285
      public static _Fields findByName(String name) {
2286
        return byName.get(name);
2287
      }
2288
 
2289
      private final short _thriftId;
2290
      private final String _fieldName;
2291
 
2292
      _Fields(short thriftId, String fieldName) {
2293
        _thriftId = thriftId;
2294
        _fieldName = fieldName;
2295
      }
2296
 
2297
      public short getThriftFieldId() {
2298
        return _thriftId;
2299
      }
2300
 
2301
      public String getFieldName() {
2302
        return _fieldName;
2303
      }
2304
    }
2305
 
2306
    // isset id assignments
695 rajveer 2307
    private static final int __USERID_ISSET_ID = 0;
2308
    private static final int __AMOUNT_ISSET_ID = 1;
2309
    private static final int __GATEWAYID_ISSET_ID = 2;
2310
    private static final int __TXNID_ISSET_ID = 3;
6050 anupam.sin 2311
    private static final int __ISDIGITAL_ISSET_ID = 4;
2312
    private BitSet __isset_bit_vector = new BitSet(5);
123 ashish 2313
 
3430 rajveer 2314
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 2315
    static {
3430 rajveer 2316
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2317
      tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2318
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2319
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2320
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
2321
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2322
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2323
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2324
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6050 anupam.sin 2325
      tmpMap.put(_Fields.IS_DIGITAL, new org.apache.thrift.meta_data.FieldMetaData("isDigital", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2326
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
3430 rajveer 2327
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2328
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createPayment_args.class, metaDataMap);
123 ashish 2329
    }
2330
 
2331
    public createPayment_args() {
2332
    }
2333
 
2334
    public createPayment_args(
695 rajveer 2335
      long userId,
123 ashish 2336
      double amount,
695 rajveer 2337
      long gatewayId,
6050 anupam.sin 2338
      long txnId,
2339
      boolean isDigital)
123 ashish 2340
    {
2341
      this();
695 rajveer 2342
      this.userId = userId;
2343
      setUserIdIsSet(true);
123 ashish 2344
      this.amount = amount;
2345
      setAmountIsSet(true);
695 rajveer 2346
      this.gatewayId = gatewayId;
2347
      setGatewayIdIsSet(true);
2348
      this.txnId = txnId;
2349
      setTxnIdIsSet(true);
6050 anupam.sin 2350
      this.isDigital = isDigital;
2351
      setIsDigitalIsSet(true);
123 ashish 2352
    }
2353
 
2354
    /**
2355
     * Performs a deep copy on <i>other</i>.
2356
     */
2357
    public createPayment_args(createPayment_args other) {
2358
      __isset_bit_vector.clear();
2359
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 2360
      this.userId = other.userId;
123 ashish 2361
      this.amount = other.amount;
695 rajveer 2362
      this.gatewayId = other.gatewayId;
2363
      this.txnId = other.txnId;
6050 anupam.sin 2364
      this.isDigital = other.isDigital;
123 ashish 2365
    }
2366
 
2367
    public createPayment_args deepCopy() {
2368
      return new createPayment_args(this);
2369
    }
2370
 
3430 rajveer 2371
    @Override
2372
    public void clear() {
2373
      setUserIdIsSet(false);
2374
      this.userId = 0;
2375
      setAmountIsSet(false);
2376
      this.amount = 0.0;
2377
      setGatewayIdIsSet(false);
2378
      this.gatewayId = 0;
2379
      setTxnIdIsSet(false);
2380
      this.txnId = 0;
6050 anupam.sin 2381
      setIsDigitalIsSet(false);
2382
      this.isDigital = false;
123 ashish 2383
    }
2384
 
695 rajveer 2385
    public long getUserId() {
2386
      return this.userId;
123 ashish 2387
    }
2388
 
3430 rajveer 2389
    public void setUserId(long userId) {
695 rajveer 2390
      this.userId = userId;
2391
      setUserIdIsSet(true);
123 ashish 2392
    }
2393
 
695 rajveer 2394
    public void unsetUserId() {
2395
      __isset_bit_vector.clear(__USERID_ISSET_ID);
123 ashish 2396
    }
2397
 
3430 rajveer 2398
    /** Returns true if field userId is set (has been assigned a value) and false otherwise */
695 rajveer 2399
    public boolean isSetUserId() {
2400
      return __isset_bit_vector.get(__USERID_ISSET_ID);
123 ashish 2401
    }
2402
 
695 rajveer 2403
    public void setUserIdIsSet(boolean value) {
2404
      __isset_bit_vector.set(__USERID_ISSET_ID, value);
123 ashish 2405
    }
2406
 
2407
    public double getAmount() {
2408
      return this.amount;
2409
    }
2410
 
3430 rajveer 2411
    public void setAmount(double amount) {
123 ashish 2412
      this.amount = amount;
2413
      setAmountIsSet(true);
2414
    }
2415
 
2416
    public void unsetAmount() {
2417
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
2418
    }
2419
 
3430 rajveer 2420
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
123 ashish 2421
    public boolean isSetAmount() {
2422
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
2423
    }
2424
 
2425
    public void setAmountIsSet(boolean value) {
2426
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
2427
    }
2428
 
695 rajveer 2429
    public long getGatewayId() {
2430
      return this.gatewayId;
123 ashish 2431
    }
2432
 
3430 rajveer 2433
    public void setGatewayId(long gatewayId) {
695 rajveer 2434
      this.gatewayId = gatewayId;
2435
      setGatewayIdIsSet(true);
123 ashish 2436
    }
2437
 
695 rajveer 2438
    public void unsetGatewayId() {
2439
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 2440
    }
2441
 
3430 rajveer 2442
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 2443
    public boolean isSetGatewayId() {
2444
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 2445
    }
2446
 
695 rajveer 2447
    public void setGatewayIdIsSet(boolean value) {
2448
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 2449
    }
2450
 
695 rajveer 2451
    public long getTxnId() {
2452
      return this.txnId;
2453
    }
2454
 
3430 rajveer 2455
    public void setTxnId(long txnId) {
695 rajveer 2456
      this.txnId = txnId;
2457
      setTxnIdIsSet(true);
2458
    }
2459
 
2460
    public void unsetTxnId() {
2461
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
2462
    }
2463
 
3430 rajveer 2464
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
695 rajveer 2465
    public boolean isSetTxnId() {
2466
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
2467
    }
2468
 
2469
    public void setTxnIdIsSet(boolean value) {
2470
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
2471
    }
2472
 
6050 anupam.sin 2473
    public boolean isIsDigital() {
2474
      return this.isDigital;
2475
    }
2476
 
2477
    public void setIsDigital(boolean isDigital) {
2478
      this.isDigital = isDigital;
2479
      setIsDigitalIsSet(true);
2480
    }
2481
 
2482
    public void unsetIsDigital() {
2483
      __isset_bit_vector.clear(__ISDIGITAL_ISSET_ID);
2484
    }
2485
 
2486
    /** Returns true if field isDigital is set (has been assigned a value) and false otherwise */
2487
    public boolean isSetIsDigital() {
2488
      return __isset_bit_vector.get(__ISDIGITAL_ISSET_ID);
2489
    }
2490
 
2491
    public void setIsDigitalIsSet(boolean value) {
2492
      __isset_bit_vector.set(__ISDIGITAL_ISSET_ID, value);
2493
    }
2494
 
123 ashish 2495
    public void setFieldValue(_Fields field, Object value) {
2496
      switch (field) {
2497
      case USER_ID:
2498
        if (value == null) {
695 rajveer 2499
          unsetUserId();
123 ashish 2500
        } else {
695 rajveer 2501
          setUserId((Long)value);
123 ashish 2502
        }
2503
        break;
2504
 
695 rajveer 2505
      case AMOUNT:
123 ashish 2506
        if (value == null) {
695 rajveer 2507
          unsetAmount();
123 ashish 2508
        } else {
695 rajveer 2509
          setAmount((Double)value);
123 ashish 2510
        }
2511
        break;
2512
 
695 rajveer 2513
      case GATEWAY_ID:
123 ashish 2514
        if (value == null) {
695 rajveer 2515
          unsetGatewayId();
123 ashish 2516
        } else {
695 rajveer 2517
          setGatewayId((Long)value);
123 ashish 2518
        }
2519
        break;
2520
 
695 rajveer 2521
      case TXN_ID:
123 ashish 2522
        if (value == null) {
695 rajveer 2523
          unsetTxnId();
123 ashish 2524
        } else {
695 rajveer 2525
          setTxnId((Long)value);
123 ashish 2526
        }
2527
        break;
2528
 
6050 anupam.sin 2529
      case IS_DIGITAL:
2530
        if (value == null) {
2531
          unsetIsDigital();
2532
        } else {
2533
          setIsDigital((Boolean)value);
2534
        }
2535
        break;
2536
 
123 ashish 2537
      }
2538
    }
2539
 
2540
    public Object getFieldValue(_Fields field) {
2541
      switch (field) {
2542
      case USER_ID:
3430 rajveer 2543
        return Long.valueOf(getUserId());
123 ashish 2544
 
2545
      case AMOUNT:
3430 rajveer 2546
        return Double.valueOf(getAmount());
123 ashish 2547
 
420 ashish 2548
      case GATEWAY_ID:
3430 rajveer 2549
        return Long.valueOf(getGatewayId());
123 ashish 2550
 
695 rajveer 2551
      case TXN_ID:
3430 rajveer 2552
        return Long.valueOf(getTxnId());
695 rajveer 2553
 
6050 anupam.sin 2554
      case IS_DIGITAL:
2555
        return Boolean.valueOf(isIsDigital());
2556
 
123 ashish 2557
      }
2558
      throw new IllegalStateException();
2559
    }
2560
 
3430 rajveer 2561
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2562
    public boolean isSet(_Fields field) {
2563
      if (field == null) {
2564
        throw new IllegalArgumentException();
2565
      }
123 ashish 2566
 
2567
      switch (field) {
2568
      case USER_ID:
695 rajveer 2569
        return isSetUserId();
123 ashish 2570
      case AMOUNT:
2571
        return isSetAmount();
420 ashish 2572
      case GATEWAY_ID:
695 rajveer 2573
        return isSetGatewayId();
2574
      case TXN_ID:
2575
        return isSetTxnId();
6050 anupam.sin 2576
      case IS_DIGITAL:
2577
        return isSetIsDigital();
123 ashish 2578
      }
2579
      throw new IllegalStateException();
2580
    }
2581
 
2582
    @Override
2583
    public boolean equals(Object that) {
2584
      if (that == null)
2585
        return false;
2586
      if (that instanceof createPayment_args)
2587
        return this.equals((createPayment_args)that);
2588
      return false;
2589
    }
2590
 
2591
    public boolean equals(createPayment_args that) {
2592
      if (that == null)
2593
        return false;
2594
 
695 rajveer 2595
      boolean this_present_userId = true;
2596
      boolean that_present_userId = true;
2597
      if (this_present_userId || that_present_userId) {
2598
        if (!(this_present_userId && that_present_userId))
123 ashish 2599
          return false;
695 rajveer 2600
        if (this.userId != that.userId)
123 ashish 2601
          return false;
2602
      }
2603
 
2604
      boolean this_present_amount = true;
2605
      boolean that_present_amount = true;
2606
      if (this_present_amount || that_present_amount) {
2607
        if (!(this_present_amount && that_present_amount))
2608
          return false;
2609
        if (this.amount != that.amount)
2610
          return false;
2611
      }
2612
 
695 rajveer 2613
      boolean this_present_gatewayId = true;
2614
      boolean that_present_gatewayId = true;
2615
      if (this_present_gatewayId || that_present_gatewayId) {
2616
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 2617
          return false;
695 rajveer 2618
        if (this.gatewayId != that.gatewayId)
123 ashish 2619
          return false;
2620
      }
2621
 
695 rajveer 2622
      boolean this_present_txnId = true;
2623
      boolean that_present_txnId = true;
2624
      if (this_present_txnId || that_present_txnId) {
2625
        if (!(this_present_txnId && that_present_txnId))
2626
          return false;
2627
        if (this.txnId != that.txnId)
2628
          return false;
2629
      }
2630
 
6050 anupam.sin 2631
      boolean this_present_isDigital = true;
2632
      boolean that_present_isDigital = true;
2633
      if (this_present_isDigital || that_present_isDigital) {
2634
        if (!(this_present_isDigital && that_present_isDigital))
2635
          return false;
2636
        if (this.isDigital != that.isDigital)
2637
          return false;
2638
      }
2639
 
123 ashish 2640
      return true;
2641
    }
2642
 
2643
    @Override
2644
    public int hashCode() {
2645
      return 0;
2646
    }
2647
 
2648
    public int compareTo(createPayment_args other) {
2649
      if (!getClass().equals(other.getClass())) {
2650
        return getClass().getName().compareTo(other.getClass().getName());
2651
      }
2652
 
2653
      int lastComparison = 0;
2654
      createPayment_args typedOther = (createPayment_args)other;
2655
 
3430 rajveer 2656
      lastComparison = Boolean.valueOf(isSetUserId()).compareTo(typedOther.isSetUserId());
123 ashish 2657
      if (lastComparison != 0) {
2658
        return lastComparison;
2659
      }
3430 rajveer 2660
      if (isSetUserId()) {
2661
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userId, typedOther.userId);
2662
        if (lastComparison != 0) {
2663
          return lastComparison;
2664
        }
123 ashish 2665
      }
3430 rajveer 2666
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
123 ashish 2667
      if (lastComparison != 0) {
2668
        return lastComparison;
2669
      }
3430 rajveer 2670
      if (isSetAmount()) {
2671
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
2672
        if (lastComparison != 0) {
2673
          return lastComparison;
2674
        }
123 ashish 2675
      }
3430 rajveer 2676
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 2677
      if (lastComparison != 0) {
2678
        return lastComparison;
2679
      }
3430 rajveer 2680
      if (isSetGatewayId()) {
2681
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
2682
        if (lastComparison != 0) {
2683
          return lastComparison;
2684
        }
123 ashish 2685
      }
3430 rajveer 2686
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
123 ashish 2687
      if (lastComparison != 0) {
2688
        return lastComparison;
2689
      }
3430 rajveer 2690
      if (isSetTxnId()) {
2691
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
2692
        if (lastComparison != 0) {
2693
          return lastComparison;
2694
        }
123 ashish 2695
      }
6050 anupam.sin 2696
      lastComparison = Boolean.valueOf(isSetIsDigital()).compareTo(typedOther.isSetIsDigital());
2697
      if (lastComparison != 0) {
2698
        return lastComparison;
2699
      }
2700
      if (isSetIsDigital()) {
2701
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isDigital, typedOther.isDigital);
2702
        if (lastComparison != 0) {
2703
          return lastComparison;
2704
        }
2705
      }
123 ashish 2706
      return 0;
2707
    }
2708
 
3430 rajveer 2709
    public _Fields fieldForId(int fieldId) {
2710
      return _Fields.findByThriftId(fieldId);
2711
    }
2712
 
2713
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2714
      org.apache.thrift.protocol.TField field;
123 ashish 2715
      iprot.readStructBegin();
2716
      while (true)
2717
      {
2718
        field = iprot.readFieldBegin();
3430 rajveer 2719
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 2720
          break;
2721
        }
3430 rajveer 2722
        switch (field.id) {
2723
          case 1: // USER_ID
2724
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2725
              this.userId = iprot.readI64();
2726
              setUserIdIsSet(true);
2727
            } else { 
2728
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2729
            }
2730
            break;
2731
          case 2: // AMOUNT
2732
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
2733
              this.amount = iprot.readDouble();
2734
              setAmountIsSet(true);
2735
            } else { 
2736
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2737
            }
2738
            break;
2739
          case 3: // GATEWAY_ID
2740
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2741
              this.gatewayId = iprot.readI64();
2742
              setGatewayIdIsSet(true);
2743
            } else { 
2744
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2745
            }
2746
            break;
2747
          case 4: // TXN_ID
2748
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2749
              this.txnId = iprot.readI64();
2750
              setTxnIdIsSet(true);
2751
            } else { 
2752
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2753
            }
2754
            break;
6050 anupam.sin 2755
          case 5: // IS_DIGITAL
2756
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
2757
              this.isDigital = iprot.readBool();
2758
              setIsDigitalIsSet(true);
2759
            } else { 
2760
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2761
            }
2762
            break;
3430 rajveer 2763
          default:
2764
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 2765
        }
3430 rajveer 2766
        iprot.readFieldEnd();
123 ashish 2767
      }
2768
      iprot.readStructEnd();
2769
      validate();
2770
    }
2771
 
3430 rajveer 2772
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 2773
      validate();
2774
 
2775
      oprot.writeStructBegin(STRUCT_DESC);
2776
      oprot.writeFieldBegin(USER_ID_FIELD_DESC);
695 rajveer 2777
      oprot.writeI64(this.userId);
123 ashish 2778
      oprot.writeFieldEnd();
2779
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
2780
      oprot.writeDouble(this.amount);
2781
      oprot.writeFieldEnd();
420 ashish 2782
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 2783
      oprot.writeI64(this.gatewayId);
420 ashish 2784
      oprot.writeFieldEnd();
695 rajveer 2785
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
2786
      oprot.writeI64(this.txnId);
2787
      oprot.writeFieldEnd();
6050 anupam.sin 2788
      oprot.writeFieldBegin(IS_DIGITAL_FIELD_DESC);
2789
      oprot.writeBool(this.isDigital);
2790
      oprot.writeFieldEnd();
123 ashish 2791
      oprot.writeFieldStop();
2792
      oprot.writeStructEnd();
2793
    }
2794
 
2795
    @Override
2796
    public String toString() {
2797
      StringBuilder sb = new StringBuilder("createPayment_args(");
2798
      boolean first = true;
2799
 
695 rajveer 2800
      sb.append("userId:");
2801
      sb.append(this.userId);
123 ashish 2802
      first = false;
2803
      if (!first) sb.append(", ");
2804
      sb.append("amount:");
2805
      sb.append(this.amount);
2806
      first = false;
2807
      if (!first) sb.append(", ");
695 rajveer 2808
      sb.append("gatewayId:");
2809
      sb.append(this.gatewayId);
123 ashish 2810
      first = false;
695 rajveer 2811
      if (!first) sb.append(", ");
2812
      sb.append("txnId:");
2813
      sb.append(this.txnId);
2814
      first = false;
6050 anupam.sin 2815
      if (!first) sb.append(", ");
2816
      sb.append("isDigital:");
2817
      sb.append(this.isDigital);
2818
      first = false;
123 ashish 2819
      sb.append(")");
2820
      return sb.toString();
2821
    }
2822
 
3430 rajveer 2823
    public void validate() throws org.apache.thrift.TException {
123 ashish 2824
      // check for required fields
2825
    }
2826
 
3430 rajveer 2827
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2828
      try {
2829
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2830
      } catch (org.apache.thrift.TException te) {
2831
        throw new java.io.IOException(te);
2832
      }
2833
    }
2834
 
2835
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2836
      try {
2837
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2838
      } catch (org.apache.thrift.TException te) {
2839
        throw new java.io.IOException(te);
2840
      }
2841
    }
2842
 
123 ashish 2843
  }
2844
 
3430 rajveer 2845
  public static class createPayment_result implements org.apache.thrift.TBase<createPayment_result, createPayment_result._Fields>, java.io.Serializable, Cloneable   {
2846
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPayment_result");
123 ashish 2847
 
3430 rajveer 2848
    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);
2849
    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 2850
 
3430 rajveer 2851
    private long success; // required
2852
    private PaymentException pe; // required
123 ashish 2853
 
2854
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2855
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 2856
      SUCCESS((short)0, "success"),
2857
      PE((short)1, "pe");
2858
 
2859
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2860
 
2861
      static {
2862
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2863
          byName.put(field.getFieldName(), field);
2864
        }
2865
      }
2866
 
2867
      /**
2868
       * Find the _Fields constant that matches fieldId, or null if its not found.
2869
       */
2870
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2871
        switch(fieldId) {
2872
          case 0: // SUCCESS
2873
            return SUCCESS;
2874
          case 1: // PE
2875
            return PE;
2876
          default:
2877
            return null;
2878
        }
123 ashish 2879
      }
2880
 
2881
      /**
2882
       * Find the _Fields constant that matches fieldId, throwing an exception
2883
       * if it is not found.
2884
       */
2885
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2886
        _Fields fields = findByThriftId(fieldId);
2887
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2888
        return fields;
2889
      }
2890
 
2891
      /**
2892
       * Find the _Fields constant that matches name, or null if its not found.
2893
       */
2894
      public static _Fields findByName(String name) {
2895
        return byName.get(name);
2896
      }
2897
 
2898
      private final short _thriftId;
2899
      private final String _fieldName;
2900
 
2901
      _Fields(short thriftId, String fieldName) {
2902
        _thriftId = thriftId;
2903
        _fieldName = fieldName;
2904
      }
2905
 
2906
      public short getThriftFieldId() {
2907
        return _thriftId;
2908
      }
2909
 
2910
      public String getFieldName() {
2911
        return _fieldName;
2912
      }
2913
    }
2914
 
2915
    // isset id assignments
420 ashish 2916
    private static final int __SUCCESS_ISSET_ID = 0;
2917
    private BitSet __isset_bit_vector = new BitSet(1);
123 ashish 2918
 
3430 rajveer 2919
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 2920
    static {
3430 rajveer 2921
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2922
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2923
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2924
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2925
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
2926
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2927
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createPayment_result.class, metaDataMap);
123 ashish 2928
    }
2929
 
2930
    public createPayment_result() {
2931
    }
2932
 
2933
    public createPayment_result(
420 ashish 2934
      long success,
123 ashish 2935
      PaymentException pe)
2936
    {
2937
      this();
2938
      this.success = success;
420 ashish 2939
      setSuccessIsSet(true);
123 ashish 2940
      this.pe = pe;
2941
    }
2942
 
2943
    /**
2944
     * Performs a deep copy on <i>other</i>.
2945
     */
2946
    public createPayment_result(createPayment_result other) {
420 ashish 2947
      __isset_bit_vector.clear();
2948
      __isset_bit_vector.or(other.__isset_bit_vector);
2949
      this.success = other.success;
123 ashish 2950
      if (other.isSetPe()) {
2951
        this.pe = new PaymentException(other.pe);
2952
      }
2953
    }
2954
 
2955
    public createPayment_result deepCopy() {
2956
      return new createPayment_result(this);
2957
    }
2958
 
3430 rajveer 2959
    @Override
2960
    public void clear() {
2961
      setSuccessIsSet(false);
2962
      this.success = 0;
2963
      this.pe = null;
123 ashish 2964
    }
2965
 
420 ashish 2966
    public long getSuccess() {
123 ashish 2967
      return this.success;
2968
    }
2969
 
3430 rajveer 2970
    public void setSuccess(long success) {
123 ashish 2971
      this.success = success;
420 ashish 2972
      setSuccessIsSet(true);
123 ashish 2973
    }
2974
 
2975
    public void unsetSuccess() {
420 ashish 2976
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
123 ashish 2977
    }
2978
 
3430 rajveer 2979
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 2980
    public boolean isSetSuccess() {
420 ashish 2981
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
123 ashish 2982
    }
2983
 
2984
    public void setSuccessIsSet(boolean value) {
420 ashish 2985
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
123 ashish 2986
    }
2987
 
2988
    public PaymentException getPe() {
2989
      return this.pe;
2990
    }
2991
 
3430 rajveer 2992
    public void setPe(PaymentException pe) {
123 ashish 2993
      this.pe = pe;
2994
    }
2995
 
2996
    public void unsetPe() {
2997
      this.pe = null;
2998
    }
2999
 
3430 rajveer 3000
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 3001
    public boolean isSetPe() {
3002
      return this.pe != null;
3003
    }
3004
 
3005
    public void setPeIsSet(boolean value) {
3006
      if (!value) {
3007
        this.pe = null;
3008
      }
3009
    }
3010
 
3011
    public void setFieldValue(_Fields field, Object value) {
3012
      switch (field) {
3013
      case SUCCESS:
3014
        if (value == null) {
3015
          unsetSuccess();
3016
        } else {
420 ashish 3017
          setSuccess((Long)value);
123 ashish 3018
        }
3019
        break;
3020
 
3021
      case PE:
3022
        if (value == null) {
3023
          unsetPe();
3024
        } else {
3025
          setPe((PaymentException)value);
3026
        }
3027
        break;
3028
 
3029
      }
3030
    }
3031
 
3032
    public Object getFieldValue(_Fields field) {
3033
      switch (field) {
3034
      case SUCCESS:
3430 rajveer 3035
        return Long.valueOf(getSuccess());
123 ashish 3036
 
3037
      case PE:
3038
        return getPe();
3039
 
3040
      }
3041
      throw new IllegalStateException();
3042
    }
3043
 
3430 rajveer 3044
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3045
    public boolean isSet(_Fields field) {
3046
      if (field == null) {
3047
        throw new IllegalArgumentException();
3048
      }
123 ashish 3049
 
3050
      switch (field) {
3051
      case SUCCESS:
3052
        return isSetSuccess();
3053
      case PE:
3054
        return isSetPe();
3055
      }
3056
      throw new IllegalStateException();
3057
    }
3058
 
3059
    @Override
3060
    public boolean equals(Object that) {
3061
      if (that == null)
3062
        return false;
3063
      if (that instanceof createPayment_result)
3064
        return this.equals((createPayment_result)that);
3065
      return false;
3066
    }
3067
 
3068
    public boolean equals(createPayment_result that) {
3069
      if (that == null)
3070
        return false;
3071
 
420 ashish 3072
      boolean this_present_success = true;
3073
      boolean that_present_success = true;
123 ashish 3074
      if (this_present_success || that_present_success) {
3075
        if (!(this_present_success && that_present_success))
3076
          return false;
420 ashish 3077
        if (this.success != that.success)
123 ashish 3078
          return false;
3079
      }
3080
 
3081
      boolean this_present_pe = true && this.isSetPe();
3082
      boolean that_present_pe = true && that.isSetPe();
3083
      if (this_present_pe || that_present_pe) {
3084
        if (!(this_present_pe && that_present_pe))
3085
          return false;
3086
        if (!this.pe.equals(that.pe))
3087
          return false;
3088
      }
3089
 
3090
      return true;
3091
    }
3092
 
3093
    @Override
3094
    public int hashCode() {
3095
      return 0;
3096
    }
3097
 
420 ashish 3098
    public int compareTo(createPayment_result other) {
3099
      if (!getClass().equals(other.getClass())) {
3100
        return getClass().getName().compareTo(other.getClass().getName());
3101
      }
3102
 
3103
      int lastComparison = 0;
3104
      createPayment_result typedOther = (createPayment_result)other;
3105
 
3430 rajveer 3106
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
420 ashish 3107
      if (lastComparison != 0) {
3108
        return lastComparison;
3109
      }
3430 rajveer 3110
      if (isSetSuccess()) {
3111
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3112
        if (lastComparison != 0) {
3113
          return lastComparison;
3114
        }
420 ashish 3115
      }
3430 rajveer 3116
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 3117
      if (lastComparison != 0) {
3118
        return lastComparison;
3119
      }
3430 rajveer 3120
      if (isSetPe()) {
3121
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
3122
        if (lastComparison != 0) {
3123
          return lastComparison;
3124
        }
420 ashish 3125
      }
3126
      return 0;
3127
    }
3128
 
3430 rajveer 3129
    public _Fields fieldForId(int fieldId) {
3130
      return _Fields.findByThriftId(fieldId);
3131
    }
3132
 
3133
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3134
      org.apache.thrift.protocol.TField field;
123 ashish 3135
      iprot.readStructBegin();
3136
      while (true)
3137
      {
3138
        field = iprot.readFieldBegin();
3430 rajveer 3139
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 3140
          break;
3141
        }
3430 rajveer 3142
        switch (field.id) {
3143
          case 0: // SUCCESS
3144
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3145
              this.success = iprot.readI64();
3146
              setSuccessIsSet(true);
3147
            } else { 
3148
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3149
            }
3150
            break;
3151
          case 1: // PE
3152
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3153
              this.pe = new PaymentException();
3154
              this.pe.read(iprot);
3155
            } else { 
3156
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3157
            }
3158
            break;
3159
          default:
3160
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 3161
        }
3430 rajveer 3162
        iprot.readFieldEnd();
123 ashish 3163
      }
3164
      iprot.readStructEnd();
3165
      validate();
3166
    }
3167
 
3430 rajveer 3168
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 3169
      oprot.writeStructBegin(STRUCT_DESC);
3170
 
3171
      if (this.isSetSuccess()) {
3172
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
420 ashish 3173
        oprot.writeI64(this.success);
123 ashish 3174
        oprot.writeFieldEnd();
3175
      } else if (this.isSetPe()) {
3176
        oprot.writeFieldBegin(PE_FIELD_DESC);
3177
        this.pe.write(oprot);
3178
        oprot.writeFieldEnd();
3179
      }
3180
      oprot.writeFieldStop();
3181
      oprot.writeStructEnd();
3182
    }
3183
 
3184
    @Override
3185
    public String toString() {
3186
      StringBuilder sb = new StringBuilder("createPayment_result(");
3187
      boolean first = true;
3188
 
3189
      sb.append("success:");
420 ashish 3190
      sb.append(this.success);
123 ashish 3191
      first = false;
3192
      if (!first) sb.append(", ");
3193
      sb.append("pe:");
3194
      if (this.pe == null) {
3195
        sb.append("null");
3196
      } else {
3197
        sb.append(this.pe);
3198
      }
3199
      first = false;
3200
      sb.append(")");
3201
      return sb.toString();
3202
    }
3203
 
3430 rajveer 3204
    public void validate() throws org.apache.thrift.TException {
123 ashish 3205
      // check for required fields
3206
    }
3207
 
3430 rajveer 3208
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3209
      try {
3210
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3211
      } catch (org.apache.thrift.TException te) {
3212
        throw new java.io.IOException(te);
3213
      }
3214
    }
3215
 
3216
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3217
      try {
3218
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3219
      } catch (org.apache.thrift.TException te) {
3220
        throw new java.io.IOException(te);
3221
      }
3222
    }
3223
 
123 ashish 3224
  }
3225
 
3430 rajveer 3226
  public static class getPaymentsForUser_args implements org.apache.thrift.TBase<getPaymentsForUser_args, getPaymentsForUser_args._Fields>, java.io.Serializable, Cloneable   {
3227
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsForUser_args");
123 ashish 3228
 
3430 rajveer 3229
    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);
3230
    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);
3231
    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);
3232
    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);
3233
    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 3234
 
3430 rajveer 3235
    private long userId; // required
3236
    private long fromTime; // required
3237
    private long toTime; // required
3238
    private PaymentStatus status; // required
3239
    private long gatewayId; // required
123 ashish 3240
 
3241
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3242
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 3243
      USER_ID((short)1, "userId"),
695 rajveer 3244
      FROM_TIME((short)2, "fromTime"),
3245
      TO_TIME((short)3, "toTime"),
123 ashish 3246
      /**
3247
       * 
3248
       * @see PaymentStatus
3249
       */
3250
      STATUS((short)4, "status"),
695 rajveer 3251
      GATEWAY_ID((short)5, "gatewayId");
123 ashish 3252
 
3253
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3254
 
3255
      static {
3256
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3257
          byName.put(field.getFieldName(), field);
3258
        }
3259
      }
3260
 
3261
      /**
3262
       * Find the _Fields constant that matches fieldId, or null if its not found.
3263
       */
3264
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3265
        switch(fieldId) {
3266
          case 1: // USER_ID
3267
            return USER_ID;
3268
          case 2: // FROM_TIME
3269
            return FROM_TIME;
3270
          case 3: // TO_TIME
3271
            return TO_TIME;
3272
          case 4: // STATUS
3273
            return STATUS;
3274
          case 5: // GATEWAY_ID
3275
            return GATEWAY_ID;
3276
          default:
3277
            return null;
3278
        }
123 ashish 3279
      }
3280
 
3281
      /**
3282
       * Find the _Fields constant that matches fieldId, throwing an exception
3283
       * if it is not found.
3284
       */
3285
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3286
        _Fields fields = findByThriftId(fieldId);
3287
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3288
        return fields;
3289
      }
3290
 
3291
      /**
3292
       * Find the _Fields constant that matches name, or null if its not found.
3293
       */
3294
      public static _Fields findByName(String name) {
3295
        return byName.get(name);
3296
      }
3297
 
3298
      private final short _thriftId;
3299
      private final String _fieldName;
3300
 
3301
      _Fields(short thriftId, String fieldName) {
3302
        _thriftId = thriftId;
3303
        _fieldName = fieldName;
3304
      }
3305
 
3306
      public short getThriftFieldId() {
3307
        return _thriftId;
3308
      }
3309
 
3310
      public String getFieldName() {
3311
        return _fieldName;
3312
      }
3313
    }
3314
 
3315
    // isset id assignments
3316
    private static final int __USERID_ISSET_ID = 0;
695 rajveer 3317
    private static final int __FROMTIME_ISSET_ID = 1;
3318
    private static final int __TOTIME_ISSET_ID = 2;
3319
    private static final int __GATEWAYID_ISSET_ID = 3;
420 ashish 3320
    private BitSet __isset_bit_vector = new BitSet(4);
123 ashish 3321
 
3430 rajveer 3322
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 3323
    static {
3430 rajveer 3324
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3325
      tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3326
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3327
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3328
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3329
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3330
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3331
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3332
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
3333
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3334
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3335
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3336
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsForUser_args.class, metaDataMap);
123 ashish 3337
    }
3338
 
3339
    public getPaymentsForUser_args() {
3340
    }
3341
 
3342
    public getPaymentsForUser_args(
3343
      long userId,
695 rajveer 3344
      long fromTime,
3345
      long toTime,
123 ashish 3346
      PaymentStatus status,
695 rajveer 3347
      long gatewayId)
123 ashish 3348
    {
3349
      this();
3350
      this.userId = userId;
3351
      setUserIdIsSet(true);
695 rajveer 3352
      this.fromTime = fromTime;
3353
      setFromTimeIsSet(true);
3354
      this.toTime = toTime;
3355
      setToTimeIsSet(true);
123 ashish 3356
      this.status = status;
695 rajveer 3357
      this.gatewayId = gatewayId;
3358
      setGatewayIdIsSet(true);
123 ashish 3359
    }
3360
 
3361
    /**
3362
     * Performs a deep copy on <i>other</i>.
3363
     */
3364
    public getPaymentsForUser_args(getPaymentsForUser_args other) {
3365
      __isset_bit_vector.clear();
3366
      __isset_bit_vector.or(other.__isset_bit_vector);
3367
      this.userId = other.userId;
695 rajveer 3368
      this.fromTime = other.fromTime;
3369
      this.toTime = other.toTime;
123 ashish 3370
      if (other.isSetStatus()) {
3371
        this.status = other.status;
3372
      }
695 rajveer 3373
      this.gatewayId = other.gatewayId;
123 ashish 3374
    }
3375
 
3376
    public getPaymentsForUser_args deepCopy() {
3377
      return new getPaymentsForUser_args(this);
3378
    }
3379
 
3430 rajveer 3380
    @Override
3381
    public void clear() {
3382
      setUserIdIsSet(false);
3383
      this.userId = 0;
3384
      setFromTimeIsSet(false);
3385
      this.fromTime = 0;
3386
      setToTimeIsSet(false);
3387
      this.toTime = 0;
3388
      this.status = null;
3389
      setGatewayIdIsSet(false);
3390
      this.gatewayId = 0;
123 ashish 3391
    }
3392
 
3393
    public long getUserId() {
3394
      return this.userId;
3395
    }
3396
 
3430 rajveer 3397
    public void setUserId(long userId) {
123 ashish 3398
      this.userId = userId;
3399
      setUserIdIsSet(true);
3400
    }
3401
 
3402
    public void unsetUserId() {
3403
      __isset_bit_vector.clear(__USERID_ISSET_ID);
3404
    }
3405
 
3430 rajveer 3406
    /** Returns true if field userId is set (has been assigned a value) and false otherwise */
123 ashish 3407
    public boolean isSetUserId() {
3408
      return __isset_bit_vector.get(__USERID_ISSET_ID);
3409
    }
3410
 
3411
    public void setUserIdIsSet(boolean value) {
3412
      __isset_bit_vector.set(__USERID_ISSET_ID, value);
3413
    }
3414
 
695 rajveer 3415
    public long getFromTime() {
3416
      return this.fromTime;
123 ashish 3417
    }
3418
 
3430 rajveer 3419
    public void setFromTime(long fromTime) {
695 rajveer 3420
      this.fromTime = fromTime;
3421
      setFromTimeIsSet(true);
123 ashish 3422
    }
3423
 
695 rajveer 3424
    public void unsetFromTime() {
3425
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
123 ashish 3426
    }
3427
 
3430 rajveer 3428
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
695 rajveer 3429
    public boolean isSetFromTime() {
3430
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
123 ashish 3431
    }
3432
 
695 rajveer 3433
    public void setFromTimeIsSet(boolean value) {
3434
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
123 ashish 3435
    }
3436
 
695 rajveer 3437
    public long getToTime() {
3438
      return this.toTime;
123 ashish 3439
    }
3440
 
3430 rajveer 3441
    public void setToTime(long toTime) {
695 rajveer 3442
      this.toTime = toTime;
3443
      setToTimeIsSet(true);
123 ashish 3444
    }
3445
 
695 rajveer 3446
    public void unsetToTime() {
3447
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
123 ashish 3448
    }
3449
 
3430 rajveer 3450
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
695 rajveer 3451
    public boolean isSetToTime() {
3452
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
123 ashish 3453
    }
3454
 
695 rajveer 3455
    public void setToTimeIsSet(boolean value) {
3456
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
123 ashish 3457
    }
3458
 
3459
    /**
3460
     * 
3461
     * @see PaymentStatus
3462
     */
3463
    public PaymentStatus getStatus() {
3464
      return this.status;
3465
    }
3466
 
3467
    /**
3468
     * 
3469
     * @see PaymentStatus
3470
     */
3430 rajveer 3471
    public void setStatus(PaymentStatus status) {
123 ashish 3472
      this.status = status;
3473
    }
3474
 
3475
    public void unsetStatus() {
3476
      this.status = null;
3477
    }
3478
 
3430 rajveer 3479
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
123 ashish 3480
    public boolean isSetStatus() {
3481
      return this.status != null;
3482
    }
3483
 
3484
    public void setStatusIsSet(boolean value) {
3485
      if (!value) {
3486
        this.status = null;
3487
      }
3488
    }
3489
 
695 rajveer 3490
    public long getGatewayId() {
3491
      return this.gatewayId;
123 ashish 3492
    }
3493
 
3430 rajveer 3494
    public void setGatewayId(long gatewayId) {
695 rajveer 3495
      this.gatewayId = gatewayId;
3496
      setGatewayIdIsSet(true);
123 ashish 3497
    }
3498
 
695 rajveer 3499
    public void unsetGatewayId() {
3500
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 3501
    }
3502
 
3430 rajveer 3503
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 3504
    public boolean isSetGatewayId() {
3505
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 3506
    }
3507
 
695 rajveer 3508
    public void setGatewayIdIsSet(boolean value) {
3509
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 3510
    }
3511
 
3512
    public void setFieldValue(_Fields field, Object value) {
3513
      switch (field) {
3514
      case USER_ID:
3515
        if (value == null) {
3516
          unsetUserId();
3517
        } else {
3518
          setUserId((Long)value);
3519
        }
3520
        break;
3521
 
3522
      case FROM_TIME:
3523
        if (value == null) {
695 rajveer 3524
          unsetFromTime();
123 ashish 3525
        } else {
695 rajveer 3526
          setFromTime((Long)value);
123 ashish 3527
        }
3528
        break;
3529
 
3530
      case TO_TIME:
3531
        if (value == null) {
695 rajveer 3532
          unsetToTime();
123 ashish 3533
        } else {
695 rajveer 3534
          setToTime((Long)value);
123 ashish 3535
        }
3536
        break;
3537
 
3538
      case STATUS:
3539
        if (value == null) {
3540
          unsetStatus();
3541
        } else {
3542
          setStatus((PaymentStatus)value);
3543
        }
3544
        break;
3545
 
420 ashish 3546
      case GATEWAY_ID:
123 ashish 3547
        if (value == null) {
695 rajveer 3548
          unsetGatewayId();
123 ashish 3549
        } else {
695 rajveer 3550
          setGatewayId((Long)value);
123 ashish 3551
        }
3552
        break;
3553
 
3554
      }
3555
    }
3556
 
3557
    public Object getFieldValue(_Fields field) {
3558
      switch (field) {
3559
      case USER_ID:
3430 rajveer 3560
        return Long.valueOf(getUserId());
123 ashish 3561
 
3562
      case FROM_TIME:
3430 rajveer 3563
        return Long.valueOf(getFromTime());
123 ashish 3564
 
3565
      case TO_TIME:
3430 rajveer 3566
        return Long.valueOf(getToTime());
123 ashish 3567
 
3568
      case STATUS:
3569
        return getStatus();
3570
 
420 ashish 3571
      case GATEWAY_ID:
3430 rajveer 3572
        return Long.valueOf(getGatewayId());
123 ashish 3573
 
3574
      }
3575
      throw new IllegalStateException();
3576
    }
3577
 
3430 rajveer 3578
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3579
    public boolean isSet(_Fields field) {
3580
      if (field == null) {
3581
        throw new IllegalArgumentException();
3582
      }
123 ashish 3583
 
3584
      switch (field) {
3585
      case USER_ID:
3586
        return isSetUserId();
3587
      case FROM_TIME:
695 rajveer 3588
        return isSetFromTime();
123 ashish 3589
      case TO_TIME:
695 rajveer 3590
        return isSetToTime();
123 ashish 3591
      case STATUS:
3592
        return isSetStatus();
420 ashish 3593
      case GATEWAY_ID:
695 rajveer 3594
        return isSetGatewayId();
123 ashish 3595
      }
3596
      throw new IllegalStateException();
3597
    }
3598
 
3599
    @Override
3600
    public boolean equals(Object that) {
3601
      if (that == null)
3602
        return false;
3603
      if (that instanceof getPaymentsForUser_args)
3604
        return this.equals((getPaymentsForUser_args)that);
3605
      return false;
3606
    }
3607
 
3608
    public boolean equals(getPaymentsForUser_args that) {
3609
      if (that == null)
3610
        return false;
3611
 
3612
      boolean this_present_userId = true;
3613
      boolean that_present_userId = true;
3614
      if (this_present_userId || that_present_userId) {
3615
        if (!(this_present_userId && that_present_userId))
3616
          return false;
3617
        if (this.userId != that.userId)
3618
          return false;
3619
      }
3620
 
695 rajveer 3621
      boolean this_present_fromTime = true;
3622
      boolean that_present_fromTime = true;
3623
      if (this_present_fromTime || that_present_fromTime) {
3624
        if (!(this_present_fromTime && that_present_fromTime))
123 ashish 3625
          return false;
695 rajveer 3626
        if (this.fromTime != that.fromTime)
123 ashish 3627
          return false;
3628
      }
3629
 
695 rajveer 3630
      boolean this_present_toTime = true;
3631
      boolean that_present_toTime = true;
3632
      if (this_present_toTime || that_present_toTime) {
3633
        if (!(this_present_toTime && that_present_toTime))
123 ashish 3634
          return false;
695 rajveer 3635
        if (this.toTime != that.toTime)
123 ashish 3636
          return false;
3637
      }
3638
 
3639
      boolean this_present_status = true && this.isSetStatus();
3640
      boolean that_present_status = true && that.isSetStatus();
3641
      if (this_present_status || that_present_status) {
3642
        if (!(this_present_status && that_present_status))
3643
          return false;
3644
        if (!this.status.equals(that.status))
3645
          return false;
3646
      }
3647
 
695 rajveer 3648
      boolean this_present_gatewayId = true;
3649
      boolean that_present_gatewayId = true;
3650
      if (this_present_gatewayId || that_present_gatewayId) {
3651
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 3652
          return false;
695 rajveer 3653
        if (this.gatewayId != that.gatewayId)
123 ashish 3654
          return false;
3655
      }
3656
 
3657
      return true;
3658
    }
3659
 
3660
    @Override
3661
    public int hashCode() {
3662
      return 0;
3663
    }
3664
 
3665
    public int compareTo(getPaymentsForUser_args other) {
3666
      if (!getClass().equals(other.getClass())) {
3667
        return getClass().getName().compareTo(other.getClass().getName());
3668
      }
3669
 
3670
      int lastComparison = 0;
3671
      getPaymentsForUser_args typedOther = (getPaymentsForUser_args)other;
3672
 
3430 rajveer 3673
      lastComparison = Boolean.valueOf(isSetUserId()).compareTo(typedOther.isSetUserId());
123 ashish 3674
      if (lastComparison != 0) {
3675
        return lastComparison;
3676
      }
3430 rajveer 3677
      if (isSetUserId()) {
3678
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userId, typedOther.userId);
3679
        if (lastComparison != 0) {
3680
          return lastComparison;
3681
        }
123 ashish 3682
      }
3430 rajveer 3683
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
123 ashish 3684
      if (lastComparison != 0) {
3685
        return lastComparison;
3686
      }
3430 rajveer 3687
      if (isSetFromTime()) {
3688
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
3689
        if (lastComparison != 0) {
3690
          return lastComparison;
3691
        }
123 ashish 3692
      }
3430 rajveer 3693
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
123 ashish 3694
      if (lastComparison != 0) {
3695
        return lastComparison;
3696
      }
3430 rajveer 3697
      if (isSetToTime()) {
3698
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
3699
        if (lastComparison != 0) {
3700
          return lastComparison;
3701
        }
123 ashish 3702
      }
3430 rajveer 3703
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
123 ashish 3704
      if (lastComparison != 0) {
3705
        return lastComparison;
3706
      }
3430 rajveer 3707
      if (isSetStatus()) {
3708
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
3709
        if (lastComparison != 0) {
3710
          return lastComparison;
3711
        }
123 ashish 3712
      }
3430 rajveer 3713
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 3714
      if (lastComparison != 0) {
3715
        return lastComparison;
3716
      }
3430 rajveer 3717
      if (isSetGatewayId()) {
3718
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
3719
        if (lastComparison != 0) {
3720
          return lastComparison;
3721
        }
123 ashish 3722
      }
3723
      return 0;
3724
    }
3725
 
3430 rajveer 3726
    public _Fields fieldForId(int fieldId) {
3727
      return _Fields.findByThriftId(fieldId);
3728
    }
3729
 
3730
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3731
      org.apache.thrift.protocol.TField field;
123 ashish 3732
      iprot.readStructBegin();
3733
      while (true)
3734
      {
3735
        field = iprot.readFieldBegin();
3430 rajveer 3736
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 3737
          break;
3738
        }
3430 rajveer 3739
        switch (field.id) {
3740
          case 1: // USER_ID
3741
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3742
              this.userId = iprot.readI64();
3743
              setUserIdIsSet(true);
3744
            } else { 
3745
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3746
            }
3747
            break;
3748
          case 2: // FROM_TIME
3749
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3750
              this.fromTime = iprot.readI64();
3751
              setFromTimeIsSet(true);
3752
            } else { 
3753
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3754
            }
3755
            break;
3756
          case 3: // TO_TIME
3757
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3758
              this.toTime = iprot.readI64();
3759
              setToTimeIsSet(true);
3760
            } else { 
3761
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3762
            }
3763
            break;
3764
          case 4: // STATUS
3765
            if (field.type == org.apache.thrift.protocol.TType.I32) {
3766
              this.status = PaymentStatus.findByValue(iprot.readI32());
3767
            } else { 
3768
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3769
            }
3770
            break;
3771
          case 5: // GATEWAY_ID
3772
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3773
              this.gatewayId = iprot.readI64();
3774
              setGatewayIdIsSet(true);
3775
            } else { 
3776
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3777
            }
3778
            break;
3779
          default:
3780
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 3781
        }
3430 rajveer 3782
        iprot.readFieldEnd();
123 ashish 3783
      }
3784
      iprot.readStructEnd();
3785
      validate();
3786
    }
3787
 
3430 rajveer 3788
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 3789
      validate();
3790
 
3791
      oprot.writeStructBegin(STRUCT_DESC);
3792
      oprot.writeFieldBegin(USER_ID_FIELD_DESC);
3793
      oprot.writeI64(this.userId);
3794
      oprot.writeFieldEnd();
3795
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
695 rajveer 3796
      oprot.writeI64(this.fromTime);
123 ashish 3797
      oprot.writeFieldEnd();
3798
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
695 rajveer 3799
      oprot.writeI64(this.toTime);
123 ashish 3800
      oprot.writeFieldEnd();
3801
      if (this.status != null) {
3802
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
3803
        oprot.writeI32(this.status.getValue());
3804
        oprot.writeFieldEnd();
3805
      }
420 ashish 3806
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 3807
      oprot.writeI64(this.gatewayId);
420 ashish 3808
      oprot.writeFieldEnd();
123 ashish 3809
      oprot.writeFieldStop();
3810
      oprot.writeStructEnd();
3811
    }
3812
 
3813
    @Override
3814
    public String toString() {
3815
      StringBuilder sb = new StringBuilder("getPaymentsForUser_args(");
3816
      boolean first = true;
3817
 
3818
      sb.append("userId:");
3819
      sb.append(this.userId);
3820
      first = false;
3821
      if (!first) sb.append(", ");
695 rajveer 3822
      sb.append("fromTime:");
3823
      sb.append(this.fromTime);
123 ashish 3824
      first = false;
3825
      if (!first) sb.append(", ");
695 rajveer 3826
      sb.append("toTime:");
3827
      sb.append(this.toTime);
123 ashish 3828
      first = false;
3829
      if (!first) sb.append(", ");
3830
      sb.append("status:");
3831
      if (this.status == null) {
3832
        sb.append("null");
3833
      } else {
3834
        sb.append(this.status);
3835
      }
3836
      first = false;
3837
      if (!first) sb.append(", ");
695 rajveer 3838
      sb.append("gatewayId:");
3839
      sb.append(this.gatewayId);
123 ashish 3840
      first = false;
3841
      sb.append(")");
3842
      return sb.toString();
3843
    }
3844
 
3430 rajveer 3845
    public void validate() throws org.apache.thrift.TException {
123 ashish 3846
      // check for required fields
3847
    }
3848
 
3430 rajveer 3849
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3850
      try {
3851
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3852
      } catch (org.apache.thrift.TException te) {
3853
        throw new java.io.IOException(te);
3854
      }
3855
    }
3856
 
3857
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3858
      try {
3859
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3860
      } catch (org.apache.thrift.TException te) {
3861
        throw new java.io.IOException(te);
3862
      }
3863
    }
3864
 
123 ashish 3865
  }
3866
 
3430 rajveer 3867
  public static class getPaymentsForUser_result implements org.apache.thrift.TBase<getPaymentsForUser_result, getPaymentsForUser_result._Fields>, java.io.Serializable, Cloneable   {
3868
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsForUser_result");
123 ashish 3869
 
3430 rajveer 3870
    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);
3871
    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 3872
 
3430 rajveer 3873
    private List<Payment> success; // required
3874
    private PaymentException pe; // required
123 ashish 3875
 
3876
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3877
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 3878
      SUCCESS((short)0, "success"),
3879
      PE((short)1, "pe");
3880
 
3881
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3882
 
3883
      static {
3884
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3885
          byName.put(field.getFieldName(), field);
3886
        }
3887
      }
3888
 
3889
      /**
3890
       * Find the _Fields constant that matches fieldId, or null if its not found.
3891
       */
3892
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3893
        switch(fieldId) {
3894
          case 0: // SUCCESS
3895
            return SUCCESS;
3896
          case 1: // PE
3897
            return PE;
3898
          default:
3899
            return null;
3900
        }
123 ashish 3901
      }
3902
 
3903
      /**
3904
       * Find the _Fields constant that matches fieldId, throwing an exception
3905
       * if it is not found.
3906
       */
3907
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3908
        _Fields fields = findByThriftId(fieldId);
3909
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3910
        return fields;
3911
      }
3912
 
3913
      /**
3914
       * Find the _Fields constant that matches name, or null if its not found.
3915
       */
3916
      public static _Fields findByName(String name) {
3917
        return byName.get(name);
3918
      }
3919
 
3920
      private final short _thriftId;
3921
      private final String _fieldName;
3922
 
3923
      _Fields(short thriftId, String fieldName) {
3924
        _thriftId = thriftId;
3925
        _fieldName = fieldName;
3926
      }
3927
 
3928
      public short getThriftFieldId() {
3929
        return _thriftId;
3930
      }
3931
 
3932
      public String getFieldName() {
3933
        return _fieldName;
3934
      }
3935
    }
3936
 
3937
    // isset id assignments
3938
 
3430 rajveer 3939
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 3940
    static {
3430 rajveer 3941
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3942
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3943
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
3944
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
3945
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3946
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3947
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3948
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsForUser_result.class, metaDataMap);
123 ashish 3949
    }
3950
 
3951
    public getPaymentsForUser_result() {
3952
    }
3953
 
3954
    public getPaymentsForUser_result(
3955
      List<Payment> success,
3956
      PaymentException pe)
3957
    {
3958
      this();
3959
      this.success = success;
3960
      this.pe = pe;
3961
    }
3962
 
3963
    /**
3964
     * Performs a deep copy on <i>other</i>.
3965
     */
3966
    public getPaymentsForUser_result(getPaymentsForUser_result other) {
3967
      if (other.isSetSuccess()) {
3968
        List<Payment> __this__success = new ArrayList<Payment>();
3969
        for (Payment other_element : other.success) {
3970
          __this__success.add(new Payment(other_element));
3971
        }
3972
        this.success = __this__success;
3973
      }
3974
      if (other.isSetPe()) {
3975
        this.pe = new PaymentException(other.pe);
3976
      }
3977
    }
3978
 
3979
    public getPaymentsForUser_result deepCopy() {
3980
      return new getPaymentsForUser_result(this);
3981
    }
3982
 
3430 rajveer 3983
    @Override
3984
    public void clear() {
3985
      this.success = null;
3986
      this.pe = null;
123 ashish 3987
    }
3988
 
3989
    public int getSuccessSize() {
3990
      return (this.success == null) ? 0 : this.success.size();
3991
    }
3992
 
3993
    public java.util.Iterator<Payment> getSuccessIterator() {
3994
      return (this.success == null) ? null : this.success.iterator();
3995
    }
3996
 
3997
    public void addToSuccess(Payment elem) {
3998
      if (this.success == null) {
3999
        this.success = new ArrayList<Payment>();
4000
      }
4001
      this.success.add(elem);
4002
    }
4003
 
4004
    public List<Payment> getSuccess() {
4005
      return this.success;
4006
    }
4007
 
3430 rajveer 4008
    public void setSuccess(List<Payment> success) {
123 ashish 4009
      this.success = success;
4010
    }
4011
 
4012
    public void unsetSuccess() {
4013
      this.success = null;
4014
    }
4015
 
3430 rajveer 4016
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 4017
    public boolean isSetSuccess() {
4018
      return this.success != null;
4019
    }
4020
 
4021
    public void setSuccessIsSet(boolean value) {
4022
      if (!value) {
4023
        this.success = null;
4024
      }
4025
    }
4026
 
4027
    public PaymentException getPe() {
4028
      return this.pe;
4029
    }
4030
 
3430 rajveer 4031
    public void setPe(PaymentException pe) {
123 ashish 4032
      this.pe = pe;
4033
    }
4034
 
4035
    public void unsetPe() {
4036
      this.pe = null;
4037
    }
4038
 
3430 rajveer 4039
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 4040
    public boolean isSetPe() {
4041
      return this.pe != null;
4042
    }
4043
 
4044
    public void setPeIsSet(boolean value) {
4045
      if (!value) {
4046
        this.pe = null;
4047
      }
4048
    }
4049
 
4050
    public void setFieldValue(_Fields field, Object value) {
4051
      switch (field) {
4052
      case SUCCESS:
4053
        if (value == null) {
4054
          unsetSuccess();
4055
        } else {
4056
          setSuccess((List<Payment>)value);
4057
        }
4058
        break;
4059
 
4060
      case PE:
4061
        if (value == null) {
4062
          unsetPe();
4063
        } else {
4064
          setPe((PaymentException)value);
4065
        }
4066
        break;
4067
 
4068
      }
4069
    }
4070
 
4071
    public Object getFieldValue(_Fields field) {
4072
      switch (field) {
4073
      case SUCCESS:
4074
        return getSuccess();
4075
 
4076
      case PE:
4077
        return getPe();
4078
 
4079
      }
4080
      throw new IllegalStateException();
4081
    }
4082
 
3430 rajveer 4083
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4084
    public boolean isSet(_Fields field) {
4085
      if (field == null) {
4086
        throw new IllegalArgumentException();
4087
      }
123 ashish 4088
 
4089
      switch (field) {
4090
      case SUCCESS:
4091
        return isSetSuccess();
4092
      case PE:
4093
        return isSetPe();
4094
      }
4095
      throw new IllegalStateException();
4096
    }
4097
 
4098
    @Override
4099
    public boolean equals(Object that) {
4100
      if (that == null)
4101
        return false;
4102
      if (that instanceof getPaymentsForUser_result)
4103
        return this.equals((getPaymentsForUser_result)that);
4104
      return false;
4105
    }
4106
 
4107
    public boolean equals(getPaymentsForUser_result that) {
4108
      if (that == null)
4109
        return false;
4110
 
4111
      boolean this_present_success = true && this.isSetSuccess();
4112
      boolean that_present_success = true && that.isSetSuccess();
4113
      if (this_present_success || that_present_success) {
4114
        if (!(this_present_success && that_present_success))
4115
          return false;
4116
        if (!this.success.equals(that.success))
4117
          return false;
4118
      }
4119
 
4120
      boolean this_present_pe = true && this.isSetPe();
4121
      boolean that_present_pe = true && that.isSetPe();
4122
      if (this_present_pe || that_present_pe) {
4123
        if (!(this_present_pe && that_present_pe))
4124
          return false;
4125
        if (!this.pe.equals(that.pe))
4126
          return false;
4127
      }
4128
 
4129
      return true;
4130
    }
4131
 
4132
    @Override
4133
    public int hashCode() {
4134
      return 0;
4135
    }
4136
 
695 rajveer 4137
    public int compareTo(getPaymentsForUser_result other) {
123 ashish 4138
      if (!getClass().equals(other.getClass())) {
4139
        return getClass().getName().compareTo(other.getClass().getName());
4140
      }
4141
 
4142
      int lastComparison = 0;
695 rajveer 4143
      getPaymentsForUser_result typedOther = (getPaymentsForUser_result)other;
123 ashish 4144
 
3430 rajveer 4145
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
123 ashish 4146
      if (lastComparison != 0) {
4147
        return lastComparison;
4148
      }
3430 rajveer 4149
      if (isSetSuccess()) {
4150
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4151
        if (lastComparison != 0) {
4152
          return lastComparison;
4153
        }
123 ashish 4154
      }
3430 rajveer 4155
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
123 ashish 4156
      if (lastComparison != 0) {
4157
        return lastComparison;
4158
      }
3430 rajveer 4159
      if (isSetPe()) {
4160
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
4161
        if (lastComparison != 0) {
4162
          return lastComparison;
4163
        }
123 ashish 4164
      }
4165
      return 0;
4166
    }
4167
 
3430 rajveer 4168
    public _Fields fieldForId(int fieldId) {
4169
      return _Fields.findByThriftId(fieldId);
4170
    }
4171
 
4172
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4173
      org.apache.thrift.protocol.TField field;
123 ashish 4174
      iprot.readStructBegin();
4175
      while (true)
4176
      {
4177
        field = iprot.readFieldBegin();
3430 rajveer 4178
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 4179
          break;
4180
        }
3430 rajveer 4181
        switch (field.id) {
4182
          case 0: // SUCCESS
4183
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
4184
              {
4185
                org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
4186
                this.success = new ArrayList<Payment>(_list12.size);
4187
                for (int _i13 = 0; _i13 < _list12.size; ++_i13)
123 ashish 4188
                {
3430 rajveer 4189
                  Payment _elem14; // required
4190
                  _elem14 = new Payment();
4191
                  _elem14.read(iprot);
4192
                  this.success.add(_elem14);
123 ashish 4193
                }
3430 rajveer 4194
                iprot.readListEnd();
123 ashish 4195
              }
3430 rajveer 4196
            } else { 
4197
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4198
            }
4199
            break;
4200
          case 1: // PE
4201
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4202
              this.pe = new PaymentException();
4203
              this.pe.read(iprot);
4204
            } else { 
4205
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4206
            }
4207
            break;
4208
          default:
4209
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 4210
        }
3430 rajveer 4211
        iprot.readFieldEnd();
123 ashish 4212
      }
4213
      iprot.readStructEnd();
4214
      validate();
4215
    }
4216
 
3430 rajveer 4217
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 4218
      oprot.writeStructBegin(STRUCT_DESC);
4219
 
4220
      if (this.isSetSuccess()) {
4221
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4222
        {
3430 rajveer 4223
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
2747 chandransh 4224
          for (Payment _iter15 : this.success)
123 ashish 4225
          {
2747 chandransh 4226
            _iter15.write(oprot);
123 ashish 4227
          }
4228
          oprot.writeListEnd();
4229
        }
4230
        oprot.writeFieldEnd();
4231
      } else if (this.isSetPe()) {
4232
        oprot.writeFieldBegin(PE_FIELD_DESC);
4233
        this.pe.write(oprot);
4234
        oprot.writeFieldEnd();
4235
      }
4236
      oprot.writeFieldStop();
4237
      oprot.writeStructEnd();
4238
    }
4239
 
4240
    @Override
4241
    public String toString() {
695 rajveer 4242
      StringBuilder sb = new StringBuilder("getPaymentsForUser_result(");
123 ashish 4243
      boolean first = true;
4244
 
4245
      sb.append("success:");
4246
      if (this.success == null) {
4247
        sb.append("null");
4248
      } else {
4249
        sb.append(this.success);
4250
      }
4251
      first = false;
4252
      if (!first) sb.append(", ");
4253
      sb.append("pe:");
4254
      if (this.pe == null) {
4255
        sb.append("null");
4256
      } else {
4257
        sb.append(this.pe);
4258
      }
4259
      first = false;
4260
      sb.append(")");
4261
      return sb.toString();
4262
    }
4263
 
3430 rajveer 4264
    public void validate() throws org.apache.thrift.TException {
123 ashish 4265
      // check for required fields
4266
    }
4267
 
3430 rajveer 4268
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4269
      try {
4270
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4271
      } catch (org.apache.thrift.TException te) {
4272
        throw new java.io.IOException(te);
4273
      }
4274
    }
4275
 
4276
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4277
      try {
4278
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4279
      } catch (org.apache.thrift.TException te) {
4280
        throw new java.io.IOException(te);
4281
      }
4282
    }
4283
 
123 ashish 4284
  }
4285
 
3430 rajveer 4286
  public static class getPayments_args implements org.apache.thrift.TBase<getPayments_args, getPayments_args._Fields>, java.io.Serializable, Cloneable   {
4287
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayments_args");
123 ashish 4288
 
3430 rajveer 4289
    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);
4290
    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);
4291
    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);
4292
    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 4293
 
3430 rajveer 4294
    private long fromTime; // required
4295
    private long toTime; // required
4296
    private PaymentStatus status; // required
4297
    private long gatewayId; // required
123 ashish 4298
 
4299
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4300
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 4301
      FROM_TIME((short)1, "fromTime"),
4302
      TO_TIME((short)2, "toTime"),
123 ashish 4303
      /**
4304
       * 
4305
       * @see PaymentStatus
4306
       */
4307
      STATUS((short)3, "status"),
695 rajveer 4308
      GATEWAY_ID((short)4, "gatewayId");
123 ashish 4309
 
4310
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4311
 
4312
      static {
4313
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4314
          byName.put(field.getFieldName(), field);
4315
        }
4316
      }
4317
 
4318
      /**
4319
       * Find the _Fields constant that matches fieldId, or null if its not found.
4320
       */
4321
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4322
        switch(fieldId) {
4323
          case 1: // FROM_TIME
4324
            return FROM_TIME;
4325
          case 2: // TO_TIME
4326
            return TO_TIME;
4327
          case 3: // STATUS
4328
            return STATUS;
4329
          case 4: // GATEWAY_ID
4330
            return GATEWAY_ID;
4331
          default:
4332
            return null;
4333
        }
123 ashish 4334
      }
4335
 
4336
      /**
4337
       * Find the _Fields constant that matches fieldId, throwing an exception
4338
       * if it is not found.
4339
       */
4340
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4341
        _Fields fields = findByThriftId(fieldId);
4342
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4343
        return fields;
4344
      }
4345
 
4346
      /**
4347
       * Find the _Fields constant that matches name, or null if its not found.
4348
       */
4349
      public static _Fields findByName(String name) {
4350
        return byName.get(name);
4351
      }
4352
 
4353
      private final short _thriftId;
4354
      private final String _fieldName;
4355
 
4356
      _Fields(short thriftId, String fieldName) {
4357
        _thriftId = thriftId;
4358
        _fieldName = fieldName;
4359
      }
4360
 
4361
      public short getThriftFieldId() {
4362
        return _thriftId;
4363
      }
4364
 
4365
      public String getFieldName() {
4366
        return _fieldName;
4367
      }
4368
    }
4369
 
4370
    // isset id assignments
695 rajveer 4371
    private static final int __FROMTIME_ISSET_ID = 0;
4372
    private static final int __TOTIME_ISSET_ID = 1;
4373
    private static final int __GATEWAYID_ISSET_ID = 2;
420 ashish 4374
    private BitSet __isset_bit_vector = new BitSet(3);
123 ashish 4375
 
3430 rajveer 4376
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 4377
    static {
3430 rajveer 4378
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4379
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4380
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4381
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4382
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4383
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4384
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
4385
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4386
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4387
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4388
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayments_args.class, metaDataMap);
123 ashish 4389
    }
4390
 
4391
    public getPayments_args() {
4392
    }
4393
 
4394
    public getPayments_args(
695 rajveer 4395
      long fromTime,
4396
      long toTime,
123 ashish 4397
      PaymentStatus status,
695 rajveer 4398
      long gatewayId)
123 ashish 4399
    {
4400
      this();
695 rajveer 4401
      this.fromTime = fromTime;
4402
      setFromTimeIsSet(true);
4403
      this.toTime = toTime;
4404
      setToTimeIsSet(true);
123 ashish 4405
      this.status = status;
695 rajveer 4406
      this.gatewayId = gatewayId;
4407
      setGatewayIdIsSet(true);
123 ashish 4408
    }
4409
 
4410
    /**
4411
     * Performs a deep copy on <i>other</i>.
4412
     */
4413
    public getPayments_args(getPayments_args other) {
4414
      __isset_bit_vector.clear();
4415
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 4416
      this.fromTime = other.fromTime;
4417
      this.toTime = other.toTime;
123 ashish 4418
      if (other.isSetStatus()) {
4419
        this.status = other.status;
4420
      }
695 rajveer 4421
      this.gatewayId = other.gatewayId;
123 ashish 4422
    }
4423
 
4424
    public getPayments_args deepCopy() {
4425
      return new getPayments_args(this);
4426
    }
4427
 
3430 rajveer 4428
    @Override
4429
    public void clear() {
4430
      setFromTimeIsSet(false);
4431
      this.fromTime = 0;
4432
      setToTimeIsSet(false);
4433
      this.toTime = 0;
4434
      this.status = null;
4435
      setGatewayIdIsSet(false);
4436
      this.gatewayId = 0;
123 ashish 4437
    }
4438
 
695 rajveer 4439
    public long getFromTime() {
4440
      return this.fromTime;
123 ashish 4441
    }
4442
 
3430 rajveer 4443
    public void setFromTime(long fromTime) {
695 rajveer 4444
      this.fromTime = fromTime;
4445
      setFromTimeIsSet(true);
123 ashish 4446
    }
4447
 
695 rajveer 4448
    public void unsetFromTime() {
4449
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
123 ashish 4450
    }
4451
 
3430 rajveer 4452
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
695 rajveer 4453
    public boolean isSetFromTime() {
4454
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
123 ashish 4455
    }
4456
 
695 rajveer 4457
    public void setFromTimeIsSet(boolean value) {
4458
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
123 ashish 4459
    }
4460
 
695 rajveer 4461
    public long getToTime() {
4462
      return this.toTime;
123 ashish 4463
    }
4464
 
3430 rajveer 4465
    public void setToTime(long toTime) {
695 rajveer 4466
      this.toTime = toTime;
4467
      setToTimeIsSet(true);
123 ashish 4468
    }
4469
 
695 rajveer 4470
    public void unsetToTime() {
4471
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
123 ashish 4472
    }
4473
 
3430 rajveer 4474
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
695 rajveer 4475
    public boolean isSetToTime() {
4476
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
123 ashish 4477
    }
4478
 
695 rajveer 4479
    public void setToTimeIsSet(boolean value) {
4480
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
123 ashish 4481
    }
4482
 
4483
    /**
4484
     * 
4485
     * @see PaymentStatus
4486
     */
4487
    public PaymentStatus getStatus() {
4488
      return this.status;
4489
    }
4490
 
4491
    /**
4492
     * 
4493
     * @see PaymentStatus
4494
     */
3430 rajveer 4495
    public void setStatus(PaymentStatus status) {
123 ashish 4496
      this.status = status;
4497
    }
4498
 
4499
    public void unsetStatus() {
4500
      this.status = null;
4501
    }
4502
 
3430 rajveer 4503
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
123 ashish 4504
    public boolean isSetStatus() {
4505
      return this.status != null;
4506
    }
4507
 
4508
    public void setStatusIsSet(boolean value) {
4509
      if (!value) {
4510
        this.status = null;
4511
      }
4512
    }
4513
 
695 rajveer 4514
    public long getGatewayId() {
4515
      return this.gatewayId;
123 ashish 4516
    }
4517
 
3430 rajveer 4518
    public void setGatewayId(long gatewayId) {
695 rajveer 4519
      this.gatewayId = gatewayId;
4520
      setGatewayIdIsSet(true);
123 ashish 4521
    }
4522
 
695 rajveer 4523
    public void unsetGatewayId() {
4524
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 4525
    }
4526
 
3430 rajveer 4527
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 4528
    public boolean isSetGatewayId() {
4529
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 4530
    }
4531
 
695 rajveer 4532
    public void setGatewayIdIsSet(boolean value) {
4533
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 4534
    }
4535
 
4536
    public void setFieldValue(_Fields field, Object value) {
4537
      switch (field) {
4538
      case FROM_TIME:
4539
        if (value == null) {
695 rajveer 4540
          unsetFromTime();
123 ashish 4541
        } else {
695 rajveer 4542
          setFromTime((Long)value);
123 ashish 4543
        }
4544
        break;
4545
 
4546
      case TO_TIME:
4547
        if (value == null) {
695 rajveer 4548
          unsetToTime();
123 ashish 4549
        } else {
695 rajveer 4550
          setToTime((Long)value);
123 ashish 4551
        }
4552
        break;
4553
 
4554
      case STATUS:
4555
        if (value == null) {
4556
          unsetStatus();
4557
        } else {
4558
          setStatus((PaymentStatus)value);
4559
        }
4560
        break;
4561
 
420 ashish 4562
      case GATEWAY_ID:
123 ashish 4563
        if (value == null) {
695 rajveer 4564
          unsetGatewayId();
123 ashish 4565
        } else {
695 rajveer 4566
          setGatewayId((Long)value);
123 ashish 4567
        }
4568
        break;
4569
 
4570
      }
4571
    }
4572
 
4573
    public Object getFieldValue(_Fields field) {
4574
      switch (field) {
4575
      case FROM_TIME:
3430 rajveer 4576
        return Long.valueOf(getFromTime());
123 ashish 4577
 
4578
      case TO_TIME:
3430 rajveer 4579
        return Long.valueOf(getToTime());
123 ashish 4580
 
4581
      case STATUS:
4582
        return getStatus();
4583
 
420 ashish 4584
      case GATEWAY_ID:
3430 rajveer 4585
        return Long.valueOf(getGatewayId());
123 ashish 4586
 
4587
      }
4588
      throw new IllegalStateException();
4589
    }
4590
 
3430 rajveer 4591
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4592
    public boolean isSet(_Fields field) {
4593
      if (field == null) {
4594
        throw new IllegalArgumentException();
4595
      }
123 ashish 4596
 
4597
      switch (field) {
4598
      case FROM_TIME:
695 rajveer 4599
        return isSetFromTime();
123 ashish 4600
      case TO_TIME:
695 rajveer 4601
        return isSetToTime();
123 ashish 4602
      case STATUS:
4603
        return isSetStatus();
420 ashish 4604
      case GATEWAY_ID:
695 rajveer 4605
        return isSetGatewayId();
123 ashish 4606
      }
4607
      throw new IllegalStateException();
4608
    }
4609
 
4610
    @Override
4611
    public boolean equals(Object that) {
4612
      if (that == null)
4613
        return false;
4614
      if (that instanceof getPayments_args)
4615
        return this.equals((getPayments_args)that);
4616
      return false;
4617
    }
4618
 
4619
    public boolean equals(getPayments_args that) {
4620
      if (that == null)
4621
        return false;
4622
 
695 rajveer 4623
      boolean this_present_fromTime = true;
4624
      boolean that_present_fromTime = true;
4625
      if (this_present_fromTime || that_present_fromTime) {
4626
        if (!(this_present_fromTime && that_present_fromTime))
123 ashish 4627
          return false;
695 rajveer 4628
        if (this.fromTime != that.fromTime)
123 ashish 4629
          return false;
4630
      }
4631
 
695 rajveer 4632
      boolean this_present_toTime = true;
4633
      boolean that_present_toTime = true;
4634
      if (this_present_toTime || that_present_toTime) {
4635
        if (!(this_present_toTime && that_present_toTime))
123 ashish 4636
          return false;
695 rajveer 4637
        if (this.toTime != that.toTime)
123 ashish 4638
          return false;
4639
      }
4640
 
4641
      boolean this_present_status = true && this.isSetStatus();
4642
      boolean that_present_status = true && that.isSetStatus();
4643
      if (this_present_status || that_present_status) {
4644
        if (!(this_present_status && that_present_status))
4645
          return false;
4646
        if (!this.status.equals(that.status))
4647
          return false;
4648
      }
4649
 
695 rajveer 4650
      boolean this_present_gatewayId = true;
4651
      boolean that_present_gatewayId = true;
4652
      if (this_present_gatewayId || that_present_gatewayId) {
4653
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 4654
          return false;
695 rajveer 4655
        if (this.gatewayId != that.gatewayId)
123 ashish 4656
          return false;
4657
      }
4658
 
4659
      return true;
4660
    }
4661
 
4662
    @Override
4663
    public int hashCode() {
4664
      return 0;
4665
    }
4666
 
4667
    public int compareTo(getPayments_args other) {
4668
      if (!getClass().equals(other.getClass())) {
4669
        return getClass().getName().compareTo(other.getClass().getName());
4670
      }
4671
 
4672
      int lastComparison = 0;
4673
      getPayments_args typedOther = (getPayments_args)other;
4674
 
3430 rajveer 4675
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
123 ashish 4676
      if (lastComparison != 0) {
4677
        return lastComparison;
4678
      }
3430 rajveer 4679
      if (isSetFromTime()) {
4680
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
4681
        if (lastComparison != 0) {
4682
          return lastComparison;
4683
        }
123 ashish 4684
      }
3430 rajveer 4685
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
123 ashish 4686
      if (lastComparison != 0) {
4687
        return lastComparison;
4688
      }
3430 rajveer 4689
      if (isSetToTime()) {
4690
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
4691
        if (lastComparison != 0) {
4692
          return lastComparison;
4693
        }
123 ashish 4694
      }
3430 rajveer 4695
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
123 ashish 4696
      if (lastComparison != 0) {
4697
        return lastComparison;
4698
      }
3430 rajveer 4699
      if (isSetStatus()) {
4700
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
4701
        if (lastComparison != 0) {
4702
          return lastComparison;
4703
        }
123 ashish 4704
      }
3430 rajveer 4705
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 4706
      if (lastComparison != 0) {
4707
        return lastComparison;
4708
      }
3430 rajveer 4709
      if (isSetGatewayId()) {
4710
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
4711
        if (lastComparison != 0) {
4712
          return lastComparison;
4713
        }
123 ashish 4714
      }
4715
      return 0;
4716
    }
4717
 
3430 rajveer 4718
    public _Fields fieldForId(int fieldId) {
4719
      return _Fields.findByThriftId(fieldId);
4720
    }
4721
 
4722
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4723
      org.apache.thrift.protocol.TField field;
123 ashish 4724
      iprot.readStructBegin();
4725
      while (true)
4726
      {
4727
        field = iprot.readFieldBegin();
3430 rajveer 4728
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 4729
          break;
4730
        }
3430 rajveer 4731
        switch (field.id) {
4732
          case 1: // FROM_TIME
4733
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4734
              this.fromTime = iprot.readI64();
4735
              setFromTimeIsSet(true);
4736
            } else { 
4737
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4738
            }
4739
            break;
4740
          case 2: // TO_TIME
4741
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4742
              this.toTime = iprot.readI64();
4743
              setToTimeIsSet(true);
4744
            } else { 
4745
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4746
            }
4747
            break;
4748
          case 3: // STATUS
4749
            if (field.type == org.apache.thrift.protocol.TType.I32) {
4750
              this.status = PaymentStatus.findByValue(iprot.readI32());
4751
            } else { 
4752
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4753
            }
4754
            break;
4755
          case 4: // GATEWAY_ID
4756
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4757
              this.gatewayId = iprot.readI64();
4758
              setGatewayIdIsSet(true);
4759
            } else { 
4760
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4761
            }
4762
            break;
4763
          default:
4764
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 4765
        }
3430 rajveer 4766
        iprot.readFieldEnd();
123 ashish 4767
      }
4768
      iprot.readStructEnd();
4769
      validate();
4770
    }
4771
 
3430 rajveer 4772
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 4773
      validate();
4774
 
4775
      oprot.writeStructBegin(STRUCT_DESC);
4776
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
695 rajveer 4777
      oprot.writeI64(this.fromTime);
123 ashish 4778
      oprot.writeFieldEnd();
4779
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
695 rajveer 4780
      oprot.writeI64(this.toTime);
123 ashish 4781
      oprot.writeFieldEnd();
4782
      if (this.status != null) {
4783
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
4784
        oprot.writeI32(this.status.getValue());
4785
        oprot.writeFieldEnd();
4786
      }
420 ashish 4787
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 4788
      oprot.writeI64(this.gatewayId);
420 ashish 4789
      oprot.writeFieldEnd();
123 ashish 4790
      oprot.writeFieldStop();
4791
      oprot.writeStructEnd();
4792
    }
4793
 
4794
    @Override
4795
    public String toString() {
4796
      StringBuilder sb = new StringBuilder("getPayments_args(");
4797
      boolean first = true;
4798
 
695 rajveer 4799
      sb.append("fromTime:");
4800
      sb.append(this.fromTime);
123 ashish 4801
      first = false;
4802
      if (!first) sb.append(", ");
695 rajveer 4803
      sb.append("toTime:");
4804
      sb.append(this.toTime);
123 ashish 4805
      first = false;
4806
      if (!first) sb.append(", ");
4807
      sb.append("status:");
4808
      if (this.status == null) {
4809
        sb.append("null");
4810
      } else {
4811
        sb.append(this.status);
4812
      }
4813
      first = false;
4814
      if (!first) sb.append(", ");
695 rajveer 4815
      sb.append("gatewayId:");
4816
      sb.append(this.gatewayId);
123 ashish 4817
      first = false;
4818
      sb.append(")");
4819
      return sb.toString();
4820
    }
4821
 
3430 rajveer 4822
    public void validate() throws org.apache.thrift.TException {
123 ashish 4823
      // check for required fields
4824
    }
4825
 
3430 rajveer 4826
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4827
      try {
4828
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4829
      } catch (org.apache.thrift.TException te) {
4830
        throw new java.io.IOException(te);
4831
      }
4832
    }
4833
 
4834
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4835
      try {
4836
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4837
      } catch (org.apache.thrift.TException te) {
4838
        throw new java.io.IOException(te);
4839
      }
4840
    }
4841
 
123 ashish 4842
  }
4843
 
3430 rajveer 4844
  public static class getPayments_result implements org.apache.thrift.TBase<getPayments_result, getPayments_result._Fields>, java.io.Serializable, Cloneable   {
4845
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayments_result");
123 ashish 4846
 
3430 rajveer 4847
    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);
4848
    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 4849
 
3430 rajveer 4850
    private List<Payment> success; // required
4851
    private PaymentException pe; // required
123 ashish 4852
 
4853
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4854
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 4855
      SUCCESS((short)0, "success"),
4856
      PE((short)1, "pe");
4857
 
4858
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4859
 
4860
      static {
4861
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4862
          byName.put(field.getFieldName(), field);
4863
        }
4864
      }
4865
 
4866
      /**
4867
       * Find the _Fields constant that matches fieldId, or null if its not found.
4868
       */
4869
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4870
        switch(fieldId) {
4871
          case 0: // SUCCESS
4872
            return SUCCESS;
4873
          case 1: // PE
4874
            return PE;
4875
          default:
4876
            return null;
4877
        }
123 ashish 4878
      }
4879
 
4880
      /**
4881
       * Find the _Fields constant that matches fieldId, throwing an exception
4882
       * if it is not found.
4883
       */
4884
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4885
        _Fields fields = findByThriftId(fieldId);
4886
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4887
        return fields;
4888
      }
4889
 
4890
      /**
4891
       * Find the _Fields constant that matches name, or null if its not found.
4892
       */
4893
      public static _Fields findByName(String name) {
4894
        return byName.get(name);
4895
      }
4896
 
4897
      private final short _thriftId;
4898
      private final String _fieldName;
4899
 
4900
      _Fields(short thriftId, String fieldName) {
4901
        _thriftId = thriftId;
4902
        _fieldName = fieldName;
4903
      }
4904
 
4905
      public short getThriftFieldId() {
4906
        return _thriftId;
4907
      }
4908
 
4909
      public String getFieldName() {
4910
        return _fieldName;
4911
      }
4912
    }
4913
 
4914
    // isset id assignments
4915
 
3430 rajveer 4916
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 4917
    static {
3430 rajveer 4918
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4919
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4920
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
4921
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
4922
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4923
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4924
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4925
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayments_result.class, metaDataMap);
123 ashish 4926
    }
4927
 
4928
    public getPayments_result() {
4929
    }
4930
 
4931
    public getPayments_result(
4932
      List<Payment> success,
4933
      PaymentException pe)
4934
    {
4935
      this();
4936
      this.success = success;
4937
      this.pe = pe;
4938
    }
4939
 
4940
    /**
4941
     * Performs a deep copy on <i>other</i>.
4942
     */
4943
    public getPayments_result(getPayments_result other) {
4944
      if (other.isSetSuccess()) {
4945
        List<Payment> __this__success = new ArrayList<Payment>();
4946
        for (Payment other_element : other.success) {
4947
          __this__success.add(new Payment(other_element));
4948
        }
4949
        this.success = __this__success;
4950
      }
4951
      if (other.isSetPe()) {
4952
        this.pe = new PaymentException(other.pe);
4953
      }
4954
    }
4955
 
4956
    public getPayments_result deepCopy() {
4957
      return new getPayments_result(this);
4958
    }
4959
 
3430 rajveer 4960
    @Override
4961
    public void clear() {
4962
      this.success = null;
4963
      this.pe = null;
123 ashish 4964
    }
4965
 
4966
    public int getSuccessSize() {
4967
      return (this.success == null) ? 0 : this.success.size();
4968
    }
4969
 
4970
    public java.util.Iterator<Payment> getSuccessIterator() {
4971
      return (this.success == null) ? null : this.success.iterator();
4972
    }
4973
 
4974
    public void addToSuccess(Payment elem) {
4975
      if (this.success == null) {
4976
        this.success = new ArrayList<Payment>();
4977
      }
4978
      this.success.add(elem);
4979
    }
4980
 
4981
    public List<Payment> getSuccess() {
4982
      return this.success;
4983
    }
4984
 
3430 rajveer 4985
    public void setSuccess(List<Payment> success) {
123 ashish 4986
      this.success = success;
4987
    }
4988
 
4989
    public void unsetSuccess() {
4990
      this.success = null;
4991
    }
4992
 
3430 rajveer 4993
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 4994
    public boolean isSetSuccess() {
4995
      return this.success != null;
4996
    }
4997
 
4998
    public void setSuccessIsSet(boolean value) {
4999
      if (!value) {
5000
        this.success = null;
5001
      }
5002
    }
5003
 
5004
    public PaymentException getPe() {
5005
      return this.pe;
5006
    }
5007
 
3430 rajveer 5008
    public void setPe(PaymentException pe) {
123 ashish 5009
      this.pe = pe;
5010
    }
5011
 
5012
    public void unsetPe() {
5013
      this.pe = null;
5014
    }
5015
 
3430 rajveer 5016
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 5017
    public boolean isSetPe() {
5018
      return this.pe != null;
5019
    }
5020
 
5021
    public void setPeIsSet(boolean value) {
5022
      if (!value) {
5023
        this.pe = null;
5024
      }
5025
    }
5026
 
5027
    public void setFieldValue(_Fields field, Object value) {
5028
      switch (field) {
5029
      case SUCCESS:
5030
        if (value == null) {
5031
          unsetSuccess();
5032
        } else {
5033
          setSuccess((List<Payment>)value);
5034
        }
5035
        break;
5036
 
5037
      case PE:
5038
        if (value == null) {
5039
          unsetPe();
5040
        } else {
5041
          setPe((PaymentException)value);
5042
        }
5043
        break;
5044
 
5045
      }
5046
    }
5047
 
5048
    public Object getFieldValue(_Fields field) {
5049
      switch (field) {
5050
      case SUCCESS:
5051
        return getSuccess();
5052
 
5053
      case PE:
5054
        return getPe();
5055
 
5056
      }
5057
      throw new IllegalStateException();
5058
    }
5059
 
3430 rajveer 5060
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5061
    public boolean isSet(_Fields field) {
5062
      if (field == null) {
5063
        throw new IllegalArgumentException();
5064
      }
123 ashish 5065
 
5066
      switch (field) {
5067
      case SUCCESS:
5068
        return isSetSuccess();
5069
      case PE:
5070
        return isSetPe();
5071
      }
5072
      throw new IllegalStateException();
5073
    }
5074
 
5075
    @Override
5076
    public boolean equals(Object that) {
5077
      if (that == null)
5078
        return false;
5079
      if (that instanceof getPayments_result)
5080
        return this.equals((getPayments_result)that);
5081
      return false;
5082
    }
5083
 
5084
    public boolean equals(getPayments_result that) {
5085
      if (that == null)
5086
        return false;
5087
 
5088
      boolean this_present_success = true && this.isSetSuccess();
5089
      boolean that_present_success = true && that.isSetSuccess();
5090
      if (this_present_success || that_present_success) {
5091
        if (!(this_present_success && that_present_success))
5092
          return false;
5093
        if (!this.success.equals(that.success))
5094
          return false;
5095
      }
5096
 
5097
      boolean this_present_pe = true && this.isSetPe();
5098
      boolean that_present_pe = true && that.isSetPe();
5099
      if (this_present_pe || that_present_pe) {
5100
        if (!(this_present_pe && that_present_pe))
5101
          return false;
5102
        if (!this.pe.equals(that.pe))
5103
          return false;
5104
      }
5105
 
5106
      return true;
5107
    }
5108
 
5109
    @Override
5110
    public int hashCode() {
5111
      return 0;
5112
    }
5113
 
695 rajveer 5114
    public int compareTo(getPayments_result other) {
123 ashish 5115
      if (!getClass().equals(other.getClass())) {
5116
        return getClass().getName().compareTo(other.getClass().getName());
5117
      }
5118
 
5119
      int lastComparison = 0;
695 rajveer 5120
      getPayments_result typedOther = (getPayments_result)other;
123 ashish 5121
 
3430 rajveer 5122
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
123 ashish 5123
      if (lastComparison != 0) {
5124
        return lastComparison;
5125
      }
3430 rajveer 5126
      if (isSetSuccess()) {
5127
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
5128
        if (lastComparison != 0) {
5129
          return lastComparison;
5130
        }
123 ashish 5131
      }
3430 rajveer 5132
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 5133
      if (lastComparison != 0) {
5134
        return lastComparison;
123 ashish 5135
      }
3430 rajveer 5136
      if (isSetPe()) {
5137
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
5138
        if (lastComparison != 0) {
5139
          return lastComparison;
5140
        }
123 ashish 5141
      }
5142
      return 0;
5143
    }
5144
 
3430 rajveer 5145
    public _Fields fieldForId(int fieldId) {
5146
      return _Fields.findByThriftId(fieldId);
5147
    }
5148
 
5149
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5150
      org.apache.thrift.protocol.TField field;
123 ashish 5151
      iprot.readStructBegin();
5152
      while (true)
5153
      {
5154
        field = iprot.readFieldBegin();
3430 rajveer 5155
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 5156
          break;
5157
        }
3430 rajveer 5158
        switch (field.id) {
5159
          case 0: // SUCCESS
5160
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
5161
              {
5162
                org.apache.thrift.protocol.TList _list16 = iprot.readListBegin();
5163
                this.success = new ArrayList<Payment>(_list16.size);
5164
                for (int _i17 = 0; _i17 < _list16.size; ++_i17)
420 ashish 5165
                {
3430 rajveer 5166
                  Payment _elem18; // required
5167
                  _elem18 = new Payment();
5168
                  _elem18.read(iprot);
5169
                  this.success.add(_elem18);
420 ashish 5170
                }
3430 rajveer 5171
                iprot.readListEnd();
123 ashish 5172
              }
3430 rajveer 5173
            } else { 
5174
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5175
            }
5176
            break;
5177
          case 1: // PE
5178
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5179
              this.pe = new PaymentException();
5180
              this.pe.read(iprot);
5181
            } else { 
5182
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5183
            }
5184
            break;
5185
          default:
5186
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 5187
        }
3430 rajveer 5188
        iprot.readFieldEnd();
123 ashish 5189
      }
5190
      iprot.readStructEnd();
5191
      validate();
5192
    }
5193
 
3430 rajveer 5194
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 5195
      oprot.writeStructBegin(STRUCT_DESC);
5196
 
5197
      if (this.isSetSuccess()) {
5198
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
420 ashish 5199
        {
3430 rajveer 5200
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
2747 chandransh 5201
          for (Payment _iter19 : this.success)
420 ashish 5202
          {
2747 chandransh 5203
            _iter19.write(oprot);
420 ashish 5204
          }
5205
          oprot.writeListEnd();
5206
        }
123 ashish 5207
        oprot.writeFieldEnd();
5208
      } else if (this.isSetPe()) {
5209
        oprot.writeFieldBegin(PE_FIELD_DESC);
5210
        this.pe.write(oprot);
5211
        oprot.writeFieldEnd();
5212
      }
5213
      oprot.writeFieldStop();
5214
      oprot.writeStructEnd();
5215
    }
5216
 
5217
    @Override
5218
    public String toString() {
695 rajveer 5219
      StringBuilder sb = new StringBuilder("getPayments_result(");
123 ashish 5220
      boolean first = true;
5221
 
5222
      sb.append("success:");
5223
      if (this.success == null) {
5224
        sb.append("null");
5225
      } else {
5226
        sb.append(this.success);
5227
      }
5228
      first = false;
5229
      if (!first) sb.append(", ");
5230
      sb.append("pe:");
5231
      if (this.pe == null) {
5232
        sb.append("null");
5233
      } else {
5234
        sb.append(this.pe);
5235
      }
5236
      first = false;
5237
      sb.append(")");
5238
      return sb.toString();
5239
    }
5240
 
3430 rajveer 5241
    public void validate() throws org.apache.thrift.TException {
123 ashish 5242
      // check for required fields
5243
    }
5244
 
3430 rajveer 5245
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5246
      try {
5247
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5248
      } catch (org.apache.thrift.TException te) {
5249
        throw new java.io.IOException(te);
5250
      }
5251
    }
5252
 
5253
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5254
      try {
5255
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5256
      } catch (org.apache.thrift.TException te) {
5257
        throw new java.io.IOException(te);
5258
      }
5259
    }
5260
 
123 ashish 5261
  }
5262
 
4141 chandransh 5263
  public static class getPaymentsByCapturedDate_args implements org.apache.thrift.TBase<getPaymentsByCapturedDate_args, getPaymentsByCapturedDate_args._Fields>, java.io.Serializable, Cloneable   {
5264
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsByCapturedDate_args");
5265
 
5266
    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);
5267
    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);
5268
    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);
5269
 
5270
    private long fromTime; // required
5271
    private long toTime; // required
5272
    private long gatewayId; // required
5273
 
5274
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5275
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5276
      FROM_TIME((short)1, "fromTime"),
5277
      TO_TIME((short)2, "toTime"),
5278
      GATEWAY_ID((short)3, "gatewayId");
5279
 
5280
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5281
 
5282
      static {
5283
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5284
          byName.put(field.getFieldName(), field);
5285
        }
5286
      }
5287
 
5288
      /**
5289
       * Find the _Fields constant that matches fieldId, or null if its not found.
5290
       */
5291
      public static _Fields findByThriftId(int fieldId) {
5292
        switch(fieldId) {
5293
          case 1: // FROM_TIME
5294
            return FROM_TIME;
5295
          case 2: // TO_TIME
5296
            return TO_TIME;
5297
          case 3: // GATEWAY_ID
5298
            return GATEWAY_ID;
5299
          default:
5300
            return null;
5301
        }
5302
      }
5303
 
5304
      /**
5305
       * Find the _Fields constant that matches fieldId, throwing an exception
5306
       * if it is not found.
5307
       */
5308
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5309
        _Fields fields = findByThriftId(fieldId);
5310
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5311
        return fields;
5312
      }
5313
 
5314
      /**
5315
       * Find the _Fields constant that matches name, or null if its not found.
5316
       */
5317
      public static _Fields findByName(String name) {
5318
        return byName.get(name);
5319
      }
5320
 
5321
      private final short _thriftId;
5322
      private final String _fieldName;
5323
 
5324
      _Fields(short thriftId, String fieldName) {
5325
        _thriftId = thriftId;
5326
        _fieldName = fieldName;
5327
      }
5328
 
5329
      public short getThriftFieldId() {
5330
        return _thriftId;
5331
      }
5332
 
5333
      public String getFieldName() {
5334
        return _fieldName;
5335
      }
5336
    }
5337
 
5338
    // isset id assignments
5339
    private static final int __FROMTIME_ISSET_ID = 0;
5340
    private static final int __TOTIME_ISSET_ID = 1;
5341
    private static final int __GATEWAYID_ISSET_ID = 2;
5342
    private BitSet __isset_bit_vector = new BitSet(3);
5343
 
5344
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5345
    static {
5346
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5347
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5348
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5349
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5350
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5351
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5352
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5353
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5354
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsByCapturedDate_args.class, metaDataMap);
5355
    }
5356
 
5357
    public getPaymentsByCapturedDate_args() {
5358
    }
5359
 
5360
    public getPaymentsByCapturedDate_args(
5361
      long fromTime,
5362
      long toTime,
5363
      long gatewayId)
5364
    {
5365
      this();
5366
      this.fromTime = fromTime;
5367
      setFromTimeIsSet(true);
5368
      this.toTime = toTime;
5369
      setToTimeIsSet(true);
5370
      this.gatewayId = gatewayId;
5371
      setGatewayIdIsSet(true);
5372
    }
5373
 
5374
    /**
5375
     * Performs a deep copy on <i>other</i>.
5376
     */
5377
    public getPaymentsByCapturedDate_args(getPaymentsByCapturedDate_args other) {
5378
      __isset_bit_vector.clear();
5379
      __isset_bit_vector.or(other.__isset_bit_vector);
5380
      this.fromTime = other.fromTime;
5381
      this.toTime = other.toTime;
5382
      this.gatewayId = other.gatewayId;
5383
    }
5384
 
5385
    public getPaymentsByCapturedDate_args deepCopy() {
5386
      return new getPaymentsByCapturedDate_args(this);
5387
    }
5388
 
5389
    @Override
5390
    public void clear() {
5391
      setFromTimeIsSet(false);
5392
      this.fromTime = 0;
5393
      setToTimeIsSet(false);
5394
      this.toTime = 0;
5395
      setGatewayIdIsSet(false);
5396
      this.gatewayId = 0;
5397
    }
5398
 
5399
    public long getFromTime() {
5400
      return this.fromTime;
5401
    }
5402
 
5403
    public void setFromTime(long fromTime) {
5404
      this.fromTime = fromTime;
5405
      setFromTimeIsSet(true);
5406
    }
5407
 
5408
    public void unsetFromTime() {
5409
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
5410
    }
5411
 
5412
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
5413
    public boolean isSetFromTime() {
5414
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
5415
    }
5416
 
5417
    public void setFromTimeIsSet(boolean value) {
5418
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
5419
    }
5420
 
5421
    public long getToTime() {
5422
      return this.toTime;
5423
    }
5424
 
5425
    public void setToTime(long toTime) {
5426
      this.toTime = toTime;
5427
      setToTimeIsSet(true);
5428
    }
5429
 
5430
    public void unsetToTime() {
5431
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
5432
    }
5433
 
5434
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
5435
    public boolean isSetToTime() {
5436
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
5437
    }
5438
 
5439
    public void setToTimeIsSet(boolean value) {
5440
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
5441
    }
5442
 
5443
    public long getGatewayId() {
5444
      return this.gatewayId;
5445
    }
5446
 
5447
    public void setGatewayId(long gatewayId) {
5448
      this.gatewayId = gatewayId;
5449
      setGatewayIdIsSet(true);
5450
    }
5451
 
5452
    public void unsetGatewayId() {
5453
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
5454
    }
5455
 
5456
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
5457
    public boolean isSetGatewayId() {
5458
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
5459
    }
5460
 
5461
    public void setGatewayIdIsSet(boolean value) {
5462
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
5463
    }
5464
 
5465
    public void setFieldValue(_Fields field, Object value) {
5466
      switch (field) {
5467
      case FROM_TIME:
5468
        if (value == null) {
5469
          unsetFromTime();
5470
        } else {
5471
          setFromTime((Long)value);
5472
        }
5473
        break;
5474
 
5475
      case TO_TIME:
5476
        if (value == null) {
5477
          unsetToTime();
5478
        } else {
5479
          setToTime((Long)value);
5480
        }
5481
        break;
5482
 
5483
      case GATEWAY_ID:
5484
        if (value == null) {
5485
          unsetGatewayId();
5486
        } else {
5487
          setGatewayId((Long)value);
5488
        }
5489
        break;
5490
 
5491
      }
5492
    }
5493
 
5494
    public Object getFieldValue(_Fields field) {
5495
      switch (field) {
5496
      case FROM_TIME:
5497
        return Long.valueOf(getFromTime());
5498
 
5499
      case TO_TIME:
5500
        return Long.valueOf(getToTime());
5501
 
5502
      case GATEWAY_ID:
5503
        return Long.valueOf(getGatewayId());
5504
 
5505
      }
5506
      throw new IllegalStateException();
5507
    }
5508
 
5509
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5510
    public boolean isSet(_Fields field) {
5511
      if (field == null) {
5512
        throw new IllegalArgumentException();
5513
      }
5514
 
5515
      switch (field) {
5516
      case FROM_TIME:
5517
        return isSetFromTime();
5518
      case TO_TIME:
5519
        return isSetToTime();
5520
      case GATEWAY_ID:
5521
        return isSetGatewayId();
5522
      }
5523
      throw new IllegalStateException();
5524
    }
5525
 
5526
    @Override
5527
    public boolean equals(Object that) {
5528
      if (that == null)
5529
        return false;
5530
      if (that instanceof getPaymentsByCapturedDate_args)
5531
        return this.equals((getPaymentsByCapturedDate_args)that);
5532
      return false;
5533
    }
5534
 
5535
    public boolean equals(getPaymentsByCapturedDate_args that) {
5536
      if (that == null)
5537
        return false;
5538
 
5539
      boolean this_present_fromTime = true;
5540
      boolean that_present_fromTime = true;
5541
      if (this_present_fromTime || that_present_fromTime) {
5542
        if (!(this_present_fromTime && that_present_fromTime))
5543
          return false;
5544
        if (this.fromTime != that.fromTime)
5545
          return false;
5546
      }
5547
 
5548
      boolean this_present_toTime = true;
5549
      boolean that_present_toTime = true;
5550
      if (this_present_toTime || that_present_toTime) {
5551
        if (!(this_present_toTime && that_present_toTime))
5552
          return false;
5553
        if (this.toTime != that.toTime)
5554
          return false;
5555
      }
5556
 
5557
      boolean this_present_gatewayId = true;
5558
      boolean that_present_gatewayId = true;
5559
      if (this_present_gatewayId || that_present_gatewayId) {
5560
        if (!(this_present_gatewayId && that_present_gatewayId))
5561
          return false;
5562
        if (this.gatewayId != that.gatewayId)
5563
          return false;
5564
      }
5565
 
5566
      return true;
5567
    }
5568
 
5569
    @Override
5570
    public int hashCode() {
5571
      return 0;
5572
    }
5573
 
5574
    public int compareTo(getPaymentsByCapturedDate_args other) {
5575
      if (!getClass().equals(other.getClass())) {
5576
        return getClass().getName().compareTo(other.getClass().getName());
5577
      }
5578
 
5579
      int lastComparison = 0;
5580
      getPaymentsByCapturedDate_args typedOther = (getPaymentsByCapturedDate_args)other;
5581
 
5582
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
5583
      if (lastComparison != 0) {
5584
        return lastComparison;
5585
      }
5586
      if (isSetFromTime()) {
5587
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
5588
        if (lastComparison != 0) {
5589
          return lastComparison;
5590
        }
5591
      }
5592
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
5593
      if (lastComparison != 0) {
5594
        return lastComparison;
5595
      }
5596
      if (isSetToTime()) {
5597
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
5598
        if (lastComparison != 0) {
5599
          return lastComparison;
5600
        }
5601
      }
5602
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
5603
      if (lastComparison != 0) {
5604
        return lastComparison;
5605
      }
5606
      if (isSetGatewayId()) {
5607
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
5608
        if (lastComparison != 0) {
5609
          return lastComparison;
5610
        }
5611
      }
5612
      return 0;
5613
    }
5614
 
5615
    public _Fields fieldForId(int fieldId) {
5616
      return _Fields.findByThriftId(fieldId);
5617
    }
5618
 
5619
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5620
      org.apache.thrift.protocol.TField field;
5621
      iprot.readStructBegin();
5622
      while (true)
5623
      {
5624
        field = iprot.readFieldBegin();
5625
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5626
          break;
5627
        }
5628
        switch (field.id) {
5629
          case 1: // FROM_TIME
5630
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5631
              this.fromTime = iprot.readI64();
5632
              setFromTimeIsSet(true);
5633
            } else { 
5634
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5635
            }
5636
            break;
5637
          case 2: // TO_TIME
5638
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5639
              this.toTime = iprot.readI64();
5640
              setToTimeIsSet(true);
5641
            } else { 
5642
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5643
            }
5644
            break;
5645
          case 3: // GATEWAY_ID
5646
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5647
              this.gatewayId = iprot.readI64();
5648
              setGatewayIdIsSet(true);
5649
            } else { 
5650
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5651
            }
5652
            break;
5653
          default:
5654
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5655
        }
5656
        iprot.readFieldEnd();
5657
      }
5658
      iprot.readStructEnd();
5659
      validate();
5660
    }
5661
 
5662
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5663
      validate();
5664
 
5665
      oprot.writeStructBegin(STRUCT_DESC);
5666
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
5667
      oprot.writeI64(this.fromTime);
5668
      oprot.writeFieldEnd();
5669
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
5670
      oprot.writeI64(this.toTime);
5671
      oprot.writeFieldEnd();
5672
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
5673
      oprot.writeI64(this.gatewayId);
5674
      oprot.writeFieldEnd();
5675
      oprot.writeFieldStop();
5676
      oprot.writeStructEnd();
5677
    }
5678
 
5679
    @Override
5680
    public String toString() {
5681
      StringBuilder sb = new StringBuilder("getPaymentsByCapturedDate_args(");
5682
      boolean first = true;
5683
 
5684
      sb.append("fromTime:");
5685
      sb.append(this.fromTime);
5686
      first = false;
5687
      if (!first) sb.append(", ");
5688
      sb.append("toTime:");
5689
      sb.append(this.toTime);
5690
      first = false;
5691
      if (!first) sb.append(", ");
5692
      sb.append("gatewayId:");
5693
      sb.append(this.gatewayId);
5694
      first = false;
5695
      sb.append(")");
5696
      return sb.toString();
5697
    }
5698
 
5699
    public void validate() throws org.apache.thrift.TException {
5700
      // check for required fields
5701
    }
5702
 
5703
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5704
      try {
5705
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5706
      } catch (org.apache.thrift.TException te) {
5707
        throw new java.io.IOException(te);
5708
      }
5709
    }
5710
 
5711
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5712
      try {
5713
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5714
      } catch (org.apache.thrift.TException te) {
5715
        throw new java.io.IOException(te);
5716
      }
5717
    }
5718
 
5719
  }
5720
 
5721
  public static class getPaymentsByCapturedDate_result implements org.apache.thrift.TBase<getPaymentsByCapturedDate_result, getPaymentsByCapturedDate_result._Fields>, java.io.Serializable, Cloneable   {
5722
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsByCapturedDate_result");
5723
 
5724
    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);
5725
    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);
5726
 
5727
    private List<Payment> success; // required
5728
    private PaymentException pe; // required
5729
 
5730
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5731
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5732
      SUCCESS((short)0, "success"),
5733
      PE((short)1, "pe");
5734
 
5735
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5736
 
5737
      static {
5738
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5739
          byName.put(field.getFieldName(), field);
5740
        }
5741
      }
5742
 
5743
      /**
5744
       * Find the _Fields constant that matches fieldId, or null if its not found.
5745
       */
5746
      public static _Fields findByThriftId(int fieldId) {
5747
        switch(fieldId) {
5748
          case 0: // SUCCESS
5749
            return SUCCESS;
5750
          case 1: // PE
5751
            return PE;
5752
          default:
5753
            return null;
5754
        }
5755
      }
5756
 
5757
      /**
5758
       * Find the _Fields constant that matches fieldId, throwing an exception
5759
       * if it is not found.
5760
       */
5761
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5762
        _Fields fields = findByThriftId(fieldId);
5763
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5764
        return fields;
5765
      }
5766
 
5767
      /**
5768
       * Find the _Fields constant that matches name, or null if its not found.
5769
       */
5770
      public static _Fields findByName(String name) {
5771
        return byName.get(name);
5772
      }
5773
 
5774
      private final short _thriftId;
5775
      private final String _fieldName;
5776
 
5777
      _Fields(short thriftId, String fieldName) {
5778
        _thriftId = thriftId;
5779
        _fieldName = fieldName;
5780
      }
5781
 
5782
      public short getThriftFieldId() {
5783
        return _thriftId;
5784
      }
5785
 
5786
      public String getFieldName() {
5787
        return _fieldName;
5788
      }
5789
    }
5790
 
5791
    // isset id assignments
5792
 
5793
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5794
    static {
5795
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5796
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5797
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
5798
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
5799
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5800
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5801
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5802
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsByCapturedDate_result.class, metaDataMap);
5803
    }
5804
 
5805
    public getPaymentsByCapturedDate_result() {
5806
    }
5807
 
5808
    public getPaymentsByCapturedDate_result(
5809
      List<Payment> success,
5810
      PaymentException pe)
5811
    {
5812
      this();
5813
      this.success = success;
5814
      this.pe = pe;
5815
    }
5816
 
5817
    /**
5818
     * Performs a deep copy on <i>other</i>.
5819
     */
5820
    public getPaymentsByCapturedDate_result(getPaymentsByCapturedDate_result other) {
5821
      if (other.isSetSuccess()) {
5822
        List<Payment> __this__success = new ArrayList<Payment>();
5823
        for (Payment other_element : other.success) {
5824
          __this__success.add(new Payment(other_element));
5825
        }
5826
        this.success = __this__success;
5827
      }
5828
      if (other.isSetPe()) {
5829
        this.pe = new PaymentException(other.pe);
5830
      }
5831
    }
5832
 
5833
    public getPaymentsByCapturedDate_result deepCopy() {
5834
      return new getPaymentsByCapturedDate_result(this);
5835
    }
5836
 
5837
    @Override
5838
    public void clear() {
5839
      this.success = null;
5840
      this.pe = null;
5841
    }
5842
 
5843
    public int getSuccessSize() {
5844
      return (this.success == null) ? 0 : this.success.size();
5845
    }
5846
 
5847
    public java.util.Iterator<Payment> getSuccessIterator() {
5848
      return (this.success == null) ? null : this.success.iterator();
5849
    }
5850
 
5851
    public void addToSuccess(Payment elem) {
5852
      if (this.success == null) {
5853
        this.success = new ArrayList<Payment>();
5854
      }
5855
      this.success.add(elem);
5856
    }
5857
 
5858
    public List<Payment> getSuccess() {
5859
      return this.success;
5860
    }
5861
 
5862
    public void setSuccess(List<Payment> success) {
5863
      this.success = success;
5864
    }
5865
 
5866
    public void unsetSuccess() {
5867
      this.success = null;
5868
    }
5869
 
5870
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
5871
    public boolean isSetSuccess() {
5872
      return this.success != null;
5873
    }
5874
 
5875
    public void setSuccessIsSet(boolean value) {
5876
      if (!value) {
5877
        this.success = null;
5878
      }
5879
    }
5880
 
5881
    public PaymentException getPe() {
5882
      return this.pe;
5883
    }
5884
 
5885
    public void setPe(PaymentException pe) {
5886
      this.pe = pe;
5887
    }
5888
 
5889
    public void unsetPe() {
5890
      this.pe = null;
5891
    }
5892
 
5893
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
5894
    public boolean isSetPe() {
5895
      return this.pe != null;
5896
    }
5897
 
5898
    public void setPeIsSet(boolean value) {
5899
      if (!value) {
5900
        this.pe = null;
5901
      }
5902
    }
5903
 
5904
    public void setFieldValue(_Fields field, Object value) {
5905
      switch (field) {
5906
      case SUCCESS:
5907
        if (value == null) {
5908
          unsetSuccess();
5909
        } else {
5910
          setSuccess((List<Payment>)value);
5911
        }
5912
        break;
5913
 
5914
      case PE:
5915
        if (value == null) {
5916
          unsetPe();
5917
        } else {
5918
          setPe((PaymentException)value);
5919
        }
5920
        break;
5921
 
5922
      }
5923
    }
5924
 
5925
    public Object getFieldValue(_Fields field) {
5926
      switch (field) {
5927
      case SUCCESS:
5928
        return getSuccess();
5929
 
5930
      case PE:
5931
        return getPe();
5932
 
5933
      }
5934
      throw new IllegalStateException();
5935
    }
5936
 
5937
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5938
    public boolean isSet(_Fields field) {
5939
      if (field == null) {
5940
        throw new IllegalArgumentException();
5941
      }
5942
 
5943
      switch (field) {
5944
      case SUCCESS:
5945
        return isSetSuccess();
5946
      case PE:
5947
        return isSetPe();
5948
      }
5949
      throw new IllegalStateException();
5950
    }
5951
 
5952
    @Override
5953
    public boolean equals(Object that) {
5954
      if (that == null)
5955
        return false;
5956
      if (that instanceof getPaymentsByCapturedDate_result)
5957
        return this.equals((getPaymentsByCapturedDate_result)that);
5958
      return false;
5959
    }
5960
 
5961
    public boolean equals(getPaymentsByCapturedDate_result that) {
5962
      if (that == null)
5963
        return false;
5964
 
5965
      boolean this_present_success = true && this.isSetSuccess();
5966
      boolean that_present_success = true && that.isSetSuccess();
5967
      if (this_present_success || that_present_success) {
5968
        if (!(this_present_success && that_present_success))
5969
          return false;
5970
        if (!this.success.equals(that.success))
5971
          return false;
5972
      }
5973
 
5974
      boolean this_present_pe = true && this.isSetPe();
5975
      boolean that_present_pe = true && that.isSetPe();
5976
      if (this_present_pe || that_present_pe) {
5977
        if (!(this_present_pe && that_present_pe))
5978
          return false;
5979
        if (!this.pe.equals(that.pe))
5980
          return false;
5981
      }
5982
 
5983
      return true;
5984
    }
5985
 
5986
    @Override
5987
    public int hashCode() {
5988
      return 0;
5989
    }
5990
 
5991
    public int compareTo(getPaymentsByCapturedDate_result other) {
5992
      if (!getClass().equals(other.getClass())) {
5993
        return getClass().getName().compareTo(other.getClass().getName());
5994
      }
5995
 
5996
      int lastComparison = 0;
5997
      getPaymentsByCapturedDate_result typedOther = (getPaymentsByCapturedDate_result)other;
5998
 
5999
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
6000
      if (lastComparison != 0) {
6001
        return lastComparison;
6002
      }
6003
      if (isSetSuccess()) {
6004
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6005
        if (lastComparison != 0) {
6006
          return lastComparison;
6007
        }
6008
      }
6009
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
6010
      if (lastComparison != 0) {
6011
        return lastComparison;
6012
      }
6013
      if (isSetPe()) {
6014
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
6015
        if (lastComparison != 0) {
6016
          return lastComparison;
6017
        }
6018
      }
6019
      return 0;
6020
    }
6021
 
6022
    public _Fields fieldForId(int fieldId) {
6023
      return _Fields.findByThriftId(fieldId);
6024
    }
6025
 
6026
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6027
      org.apache.thrift.protocol.TField field;
6028
      iprot.readStructBegin();
6029
      while (true)
6030
      {
6031
        field = iprot.readFieldBegin();
6032
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6033
          break;
6034
        }
6035
        switch (field.id) {
6036
          case 0: // SUCCESS
6037
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
6038
              {
6039
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
6040
                this.success = new ArrayList<Payment>(_list20.size);
6041
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
6042
                {
6043
                  Payment _elem22; // required
6044
                  _elem22 = new Payment();
6045
                  _elem22.read(iprot);
6046
                  this.success.add(_elem22);
6047
                }
6048
                iprot.readListEnd();
6049
              }
6050
            } else { 
6051
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6052
            }
6053
            break;
6054
          case 1: // PE
6055
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6056
              this.pe = new PaymentException();
6057
              this.pe.read(iprot);
6058
            } else { 
6059
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6060
            }
6061
            break;
6062
          default:
6063
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6064
        }
6065
        iprot.readFieldEnd();
6066
      }
6067
      iprot.readStructEnd();
6068
      validate();
6069
    }
6070
 
6071
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6072
      oprot.writeStructBegin(STRUCT_DESC);
6073
 
6074
      if (this.isSetSuccess()) {
6075
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
6076
        {
6077
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
6078
          for (Payment _iter23 : this.success)
6079
          {
6080
            _iter23.write(oprot);
6081
          }
6082
          oprot.writeListEnd();
6083
        }
6084
        oprot.writeFieldEnd();
6085
      } else if (this.isSetPe()) {
6086
        oprot.writeFieldBegin(PE_FIELD_DESC);
6087
        this.pe.write(oprot);
6088
        oprot.writeFieldEnd();
6089
      }
6090
      oprot.writeFieldStop();
6091
      oprot.writeStructEnd();
6092
    }
6093
 
6094
    @Override
6095
    public String toString() {
6096
      StringBuilder sb = new StringBuilder("getPaymentsByCapturedDate_result(");
6097
      boolean first = true;
6098
 
6099
      sb.append("success:");
6100
      if (this.success == null) {
6101
        sb.append("null");
6102
      } else {
6103
        sb.append(this.success);
6104
      }
6105
      first = false;
6106
      if (!first) sb.append(", ");
6107
      sb.append("pe:");
6108
      if (this.pe == null) {
6109
        sb.append("null");
6110
      } else {
6111
        sb.append(this.pe);
6112
      }
6113
      first = false;
6114
      sb.append(")");
6115
      return sb.toString();
6116
    }
6117
 
6118
    public void validate() throws org.apache.thrift.TException {
6119
      // check for required fields
6120
    }
6121
 
6122
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6123
      try {
6124
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6125
      } catch (org.apache.thrift.TException te) {
6126
        throw new java.io.IOException(te);
6127
      }
6128
    }
6129
 
6130
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6131
      try {
6132
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6133
      } catch (org.apache.thrift.TException te) {
6134
        throw new java.io.IOException(te);
6135
      }
6136
    }
6137
 
6138
  }
6139
 
3430 rajveer 6140
  public static class getPaymentGateway_args implements org.apache.thrift.TBase<getPaymentGateway_args, getPaymentGateway_args._Fields>, java.io.Serializable, Cloneable   {
6141
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentGateway_args");
123 ashish 6142
 
3430 rajveer 6143
    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 6144
 
3430 rajveer 6145
    private long id; // required
123 ashish 6146
 
6147
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6148
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 6149
      ID((short)1, "id");
123 ashish 6150
 
6151
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6152
 
6153
      static {
6154
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6155
          byName.put(field.getFieldName(), field);
6156
        }
6157
      }
6158
 
6159
      /**
6160
       * Find the _Fields constant that matches fieldId, or null if its not found.
6161
       */
6162
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6163
        switch(fieldId) {
6164
          case 1: // ID
6165
            return ID;
6166
          default:
6167
            return null;
6168
        }
123 ashish 6169
      }
6170
 
6171
      /**
6172
       * Find the _Fields constant that matches fieldId, throwing an exception
6173
       * if it is not found.
6174
       */
6175
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6176
        _Fields fields = findByThriftId(fieldId);
6177
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6178
        return fields;
6179
      }
6180
 
6181
      /**
6182
       * Find the _Fields constant that matches name, or null if its not found.
6183
       */
6184
      public static _Fields findByName(String name) {
6185
        return byName.get(name);
6186
      }
6187
 
6188
      private final short _thriftId;
6189
      private final String _fieldName;
6190
 
6191
      _Fields(short thriftId, String fieldName) {
6192
        _thriftId = thriftId;
6193
        _fieldName = fieldName;
6194
      }
6195
 
6196
      public short getThriftFieldId() {
6197
        return _thriftId;
6198
      }
6199
 
6200
      public String getFieldName() {
6201
        return _fieldName;
6202
      }
6203
    }
6204
 
6205
    // isset id assignments
420 ashish 6206
    private static final int __ID_ISSET_ID = 0;
123 ashish 6207
    private BitSet __isset_bit_vector = new BitSet(1);
6208
 
3430 rajveer 6209
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 6210
    static {
3430 rajveer 6211
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6212
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6213
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6214
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6215
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentGateway_args.class, metaDataMap);
123 ashish 6216
    }
6217
 
695 rajveer 6218
    public getPaymentGateway_args() {
123 ashish 6219
    }
6220
 
695 rajveer 6221
    public getPaymentGateway_args(
6222
      long id)
123 ashish 6223
    {
6224
      this();
420 ashish 6225
      this.id = id;
6226
      setIdIsSet(true);
123 ashish 6227
    }
6228
 
6229
    /**
6230
     * Performs a deep copy on <i>other</i>.
6231
     */
695 rajveer 6232
    public getPaymentGateway_args(getPaymentGateway_args other) {
123 ashish 6233
      __isset_bit_vector.clear();
6234
      __isset_bit_vector.or(other.__isset_bit_vector);
420 ashish 6235
      this.id = other.id;
123 ashish 6236
    }
6237
 
695 rajveer 6238
    public getPaymentGateway_args deepCopy() {
6239
      return new getPaymentGateway_args(this);
123 ashish 6240
    }
6241
 
3430 rajveer 6242
    @Override
6243
    public void clear() {
6244
      setIdIsSet(false);
6245
      this.id = 0;
123 ashish 6246
    }
6247
 
420 ashish 6248
    public long getId() {
6249
      return this.id;
123 ashish 6250
    }
6251
 
3430 rajveer 6252
    public void setId(long id) {
420 ashish 6253
      this.id = id;
6254
      setIdIsSet(true);
123 ashish 6255
    }
6256
 
420 ashish 6257
    public void unsetId() {
6258
      __isset_bit_vector.clear(__ID_ISSET_ID);
123 ashish 6259
    }
6260
 
3430 rajveer 6261
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 6262
    public boolean isSetId() {
6263
      return __isset_bit_vector.get(__ID_ISSET_ID);
123 ashish 6264
    }
6265
 
420 ashish 6266
    public void setIdIsSet(boolean value) {
6267
      __isset_bit_vector.set(__ID_ISSET_ID, value);
123 ashish 6268
    }
6269
 
6270
    public void setFieldValue(_Fields field, Object value) {
6271
      switch (field) {
420 ashish 6272
      case ID:
123 ashish 6273
        if (value == null) {
420 ashish 6274
          unsetId();
123 ashish 6275
        } else {
420 ashish 6276
          setId((Long)value);
123 ashish 6277
        }
6278
        break;
6279
 
6280
      }
6281
    }
6282
 
6283
    public Object getFieldValue(_Fields field) {
6284
      switch (field) {
420 ashish 6285
      case ID:
3430 rajveer 6286
        return Long.valueOf(getId());
123 ashish 6287
 
6288
      }
6289
      throw new IllegalStateException();
6290
    }
6291
 
3430 rajveer 6292
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6293
    public boolean isSet(_Fields field) {
6294
      if (field == null) {
6295
        throw new IllegalArgumentException();
6296
      }
123 ashish 6297
 
6298
      switch (field) {
420 ashish 6299
      case ID:
6300
        return isSetId();
123 ashish 6301
      }
6302
      throw new IllegalStateException();
6303
    }
6304
 
6305
    @Override
6306
    public boolean equals(Object that) {
6307
      if (that == null)
6308
        return false;
695 rajveer 6309
      if (that instanceof getPaymentGateway_args)
6310
        return this.equals((getPaymentGateway_args)that);
123 ashish 6311
      return false;
6312
    }
6313
 
695 rajveer 6314
    public boolean equals(getPaymentGateway_args that) {
123 ashish 6315
      if (that == null)
6316
        return false;
6317
 
420 ashish 6318
      boolean this_present_id = true;
6319
      boolean that_present_id = true;
6320
      if (this_present_id || that_present_id) {
6321
        if (!(this_present_id && that_present_id))
123 ashish 6322
          return false;
420 ashish 6323
        if (this.id != that.id)
123 ashish 6324
          return false;
6325
      }
6326
 
6327
      return true;
6328
    }
6329
 
6330
    @Override
6331
    public int hashCode() {
6332
      return 0;
6333
    }
6334
 
695 rajveer 6335
    public int compareTo(getPaymentGateway_args other) {
123 ashish 6336
      if (!getClass().equals(other.getClass())) {
6337
        return getClass().getName().compareTo(other.getClass().getName());
6338
      }
6339
 
6340
      int lastComparison = 0;
695 rajveer 6341
      getPaymentGateway_args typedOther = (getPaymentGateway_args)other;
123 ashish 6342
 
3430 rajveer 6343
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
123 ashish 6344
      if (lastComparison != 0) {
6345
        return lastComparison;
6346
      }
3430 rajveer 6347
      if (isSetId()) {
6348
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
6349
        if (lastComparison != 0) {
6350
          return lastComparison;
6351
        }
123 ashish 6352
      }
6353
      return 0;
6354
    }
6355
 
3430 rajveer 6356
    public _Fields fieldForId(int fieldId) {
6357
      return _Fields.findByThriftId(fieldId);
6358
    }
6359
 
6360
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6361
      org.apache.thrift.protocol.TField field;
123 ashish 6362
      iprot.readStructBegin();
6363
      while (true)
6364
      {
6365
        field = iprot.readFieldBegin();
3430 rajveer 6366
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 6367
          break;
6368
        }
3430 rajveer 6369
        switch (field.id) {
6370
          case 1: // ID
6371
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6372
              this.id = iprot.readI64();
6373
              setIdIsSet(true);
6374
            } else { 
6375
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6376
            }
6377
            break;
6378
          default:
6379
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 6380
        }
3430 rajveer 6381
        iprot.readFieldEnd();
123 ashish 6382
      }
6383
      iprot.readStructEnd();
6384
      validate();
6385
    }
6386
 
3430 rajveer 6387
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 6388
      validate();
6389
 
6390
      oprot.writeStructBegin(STRUCT_DESC);
420 ashish 6391
      oprot.writeFieldBegin(ID_FIELD_DESC);
6392
      oprot.writeI64(this.id);
123 ashish 6393
      oprot.writeFieldEnd();
6394
      oprot.writeFieldStop();
6395
      oprot.writeStructEnd();
6396
    }
6397
 
6398
    @Override
6399
    public String toString() {
695 rajveer 6400
      StringBuilder sb = new StringBuilder("getPaymentGateway_args(");
123 ashish 6401
      boolean first = true;
6402
 
420 ashish 6403
      sb.append("id:");
6404
      sb.append(this.id);
123 ashish 6405
      first = false;
6406
      sb.append(")");
6407
      return sb.toString();
6408
    }
6409
 
3430 rajveer 6410
    public void validate() throws org.apache.thrift.TException {
123 ashish 6411
      // check for required fields
6412
    }
6413
 
3430 rajveer 6414
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6415
      try {
6416
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6417
      } catch (org.apache.thrift.TException te) {
6418
        throw new java.io.IOException(te);
6419
      }
6420
    }
6421
 
6422
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6423
      try {
6424
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6425
        __isset_bit_vector = new BitSet(1);
6426
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6427
      } catch (org.apache.thrift.TException te) {
6428
        throw new java.io.IOException(te);
6429
      }
6430
    }
6431
 
123 ashish 6432
  }
6433
 
3430 rajveer 6434
  public static class getPaymentGateway_result implements org.apache.thrift.TBase<getPaymentGateway_result, getPaymentGateway_result._Fields>, java.io.Serializable, Cloneable   {
6435
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentGateway_result");
123 ashish 6436
 
3430 rajveer 6437
    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);
6438
    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 6439
 
3430 rajveer 6440
    private PaymentGateway success; // required
6441
    private PaymentException pe; // required
123 ashish 6442
 
6443
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6444
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 6445
      SUCCESS((short)0, "success"),
6446
      PE((short)1, "pe");
6447
 
6448
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6449
 
6450
      static {
6451
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6452
          byName.put(field.getFieldName(), field);
6453
        }
6454
      }
6455
 
6456
      /**
6457
       * Find the _Fields constant that matches fieldId, or null if its not found.
6458
       */
6459
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6460
        switch(fieldId) {
6461
          case 0: // SUCCESS
6462
            return SUCCESS;
6463
          case 1: // PE
6464
            return PE;
6465
          default:
6466
            return null;
6467
        }
420 ashish 6468
      }
6469
 
6470
      /**
6471
       * Find the _Fields constant that matches fieldId, throwing an exception
6472
       * if it is not found.
6473
       */
6474
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6475
        _Fields fields = findByThriftId(fieldId);
6476
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6477
        return fields;
6478
      }
6479
 
6480
      /**
6481
       * Find the _Fields constant that matches name, or null if its not found.
6482
       */
6483
      public static _Fields findByName(String name) {
6484
        return byName.get(name);
6485
      }
6486
 
6487
      private final short _thriftId;
6488
      private final String _fieldName;
6489
 
6490
      _Fields(short thriftId, String fieldName) {
6491
        _thriftId = thriftId;
6492
        _fieldName = fieldName;
6493
      }
6494
 
6495
      public short getThriftFieldId() {
6496
        return _thriftId;
6497
      }
6498
 
6499
      public String getFieldName() {
6500
        return _fieldName;
6501
      }
6502
    }
6503
 
6504
    // isset id assignments
6505
 
3430 rajveer 6506
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 6507
    static {
3430 rajveer 6508
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6509
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6510
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PaymentGateway.class)));
6511
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6512
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6513
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6514
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentGateway_result.class, metaDataMap);
420 ashish 6515
    }
6516
 
695 rajveer 6517
    public getPaymentGateway_result() {
420 ashish 6518
    }
6519
 
695 rajveer 6520
    public getPaymentGateway_result(
6521
      PaymentGateway success,
420 ashish 6522
      PaymentException pe)
6523
    {
6524
      this();
6525
      this.success = success;
6526
      this.pe = pe;
6527
    }
6528
 
6529
    /**
6530
     * Performs a deep copy on <i>other</i>.
6531
     */
695 rajveer 6532
    public getPaymentGateway_result(getPaymentGateway_result other) {
420 ashish 6533
      if (other.isSetSuccess()) {
695 rajveer 6534
        this.success = new PaymentGateway(other.success);
420 ashish 6535
      }
6536
      if (other.isSetPe()) {
6537
        this.pe = new PaymentException(other.pe);
6538
      }
6539
    }
6540
 
695 rajveer 6541
    public getPaymentGateway_result deepCopy() {
6542
      return new getPaymentGateway_result(this);
420 ashish 6543
    }
6544
 
3430 rajveer 6545
    @Override
6546
    public void clear() {
6547
      this.success = null;
6548
      this.pe = null;
420 ashish 6549
    }
6550
 
695 rajveer 6551
    public PaymentGateway getSuccess() {
420 ashish 6552
      return this.success;
6553
    }
6554
 
3430 rajveer 6555
    public void setSuccess(PaymentGateway success) {
420 ashish 6556
      this.success = success;
6557
    }
6558
 
6559
    public void unsetSuccess() {
6560
      this.success = null;
6561
    }
6562
 
3430 rajveer 6563
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 6564
    public boolean isSetSuccess() {
6565
      return this.success != null;
6566
    }
6567
 
6568
    public void setSuccessIsSet(boolean value) {
6569
      if (!value) {
6570
        this.success = null;
6571
      }
6572
    }
6573
 
6574
    public PaymentException getPe() {
6575
      return this.pe;
6576
    }
6577
 
3430 rajveer 6578
    public void setPe(PaymentException pe) {
420 ashish 6579
      this.pe = pe;
6580
    }
6581
 
6582
    public void unsetPe() {
6583
      this.pe = null;
6584
    }
6585
 
3430 rajveer 6586
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 6587
    public boolean isSetPe() {
6588
      return this.pe != null;
6589
    }
6590
 
6591
    public void setPeIsSet(boolean value) {
6592
      if (!value) {
6593
        this.pe = null;
6594
      }
6595
    }
6596
 
6597
    public void setFieldValue(_Fields field, Object value) {
6598
      switch (field) {
6599
      case SUCCESS:
6600
        if (value == null) {
6601
          unsetSuccess();
6602
        } else {
695 rajveer 6603
          setSuccess((PaymentGateway)value);
420 ashish 6604
        }
6605
        break;
6606
 
6607
      case PE:
6608
        if (value == null) {
6609
          unsetPe();
6610
        } else {
6611
          setPe((PaymentException)value);
6612
        }
6613
        break;
6614
 
6615
      }
6616
    }
6617
 
6618
    public Object getFieldValue(_Fields field) {
6619
      switch (field) {
6620
      case SUCCESS:
6621
        return getSuccess();
6622
 
6623
      case PE:
6624
        return getPe();
6625
 
6626
      }
6627
      throw new IllegalStateException();
6628
    }
6629
 
3430 rajveer 6630
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6631
    public boolean isSet(_Fields field) {
6632
      if (field == null) {
6633
        throw new IllegalArgumentException();
6634
      }
420 ashish 6635
 
6636
      switch (field) {
6637
      case SUCCESS:
6638
        return isSetSuccess();
6639
      case PE:
6640
        return isSetPe();
6641
      }
6642
      throw new IllegalStateException();
6643
    }
6644
 
6645
    @Override
6646
    public boolean equals(Object that) {
6647
      if (that == null)
6648
        return false;
695 rajveer 6649
      if (that instanceof getPaymentGateway_result)
6650
        return this.equals((getPaymentGateway_result)that);
420 ashish 6651
      return false;
6652
    }
6653
 
695 rajveer 6654
    public boolean equals(getPaymentGateway_result that) {
420 ashish 6655
      if (that == null)
6656
        return false;
6657
 
6658
      boolean this_present_success = true && this.isSetSuccess();
6659
      boolean that_present_success = true && that.isSetSuccess();
6660
      if (this_present_success || that_present_success) {
6661
        if (!(this_present_success && that_present_success))
6662
          return false;
6663
        if (!this.success.equals(that.success))
6664
          return false;
6665
      }
6666
 
6667
      boolean this_present_pe = true && this.isSetPe();
6668
      boolean that_present_pe = true && that.isSetPe();
6669
      if (this_present_pe || that_present_pe) {
6670
        if (!(this_present_pe && that_present_pe))
6671
          return false;
6672
        if (!this.pe.equals(that.pe))
6673
          return false;
6674
      }
6675
 
6676
      return true;
6677
    }
6678
 
6679
    @Override
6680
    public int hashCode() {
6681
      return 0;
6682
    }
6683
 
695 rajveer 6684
    public int compareTo(getPaymentGateway_result other) {
6685
      if (!getClass().equals(other.getClass())) {
6686
        return getClass().getName().compareTo(other.getClass().getName());
6687
      }
6688
 
6689
      int lastComparison = 0;
6690
      getPaymentGateway_result typedOther = (getPaymentGateway_result)other;
6691
 
3430 rajveer 6692
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 6693
      if (lastComparison != 0) {
6694
        return lastComparison;
6695
      }
3430 rajveer 6696
      if (isSetSuccess()) {
6697
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6698
        if (lastComparison != 0) {
6699
          return lastComparison;
6700
        }
695 rajveer 6701
      }
3430 rajveer 6702
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 6703
      if (lastComparison != 0) {
6704
        return lastComparison;
6705
      }
3430 rajveer 6706
      if (isSetPe()) {
6707
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
6708
        if (lastComparison != 0) {
6709
          return lastComparison;
6710
        }
695 rajveer 6711
      }
6712
      return 0;
6713
    }
6714
 
3430 rajveer 6715
    public _Fields fieldForId(int fieldId) {
6716
      return _Fields.findByThriftId(fieldId);
6717
    }
6718
 
6719
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6720
      org.apache.thrift.protocol.TField field;
420 ashish 6721
      iprot.readStructBegin();
6722
      while (true)
6723
      {
6724
        field = iprot.readFieldBegin();
3430 rajveer 6725
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 6726
          break;
6727
        }
3430 rajveer 6728
        switch (field.id) {
6729
          case 0: // SUCCESS
6730
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6731
              this.success = new PaymentGateway();
6732
              this.success.read(iprot);
6733
            } else { 
6734
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6735
            }
6736
            break;
6737
          case 1: // PE
6738
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6739
              this.pe = new PaymentException();
6740
              this.pe.read(iprot);
6741
            } else { 
6742
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6743
            }
6744
            break;
6745
          default:
6746
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 6747
        }
3430 rajveer 6748
        iprot.readFieldEnd();
420 ashish 6749
      }
6750
      iprot.readStructEnd();
6751
      validate();
6752
    }
6753
 
3430 rajveer 6754
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 6755
      oprot.writeStructBegin(STRUCT_DESC);
6756
 
6757
      if (this.isSetSuccess()) {
6758
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
695 rajveer 6759
        this.success.write(oprot);
420 ashish 6760
        oprot.writeFieldEnd();
6761
      } else if (this.isSetPe()) {
6762
        oprot.writeFieldBegin(PE_FIELD_DESC);
6763
        this.pe.write(oprot);
6764
        oprot.writeFieldEnd();
6765
      }
6766
      oprot.writeFieldStop();
6767
      oprot.writeStructEnd();
6768
    }
6769
 
6770
    @Override
6771
    public String toString() {
695 rajveer 6772
      StringBuilder sb = new StringBuilder("getPaymentGateway_result(");
420 ashish 6773
      boolean first = true;
6774
 
6775
      sb.append("success:");
6776
      if (this.success == null) {
6777
        sb.append("null");
6778
      } else {
6779
        sb.append(this.success);
6780
      }
6781
      first = false;
6782
      if (!first) sb.append(", ");
6783
      sb.append("pe:");
6784
      if (this.pe == null) {
6785
        sb.append("null");
6786
      } else {
6787
        sb.append(this.pe);
6788
      }
6789
      first = false;
6790
      sb.append(")");
6791
      return sb.toString();
6792
    }
6793
 
3430 rajveer 6794
    public void validate() throws org.apache.thrift.TException {
420 ashish 6795
      // check for required fields
6796
    }
6797
 
3430 rajveer 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
 
420 ashish 6814
  }
6815
 
4600 varun.gupt 6816
  public static class getActivePaymentGateways_args implements org.apache.thrift.TBase<getActivePaymentGateways_args, getActivePaymentGateways_args._Fields>, java.io.Serializable, Cloneable   {
6817
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getActivePaymentGateways_args");
6818
 
6819
 
6820
 
6821
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6822
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6823
;
6824
 
6825
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6826
 
6827
      static {
6828
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6829
          byName.put(field.getFieldName(), field);
6830
        }
6831
      }
6832
 
6833
      /**
6834
       * Find the _Fields constant that matches fieldId, or null if its not found.
6835
       */
6836
      public static _Fields findByThriftId(int fieldId) {
6837
        switch(fieldId) {
6838
          default:
6839
            return null;
6840
        }
6841
      }
6842
 
6843
      /**
6844
       * Find the _Fields constant that matches fieldId, throwing an exception
6845
       * if it is not found.
6846
       */
6847
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6848
        _Fields fields = findByThriftId(fieldId);
6849
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6850
        return fields;
6851
      }
6852
 
6853
      /**
6854
       * Find the _Fields constant that matches name, or null if its not found.
6855
       */
6856
      public static _Fields findByName(String name) {
6857
        return byName.get(name);
6858
      }
6859
 
6860
      private final short _thriftId;
6861
      private final String _fieldName;
6862
 
6863
      _Fields(short thriftId, String fieldName) {
6864
        _thriftId = thriftId;
6865
        _fieldName = fieldName;
6866
      }
6867
 
6868
      public short getThriftFieldId() {
6869
        return _thriftId;
6870
      }
6871
 
6872
      public String getFieldName() {
6873
        return _fieldName;
6874
      }
6875
    }
6876
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6877
    static {
6878
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6879
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6880
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getActivePaymentGateways_args.class, metaDataMap);
6881
    }
6882
 
6883
    public getActivePaymentGateways_args() {
6884
    }
6885
 
6886
    /**
6887
     * Performs a deep copy on <i>other</i>.
6888
     */
6889
    public getActivePaymentGateways_args(getActivePaymentGateways_args other) {
6890
    }
6891
 
6892
    public getActivePaymentGateways_args deepCopy() {
6893
      return new getActivePaymentGateways_args(this);
6894
    }
6895
 
6896
    @Override
6897
    public void clear() {
6898
    }
6899
 
6900
    public void setFieldValue(_Fields field, Object value) {
6901
      switch (field) {
6902
      }
6903
    }
6904
 
6905
    public Object getFieldValue(_Fields field) {
6906
      switch (field) {
6907
      }
6908
      throw new IllegalStateException();
6909
    }
6910
 
6911
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6912
    public boolean isSet(_Fields field) {
6913
      if (field == null) {
6914
        throw new IllegalArgumentException();
6915
      }
6916
 
6917
      switch (field) {
6918
      }
6919
      throw new IllegalStateException();
6920
    }
6921
 
6922
    @Override
6923
    public boolean equals(Object that) {
6924
      if (that == null)
6925
        return false;
6926
      if (that instanceof getActivePaymentGateways_args)
6927
        return this.equals((getActivePaymentGateways_args)that);
6928
      return false;
6929
    }
6930
 
6931
    public boolean equals(getActivePaymentGateways_args that) {
6932
      if (that == null)
6933
        return false;
6934
 
6935
      return true;
6936
    }
6937
 
6938
    @Override
6939
    public int hashCode() {
6940
      return 0;
6941
    }
6942
 
6943
    public int compareTo(getActivePaymentGateways_args other) {
6944
      if (!getClass().equals(other.getClass())) {
6945
        return getClass().getName().compareTo(other.getClass().getName());
6946
      }
6947
 
6948
      int lastComparison = 0;
6949
      getActivePaymentGateways_args typedOther = (getActivePaymentGateways_args)other;
6950
 
6951
      return 0;
6952
    }
6953
 
6954
    public _Fields fieldForId(int fieldId) {
6955
      return _Fields.findByThriftId(fieldId);
6956
    }
6957
 
6958
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6959
      org.apache.thrift.protocol.TField field;
6960
      iprot.readStructBegin();
6961
      while (true)
6962
      {
6963
        field = iprot.readFieldBegin();
6964
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6965
          break;
6966
        }
6967
        switch (field.id) {
6968
          default:
6969
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6970
        }
6971
        iprot.readFieldEnd();
6972
      }
6973
      iprot.readStructEnd();
6974
      validate();
6975
    }
6976
 
6977
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6978
      validate();
6979
 
6980
      oprot.writeStructBegin(STRUCT_DESC);
6981
      oprot.writeFieldStop();
6982
      oprot.writeStructEnd();
6983
    }
6984
 
6985
    @Override
6986
    public String toString() {
6987
      StringBuilder sb = new StringBuilder("getActivePaymentGateways_args(");
6988
      boolean first = true;
6989
 
6990
      sb.append(")");
6991
      return sb.toString();
6992
    }
6993
 
6994
    public void validate() throws org.apache.thrift.TException {
6995
      // check for required fields
6996
    }
6997
 
6998
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6999
      try {
7000
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7001
      } catch (org.apache.thrift.TException te) {
7002
        throw new java.io.IOException(te);
7003
      }
7004
    }
7005
 
7006
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7007
      try {
7008
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7009
      } catch (org.apache.thrift.TException te) {
7010
        throw new java.io.IOException(te);
7011
      }
7012
    }
7013
 
7014
  }
7015
 
7016
  public static class getActivePaymentGateways_result implements org.apache.thrift.TBase<getActivePaymentGateways_result, getActivePaymentGateways_result._Fields>, java.io.Serializable, Cloneable   {
7017
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getActivePaymentGateways_result");
7018
 
7019
    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);
7020
    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);
7021
 
7022
    private List<PaymentGateway> success; // required
7023
    private PaymentException pe; // required
7024
 
7025
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7026
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7027
      SUCCESS((short)0, "success"),
7028
      PE((short)1, "pe");
7029
 
7030
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7031
 
7032
      static {
7033
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7034
          byName.put(field.getFieldName(), field);
7035
        }
7036
      }
7037
 
7038
      /**
7039
       * Find the _Fields constant that matches fieldId, or null if its not found.
7040
       */
7041
      public static _Fields findByThriftId(int fieldId) {
7042
        switch(fieldId) {
7043
          case 0: // SUCCESS
7044
            return SUCCESS;
7045
          case 1: // PE
7046
            return PE;
7047
          default:
7048
            return null;
7049
        }
7050
      }
7051
 
7052
      /**
7053
       * Find the _Fields constant that matches fieldId, throwing an exception
7054
       * if it is not found.
7055
       */
7056
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7057
        _Fields fields = findByThriftId(fieldId);
7058
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7059
        return fields;
7060
      }
7061
 
7062
      /**
7063
       * Find the _Fields constant that matches name, or null if its not found.
7064
       */
7065
      public static _Fields findByName(String name) {
7066
        return byName.get(name);
7067
      }
7068
 
7069
      private final short _thriftId;
7070
      private final String _fieldName;
7071
 
7072
      _Fields(short thriftId, String fieldName) {
7073
        _thriftId = thriftId;
7074
        _fieldName = fieldName;
7075
      }
7076
 
7077
      public short getThriftFieldId() {
7078
        return _thriftId;
7079
      }
7080
 
7081
      public String getFieldName() {
7082
        return _fieldName;
7083
      }
7084
    }
7085
 
7086
    // isset id assignments
7087
 
7088
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7089
    static {
7090
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7091
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7092
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
7093
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PaymentGateway.class))));
7094
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7095
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7096
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7097
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getActivePaymentGateways_result.class, metaDataMap);
7098
    }
7099
 
7100
    public getActivePaymentGateways_result() {
7101
    }
7102
 
7103
    public getActivePaymentGateways_result(
7104
      List<PaymentGateway> success,
7105
      PaymentException pe)
7106
    {
7107
      this();
7108
      this.success = success;
7109
      this.pe = pe;
7110
    }
7111
 
7112
    /**
7113
     * Performs a deep copy on <i>other</i>.
7114
     */
7115
    public getActivePaymentGateways_result(getActivePaymentGateways_result other) {
7116
      if (other.isSetSuccess()) {
7117
        List<PaymentGateway> __this__success = new ArrayList<PaymentGateway>();
7118
        for (PaymentGateway other_element : other.success) {
7119
          __this__success.add(new PaymentGateway(other_element));
7120
        }
7121
        this.success = __this__success;
7122
      }
7123
      if (other.isSetPe()) {
7124
        this.pe = new PaymentException(other.pe);
7125
      }
7126
    }
7127
 
7128
    public getActivePaymentGateways_result deepCopy() {
7129
      return new getActivePaymentGateways_result(this);
7130
    }
7131
 
7132
    @Override
7133
    public void clear() {
7134
      this.success = null;
7135
      this.pe = null;
7136
    }
7137
 
7138
    public int getSuccessSize() {
7139
      return (this.success == null) ? 0 : this.success.size();
7140
    }
7141
 
7142
    public java.util.Iterator<PaymentGateway> getSuccessIterator() {
7143
      return (this.success == null) ? null : this.success.iterator();
7144
    }
7145
 
7146
    public void addToSuccess(PaymentGateway elem) {
7147
      if (this.success == null) {
7148
        this.success = new ArrayList<PaymentGateway>();
7149
      }
7150
      this.success.add(elem);
7151
    }
7152
 
7153
    public List<PaymentGateway> getSuccess() {
7154
      return this.success;
7155
    }
7156
 
7157
    public void setSuccess(List<PaymentGateway> success) {
7158
      this.success = success;
7159
    }
7160
 
7161
    public void unsetSuccess() {
7162
      this.success = null;
7163
    }
7164
 
7165
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
7166
    public boolean isSetSuccess() {
7167
      return this.success != null;
7168
    }
7169
 
7170
    public void setSuccessIsSet(boolean value) {
7171
      if (!value) {
7172
        this.success = null;
7173
      }
7174
    }
7175
 
7176
    public PaymentException getPe() {
7177
      return this.pe;
7178
    }
7179
 
7180
    public void setPe(PaymentException pe) {
7181
      this.pe = pe;
7182
    }
7183
 
7184
    public void unsetPe() {
7185
      this.pe = null;
7186
    }
7187
 
7188
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
7189
    public boolean isSetPe() {
7190
      return this.pe != null;
7191
    }
7192
 
7193
    public void setPeIsSet(boolean value) {
7194
      if (!value) {
7195
        this.pe = null;
7196
      }
7197
    }
7198
 
7199
    public void setFieldValue(_Fields field, Object value) {
7200
      switch (field) {
7201
      case SUCCESS:
7202
        if (value == null) {
7203
          unsetSuccess();
7204
        } else {
7205
          setSuccess((List<PaymentGateway>)value);
7206
        }
7207
        break;
7208
 
7209
      case PE:
7210
        if (value == null) {
7211
          unsetPe();
7212
        } else {
7213
          setPe((PaymentException)value);
7214
        }
7215
        break;
7216
 
7217
      }
7218
    }
7219
 
7220
    public Object getFieldValue(_Fields field) {
7221
      switch (field) {
7222
      case SUCCESS:
7223
        return getSuccess();
7224
 
7225
      case PE:
7226
        return getPe();
7227
 
7228
      }
7229
      throw new IllegalStateException();
7230
    }
7231
 
7232
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7233
    public boolean isSet(_Fields field) {
7234
      if (field == null) {
7235
        throw new IllegalArgumentException();
7236
      }
7237
 
7238
      switch (field) {
7239
      case SUCCESS:
7240
        return isSetSuccess();
7241
      case PE:
7242
        return isSetPe();
7243
      }
7244
      throw new IllegalStateException();
7245
    }
7246
 
7247
    @Override
7248
    public boolean equals(Object that) {
7249
      if (that == null)
7250
        return false;
7251
      if (that instanceof getActivePaymentGateways_result)
7252
        return this.equals((getActivePaymentGateways_result)that);
7253
      return false;
7254
    }
7255
 
7256
    public boolean equals(getActivePaymentGateways_result that) {
7257
      if (that == null)
7258
        return false;
7259
 
7260
      boolean this_present_success = true && this.isSetSuccess();
7261
      boolean that_present_success = true && that.isSetSuccess();
7262
      if (this_present_success || that_present_success) {
7263
        if (!(this_present_success && that_present_success))
7264
          return false;
7265
        if (!this.success.equals(that.success))
7266
          return false;
7267
      }
7268
 
7269
      boolean this_present_pe = true && this.isSetPe();
7270
      boolean that_present_pe = true && that.isSetPe();
7271
      if (this_present_pe || that_present_pe) {
7272
        if (!(this_present_pe && that_present_pe))
7273
          return false;
7274
        if (!this.pe.equals(that.pe))
7275
          return false;
7276
      }
7277
 
7278
      return true;
7279
    }
7280
 
7281
    @Override
7282
    public int hashCode() {
7283
      return 0;
7284
    }
7285
 
7286
    public int compareTo(getActivePaymentGateways_result other) {
7287
      if (!getClass().equals(other.getClass())) {
7288
        return getClass().getName().compareTo(other.getClass().getName());
7289
      }
7290
 
7291
      int lastComparison = 0;
7292
      getActivePaymentGateways_result typedOther = (getActivePaymentGateways_result)other;
7293
 
7294
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
7295
      if (lastComparison != 0) {
7296
        return lastComparison;
7297
      }
7298
      if (isSetSuccess()) {
7299
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7300
        if (lastComparison != 0) {
7301
          return lastComparison;
7302
        }
7303
      }
7304
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
7305
      if (lastComparison != 0) {
7306
        return lastComparison;
7307
      }
7308
      if (isSetPe()) {
7309
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
7310
        if (lastComparison != 0) {
7311
          return lastComparison;
7312
        }
7313
      }
7314
      return 0;
7315
    }
7316
 
7317
    public _Fields fieldForId(int fieldId) {
7318
      return _Fields.findByThriftId(fieldId);
7319
    }
7320
 
7321
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7322
      org.apache.thrift.protocol.TField field;
7323
      iprot.readStructBegin();
7324
      while (true)
7325
      {
7326
        field = iprot.readFieldBegin();
7327
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7328
          break;
7329
        }
7330
        switch (field.id) {
7331
          case 0: // SUCCESS
7332
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
7333
              {
7334
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
7335
                this.success = new ArrayList<PaymentGateway>(_list24.size);
7336
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
7337
                {
7338
                  PaymentGateway _elem26; // required
7339
                  _elem26 = new PaymentGateway();
7340
                  _elem26.read(iprot);
7341
                  this.success.add(_elem26);
7342
                }
7343
                iprot.readListEnd();
7344
              }
7345
            } else { 
7346
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7347
            }
7348
            break;
7349
          case 1: // PE
7350
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7351
              this.pe = new PaymentException();
7352
              this.pe.read(iprot);
7353
            } else { 
7354
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7355
            }
7356
            break;
7357
          default:
7358
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7359
        }
7360
        iprot.readFieldEnd();
7361
      }
7362
      iprot.readStructEnd();
7363
      validate();
7364
    }
7365
 
7366
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7367
      oprot.writeStructBegin(STRUCT_DESC);
7368
 
7369
      if (this.isSetSuccess()) {
7370
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7371
        {
7372
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
7373
          for (PaymentGateway _iter27 : this.success)
7374
          {
7375
            _iter27.write(oprot);
7376
          }
7377
          oprot.writeListEnd();
7378
        }
7379
        oprot.writeFieldEnd();
7380
      } else if (this.isSetPe()) {
7381
        oprot.writeFieldBegin(PE_FIELD_DESC);
7382
        this.pe.write(oprot);
7383
        oprot.writeFieldEnd();
7384
      }
7385
      oprot.writeFieldStop();
7386
      oprot.writeStructEnd();
7387
    }
7388
 
7389
    @Override
7390
    public String toString() {
7391
      StringBuilder sb = new StringBuilder("getActivePaymentGateways_result(");
7392
      boolean first = true;
7393
 
7394
      sb.append("success:");
7395
      if (this.success == null) {
7396
        sb.append("null");
7397
      } else {
7398
        sb.append(this.success);
7399
      }
7400
      first = false;
7401
      if (!first) sb.append(", ");
7402
      sb.append("pe:");
7403
      if (this.pe == null) {
7404
        sb.append("null");
7405
      } else {
7406
        sb.append(this.pe);
7407
      }
7408
      first = false;
7409
      sb.append(")");
7410
      return sb.toString();
7411
    }
7412
 
7413
    public void validate() throws org.apache.thrift.TException {
7414
      // check for required fields
7415
    }
7416
 
7417
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7418
      try {
7419
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7420
      } catch (org.apache.thrift.TException te) {
7421
        throw new java.io.IOException(te);
7422
      }
7423
    }
7424
 
7425
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7426
      try {
7427
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7428
      } catch (org.apache.thrift.TException te) {
7429
        throw new java.io.IOException(te);
7430
      }
7431
    }
7432
 
7433
  }
7434
 
3430 rajveer 7435
  public static class getPayment_args implements org.apache.thrift.TBase<getPayment_args, getPayment_args._Fields>, java.io.Serializable, Cloneable   {
7436
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayment_args");
420 ashish 7437
 
3430 rajveer 7438
    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 7439
 
3430 rajveer 7440
    private long id; // required
420 ashish 7441
 
7442
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7443
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 7444
      ID((short)1, "id");
7445
 
7446
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7447
 
7448
      static {
7449
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7450
          byName.put(field.getFieldName(), field);
7451
        }
7452
      }
7453
 
7454
      /**
7455
       * Find the _Fields constant that matches fieldId, or null if its not found.
7456
       */
7457
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7458
        switch(fieldId) {
7459
          case 1: // ID
7460
            return ID;
7461
          default:
7462
            return null;
7463
        }
420 ashish 7464
      }
7465
 
7466
      /**
7467
       * Find the _Fields constant that matches fieldId, throwing an exception
7468
       * if it is not found.
7469
       */
7470
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7471
        _Fields fields = findByThriftId(fieldId);
7472
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7473
        return fields;
7474
      }
7475
 
7476
      /**
7477
       * Find the _Fields constant that matches name, or null if its not found.
7478
       */
7479
      public static _Fields findByName(String name) {
7480
        return byName.get(name);
7481
      }
7482
 
7483
      private final short _thriftId;
7484
      private final String _fieldName;
7485
 
7486
      _Fields(short thriftId, String fieldName) {
7487
        _thriftId = thriftId;
7488
        _fieldName = fieldName;
7489
      }
7490
 
7491
      public short getThriftFieldId() {
7492
        return _thriftId;
7493
      }
7494
 
7495
      public String getFieldName() {
7496
        return _fieldName;
7497
      }
7498
    }
7499
 
7500
    // isset id assignments
7501
    private static final int __ID_ISSET_ID = 0;
7502
    private BitSet __isset_bit_vector = new BitSet(1);
7503
 
3430 rajveer 7504
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 7505
    static {
3430 rajveer 7506
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7507
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7508
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7509
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7510
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayment_args.class, metaDataMap);
420 ashish 7511
    }
7512
 
695 rajveer 7513
    public getPayment_args() {
420 ashish 7514
    }
7515
 
695 rajveer 7516
    public getPayment_args(
420 ashish 7517
      long id)
7518
    {
7519
      this();
7520
      this.id = id;
7521
      setIdIsSet(true);
7522
    }
7523
 
7524
    /**
7525
     * Performs a deep copy on <i>other</i>.
7526
     */
695 rajveer 7527
    public getPayment_args(getPayment_args other) {
420 ashish 7528
      __isset_bit_vector.clear();
7529
      __isset_bit_vector.or(other.__isset_bit_vector);
7530
      this.id = other.id;
7531
    }
7532
 
695 rajveer 7533
    public getPayment_args deepCopy() {
7534
      return new getPayment_args(this);
420 ashish 7535
    }
7536
 
3430 rajveer 7537
    @Override
7538
    public void clear() {
7539
      setIdIsSet(false);
7540
      this.id = 0;
420 ashish 7541
    }
7542
 
7543
    public long getId() {
7544
      return this.id;
7545
    }
7546
 
3430 rajveer 7547
    public void setId(long id) {
420 ashish 7548
      this.id = id;
7549
      setIdIsSet(true);
7550
    }
7551
 
7552
    public void unsetId() {
7553
      __isset_bit_vector.clear(__ID_ISSET_ID);
7554
    }
7555
 
3430 rajveer 7556
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 7557
    public boolean isSetId() {
7558
      return __isset_bit_vector.get(__ID_ISSET_ID);
7559
    }
7560
 
7561
    public void setIdIsSet(boolean value) {
7562
      __isset_bit_vector.set(__ID_ISSET_ID, value);
7563
    }
7564
 
7565
    public void setFieldValue(_Fields field, Object value) {
7566
      switch (field) {
7567
      case ID:
7568
        if (value == null) {
7569
          unsetId();
7570
        } else {
7571
          setId((Long)value);
7572
        }
7573
        break;
7574
 
7575
      }
7576
    }
7577
 
7578
    public Object getFieldValue(_Fields field) {
7579
      switch (field) {
7580
      case ID:
3430 rajveer 7581
        return Long.valueOf(getId());
420 ashish 7582
 
7583
      }
7584
      throw new IllegalStateException();
7585
    }
7586
 
3430 rajveer 7587
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7588
    public boolean isSet(_Fields field) {
7589
      if (field == null) {
7590
        throw new IllegalArgumentException();
7591
      }
420 ashish 7592
 
7593
      switch (field) {
7594
      case ID:
7595
        return isSetId();
7596
      }
7597
      throw new IllegalStateException();
7598
    }
7599
 
7600
    @Override
7601
    public boolean equals(Object that) {
7602
      if (that == null)
7603
        return false;
695 rajveer 7604
      if (that instanceof getPayment_args)
7605
        return this.equals((getPayment_args)that);
420 ashish 7606
      return false;
7607
    }
7608
 
695 rajveer 7609
    public boolean equals(getPayment_args that) {
420 ashish 7610
      if (that == null)
7611
        return false;
7612
 
7613
      boolean this_present_id = true;
7614
      boolean that_present_id = true;
7615
      if (this_present_id || that_present_id) {
7616
        if (!(this_present_id && that_present_id))
7617
          return false;
7618
        if (this.id != that.id)
7619
          return false;
7620
      }
7621
 
7622
      return true;
7623
    }
7624
 
7625
    @Override
7626
    public int hashCode() {
7627
      return 0;
7628
    }
7629
 
695 rajveer 7630
    public int compareTo(getPayment_args other) {
420 ashish 7631
      if (!getClass().equals(other.getClass())) {
7632
        return getClass().getName().compareTo(other.getClass().getName());
7633
      }
7634
 
7635
      int lastComparison = 0;
695 rajveer 7636
      getPayment_args typedOther = (getPayment_args)other;
420 ashish 7637
 
3430 rajveer 7638
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
420 ashish 7639
      if (lastComparison != 0) {
7640
        return lastComparison;
7641
      }
3430 rajveer 7642
      if (isSetId()) {
7643
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
7644
        if (lastComparison != 0) {
7645
          return lastComparison;
7646
        }
420 ashish 7647
      }
7648
      return 0;
7649
    }
7650
 
3430 rajveer 7651
    public _Fields fieldForId(int fieldId) {
7652
      return _Fields.findByThriftId(fieldId);
7653
    }
7654
 
7655
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7656
      org.apache.thrift.protocol.TField field;
420 ashish 7657
      iprot.readStructBegin();
7658
      while (true)
7659
      {
7660
        field = iprot.readFieldBegin();
3430 rajveer 7661
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 7662
          break;
7663
        }
3430 rajveer 7664
        switch (field.id) {
7665
          case 1: // ID
7666
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7667
              this.id = iprot.readI64();
7668
              setIdIsSet(true);
7669
            } else { 
7670
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7671
            }
7672
            break;
7673
          default:
7674
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 7675
        }
3430 rajveer 7676
        iprot.readFieldEnd();
420 ashish 7677
      }
7678
      iprot.readStructEnd();
7679
      validate();
7680
    }
7681
 
3430 rajveer 7682
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 7683
      validate();
7684
 
7685
      oprot.writeStructBegin(STRUCT_DESC);
7686
      oprot.writeFieldBegin(ID_FIELD_DESC);
7687
      oprot.writeI64(this.id);
7688
      oprot.writeFieldEnd();
7689
      oprot.writeFieldStop();
7690
      oprot.writeStructEnd();
7691
    }
7692
 
7693
    @Override
7694
    public String toString() {
695 rajveer 7695
      StringBuilder sb = new StringBuilder("getPayment_args(");
420 ashish 7696
      boolean first = true;
7697
 
7698
      sb.append("id:");
7699
      sb.append(this.id);
7700
      first = false;
7701
      sb.append(")");
7702
      return sb.toString();
7703
    }
7704
 
3430 rajveer 7705
    public void validate() throws org.apache.thrift.TException {
420 ashish 7706
      // check for required fields
7707
    }
7708
 
3430 rajveer 7709
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7710
      try {
7711
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7712
      } catch (org.apache.thrift.TException te) {
7713
        throw new java.io.IOException(te);
7714
      }
7715
    }
7716
 
7717
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7718
      try {
7719
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7720
        __isset_bit_vector = new BitSet(1);
7721
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7722
      } catch (org.apache.thrift.TException te) {
7723
        throw new java.io.IOException(te);
7724
      }
7725
    }
7726
 
420 ashish 7727
  }
7728
 
3430 rajveer 7729
  public static class getPayment_result implements org.apache.thrift.TBase<getPayment_result, getPayment_result._Fields>, java.io.Serializable, Cloneable   {
7730
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayment_result");
420 ashish 7731
 
3430 rajveer 7732
    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);
7733
    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 7734
 
3430 rajveer 7735
    private Payment success; // required
7736
    private PaymentException pe; // required
420 ashish 7737
 
7738
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7739
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 7740
      SUCCESS((short)0, "success"),
7741
      PE((short)1, "pe");
7742
 
7743
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7744
 
7745
      static {
7746
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7747
          byName.put(field.getFieldName(), field);
7748
        }
7749
      }
7750
 
7751
      /**
7752
       * Find the _Fields constant that matches fieldId, or null if its not found.
7753
       */
7754
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7755
        switch(fieldId) {
7756
          case 0: // SUCCESS
7757
            return SUCCESS;
7758
          case 1: // PE
7759
            return PE;
7760
          default:
7761
            return null;
7762
        }
420 ashish 7763
      }
7764
 
7765
      /**
7766
       * Find the _Fields constant that matches fieldId, throwing an exception
7767
       * if it is not found.
7768
       */
7769
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7770
        _Fields fields = findByThriftId(fieldId);
7771
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7772
        return fields;
7773
      }
7774
 
7775
      /**
7776
       * Find the _Fields constant that matches name, or null if its not found.
7777
       */
7778
      public static _Fields findByName(String name) {
7779
        return byName.get(name);
7780
      }
7781
 
7782
      private final short _thriftId;
7783
      private final String _fieldName;
7784
 
7785
      _Fields(short thriftId, String fieldName) {
7786
        _thriftId = thriftId;
7787
        _fieldName = fieldName;
7788
      }
7789
 
7790
      public short getThriftFieldId() {
7791
        return _thriftId;
7792
      }
7793
 
7794
      public String getFieldName() {
7795
        return _fieldName;
7796
      }
7797
    }
7798
 
7799
    // isset id assignments
7800
 
3430 rajveer 7801
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 7802
    static {
3430 rajveer 7803
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7804
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7805
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class)));
7806
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7807
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7808
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7809
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayment_result.class, metaDataMap);
420 ashish 7810
    }
7811
 
695 rajveer 7812
    public getPayment_result() {
420 ashish 7813
    }
7814
 
695 rajveer 7815
    public getPayment_result(
7816
      Payment success,
420 ashish 7817
      PaymentException pe)
7818
    {
7819
      this();
7820
      this.success = success;
7821
      this.pe = pe;
7822
    }
7823
 
7824
    /**
7825
     * Performs a deep copy on <i>other</i>.
7826
     */
695 rajveer 7827
    public getPayment_result(getPayment_result other) {
420 ashish 7828
      if (other.isSetSuccess()) {
695 rajveer 7829
        this.success = new Payment(other.success);
420 ashish 7830
      }
7831
      if (other.isSetPe()) {
7832
        this.pe = new PaymentException(other.pe);
7833
      }
7834
    }
7835
 
695 rajveer 7836
    public getPayment_result deepCopy() {
7837
      return new getPayment_result(this);
420 ashish 7838
    }
7839
 
3430 rajveer 7840
    @Override
7841
    public void clear() {
7842
      this.success = null;
7843
      this.pe = null;
420 ashish 7844
    }
7845
 
695 rajveer 7846
    public Payment getSuccess() {
420 ashish 7847
      return this.success;
7848
    }
7849
 
3430 rajveer 7850
    public void setSuccess(Payment success) {
420 ashish 7851
      this.success = success;
7852
    }
7853
 
7854
    public void unsetSuccess() {
7855
      this.success = null;
7856
    }
7857
 
3430 rajveer 7858
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 7859
    public boolean isSetSuccess() {
7860
      return this.success != null;
7861
    }
7862
 
7863
    public void setSuccessIsSet(boolean value) {
7864
      if (!value) {
7865
        this.success = null;
7866
      }
7867
    }
7868
 
7869
    public PaymentException getPe() {
7870
      return this.pe;
7871
    }
7872
 
3430 rajveer 7873
    public void setPe(PaymentException pe) {
420 ashish 7874
      this.pe = pe;
7875
    }
7876
 
7877
    public void unsetPe() {
7878
      this.pe = null;
7879
    }
7880
 
3430 rajveer 7881
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 7882
    public boolean isSetPe() {
7883
      return this.pe != null;
7884
    }
7885
 
7886
    public void setPeIsSet(boolean value) {
7887
      if (!value) {
7888
        this.pe = null;
7889
      }
7890
    }
7891
 
7892
    public void setFieldValue(_Fields field, Object value) {
7893
      switch (field) {
7894
      case SUCCESS:
7895
        if (value == null) {
7896
          unsetSuccess();
7897
        } else {
695 rajveer 7898
          setSuccess((Payment)value);
420 ashish 7899
        }
7900
        break;
7901
 
7902
      case PE:
7903
        if (value == null) {
7904
          unsetPe();
7905
        } else {
7906
          setPe((PaymentException)value);
7907
        }
7908
        break;
7909
 
7910
      }
7911
    }
7912
 
7913
    public Object getFieldValue(_Fields field) {
7914
      switch (field) {
7915
      case SUCCESS:
7916
        return getSuccess();
7917
 
7918
      case PE:
7919
        return getPe();
7920
 
7921
      }
7922
      throw new IllegalStateException();
7923
    }
7924
 
3430 rajveer 7925
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7926
    public boolean isSet(_Fields field) {
7927
      if (field == null) {
7928
        throw new IllegalArgumentException();
7929
      }
420 ashish 7930
 
7931
      switch (field) {
7932
      case SUCCESS:
7933
        return isSetSuccess();
7934
      case PE:
7935
        return isSetPe();
7936
      }
7937
      throw new IllegalStateException();
7938
    }
7939
 
7940
    @Override
7941
    public boolean equals(Object that) {
7942
      if (that == null)
7943
        return false;
695 rajveer 7944
      if (that instanceof getPayment_result)
7945
        return this.equals((getPayment_result)that);
420 ashish 7946
      return false;
7947
    }
7948
 
695 rajveer 7949
    public boolean equals(getPayment_result that) {
420 ashish 7950
      if (that == null)
7951
        return false;
7952
 
7953
      boolean this_present_success = true && this.isSetSuccess();
7954
      boolean that_present_success = true && that.isSetSuccess();
7955
      if (this_present_success || that_present_success) {
7956
        if (!(this_present_success && that_present_success))
7957
          return false;
7958
        if (!this.success.equals(that.success))
7959
          return false;
7960
      }
7961
 
7962
      boolean this_present_pe = true && this.isSetPe();
7963
      boolean that_present_pe = true && that.isSetPe();
7964
      if (this_present_pe || that_present_pe) {
7965
        if (!(this_present_pe && that_present_pe))
7966
          return false;
7967
        if (!this.pe.equals(that.pe))
7968
          return false;
7969
      }
7970
 
7971
      return true;
7972
    }
7973
 
7974
    @Override
7975
    public int hashCode() {
7976
      return 0;
7977
    }
7978
 
695 rajveer 7979
    public int compareTo(getPayment_result other) {
420 ashish 7980
      if (!getClass().equals(other.getClass())) {
7981
        return getClass().getName().compareTo(other.getClass().getName());
7982
      }
7983
 
7984
      int lastComparison = 0;
695 rajveer 7985
      getPayment_result typedOther = (getPayment_result)other;
420 ashish 7986
 
3430 rajveer 7987
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
420 ashish 7988
      if (lastComparison != 0) {
7989
        return lastComparison;
7990
      }
3430 rajveer 7991
      if (isSetSuccess()) {
7992
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7993
        if (lastComparison != 0) {
7994
          return lastComparison;
7995
        }
420 ashish 7996
      }
3430 rajveer 7997
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 7998
      if (lastComparison != 0) {
7999
        return lastComparison;
8000
      }
3430 rajveer 8001
      if (isSetPe()) {
8002
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
8003
        if (lastComparison != 0) {
8004
          return lastComparison;
8005
        }
420 ashish 8006
      }
8007
      return 0;
8008
    }
8009
 
3430 rajveer 8010
    public _Fields fieldForId(int fieldId) {
8011
      return _Fields.findByThriftId(fieldId);
8012
    }
8013
 
8014
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8015
      org.apache.thrift.protocol.TField field;
420 ashish 8016
      iprot.readStructBegin();
8017
      while (true)
8018
      {
8019
        field = iprot.readFieldBegin();
3430 rajveer 8020
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 8021
          break;
8022
        }
3430 rajveer 8023
        switch (field.id) {
8024
          case 0: // SUCCESS
8025
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8026
              this.success = new Payment();
8027
              this.success.read(iprot);
8028
            } else { 
8029
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8030
            }
8031
            break;
8032
          case 1: // PE
8033
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8034
              this.pe = new PaymentException();
8035
              this.pe.read(iprot);
8036
            } else { 
8037
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8038
            }
8039
            break;
8040
          default:
8041
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 8042
        }
3430 rajveer 8043
        iprot.readFieldEnd();
420 ashish 8044
      }
8045
      iprot.readStructEnd();
8046
      validate();
8047
    }
8048
 
3430 rajveer 8049
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 8050
      oprot.writeStructBegin(STRUCT_DESC);
8051
 
695 rajveer 8052
      if (this.isSetSuccess()) {
8053
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8054
        this.success.write(oprot);
8055
        oprot.writeFieldEnd();
8056
      } else if (this.isSetPe()) {
420 ashish 8057
        oprot.writeFieldBegin(PE_FIELD_DESC);
8058
        this.pe.write(oprot);
8059
        oprot.writeFieldEnd();
8060
      }
8061
      oprot.writeFieldStop();
8062
      oprot.writeStructEnd();
8063
    }
8064
 
8065
    @Override
8066
    public String toString() {
695 rajveer 8067
      StringBuilder sb = new StringBuilder("getPayment_result(");
420 ashish 8068
      boolean first = true;
8069
 
695 rajveer 8070
      sb.append("success:");
8071
      if (this.success == null) {
8072
        sb.append("null");
8073
      } else {
8074
        sb.append(this.success);
8075
      }
8076
      first = false;
8077
      if (!first) sb.append(", ");
420 ashish 8078
      sb.append("pe:");
8079
      if (this.pe == null) {
8080
        sb.append("null");
8081
      } else {
8082
        sb.append(this.pe);
8083
      }
8084
      first = false;
8085
      sb.append(")");
8086
      return sb.toString();
8087
    }
8088
 
3430 rajveer 8089
    public void validate() throws org.apache.thrift.TException {
420 ashish 8090
      // check for required fields
8091
    }
8092
 
3430 rajveer 8093
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8094
      try {
8095
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8096
      } catch (org.apache.thrift.TException te) {
8097
        throw new java.io.IOException(te);
8098
      }
8099
    }
8100
 
8101
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8102
      try {
8103
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8104
      } catch (org.apache.thrift.TException te) {
8105
        throw new java.io.IOException(te);
8106
      }
8107
    }
8108
 
420 ashish 8109
  }
8110
 
3430 rajveer 8111
  public static class getPaymentForTxnId_args implements org.apache.thrift.TBase<getPaymentForTxnId_args, getPaymentForTxnId_args._Fields>, java.io.Serializable, Cloneable   {
8112
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForTxnId_args");
420 ashish 8113
 
3430 rajveer 8114
    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 8115
 
3430 rajveer 8116
    private long txnId; // required
420 ashish 8117
 
8118
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 8119
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 8120
      TXN_ID((short)1, "txnId");
420 ashish 8121
 
8122
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8123
 
8124
      static {
8125
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8126
          byName.put(field.getFieldName(), field);
8127
        }
8128
      }
8129
 
8130
      /**
8131
       * Find the _Fields constant that matches fieldId, or null if its not found.
8132
       */
8133
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 8134
        switch(fieldId) {
8135
          case 1: // TXN_ID
8136
            return TXN_ID;
8137
          default:
8138
            return null;
8139
        }
420 ashish 8140
      }
8141
 
8142
      /**
8143
       * Find the _Fields constant that matches fieldId, throwing an exception
8144
       * if it is not found.
8145
       */
8146
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8147
        _Fields fields = findByThriftId(fieldId);
8148
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8149
        return fields;
8150
      }
8151
 
8152
      /**
8153
       * Find the _Fields constant that matches name, or null if its not found.
8154
       */
8155
      public static _Fields findByName(String name) {
8156
        return byName.get(name);
8157
      }
8158
 
8159
      private final short _thriftId;
8160
      private final String _fieldName;
8161
 
8162
      _Fields(short thriftId, String fieldName) {
8163
        _thriftId = thriftId;
8164
        _fieldName = fieldName;
8165
      }
8166
 
8167
      public short getThriftFieldId() {
8168
        return _thriftId;
8169
      }
8170
 
8171
      public String getFieldName() {
8172
        return _fieldName;
8173
      }
8174
    }
8175
 
8176
    // isset id assignments
695 rajveer 8177
    private static final int __TXNID_ISSET_ID = 0;
420 ashish 8178
    private BitSet __isset_bit_vector = new BitSet(1);
8179
 
3430 rajveer 8180
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 8181
    static {
3430 rajveer 8182
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8183
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8184
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8185
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8186
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForTxnId_args.class, metaDataMap);
420 ashish 8187
    }
8188
 
695 rajveer 8189
    public getPaymentForTxnId_args() {
420 ashish 8190
    }
8191
 
695 rajveer 8192
    public getPaymentForTxnId_args(
8193
      long txnId)
420 ashish 8194
    {
8195
      this();
695 rajveer 8196
      this.txnId = txnId;
8197
      setTxnIdIsSet(true);
420 ashish 8198
    }
8199
 
8200
    /**
8201
     * Performs a deep copy on <i>other</i>.
8202
     */
695 rajveer 8203
    public getPaymentForTxnId_args(getPaymentForTxnId_args other) {
420 ashish 8204
      __isset_bit_vector.clear();
8205
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 8206
      this.txnId = other.txnId;
420 ashish 8207
    }
8208
 
695 rajveer 8209
    public getPaymentForTxnId_args deepCopy() {
8210
      return new getPaymentForTxnId_args(this);
420 ashish 8211
    }
8212
 
3430 rajveer 8213
    @Override
8214
    public void clear() {
8215
      setTxnIdIsSet(false);
8216
      this.txnId = 0;
420 ashish 8217
    }
8218
 
695 rajveer 8219
    public long getTxnId() {
8220
      return this.txnId;
420 ashish 8221
    }
8222
 
3430 rajveer 8223
    public void setTxnId(long txnId) {
695 rajveer 8224
      this.txnId = txnId;
8225
      setTxnIdIsSet(true);
420 ashish 8226
    }
8227
 
695 rajveer 8228
    public void unsetTxnId() {
8229
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
420 ashish 8230
    }
8231
 
3430 rajveer 8232
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
695 rajveer 8233
    public boolean isSetTxnId() {
8234
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
420 ashish 8235
    }
8236
 
695 rajveer 8237
    public void setTxnIdIsSet(boolean value) {
8238
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
420 ashish 8239
    }
8240
 
8241
    public void setFieldValue(_Fields field, Object value) {
8242
      switch (field) {
695 rajveer 8243
      case TXN_ID:
420 ashish 8244
        if (value == null) {
695 rajveer 8245
          unsetTxnId();
420 ashish 8246
        } else {
695 rajveer 8247
          setTxnId((Long)value);
420 ashish 8248
        }
8249
        break;
8250
 
8251
      }
8252
    }
8253
 
8254
    public Object getFieldValue(_Fields field) {
8255
      switch (field) {
695 rajveer 8256
      case TXN_ID:
3430 rajveer 8257
        return Long.valueOf(getTxnId());
420 ashish 8258
 
8259
      }
8260
      throw new IllegalStateException();
8261
    }
8262
 
3430 rajveer 8263
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8264
    public boolean isSet(_Fields field) {
8265
      if (field == null) {
8266
        throw new IllegalArgumentException();
8267
      }
420 ashish 8268
 
8269
      switch (field) {
695 rajveer 8270
      case TXN_ID:
8271
        return isSetTxnId();
420 ashish 8272
      }
8273
      throw new IllegalStateException();
8274
    }
8275
 
8276
    @Override
8277
    public boolean equals(Object that) {
8278
      if (that == null)
8279
        return false;
695 rajveer 8280
      if (that instanceof getPaymentForTxnId_args)
8281
        return this.equals((getPaymentForTxnId_args)that);
420 ashish 8282
      return false;
8283
    }
8284
 
695 rajveer 8285
    public boolean equals(getPaymentForTxnId_args that) {
420 ashish 8286
      if (that == null)
8287
        return false;
8288
 
695 rajveer 8289
      boolean this_present_txnId = true;
8290
      boolean that_present_txnId = true;
8291
      if (this_present_txnId || that_present_txnId) {
8292
        if (!(this_present_txnId && that_present_txnId))
420 ashish 8293
          return false;
695 rajveer 8294
        if (this.txnId != that.txnId)
420 ashish 8295
          return false;
8296
      }
8297
 
8298
      return true;
8299
    }
8300
 
8301
    @Override
8302
    public int hashCode() {
8303
      return 0;
8304
    }
8305
 
695 rajveer 8306
    public int compareTo(getPaymentForTxnId_args other) {
420 ashish 8307
      if (!getClass().equals(other.getClass())) {
8308
        return getClass().getName().compareTo(other.getClass().getName());
8309
      }
8310
 
8311
      int lastComparison = 0;
695 rajveer 8312
      getPaymentForTxnId_args typedOther = (getPaymentForTxnId_args)other;
420 ashish 8313
 
3430 rajveer 8314
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
420 ashish 8315
      if (lastComparison != 0) {
8316
        return lastComparison;
8317
      }
3430 rajveer 8318
      if (isSetTxnId()) {
8319
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
8320
        if (lastComparison != 0) {
8321
          return lastComparison;
8322
        }
420 ashish 8323
      }
8324
      return 0;
8325
    }
8326
 
3430 rajveer 8327
    public _Fields fieldForId(int fieldId) {
8328
      return _Fields.findByThriftId(fieldId);
8329
    }
8330
 
8331
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8332
      org.apache.thrift.protocol.TField field;
420 ashish 8333
      iprot.readStructBegin();
8334
      while (true)
8335
      {
8336
        field = iprot.readFieldBegin();
3430 rajveer 8337
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 8338
          break;
8339
        }
3430 rajveer 8340
        switch (field.id) {
8341
          case 1: // TXN_ID
8342
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8343
              this.txnId = iprot.readI64();
8344
              setTxnIdIsSet(true);
8345
            } else { 
8346
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8347
            }
8348
            break;
8349
          default:
8350
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 8351
        }
3430 rajveer 8352
        iprot.readFieldEnd();
420 ashish 8353
      }
8354
      iprot.readStructEnd();
8355
      validate();
8356
    }
8357
 
3430 rajveer 8358
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 8359
      validate();
8360
 
8361
      oprot.writeStructBegin(STRUCT_DESC);
695 rajveer 8362
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
8363
      oprot.writeI64(this.txnId);
420 ashish 8364
      oprot.writeFieldEnd();
8365
      oprot.writeFieldStop();
8366
      oprot.writeStructEnd();
8367
    }
8368
 
8369
    @Override
8370
    public String toString() {
695 rajveer 8371
      StringBuilder sb = new StringBuilder("getPaymentForTxnId_args(");
420 ashish 8372
      boolean first = true;
8373
 
695 rajveer 8374
      sb.append("txnId:");
8375
      sb.append(this.txnId);
420 ashish 8376
      first = false;
8377
      sb.append(")");
8378
      return sb.toString();
8379
    }
8380
 
3430 rajveer 8381
    public void validate() throws org.apache.thrift.TException {
420 ashish 8382
      // check for required fields
8383
    }
8384
 
3430 rajveer 8385
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8386
      try {
8387
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8388
      } catch (org.apache.thrift.TException te) {
8389
        throw new java.io.IOException(te);
8390
      }
8391
    }
8392
 
8393
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8394
      try {
8395
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8396
        __isset_bit_vector = new BitSet(1);
8397
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8398
      } catch (org.apache.thrift.TException te) {
8399
        throw new java.io.IOException(te);
8400
      }
8401
    }
8402
 
420 ashish 8403
  }
8404
 
3430 rajveer 8405
  public static class getPaymentForTxnId_result implements org.apache.thrift.TBase<getPaymentForTxnId_result, getPaymentForTxnId_result._Fields>, java.io.Serializable, Cloneable   {
8406
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForTxnId_result");
420 ashish 8407
 
3430 rajveer 8408
    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);
8409
    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 8410
 
3430 rajveer 8411
    private List<Payment> success; // required
8412
    private PaymentException pe; // required
420 ashish 8413
 
8414
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 8415
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 8416
      SUCCESS((short)0, "success"),
8417
      PE((short)1, "pe");
8418
 
8419
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8420
 
8421
      static {
8422
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8423
          byName.put(field.getFieldName(), field);
8424
        }
8425
      }
8426
 
8427
      /**
8428
       * Find the _Fields constant that matches fieldId, or null if its not found.
8429
       */
8430
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 8431
        switch(fieldId) {
8432
          case 0: // SUCCESS
8433
            return SUCCESS;
8434
          case 1: // PE
8435
            return PE;
8436
          default:
8437
            return null;
8438
        }
420 ashish 8439
      }
8440
 
8441
      /**
8442
       * Find the _Fields constant that matches fieldId, throwing an exception
8443
       * if it is not found.
8444
       */
8445
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8446
        _Fields fields = findByThriftId(fieldId);
8447
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8448
        return fields;
8449
      }
8450
 
8451
      /**
8452
       * Find the _Fields constant that matches name, or null if its not found.
8453
       */
8454
      public static _Fields findByName(String name) {
8455
        return byName.get(name);
8456
      }
8457
 
8458
      private final short _thriftId;
8459
      private final String _fieldName;
8460
 
8461
      _Fields(short thriftId, String fieldName) {
8462
        _thriftId = thriftId;
8463
        _fieldName = fieldName;
8464
      }
8465
 
8466
      public short getThriftFieldId() {
8467
        return _thriftId;
8468
      }
8469
 
8470
      public String getFieldName() {
8471
        return _fieldName;
8472
      }
8473
    }
8474
 
8475
    // isset id assignments
8476
 
3430 rajveer 8477
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 8478
    static {
3430 rajveer 8479
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8480
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8481
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
8482
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
8483
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8484
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8485
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8486
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForTxnId_result.class, metaDataMap);
420 ashish 8487
    }
8488
 
695 rajveer 8489
    public getPaymentForTxnId_result() {
420 ashish 8490
    }
8491
 
695 rajveer 8492
    public getPaymentForTxnId_result(
8493
      List<Payment> success,
420 ashish 8494
      PaymentException pe)
8495
    {
8496
      this();
8497
      this.success = success;
8498
      this.pe = pe;
8499
    }
8500
 
8501
    /**
8502
     * Performs a deep copy on <i>other</i>.
8503
     */
695 rajveer 8504
    public getPaymentForTxnId_result(getPaymentForTxnId_result other) {
420 ashish 8505
      if (other.isSetSuccess()) {
695 rajveer 8506
        List<Payment> __this__success = new ArrayList<Payment>();
8507
        for (Payment other_element : other.success) {
8508
          __this__success.add(new Payment(other_element));
8509
        }
8510
        this.success = __this__success;
420 ashish 8511
      }
8512
      if (other.isSetPe()) {
8513
        this.pe = new PaymentException(other.pe);
8514
      }
8515
    }
8516
 
695 rajveer 8517
    public getPaymentForTxnId_result deepCopy() {
8518
      return new getPaymentForTxnId_result(this);
420 ashish 8519
    }
8520
 
3430 rajveer 8521
    @Override
8522
    public void clear() {
8523
      this.success = null;
8524
      this.pe = null;
420 ashish 8525
    }
8526
 
695 rajveer 8527
    public int getSuccessSize() {
8528
      return (this.success == null) ? 0 : this.success.size();
8529
    }
8530
 
8531
    public java.util.Iterator<Payment> getSuccessIterator() {
8532
      return (this.success == null) ? null : this.success.iterator();
8533
    }
8534
 
8535
    public void addToSuccess(Payment elem) {
8536
      if (this.success == null) {
8537
        this.success = new ArrayList<Payment>();
8538
      }
8539
      this.success.add(elem);
8540
    }
8541
 
8542
    public List<Payment> getSuccess() {
420 ashish 8543
      return this.success;
8544
    }
8545
 
3430 rajveer 8546
    public void setSuccess(List<Payment> success) {
420 ashish 8547
      this.success = success;
8548
    }
8549
 
8550
    public void unsetSuccess() {
8551
      this.success = null;
8552
    }
8553
 
3430 rajveer 8554
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 8555
    public boolean isSetSuccess() {
8556
      return this.success != null;
8557
    }
8558
 
8559
    public void setSuccessIsSet(boolean value) {
8560
      if (!value) {
8561
        this.success = null;
8562
      }
8563
    }
8564
 
8565
    public PaymentException getPe() {
8566
      return this.pe;
8567
    }
8568
 
3430 rajveer 8569
    public void setPe(PaymentException pe) {
420 ashish 8570
      this.pe = pe;
8571
    }
8572
 
8573
    public void unsetPe() {
8574
      this.pe = null;
8575
    }
8576
 
3430 rajveer 8577
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 8578
    public boolean isSetPe() {
8579
      return this.pe != null;
8580
    }
8581
 
8582
    public void setPeIsSet(boolean value) {
8583
      if (!value) {
8584
        this.pe = null;
8585
      }
8586
    }
8587
 
8588
    public void setFieldValue(_Fields field, Object value) {
8589
      switch (field) {
8590
      case SUCCESS:
8591
        if (value == null) {
8592
          unsetSuccess();
8593
        } else {
695 rajveer 8594
          setSuccess((List<Payment>)value);
420 ashish 8595
        }
8596
        break;
8597
 
8598
      case PE:
8599
        if (value == null) {
8600
          unsetPe();
8601
        } else {
8602
          setPe((PaymentException)value);
8603
        }
8604
        break;
8605
 
8606
      }
8607
    }
8608
 
8609
    public Object getFieldValue(_Fields field) {
8610
      switch (field) {
8611
      case SUCCESS:
8612
        return getSuccess();
8613
 
8614
      case PE:
8615
        return getPe();
8616
 
8617
      }
8618
      throw new IllegalStateException();
8619
    }
8620
 
3430 rajveer 8621
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8622
    public boolean isSet(_Fields field) {
8623
      if (field == null) {
8624
        throw new IllegalArgumentException();
8625
      }
420 ashish 8626
 
8627
      switch (field) {
8628
      case SUCCESS:
8629
        return isSetSuccess();
8630
      case PE:
8631
        return isSetPe();
8632
      }
8633
      throw new IllegalStateException();
8634
    }
8635
 
8636
    @Override
8637
    public boolean equals(Object that) {
8638
      if (that == null)
8639
        return false;
695 rajveer 8640
      if (that instanceof getPaymentForTxnId_result)
8641
        return this.equals((getPaymentForTxnId_result)that);
420 ashish 8642
      return false;
8643
    }
8644
 
695 rajveer 8645
    public boolean equals(getPaymentForTxnId_result that) {
420 ashish 8646
      if (that == null)
8647
        return false;
8648
 
8649
      boolean this_present_success = true && this.isSetSuccess();
8650
      boolean that_present_success = true && that.isSetSuccess();
8651
      if (this_present_success || that_present_success) {
8652
        if (!(this_present_success && that_present_success))
8653
          return false;
8654
        if (!this.success.equals(that.success))
8655
          return false;
8656
      }
8657
 
8658
      boolean this_present_pe = true && this.isSetPe();
8659
      boolean that_present_pe = true && that.isSetPe();
8660
      if (this_present_pe || that_present_pe) {
8661
        if (!(this_present_pe && that_present_pe))
8662
          return false;
8663
        if (!this.pe.equals(that.pe))
8664
          return false;
8665
      }
8666
 
8667
      return true;
8668
    }
8669
 
8670
    @Override
8671
    public int hashCode() {
8672
      return 0;
8673
    }
8674
 
695 rajveer 8675
    public int compareTo(getPaymentForTxnId_result other) {
8676
      if (!getClass().equals(other.getClass())) {
8677
        return getClass().getName().compareTo(other.getClass().getName());
8678
      }
8679
 
8680
      int lastComparison = 0;
8681
      getPaymentForTxnId_result typedOther = (getPaymentForTxnId_result)other;
8682
 
3430 rajveer 8683
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 8684
      if (lastComparison != 0) {
8685
        return lastComparison;
8686
      }
3430 rajveer 8687
      if (isSetSuccess()) {
8688
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8689
        if (lastComparison != 0) {
8690
          return lastComparison;
8691
        }
695 rajveer 8692
      }
3430 rajveer 8693
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 8694
      if (lastComparison != 0) {
8695
        return lastComparison;
8696
      }
3430 rajveer 8697
      if (isSetPe()) {
8698
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
8699
        if (lastComparison != 0) {
8700
          return lastComparison;
8701
        }
695 rajveer 8702
      }
8703
      return 0;
8704
    }
8705
 
3430 rajveer 8706
    public _Fields fieldForId(int fieldId) {
8707
      return _Fields.findByThriftId(fieldId);
8708
    }
8709
 
8710
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8711
      org.apache.thrift.protocol.TField field;
420 ashish 8712
      iprot.readStructBegin();
8713
      while (true)
8714
      {
8715
        field = iprot.readFieldBegin();
3430 rajveer 8716
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 8717
          break;
8718
        }
3430 rajveer 8719
        switch (field.id) {
8720
          case 0: // SUCCESS
8721
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
8722
              {
4600 varun.gupt 8723
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
8724
                this.success = new ArrayList<Payment>(_list28.size);
8725
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
695 rajveer 8726
                {
4600 varun.gupt 8727
                  Payment _elem30; // required
8728
                  _elem30 = new Payment();
8729
                  _elem30.read(iprot);
8730
                  this.success.add(_elem30);
695 rajveer 8731
                }
3430 rajveer 8732
                iprot.readListEnd();
420 ashish 8733
              }
3430 rajveer 8734
            } else { 
8735
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8736
            }
8737
            break;
8738
          case 1: // PE
8739
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8740
              this.pe = new PaymentException();
8741
              this.pe.read(iprot);
8742
            } else { 
8743
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8744
            }
8745
            break;
8746
          default:
8747
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 8748
        }
3430 rajveer 8749
        iprot.readFieldEnd();
420 ashish 8750
      }
8751
      iprot.readStructEnd();
8752
      validate();
8753
    }
8754
 
3430 rajveer 8755
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 8756
      oprot.writeStructBegin(STRUCT_DESC);
8757
 
8758
      if (this.isSetSuccess()) {
8759
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
695 rajveer 8760
        {
3430 rajveer 8761
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
4600 varun.gupt 8762
          for (Payment _iter31 : this.success)
695 rajveer 8763
          {
4600 varun.gupt 8764
            _iter31.write(oprot);
695 rajveer 8765
          }
8766
          oprot.writeListEnd();
8767
        }
420 ashish 8768
        oprot.writeFieldEnd();
8769
      } else if (this.isSetPe()) {
8770
        oprot.writeFieldBegin(PE_FIELD_DESC);
8771
        this.pe.write(oprot);
8772
        oprot.writeFieldEnd();
8773
      }
8774
      oprot.writeFieldStop();
8775
      oprot.writeStructEnd();
8776
    }
8777
 
8778
    @Override
8779
    public String toString() {
695 rajveer 8780
      StringBuilder sb = new StringBuilder("getPaymentForTxnId_result(");
420 ashish 8781
      boolean first = true;
8782
 
8783
      sb.append("success:");
8784
      if (this.success == null) {
8785
        sb.append("null");
8786
      } else {
8787
        sb.append(this.success);
8788
      }
8789
      first = false;
8790
      if (!first) sb.append(", ");
8791
      sb.append("pe:");
8792
      if (this.pe == null) {
8793
        sb.append("null");
8794
      } else {
8795
        sb.append(this.pe);
8796
      }
8797
      first = false;
8798
      sb.append(")");
8799
      return sb.toString();
8800
    }
8801
 
3430 rajveer 8802
    public void validate() throws org.apache.thrift.TException {
420 ashish 8803
      // check for required fields
8804
    }
8805
 
3430 rajveer 8806
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8807
      try {
8808
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8809
      } catch (org.apache.thrift.TException te) {
8810
        throw new java.io.IOException(te);
8811
      }
8812
    }
8813
 
8814
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8815
      try {
8816
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8817
      } catch (org.apache.thrift.TException te) {
8818
        throw new java.io.IOException(te);
8819
      }
8820
    }
8821
 
420 ashish 8822
  }
8823
 
7049 anupam.sin 8824
  public static class getPaymentForRechargeTxnId_args implements org.apache.thrift.TBase<getPaymentForRechargeTxnId_args, getPaymentForRechargeTxnId_args._Fields>, java.io.Serializable, Cloneable   {
8825
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForRechargeTxnId_args");
8826
 
8827
    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);
8828
 
8829
    private long txnId; // required
8830
 
8831
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8832
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8833
      TXN_ID((short)1, "txnId");
8834
 
8835
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8836
 
8837
      static {
8838
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8839
          byName.put(field.getFieldName(), field);
8840
        }
8841
      }
8842
 
8843
      /**
8844
       * Find the _Fields constant that matches fieldId, or null if its not found.
8845
       */
8846
      public static _Fields findByThriftId(int fieldId) {
8847
        switch(fieldId) {
8848
          case 1: // TXN_ID
8849
            return TXN_ID;
8850
          default:
8851
            return null;
8852
        }
8853
      }
8854
 
8855
      /**
8856
       * Find the _Fields constant that matches fieldId, throwing an exception
8857
       * if it is not found.
8858
       */
8859
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8860
        _Fields fields = findByThriftId(fieldId);
8861
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8862
        return fields;
8863
      }
8864
 
8865
      /**
8866
       * Find the _Fields constant that matches name, or null if its not found.
8867
       */
8868
      public static _Fields findByName(String name) {
8869
        return byName.get(name);
8870
      }
8871
 
8872
      private final short _thriftId;
8873
      private final String _fieldName;
8874
 
8875
      _Fields(short thriftId, String fieldName) {
8876
        _thriftId = thriftId;
8877
        _fieldName = fieldName;
8878
      }
8879
 
8880
      public short getThriftFieldId() {
8881
        return _thriftId;
8882
      }
8883
 
8884
      public String getFieldName() {
8885
        return _fieldName;
8886
      }
8887
    }
8888
 
8889
    // isset id assignments
8890
    private static final int __TXNID_ISSET_ID = 0;
8891
    private BitSet __isset_bit_vector = new BitSet(1);
8892
 
8893
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8894
    static {
8895
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8896
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8897
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8898
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8899
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForRechargeTxnId_args.class, metaDataMap);
8900
    }
8901
 
8902
    public getPaymentForRechargeTxnId_args() {
8903
    }
8904
 
8905
    public getPaymentForRechargeTxnId_args(
8906
      long txnId)
8907
    {
8908
      this();
8909
      this.txnId = txnId;
8910
      setTxnIdIsSet(true);
8911
    }
8912
 
8913
    /**
8914
     * Performs a deep copy on <i>other</i>.
8915
     */
8916
    public getPaymentForRechargeTxnId_args(getPaymentForRechargeTxnId_args other) {
8917
      __isset_bit_vector.clear();
8918
      __isset_bit_vector.or(other.__isset_bit_vector);
8919
      this.txnId = other.txnId;
8920
    }
8921
 
8922
    public getPaymentForRechargeTxnId_args deepCopy() {
8923
      return new getPaymentForRechargeTxnId_args(this);
8924
    }
8925
 
8926
    @Override
8927
    public void clear() {
8928
      setTxnIdIsSet(false);
8929
      this.txnId = 0;
8930
    }
8931
 
8932
    public long getTxnId() {
8933
      return this.txnId;
8934
    }
8935
 
8936
    public void setTxnId(long txnId) {
8937
      this.txnId = txnId;
8938
      setTxnIdIsSet(true);
8939
    }
8940
 
8941
    public void unsetTxnId() {
8942
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
8943
    }
8944
 
8945
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
8946
    public boolean isSetTxnId() {
8947
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
8948
    }
8949
 
8950
    public void setTxnIdIsSet(boolean value) {
8951
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
8952
    }
8953
 
8954
    public void setFieldValue(_Fields field, Object value) {
8955
      switch (field) {
8956
      case TXN_ID:
8957
        if (value == null) {
8958
          unsetTxnId();
8959
        } else {
8960
          setTxnId((Long)value);
8961
        }
8962
        break;
8963
 
8964
      }
8965
    }
8966
 
8967
    public Object getFieldValue(_Fields field) {
8968
      switch (field) {
8969
      case TXN_ID:
8970
        return Long.valueOf(getTxnId());
8971
 
8972
      }
8973
      throw new IllegalStateException();
8974
    }
8975
 
8976
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8977
    public boolean isSet(_Fields field) {
8978
      if (field == null) {
8979
        throw new IllegalArgumentException();
8980
      }
8981
 
8982
      switch (field) {
8983
      case TXN_ID:
8984
        return isSetTxnId();
8985
      }
8986
      throw new IllegalStateException();
8987
    }
8988
 
8989
    @Override
8990
    public boolean equals(Object that) {
8991
      if (that == null)
8992
        return false;
8993
      if (that instanceof getPaymentForRechargeTxnId_args)
8994
        return this.equals((getPaymentForRechargeTxnId_args)that);
8995
      return false;
8996
    }
8997
 
8998
    public boolean equals(getPaymentForRechargeTxnId_args that) {
8999
      if (that == null)
9000
        return false;
9001
 
9002
      boolean this_present_txnId = true;
9003
      boolean that_present_txnId = true;
9004
      if (this_present_txnId || that_present_txnId) {
9005
        if (!(this_present_txnId && that_present_txnId))
9006
          return false;
9007
        if (this.txnId != that.txnId)
9008
          return false;
9009
      }
9010
 
9011
      return true;
9012
    }
9013
 
9014
    @Override
9015
    public int hashCode() {
9016
      return 0;
9017
    }
9018
 
9019
    public int compareTo(getPaymentForRechargeTxnId_args other) {
9020
      if (!getClass().equals(other.getClass())) {
9021
        return getClass().getName().compareTo(other.getClass().getName());
9022
      }
9023
 
9024
      int lastComparison = 0;
9025
      getPaymentForRechargeTxnId_args typedOther = (getPaymentForRechargeTxnId_args)other;
9026
 
9027
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
9028
      if (lastComparison != 0) {
9029
        return lastComparison;
9030
      }
9031
      if (isSetTxnId()) {
9032
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
9033
        if (lastComparison != 0) {
9034
          return lastComparison;
9035
        }
9036
      }
9037
      return 0;
9038
    }
9039
 
9040
    public _Fields fieldForId(int fieldId) {
9041
      return _Fields.findByThriftId(fieldId);
9042
    }
9043
 
9044
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9045
      org.apache.thrift.protocol.TField field;
9046
      iprot.readStructBegin();
9047
      while (true)
9048
      {
9049
        field = iprot.readFieldBegin();
9050
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9051
          break;
9052
        }
9053
        switch (field.id) {
9054
          case 1: // TXN_ID
9055
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9056
              this.txnId = iprot.readI64();
9057
              setTxnIdIsSet(true);
9058
            } else { 
9059
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9060
            }
9061
            break;
9062
          default:
9063
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9064
        }
9065
        iprot.readFieldEnd();
9066
      }
9067
      iprot.readStructEnd();
9068
      validate();
9069
    }
9070
 
9071
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9072
      validate();
9073
 
9074
      oprot.writeStructBegin(STRUCT_DESC);
9075
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
9076
      oprot.writeI64(this.txnId);
9077
      oprot.writeFieldEnd();
9078
      oprot.writeFieldStop();
9079
      oprot.writeStructEnd();
9080
    }
9081
 
9082
    @Override
9083
    public String toString() {
9084
      StringBuilder sb = new StringBuilder("getPaymentForRechargeTxnId_args(");
9085
      boolean first = true;
9086
 
9087
      sb.append("txnId:");
9088
      sb.append(this.txnId);
9089
      first = false;
9090
      sb.append(")");
9091
      return sb.toString();
9092
    }
9093
 
9094
    public void validate() throws org.apache.thrift.TException {
9095
      // check for required fields
9096
    }
9097
 
9098
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9099
      try {
9100
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9101
      } catch (org.apache.thrift.TException te) {
9102
        throw new java.io.IOException(te);
9103
      }
9104
    }
9105
 
9106
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9107
      try {
9108
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
9109
        __isset_bit_vector = new BitSet(1);
9110
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9111
      } catch (org.apache.thrift.TException te) {
9112
        throw new java.io.IOException(te);
9113
      }
9114
    }
9115
 
9116
  }
9117
 
9118
  public static class getPaymentForRechargeTxnId_result implements org.apache.thrift.TBase<getPaymentForRechargeTxnId_result, getPaymentForRechargeTxnId_result._Fields>, java.io.Serializable, Cloneable   {
9119
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForRechargeTxnId_result");
9120
 
9121
    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);
9122
    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);
9123
 
9124
    private List<Payment> success; // required
9125
    private PaymentException pe; // required
9126
 
9127
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9128
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9129
      SUCCESS((short)0, "success"),
9130
      PE((short)1, "pe");
9131
 
9132
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9133
 
9134
      static {
9135
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9136
          byName.put(field.getFieldName(), field);
9137
        }
9138
      }
9139
 
9140
      /**
9141
       * Find the _Fields constant that matches fieldId, or null if its not found.
9142
       */
9143
      public static _Fields findByThriftId(int fieldId) {
9144
        switch(fieldId) {
9145
          case 0: // SUCCESS
9146
            return SUCCESS;
9147
          case 1: // PE
9148
            return PE;
9149
          default:
9150
            return null;
9151
        }
9152
      }
9153
 
9154
      /**
9155
       * Find the _Fields constant that matches fieldId, throwing an exception
9156
       * if it is not found.
9157
       */
9158
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9159
        _Fields fields = findByThriftId(fieldId);
9160
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9161
        return fields;
9162
      }
9163
 
9164
      /**
9165
       * Find the _Fields constant that matches name, or null if its not found.
9166
       */
9167
      public static _Fields findByName(String name) {
9168
        return byName.get(name);
9169
      }
9170
 
9171
      private final short _thriftId;
9172
      private final String _fieldName;
9173
 
9174
      _Fields(short thriftId, String fieldName) {
9175
        _thriftId = thriftId;
9176
        _fieldName = fieldName;
9177
      }
9178
 
9179
      public short getThriftFieldId() {
9180
        return _thriftId;
9181
      }
9182
 
9183
      public String getFieldName() {
9184
        return _fieldName;
9185
      }
9186
    }
9187
 
9188
    // isset id assignments
9189
 
9190
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9191
    static {
9192
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9193
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9194
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9195
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
9196
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9197
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9198
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9199
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForRechargeTxnId_result.class, metaDataMap);
9200
    }
9201
 
9202
    public getPaymentForRechargeTxnId_result() {
9203
    }
9204
 
9205
    public getPaymentForRechargeTxnId_result(
9206
      List<Payment> success,
9207
      PaymentException pe)
9208
    {
9209
      this();
9210
      this.success = success;
9211
      this.pe = pe;
9212
    }
9213
 
9214
    /**
9215
     * Performs a deep copy on <i>other</i>.
9216
     */
9217
    public getPaymentForRechargeTxnId_result(getPaymentForRechargeTxnId_result other) {
9218
      if (other.isSetSuccess()) {
9219
        List<Payment> __this__success = new ArrayList<Payment>();
9220
        for (Payment other_element : other.success) {
9221
          __this__success.add(new Payment(other_element));
9222
        }
9223
        this.success = __this__success;
9224
      }
9225
      if (other.isSetPe()) {
9226
        this.pe = new PaymentException(other.pe);
9227
      }
9228
    }
9229
 
9230
    public getPaymentForRechargeTxnId_result deepCopy() {
9231
      return new getPaymentForRechargeTxnId_result(this);
9232
    }
9233
 
9234
    @Override
9235
    public void clear() {
9236
      this.success = null;
9237
      this.pe = null;
9238
    }
9239
 
9240
    public int getSuccessSize() {
9241
      return (this.success == null) ? 0 : this.success.size();
9242
    }
9243
 
9244
    public java.util.Iterator<Payment> getSuccessIterator() {
9245
      return (this.success == null) ? null : this.success.iterator();
9246
    }
9247
 
9248
    public void addToSuccess(Payment elem) {
9249
      if (this.success == null) {
9250
        this.success = new ArrayList<Payment>();
9251
      }
9252
      this.success.add(elem);
9253
    }
9254
 
9255
    public List<Payment> getSuccess() {
9256
      return this.success;
9257
    }
9258
 
9259
    public void setSuccess(List<Payment> success) {
9260
      this.success = success;
9261
    }
9262
 
9263
    public void unsetSuccess() {
9264
      this.success = null;
9265
    }
9266
 
9267
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9268
    public boolean isSetSuccess() {
9269
      return this.success != null;
9270
    }
9271
 
9272
    public void setSuccessIsSet(boolean value) {
9273
      if (!value) {
9274
        this.success = null;
9275
      }
9276
    }
9277
 
9278
    public PaymentException getPe() {
9279
      return this.pe;
9280
    }
9281
 
9282
    public void setPe(PaymentException pe) {
9283
      this.pe = pe;
9284
    }
9285
 
9286
    public void unsetPe() {
9287
      this.pe = null;
9288
    }
9289
 
9290
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
9291
    public boolean isSetPe() {
9292
      return this.pe != null;
9293
    }
9294
 
9295
    public void setPeIsSet(boolean value) {
9296
      if (!value) {
9297
        this.pe = null;
9298
      }
9299
    }
9300
 
9301
    public void setFieldValue(_Fields field, Object value) {
9302
      switch (field) {
9303
      case SUCCESS:
9304
        if (value == null) {
9305
          unsetSuccess();
9306
        } else {
9307
          setSuccess((List<Payment>)value);
9308
        }
9309
        break;
9310
 
9311
      case PE:
9312
        if (value == null) {
9313
          unsetPe();
9314
        } else {
9315
          setPe((PaymentException)value);
9316
        }
9317
        break;
9318
 
9319
      }
9320
    }
9321
 
9322
    public Object getFieldValue(_Fields field) {
9323
      switch (field) {
9324
      case SUCCESS:
9325
        return getSuccess();
9326
 
9327
      case PE:
9328
        return getPe();
9329
 
9330
      }
9331
      throw new IllegalStateException();
9332
    }
9333
 
9334
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9335
    public boolean isSet(_Fields field) {
9336
      if (field == null) {
9337
        throw new IllegalArgumentException();
9338
      }
9339
 
9340
      switch (field) {
9341
      case SUCCESS:
9342
        return isSetSuccess();
9343
      case PE:
9344
        return isSetPe();
9345
      }
9346
      throw new IllegalStateException();
9347
    }
9348
 
9349
    @Override
9350
    public boolean equals(Object that) {
9351
      if (that == null)
9352
        return false;
9353
      if (that instanceof getPaymentForRechargeTxnId_result)
9354
        return this.equals((getPaymentForRechargeTxnId_result)that);
9355
      return false;
9356
    }
9357
 
9358
    public boolean equals(getPaymentForRechargeTxnId_result that) {
9359
      if (that == null)
9360
        return false;
9361
 
9362
      boolean this_present_success = true && this.isSetSuccess();
9363
      boolean that_present_success = true && that.isSetSuccess();
9364
      if (this_present_success || that_present_success) {
9365
        if (!(this_present_success && that_present_success))
9366
          return false;
9367
        if (!this.success.equals(that.success))
9368
          return false;
9369
      }
9370
 
9371
      boolean this_present_pe = true && this.isSetPe();
9372
      boolean that_present_pe = true && that.isSetPe();
9373
      if (this_present_pe || that_present_pe) {
9374
        if (!(this_present_pe && that_present_pe))
9375
          return false;
9376
        if (!this.pe.equals(that.pe))
9377
          return false;
9378
      }
9379
 
9380
      return true;
9381
    }
9382
 
9383
    @Override
9384
    public int hashCode() {
9385
      return 0;
9386
    }
9387
 
9388
    public int compareTo(getPaymentForRechargeTxnId_result other) {
9389
      if (!getClass().equals(other.getClass())) {
9390
        return getClass().getName().compareTo(other.getClass().getName());
9391
      }
9392
 
9393
      int lastComparison = 0;
9394
      getPaymentForRechargeTxnId_result typedOther = (getPaymentForRechargeTxnId_result)other;
9395
 
9396
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9397
      if (lastComparison != 0) {
9398
        return lastComparison;
9399
      }
9400
      if (isSetSuccess()) {
9401
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9402
        if (lastComparison != 0) {
9403
          return lastComparison;
9404
        }
9405
      }
9406
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
9407
      if (lastComparison != 0) {
9408
        return lastComparison;
9409
      }
9410
      if (isSetPe()) {
9411
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
9412
        if (lastComparison != 0) {
9413
          return lastComparison;
9414
        }
9415
      }
9416
      return 0;
9417
    }
9418
 
9419
    public _Fields fieldForId(int fieldId) {
9420
      return _Fields.findByThriftId(fieldId);
9421
    }
9422
 
9423
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9424
      org.apache.thrift.protocol.TField field;
9425
      iprot.readStructBegin();
9426
      while (true)
9427
      {
9428
        field = iprot.readFieldBegin();
9429
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9430
          break;
9431
        }
9432
        switch (field.id) {
9433
          case 0: // SUCCESS
9434
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9435
              {
9436
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
9437
                this.success = new ArrayList<Payment>(_list32.size);
9438
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
9439
                {
9440
                  Payment _elem34; // required
9441
                  _elem34 = new Payment();
9442
                  _elem34.read(iprot);
9443
                  this.success.add(_elem34);
9444
                }
9445
                iprot.readListEnd();
9446
              }
9447
            } else { 
9448
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9449
            }
9450
            break;
9451
          case 1: // PE
9452
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9453
              this.pe = new PaymentException();
9454
              this.pe.read(iprot);
9455
            } else { 
9456
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9457
            }
9458
            break;
9459
          default:
9460
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9461
        }
9462
        iprot.readFieldEnd();
9463
      }
9464
      iprot.readStructEnd();
9465
      validate();
9466
    }
9467
 
9468
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9469
      oprot.writeStructBegin(STRUCT_DESC);
9470
 
9471
      if (this.isSetSuccess()) {
9472
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9473
        {
9474
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
9475
          for (Payment _iter35 : this.success)
9476
          {
9477
            _iter35.write(oprot);
9478
          }
9479
          oprot.writeListEnd();
9480
        }
9481
        oprot.writeFieldEnd();
9482
      } else if (this.isSetPe()) {
9483
        oprot.writeFieldBegin(PE_FIELD_DESC);
9484
        this.pe.write(oprot);
9485
        oprot.writeFieldEnd();
9486
      }
9487
      oprot.writeFieldStop();
9488
      oprot.writeStructEnd();
9489
    }
9490
 
9491
    @Override
9492
    public String toString() {
9493
      StringBuilder sb = new StringBuilder("getPaymentForRechargeTxnId_result(");
9494
      boolean first = true;
9495
 
9496
      sb.append("success:");
9497
      if (this.success == null) {
9498
        sb.append("null");
9499
      } else {
9500
        sb.append(this.success);
9501
      }
9502
      first = false;
9503
      if (!first) sb.append(", ");
9504
      sb.append("pe:");
9505
      if (this.pe == null) {
9506
        sb.append("null");
9507
      } else {
9508
        sb.append(this.pe);
9509
      }
9510
      first = false;
9511
      sb.append(")");
9512
      return sb.toString();
9513
    }
9514
 
9515
    public void validate() throws org.apache.thrift.TException {
9516
      // check for required fields
9517
    }
9518
 
9519
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9520
      try {
9521
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9522
      } catch (org.apache.thrift.TException te) {
9523
        throw new java.io.IOException(te);
9524
      }
9525
    }
9526
 
9527
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9528
      try {
9529
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9530
      } catch (org.apache.thrift.TException te) {
9531
        throw new java.io.IOException(te);
9532
      }
9533
    }
9534
 
9535
  }
9536
 
4600 varun.gupt 9537
  public static class getSuccessfulPaymentForTxnId_args implements org.apache.thrift.TBase<getSuccessfulPaymentForTxnId_args, getSuccessfulPaymentForTxnId_args._Fields>, java.io.Serializable, Cloneable   {
9538
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentForTxnId_args");
9539
 
9540
    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);
9541
 
9542
    private long txnId; // required
9543
 
9544
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9545
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9546
      TXN_ID((short)1, "txnId");
9547
 
9548
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9549
 
9550
      static {
9551
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9552
          byName.put(field.getFieldName(), field);
9553
        }
9554
      }
9555
 
9556
      /**
9557
       * Find the _Fields constant that matches fieldId, or null if its not found.
9558
       */
9559
      public static _Fields findByThriftId(int fieldId) {
9560
        switch(fieldId) {
9561
          case 1: // TXN_ID
9562
            return TXN_ID;
9563
          default:
9564
            return null;
9565
        }
9566
      }
9567
 
9568
      /**
9569
       * Find the _Fields constant that matches fieldId, throwing an exception
9570
       * if it is not found.
9571
       */
9572
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9573
        _Fields fields = findByThriftId(fieldId);
9574
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9575
        return fields;
9576
      }
9577
 
9578
      /**
9579
       * Find the _Fields constant that matches name, or null if its not found.
9580
       */
9581
      public static _Fields findByName(String name) {
9582
        return byName.get(name);
9583
      }
9584
 
9585
      private final short _thriftId;
9586
      private final String _fieldName;
9587
 
9588
      _Fields(short thriftId, String fieldName) {
9589
        _thriftId = thriftId;
9590
        _fieldName = fieldName;
9591
      }
9592
 
9593
      public short getThriftFieldId() {
9594
        return _thriftId;
9595
      }
9596
 
9597
      public String getFieldName() {
9598
        return _fieldName;
9599
      }
9600
    }
9601
 
9602
    // isset id assignments
9603
    private static final int __TXNID_ISSET_ID = 0;
9604
    private BitSet __isset_bit_vector = new BitSet(1);
9605
 
9606
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9607
    static {
9608
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9609
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9610
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
9611
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9612
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentForTxnId_args.class, metaDataMap);
9613
    }
9614
 
9615
    public getSuccessfulPaymentForTxnId_args() {
9616
    }
9617
 
9618
    public getSuccessfulPaymentForTxnId_args(
9619
      long txnId)
9620
    {
9621
      this();
9622
      this.txnId = txnId;
9623
      setTxnIdIsSet(true);
9624
    }
9625
 
9626
    /**
9627
     * Performs a deep copy on <i>other</i>.
9628
     */
9629
    public getSuccessfulPaymentForTxnId_args(getSuccessfulPaymentForTxnId_args other) {
9630
      __isset_bit_vector.clear();
9631
      __isset_bit_vector.or(other.__isset_bit_vector);
9632
      this.txnId = other.txnId;
9633
    }
9634
 
9635
    public getSuccessfulPaymentForTxnId_args deepCopy() {
9636
      return new getSuccessfulPaymentForTxnId_args(this);
9637
    }
9638
 
9639
    @Override
9640
    public void clear() {
9641
      setTxnIdIsSet(false);
9642
      this.txnId = 0;
9643
    }
9644
 
9645
    public long getTxnId() {
9646
      return this.txnId;
9647
    }
9648
 
9649
    public void setTxnId(long txnId) {
9650
      this.txnId = txnId;
9651
      setTxnIdIsSet(true);
9652
    }
9653
 
9654
    public void unsetTxnId() {
9655
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
9656
    }
9657
 
9658
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
9659
    public boolean isSetTxnId() {
9660
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
9661
    }
9662
 
9663
    public void setTxnIdIsSet(boolean value) {
9664
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
9665
    }
9666
 
9667
    public void setFieldValue(_Fields field, Object value) {
9668
      switch (field) {
9669
      case TXN_ID:
9670
        if (value == null) {
9671
          unsetTxnId();
9672
        } else {
9673
          setTxnId((Long)value);
9674
        }
9675
        break;
9676
 
9677
      }
9678
    }
9679
 
9680
    public Object getFieldValue(_Fields field) {
9681
      switch (field) {
9682
      case TXN_ID:
9683
        return Long.valueOf(getTxnId());
9684
 
9685
      }
9686
      throw new IllegalStateException();
9687
    }
9688
 
9689
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9690
    public boolean isSet(_Fields field) {
9691
      if (field == null) {
9692
        throw new IllegalArgumentException();
9693
      }
9694
 
9695
      switch (field) {
9696
      case TXN_ID:
9697
        return isSetTxnId();
9698
      }
9699
      throw new IllegalStateException();
9700
    }
9701
 
9702
    @Override
9703
    public boolean equals(Object that) {
9704
      if (that == null)
9705
        return false;
9706
      if (that instanceof getSuccessfulPaymentForTxnId_args)
9707
        return this.equals((getSuccessfulPaymentForTxnId_args)that);
9708
      return false;
9709
    }
9710
 
9711
    public boolean equals(getSuccessfulPaymentForTxnId_args that) {
9712
      if (that == null)
9713
        return false;
9714
 
9715
      boolean this_present_txnId = true;
9716
      boolean that_present_txnId = true;
9717
      if (this_present_txnId || that_present_txnId) {
9718
        if (!(this_present_txnId && that_present_txnId))
9719
          return false;
9720
        if (this.txnId != that.txnId)
9721
          return false;
9722
      }
9723
 
9724
      return true;
9725
    }
9726
 
9727
    @Override
9728
    public int hashCode() {
9729
      return 0;
9730
    }
9731
 
9732
    public int compareTo(getSuccessfulPaymentForTxnId_args other) {
9733
      if (!getClass().equals(other.getClass())) {
9734
        return getClass().getName().compareTo(other.getClass().getName());
9735
      }
9736
 
9737
      int lastComparison = 0;
9738
      getSuccessfulPaymentForTxnId_args typedOther = (getSuccessfulPaymentForTxnId_args)other;
9739
 
9740
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
9741
      if (lastComparison != 0) {
9742
        return lastComparison;
9743
      }
9744
      if (isSetTxnId()) {
9745
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
9746
        if (lastComparison != 0) {
9747
          return lastComparison;
9748
        }
9749
      }
9750
      return 0;
9751
    }
9752
 
9753
    public _Fields fieldForId(int fieldId) {
9754
      return _Fields.findByThriftId(fieldId);
9755
    }
9756
 
9757
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9758
      org.apache.thrift.protocol.TField field;
9759
      iprot.readStructBegin();
9760
      while (true)
9761
      {
9762
        field = iprot.readFieldBegin();
9763
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9764
          break;
9765
        }
9766
        switch (field.id) {
9767
          case 1: // TXN_ID
9768
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9769
              this.txnId = iprot.readI64();
9770
              setTxnIdIsSet(true);
9771
            } else { 
9772
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9773
            }
9774
            break;
9775
          default:
9776
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9777
        }
9778
        iprot.readFieldEnd();
9779
      }
9780
      iprot.readStructEnd();
9781
      validate();
9782
    }
9783
 
9784
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9785
      validate();
9786
 
9787
      oprot.writeStructBegin(STRUCT_DESC);
9788
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
9789
      oprot.writeI64(this.txnId);
9790
      oprot.writeFieldEnd();
9791
      oprot.writeFieldStop();
9792
      oprot.writeStructEnd();
9793
    }
9794
 
9795
    @Override
9796
    public String toString() {
9797
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentForTxnId_args(");
9798
      boolean first = true;
9799
 
9800
      sb.append("txnId:");
9801
      sb.append(this.txnId);
9802
      first = false;
9803
      sb.append(")");
9804
      return sb.toString();
9805
    }
9806
 
9807
    public void validate() throws org.apache.thrift.TException {
9808
      // check for required fields
9809
    }
9810
 
9811
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9812
      try {
9813
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9814
      } catch (org.apache.thrift.TException te) {
9815
        throw new java.io.IOException(te);
9816
      }
9817
    }
9818
 
9819
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9820
      try {
9821
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
9822
        __isset_bit_vector = new BitSet(1);
9823
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9824
      } catch (org.apache.thrift.TException te) {
9825
        throw new java.io.IOException(te);
9826
      }
9827
    }
9828
 
9829
  }
9830
 
9831
  public static class getSuccessfulPaymentForTxnId_result implements org.apache.thrift.TBase<getSuccessfulPaymentForTxnId_result, getSuccessfulPaymentForTxnId_result._Fields>, java.io.Serializable, Cloneable   {
9832
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentForTxnId_result");
9833
 
9834
    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);
9835
    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);
9836
 
9837
    private Payment success; // required
9838
    private PaymentException pe; // required
9839
 
9840
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9841
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9842
      SUCCESS((short)0, "success"),
9843
      PE((short)1, "pe");
9844
 
9845
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9846
 
9847
      static {
9848
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9849
          byName.put(field.getFieldName(), field);
9850
        }
9851
      }
9852
 
9853
      /**
9854
       * Find the _Fields constant that matches fieldId, or null if its not found.
9855
       */
9856
      public static _Fields findByThriftId(int fieldId) {
9857
        switch(fieldId) {
9858
          case 0: // SUCCESS
9859
            return SUCCESS;
9860
          case 1: // PE
9861
            return PE;
9862
          default:
9863
            return null;
9864
        }
9865
      }
9866
 
9867
      /**
9868
       * Find the _Fields constant that matches fieldId, throwing an exception
9869
       * if it is not found.
9870
       */
9871
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9872
        _Fields fields = findByThriftId(fieldId);
9873
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9874
        return fields;
9875
      }
9876
 
9877
      /**
9878
       * Find the _Fields constant that matches name, or null if its not found.
9879
       */
9880
      public static _Fields findByName(String name) {
9881
        return byName.get(name);
9882
      }
9883
 
9884
      private final short _thriftId;
9885
      private final String _fieldName;
9886
 
9887
      _Fields(short thriftId, String fieldName) {
9888
        _thriftId = thriftId;
9889
        _fieldName = fieldName;
9890
      }
9891
 
9892
      public short getThriftFieldId() {
9893
        return _thriftId;
9894
      }
9895
 
9896
      public String getFieldName() {
9897
        return _fieldName;
9898
      }
9899
    }
9900
 
9901
    // isset id assignments
9902
 
9903
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9904
    static {
9905
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9906
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9907
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class)));
9908
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9909
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9910
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9911
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentForTxnId_result.class, metaDataMap);
9912
    }
9913
 
9914
    public getSuccessfulPaymentForTxnId_result() {
9915
    }
9916
 
9917
    public getSuccessfulPaymentForTxnId_result(
9918
      Payment success,
9919
      PaymentException pe)
9920
    {
9921
      this();
9922
      this.success = success;
9923
      this.pe = pe;
9924
    }
9925
 
9926
    /**
9927
     * Performs a deep copy on <i>other</i>.
9928
     */
9929
    public getSuccessfulPaymentForTxnId_result(getSuccessfulPaymentForTxnId_result other) {
9930
      if (other.isSetSuccess()) {
9931
        this.success = new Payment(other.success);
9932
      }
9933
      if (other.isSetPe()) {
9934
        this.pe = new PaymentException(other.pe);
9935
      }
9936
    }
9937
 
9938
    public getSuccessfulPaymentForTxnId_result deepCopy() {
9939
      return new getSuccessfulPaymentForTxnId_result(this);
9940
    }
9941
 
9942
    @Override
9943
    public void clear() {
9944
      this.success = null;
9945
      this.pe = null;
9946
    }
9947
 
9948
    public Payment getSuccess() {
9949
      return this.success;
9950
    }
9951
 
9952
    public void setSuccess(Payment success) {
9953
      this.success = success;
9954
    }
9955
 
9956
    public void unsetSuccess() {
9957
      this.success = null;
9958
    }
9959
 
9960
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9961
    public boolean isSetSuccess() {
9962
      return this.success != null;
9963
    }
9964
 
9965
    public void setSuccessIsSet(boolean value) {
9966
      if (!value) {
9967
        this.success = null;
9968
      }
9969
    }
9970
 
9971
    public PaymentException getPe() {
9972
      return this.pe;
9973
    }
9974
 
9975
    public void setPe(PaymentException pe) {
9976
      this.pe = pe;
9977
    }
9978
 
9979
    public void unsetPe() {
9980
      this.pe = null;
9981
    }
9982
 
9983
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
9984
    public boolean isSetPe() {
9985
      return this.pe != null;
9986
    }
9987
 
9988
    public void setPeIsSet(boolean value) {
9989
      if (!value) {
9990
        this.pe = null;
9991
      }
9992
    }
9993
 
9994
    public void setFieldValue(_Fields field, Object value) {
9995
      switch (field) {
9996
      case SUCCESS:
9997
        if (value == null) {
9998
          unsetSuccess();
9999
        } else {
10000
          setSuccess((Payment)value);
10001
        }
10002
        break;
10003
 
10004
      case PE:
10005
        if (value == null) {
10006
          unsetPe();
10007
        } else {
10008
          setPe((PaymentException)value);
10009
        }
10010
        break;
10011
 
10012
      }
10013
    }
10014
 
10015
    public Object getFieldValue(_Fields field) {
10016
      switch (field) {
10017
      case SUCCESS:
10018
        return getSuccess();
10019
 
10020
      case PE:
10021
        return getPe();
10022
 
10023
      }
10024
      throw new IllegalStateException();
10025
    }
10026
 
10027
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10028
    public boolean isSet(_Fields field) {
10029
      if (field == null) {
10030
        throw new IllegalArgumentException();
10031
      }
10032
 
10033
      switch (field) {
10034
      case SUCCESS:
10035
        return isSetSuccess();
10036
      case PE:
10037
        return isSetPe();
10038
      }
10039
      throw new IllegalStateException();
10040
    }
10041
 
10042
    @Override
10043
    public boolean equals(Object that) {
10044
      if (that == null)
10045
        return false;
10046
      if (that instanceof getSuccessfulPaymentForTxnId_result)
10047
        return this.equals((getSuccessfulPaymentForTxnId_result)that);
10048
      return false;
10049
    }
10050
 
10051
    public boolean equals(getSuccessfulPaymentForTxnId_result that) {
10052
      if (that == null)
10053
        return false;
10054
 
10055
      boolean this_present_success = true && this.isSetSuccess();
10056
      boolean that_present_success = true && that.isSetSuccess();
10057
      if (this_present_success || that_present_success) {
10058
        if (!(this_present_success && that_present_success))
10059
          return false;
10060
        if (!this.success.equals(that.success))
10061
          return false;
10062
      }
10063
 
10064
      boolean this_present_pe = true && this.isSetPe();
10065
      boolean that_present_pe = true && that.isSetPe();
10066
      if (this_present_pe || that_present_pe) {
10067
        if (!(this_present_pe && that_present_pe))
10068
          return false;
10069
        if (!this.pe.equals(that.pe))
10070
          return false;
10071
      }
10072
 
10073
      return true;
10074
    }
10075
 
10076
    @Override
10077
    public int hashCode() {
10078
      return 0;
10079
    }
10080
 
10081
    public int compareTo(getSuccessfulPaymentForTxnId_result other) {
10082
      if (!getClass().equals(other.getClass())) {
10083
        return getClass().getName().compareTo(other.getClass().getName());
10084
      }
10085
 
10086
      int lastComparison = 0;
10087
      getSuccessfulPaymentForTxnId_result typedOther = (getSuccessfulPaymentForTxnId_result)other;
10088
 
10089
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10090
      if (lastComparison != 0) {
10091
        return lastComparison;
10092
      }
10093
      if (isSetSuccess()) {
10094
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10095
        if (lastComparison != 0) {
10096
          return lastComparison;
10097
        }
10098
      }
10099
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
10100
      if (lastComparison != 0) {
10101
        return lastComparison;
10102
      }
10103
      if (isSetPe()) {
10104
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
10105
        if (lastComparison != 0) {
10106
          return lastComparison;
10107
        }
10108
      }
10109
      return 0;
10110
    }
10111
 
10112
    public _Fields fieldForId(int fieldId) {
10113
      return _Fields.findByThriftId(fieldId);
10114
    }
10115
 
10116
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10117
      org.apache.thrift.protocol.TField field;
10118
      iprot.readStructBegin();
10119
      while (true)
10120
      {
10121
        field = iprot.readFieldBegin();
10122
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10123
          break;
10124
        }
10125
        switch (field.id) {
10126
          case 0: // SUCCESS
10127
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10128
              this.success = new Payment();
10129
              this.success.read(iprot);
10130
            } else { 
10131
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10132
            }
10133
            break;
10134
          case 1: // PE
10135
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10136
              this.pe = new PaymentException();
10137
              this.pe.read(iprot);
10138
            } else { 
10139
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10140
            }
10141
            break;
10142
          default:
10143
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10144
        }
10145
        iprot.readFieldEnd();
10146
      }
10147
      iprot.readStructEnd();
10148
      validate();
10149
    }
10150
 
10151
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10152
      oprot.writeStructBegin(STRUCT_DESC);
10153
 
10154
      if (this.isSetSuccess()) {
10155
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10156
        this.success.write(oprot);
10157
        oprot.writeFieldEnd();
10158
      } else if (this.isSetPe()) {
10159
        oprot.writeFieldBegin(PE_FIELD_DESC);
10160
        this.pe.write(oprot);
10161
        oprot.writeFieldEnd();
10162
      }
10163
      oprot.writeFieldStop();
10164
      oprot.writeStructEnd();
10165
    }
10166
 
10167
    @Override
10168
    public String toString() {
10169
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentForTxnId_result(");
10170
      boolean first = true;
10171
 
10172
      sb.append("success:");
10173
      if (this.success == null) {
10174
        sb.append("null");
10175
      } else {
10176
        sb.append(this.success);
10177
      }
10178
      first = false;
10179
      if (!first) sb.append(", ");
10180
      sb.append("pe:");
10181
      if (this.pe == null) {
10182
        sb.append("null");
10183
      } else {
10184
        sb.append(this.pe);
10185
      }
10186
      first = false;
10187
      sb.append(")");
10188
      return sb.toString();
10189
    }
10190
 
10191
    public void validate() throws org.apache.thrift.TException {
10192
      // check for required fields
10193
    }
10194
 
10195
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10196
      try {
10197
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10198
      } catch (org.apache.thrift.TException te) {
10199
        throw new java.io.IOException(te);
10200
      }
10201
    }
10202
 
10203
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10204
      try {
10205
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10206
      } catch (org.apache.thrift.TException te) {
10207
        throw new java.io.IOException(te);
10208
      }
10209
    }
10210
 
10211
  }
10212
 
3430 rajveer 10213
  public static class updatePaymentDetails_args implements org.apache.thrift.TBase<updatePaymentDetails_args, updatePaymentDetails_args._Fields>, java.io.Serializable, Cloneable   {
10214
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updatePaymentDetails_args");
420 ashish 10215
 
3430 rajveer 10216
    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);
10217
    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);
10218
    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);
10219
    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);
10220
    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);
10221
    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);
10222
    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);
10223
    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);
10224
    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);
10225
    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);
10226
    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);
10227
    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 10228
 
3430 rajveer 10229
    private long id; // required
10230
    private String gatewayPaymentId; // required
10231
    private String sessionId; // required
10232
    private String gatewayTxnStatus; // required
10233
    private String description; // required
10234
    private String gatewayTxnId; // required
10235
    private String authCode; // required
10236
    private String referenceCode; // required
10237
    private String errorCode; // required
10238
    private PaymentStatus status; // required
10239
    private String gatewayTxnDate; // required
10240
    private List<Attribute> attributes; // required
420 ashish 10241
 
10242
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 10243
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 10244
      ID((short)1, "id"),
695 rajveer 10245
      GATEWAY_PAYMENT_ID((short)2, "gatewayPaymentId"),
10246
      SESSION_ID((short)3, "sessionId"),
10247
      GATEWAY_TXN_STATUS((short)4, "gatewayTxnStatus"),
10248
      DESCRIPTION((short)5, "description"),
10249
      GATEWAY_TXN_ID((short)6, "gatewayTxnId"),
10250
      AUTH_CODE((short)7, "authCode"),
10251
      REFERENCE_CODE((short)8, "referenceCode"),
10252
      ERROR_CODE((short)9, "errorCode"),
10253
      /**
10254
       * 
10255
       * @see PaymentStatus
10256
       */
10257
      STATUS((short)10, "status"),
1119 rajveer 10258
      GATEWAY_TXN_DATE((short)11, "gatewayTxnDate"),
10259
      ATTRIBUTES((short)12, "attributes");
420 ashish 10260
 
10261
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10262
 
10263
      static {
10264
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10265
          byName.put(field.getFieldName(), field);
10266
        }
10267
      }
10268
 
10269
      /**
10270
       * Find the _Fields constant that matches fieldId, or null if its not found.
10271
       */
10272
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 10273
        switch(fieldId) {
10274
          case 1: // ID
10275
            return ID;
10276
          case 2: // GATEWAY_PAYMENT_ID
10277
            return GATEWAY_PAYMENT_ID;
10278
          case 3: // SESSION_ID
10279
            return SESSION_ID;
10280
          case 4: // GATEWAY_TXN_STATUS
10281
            return GATEWAY_TXN_STATUS;
10282
          case 5: // DESCRIPTION
10283
            return DESCRIPTION;
10284
          case 6: // GATEWAY_TXN_ID
10285
            return GATEWAY_TXN_ID;
10286
          case 7: // AUTH_CODE
10287
            return AUTH_CODE;
10288
          case 8: // REFERENCE_CODE
10289
            return REFERENCE_CODE;
10290
          case 9: // ERROR_CODE
10291
            return ERROR_CODE;
10292
          case 10: // STATUS
10293
            return STATUS;
10294
          case 11: // GATEWAY_TXN_DATE
10295
            return GATEWAY_TXN_DATE;
10296
          case 12: // ATTRIBUTES
10297
            return ATTRIBUTES;
10298
          default:
10299
            return null;
10300
        }
420 ashish 10301
      }
10302
 
10303
      /**
10304
       * Find the _Fields constant that matches fieldId, throwing an exception
10305
       * if it is not found.
10306
       */
10307
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10308
        _Fields fields = findByThriftId(fieldId);
10309
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10310
        return fields;
10311
      }
10312
 
10313
      /**
10314
       * Find the _Fields constant that matches name, or null if its not found.
10315
       */
10316
      public static _Fields findByName(String name) {
10317
        return byName.get(name);
10318
      }
10319
 
10320
      private final short _thriftId;
10321
      private final String _fieldName;
10322
 
10323
      _Fields(short thriftId, String fieldName) {
10324
        _thriftId = thriftId;
10325
        _fieldName = fieldName;
10326
      }
10327
 
10328
      public short getThriftFieldId() {
10329
        return _thriftId;
10330
      }
10331
 
10332
      public String getFieldName() {
10333
        return _fieldName;
10334
      }
10335
    }
10336
 
10337
    // isset id assignments
10338
    private static final int __ID_ISSET_ID = 0;
10339
    private BitSet __isset_bit_vector = new BitSet(1);
10340
 
3430 rajveer 10341
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 10342
    static {
3430 rajveer 10343
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10344
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10345
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10346
      tmpMap.put(_Fields.GATEWAY_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10347
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10348
      tmpMap.put(_Fields.SESSION_ID, new org.apache.thrift.meta_data.FieldMetaData("sessionId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10349
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10350
      tmpMap.put(_Fields.GATEWAY_TXN_STATUS, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnStatus", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10351
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10352
      tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10353
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10354
      tmpMap.put(_Fields.GATEWAY_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10355
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10356
      tmpMap.put(_Fields.AUTH_CODE, new org.apache.thrift.meta_data.FieldMetaData("authCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10357
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10358
      tmpMap.put(_Fields.REFERENCE_CODE, new org.apache.thrift.meta_data.FieldMetaData("referenceCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10359
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10360
      tmpMap.put(_Fields.ERROR_CODE, new org.apache.thrift.meta_data.FieldMetaData("errorCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10361
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10362
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10363
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
10364
      tmpMap.put(_Fields.GATEWAY_TXN_DATE, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10365
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10366
      tmpMap.put(_Fields.ATTRIBUTES, new org.apache.thrift.meta_data.FieldMetaData("attributes", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10367
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
10368
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Attribute.class))));
10369
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10370
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updatePaymentDetails_args.class, metaDataMap);
420 ashish 10371
    }
10372
 
695 rajveer 10373
    public updatePaymentDetails_args() {
420 ashish 10374
    }
10375
 
695 rajveer 10376
    public updatePaymentDetails_args(
420 ashish 10377
      long id,
695 rajveer 10378
      String gatewayPaymentId,
10379
      String sessionId,
10380
      String gatewayTxnStatus,
10381
      String description,
10382
      String gatewayTxnId,
10383
      String authCode,
10384
      String referenceCode,
10385
      String errorCode,
10386
      PaymentStatus status,
1119 rajveer 10387
      String gatewayTxnDate,
695 rajveer 10388
      List<Attribute> attributes)
420 ashish 10389
    {
10390
      this();
10391
      this.id = id;
10392
      setIdIsSet(true);
695 rajveer 10393
      this.gatewayPaymentId = gatewayPaymentId;
10394
      this.sessionId = sessionId;
10395
      this.gatewayTxnStatus = gatewayTxnStatus;
10396
      this.description = description;
10397
      this.gatewayTxnId = gatewayTxnId;
10398
      this.authCode = authCode;
10399
      this.referenceCode = referenceCode;
10400
      this.errorCode = errorCode;
10401
      this.status = status;
1119 rajveer 10402
      this.gatewayTxnDate = gatewayTxnDate;
695 rajveer 10403
      this.attributes = attributes;
420 ashish 10404
    }
10405
 
10406
    /**
10407
     * Performs a deep copy on <i>other</i>.
10408
     */
695 rajveer 10409
    public updatePaymentDetails_args(updatePaymentDetails_args other) {
420 ashish 10410
      __isset_bit_vector.clear();
10411
      __isset_bit_vector.or(other.__isset_bit_vector);
10412
      this.id = other.id;
695 rajveer 10413
      if (other.isSetGatewayPaymentId()) {
10414
        this.gatewayPaymentId = other.gatewayPaymentId;
420 ashish 10415
      }
695 rajveer 10416
      if (other.isSetSessionId()) {
10417
        this.sessionId = other.sessionId;
420 ashish 10418
      }
695 rajveer 10419
      if (other.isSetGatewayTxnStatus()) {
10420
        this.gatewayTxnStatus = other.gatewayTxnStatus;
420 ashish 10421
      }
695 rajveer 10422
      if (other.isSetDescription()) {
10423
        this.description = other.description;
420 ashish 10424
      }
695 rajveer 10425
      if (other.isSetGatewayTxnId()) {
10426
        this.gatewayTxnId = other.gatewayTxnId;
420 ashish 10427
      }
695 rajveer 10428
      if (other.isSetAuthCode()) {
10429
        this.authCode = other.authCode;
420 ashish 10430
      }
695 rajveer 10431
      if (other.isSetReferenceCode()) {
10432
        this.referenceCode = other.referenceCode;
420 ashish 10433
      }
695 rajveer 10434
      if (other.isSetErrorCode()) {
10435
        this.errorCode = other.errorCode;
10436
      }
10437
      if (other.isSetStatus()) {
10438
        this.status = other.status;
10439
      }
1119 rajveer 10440
      if (other.isSetGatewayTxnDate()) {
10441
        this.gatewayTxnDate = other.gatewayTxnDate;
10442
      }
695 rajveer 10443
      if (other.isSetAttributes()) {
10444
        List<Attribute> __this__attributes = new ArrayList<Attribute>();
10445
        for (Attribute other_element : other.attributes) {
10446
          __this__attributes.add(new Attribute(other_element));
10447
        }
10448
        this.attributes = __this__attributes;
10449
      }
420 ashish 10450
    }
10451
 
695 rajveer 10452
    public updatePaymentDetails_args deepCopy() {
10453
      return new updatePaymentDetails_args(this);
420 ashish 10454
    }
10455
 
3430 rajveer 10456
    @Override
10457
    public void clear() {
10458
      setIdIsSet(false);
10459
      this.id = 0;
10460
      this.gatewayPaymentId = null;
10461
      this.sessionId = null;
10462
      this.gatewayTxnStatus = null;
10463
      this.description = null;
10464
      this.gatewayTxnId = null;
10465
      this.authCode = null;
10466
      this.referenceCode = null;
10467
      this.errorCode = null;
10468
      this.status = null;
10469
      this.gatewayTxnDate = null;
10470
      this.attributes = null;
420 ashish 10471
    }
10472
 
10473
    public long getId() {
10474
      return this.id;
10475
    }
10476
 
3430 rajveer 10477
    public void setId(long id) {
420 ashish 10478
      this.id = id;
10479
      setIdIsSet(true);
10480
    }
10481
 
10482
    public void unsetId() {
10483
      __isset_bit_vector.clear(__ID_ISSET_ID);
10484
    }
10485
 
3430 rajveer 10486
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 10487
    public boolean isSetId() {
10488
      return __isset_bit_vector.get(__ID_ISSET_ID);
10489
    }
10490
 
10491
    public void setIdIsSet(boolean value) {
10492
      __isset_bit_vector.set(__ID_ISSET_ID, value);
10493
    }
10494
 
695 rajveer 10495
    public String getGatewayPaymentId() {
10496
      return this.gatewayPaymentId;
420 ashish 10497
    }
10498
 
3430 rajveer 10499
    public void setGatewayPaymentId(String gatewayPaymentId) {
695 rajveer 10500
      this.gatewayPaymentId = gatewayPaymentId;
420 ashish 10501
    }
10502
 
695 rajveer 10503
    public void unsetGatewayPaymentId() {
10504
      this.gatewayPaymentId = null;
420 ashish 10505
    }
10506
 
3430 rajveer 10507
    /** Returns true if field gatewayPaymentId is set (has been assigned a value) and false otherwise */
695 rajveer 10508
    public boolean isSetGatewayPaymentId() {
10509
      return this.gatewayPaymentId != null;
420 ashish 10510
    }
10511
 
695 rajveer 10512
    public void setGatewayPaymentIdIsSet(boolean value) {
420 ashish 10513
      if (!value) {
695 rajveer 10514
        this.gatewayPaymentId = null;
420 ashish 10515
      }
10516
    }
10517
 
695 rajveer 10518
    public String getSessionId() {
10519
      return this.sessionId;
420 ashish 10520
    }
10521
 
3430 rajveer 10522
    public void setSessionId(String sessionId) {
695 rajveer 10523
      this.sessionId = sessionId;
420 ashish 10524
    }
10525
 
695 rajveer 10526
    public void unsetSessionId() {
10527
      this.sessionId = null;
420 ashish 10528
    }
10529
 
3430 rajveer 10530
    /** Returns true if field sessionId is set (has been assigned a value) and false otherwise */
695 rajveer 10531
    public boolean isSetSessionId() {
10532
      return this.sessionId != null;
420 ashish 10533
    }
10534
 
695 rajveer 10535
    public void setSessionIdIsSet(boolean value) {
420 ashish 10536
      if (!value) {
695 rajveer 10537
        this.sessionId = null;
420 ashish 10538
      }
10539
    }
10540
 
695 rajveer 10541
    public String getGatewayTxnStatus() {
10542
      return this.gatewayTxnStatus;
420 ashish 10543
    }
10544
 
3430 rajveer 10545
    public void setGatewayTxnStatus(String gatewayTxnStatus) {
695 rajveer 10546
      this.gatewayTxnStatus = gatewayTxnStatus;
420 ashish 10547
    }
10548
 
695 rajveer 10549
    public void unsetGatewayTxnStatus() {
10550
      this.gatewayTxnStatus = null;
420 ashish 10551
    }
10552
 
3430 rajveer 10553
    /** Returns true if field gatewayTxnStatus is set (has been assigned a value) and false otherwise */
695 rajveer 10554
    public boolean isSetGatewayTxnStatus() {
10555
      return this.gatewayTxnStatus != null;
420 ashish 10556
    }
10557
 
695 rajveer 10558
    public void setGatewayTxnStatusIsSet(boolean value) {
420 ashish 10559
      if (!value) {
695 rajveer 10560
        this.gatewayTxnStatus = null;
420 ashish 10561
      }
10562
    }
10563
 
695 rajveer 10564
    public String getDescription() {
10565
      return this.description;
420 ashish 10566
    }
10567
 
3430 rajveer 10568
    public void setDescription(String description) {
695 rajveer 10569
      this.description = description;
420 ashish 10570
    }
10571
 
695 rajveer 10572
    public void unsetDescription() {
10573
      this.description = null;
420 ashish 10574
    }
10575
 
3430 rajveer 10576
    /** Returns true if field description is set (has been assigned a value) and false otherwise */
695 rajveer 10577
    public boolean isSetDescription() {
10578
      return this.description != null;
420 ashish 10579
    }
10580
 
695 rajveer 10581
    public void setDescriptionIsSet(boolean value) {
420 ashish 10582
      if (!value) {
695 rajveer 10583
        this.description = null;
420 ashish 10584
      }
10585
    }
10586
 
695 rajveer 10587
    public String getGatewayTxnId() {
10588
      return this.gatewayTxnId;
420 ashish 10589
    }
10590
 
3430 rajveer 10591
    public void setGatewayTxnId(String gatewayTxnId) {
695 rajveer 10592
      this.gatewayTxnId = gatewayTxnId;
420 ashish 10593
    }
10594
 
695 rajveer 10595
    public void unsetGatewayTxnId() {
10596
      this.gatewayTxnId = null;
420 ashish 10597
    }
10598
 
3430 rajveer 10599
    /** Returns true if field gatewayTxnId is set (has been assigned a value) and false otherwise */
695 rajveer 10600
    public boolean isSetGatewayTxnId() {
10601
      return this.gatewayTxnId != null;
420 ashish 10602
    }
10603
 
695 rajveer 10604
    public void setGatewayTxnIdIsSet(boolean value) {
420 ashish 10605
      if (!value) {
695 rajveer 10606
        this.gatewayTxnId = null;
420 ashish 10607
      }
10608
    }
10609
 
695 rajveer 10610
    public String getAuthCode() {
10611
      return this.authCode;
420 ashish 10612
    }
10613
 
3430 rajveer 10614
    public void setAuthCode(String authCode) {
695 rajveer 10615
      this.authCode = authCode;
420 ashish 10616
    }
10617
 
695 rajveer 10618
    public void unsetAuthCode() {
10619
      this.authCode = null;
420 ashish 10620
    }
10621
 
3430 rajveer 10622
    /** Returns true if field authCode is set (has been assigned a value) and false otherwise */
695 rajveer 10623
    public boolean isSetAuthCode() {
10624
      return this.authCode != null;
420 ashish 10625
    }
10626
 
695 rajveer 10627
    public void setAuthCodeIsSet(boolean value) {
420 ashish 10628
      if (!value) {
695 rajveer 10629
        this.authCode = null;
420 ashish 10630
      }
10631
    }
10632
 
695 rajveer 10633
    public String getReferenceCode() {
10634
      return this.referenceCode;
420 ashish 10635
    }
10636
 
3430 rajveer 10637
    public void setReferenceCode(String referenceCode) {
695 rajveer 10638
      this.referenceCode = referenceCode;
420 ashish 10639
    }
10640
 
695 rajveer 10641
    public void unsetReferenceCode() {
10642
      this.referenceCode = null;
420 ashish 10643
    }
10644
 
3430 rajveer 10645
    /** Returns true if field referenceCode is set (has been assigned a value) and false otherwise */
695 rajveer 10646
    public boolean isSetReferenceCode() {
10647
      return this.referenceCode != null;
420 ashish 10648
    }
10649
 
695 rajveer 10650
    public void setReferenceCodeIsSet(boolean value) {
420 ashish 10651
      if (!value) {
695 rajveer 10652
        this.referenceCode = null;
420 ashish 10653
      }
10654
    }
10655
 
695 rajveer 10656
    public String getErrorCode() {
10657
      return this.errorCode;
10658
    }
10659
 
3430 rajveer 10660
    public void setErrorCode(String errorCode) {
695 rajveer 10661
      this.errorCode = errorCode;
10662
    }
10663
 
10664
    public void unsetErrorCode() {
10665
      this.errorCode = null;
10666
    }
10667
 
3430 rajveer 10668
    /** Returns true if field errorCode is set (has been assigned a value) and false otherwise */
695 rajveer 10669
    public boolean isSetErrorCode() {
10670
      return this.errorCode != null;
10671
    }
10672
 
10673
    public void setErrorCodeIsSet(boolean value) {
10674
      if (!value) {
10675
        this.errorCode = null;
10676
      }
10677
    }
10678
 
10679
    /**
10680
     * 
10681
     * @see PaymentStatus
10682
     */
10683
    public PaymentStatus getStatus() {
10684
      return this.status;
10685
    }
10686
 
10687
    /**
10688
     * 
10689
     * @see PaymentStatus
10690
     */
3430 rajveer 10691
    public void setStatus(PaymentStatus status) {
695 rajveer 10692
      this.status = status;
10693
    }
10694
 
10695
    public void unsetStatus() {
10696
      this.status = null;
10697
    }
10698
 
3430 rajveer 10699
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
695 rajveer 10700
    public boolean isSetStatus() {
10701
      return this.status != null;
10702
    }
10703
 
10704
    public void setStatusIsSet(boolean value) {
10705
      if (!value) {
10706
        this.status = null;
10707
      }
10708
    }
10709
 
1119 rajveer 10710
    public String getGatewayTxnDate() {
10711
      return this.gatewayTxnDate;
10712
    }
10713
 
3430 rajveer 10714
    public void setGatewayTxnDate(String gatewayTxnDate) {
1119 rajveer 10715
      this.gatewayTxnDate = gatewayTxnDate;
10716
    }
10717
 
10718
    public void unsetGatewayTxnDate() {
10719
      this.gatewayTxnDate = null;
10720
    }
10721
 
3430 rajveer 10722
    /** Returns true if field gatewayTxnDate is set (has been assigned a value) and false otherwise */
1119 rajveer 10723
    public boolean isSetGatewayTxnDate() {
10724
      return this.gatewayTxnDate != null;
10725
    }
10726
 
10727
    public void setGatewayTxnDateIsSet(boolean value) {
10728
      if (!value) {
10729
        this.gatewayTxnDate = null;
10730
      }
10731
    }
10732
 
695 rajveer 10733
    public int getAttributesSize() {
10734
      return (this.attributes == null) ? 0 : this.attributes.size();
10735
    }
10736
 
10737
    public java.util.Iterator<Attribute> getAttributesIterator() {
10738
      return (this.attributes == null) ? null : this.attributes.iterator();
10739
    }
10740
 
10741
    public void addToAttributes(Attribute elem) {
10742
      if (this.attributes == null) {
10743
        this.attributes = new ArrayList<Attribute>();
10744
      }
10745
      this.attributes.add(elem);
10746
    }
10747
 
10748
    public List<Attribute> getAttributes() {
10749
      return this.attributes;
10750
    }
10751
 
3430 rajveer 10752
    public void setAttributes(List<Attribute> attributes) {
695 rajveer 10753
      this.attributes = attributes;
10754
    }
10755
 
10756
    public void unsetAttributes() {
10757
      this.attributes = null;
10758
    }
10759
 
3430 rajveer 10760
    /** Returns true if field attributes is set (has been assigned a value) and false otherwise */
695 rajveer 10761
    public boolean isSetAttributes() {
10762
      return this.attributes != null;
10763
    }
10764
 
10765
    public void setAttributesIsSet(boolean value) {
10766
      if (!value) {
10767
        this.attributes = null;
10768
      }
10769
    }
10770
 
420 ashish 10771
    public void setFieldValue(_Fields field, Object value) {
10772
      switch (field) {
10773
      case ID:
10774
        if (value == null) {
10775
          unsetId();
10776
        } else {
10777
          setId((Long)value);
10778
        }
10779
        break;
10780
 
695 rajveer 10781
      case GATEWAY_PAYMENT_ID:
420 ashish 10782
        if (value == null) {
695 rajveer 10783
          unsetGatewayPaymentId();
420 ashish 10784
        } else {
695 rajveer 10785
          setGatewayPaymentId((String)value);
420 ashish 10786
        }
10787
        break;
10788
 
695 rajveer 10789
      case SESSION_ID:
420 ashish 10790
        if (value == null) {
695 rajveer 10791
          unsetSessionId();
420 ashish 10792
        } else {
695 rajveer 10793
          setSessionId((String)value);
420 ashish 10794
        }
10795
        break;
10796
 
695 rajveer 10797
      case GATEWAY_TXN_STATUS:
420 ashish 10798
        if (value == null) {
695 rajveer 10799
          unsetGatewayTxnStatus();
420 ashish 10800
        } else {
695 rajveer 10801
          setGatewayTxnStatus((String)value);
420 ashish 10802
        }
10803
        break;
10804
 
695 rajveer 10805
      case DESCRIPTION:
420 ashish 10806
        if (value == null) {
695 rajveer 10807
          unsetDescription();
420 ashish 10808
        } else {
695 rajveer 10809
          setDescription((String)value);
420 ashish 10810
        }
10811
        break;
10812
 
695 rajveer 10813
      case GATEWAY_TXN_ID:
420 ashish 10814
        if (value == null) {
695 rajveer 10815
          unsetGatewayTxnId();
420 ashish 10816
        } else {
695 rajveer 10817
          setGatewayTxnId((String)value);
420 ashish 10818
        }
10819
        break;
10820
 
10821
      case AUTH_CODE:
10822
        if (value == null) {
695 rajveer 10823
          unsetAuthCode();
420 ashish 10824
        } else {
695 rajveer 10825
          setAuthCode((String)value);
420 ashish 10826
        }
10827
        break;
10828
 
695 rajveer 10829
      case REFERENCE_CODE:
420 ashish 10830
        if (value == null) {
695 rajveer 10831
          unsetReferenceCode();
420 ashish 10832
        } else {
695 rajveer 10833
          setReferenceCode((String)value);
420 ashish 10834
        }
10835
        break;
10836
 
695 rajveer 10837
      case ERROR_CODE:
10838
        if (value == null) {
10839
          unsetErrorCode();
10840
        } else {
10841
          setErrorCode((String)value);
10842
        }
10843
        break;
10844
 
10845
      case STATUS:
10846
        if (value == null) {
10847
          unsetStatus();
10848
        } else {
10849
          setStatus((PaymentStatus)value);
10850
        }
10851
        break;
10852
 
1119 rajveer 10853
      case GATEWAY_TXN_DATE:
10854
        if (value == null) {
10855
          unsetGatewayTxnDate();
10856
        } else {
10857
          setGatewayTxnDate((String)value);
10858
        }
10859
        break;
10860
 
695 rajveer 10861
      case ATTRIBUTES:
10862
        if (value == null) {
10863
          unsetAttributes();
10864
        } else {
10865
          setAttributes((List<Attribute>)value);
10866
        }
10867
        break;
10868
 
420 ashish 10869
      }
10870
    }
10871
 
10872
    public Object getFieldValue(_Fields field) {
10873
      switch (field) {
10874
      case ID:
3430 rajveer 10875
        return Long.valueOf(getId());
420 ashish 10876
 
695 rajveer 10877
      case GATEWAY_PAYMENT_ID:
10878
        return getGatewayPaymentId();
420 ashish 10879
 
695 rajveer 10880
      case SESSION_ID:
10881
        return getSessionId();
420 ashish 10882
 
695 rajveer 10883
      case GATEWAY_TXN_STATUS:
10884
        return getGatewayTxnStatus();
420 ashish 10885
 
695 rajveer 10886
      case DESCRIPTION:
10887
        return getDescription();
420 ashish 10888
 
695 rajveer 10889
      case GATEWAY_TXN_ID:
10890
        return getGatewayTxnId();
420 ashish 10891
 
10892
      case AUTH_CODE:
695 rajveer 10893
        return getAuthCode();
420 ashish 10894
 
695 rajveer 10895
      case REFERENCE_CODE:
10896
        return getReferenceCode();
420 ashish 10897
 
695 rajveer 10898
      case ERROR_CODE:
10899
        return getErrorCode();
10900
 
10901
      case STATUS:
10902
        return getStatus();
10903
 
1119 rajveer 10904
      case GATEWAY_TXN_DATE:
10905
        return getGatewayTxnDate();
10906
 
695 rajveer 10907
      case ATTRIBUTES:
10908
        return getAttributes();
10909
 
420 ashish 10910
      }
10911
      throw new IllegalStateException();
10912
    }
10913
 
3430 rajveer 10914
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10915
    public boolean isSet(_Fields field) {
10916
      if (field == null) {
10917
        throw new IllegalArgumentException();
10918
      }
420 ashish 10919
 
10920
      switch (field) {
10921
      case ID:
10922
        return isSetId();
695 rajveer 10923
      case GATEWAY_PAYMENT_ID:
10924
        return isSetGatewayPaymentId();
420 ashish 10925
      case SESSION_ID:
695 rajveer 10926
        return isSetSessionId();
10927
      case GATEWAY_TXN_STATUS:
10928
        return isSetGatewayTxnStatus();
10929
      case DESCRIPTION:
10930
        return isSetDescription();
10931
      case GATEWAY_TXN_ID:
10932
        return isSetGatewayTxnId();
420 ashish 10933
      case AUTH_CODE:
695 rajveer 10934
        return isSetAuthCode();
10935
      case REFERENCE_CODE:
10936
        return isSetReferenceCode();
10937
      case ERROR_CODE:
10938
        return isSetErrorCode();
10939
      case STATUS:
10940
        return isSetStatus();
1119 rajveer 10941
      case GATEWAY_TXN_DATE:
10942
        return isSetGatewayTxnDate();
695 rajveer 10943
      case ATTRIBUTES:
10944
        return isSetAttributes();
420 ashish 10945
      }
10946
      throw new IllegalStateException();
10947
    }
10948
 
10949
    @Override
10950
    public boolean equals(Object that) {
10951
      if (that == null)
10952
        return false;
695 rajveer 10953
      if (that instanceof updatePaymentDetails_args)
10954
        return this.equals((updatePaymentDetails_args)that);
420 ashish 10955
      return false;
10956
    }
10957
 
695 rajveer 10958
    public boolean equals(updatePaymentDetails_args that) {
420 ashish 10959
      if (that == null)
10960
        return false;
10961
 
10962
      boolean this_present_id = true;
10963
      boolean that_present_id = true;
10964
      if (this_present_id || that_present_id) {
10965
        if (!(this_present_id && that_present_id))
10966
          return false;
10967
        if (this.id != that.id)
10968
          return false;
10969
      }
10970
 
695 rajveer 10971
      boolean this_present_gatewayPaymentId = true && this.isSetGatewayPaymentId();
10972
      boolean that_present_gatewayPaymentId = true && that.isSetGatewayPaymentId();
10973
      if (this_present_gatewayPaymentId || that_present_gatewayPaymentId) {
10974
        if (!(this_present_gatewayPaymentId && that_present_gatewayPaymentId))
420 ashish 10975
          return false;
695 rajveer 10976
        if (!this.gatewayPaymentId.equals(that.gatewayPaymentId))
420 ashish 10977
          return false;
10978
      }
10979
 
695 rajveer 10980
      boolean this_present_sessionId = true && this.isSetSessionId();
10981
      boolean that_present_sessionId = true && that.isSetSessionId();
10982
      if (this_present_sessionId || that_present_sessionId) {
10983
        if (!(this_present_sessionId && that_present_sessionId))
420 ashish 10984
          return false;
695 rajveer 10985
        if (!this.sessionId.equals(that.sessionId))
420 ashish 10986
          return false;
10987
      }
10988
 
695 rajveer 10989
      boolean this_present_gatewayTxnStatus = true && this.isSetGatewayTxnStatus();
10990
      boolean that_present_gatewayTxnStatus = true && that.isSetGatewayTxnStatus();
10991
      if (this_present_gatewayTxnStatus || that_present_gatewayTxnStatus) {
10992
        if (!(this_present_gatewayTxnStatus && that_present_gatewayTxnStatus))
420 ashish 10993
          return false;
695 rajveer 10994
        if (!this.gatewayTxnStatus.equals(that.gatewayTxnStatus))
420 ashish 10995
          return false;
10996
      }
10997
 
695 rajveer 10998
      boolean this_present_description = true && this.isSetDescription();
10999
      boolean that_present_description = true && that.isSetDescription();
11000
      if (this_present_description || that_present_description) {
11001
        if (!(this_present_description && that_present_description))
420 ashish 11002
          return false;
695 rajveer 11003
        if (!this.description.equals(that.description))
420 ashish 11004
          return false;
11005
      }
11006
 
695 rajveer 11007
      boolean this_present_gatewayTxnId = true && this.isSetGatewayTxnId();
11008
      boolean that_present_gatewayTxnId = true && that.isSetGatewayTxnId();
11009
      if (this_present_gatewayTxnId || that_present_gatewayTxnId) {
11010
        if (!(this_present_gatewayTxnId && that_present_gatewayTxnId))
420 ashish 11011
          return false;
695 rajveer 11012
        if (!this.gatewayTxnId.equals(that.gatewayTxnId))
420 ashish 11013
          return false;
11014
      }
11015
 
695 rajveer 11016
      boolean this_present_authCode = true && this.isSetAuthCode();
11017
      boolean that_present_authCode = true && that.isSetAuthCode();
11018
      if (this_present_authCode || that_present_authCode) {
11019
        if (!(this_present_authCode && that_present_authCode))
420 ashish 11020
          return false;
695 rajveer 11021
        if (!this.authCode.equals(that.authCode))
420 ashish 11022
          return false;
11023
      }
11024
 
695 rajveer 11025
      boolean this_present_referenceCode = true && this.isSetReferenceCode();
11026
      boolean that_present_referenceCode = true && that.isSetReferenceCode();
11027
      if (this_present_referenceCode || that_present_referenceCode) {
11028
        if (!(this_present_referenceCode && that_present_referenceCode))
420 ashish 11029
          return false;
695 rajveer 11030
        if (!this.referenceCode.equals(that.referenceCode))
420 ashish 11031
          return false;
11032
      }
11033
 
695 rajveer 11034
      boolean this_present_errorCode = true && this.isSetErrorCode();
11035
      boolean that_present_errorCode = true && that.isSetErrorCode();
11036
      if (this_present_errorCode || that_present_errorCode) {
11037
        if (!(this_present_errorCode && that_present_errorCode))
11038
          return false;
11039
        if (!this.errorCode.equals(that.errorCode))
11040
          return false;
11041
      }
11042
 
11043
      boolean this_present_status = true && this.isSetStatus();
11044
      boolean that_present_status = true && that.isSetStatus();
11045
      if (this_present_status || that_present_status) {
11046
        if (!(this_present_status && that_present_status))
11047
          return false;
11048
        if (!this.status.equals(that.status))
11049
          return false;
11050
      }
11051
 
1119 rajveer 11052
      boolean this_present_gatewayTxnDate = true && this.isSetGatewayTxnDate();
11053
      boolean that_present_gatewayTxnDate = true && that.isSetGatewayTxnDate();
11054
      if (this_present_gatewayTxnDate || that_present_gatewayTxnDate) {
11055
        if (!(this_present_gatewayTxnDate && that_present_gatewayTxnDate))
11056
          return false;
11057
        if (!this.gatewayTxnDate.equals(that.gatewayTxnDate))
11058
          return false;
11059
      }
11060
 
695 rajveer 11061
      boolean this_present_attributes = true && this.isSetAttributes();
11062
      boolean that_present_attributes = true && that.isSetAttributes();
11063
      if (this_present_attributes || that_present_attributes) {
11064
        if (!(this_present_attributes && that_present_attributes))
11065
          return false;
11066
        if (!this.attributes.equals(that.attributes))
11067
          return false;
11068
      }
11069
 
420 ashish 11070
      return true;
11071
    }
11072
 
11073
    @Override
11074
    public int hashCode() {
11075
      return 0;
11076
    }
11077
 
695 rajveer 11078
    public int compareTo(updatePaymentDetails_args other) {
420 ashish 11079
      if (!getClass().equals(other.getClass())) {
11080
        return getClass().getName().compareTo(other.getClass().getName());
11081
      }
11082
 
11083
      int lastComparison = 0;
695 rajveer 11084
      updatePaymentDetails_args typedOther = (updatePaymentDetails_args)other;
420 ashish 11085
 
3430 rajveer 11086
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
420 ashish 11087
      if (lastComparison != 0) {
11088
        return lastComparison;
11089
      }
3430 rajveer 11090
      if (isSetId()) {
11091
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
11092
        if (lastComparison != 0) {
11093
          return lastComparison;
11094
        }
420 ashish 11095
      }
3430 rajveer 11096
      lastComparison = Boolean.valueOf(isSetGatewayPaymentId()).compareTo(typedOther.isSetGatewayPaymentId());
420 ashish 11097
      if (lastComparison != 0) {
11098
        return lastComparison;
11099
      }
3430 rajveer 11100
      if (isSetGatewayPaymentId()) {
11101
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayPaymentId, typedOther.gatewayPaymentId);
11102
        if (lastComparison != 0) {
11103
          return lastComparison;
11104
        }
420 ashish 11105
      }
3430 rajveer 11106
      lastComparison = Boolean.valueOf(isSetSessionId()).compareTo(typedOther.isSetSessionId());
420 ashish 11107
      if (lastComparison != 0) {
11108
        return lastComparison;
11109
      }
3430 rajveer 11110
      if (isSetSessionId()) {
11111
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sessionId, typedOther.sessionId);
11112
        if (lastComparison != 0) {
11113
          return lastComparison;
11114
        }
420 ashish 11115
      }
3430 rajveer 11116
      lastComparison = Boolean.valueOf(isSetGatewayTxnStatus()).compareTo(typedOther.isSetGatewayTxnStatus());
420 ashish 11117
      if (lastComparison != 0) {
11118
        return lastComparison;
11119
      }
3430 rajveer 11120
      if (isSetGatewayTxnStatus()) {
11121
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnStatus, typedOther.gatewayTxnStatus);
11122
        if (lastComparison != 0) {
11123
          return lastComparison;
11124
        }
420 ashish 11125
      }
3430 rajveer 11126
      lastComparison = Boolean.valueOf(isSetDescription()).compareTo(typedOther.isSetDescription());
420 ashish 11127
      if (lastComparison != 0) {
11128
        return lastComparison;
11129
      }
3430 rajveer 11130
      if (isSetDescription()) {
11131
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.description, typedOther.description);
11132
        if (lastComparison != 0) {
11133
          return lastComparison;
11134
        }
420 ashish 11135
      }
3430 rajveer 11136
      lastComparison = Boolean.valueOf(isSetGatewayTxnId()).compareTo(typedOther.isSetGatewayTxnId());
420 ashish 11137
      if (lastComparison != 0) {
11138
        return lastComparison;
11139
      }
3430 rajveer 11140
      if (isSetGatewayTxnId()) {
11141
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnId, typedOther.gatewayTxnId);
11142
        if (lastComparison != 0) {
11143
          return lastComparison;
11144
        }
420 ashish 11145
      }
3430 rajveer 11146
      lastComparison = Boolean.valueOf(isSetAuthCode()).compareTo(typedOther.isSetAuthCode());
420 ashish 11147
      if (lastComparison != 0) {
11148
        return lastComparison;
11149
      }
3430 rajveer 11150
      if (isSetAuthCode()) {
11151
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.authCode, typedOther.authCode);
11152
        if (lastComparison != 0) {
11153
          return lastComparison;
11154
        }
420 ashish 11155
      }
3430 rajveer 11156
      lastComparison = Boolean.valueOf(isSetReferenceCode()).compareTo(typedOther.isSetReferenceCode());
420 ashish 11157
      if (lastComparison != 0) {
11158
        return lastComparison;
11159
      }
3430 rajveer 11160
      if (isSetReferenceCode()) {
11161
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.referenceCode, typedOther.referenceCode);
11162
        if (lastComparison != 0) {
11163
          return lastComparison;
11164
        }
420 ashish 11165
      }
3430 rajveer 11166
      lastComparison = Boolean.valueOf(isSetErrorCode()).compareTo(typedOther.isSetErrorCode());
695 rajveer 11167
      if (lastComparison != 0) {
11168
        return lastComparison;
11169
      }
3430 rajveer 11170
      if (isSetErrorCode()) {
11171
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errorCode, typedOther.errorCode);
11172
        if (lastComparison != 0) {
11173
          return lastComparison;
11174
        }
695 rajveer 11175
      }
3430 rajveer 11176
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
695 rajveer 11177
      if (lastComparison != 0) {
11178
        return lastComparison;
11179
      }
3430 rajveer 11180
      if (isSetStatus()) {
11181
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
11182
        if (lastComparison != 0) {
11183
          return lastComparison;
11184
        }
695 rajveer 11185
      }
3430 rajveer 11186
      lastComparison = Boolean.valueOf(isSetGatewayTxnDate()).compareTo(typedOther.isSetGatewayTxnDate());
1119 rajveer 11187
      if (lastComparison != 0) {
11188
        return lastComparison;
11189
      }
3430 rajveer 11190
      if (isSetGatewayTxnDate()) {
11191
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnDate, typedOther.gatewayTxnDate);
11192
        if (lastComparison != 0) {
11193
          return lastComparison;
11194
        }
1119 rajveer 11195
      }
3430 rajveer 11196
      lastComparison = Boolean.valueOf(isSetAttributes()).compareTo(typedOther.isSetAttributes());
695 rajveer 11197
      if (lastComparison != 0) {
11198
        return lastComparison;
11199
      }
3430 rajveer 11200
      if (isSetAttributes()) {
11201
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.attributes, typedOther.attributes);
11202
        if (lastComparison != 0) {
11203
          return lastComparison;
11204
        }
695 rajveer 11205
      }
420 ashish 11206
      return 0;
11207
    }
11208
 
3430 rajveer 11209
    public _Fields fieldForId(int fieldId) {
11210
      return _Fields.findByThriftId(fieldId);
11211
    }
11212
 
11213
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11214
      org.apache.thrift.protocol.TField field;
420 ashish 11215
      iprot.readStructBegin();
11216
      while (true)
11217
      {
11218
        field = iprot.readFieldBegin();
3430 rajveer 11219
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 11220
          break;
11221
        }
3430 rajveer 11222
        switch (field.id) {
11223
          case 1: // ID
11224
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11225
              this.id = iprot.readI64();
11226
              setIdIsSet(true);
11227
            } else { 
11228
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11229
            }
11230
            break;
11231
          case 2: // GATEWAY_PAYMENT_ID
11232
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11233
              this.gatewayPaymentId = iprot.readString();
11234
            } else { 
11235
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11236
            }
11237
            break;
11238
          case 3: // SESSION_ID
11239
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11240
              this.sessionId = iprot.readString();
11241
            } else { 
11242
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11243
            }
11244
            break;
11245
          case 4: // GATEWAY_TXN_STATUS
11246
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11247
              this.gatewayTxnStatus = iprot.readString();
11248
            } else { 
11249
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11250
            }
11251
            break;
11252
          case 5: // DESCRIPTION
11253
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11254
              this.description = iprot.readString();
11255
            } else { 
11256
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11257
            }
11258
            break;
11259
          case 6: // GATEWAY_TXN_ID
11260
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11261
              this.gatewayTxnId = iprot.readString();
11262
            } else { 
11263
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11264
            }
11265
            break;
11266
          case 7: // AUTH_CODE
11267
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11268
              this.authCode = iprot.readString();
11269
            } else { 
11270
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11271
            }
11272
            break;
11273
          case 8: // REFERENCE_CODE
11274
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11275
              this.referenceCode = iprot.readString();
11276
            } else { 
11277
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11278
            }
11279
            break;
11280
          case 9: // ERROR_CODE
11281
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11282
              this.errorCode = iprot.readString();
11283
            } else { 
11284
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11285
            }
11286
            break;
11287
          case 10: // STATUS
11288
            if (field.type == org.apache.thrift.protocol.TType.I32) {
11289
              this.status = PaymentStatus.findByValue(iprot.readI32());
11290
            } else { 
11291
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11292
            }
11293
            break;
11294
          case 11: // GATEWAY_TXN_DATE
11295
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11296
              this.gatewayTxnDate = iprot.readString();
11297
            } else { 
11298
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11299
            }
11300
            break;
11301
          case 12: // ATTRIBUTES
11302
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11303
              {
7049 anupam.sin 11304
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
11305
                this.attributes = new ArrayList<Attribute>(_list36.size);
11306
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
695 rajveer 11307
                {
7049 anupam.sin 11308
                  Attribute _elem38; // required
11309
                  _elem38 = new Attribute();
11310
                  _elem38.read(iprot);
11311
                  this.attributes.add(_elem38);
695 rajveer 11312
                }
3430 rajveer 11313
                iprot.readListEnd();
695 rajveer 11314
              }
3430 rajveer 11315
            } else { 
11316
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11317
            }
11318
            break;
11319
          default:
11320
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 11321
        }
3430 rajveer 11322
        iprot.readFieldEnd();
420 ashish 11323
      }
11324
      iprot.readStructEnd();
11325
      validate();
11326
    }
11327
 
3430 rajveer 11328
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 11329
      validate();
11330
 
11331
      oprot.writeStructBegin(STRUCT_DESC);
11332
      oprot.writeFieldBegin(ID_FIELD_DESC);
11333
      oprot.writeI64(this.id);
11334
      oprot.writeFieldEnd();
695 rajveer 11335
      if (this.gatewayPaymentId != null) {
11336
        oprot.writeFieldBegin(GATEWAY_PAYMENT_ID_FIELD_DESC);
11337
        oprot.writeString(this.gatewayPaymentId);
420 ashish 11338
        oprot.writeFieldEnd();
11339
      }
695 rajveer 11340
      if (this.sessionId != null) {
11341
        oprot.writeFieldBegin(SESSION_ID_FIELD_DESC);
11342
        oprot.writeString(this.sessionId);
420 ashish 11343
        oprot.writeFieldEnd();
11344
      }
695 rajveer 11345
      if (this.gatewayTxnStatus != null) {
11346
        oprot.writeFieldBegin(GATEWAY_TXN_STATUS_FIELD_DESC);
11347
        oprot.writeString(this.gatewayTxnStatus);
420 ashish 11348
        oprot.writeFieldEnd();
11349
      }
695 rajveer 11350
      if (this.description != null) {
11351
        oprot.writeFieldBegin(DESCRIPTION_FIELD_DESC);
11352
        oprot.writeString(this.description);
420 ashish 11353
        oprot.writeFieldEnd();
11354
      }
695 rajveer 11355
      if (this.gatewayTxnId != null) {
11356
        oprot.writeFieldBegin(GATEWAY_TXN_ID_FIELD_DESC);
11357
        oprot.writeString(this.gatewayTxnId);
420 ashish 11358
        oprot.writeFieldEnd();
11359
      }
695 rajveer 11360
      if (this.authCode != null) {
420 ashish 11361
        oprot.writeFieldBegin(AUTH_CODE_FIELD_DESC);
695 rajveer 11362
        oprot.writeString(this.authCode);
420 ashish 11363
        oprot.writeFieldEnd();
11364
      }
695 rajveer 11365
      if (this.referenceCode != null) {
11366
        oprot.writeFieldBegin(REFERENCE_CODE_FIELD_DESC);
11367
        oprot.writeString(this.referenceCode);
420 ashish 11368
        oprot.writeFieldEnd();
11369
      }
695 rajveer 11370
      if (this.errorCode != null) {
11371
        oprot.writeFieldBegin(ERROR_CODE_FIELD_DESC);
11372
        oprot.writeString(this.errorCode);
11373
        oprot.writeFieldEnd();
11374
      }
11375
      if (this.status != null) {
11376
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
11377
        oprot.writeI32(this.status.getValue());
11378
        oprot.writeFieldEnd();
11379
      }
1119 rajveer 11380
      if (this.gatewayTxnDate != null) {
11381
        oprot.writeFieldBegin(GATEWAY_TXN_DATE_FIELD_DESC);
11382
        oprot.writeString(this.gatewayTxnDate);
11383
        oprot.writeFieldEnd();
11384
      }
695 rajveer 11385
      if (this.attributes != null) {
11386
        oprot.writeFieldBegin(ATTRIBUTES_FIELD_DESC);
11387
        {
3430 rajveer 11388
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.attributes.size()));
7049 anupam.sin 11389
          for (Attribute _iter39 : this.attributes)
695 rajveer 11390
          {
7049 anupam.sin 11391
            _iter39.write(oprot);
695 rajveer 11392
          }
11393
          oprot.writeListEnd();
11394
        }
11395
        oprot.writeFieldEnd();
11396
      }
420 ashish 11397
      oprot.writeFieldStop();
11398
      oprot.writeStructEnd();
11399
    }
11400
 
11401
    @Override
11402
    public String toString() {
695 rajveer 11403
      StringBuilder sb = new StringBuilder("updatePaymentDetails_args(");
420 ashish 11404
      boolean first = true;
11405
 
11406
      sb.append("id:");
11407
      sb.append(this.id);
11408
      first = false;
11409
      if (!first) sb.append(", ");
695 rajveer 11410
      sb.append("gatewayPaymentId:");
11411
      if (this.gatewayPaymentId == null) {
420 ashish 11412
        sb.append("null");
11413
      } else {
695 rajveer 11414
        sb.append(this.gatewayPaymentId);
420 ashish 11415
      }
11416
      first = false;
11417
      if (!first) sb.append(", ");
695 rajveer 11418
      sb.append("sessionId:");
11419
      if (this.sessionId == null) {
420 ashish 11420
        sb.append("null");
11421
      } else {
695 rajveer 11422
        sb.append(this.sessionId);
420 ashish 11423
      }
11424
      first = false;
11425
      if (!first) sb.append(", ");
695 rajveer 11426
      sb.append("gatewayTxnStatus:");
11427
      if (this.gatewayTxnStatus == null) {
420 ashish 11428
        sb.append("null");
11429
      } else {
695 rajveer 11430
        sb.append(this.gatewayTxnStatus);
420 ashish 11431
      }
11432
      first = false;
11433
      if (!first) sb.append(", ");
695 rajveer 11434
      sb.append("description:");
11435
      if (this.description == null) {
420 ashish 11436
        sb.append("null");
11437
      } else {
695 rajveer 11438
        sb.append(this.description);
420 ashish 11439
      }
11440
      first = false;
11441
      if (!first) sb.append(", ");
695 rajveer 11442
      sb.append("gatewayTxnId:");
11443
      if (this.gatewayTxnId == null) {
420 ashish 11444
        sb.append("null");
11445
      } else {
695 rajveer 11446
        sb.append(this.gatewayTxnId);
420 ashish 11447
      }
11448
      first = false;
11449
      if (!first) sb.append(", ");
695 rajveer 11450
      sb.append("authCode:");
11451
      if (this.authCode == null) {
420 ashish 11452
        sb.append("null");
11453
      } else {
695 rajveer 11454
        sb.append(this.authCode);
420 ashish 11455
      }
11456
      first = false;
11457
      if (!first) sb.append(", ");
695 rajveer 11458
      sb.append("referenceCode:");
11459
      if (this.referenceCode == null) {
420 ashish 11460
        sb.append("null");
11461
      } else {
695 rajveer 11462
        sb.append(this.referenceCode);
420 ashish 11463
      }
11464
      first = false;
695 rajveer 11465
      if (!first) sb.append(", ");
11466
      sb.append("errorCode:");
11467
      if (this.errorCode == null) {
11468
        sb.append("null");
11469
      } else {
11470
        sb.append(this.errorCode);
11471
      }
11472
      first = false;
11473
      if (!first) sb.append(", ");
11474
      sb.append("status:");
11475
      if (this.status == null) {
11476
        sb.append("null");
11477
      } else {
11478
        sb.append(this.status);
11479
      }
11480
      first = false;
11481
      if (!first) sb.append(", ");
1119 rajveer 11482
      sb.append("gatewayTxnDate:");
11483
      if (this.gatewayTxnDate == null) {
11484
        sb.append("null");
11485
      } else {
11486
        sb.append(this.gatewayTxnDate);
11487
      }
11488
      first = false;
11489
      if (!first) sb.append(", ");
695 rajveer 11490
      sb.append("attributes:");
11491
      if (this.attributes == null) {
11492
        sb.append("null");
11493
      } else {
11494
        sb.append(this.attributes);
11495
      }
11496
      first = false;
420 ashish 11497
      sb.append(")");
11498
      return sb.toString();
11499
    }
11500
 
3430 rajveer 11501
    public void validate() throws org.apache.thrift.TException {
420 ashish 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
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
11516
        __isset_bit_vector = new BitSet(1);
11517
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11518
      } catch (org.apache.thrift.TException te) {
11519
        throw new java.io.IOException(te);
11520
      }
11521
    }
11522
 
420 ashish 11523
  }
11524
 
3430 rajveer 11525
  public static class updatePaymentDetails_result implements org.apache.thrift.TBase<updatePaymentDetails_result, updatePaymentDetails_result._Fields>, java.io.Serializable, Cloneable   {
11526
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updatePaymentDetails_result");
420 ashish 11527
 
3430 rajveer 11528
    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);
11529
    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 11530
 
3430 rajveer 11531
    private boolean success; // required
11532
    private PaymentException pe; // required
420 ashish 11533
 
11534
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11535
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 11536
      SUCCESS((short)0, "success"),
420 ashish 11537
      PE((short)1, "pe");
11538
 
11539
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11540
 
11541
      static {
11542
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11543
          byName.put(field.getFieldName(), field);
11544
        }
11545
      }
11546
 
11547
      /**
11548
       * Find the _Fields constant that matches fieldId, or null if its not found.
11549
       */
11550
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11551
        switch(fieldId) {
11552
          case 0: // SUCCESS
11553
            return SUCCESS;
11554
          case 1: // PE
11555
            return PE;
11556
          default:
11557
            return null;
11558
        }
420 ashish 11559
      }
11560
 
11561
      /**
11562
       * Find the _Fields constant that matches fieldId, throwing an exception
11563
       * if it is not found.
11564
       */
11565
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11566
        _Fields fields = findByThriftId(fieldId);
11567
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11568
        return fields;
11569
      }
11570
 
11571
      /**
11572
       * Find the _Fields constant that matches name, or null if its not found.
11573
       */
11574
      public static _Fields findByName(String name) {
11575
        return byName.get(name);
11576
      }
11577
 
11578
      private final short _thriftId;
11579
      private final String _fieldName;
11580
 
11581
      _Fields(short thriftId, String fieldName) {
11582
        _thriftId = thriftId;
11583
        _fieldName = fieldName;
11584
      }
11585
 
11586
      public short getThriftFieldId() {
11587
        return _thriftId;
11588
      }
11589
 
11590
      public String getFieldName() {
11591
        return _fieldName;
11592
      }
11593
    }
11594
 
11595
    // isset id assignments
695 rajveer 11596
    private static final int __SUCCESS_ISSET_ID = 0;
11597
    private BitSet __isset_bit_vector = new BitSet(1);
420 ashish 11598
 
3430 rajveer 11599
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 11600
    static {
3430 rajveer 11601
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11602
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11603
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
11604
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11605
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11606
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11607
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updatePaymentDetails_result.class, metaDataMap);
420 ashish 11608
    }
11609
 
695 rajveer 11610
    public updatePaymentDetails_result() {
420 ashish 11611
    }
11612
 
695 rajveer 11613
    public updatePaymentDetails_result(
11614
      boolean success,
420 ashish 11615
      PaymentException pe)
11616
    {
11617
      this();
695 rajveer 11618
      this.success = success;
11619
      setSuccessIsSet(true);
420 ashish 11620
      this.pe = pe;
11621
    }
11622
 
11623
    /**
11624
     * Performs a deep copy on <i>other</i>.
11625
     */
695 rajveer 11626
    public updatePaymentDetails_result(updatePaymentDetails_result other) {
11627
      __isset_bit_vector.clear();
11628
      __isset_bit_vector.or(other.__isset_bit_vector);
11629
      this.success = other.success;
420 ashish 11630
      if (other.isSetPe()) {
11631
        this.pe = new PaymentException(other.pe);
11632
      }
11633
    }
11634
 
695 rajveer 11635
    public updatePaymentDetails_result deepCopy() {
11636
      return new updatePaymentDetails_result(this);
420 ashish 11637
    }
11638
 
3430 rajveer 11639
    @Override
11640
    public void clear() {
11641
      setSuccessIsSet(false);
11642
      this.success = false;
11643
      this.pe = null;
420 ashish 11644
    }
11645
 
695 rajveer 11646
    public boolean isSuccess() {
11647
      return this.success;
11648
    }
11649
 
3430 rajveer 11650
    public void setSuccess(boolean success) {
695 rajveer 11651
      this.success = success;
11652
      setSuccessIsSet(true);
11653
    }
11654
 
11655
    public void unsetSuccess() {
11656
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
11657
    }
11658
 
3430 rajveer 11659
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
695 rajveer 11660
    public boolean isSetSuccess() {
11661
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
11662
    }
11663
 
11664
    public void setSuccessIsSet(boolean value) {
11665
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
11666
    }
11667
 
420 ashish 11668
    public PaymentException getPe() {
11669
      return this.pe;
11670
    }
11671
 
3430 rajveer 11672
    public void setPe(PaymentException pe) {
420 ashish 11673
      this.pe = pe;
11674
    }
11675
 
11676
    public void unsetPe() {
11677
      this.pe = null;
11678
    }
11679
 
3430 rajveer 11680
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 11681
    public boolean isSetPe() {
11682
      return this.pe != null;
11683
    }
11684
 
11685
    public void setPeIsSet(boolean value) {
11686
      if (!value) {
11687
        this.pe = null;
11688
      }
11689
    }
11690
 
11691
    public void setFieldValue(_Fields field, Object value) {
11692
      switch (field) {
695 rajveer 11693
      case SUCCESS:
11694
        if (value == null) {
11695
          unsetSuccess();
11696
        } else {
11697
          setSuccess((Boolean)value);
11698
        }
11699
        break;
11700
 
420 ashish 11701
      case PE:
11702
        if (value == null) {
11703
          unsetPe();
11704
        } else {
11705
          setPe((PaymentException)value);
11706
        }
11707
        break;
11708
 
11709
      }
11710
    }
11711
 
11712
    public Object getFieldValue(_Fields field) {
11713
      switch (field) {
695 rajveer 11714
      case SUCCESS:
3430 rajveer 11715
        return Boolean.valueOf(isSuccess());
695 rajveer 11716
 
420 ashish 11717
      case PE:
11718
        return getPe();
11719
 
11720
      }
11721
      throw new IllegalStateException();
11722
    }
11723
 
3430 rajveer 11724
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11725
    public boolean isSet(_Fields field) {
11726
      if (field == null) {
11727
        throw new IllegalArgumentException();
11728
      }
420 ashish 11729
 
11730
      switch (field) {
695 rajveer 11731
      case SUCCESS:
11732
        return isSetSuccess();
420 ashish 11733
      case PE:
11734
        return isSetPe();
11735
      }
11736
      throw new IllegalStateException();
11737
    }
11738
 
11739
    @Override
11740
    public boolean equals(Object that) {
11741
      if (that == null)
11742
        return false;
695 rajveer 11743
      if (that instanceof updatePaymentDetails_result)
11744
        return this.equals((updatePaymentDetails_result)that);
420 ashish 11745
      return false;
11746
    }
11747
 
695 rajveer 11748
    public boolean equals(updatePaymentDetails_result that) {
420 ashish 11749
      if (that == null)
11750
        return false;
11751
 
695 rajveer 11752
      boolean this_present_success = true;
11753
      boolean that_present_success = true;
11754
      if (this_present_success || that_present_success) {
11755
        if (!(this_present_success && that_present_success))
11756
          return false;
11757
        if (this.success != that.success)
11758
          return false;
11759
      }
11760
 
420 ashish 11761
      boolean this_present_pe = true && this.isSetPe();
11762
      boolean that_present_pe = true && that.isSetPe();
11763
      if (this_present_pe || that_present_pe) {
11764
        if (!(this_present_pe && that_present_pe))
11765
          return false;
11766
        if (!this.pe.equals(that.pe))
11767
          return false;
11768
      }
11769
 
11770
      return true;
11771
    }
11772
 
11773
    @Override
11774
    public int hashCode() {
11775
      return 0;
11776
    }
11777
 
695 rajveer 11778
    public int compareTo(updatePaymentDetails_result other) {
420 ashish 11779
      if (!getClass().equals(other.getClass())) {
11780
        return getClass().getName().compareTo(other.getClass().getName());
11781
      }
11782
 
11783
      int lastComparison = 0;
695 rajveer 11784
      updatePaymentDetails_result typedOther = (updatePaymentDetails_result)other;
420 ashish 11785
 
3430 rajveer 11786
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 11787
      if (lastComparison != 0) {
11788
        return lastComparison;
11789
      }
3430 rajveer 11790
      if (isSetSuccess()) {
11791
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11792
        if (lastComparison != 0) {
11793
          return lastComparison;
11794
        }
695 rajveer 11795
      }
3430 rajveer 11796
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 11797
      if (lastComparison != 0) {
11798
        return lastComparison;
11799
      }
3430 rajveer 11800
      if (isSetPe()) {
11801
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
11802
        if (lastComparison != 0) {
11803
          return lastComparison;
11804
        }
420 ashish 11805
      }
11806
      return 0;
11807
    }
11808
 
3430 rajveer 11809
    public _Fields fieldForId(int fieldId) {
11810
      return _Fields.findByThriftId(fieldId);
11811
    }
11812
 
11813
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11814
      org.apache.thrift.protocol.TField field;
420 ashish 11815
      iprot.readStructBegin();
11816
      while (true)
11817
      {
11818
        field = iprot.readFieldBegin();
3430 rajveer 11819
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 11820
          break;
11821
        }
3430 rajveer 11822
        switch (field.id) {
11823
          case 0: // SUCCESS
11824
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
11825
              this.success = iprot.readBool();
11826
              setSuccessIsSet(true);
11827
            } else { 
11828
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11829
            }
11830
            break;
11831
          case 1: // PE
11832
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11833
              this.pe = new PaymentException();
11834
              this.pe.read(iprot);
11835
            } else { 
11836
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11837
            }
11838
            break;
11839
          default:
11840
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 11841
        }
3430 rajveer 11842
        iprot.readFieldEnd();
420 ashish 11843
      }
11844
      iprot.readStructEnd();
11845
      validate();
11846
    }
11847
 
3430 rajveer 11848
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 11849
      oprot.writeStructBegin(STRUCT_DESC);
11850
 
695 rajveer 11851
      if (this.isSetSuccess()) {
11852
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11853
        oprot.writeBool(this.success);
11854
        oprot.writeFieldEnd();
11855
      } else if (this.isSetPe()) {
420 ashish 11856
        oprot.writeFieldBegin(PE_FIELD_DESC);
11857
        this.pe.write(oprot);
11858
        oprot.writeFieldEnd();
11859
      }
11860
      oprot.writeFieldStop();
11861
      oprot.writeStructEnd();
11862
    }
11863
 
11864
    @Override
11865
    public String toString() {
695 rajveer 11866
      StringBuilder sb = new StringBuilder("updatePaymentDetails_result(");
420 ashish 11867
      boolean first = true;
11868
 
695 rajveer 11869
      sb.append("success:");
11870
      sb.append(this.success);
11871
      first = false;
11872
      if (!first) sb.append(", ");
420 ashish 11873
      sb.append("pe:");
11874
      if (this.pe == null) {
11875
        sb.append("null");
11876
      } else {
11877
        sb.append(this.pe);
11878
      }
11879
      first = false;
11880
      sb.append(")");
11881
      return sb.toString();
11882
    }
11883
 
3430 rajveer 11884
    public void validate() throws org.apache.thrift.TException {
420 ashish 11885
      // check for required fields
11886
    }
11887
 
3430 rajveer 11888
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11889
      try {
11890
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11891
      } catch (org.apache.thrift.TException te) {
11892
        throw new java.io.IOException(te);
11893
      }
11894
    }
11895
 
11896
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11897
      try {
11898
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11899
      } catch (org.apache.thrift.TException te) {
11900
        throw new java.io.IOException(te);
11901
      }
11902
    }
11903
 
420 ashish 11904
  }
11905
 
3430 rajveer 11906
  public static class getSuccessfulPaymentsAmountRange_args implements org.apache.thrift.TBase<getSuccessfulPaymentsAmountRange_args, getSuccessfulPaymentsAmountRange_args._Fields>, java.io.Serializable, Cloneable   {
11907
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentsAmountRange_args");
1629 ankur.sing 11908
 
11909
 
11910
 
11911
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11912
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1629 ankur.sing 11913
;
11914
 
11915
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11916
 
11917
      static {
11918
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11919
          byName.put(field.getFieldName(), field);
11920
        }
11921
      }
11922
 
11923
      /**
11924
       * Find the _Fields constant that matches fieldId, or null if its not found.
11925
       */
11926
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11927
        switch(fieldId) {
11928
          default:
11929
            return null;
11930
        }
1629 ankur.sing 11931
      }
11932
 
11933
      /**
11934
       * Find the _Fields constant that matches fieldId, throwing an exception
11935
       * if it is not found.
11936
       */
11937
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11938
        _Fields fields = findByThriftId(fieldId);
11939
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11940
        return fields;
11941
      }
11942
 
11943
      /**
11944
       * Find the _Fields constant that matches name, or null if its not found.
11945
       */
11946
      public static _Fields findByName(String name) {
11947
        return byName.get(name);
11948
      }
11949
 
11950
      private final short _thriftId;
11951
      private final String _fieldName;
11952
 
11953
      _Fields(short thriftId, String fieldName) {
11954
        _thriftId = thriftId;
11955
        _fieldName = fieldName;
11956
      }
11957
 
11958
      public short getThriftFieldId() {
11959
        return _thriftId;
11960
      }
11961
 
11962
      public String getFieldName() {
11963
        return _fieldName;
11964
      }
11965
    }
3430 rajveer 11966
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1629 ankur.sing 11967
    static {
3430 rajveer 11968
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11969
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11970
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentsAmountRange_args.class, metaDataMap);
1629 ankur.sing 11971
    }
11972
 
1731 ankur.sing 11973
    public getSuccessfulPaymentsAmountRange_args() {
1629 ankur.sing 11974
    }
11975
 
11976
    /**
11977
     * Performs a deep copy on <i>other</i>.
11978
     */
1731 ankur.sing 11979
    public getSuccessfulPaymentsAmountRange_args(getSuccessfulPaymentsAmountRange_args other) {
1629 ankur.sing 11980
    }
11981
 
1731 ankur.sing 11982
    public getSuccessfulPaymentsAmountRange_args deepCopy() {
11983
      return new getSuccessfulPaymentsAmountRange_args(this);
1629 ankur.sing 11984
    }
11985
 
3430 rajveer 11986
    @Override
11987
    public void clear() {
1629 ankur.sing 11988
    }
11989
 
11990
    public void setFieldValue(_Fields field, Object value) {
11991
      switch (field) {
11992
      }
11993
    }
11994
 
11995
    public Object getFieldValue(_Fields field) {
11996
      switch (field) {
11997
      }
11998
      throw new IllegalStateException();
11999
    }
12000
 
3430 rajveer 12001
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12002
    public boolean isSet(_Fields field) {
12003
      if (field == null) {
12004
        throw new IllegalArgumentException();
12005
      }
1629 ankur.sing 12006
 
12007
      switch (field) {
12008
      }
12009
      throw new IllegalStateException();
12010
    }
12011
 
12012
    @Override
12013
    public boolean equals(Object that) {
12014
      if (that == null)
12015
        return false;
1731 ankur.sing 12016
      if (that instanceof getSuccessfulPaymentsAmountRange_args)
12017
        return this.equals((getSuccessfulPaymentsAmountRange_args)that);
1629 ankur.sing 12018
      return false;
12019
    }
12020
 
1731 ankur.sing 12021
    public boolean equals(getSuccessfulPaymentsAmountRange_args that) {
1629 ankur.sing 12022
      if (that == null)
12023
        return false;
12024
 
12025
      return true;
12026
    }
12027
 
12028
    @Override
12029
    public int hashCode() {
12030
      return 0;
12031
    }
12032
 
1731 ankur.sing 12033
    public int compareTo(getSuccessfulPaymentsAmountRange_args other) {
1629 ankur.sing 12034
      if (!getClass().equals(other.getClass())) {
12035
        return getClass().getName().compareTo(other.getClass().getName());
12036
      }
12037
 
12038
      int lastComparison = 0;
1731 ankur.sing 12039
      getSuccessfulPaymentsAmountRange_args typedOther = (getSuccessfulPaymentsAmountRange_args)other;
1629 ankur.sing 12040
 
12041
      return 0;
12042
    }
12043
 
3430 rajveer 12044
    public _Fields fieldForId(int fieldId) {
12045
      return _Fields.findByThriftId(fieldId);
12046
    }
12047
 
12048
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12049
      org.apache.thrift.protocol.TField field;
1629 ankur.sing 12050
      iprot.readStructBegin();
12051
      while (true)
12052
      {
12053
        field = iprot.readFieldBegin();
3430 rajveer 12054
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1629 ankur.sing 12055
          break;
12056
        }
3430 rajveer 12057
        switch (field.id) {
12058
          default:
12059
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1629 ankur.sing 12060
        }
3430 rajveer 12061
        iprot.readFieldEnd();
1629 ankur.sing 12062
      }
12063
      iprot.readStructEnd();
12064
      validate();
12065
    }
12066
 
3430 rajveer 12067
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1629 ankur.sing 12068
      validate();
12069
 
12070
      oprot.writeStructBegin(STRUCT_DESC);
12071
      oprot.writeFieldStop();
12072
      oprot.writeStructEnd();
12073
    }
12074
 
12075
    @Override
12076
    public String toString() {
1731 ankur.sing 12077
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentsAmountRange_args(");
1629 ankur.sing 12078
      boolean first = true;
12079
 
12080
      sb.append(")");
12081
      return sb.toString();
12082
    }
12083
 
3430 rajveer 12084
    public void validate() throws org.apache.thrift.TException {
1629 ankur.sing 12085
      // check for required fields
12086
    }
12087
 
3430 rajveer 12088
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12089
      try {
12090
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12091
      } catch (org.apache.thrift.TException te) {
12092
        throw new java.io.IOException(te);
12093
      }
12094
    }
12095
 
12096
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12097
      try {
12098
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12099
      } catch (org.apache.thrift.TException te) {
12100
        throw new java.io.IOException(te);
12101
      }
12102
    }
12103
 
1629 ankur.sing 12104
  }
12105
 
3430 rajveer 12106
  public static class getSuccessfulPaymentsAmountRange_result implements org.apache.thrift.TBase<getSuccessfulPaymentsAmountRange_result, getSuccessfulPaymentsAmountRange_result._Fields>, java.io.Serializable, Cloneable   {
12107
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentsAmountRange_result");
1629 ankur.sing 12108
 
3430 rajveer 12109
    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 12110
 
3430 rajveer 12111
    private List<Double> success; // required
1629 ankur.sing 12112
 
12113
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 12114
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1629 ankur.sing 12115
      SUCCESS((short)0, "success");
12116
 
12117
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12118
 
12119
      static {
12120
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12121
          byName.put(field.getFieldName(), field);
12122
        }
12123
      }
12124
 
12125
      /**
12126
       * Find the _Fields constant that matches fieldId, or null if its not found.
12127
       */
12128
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 12129
        switch(fieldId) {
12130
          case 0: // SUCCESS
12131
            return SUCCESS;
12132
          default:
12133
            return null;
12134
        }
1629 ankur.sing 12135
      }
12136
 
12137
      /**
12138
       * Find the _Fields constant that matches fieldId, throwing an exception
12139
       * if it is not found.
12140
       */
12141
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12142
        _Fields fields = findByThriftId(fieldId);
12143
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12144
        return fields;
12145
      }
12146
 
12147
      /**
12148
       * Find the _Fields constant that matches name, or null if its not found.
12149
       */
12150
      public static _Fields findByName(String name) {
12151
        return byName.get(name);
12152
      }
12153
 
12154
      private final short _thriftId;
12155
      private final String _fieldName;
12156
 
12157
      _Fields(short thriftId, String fieldName) {
12158
        _thriftId = thriftId;
12159
        _fieldName = fieldName;
12160
      }
12161
 
12162
      public short getThriftFieldId() {
12163
        return _thriftId;
12164
      }
12165
 
12166
      public String getFieldName() {
12167
        return _fieldName;
12168
      }
12169
    }
12170
 
12171
    // isset id assignments
12172
 
3430 rajveer 12173
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1629 ankur.sing 12174
    static {
3430 rajveer 12175
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12176
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12177
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
12178
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE))));
12179
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12180
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentsAmountRange_result.class, metaDataMap);
1629 ankur.sing 12181
    }
12182
 
1731 ankur.sing 12183
    public getSuccessfulPaymentsAmountRange_result() {
1629 ankur.sing 12184
    }
12185
 
1731 ankur.sing 12186
    public getSuccessfulPaymentsAmountRange_result(
12187
      List<Double> success)
1629 ankur.sing 12188
    {
12189
      this();
12190
      this.success = success;
12191
    }
12192
 
12193
    /**
12194
     * Performs a deep copy on <i>other</i>.
12195
     */
1731 ankur.sing 12196
    public getSuccessfulPaymentsAmountRange_result(getSuccessfulPaymentsAmountRange_result other) {
12197
      if (other.isSetSuccess()) {
12198
        List<Double> __this__success = new ArrayList<Double>();
12199
        for (Double other_element : other.success) {
12200
          __this__success.add(other_element);
1629 ankur.sing 12201
        }
1731 ankur.sing 12202
        this.success = __this__success;
1629 ankur.sing 12203
      }
12204
    }
12205
 
1731 ankur.sing 12206
    public getSuccessfulPaymentsAmountRange_result deepCopy() {
12207
      return new getSuccessfulPaymentsAmountRange_result(this);
1629 ankur.sing 12208
    }
12209
 
3430 rajveer 12210
    @Override
12211
    public void clear() {
12212
      this.success = null;
1629 ankur.sing 12213
    }
12214
 
1731 ankur.sing 12215
    public int getSuccessSize() {
12216
      return (this.success == null) ? 0 : this.success.size();
1629 ankur.sing 12217
    }
12218
 
1731 ankur.sing 12219
    public java.util.Iterator<Double> getSuccessIterator() {
12220
      return (this.success == null) ? null : this.success.iterator();
1629 ankur.sing 12221
    }
12222
 
1731 ankur.sing 12223
    public void addToSuccess(double elem) {
12224
      if (this.success == null) {
12225
        this.success = new ArrayList<Double>();
1629 ankur.sing 12226
      }
1731 ankur.sing 12227
      this.success.add(elem);
1629 ankur.sing 12228
    }
12229
 
1731 ankur.sing 12230
    public List<Double> getSuccess() {
1629 ankur.sing 12231
      return this.success;
12232
    }
12233
 
3430 rajveer 12234
    public void setSuccess(List<Double> success) {
1629 ankur.sing 12235
      this.success = success;
12236
    }
12237
 
12238
    public void unsetSuccess() {
1731 ankur.sing 12239
      this.success = null;
1629 ankur.sing 12240
    }
12241
 
3430 rajveer 12242
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
1629 ankur.sing 12243
    public boolean isSetSuccess() {
1731 ankur.sing 12244
      return this.success != null;
1629 ankur.sing 12245
    }
12246
 
12247
    public void setSuccessIsSet(boolean value) {
1731 ankur.sing 12248
      if (!value) {
12249
        this.success = null;
12250
      }
1629 ankur.sing 12251
    }
12252
 
12253
    public void setFieldValue(_Fields field, Object value) {
12254
      switch (field) {
12255
      case SUCCESS:
12256
        if (value == null) {
12257
          unsetSuccess();
12258
        } else {
1731 ankur.sing 12259
          setSuccess((List<Double>)value);
1629 ankur.sing 12260
        }
12261
        break;
12262
 
12263
      }
12264
    }
12265
 
12266
    public Object getFieldValue(_Fields field) {
12267
      switch (field) {
12268
      case SUCCESS:
1731 ankur.sing 12269
        return getSuccess();
1629 ankur.sing 12270
 
12271
      }
12272
      throw new IllegalStateException();
12273
    }
12274
 
3430 rajveer 12275
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12276
    public boolean isSet(_Fields field) {
12277
      if (field == null) {
12278
        throw new IllegalArgumentException();
12279
      }
1629 ankur.sing 12280
 
12281
      switch (field) {
12282
      case SUCCESS:
12283
        return isSetSuccess();
12284
      }
12285
      throw new IllegalStateException();
12286
    }
12287
 
12288
    @Override
12289
    public boolean equals(Object that) {
12290
      if (that == null)
12291
        return false;
1731 ankur.sing 12292
      if (that instanceof getSuccessfulPaymentsAmountRange_result)
12293
        return this.equals((getSuccessfulPaymentsAmountRange_result)that);
1629 ankur.sing 12294
      return false;
12295
    }
12296
 
1731 ankur.sing 12297
    public boolean equals(getSuccessfulPaymentsAmountRange_result that) {
1629 ankur.sing 12298
      if (that == null)
12299
        return false;
12300
 
1731 ankur.sing 12301
      boolean this_present_success = true && this.isSetSuccess();
12302
      boolean that_present_success = true && that.isSetSuccess();
1629 ankur.sing 12303
      if (this_present_success || that_present_success) {
12304
        if (!(this_present_success && that_present_success))
12305
          return false;
1731 ankur.sing 12306
        if (!this.success.equals(that.success))
1629 ankur.sing 12307
          return false;
12308
      }
12309
 
12310
      return true;
12311
    }
12312
 
12313
    @Override
12314
    public int hashCode() {
12315
      return 0;
12316
    }
12317
 
1731 ankur.sing 12318
    public int compareTo(getSuccessfulPaymentsAmountRange_result other) {
1629 ankur.sing 12319
      if (!getClass().equals(other.getClass())) {
12320
        return getClass().getName().compareTo(other.getClass().getName());
12321
      }
12322
 
12323
      int lastComparison = 0;
1731 ankur.sing 12324
      getSuccessfulPaymentsAmountRange_result typedOther = (getSuccessfulPaymentsAmountRange_result)other;
1629 ankur.sing 12325
 
3430 rajveer 12326
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
1629 ankur.sing 12327
      if (lastComparison != 0) {
12328
        return lastComparison;
12329
      }
3430 rajveer 12330
      if (isSetSuccess()) {
12331
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12332
        if (lastComparison != 0) {
12333
          return lastComparison;
12334
        }
1629 ankur.sing 12335
      }
12336
      return 0;
12337
    }
12338
 
3430 rajveer 12339
    public _Fields fieldForId(int fieldId) {
12340
      return _Fields.findByThriftId(fieldId);
12341
    }
12342
 
12343
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12344
      org.apache.thrift.protocol.TField field;
1629 ankur.sing 12345
      iprot.readStructBegin();
12346
      while (true)
12347
      {
12348
        field = iprot.readFieldBegin();
3430 rajveer 12349
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1629 ankur.sing 12350
          break;
12351
        }
3430 rajveer 12352
        switch (field.id) {
12353
          case 0: // SUCCESS
12354
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
12355
              {
7049 anupam.sin 12356
                org.apache.thrift.protocol.TList _list40 = iprot.readListBegin();
12357
                this.success = new ArrayList<Double>(_list40.size);
12358
                for (int _i41 = 0; _i41 < _list40.size; ++_i41)
1731 ankur.sing 12359
                {
7049 anupam.sin 12360
                  double _elem42; // required
12361
                  _elem42 = iprot.readDouble();
12362
                  this.success.add(_elem42);
1731 ankur.sing 12363
                }
3430 rajveer 12364
                iprot.readListEnd();
1629 ankur.sing 12365
              }
3430 rajveer 12366
            } else { 
12367
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12368
            }
12369
            break;
12370
          default:
12371
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1629 ankur.sing 12372
        }
3430 rajveer 12373
        iprot.readFieldEnd();
1629 ankur.sing 12374
      }
12375
      iprot.readStructEnd();
12376
      validate();
12377
    }
12378
 
3430 rajveer 12379
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1629 ankur.sing 12380
      oprot.writeStructBegin(STRUCT_DESC);
12381
 
12382
      if (this.isSetSuccess()) {
12383
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
1731 ankur.sing 12384
        {
3430 rajveer 12385
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.DOUBLE, this.success.size()));
7049 anupam.sin 12386
          for (double _iter43 : this.success)
1731 ankur.sing 12387
          {
7049 anupam.sin 12388
            oprot.writeDouble(_iter43);
1731 ankur.sing 12389
          }
12390
          oprot.writeListEnd();
12391
        }
1629 ankur.sing 12392
        oprot.writeFieldEnd();
12393
      }
12394
      oprot.writeFieldStop();
12395
      oprot.writeStructEnd();
12396
    }
12397
 
12398
    @Override
12399
    public String toString() {
1731 ankur.sing 12400
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentsAmountRange_result(");
1629 ankur.sing 12401
      boolean first = true;
12402
 
12403
      sb.append("success:");
1731 ankur.sing 12404
      if (this.success == null) {
12405
        sb.append("null");
12406
      } else {
12407
        sb.append(this.success);
12408
      }
1629 ankur.sing 12409
      first = false;
12410
      sb.append(")");
12411
      return sb.toString();
12412
    }
12413
 
3430 rajveer 12414
    public void validate() throws org.apache.thrift.TException {
1629 ankur.sing 12415
      // check for required fields
12416
    }
12417
 
3430 rajveer 12418
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12419
      try {
12420
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12421
      } catch (org.apache.thrift.TException te) {
12422
        throw new java.io.IOException(te);
12423
      }
12424
    }
12425
 
12426
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12427
      try {
12428
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12429
      } catch (org.apache.thrift.TException te) {
12430
        throw new java.io.IOException(te);
12431
      }
12432
    }
12433
 
1629 ankur.sing 12434
  }
12435
 
3430 rajveer 12436
  public static class initializeHdfcPayment_args implements org.apache.thrift.TBase<initializeHdfcPayment_args, initializeHdfcPayment_args._Fields>, java.io.Serializable, Cloneable   {
12437
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcPayment_args");
2462 chandransh 12438
 
3430 rajveer 12439
    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);
10269 amit.gupta 12440
    private static final org.apache.thrift.protocol.TField IS_MOBILE_FIELD_DESC = new org.apache.thrift.protocol.TField("isMobile", org.apache.thrift.protocol.TType.BOOL, (short)2);
2462 chandransh 12441
 
3430 rajveer 12442
    private long merchantPaymentId; // required
10269 amit.gupta 12443
    private boolean isMobile; // required
2462 chandransh 12444
 
12445
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 12446
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10269 amit.gupta 12447
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId"),
12448
      IS_MOBILE((short)2, "isMobile");
2462 chandransh 12449
 
12450
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12451
 
12452
      static {
12453
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12454
          byName.put(field.getFieldName(), field);
12455
        }
12456
      }
12457
 
12458
      /**
12459
       * Find the _Fields constant that matches fieldId, or null if its not found.
12460
       */
12461
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 12462
        switch(fieldId) {
12463
          case 1: // MERCHANT_PAYMENT_ID
12464
            return MERCHANT_PAYMENT_ID;
10269 amit.gupta 12465
          case 2: // IS_MOBILE
12466
            return IS_MOBILE;
3430 rajveer 12467
          default:
12468
            return null;
12469
        }
2462 chandransh 12470
      }
12471
 
12472
      /**
12473
       * Find the _Fields constant that matches fieldId, throwing an exception
12474
       * if it is not found.
12475
       */
12476
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12477
        _Fields fields = findByThriftId(fieldId);
12478
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12479
        return fields;
12480
      }
12481
 
12482
      /**
12483
       * Find the _Fields constant that matches name, or null if its not found.
12484
       */
12485
      public static _Fields findByName(String name) {
12486
        return byName.get(name);
12487
      }
12488
 
12489
      private final short _thriftId;
12490
      private final String _fieldName;
12491
 
12492
      _Fields(short thriftId, String fieldName) {
12493
        _thriftId = thriftId;
12494
        _fieldName = fieldName;
12495
      }
12496
 
12497
      public short getThriftFieldId() {
12498
        return _thriftId;
12499
      }
12500
 
12501
      public String getFieldName() {
12502
        return _fieldName;
12503
      }
12504
    }
12505
 
12506
    // isset id assignments
12507
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
10269 amit.gupta 12508
    private static final int __ISMOBILE_ISSET_ID = 1;
12509
    private BitSet __isset_bit_vector = new BitSet(2);
2462 chandransh 12510
 
3430 rajveer 12511
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 12512
    static {
3430 rajveer 12513
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12514
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12515
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10269 amit.gupta 12516
      tmpMap.put(_Fields.IS_MOBILE, new org.apache.thrift.meta_data.FieldMetaData("isMobile", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12517
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
3430 rajveer 12518
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12519
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcPayment_args.class, metaDataMap);
2462 chandransh 12520
    }
12521
 
3010 chandransh 12522
    public initializeHdfcPayment_args() {
2462 chandransh 12523
    }
12524
 
3010 chandransh 12525
    public initializeHdfcPayment_args(
10269 amit.gupta 12526
      long merchantPaymentId,
12527
      boolean isMobile)
2462 chandransh 12528
    {
12529
      this();
12530
      this.merchantPaymentId = merchantPaymentId;
12531
      setMerchantPaymentIdIsSet(true);
10269 amit.gupta 12532
      this.isMobile = isMobile;
12533
      setIsMobileIsSet(true);
2462 chandransh 12534
    }
12535
 
12536
    /**
12537
     * Performs a deep copy on <i>other</i>.
12538
     */
3010 chandransh 12539
    public initializeHdfcPayment_args(initializeHdfcPayment_args other) {
2462 chandransh 12540
      __isset_bit_vector.clear();
12541
      __isset_bit_vector.or(other.__isset_bit_vector);
12542
      this.merchantPaymentId = other.merchantPaymentId;
10269 amit.gupta 12543
      this.isMobile = other.isMobile;
2462 chandransh 12544
    }
12545
 
3010 chandransh 12546
    public initializeHdfcPayment_args deepCopy() {
12547
      return new initializeHdfcPayment_args(this);
2462 chandransh 12548
    }
12549
 
3430 rajveer 12550
    @Override
12551
    public void clear() {
12552
      setMerchantPaymentIdIsSet(false);
12553
      this.merchantPaymentId = 0;
10269 amit.gupta 12554
      setIsMobileIsSet(false);
12555
      this.isMobile = false;
2462 chandransh 12556
    }
12557
 
12558
    public long getMerchantPaymentId() {
12559
      return this.merchantPaymentId;
12560
    }
12561
 
3430 rajveer 12562
    public void setMerchantPaymentId(long merchantPaymentId) {
2462 chandransh 12563
      this.merchantPaymentId = merchantPaymentId;
12564
      setMerchantPaymentIdIsSet(true);
12565
    }
12566
 
12567
    public void unsetMerchantPaymentId() {
12568
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
12569
    }
12570
 
3430 rajveer 12571
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
2462 chandransh 12572
    public boolean isSetMerchantPaymentId() {
12573
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
12574
    }
12575
 
12576
    public void setMerchantPaymentIdIsSet(boolean value) {
12577
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
12578
    }
12579
 
10269 amit.gupta 12580
    public boolean isIsMobile() {
12581
      return this.isMobile;
12582
    }
12583
 
12584
    public void setIsMobile(boolean isMobile) {
12585
      this.isMobile = isMobile;
12586
      setIsMobileIsSet(true);
12587
    }
12588
 
12589
    public void unsetIsMobile() {
12590
      __isset_bit_vector.clear(__ISMOBILE_ISSET_ID);
12591
    }
12592
 
12593
    /** Returns true if field isMobile is set (has been assigned a value) and false otherwise */
12594
    public boolean isSetIsMobile() {
12595
      return __isset_bit_vector.get(__ISMOBILE_ISSET_ID);
12596
    }
12597
 
12598
    public void setIsMobileIsSet(boolean value) {
12599
      __isset_bit_vector.set(__ISMOBILE_ISSET_ID, value);
12600
    }
12601
 
2462 chandransh 12602
    public void setFieldValue(_Fields field, Object value) {
12603
      switch (field) {
12604
      case MERCHANT_PAYMENT_ID:
12605
        if (value == null) {
12606
          unsetMerchantPaymentId();
12607
        } else {
12608
          setMerchantPaymentId((Long)value);
12609
        }
12610
        break;
12611
 
10269 amit.gupta 12612
      case IS_MOBILE:
12613
        if (value == null) {
12614
          unsetIsMobile();
12615
        } else {
12616
          setIsMobile((Boolean)value);
12617
        }
12618
        break;
12619
 
2462 chandransh 12620
      }
12621
    }
12622
 
12623
    public Object getFieldValue(_Fields field) {
12624
      switch (field) {
12625
      case MERCHANT_PAYMENT_ID:
3430 rajveer 12626
        return Long.valueOf(getMerchantPaymentId());
2462 chandransh 12627
 
10269 amit.gupta 12628
      case IS_MOBILE:
12629
        return Boolean.valueOf(isIsMobile());
12630
 
2462 chandransh 12631
      }
12632
      throw new IllegalStateException();
12633
    }
12634
 
3430 rajveer 12635
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12636
    public boolean isSet(_Fields field) {
12637
      if (field == null) {
12638
        throw new IllegalArgumentException();
12639
      }
2462 chandransh 12640
 
12641
      switch (field) {
12642
      case MERCHANT_PAYMENT_ID:
12643
        return isSetMerchantPaymentId();
10269 amit.gupta 12644
      case IS_MOBILE:
12645
        return isSetIsMobile();
2462 chandransh 12646
      }
12647
      throw new IllegalStateException();
12648
    }
12649
 
12650
    @Override
12651
    public boolean equals(Object that) {
12652
      if (that == null)
12653
        return false;
3010 chandransh 12654
      if (that instanceof initializeHdfcPayment_args)
12655
        return this.equals((initializeHdfcPayment_args)that);
2462 chandransh 12656
      return false;
12657
    }
12658
 
3010 chandransh 12659
    public boolean equals(initializeHdfcPayment_args that) {
2462 chandransh 12660
      if (that == null)
12661
        return false;
12662
 
12663
      boolean this_present_merchantPaymentId = true;
12664
      boolean that_present_merchantPaymentId = true;
12665
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
12666
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
12667
          return false;
12668
        if (this.merchantPaymentId != that.merchantPaymentId)
12669
          return false;
12670
      }
12671
 
10269 amit.gupta 12672
      boolean this_present_isMobile = true;
12673
      boolean that_present_isMobile = true;
12674
      if (this_present_isMobile || that_present_isMobile) {
12675
        if (!(this_present_isMobile && that_present_isMobile))
12676
          return false;
12677
        if (this.isMobile != that.isMobile)
12678
          return false;
12679
      }
12680
 
2462 chandransh 12681
      return true;
12682
    }
12683
 
12684
    @Override
12685
    public int hashCode() {
12686
      return 0;
12687
    }
12688
 
3010 chandransh 12689
    public int compareTo(initializeHdfcPayment_args other) {
2462 chandransh 12690
      if (!getClass().equals(other.getClass())) {
12691
        return getClass().getName().compareTo(other.getClass().getName());
12692
      }
12693
 
12694
      int lastComparison = 0;
3010 chandransh 12695
      initializeHdfcPayment_args typedOther = (initializeHdfcPayment_args)other;
2462 chandransh 12696
 
3430 rajveer 12697
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
2462 chandransh 12698
      if (lastComparison != 0) {
12699
        return lastComparison;
12700
      }
3430 rajveer 12701
      if (isSetMerchantPaymentId()) {
12702
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
12703
        if (lastComparison != 0) {
12704
          return lastComparison;
12705
        }
2462 chandransh 12706
      }
10269 amit.gupta 12707
      lastComparison = Boolean.valueOf(isSetIsMobile()).compareTo(typedOther.isSetIsMobile());
12708
      if (lastComparison != 0) {
12709
        return lastComparison;
12710
      }
12711
      if (isSetIsMobile()) {
12712
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isMobile, typedOther.isMobile);
12713
        if (lastComparison != 0) {
12714
          return lastComparison;
12715
        }
12716
      }
2462 chandransh 12717
      return 0;
12718
    }
12719
 
3430 rajveer 12720
    public _Fields fieldForId(int fieldId) {
12721
      return _Fields.findByThriftId(fieldId);
12722
    }
12723
 
12724
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12725
      org.apache.thrift.protocol.TField field;
2462 chandransh 12726
      iprot.readStructBegin();
12727
      while (true)
12728
      {
12729
        field = iprot.readFieldBegin();
3430 rajveer 12730
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 12731
          break;
12732
        }
3430 rajveer 12733
        switch (field.id) {
12734
          case 1: // MERCHANT_PAYMENT_ID
12735
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12736
              this.merchantPaymentId = iprot.readI64();
12737
              setMerchantPaymentIdIsSet(true);
12738
            } else { 
12739
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12740
            }
12741
            break;
10269 amit.gupta 12742
          case 2: // IS_MOBILE
12743
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
12744
              this.isMobile = iprot.readBool();
12745
              setIsMobileIsSet(true);
12746
            } else { 
12747
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12748
            }
12749
            break;
3430 rajveer 12750
          default:
12751
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 12752
        }
3430 rajveer 12753
        iprot.readFieldEnd();
2462 chandransh 12754
      }
12755
      iprot.readStructEnd();
12756
      validate();
12757
    }
12758
 
3430 rajveer 12759
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 12760
      validate();
12761
 
12762
      oprot.writeStructBegin(STRUCT_DESC);
12763
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
12764
      oprot.writeI64(this.merchantPaymentId);
12765
      oprot.writeFieldEnd();
10269 amit.gupta 12766
      oprot.writeFieldBegin(IS_MOBILE_FIELD_DESC);
12767
      oprot.writeBool(this.isMobile);
12768
      oprot.writeFieldEnd();
2462 chandransh 12769
      oprot.writeFieldStop();
12770
      oprot.writeStructEnd();
12771
    }
12772
 
12773
    @Override
12774
    public String toString() {
3010 chandransh 12775
      StringBuilder sb = new StringBuilder("initializeHdfcPayment_args(");
2462 chandransh 12776
      boolean first = true;
12777
 
12778
      sb.append("merchantPaymentId:");
12779
      sb.append(this.merchantPaymentId);
12780
      first = false;
10269 amit.gupta 12781
      if (!first) sb.append(", ");
12782
      sb.append("isMobile:");
12783
      sb.append(this.isMobile);
12784
      first = false;
2462 chandransh 12785
      sb.append(")");
12786
      return sb.toString();
12787
    }
12788
 
3430 rajveer 12789
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 12790
      // check for required fields
12791
    }
12792
 
3430 rajveer 12793
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12794
      try {
12795
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12796
      } catch (org.apache.thrift.TException te) {
12797
        throw new java.io.IOException(te);
12798
      }
12799
    }
12800
 
12801
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12802
      try {
12803
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12804
      } catch (org.apache.thrift.TException te) {
12805
        throw new java.io.IOException(te);
12806
      }
12807
    }
12808
 
2462 chandransh 12809
  }
12810
 
3430 rajveer 12811
  public static class initializeHdfcPayment_result implements org.apache.thrift.TBase<initializeHdfcPayment_result, initializeHdfcPayment_result._Fields>, java.io.Serializable, Cloneable   {
12812
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcPayment_result");
2462 chandransh 12813
 
3430 rajveer 12814
    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);
12815
    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 12816
 
3430 rajveer 12817
    private String success; // required
12818
    private PaymentException pe; // required
2462 chandransh 12819
 
12820
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 12821
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 12822
      SUCCESS((short)0, "success"),
12823
      PE((short)1, "pe");
12824
 
12825
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12826
 
12827
      static {
12828
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12829
          byName.put(field.getFieldName(), field);
12830
        }
12831
      }
12832
 
12833
      /**
12834
       * Find the _Fields constant that matches fieldId, or null if its not found.
12835
       */
12836
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 12837
        switch(fieldId) {
12838
          case 0: // SUCCESS
12839
            return SUCCESS;
12840
          case 1: // PE
12841
            return PE;
12842
          default:
12843
            return null;
12844
        }
2462 chandransh 12845
      }
12846
 
12847
      /**
12848
       * Find the _Fields constant that matches fieldId, throwing an exception
12849
       * if it is not found.
12850
       */
12851
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12852
        _Fields fields = findByThriftId(fieldId);
12853
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12854
        return fields;
12855
      }
12856
 
12857
      /**
12858
       * Find the _Fields constant that matches name, or null if its not found.
12859
       */
12860
      public static _Fields findByName(String name) {
12861
        return byName.get(name);
12862
      }
12863
 
12864
      private final short _thriftId;
12865
      private final String _fieldName;
12866
 
12867
      _Fields(short thriftId, String fieldName) {
12868
        _thriftId = thriftId;
12869
        _fieldName = fieldName;
12870
      }
12871
 
12872
      public short getThriftFieldId() {
12873
        return _thriftId;
12874
      }
12875
 
12876
      public String getFieldName() {
12877
        return _fieldName;
12878
      }
12879
    }
12880
 
12881
    // isset id assignments
12882
 
3430 rajveer 12883
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 12884
    static {
3430 rajveer 12885
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12886
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12887
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
12888
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12889
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
12890
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12891
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcPayment_result.class, metaDataMap);
2462 chandransh 12892
    }
12893
 
3010 chandransh 12894
    public initializeHdfcPayment_result() {
2462 chandransh 12895
    }
12896
 
3010 chandransh 12897
    public initializeHdfcPayment_result(
12898
      String success,
2462 chandransh 12899
      PaymentException pe)
12900
    {
12901
      this();
12902
      this.success = success;
12903
      this.pe = pe;
12904
    }
12905
 
12906
    /**
12907
     * Performs a deep copy on <i>other</i>.
12908
     */
3010 chandransh 12909
    public initializeHdfcPayment_result(initializeHdfcPayment_result other) {
2462 chandransh 12910
      if (other.isSetSuccess()) {
3010 chandransh 12911
        this.success = other.success;
2462 chandransh 12912
      }
12913
      if (other.isSetPe()) {
12914
        this.pe = new PaymentException(other.pe);
12915
      }
12916
    }
12917
 
3010 chandransh 12918
    public initializeHdfcPayment_result deepCopy() {
12919
      return new initializeHdfcPayment_result(this);
2462 chandransh 12920
    }
12921
 
3430 rajveer 12922
    @Override
12923
    public void clear() {
12924
      this.success = null;
12925
      this.pe = null;
2462 chandransh 12926
    }
12927
 
3010 chandransh 12928
    public String getSuccess() {
2462 chandransh 12929
      return this.success;
12930
    }
12931
 
3430 rajveer 12932
    public void setSuccess(String success) {
2462 chandransh 12933
      this.success = success;
12934
    }
12935
 
12936
    public void unsetSuccess() {
12937
      this.success = null;
12938
    }
12939
 
3430 rajveer 12940
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2462 chandransh 12941
    public boolean isSetSuccess() {
12942
      return this.success != null;
12943
    }
12944
 
12945
    public void setSuccessIsSet(boolean value) {
12946
      if (!value) {
12947
        this.success = null;
12948
      }
12949
    }
12950
 
12951
    public PaymentException getPe() {
12952
      return this.pe;
12953
    }
12954
 
3430 rajveer 12955
    public void setPe(PaymentException pe) {
2462 chandransh 12956
      this.pe = pe;
12957
    }
12958
 
12959
    public void unsetPe() {
12960
      this.pe = null;
12961
    }
12962
 
3430 rajveer 12963
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2462 chandransh 12964
    public boolean isSetPe() {
12965
      return this.pe != null;
12966
    }
12967
 
12968
    public void setPeIsSet(boolean value) {
12969
      if (!value) {
12970
        this.pe = null;
12971
      }
12972
    }
12973
 
12974
    public void setFieldValue(_Fields field, Object value) {
12975
      switch (field) {
12976
      case SUCCESS:
12977
        if (value == null) {
12978
          unsetSuccess();
12979
        } else {
3010 chandransh 12980
          setSuccess((String)value);
2462 chandransh 12981
        }
12982
        break;
12983
 
12984
      case PE:
12985
        if (value == null) {
12986
          unsetPe();
12987
        } else {
12988
          setPe((PaymentException)value);
12989
        }
12990
        break;
12991
 
12992
      }
12993
    }
12994
 
12995
    public Object getFieldValue(_Fields field) {
12996
      switch (field) {
12997
      case SUCCESS:
12998
        return getSuccess();
12999
 
13000
      case PE:
13001
        return getPe();
13002
 
13003
      }
13004
      throw new IllegalStateException();
13005
    }
13006
 
3430 rajveer 13007
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13008
    public boolean isSet(_Fields field) {
13009
      if (field == null) {
13010
        throw new IllegalArgumentException();
13011
      }
2462 chandransh 13012
 
13013
      switch (field) {
13014
      case SUCCESS:
13015
        return isSetSuccess();
13016
      case PE:
13017
        return isSetPe();
13018
      }
13019
      throw new IllegalStateException();
13020
    }
13021
 
13022
    @Override
13023
    public boolean equals(Object that) {
13024
      if (that == null)
13025
        return false;
3010 chandransh 13026
      if (that instanceof initializeHdfcPayment_result)
13027
        return this.equals((initializeHdfcPayment_result)that);
2462 chandransh 13028
      return false;
13029
    }
13030
 
3010 chandransh 13031
    public boolean equals(initializeHdfcPayment_result that) {
2462 chandransh 13032
      if (that == null)
13033
        return false;
13034
 
13035
      boolean this_present_success = true && this.isSetSuccess();
13036
      boolean that_present_success = true && that.isSetSuccess();
13037
      if (this_present_success || that_present_success) {
13038
        if (!(this_present_success && that_present_success))
13039
          return false;
13040
        if (!this.success.equals(that.success))
13041
          return false;
13042
      }
13043
 
13044
      boolean this_present_pe = true && this.isSetPe();
13045
      boolean that_present_pe = true && that.isSetPe();
13046
      if (this_present_pe || that_present_pe) {
13047
        if (!(this_present_pe && that_present_pe))
13048
          return false;
13049
        if (!this.pe.equals(that.pe))
13050
          return false;
13051
      }
13052
 
13053
      return true;
13054
    }
13055
 
13056
    @Override
13057
    public int hashCode() {
13058
      return 0;
13059
    }
13060
 
3010 chandransh 13061
    public int compareTo(initializeHdfcPayment_result other) {
13062
      if (!getClass().equals(other.getClass())) {
13063
        return getClass().getName().compareTo(other.getClass().getName());
13064
      }
13065
 
13066
      int lastComparison = 0;
13067
      initializeHdfcPayment_result typedOther = (initializeHdfcPayment_result)other;
13068
 
3430 rajveer 13069
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3010 chandransh 13070
      if (lastComparison != 0) {
13071
        return lastComparison;
13072
      }
3430 rajveer 13073
      if (isSetSuccess()) {
13074
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13075
        if (lastComparison != 0) {
13076
          return lastComparison;
13077
        }
3010 chandransh 13078
      }
3430 rajveer 13079
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
3010 chandransh 13080
      if (lastComparison != 0) {
13081
        return lastComparison;
13082
      }
3430 rajveer 13083
      if (isSetPe()) {
13084
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
13085
        if (lastComparison != 0) {
13086
          return lastComparison;
13087
        }
3010 chandransh 13088
      }
13089
      return 0;
13090
    }
13091
 
3430 rajveer 13092
    public _Fields fieldForId(int fieldId) {
13093
      return _Fields.findByThriftId(fieldId);
13094
    }
13095
 
13096
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13097
      org.apache.thrift.protocol.TField field;
2462 chandransh 13098
      iprot.readStructBegin();
13099
      while (true)
13100
      {
13101
        field = iprot.readFieldBegin();
3430 rajveer 13102
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 13103
          break;
13104
        }
3430 rajveer 13105
        switch (field.id) {
13106
          case 0: // SUCCESS
13107
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
13108
              this.success = iprot.readString();
13109
            } else { 
13110
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13111
            }
13112
            break;
13113
          case 1: // PE
13114
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13115
              this.pe = new PaymentException();
13116
              this.pe.read(iprot);
13117
            } else { 
13118
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13119
            }
13120
            break;
13121
          default:
13122
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 13123
        }
3430 rajveer 13124
        iprot.readFieldEnd();
2462 chandransh 13125
      }
13126
      iprot.readStructEnd();
13127
      validate();
13128
    }
13129
 
3430 rajveer 13130
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 13131
      oprot.writeStructBegin(STRUCT_DESC);
13132
 
13133
      if (this.isSetSuccess()) {
13134
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 13135
        oprot.writeString(this.success);
2462 chandransh 13136
        oprot.writeFieldEnd();
13137
      } else if (this.isSetPe()) {
13138
        oprot.writeFieldBegin(PE_FIELD_DESC);
13139
        this.pe.write(oprot);
13140
        oprot.writeFieldEnd();
13141
      }
13142
      oprot.writeFieldStop();
13143
      oprot.writeStructEnd();
13144
    }
13145
 
13146
    @Override
13147
    public String toString() {
3010 chandransh 13148
      StringBuilder sb = new StringBuilder("initializeHdfcPayment_result(");
2462 chandransh 13149
      boolean first = true;
13150
 
13151
      sb.append("success:");
13152
      if (this.success == null) {
13153
        sb.append("null");
13154
      } else {
13155
        sb.append(this.success);
13156
      }
13157
      first = false;
13158
      if (!first) sb.append(", ");
13159
      sb.append("pe:");
13160
      if (this.pe == null) {
13161
        sb.append("null");
13162
      } else {
13163
        sb.append(this.pe);
13164
      }
13165
      first = false;
13166
      sb.append(")");
13167
      return sb.toString();
13168
    }
13169
 
3430 rajveer 13170
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 13171
      // check for required fields
13172
    }
13173
 
3430 rajveer 13174
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13175
      try {
13176
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13177
      } catch (org.apache.thrift.TException te) {
13178
        throw new java.io.IOException(te);
13179
      }
13180
    }
13181
 
13182
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13183
      try {
13184
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13185
      } catch (org.apache.thrift.TException te) {
13186
        throw new java.io.IOException(te);
13187
      }
13188
    }
13189
 
2462 chandransh 13190
  }
13191
 
6050 anupam.sin 13192
  public static class doHdfcPaymentForDigitalOrder_args implements org.apache.thrift.TBase<doHdfcPaymentForDigitalOrder_args, doHdfcPaymentForDigitalOrder_args._Fields>, java.io.Serializable, Cloneable   {
13193
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("doHdfcPaymentForDigitalOrder_args");
13194
 
13195
    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);
13196
    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);
10269 amit.gupta 13197
    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)3);
13198
    private static final org.apache.thrift.protocol.TField IS_MOBILE_FIELD_DESC = new org.apache.thrift.protocol.TField("isMobile", org.apache.thrift.protocol.TType.BOOL, (short)4);
6050 anupam.sin 13199
 
13200
    private long merchantPaymentId; // required
13201
    private long rechargeOrderId; // required
6228 anupam.sin 13202
    private String phone; // required
10269 amit.gupta 13203
    private boolean isMobile; // required
6050 anupam.sin 13204
 
13205
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13206
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13207
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId"),
6228 anupam.sin 13208
      RECHARGE_ORDER_ID((short)2, "rechargeOrderId"),
10269 amit.gupta 13209
      PHONE((short)3, "phone"),
13210
      IS_MOBILE((short)4, "isMobile");
6050 anupam.sin 13211
 
13212
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13213
 
13214
      static {
13215
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13216
          byName.put(field.getFieldName(), field);
13217
        }
13218
      }
13219
 
13220
      /**
13221
       * Find the _Fields constant that matches fieldId, or null if its not found.
13222
       */
13223
      public static _Fields findByThriftId(int fieldId) {
13224
        switch(fieldId) {
13225
          case 1: // MERCHANT_PAYMENT_ID
13226
            return MERCHANT_PAYMENT_ID;
13227
          case 2: // RECHARGE_ORDER_ID
13228
            return RECHARGE_ORDER_ID;
10269 amit.gupta 13229
          case 3: // PHONE
6228 anupam.sin 13230
            return PHONE;
10269 amit.gupta 13231
          case 4: // IS_MOBILE
13232
            return IS_MOBILE;
6050 anupam.sin 13233
          default:
13234
            return null;
13235
        }
13236
      }
13237
 
13238
      /**
13239
       * Find the _Fields constant that matches fieldId, throwing an exception
13240
       * if it is not found.
13241
       */
13242
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13243
        _Fields fields = findByThriftId(fieldId);
13244
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13245
        return fields;
13246
      }
13247
 
13248
      /**
13249
       * Find the _Fields constant that matches name, or null if its not found.
13250
       */
13251
      public static _Fields findByName(String name) {
13252
        return byName.get(name);
13253
      }
13254
 
13255
      private final short _thriftId;
13256
      private final String _fieldName;
13257
 
13258
      _Fields(short thriftId, String fieldName) {
13259
        _thriftId = thriftId;
13260
        _fieldName = fieldName;
13261
      }
13262
 
13263
      public short getThriftFieldId() {
13264
        return _thriftId;
13265
      }
13266
 
13267
      public String getFieldName() {
13268
        return _fieldName;
13269
      }
13270
    }
13271
 
13272
    // isset id assignments
13273
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
13274
    private static final int __RECHARGEORDERID_ISSET_ID = 1;
10269 amit.gupta 13275
    private static final int __ISMOBILE_ISSET_ID = 2;
13276
    private BitSet __isset_bit_vector = new BitSet(3);
6050 anupam.sin 13277
 
13278
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13279
    static {
13280
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13281
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13282
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13283
      tmpMap.put(_Fields.RECHARGE_ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("rechargeOrderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13284
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6228 anupam.sin 13285
      tmpMap.put(_Fields.PHONE, new org.apache.thrift.meta_data.FieldMetaData("phone", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13286
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10269 amit.gupta 13287
      tmpMap.put(_Fields.IS_MOBILE, new org.apache.thrift.meta_data.FieldMetaData("isMobile", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13288
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
6050 anupam.sin 13289
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13290
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(doHdfcPaymentForDigitalOrder_args.class, metaDataMap);
13291
    }
13292
 
13293
    public doHdfcPaymentForDigitalOrder_args() {
13294
    }
13295
 
13296
    public doHdfcPaymentForDigitalOrder_args(
13297
      long merchantPaymentId,
6228 anupam.sin 13298
      long rechargeOrderId,
10269 amit.gupta 13299
      String phone,
13300
      boolean isMobile)
6050 anupam.sin 13301
    {
13302
      this();
13303
      this.merchantPaymentId = merchantPaymentId;
13304
      setMerchantPaymentIdIsSet(true);
13305
      this.rechargeOrderId = rechargeOrderId;
13306
      setRechargeOrderIdIsSet(true);
6228 anupam.sin 13307
      this.phone = phone;
10269 amit.gupta 13308
      this.isMobile = isMobile;
13309
      setIsMobileIsSet(true);
6050 anupam.sin 13310
    }
13311
 
13312
    /**
13313
     * Performs a deep copy on <i>other</i>.
13314
     */
13315
    public doHdfcPaymentForDigitalOrder_args(doHdfcPaymentForDigitalOrder_args other) {
13316
      __isset_bit_vector.clear();
13317
      __isset_bit_vector.or(other.__isset_bit_vector);
13318
      this.merchantPaymentId = other.merchantPaymentId;
13319
      this.rechargeOrderId = other.rechargeOrderId;
6228 anupam.sin 13320
      if (other.isSetPhone()) {
13321
        this.phone = other.phone;
13322
      }
10269 amit.gupta 13323
      this.isMobile = other.isMobile;
6050 anupam.sin 13324
    }
13325
 
13326
    public doHdfcPaymentForDigitalOrder_args deepCopy() {
13327
      return new doHdfcPaymentForDigitalOrder_args(this);
13328
    }
13329
 
13330
    @Override
13331
    public void clear() {
13332
      setMerchantPaymentIdIsSet(false);
13333
      this.merchantPaymentId = 0;
13334
      setRechargeOrderIdIsSet(false);
13335
      this.rechargeOrderId = 0;
6228 anupam.sin 13336
      this.phone = null;
10269 amit.gupta 13337
      setIsMobileIsSet(false);
13338
      this.isMobile = false;
6050 anupam.sin 13339
    }
13340
 
13341
    public long getMerchantPaymentId() {
13342
      return this.merchantPaymentId;
13343
    }
13344
 
13345
    public void setMerchantPaymentId(long merchantPaymentId) {
13346
      this.merchantPaymentId = merchantPaymentId;
13347
      setMerchantPaymentIdIsSet(true);
13348
    }
13349
 
13350
    public void unsetMerchantPaymentId() {
13351
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
13352
    }
13353
 
13354
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
13355
    public boolean isSetMerchantPaymentId() {
13356
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
13357
    }
13358
 
13359
    public void setMerchantPaymentIdIsSet(boolean value) {
13360
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
13361
    }
13362
 
13363
    public long getRechargeOrderId() {
13364
      return this.rechargeOrderId;
13365
    }
13366
 
13367
    public void setRechargeOrderId(long rechargeOrderId) {
13368
      this.rechargeOrderId = rechargeOrderId;
13369
      setRechargeOrderIdIsSet(true);
13370
    }
13371
 
13372
    public void unsetRechargeOrderId() {
13373
      __isset_bit_vector.clear(__RECHARGEORDERID_ISSET_ID);
13374
    }
13375
 
13376
    /** Returns true if field rechargeOrderId is set (has been assigned a value) and false otherwise */
13377
    public boolean isSetRechargeOrderId() {
13378
      return __isset_bit_vector.get(__RECHARGEORDERID_ISSET_ID);
13379
    }
13380
 
13381
    public void setRechargeOrderIdIsSet(boolean value) {
13382
      __isset_bit_vector.set(__RECHARGEORDERID_ISSET_ID, value);
13383
    }
13384
 
6228 anupam.sin 13385
    public String getPhone() {
13386
      return this.phone;
13387
    }
13388
 
13389
    public void setPhone(String phone) {
13390
      this.phone = phone;
13391
    }
13392
 
13393
    public void unsetPhone() {
13394
      this.phone = null;
13395
    }
13396
 
13397
    /** Returns true if field phone is set (has been assigned a value) and false otherwise */
13398
    public boolean isSetPhone() {
13399
      return this.phone != null;
13400
    }
13401
 
13402
    public void setPhoneIsSet(boolean value) {
13403
      if (!value) {
13404
        this.phone = null;
13405
      }
13406
    }
13407
 
10269 amit.gupta 13408
    public boolean isIsMobile() {
13409
      return this.isMobile;
13410
    }
13411
 
13412
    public void setIsMobile(boolean isMobile) {
13413
      this.isMobile = isMobile;
13414
      setIsMobileIsSet(true);
13415
    }
13416
 
13417
    public void unsetIsMobile() {
13418
      __isset_bit_vector.clear(__ISMOBILE_ISSET_ID);
13419
    }
13420
 
13421
    /** Returns true if field isMobile is set (has been assigned a value) and false otherwise */
13422
    public boolean isSetIsMobile() {
13423
      return __isset_bit_vector.get(__ISMOBILE_ISSET_ID);
13424
    }
13425
 
13426
    public void setIsMobileIsSet(boolean value) {
13427
      __isset_bit_vector.set(__ISMOBILE_ISSET_ID, value);
13428
    }
13429
 
6050 anupam.sin 13430
    public void setFieldValue(_Fields field, Object value) {
13431
      switch (field) {
13432
      case MERCHANT_PAYMENT_ID:
13433
        if (value == null) {
13434
          unsetMerchantPaymentId();
13435
        } else {
13436
          setMerchantPaymentId((Long)value);
13437
        }
13438
        break;
13439
 
13440
      case RECHARGE_ORDER_ID:
13441
        if (value == null) {
13442
          unsetRechargeOrderId();
13443
        } else {
13444
          setRechargeOrderId((Long)value);
13445
        }
13446
        break;
13447
 
6228 anupam.sin 13448
      case PHONE:
13449
        if (value == null) {
13450
          unsetPhone();
13451
        } else {
13452
          setPhone((String)value);
13453
        }
13454
        break;
13455
 
10269 amit.gupta 13456
      case IS_MOBILE:
13457
        if (value == null) {
13458
          unsetIsMobile();
13459
        } else {
13460
          setIsMobile((Boolean)value);
13461
        }
13462
        break;
13463
 
6050 anupam.sin 13464
      }
13465
    }
13466
 
13467
    public Object getFieldValue(_Fields field) {
13468
      switch (field) {
13469
      case MERCHANT_PAYMENT_ID:
13470
        return Long.valueOf(getMerchantPaymentId());
13471
 
13472
      case RECHARGE_ORDER_ID:
13473
        return Long.valueOf(getRechargeOrderId());
13474
 
6228 anupam.sin 13475
      case PHONE:
13476
        return getPhone();
13477
 
10269 amit.gupta 13478
      case IS_MOBILE:
13479
        return Boolean.valueOf(isIsMobile());
13480
 
6050 anupam.sin 13481
      }
13482
      throw new IllegalStateException();
13483
    }
13484
 
13485
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13486
    public boolean isSet(_Fields field) {
13487
      if (field == null) {
13488
        throw new IllegalArgumentException();
13489
      }
13490
 
13491
      switch (field) {
13492
      case MERCHANT_PAYMENT_ID:
13493
        return isSetMerchantPaymentId();
13494
      case RECHARGE_ORDER_ID:
13495
        return isSetRechargeOrderId();
6228 anupam.sin 13496
      case PHONE:
13497
        return isSetPhone();
10269 amit.gupta 13498
      case IS_MOBILE:
13499
        return isSetIsMobile();
6050 anupam.sin 13500
      }
13501
      throw new IllegalStateException();
13502
    }
13503
 
13504
    @Override
13505
    public boolean equals(Object that) {
13506
      if (that == null)
13507
        return false;
13508
      if (that instanceof doHdfcPaymentForDigitalOrder_args)
13509
        return this.equals((doHdfcPaymentForDigitalOrder_args)that);
13510
      return false;
13511
    }
13512
 
13513
    public boolean equals(doHdfcPaymentForDigitalOrder_args that) {
13514
      if (that == null)
13515
        return false;
13516
 
13517
      boolean this_present_merchantPaymentId = true;
13518
      boolean that_present_merchantPaymentId = true;
13519
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
13520
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
13521
          return false;
13522
        if (this.merchantPaymentId != that.merchantPaymentId)
13523
          return false;
13524
      }
13525
 
13526
      boolean this_present_rechargeOrderId = true;
13527
      boolean that_present_rechargeOrderId = true;
13528
      if (this_present_rechargeOrderId || that_present_rechargeOrderId) {
13529
        if (!(this_present_rechargeOrderId && that_present_rechargeOrderId))
13530
          return false;
13531
        if (this.rechargeOrderId != that.rechargeOrderId)
13532
          return false;
13533
      }
13534
 
6228 anupam.sin 13535
      boolean this_present_phone = true && this.isSetPhone();
13536
      boolean that_present_phone = true && that.isSetPhone();
13537
      if (this_present_phone || that_present_phone) {
13538
        if (!(this_present_phone && that_present_phone))
13539
          return false;
13540
        if (!this.phone.equals(that.phone))
13541
          return false;
13542
      }
13543
 
10269 amit.gupta 13544
      boolean this_present_isMobile = true;
13545
      boolean that_present_isMobile = true;
13546
      if (this_present_isMobile || that_present_isMobile) {
13547
        if (!(this_present_isMobile && that_present_isMobile))
13548
          return false;
13549
        if (this.isMobile != that.isMobile)
13550
          return false;
13551
      }
13552
 
6050 anupam.sin 13553
      return true;
13554
    }
13555
 
13556
    @Override
13557
    public int hashCode() {
13558
      return 0;
13559
    }
13560
 
13561
    public int compareTo(doHdfcPaymentForDigitalOrder_args other) {
13562
      if (!getClass().equals(other.getClass())) {
13563
        return getClass().getName().compareTo(other.getClass().getName());
13564
      }
13565
 
13566
      int lastComparison = 0;
13567
      doHdfcPaymentForDigitalOrder_args typedOther = (doHdfcPaymentForDigitalOrder_args)other;
13568
 
13569
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
13570
      if (lastComparison != 0) {
13571
        return lastComparison;
13572
      }
13573
      if (isSetMerchantPaymentId()) {
13574
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
13575
        if (lastComparison != 0) {
13576
          return lastComparison;
13577
        }
13578
      }
13579
      lastComparison = Boolean.valueOf(isSetRechargeOrderId()).compareTo(typedOther.isSetRechargeOrderId());
13580
      if (lastComparison != 0) {
13581
        return lastComparison;
13582
      }
13583
      if (isSetRechargeOrderId()) {
13584
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.rechargeOrderId, typedOther.rechargeOrderId);
13585
        if (lastComparison != 0) {
13586
          return lastComparison;
13587
        }
13588
      }
6228 anupam.sin 13589
      lastComparison = Boolean.valueOf(isSetPhone()).compareTo(typedOther.isSetPhone());
13590
      if (lastComparison != 0) {
13591
        return lastComparison;
13592
      }
13593
      if (isSetPhone()) {
13594
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.phone, typedOther.phone);
13595
        if (lastComparison != 0) {
13596
          return lastComparison;
13597
        }
13598
      }
10269 amit.gupta 13599
      lastComparison = Boolean.valueOf(isSetIsMobile()).compareTo(typedOther.isSetIsMobile());
13600
      if (lastComparison != 0) {
13601
        return lastComparison;
13602
      }
13603
      if (isSetIsMobile()) {
13604
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isMobile, typedOther.isMobile);
13605
        if (lastComparison != 0) {
13606
          return lastComparison;
13607
        }
13608
      }
6050 anupam.sin 13609
      return 0;
13610
    }
13611
 
13612
    public _Fields fieldForId(int fieldId) {
13613
      return _Fields.findByThriftId(fieldId);
13614
    }
13615
 
13616
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13617
      org.apache.thrift.protocol.TField field;
13618
      iprot.readStructBegin();
13619
      while (true)
13620
      {
13621
        field = iprot.readFieldBegin();
13622
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13623
          break;
13624
        }
13625
        switch (field.id) {
13626
          case 1: // MERCHANT_PAYMENT_ID
13627
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13628
              this.merchantPaymentId = iprot.readI64();
13629
              setMerchantPaymentIdIsSet(true);
13630
            } else { 
13631
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13632
            }
13633
            break;
13634
          case 2: // RECHARGE_ORDER_ID
13635
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13636
              this.rechargeOrderId = iprot.readI64();
13637
              setRechargeOrderIdIsSet(true);
13638
            } else { 
13639
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13640
            }
13641
            break;
10269 amit.gupta 13642
          case 3: // PHONE
6228 anupam.sin 13643
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
13644
              this.phone = iprot.readString();
13645
            } else { 
13646
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13647
            }
13648
            break;
10269 amit.gupta 13649
          case 4: // IS_MOBILE
13650
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
13651
              this.isMobile = iprot.readBool();
13652
              setIsMobileIsSet(true);
13653
            } else { 
13654
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13655
            }
13656
            break;
6050 anupam.sin 13657
          default:
13658
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13659
        }
13660
        iprot.readFieldEnd();
13661
      }
13662
      iprot.readStructEnd();
13663
      validate();
13664
    }
13665
 
13666
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13667
      validate();
13668
 
13669
      oprot.writeStructBegin(STRUCT_DESC);
10269 amit.gupta 13670
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
13671
      oprot.writeI64(this.merchantPaymentId);
13672
      oprot.writeFieldEnd();
13673
      oprot.writeFieldBegin(RECHARGE_ORDER_ID_FIELD_DESC);
13674
      oprot.writeI64(this.rechargeOrderId);
13675
      oprot.writeFieldEnd();
6228 anupam.sin 13676
      if (this.phone != null) {
13677
        oprot.writeFieldBegin(PHONE_FIELD_DESC);
13678
        oprot.writeString(this.phone);
13679
        oprot.writeFieldEnd();
13680
      }
10269 amit.gupta 13681
      oprot.writeFieldBegin(IS_MOBILE_FIELD_DESC);
13682
      oprot.writeBool(this.isMobile);
6050 anupam.sin 13683
      oprot.writeFieldEnd();
13684
      oprot.writeFieldStop();
13685
      oprot.writeStructEnd();
13686
    }
13687
 
13688
    @Override
13689
    public String toString() {
13690
      StringBuilder sb = new StringBuilder("doHdfcPaymentForDigitalOrder_args(");
13691
      boolean first = true;
13692
 
13693
      sb.append("merchantPaymentId:");
13694
      sb.append(this.merchantPaymentId);
13695
      first = false;
13696
      if (!first) sb.append(", ");
13697
      sb.append("rechargeOrderId:");
13698
      sb.append(this.rechargeOrderId);
13699
      first = false;
6228 anupam.sin 13700
      if (!first) sb.append(", ");
13701
      sb.append("phone:");
13702
      if (this.phone == null) {
13703
        sb.append("null");
13704
      } else {
13705
        sb.append(this.phone);
13706
      }
13707
      first = false;
10269 amit.gupta 13708
      if (!first) sb.append(", ");
13709
      sb.append("isMobile:");
13710
      sb.append(this.isMobile);
13711
      first = false;
6050 anupam.sin 13712
      sb.append(")");
13713
      return sb.toString();
13714
    }
13715
 
13716
    public void validate() throws org.apache.thrift.TException {
13717
      // check for required fields
13718
    }
13719
 
13720
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13721
      try {
13722
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13723
      } catch (org.apache.thrift.TException te) {
13724
        throw new java.io.IOException(te);
13725
      }
13726
    }
13727
 
13728
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13729
      try {
13730
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13731
      } catch (org.apache.thrift.TException te) {
13732
        throw new java.io.IOException(te);
13733
      }
13734
    }
13735
 
13736
  }
13737
 
13738
  public static class doHdfcPaymentForDigitalOrder_result implements org.apache.thrift.TBase<doHdfcPaymentForDigitalOrder_result, doHdfcPaymentForDigitalOrder_result._Fields>, java.io.Serializable, Cloneable   {
13739
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("doHdfcPaymentForDigitalOrder_result");
13740
 
13741
    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);
13742
    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);
13743
 
13744
    private String success; // required
13745
    private PaymentException pe; // required
13746
 
13747
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13748
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13749
      SUCCESS((short)0, "success"),
13750
      PE((short)1, "pe");
13751
 
13752
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13753
 
13754
      static {
13755
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13756
          byName.put(field.getFieldName(), field);
13757
        }
13758
      }
13759
 
13760
      /**
13761
       * Find the _Fields constant that matches fieldId, or null if its not found.
13762
       */
13763
      public static _Fields findByThriftId(int fieldId) {
13764
        switch(fieldId) {
13765
          case 0: // SUCCESS
13766
            return SUCCESS;
13767
          case 1: // PE
13768
            return PE;
13769
          default:
13770
            return null;
13771
        }
13772
      }
13773
 
13774
      /**
13775
       * Find the _Fields constant that matches fieldId, throwing an exception
13776
       * if it is not found.
13777
       */
13778
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13779
        _Fields fields = findByThriftId(fieldId);
13780
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13781
        return fields;
13782
      }
13783
 
13784
      /**
13785
       * Find the _Fields constant that matches name, or null if its not found.
13786
       */
13787
      public static _Fields findByName(String name) {
13788
        return byName.get(name);
13789
      }
13790
 
13791
      private final short _thriftId;
13792
      private final String _fieldName;
13793
 
13794
      _Fields(short thriftId, String fieldName) {
13795
        _thriftId = thriftId;
13796
        _fieldName = fieldName;
13797
      }
13798
 
13799
      public short getThriftFieldId() {
13800
        return _thriftId;
13801
      }
13802
 
13803
      public String getFieldName() {
13804
        return _fieldName;
13805
      }
13806
    }
13807
 
13808
    // isset id assignments
13809
 
13810
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13811
    static {
13812
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13813
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13814
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
13815
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13816
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
13817
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13818
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(doHdfcPaymentForDigitalOrder_result.class, metaDataMap);
13819
    }
13820
 
13821
    public doHdfcPaymentForDigitalOrder_result() {
13822
    }
13823
 
13824
    public doHdfcPaymentForDigitalOrder_result(
13825
      String success,
13826
      PaymentException pe)
13827
    {
13828
      this();
13829
      this.success = success;
13830
      this.pe = pe;
13831
    }
13832
 
13833
    /**
13834
     * Performs a deep copy on <i>other</i>.
13835
     */
13836
    public doHdfcPaymentForDigitalOrder_result(doHdfcPaymentForDigitalOrder_result other) {
13837
      if (other.isSetSuccess()) {
13838
        this.success = other.success;
13839
      }
13840
      if (other.isSetPe()) {
13841
        this.pe = new PaymentException(other.pe);
13842
      }
13843
    }
13844
 
13845
    public doHdfcPaymentForDigitalOrder_result deepCopy() {
13846
      return new doHdfcPaymentForDigitalOrder_result(this);
13847
    }
13848
 
13849
    @Override
13850
    public void clear() {
13851
      this.success = null;
13852
      this.pe = null;
13853
    }
13854
 
13855
    public String getSuccess() {
13856
      return this.success;
13857
    }
13858
 
13859
    public void setSuccess(String success) {
13860
      this.success = success;
13861
    }
13862
 
13863
    public void unsetSuccess() {
13864
      this.success = null;
13865
    }
13866
 
13867
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13868
    public boolean isSetSuccess() {
13869
      return this.success != null;
13870
    }
13871
 
13872
    public void setSuccessIsSet(boolean value) {
13873
      if (!value) {
13874
        this.success = null;
13875
      }
13876
    }
13877
 
13878
    public PaymentException getPe() {
13879
      return this.pe;
13880
    }
13881
 
13882
    public void setPe(PaymentException pe) {
13883
      this.pe = pe;
13884
    }
13885
 
13886
    public void unsetPe() {
13887
      this.pe = null;
13888
    }
13889
 
13890
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
13891
    public boolean isSetPe() {
13892
      return this.pe != null;
13893
    }
13894
 
13895
    public void setPeIsSet(boolean value) {
13896
      if (!value) {
13897
        this.pe = null;
13898
      }
13899
    }
13900
 
13901
    public void setFieldValue(_Fields field, Object value) {
13902
      switch (field) {
13903
      case SUCCESS:
13904
        if (value == null) {
13905
          unsetSuccess();
13906
        } else {
13907
          setSuccess((String)value);
13908
        }
13909
        break;
13910
 
13911
      case PE:
13912
        if (value == null) {
13913
          unsetPe();
13914
        } else {
13915
          setPe((PaymentException)value);
13916
        }
13917
        break;
13918
 
13919
      }
13920
    }
13921
 
13922
    public Object getFieldValue(_Fields field) {
13923
      switch (field) {
13924
      case SUCCESS:
13925
        return getSuccess();
13926
 
13927
      case PE:
13928
        return getPe();
13929
 
13930
      }
13931
      throw new IllegalStateException();
13932
    }
13933
 
13934
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13935
    public boolean isSet(_Fields field) {
13936
      if (field == null) {
13937
        throw new IllegalArgumentException();
13938
      }
13939
 
13940
      switch (field) {
13941
      case SUCCESS:
13942
        return isSetSuccess();
13943
      case PE:
13944
        return isSetPe();
13945
      }
13946
      throw new IllegalStateException();
13947
    }
13948
 
13949
    @Override
13950
    public boolean equals(Object that) {
13951
      if (that == null)
13952
        return false;
13953
      if (that instanceof doHdfcPaymentForDigitalOrder_result)
13954
        return this.equals((doHdfcPaymentForDigitalOrder_result)that);
13955
      return false;
13956
    }
13957
 
13958
    public boolean equals(doHdfcPaymentForDigitalOrder_result that) {
13959
      if (that == null)
13960
        return false;
13961
 
13962
      boolean this_present_success = true && this.isSetSuccess();
13963
      boolean that_present_success = true && that.isSetSuccess();
13964
      if (this_present_success || that_present_success) {
13965
        if (!(this_present_success && that_present_success))
13966
          return false;
13967
        if (!this.success.equals(that.success))
13968
          return false;
13969
      }
13970
 
13971
      boolean this_present_pe = true && this.isSetPe();
13972
      boolean that_present_pe = true && that.isSetPe();
13973
      if (this_present_pe || that_present_pe) {
13974
        if (!(this_present_pe && that_present_pe))
13975
          return false;
13976
        if (!this.pe.equals(that.pe))
13977
          return false;
13978
      }
13979
 
13980
      return true;
13981
    }
13982
 
13983
    @Override
13984
    public int hashCode() {
13985
      return 0;
13986
    }
13987
 
13988
    public int compareTo(doHdfcPaymentForDigitalOrder_result other) {
13989
      if (!getClass().equals(other.getClass())) {
13990
        return getClass().getName().compareTo(other.getClass().getName());
13991
      }
13992
 
13993
      int lastComparison = 0;
13994
      doHdfcPaymentForDigitalOrder_result typedOther = (doHdfcPaymentForDigitalOrder_result)other;
13995
 
13996
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13997
      if (lastComparison != 0) {
13998
        return lastComparison;
13999
      }
14000
      if (isSetSuccess()) {
14001
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14002
        if (lastComparison != 0) {
14003
          return lastComparison;
14004
        }
14005
      }
14006
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
14007
      if (lastComparison != 0) {
14008
        return lastComparison;
14009
      }
14010
      if (isSetPe()) {
14011
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
14012
        if (lastComparison != 0) {
14013
          return lastComparison;
14014
        }
14015
      }
14016
      return 0;
14017
    }
14018
 
14019
    public _Fields fieldForId(int fieldId) {
14020
      return _Fields.findByThriftId(fieldId);
14021
    }
14022
 
14023
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14024
      org.apache.thrift.protocol.TField field;
14025
      iprot.readStructBegin();
14026
      while (true)
14027
      {
14028
        field = iprot.readFieldBegin();
14029
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14030
          break;
14031
        }
14032
        switch (field.id) {
14033
          case 0: // SUCCESS
14034
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
14035
              this.success = iprot.readString();
14036
            } else { 
14037
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14038
            }
14039
            break;
14040
          case 1: // PE
14041
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14042
              this.pe = new PaymentException();
14043
              this.pe.read(iprot);
14044
            } else { 
14045
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14046
            }
14047
            break;
14048
          default:
14049
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14050
        }
14051
        iprot.readFieldEnd();
14052
      }
14053
      iprot.readStructEnd();
14054
      validate();
14055
    }
14056
 
14057
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14058
      oprot.writeStructBegin(STRUCT_DESC);
14059
 
14060
      if (this.isSetSuccess()) {
14061
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
14062
        oprot.writeString(this.success);
14063
        oprot.writeFieldEnd();
14064
      } else if (this.isSetPe()) {
14065
        oprot.writeFieldBegin(PE_FIELD_DESC);
14066
        this.pe.write(oprot);
14067
        oprot.writeFieldEnd();
14068
      }
14069
      oprot.writeFieldStop();
14070
      oprot.writeStructEnd();
14071
    }
14072
 
14073
    @Override
14074
    public String toString() {
14075
      StringBuilder sb = new StringBuilder("doHdfcPaymentForDigitalOrder_result(");
14076
      boolean first = true;
14077
 
14078
      sb.append("success:");
14079
      if (this.success == null) {
14080
        sb.append("null");
14081
      } else {
14082
        sb.append(this.success);
14083
      }
14084
      first = false;
14085
      if (!first) sb.append(", ");
14086
      sb.append("pe:");
14087
      if (this.pe == null) {
14088
        sb.append("null");
14089
      } else {
14090
        sb.append(this.pe);
14091
      }
14092
      first = false;
14093
      sb.append(")");
14094
      return sb.toString();
14095
    }
14096
 
14097
    public void validate() throws org.apache.thrift.TException {
14098
      // check for required fields
14099
    }
14100
 
14101
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14102
      try {
14103
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14104
      } catch (org.apache.thrift.TException te) {
14105
        throw new java.io.IOException(te);
14106
      }
14107
    }
14108
 
14109
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14110
      try {
14111
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14112
      } catch (org.apache.thrift.TException te) {
14113
        throw new java.io.IOException(te);
14114
      }
14115
    }
14116
 
14117
  }
14118
 
3616 chandransh 14119
  public static class initializeHdfcEmiPayment_args implements org.apache.thrift.TBase<initializeHdfcEmiPayment_args, initializeHdfcEmiPayment_args._Fields>, java.io.Serializable, Cloneable   {
14120
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcEmiPayment_args");
14121
 
14122
    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);
10269 amit.gupta 14123
    private static final org.apache.thrift.protocol.TField IS_MOBILE_FIELD_DESC = new org.apache.thrift.protocol.TField("isMobile", org.apache.thrift.protocol.TType.BOOL, (short)2);
3616 chandransh 14124
 
14125
    private long merchantPaymentId; // required
10269 amit.gupta 14126
    private boolean isMobile; // required
3616 chandransh 14127
 
14128
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14129
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10269 amit.gupta 14130
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId"),
14131
      IS_MOBILE((short)2, "isMobile");
3616 chandransh 14132
 
14133
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14134
 
14135
      static {
14136
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14137
          byName.put(field.getFieldName(), field);
14138
        }
14139
      }
14140
 
14141
      /**
14142
       * Find the _Fields constant that matches fieldId, or null if its not found.
14143
       */
14144
      public static _Fields findByThriftId(int fieldId) {
14145
        switch(fieldId) {
14146
          case 1: // MERCHANT_PAYMENT_ID
14147
            return MERCHANT_PAYMENT_ID;
10269 amit.gupta 14148
          case 2: // IS_MOBILE
14149
            return IS_MOBILE;
3616 chandransh 14150
          default:
14151
            return null;
14152
        }
14153
      }
14154
 
14155
      /**
14156
       * Find the _Fields constant that matches fieldId, throwing an exception
14157
       * if it is not found.
14158
       */
14159
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14160
        _Fields fields = findByThriftId(fieldId);
14161
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14162
        return fields;
14163
      }
14164
 
14165
      /**
14166
       * Find the _Fields constant that matches name, or null if its not found.
14167
       */
14168
      public static _Fields findByName(String name) {
14169
        return byName.get(name);
14170
      }
14171
 
14172
      private final short _thriftId;
14173
      private final String _fieldName;
14174
 
14175
      _Fields(short thriftId, String fieldName) {
14176
        _thriftId = thriftId;
14177
        _fieldName = fieldName;
14178
      }
14179
 
14180
      public short getThriftFieldId() {
14181
        return _thriftId;
14182
      }
14183
 
14184
      public String getFieldName() {
14185
        return _fieldName;
14186
      }
14187
    }
14188
 
14189
    // isset id assignments
14190
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
10269 amit.gupta 14191
    private static final int __ISMOBILE_ISSET_ID = 1;
14192
    private BitSet __isset_bit_vector = new BitSet(2);
3616 chandransh 14193
 
14194
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14195
    static {
14196
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14197
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14198
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10269 amit.gupta 14199
      tmpMap.put(_Fields.IS_MOBILE, new org.apache.thrift.meta_data.FieldMetaData("isMobile", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14200
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
3616 chandransh 14201
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14202
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcEmiPayment_args.class, metaDataMap);
14203
    }
14204
 
14205
    public initializeHdfcEmiPayment_args() {
14206
    }
14207
 
14208
    public initializeHdfcEmiPayment_args(
10269 amit.gupta 14209
      long merchantPaymentId,
14210
      boolean isMobile)
3616 chandransh 14211
    {
14212
      this();
14213
      this.merchantPaymentId = merchantPaymentId;
14214
      setMerchantPaymentIdIsSet(true);
10269 amit.gupta 14215
      this.isMobile = isMobile;
14216
      setIsMobileIsSet(true);
3616 chandransh 14217
    }
14218
 
14219
    /**
14220
     * Performs a deep copy on <i>other</i>.
14221
     */
14222
    public initializeHdfcEmiPayment_args(initializeHdfcEmiPayment_args other) {
14223
      __isset_bit_vector.clear();
14224
      __isset_bit_vector.or(other.__isset_bit_vector);
14225
      this.merchantPaymentId = other.merchantPaymentId;
10269 amit.gupta 14226
      this.isMobile = other.isMobile;
3616 chandransh 14227
    }
14228
 
14229
    public initializeHdfcEmiPayment_args deepCopy() {
14230
      return new initializeHdfcEmiPayment_args(this);
14231
    }
14232
 
14233
    @Override
14234
    public void clear() {
14235
      setMerchantPaymentIdIsSet(false);
14236
      this.merchantPaymentId = 0;
10269 amit.gupta 14237
      setIsMobileIsSet(false);
14238
      this.isMobile = false;
3616 chandransh 14239
    }
14240
 
14241
    public long getMerchantPaymentId() {
14242
      return this.merchantPaymentId;
14243
    }
14244
 
14245
    public void setMerchantPaymentId(long merchantPaymentId) {
14246
      this.merchantPaymentId = merchantPaymentId;
14247
      setMerchantPaymentIdIsSet(true);
14248
    }
14249
 
14250
    public void unsetMerchantPaymentId() {
14251
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
14252
    }
14253
 
14254
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
14255
    public boolean isSetMerchantPaymentId() {
14256
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
14257
    }
14258
 
14259
    public void setMerchantPaymentIdIsSet(boolean value) {
14260
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
14261
    }
14262
 
10269 amit.gupta 14263
    public boolean isIsMobile() {
14264
      return this.isMobile;
14265
    }
14266
 
14267
    public void setIsMobile(boolean isMobile) {
14268
      this.isMobile = isMobile;
14269
      setIsMobileIsSet(true);
14270
    }
14271
 
14272
    public void unsetIsMobile() {
14273
      __isset_bit_vector.clear(__ISMOBILE_ISSET_ID);
14274
    }
14275
 
14276
    /** Returns true if field isMobile is set (has been assigned a value) and false otherwise */
14277
    public boolean isSetIsMobile() {
14278
      return __isset_bit_vector.get(__ISMOBILE_ISSET_ID);
14279
    }
14280
 
14281
    public void setIsMobileIsSet(boolean value) {
14282
      __isset_bit_vector.set(__ISMOBILE_ISSET_ID, value);
14283
    }
14284
 
3616 chandransh 14285
    public void setFieldValue(_Fields field, Object value) {
14286
      switch (field) {
14287
      case MERCHANT_PAYMENT_ID:
14288
        if (value == null) {
14289
          unsetMerchantPaymentId();
14290
        } else {
14291
          setMerchantPaymentId((Long)value);
14292
        }
14293
        break;
14294
 
10269 amit.gupta 14295
      case IS_MOBILE:
14296
        if (value == null) {
14297
          unsetIsMobile();
14298
        } else {
14299
          setIsMobile((Boolean)value);
14300
        }
14301
        break;
14302
 
3616 chandransh 14303
      }
14304
    }
14305
 
14306
    public Object getFieldValue(_Fields field) {
14307
      switch (field) {
14308
      case MERCHANT_PAYMENT_ID:
14309
        return Long.valueOf(getMerchantPaymentId());
14310
 
10269 amit.gupta 14311
      case IS_MOBILE:
14312
        return Boolean.valueOf(isIsMobile());
14313
 
3616 chandransh 14314
      }
14315
      throw new IllegalStateException();
14316
    }
14317
 
14318
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14319
    public boolean isSet(_Fields field) {
14320
      if (field == null) {
14321
        throw new IllegalArgumentException();
14322
      }
14323
 
14324
      switch (field) {
14325
      case MERCHANT_PAYMENT_ID:
14326
        return isSetMerchantPaymentId();
10269 amit.gupta 14327
      case IS_MOBILE:
14328
        return isSetIsMobile();
3616 chandransh 14329
      }
14330
      throw new IllegalStateException();
14331
    }
14332
 
14333
    @Override
14334
    public boolean equals(Object that) {
14335
      if (that == null)
14336
        return false;
14337
      if (that instanceof initializeHdfcEmiPayment_args)
14338
        return this.equals((initializeHdfcEmiPayment_args)that);
14339
      return false;
14340
    }
14341
 
14342
    public boolean equals(initializeHdfcEmiPayment_args that) {
14343
      if (that == null)
14344
        return false;
14345
 
14346
      boolean this_present_merchantPaymentId = true;
14347
      boolean that_present_merchantPaymentId = true;
14348
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
14349
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
14350
          return false;
14351
        if (this.merchantPaymentId != that.merchantPaymentId)
14352
          return false;
14353
      }
14354
 
10269 amit.gupta 14355
      boolean this_present_isMobile = true;
14356
      boolean that_present_isMobile = true;
14357
      if (this_present_isMobile || that_present_isMobile) {
14358
        if (!(this_present_isMobile && that_present_isMobile))
14359
          return false;
14360
        if (this.isMobile != that.isMobile)
14361
          return false;
14362
      }
14363
 
3616 chandransh 14364
      return true;
14365
    }
14366
 
14367
    @Override
14368
    public int hashCode() {
14369
      return 0;
14370
    }
14371
 
14372
    public int compareTo(initializeHdfcEmiPayment_args other) {
14373
      if (!getClass().equals(other.getClass())) {
14374
        return getClass().getName().compareTo(other.getClass().getName());
14375
      }
14376
 
14377
      int lastComparison = 0;
14378
      initializeHdfcEmiPayment_args typedOther = (initializeHdfcEmiPayment_args)other;
14379
 
14380
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
14381
      if (lastComparison != 0) {
14382
        return lastComparison;
14383
      }
14384
      if (isSetMerchantPaymentId()) {
14385
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
14386
        if (lastComparison != 0) {
14387
          return lastComparison;
14388
        }
14389
      }
10269 amit.gupta 14390
      lastComparison = Boolean.valueOf(isSetIsMobile()).compareTo(typedOther.isSetIsMobile());
14391
      if (lastComparison != 0) {
14392
        return lastComparison;
14393
      }
14394
      if (isSetIsMobile()) {
14395
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isMobile, typedOther.isMobile);
14396
        if (lastComparison != 0) {
14397
          return lastComparison;
14398
        }
14399
      }
3616 chandransh 14400
      return 0;
14401
    }
14402
 
14403
    public _Fields fieldForId(int fieldId) {
14404
      return _Fields.findByThriftId(fieldId);
14405
    }
14406
 
14407
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14408
      org.apache.thrift.protocol.TField field;
14409
      iprot.readStructBegin();
14410
      while (true)
14411
      {
14412
        field = iprot.readFieldBegin();
14413
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14414
          break;
14415
        }
14416
        switch (field.id) {
14417
          case 1: // MERCHANT_PAYMENT_ID
14418
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14419
              this.merchantPaymentId = iprot.readI64();
14420
              setMerchantPaymentIdIsSet(true);
14421
            } else { 
14422
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14423
            }
14424
            break;
10269 amit.gupta 14425
          case 2: // IS_MOBILE
14426
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
14427
              this.isMobile = iprot.readBool();
14428
              setIsMobileIsSet(true);
14429
            } else { 
14430
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14431
            }
14432
            break;
3616 chandransh 14433
          default:
14434
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14435
        }
14436
        iprot.readFieldEnd();
14437
      }
14438
      iprot.readStructEnd();
14439
      validate();
14440
    }
14441
 
14442
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14443
      validate();
14444
 
14445
      oprot.writeStructBegin(STRUCT_DESC);
14446
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
14447
      oprot.writeI64(this.merchantPaymentId);
14448
      oprot.writeFieldEnd();
10269 amit.gupta 14449
      oprot.writeFieldBegin(IS_MOBILE_FIELD_DESC);
14450
      oprot.writeBool(this.isMobile);
14451
      oprot.writeFieldEnd();
3616 chandransh 14452
      oprot.writeFieldStop();
14453
      oprot.writeStructEnd();
14454
    }
14455
 
14456
    @Override
14457
    public String toString() {
14458
      StringBuilder sb = new StringBuilder("initializeHdfcEmiPayment_args(");
14459
      boolean first = true;
14460
 
14461
      sb.append("merchantPaymentId:");
14462
      sb.append(this.merchantPaymentId);
14463
      first = false;
10269 amit.gupta 14464
      if (!first) sb.append(", ");
14465
      sb.append("isMobile:");
14466
      sb.append(this.isMobile);
14467
      first = false;
3616 chandransh 14468
      sb.append(")");
14469
      return sb.toString();
14470
    }
14471
 
14472
    public void validate() throws org.apache.thrift.TException {
14473
      // check for required fields
14474
    }
14475
 
14476
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14477
      try {
14478
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14479
      } catch (org.apache.thrift.TException te) {
14480
        throw new java.io.IOException(te);
14481
      }
14482
    }
14483
 
14484
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14485
      try {
14486
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14487
      } catch (org.apache.thrift.TException te) {
14488
        throw new java.io.IOException(te);
14489
      }
14490
    }
14491
 
14492
  }
14493
 
14494
  public static class initializeHdfcEmiPayment_result implements org.apache.thrift.TBase<initializeHdfcEmiPayment_result, initializeHdfcEmiPayment_result._Fields>, java.io.Serializable, Cloneable   {
14495
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcEmiPayment_result");
14496
 
14497
    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);
14498
    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);
14499
 
14500
    private String success; // required
14501
    private PaymentException pe; // required
14502
 
14503
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14504
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14505
      SUCCESS((short)0, "success"),
14506
      PE((short)1, "pe");
14507
 
14508
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14509
 
14510
      static {
14511
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14512
          byName.put(field.getFieldName(), field);
14513
        }
14514
      }
14515
 
14516
      /**
14517
       * Find the _Fields constant that matches fieldId, or null if its not found.
14518
       */
14519
      public static _Fields findByThriftId(int fieldId) {
14520
        switch(fieldId) {
14521
          case 0: // SUCCESS
14522
            return SUCCESS;
14523
          case 1: // PE
14524
            return PE;
14525
          default:
14526
            return null;
14527
        }
14528
      }
14529
 
14530
      /**
14531
       * Find the _Fields constant that matches fieldId, throwing an exception
14532
       * if it is not found.
14533
       */
14534
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14535
        _Fields fields = findByThriftId(fieldId);
14536
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14537
        return fields;
14538
      }
14539
 
14540
      /**
14541
       * Find the _Fields constant that matches name, or null if its not found.
14542
       */
14543
      public static _Fields findByName(String name) {
14544
        return byName.get(name);
14545
      }
14546
 
14547
      private final short _thriftId;
14548
      private final String _fieldName;
14549
 
14550
      _Fields(short thriftId, String fieldName) {
14551
        _thriftId = thriftId;
14552
        _fieldName = fieldName;
14553
      }
14554
 
14555
      public short getThriftFieldId() {
14556
        return _thriftId;
14557
      }
14558
 
14559
      public String getFieldName() {
14560
        return _fieldName;
14561
      }
14562
    }
14563
 
14564
    // isset id assignments
14565
 
14566
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14567
    static {
14568
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14569
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14570
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
14571
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14572
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14573
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14574
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcEmiPayment_result.class, metaDataMap);
14575
    }
14576
 
14577
    public initializeHdfcEmiPayment_result() {
14578
    }
14579
 
14580
    public initializeHdfcEmiPayment_result(
14581
      String success,
14582
      PaymentException pe)
14583
    {
14584
      this();
14585
      this.success = success;
14586
      this.pe = pe;
14587
    }
14588
 
14589
    /**
14590
     * Performs a deep copy on <i>other</i>.
14591
     */
14592
    public initializeHdfcEmiPayment_result(initializeHdfcEmiPayment_result other) {
14593
      if (other.isSetSuccess()) {
14594
        this.success = other.success;
14595
      }
14596
      if (other.isSetPe()) {
14597
        this.pe = new PaymentException(other.pe);
14598
      }
14599
    }
14600
 
14601
    public initializeHdfcEmiPayment_result deepCopy() {
14602
      return new initializeHdfcEmiPayment_result(this);
14603
    }
14604
 
14605
    @Override
14606
    public void clear() {
14607
      this.success = null;
14608
      this.pe = null;
14609
    }
14610
 
14611
    public String getSuccess() {
14612
      return this.success;
14613
    }
14614
 
14615
    public void setSuccess(String success) {
14616
      this.success = success;
14617
    }
14618
 
14619
    public void unsetSuccess() {
14620
      this.success = null;
14621
    }
14622
 
14623
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
14624
    public boolean isSetSuccess() {
14625
      return this.success != null;
14626
    }
14627
 
14628
    public void setSuccessIsSet(boolean value) {
14629
      if (!value) {
14630
        this.success = null;
14631
      }
14632
    }
14633
 
14634
    public PaymentException getPe() {
14635
      return this.pe;
14636
    }
14637
 
14638
    public void setPe(PaymentException pe) {
14639
      this.pe = pe;
14640
    }
14641
 
14642
    public void unsetPe() {
14643
      this.pe = null;
14644
    }
14645
 
14646
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
14647
    public boolean isSetPe() {
14648
      return this.pe != null;
14649
    }
14650
 
14651
    public void setPeIsSet(boolean value) {
14652
      if (!value) {
14653
        this.pe = null;
14654
      }
14655
    }
14656
 
14657
    public void setFieldValue(_Fields field, Object value) {
14658
      switch (field) {
14659
      case SUCCESS:
14660
        if (value == null) {
14661
          unsetSuccess();
14662
        } else {
14663
          setSuccess((String)value);
14664
        }
14665
        break;
14666
 
14667
      case PE:
14668
        if (value == null) {
14669
          unsetPe();
14670
        } else {
14671
          setPe((PaymentException)value);
14672
        }
14673
        break;
14674
 
14675
      }
14676
    }
14677
 
14678
    public Object getFieldValue(_Fields field) {
14679
      switch (field) {
14680
      case SUCCESS:
14681
        return getSuccess();
14682
 
14683
      case PE:
14684
        return getPe();
14685
 
14686
      }
14687
      throw new IllegalStateException();
14688
    }
14689
 
14690
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14691
    public boolean isSet(_Fields field) {
14692
      if (field == null) {
14693
        throw new IllegalArgumentException();
14694
      }
14695
 
14696
      switch (field) {
14697
      case SUCCESS:
14698
        return isSetSuccess();
14699
      case PE:
14700
        return isSetPe();
14701
      }
14702
      throw new IllegalStateException();
14703
    }
14704
 
14705
    @Override
14706
    public boolean equals(Object that) {
14707
      if (that == null)
14708
        return false;
14709
      if (that instanceof initializeHdfcEmiPayment_result)
14710
        return this.equals((initializeHdfcEmiPayment_result)that);
14711
      return false;
14712
    }
14713
 
14714
    public boolean equals(initializeHdfcEmiPayment_result that) {
14715
      if (that == null)
14716
        return false;
14717
 
14718
      boolean this_present_success = true && this.isSetSuccess();
14719
      boolean that_present_success = true && that.isSetSuccess();
14720
      if (this_present_success || that_present_success) {
14721
        if (!(this_present_success && that_present_success))
14722
          return false;
14723
        if (!this.success.equals(that.success))
14724
          return false;
14725
      }
14726
 
14727
      boolean this_present_pe = true && this.isSetPe();
14728
      boolean that_present_pe = true && that.isSetPe();
14729
      if (this_present_pe || that_present_pe) {
14730
        if (!(this_present_pe && that_present_pe))
14731
          return false;
14732
        if (!this.pe.equals(that.pe))
14733
          return false;
14734
      }
14735
 
14736
      return true;
14737
    }
14738
 
14739
    @Override
14740
    public int hashCode() {
14741
      return 0;
14742
    }
14743
 
14744
    public int compareTo(initializeHdfcEmiPayment_result other) {
14745
      if (!getClass().equals(other.getClass())) {
14746
        return getClass().getName().compareTo(other.getClass().getName());
14747
      }
14748
 
14749
      int lastComparison = 0;
14750
      initializeHdfcEmiPayment_result typedOther = (initializeHdfcEmiPayment_result)other;
14751
 
14752
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
14753
      if (lastComparison != 0) {
14754
        return lastComparison;
14755
      }
14756
      if (isSetSuccess()) {
14757
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14758
        if (lastComparison != 0) {
14759
          return lastComparison;
14760
        }
14761
      }
14762
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
14763
      if (lastComparison != 0) {
14764
        return lastComparison;
14765
      }
14766
      if (isSetPe()) {
14767
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
14768
        if (lastComparison != 0) {
14769
          return lastComparison;
14770
        }
14771
      }
14772
      return 0;
14773
    }
14774
 
14775
    public _Fields fieldForId(int fieldId) {
14776
      return _Fields.findByThriftId(fieldId);
14777
    }
14778
 
14779
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14780
      org.apache.thrift.protocol.TField field;
14781
      iprot.readStructBegin();
14782
      while (true)
14783
      {
14784
        field = iprot.readFieldBegin();
14785
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14786
          break;
14787
        }
14788
        switch (field.id) {
14789
          case 0: // SUCCESS
14790
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
14791
              this.success = iprot.readString();
14792
            } else { 
14793
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14794
            }
14795
            break;
14796
          case 1: // PE
14797
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14798
              this.pe = new PaymentException();
14799
              this.pe.read(iprot);
14800
            } else { 
14801
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14802
            }
14803
            break;
14804
          default:
14805
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14806
        }
14807
        iprot.readFieldEnd();
14808
      }
14809
      iprot.readStructEnd();
14810
      validate();
14811
    }
14812
 
14813
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14814
      oprot.writeStructBegin(STRUCT_DESC);
14815
 
14816
      if (this.isSetSuccess()) {
14817
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
14818
        oprot.writeString(this.success);
14819
        oprot.writeFieldEnd();
14820
      } else if (this.isSetPe()) {
14821
        oprot.writeFieldBegin(PE_FIELD_DESC);
14822
        this.pe.write(oprot);
14823
        oprot.writeFieldEnd();
14824
      }
14825
      oprot.writeFieldStop();
14826
      oprot.writeStructEnd();
14827
    }
14828
 
14829
    @Override
14830
    public String toString() {
14831
      StringBuilder sb = new StringBuilder("initializeHdfcEmiPayment_result(");
14832
      boolean first = true;
14833
 
14834
      sb.append("success:");
14835
      if (this.success == null) {
14836
        sb.append("null");
14837
      } else {
14838
        sb.append(this.success);
14839
      }
14840
      first = false;
14841
      if (!first) sb.append(", ");
14842
      sb.append("pe:");
14843
      if (this.pe == null) {
14844
        sb.append("null");
14845
      } else {
14846
        sb.append(this.pe);
14847
      }
14848
      first = false;
14849
      sb.append(")");
14850
      return sb.toString();
14851
    }
14852
 
14853
    public void validate() throws org.apache.thrift.TException {
14854
      // check for required fields
14855
    }
14856
 
14857
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14858
      try {
14859
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14860
      } catch (org.apache.thrift.TException te) {
14861
        throw new java.io.IOException(te);
14862
      }
14863
    }
14864
 
14865
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14866
      try {
14867
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14868
      } catch (org.apache.thrift.TException te) {
14869
        throw new java.io.IOException(te);
14870
      }
14871
    }
14872
 
14873
  }
14874
 
3430 rajveer 14875
  public static class createRefund_args implements org.apache.thrift.TBase<createRefund_args, createRefund_args._Fields>, java.io.Serializable, Cloneable   {
14876
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createRefund_args");
2462 chandransh 14877
 
3430 rajveer 14878
    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);
14879
    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);
14880
    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 14881
 
3430 rajveer 14882
    private long orderId; // required
14883
    private long merchantTxnId; // required
14884
    private double amount; // required
2462 chandransh 14885
 
14886
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 14887
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3010 chandransh 14888
      ORDER_ID((short)1, "orderId"),
14889
      MERCHANT_TXN_ID((short)2, "merchantTxnId"),
14890
      AMOUNT((short)3, "amount");
2462 chandransh 14891
 
14892
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14893
 
14894
      static {
14895
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14896
          byName.put(field.getFieldName(), field);
14897
        }
14898
      }
14899
 
14900
      /**
14901
       * Find the _Fields constant that matches fieldId, or null if its not found.
14902
       */
14903
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 14904
        switch(fieldId) {
14905
          case 1: // ORDER_ID
14906
            return ORDER_ID;
14907
          case 2: // MERCHANT_TXN_ID
14908
            return MERCHANT_TXN_ID;
14909
          case 3: // AMOUNT
14910
            return AMOUNT;
14911
          default:
14912
            return null;
14913
        }
2462 chandransh 14914
      }
14915
 
14916
      /**
14917
       * Find the _Fields constant that matches fieldId, throwing an exception
14918
       * if it is not found.
14919
       */
14920
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14921
        _Fields fields = findByThriftId(fieldId);
14922
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14923
        return fields;
14924
      }
14925
 
14926
      /**
14927
       * Find the _Fields constant that matches name, or null if its not found.
14928
       */
14929
      public static _Fields findByName(String name) {
14930
        return byName.get(name);
14931
      }
14932
 
14933
      private final short _thriftId;
14934
      private final String _fieldName;
14935
 
14936
      _Fields(short thriftId, String fieldName) {
14937
        _thriftId = thriftId;
14938
        _fieldName = fieldName;
14939
      }
14940
 
14941
      public short getThriftFieldId() {
14942
        return _thriftId;
14943
      }
14944
 
14945
      public String getFieldName() {
14946
        return _fieldName;
14947
      }
14948
    }
14949
 
14950
    // isset id assignments
3010 chandransh 14951
    private static final int __ORDERID_ISSET_ID = 0;
14952
    private static final int __MERCHANTTXNID_ISSET_ID = 1;
14953
    private static final int __AMOUNT_ISSET_ID = 2;
14954
    private BitSet __isset_bit_vector = new BitSet(3);
2462 chandransh 14955
 
3430 rajveer 14956
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 14957
    static {
3430 rajveer 14958
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14959
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14960
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14961
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14962
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14963
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14964
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
14965
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14966
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createRefund_args.class, metaDataMap);
2462 chandransh 14967
    }
14968
 
3010 chandransh 14969
    public createRefund_args() {
2462 chandransh 14970
    }
14971
 
3010 chandransh 14972
    public createRefund_args(
14973
      long orderId,
14974
      long merchantTxnId,
14975
      double amount)
2462 chandransh 14976
    {
14977
      this();
3010 chandransh 14978
      this.orderId = orderId;
14979
      setOrderIdIsSet(true);
14980
      this.merchantTxnId = merchantTxnId;
14981
      setMerchantTxnIdIsSet(true);
14982
      this.amount = amount;
14983
      setAmountIsSet(true);
2462 chandransh 14984
    }
14985
 
14986
    /**
14987
     * Performs a deep copy on <i>other</i>.
14988
     */
3010 chandransh 14989
    public createRefund_args(createRefund_args other) {
2462 chandransh 14990
      __isset_bit_vector.clear();
14991
      __isset_bit_vector.or(other.__isset_bit_vector);
3010 chandransh 14992
      this.orderId = other.orderId;
14993
      this.merchantTxnId = other.merchantTxnId;
14994
      this.amount = other.amount;
2462 chandransh 14995
    }
14996
 
3010 chandransh 14997
    public createRefund_args deepCopy() {
14998
      return new createRefund_args(this);
2462 chandransh 14999
    }
15000
 
3430 rajveer 15001
    @Override
15002
    public void clear() {
15003
      setOrderIdIsSet(false);
15004
      this.orderId = 0;
15005
      setMerchantTxnIdIsSet(false);
15006
      this.merchantTxnId = 0;
15007
      setAmountIsSet(false);
15008
      this.amount = 0.0;
2462 chandransh 15009
    }
15010
 
3010 chandransh 15011
    public long getOrderId() {
15012
      return this.orderId;
2462 chandransh 15013
    }
15014
 
3430 rajveer 15015
    public void setOrderId(long orderId) {
3010 chandransh 15016
      this.orderId = orderId;
15017
      setOrderIdIsSet(true);
2462 chandransh 15018
    }
15019
 
3010 chandransh 15020
    public void unsetOrderId() {
15021
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
2462 chandransh 15022
    }
15023
 
3430 rajveer 15024
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
3010 chandransh 15025
    public boolean isSetOrderId() {
15026
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
2462 chandransh 15027
    }
15028
 
3010 chandransh 15029
    public void setOrderIdIsSet(boolean value) {
15030
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
2462 chandransh 15031
    }
15032
 
3010 chandransh 15033
    public long getMerchantTxnId() {
15034
      return this.merchantTxnId;
15035
    }
15036
 
3430 rajveer 15037
    public void setMerchantTxnId(long merchantTxnId) {
3010 chandransh 15038
      this.merchantTxnId = merchantTxnId;
15039
      setMerchantTxnIdIsSet(true);
15040
    }
15041
 
15042
    public void unsetMerchantTxnId() {
15043
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
15044
    }
15045
 
3430 rajveer 15046
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
3010 chandransh 15047
    public boolean isSetMerchantTxnId() {
15048
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
15049
    }
15050
 
15051
    public void setMerchantTxnIdIsSet(boolean value) {
15052
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
15053
    }
15054
 
15055
    public double getAmount() {
15056
      return this.amount;
15057
    }
15058
 
3430 rajveer 15059
    public void setAmount(double amount) {
3010 chandransh 15060
      this.amount = amount;
15061
      setAmountIsSet(true);
15062
    }
15063
 
15064
    public void unsetAmount() {
15065
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
15066
    }
15067
 
3430 rajveer 15068
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
3010 chandransh 15069
    public boolean isSetAmount() {
15070
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
15071
    }
15072
 
15073
    public void setAmountIsSet(boolean value) {
15074
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
15075
    }
15076
 
2462 chandransh 15077
    public void setFieldValue(_Fields field, Object value) {
15078
      switch (field) {
3010 chandransh 15079
      case ORDER_ID:
2462 chandransh 15080
        if (value == null) {
3010 chandransh 15081
          unsetOrderId();
2462 chandransh 15082
        } else {
3010 chandransh 15083
          setOrderId((Long)value);
2462 chandransh 15084
        }
15085
        break;
15086
 
3010 chandransh 15087
      case MERCHANT_TXN_ID:
15088
        if (value == null) {
15089
          unsetMerchantTxnId();
15090
        } else {
15091
          setMerchantTxnId((Long)value);
15092
        }
15093
        break;
15094
 
15095
      case AMOUNT:
15096
        if (value == null) {
15097
          unsetAmount();
15098
        } else {
15099
          setAmount((Double)value);
15100
        }
15101
        break;
15102
 
2462 chandransh 15103
      }
15104
    }
15105
 
15106
    public Object getFieldValue(_Fields field) {
15107
      switch (field) {
3010 chandransh 15108
      case ORDER_ID:
3430 rajveer 15109
        return Long.valueOf(getOrderId());
2462 chandransh 15110
 
3010 chandransh 15111
      case MERCHANT_TXN_ID:
3430 rajveer 15112
        return Long.valueOf(getMerchantTxnId());
3010 chandransh 15113
 
15114
      case AMOUNT:
3430 rajveer 15115
        return Double.valueOf(getAmount());
3010 chandransh 15116
 
2462 chandransh 15117
      }
15118
      throw new IllegalStateException();
15119
    }
15120
 
3430 rajveer 15121
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15122
    public boolean isSet(_Fields field) {
15123
      if (field == null) {
15124
        throw new IllegalArgumentException();
15125
      }
2462 chandransh 15126
 
15127
      switch (field) {
3010 chandransh 15128
      case ORDER_ID:
15129
        return isSetOrderId();
15130
      case MERCHANT_TXN_ID:
15131
        return isSetMerchantTxnId();
15132
      case AMOUNT:
15133
        return isSetAmount();
2462 chandransh 15134
      }
15135
      throw new IllegalStateException();
15136
    }
15137
 
15138
    @Override
15139
    public boolean equals(Object that) {
15140
      if (that == null)
15141
        return false;
3010 chandransh 15142
      if (that instanceof createRefund_args)
15143
        return this.equals((createRefund_args)that);
2462 chandransh 15144
      return false;
15145
    }
15146
 
3010 chandransh 15147
    public boolean equals(createRefund_args that) {
2462 chandransh 15148
      if (that == null)
15149
        return false;
15150
 
3010 chandransh 15151
      boolean this_present_orderId = true;
15152
      boolean that_present_orderId = true;
15153
      if (this_present_orderId || that_present_orderId) {
15154
        if (!(this_present_orderId && that_present_orderId))
2462 chandransh 15155
          return false;
3010 chandransh 15156
        if (this.orderId != that.orderId)
2462 chandransh 15157
          return false;
15158
      }
15159
 
3010 chandransh 15160
      boolean this_present_merchantTxnId = true;
15161
      boolean that_present_merchantTxnId = true;
15162
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
15163
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
15164
          return false;
15165
        if (this.merchantTxnId != that.merchantTxnId)
15166
          return false;
15167
      }
15168
 
15169
      boolean this_present_amount = true;
15170
      boolean that_present_amount = true;
15171
      if (this_present_amount || that_present_amount) {
15172
        if (!(this_present_amount && that_present_amount))
15173
          return false;
15174
        if (this.amount != that.amount)
15175
          return false;
15176
      }
15177
 
2462 chandransh 15178
      return true;
15179
    }
15180
 
15181
    @Override
15182
    public int hashCode() {
15183
      return 0;
15184
    }
15185
 
3010 chandransh 15186
    public int compareTo(createRefund_args other) {
2462 chandransh 15187
      if (!getClass().equals(other.getClass())) {
15188
        return getClass().getName().compareTo(other.getClass().getName());
15189
      }
15190
 
15191
      int lastComparison = 0;
3010 chandransh 15192
      createRefund_args typedOther = (createRefund_args)other;
2462 chandransh 15193
 
3430 rajveer 15194
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
2462 chandransh 15195
      if (lastComparison != 0) {
15196
        return lastComparison;
15197
      }
3430 rajveer 15198
      if (isSetOrderId()) {
15199
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
15200
        if (lastComparison != 0) {
15201
          return lastComparison;
15202
        }
2462 chandransh 15203
      }
3430 rajveer 15204
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
3010 chandransh 15205
      if (lastComparison != 0) {
15206
        return lastComparison;
15207
      }
3430 rajveer 15208
      if (isSetMerchantTxnId()) {
15209
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
15210
        if (lastComparison != 0) {
15211
          return lastComparison;
15212
        }
3010 chandransh 15213
      }
3430 rajveer 15214
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
3010 chandransh 15215
      if (lastComparison != 0) {
15216
        return lastComparison;
15217
      }
3430 rajveer 15218
      if (isSetAmount()) {
15219
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
15220
        if (lastComparison != 0) {
15221
          return lastComparison;
15222
        }
3010 chandransh 15223
      }
2462 chandransh 15224
      return 0;
15225
    }
15226
 
3430 rajveer 15227
    public _Fields fieldForId(int fieldId) {
15228
      return _Fields.findByThriftId(fieldId);
15229
    }
15230
 
15231
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15232
      org.apache.thrift.protocol.TField field;
2462 chandransh 15233
      iprot.readStructBegin();
15234
      while (true)
15235
      {
15236
        field = iprot.readFieldBegin();
3430 rajveer 15237
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 15238
          break;
15239
        }
3430 rajveer 15240
        switch (field.id) {
15241
          case 1: // ORDER_ID
15242
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15243
              this.orderId = iprot.readI64();
15244
              setOrderIdIsSet(true);
15245
            } else { 
15246
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15247
            }
15248
            break;
15249
          case 2: // MERCHANT_TXN_ID
15250
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15251
              this.merchantTxnId = iprot.readI64();
15252
              setMerchantTxnIdIsSet(true);
15253
            } else { 
15254
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15255
            }
15256
            break;
15257
          case 3: // AMOUNT
15258
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
15259
              this.amount = iprot.readDouble();
15260
              setAmountIsSet(true);
15261
            } else { 
15262
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15263
            }
15264
            break;
15265
          default:
15266
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 15267
        }
3430 rajveer 15268
        iprot.readFieldEnd();
2462 chandransh 15269
      }
15270
      iprot.readStructEnd();
15271
      validate();
15272
    }
15273
 
3430 rajveer 15274
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 15275
      validate();
15276
 
15277
      oprot.writeStructBegin(STRUCT_DESC);
3010 chandransh 15278
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
15279
      oprot.writeI64(this.orderId);
2462 chandransh 15280
      oprot.writeFieldEnd();
3010 chandransh 15281
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
15282
      oprot.writeI64(this.merchantTxnId);
15283
      oprot.writeFieldEnd();
15284
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
15285
      oprot.writeDouble(this.amount);
15286
      oprot.writeFieldEnd();
2462 chandransh 15287
      oprot.writeFieldStop();
15288
      oprot.writeStructEnd();
15289
    }
15290
 
15291
    @Override
15292
    public String toString() {
3010 chandransh 15293
      StringBuilder sb = new StringBuilder("createRefund_args(");
2462 chandransh 15294
      boolean first = true;
15295
 
3010 chandransh 15296
      sb.append("orderId:");
15297
      sb.append(this.orderId);
2462 chandransh 15298
      first = false;
3010 chandransh 15299
      if (!first) sb.append(", ");
15300
      sb.append("merchantTxnId:");
15301
      sb.append(this.merchantTxnId);
15302
      first = false;
15303
      if (!first) sb.append(", ");
15304
      sb.append("amount:");
15305
      sb.append(this.amount);
15306
      first = false;
2462 chandransh 15307
      sb.append(")");
15308
      return sb.toString();
15309
    }
15310
 
3430 rajveer 15311
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 15312
      // check for required fields
15313
    }
15314
 
3430 rajveer 15315
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15316
      try {
15317
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15318
      } catch (org.apache.thrift.TException te) {
15319
        throw new java.io.IOException(te);
15320
      }
15321
    }
15322
 
15323
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15324
      try {
15325
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15326
      } catch (org.apache.thrift.TException te) {
15327
        throw new java.io.IOException(te);
15328
      }
15329
    }
15330
 
2462 chandransh 15331
  }
15332
 
3430 rajveer 15333
  public static class createRefund_result implements org.apache.thrift.TBase<createRefund_result, createRefund_result._Fields>, java.io.Serializable, Cloneable   {
15334
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createRefund_result");
2462 chandransh 15335
 
3430 rajveer 15336
    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);
15337
    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 15338
 
3430 rajveer 15339
    private long success; // required
15340
    private PaymentException pe; // required
2462 chandransh 15341
 
15342
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 15343
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 15344
      SUCCESS((short)0, "success"),
15345
      PE((short)1, "pe");
15346
 
15347
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15348
 
15349
      static {
15350
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15351
          byName.put(field.getFieldName(), field);
15352
        }
15353
      }
15354
 
15355
      /**
15356
       * Find the _Fields constant that matches fieldId, or null if its not found.
15357
       */
15358
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 15359
        switch(fieldId) {
15360
          case 0: // SUCCESS
15361
            return SUCCESS;
15362
          case 1: // PE
15363
            return PE;
15364
          default:
15365
            return null;
15366
        }
2462 chandransh 15367
      }
15368
 
15369
      /**
15370
       * Find the _Fields constant that matches fieldId, throwing an exception
15371
       * if it is not found.
15372
       */
15373
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15374
        _Fields fields = findByThriftId(fieldId);
15375
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15376
        return fields;
15377
      }
15378
 
15379
      /**
15380
       * Find the _Fields constant that matches name, or null if its not found.
15381
       */
15382
      public static _Fields findByName(String name) {
15383
        return byName.get(name);
15384
      }
15385
 
15386
      private final short _thriftId;
15387
      private final String _fieldName;
15388
 
15389
      _Fields(short thriftId, String fieldName) {
15390
        _thriftId = thriftId;
15391
        _fieldName = fieldName;
15392
      }
15393
 
15394
      public short getThriftFieldId() {
15395
        return _thriftId;
15396
      }
15397
 
15398
      public String getFieldName() {
15399
        return _fieldName;
15400
      }
15401
    }
15402
 
15403
    // isset id assignments
3010 chandransh 15404
    private static final int __SUCCESS_ISSET_ID = 0;
15405
    private BitSet __isset_bit_vector = new BitSet(1);
2462 chandransh 15406
 
3430 rajveer 15407
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 15408
    static {
3430 rajveer 15409
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15410
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15411
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
15412
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15413
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15414
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15415
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createRefund_result.class, metaDataMap);
2462 chandransh 15416
    }
15417
 
3010 chandransh 15418
    public createRefund_result() {
2462 chandransh 15419
    }
15420
 
3010 chandransh 15421
    public createRefund_result(
15422
      long success,
2462 chandransh 15423
      PaymentException pe)
15424
    {
15425
      this();
15426
      this.success = success;
3010 chandransh 15427
      setSuccessIsSet(true);
2462 chandransh 15428
      this.pe = pe;
15429
    }
15430
 
15431
    /**
15432
     * Performs a deep copy on <i>other</i>.
15433
     */
3010 chandransh 15434
    public createRefund_result(createRefund_result other) {
15435
      __isset_bit_vector.clear();
15436
      __isset_bit_vector.or(other.__isset_bit_vector);
15437
      this.success = other.success;
2462 chandransh 15438
      if (other.isSetPe()) {
15439
        this.pe = new PaymentException(other.pe);
15440
      }
15441
    }
15442
 
3010 chandransh 15443
    public createRefund_result deepCopy() {
15444
      return new createRefund_result(this);
2462 chandransh 15445
    }
15446
 
3430 rajveer 15447
    @Override
15448
    public void clear() {
15449
      setSuccessIsSet(false);
15450
      this.success = 0;
15451
      this.pe = null;
2462 chandransh 15452
    }
15453
 
3010 chandransh 15454
    public long getSuccess() {
2462 chandransh 15455
      return this.success;
15456
    }
15457
 
3430 rajveer 15458
    public void setSuccess(long success) {
2462 chandransh 15459
      this.success = success;
3010 chandransh 15460
      setSuccessIsSet(true);
2462 chandransh 15461
    }
15462
 
15463
    public void unsetSuccess() {
3010 chandransh 15464
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
2462 chandransh 15465
    }
15466
 
3430 rajveer 15467
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2462 chandransh 15468
    public boolean isSetSuccess() {
3010 chandransh 15469
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
2462 chandransh 15470
    }
15471
 
15472
    public void setSuccessIsSet(boolean value) {
3010 chandransh 15473
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
2462 chandransh 15474
    }
15475
 
15476
    public PaymentException getPe() {
15477
      return this.pe;
15478
    }
15479
 
3430 rajveer 15480
    public void setPe(PaymentException pe) {
2462 chandransh 15481
      this.pe = pe;
15482
    }
15483
 
15484
    public void unsetPe() {
15485
      this.pe = null;
15486
    }
15487
 
3430 rajveer 15488
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2462 chandransh 15489
    public boolean isSetPe() {
15490
      return this.pe != null;
15491
    }
15492
 
15493
    public void setPeIsSet(boolean value) {
15494
      if (!value) {
15495
        this.pe = null;
15496
      }
15497
    }
15498
 
15499
    public void setFieldValue(_Fields field, Object value) {
15500
      switch (field) {
15501
      case SUCCESS:
15502
        if (value == null) {
15503
          unsetSuccess();
15504
        } else {
3010 chandransh 15505
          setSuccess((Long)value);
2462 chandransh 15506
        }
15507
        break;
15508
 
15509
      case PE:
15510
        if (value == null) {
15511
          unsetPe();
15512
        } else {
15513
          setPe((PaymentException)value);
15514
        }
15515
        break;
15516
 
15517
      }
15518
    }
15519
 
15520
    public Object getFieldValue(_Fields field) {
15521
      switch (field) {
15522
      case SUCCESS:
3430 rajveer 15523
        return Long.valueOf(getSuccess());
2462 chandransh 15524
 
15525
      case PE:
15526
        return getPe();
15527
 
15528
      }
15529
      throw new IllegalStateException();
15530
    }
15531
 
3430 rajveer 15532
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15533
    public boolean isSet(_Fields field) {
15534
      if (field == null) {
15535
        throw new IllegalArgumentException();
15536
      }
2462 chandransh 15537
 
15538
      switch (field) {
15539
      case SUCCESS:
15540
        return isSetSuccess();
15541
      case PE:
15542
        return isSetPe();
15543
      }
15544
      throw new IllegalStateException();
15545
    }
15546
 
15547
    @Override
15548
    public boolean equals(Object that) {
15549
      if (that == null)
15550
        return false;
3010 chandransh 15551
      if (that instanceof createRefund_result)
15552
        return this.equals((createRefund_result)that);
2462 chandransh 15553
      return false;
15554
    }
15555
 
3010 chandransh 15556
    public boolean equals(createRefund_result that) {
2462 chandransh 15557
      if (that == null)
15558
        return false;
15559
 
3010 chandransh 15560
      boolean this_present_success = true;
15561
      boolean that_present_success = true;
2462 chandransh 15562
      if (this_present_success || that_present_success) {
15563
        if (!(this_present_success && that_present_success))
15564
          return false;
3010 chandransh 15565
        if (this.success != that.success)
2462 chandransh 15566
          return false;
15567
      }
15568
 
15569
      boolean this_present_pe = true && this.isSetPe();
15570
      boolean that_present_pe = true && that.isSetPe();
15571
      if (this_present_pe || that_present_pe) {
15572
        if (!(this_present_pe && that_present_pe))
15573
          return false;
15574
        if (!this.pe.equals(that.pe))
15575
          return false;
15576
      }
15577
 
15578
      return true;
15579
    }
15580
 
15581
    @Override
15582
    public int hashCode() {
15583
      return 0;
15584
    }
15585
 
3010 chandransh 15586
    public int compareTo(createRefund_result other) {
2462 chandransh 15587
      if (!getClass().equals(other.getClass())) {
15588
        return getClass().getName().compareTo(other.getClass().getName());
15589
      }
15590
 
15591
      int lastComparison = 0;
3010 chandransh 15592
      createRefund_result typedOther = (createRefund_result)other;
2462 chandransh 15593
 
3430 rajveer 15594
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2462 chandransh 15595
      if (lastComparison != 0) {
15596
        return lastComparison;
15597
      }
3430 rajveer 15598
      if (isSetSuccess()) {
15599
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15600
        if (lastComparison != 0) {
15601
          return lastComparison;
15602
        }
2462 chandransh 15603
      }
3430 rajveer 15604
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
2462 chandransh 15605
      if (lastComparison != 0) {
15606
        return lastComparison;
15607
      }
3430 rajveer 15608
      if (isSetPe()) {
15609
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
15610
        if (lastComparison != 0) {
15611
          return lastComparison;
15612
        }
2462 chandransh 15613
      }
15614
      return 0;
15615
    }
15616
 
3430 rajveer 15617
    public _Fields fieldForId(int fieldId) {
15618
      return _Fields.findByThriftId(fieldId);
15619
    }
15620
 
15621
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15622
      org.apache.thrift.protocol.TField field;
2462 chandransh 15623
      iprot.readStructBegin();
15624
      while (true)
15625
      {
15626
        field = iprot.readFieldBegin();
3430 rajveer 15627
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 15628
          break;
15629
        }
3430 rajveer 15630
        switch (field.id) {
15631
          case 0: // SUCCESS
15632
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15633
              this.success = iprot.readI64();
15634
              setSuccessIsSet(true);
15635
            } else { 
15636
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15637
            }
15638
            break;
15639
          case 1: // PE
15640
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15641
              this.pe = new PaymentException();
15642
              this.pe.read(iprot);
15643
            } else { 
15644
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15645
            }
15646
            break;
15647
          default:
15648
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 15649
        }
3430 rajveer 15650
        iprot.readFieldEnd();
2462 chandransh 15651
      }
15652
      iprot.readStructEnd();
15653
      validate();
15654
    }
15655
 
3430 rajveer 15656
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 15657
      oprot.writeStructBegin(STRUCT_DESC);
15658
 
15659
      if (this.isSetSuccess()) {
15660
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 15661
        oprot.writeI64(this.success);
2462 chandransh 15662
        oprot.writeFieldEnd();
15663
      } else if (this.isSetPe()) {
15664
        oprot.writeFieldBegin(PE_FIELD_DESC);
15665
        this.pe.write(oprot);
15666
        oprot.writeFieldEnd();
15667
      }
15668
      oprot.writeFieldStop();
15669
      oprot.writeStructEnd();
15670
    }
15671
 
15672
    @Override
15673
    public String toString() {
3010 chandransh 15674
      StringBuilder sb = new StringBuilder("createRefund_result(");
2462 chandransh 15675
      boolean first = true;
15676
 
15677
      sb.append("success:");
3010 chandransh 15678
      sb.append(this.success);
2462 chandransh 15679
      first = false;
15680
      if (!first) sb.append(", ");
15681
      sb.append("pe:");
15682
      if (this.pe == null) {
15683
        sb.append("null");
15684
      } else {
15685
        sb.append(this.pe);
15686
      }
15687
      first = false;
15688
      sb.append(")");
15689
      return sb.toString();
15690
    }
15691
 
3430 rajveer 15692
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 15693
      // check for required fields
15694
    }
15695
 
3430 rajveer 15696
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15697
      try {
15698
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15699
      } catch (org.apache.thrift.TException te) {
15700
        throw new java.io.IOException(te);
15701
      }
15702
    }
15703
 
15704
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15705
      try {
15706
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15707
      } catch (org.apache.thrift.TException te) {
15708
        throw new java.io.IOException(te);
15709
      }
15710
    }
15711
 
2462 chandransh 15712
  }
15713
 
3430 rajveer 15714
  public static class capturePayment_args implements org.apache.thrift.TBase<capturePayment_args, capturePayment_args._Fields>, java.io.Serializable, Cloneable   {
15715
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("capturePayment_args");
2690 chandransh 15716
 
3430 rajveer 15717
    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);
8618 rajveer 15718
    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)2);
2690 chandransh 15719
 
3430 rajveer 15720
    private long merchantTxnId; // required
8618 rajveer 15721
    private boolean isDigital; // required
2690 chandransh 15722
 
15723
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 15724
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8618 rajveer 15725
      MERCHANT_TXN_ID((short)1, "merchantTxnId"),
15726
      IS_DIGITAL((short)2, "isDigital");
2690 chandransh 15727
 
15728
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15729
 
15730
      static {
15731
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15732
          byName.put(field.getFieldName(), field);
15733
        }
15734
      }
15735
 
15736
      /**
15737
       * Find the _Fields constant that matches fieldId, or null if its not found.
15738
       */
15739
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 15740
        switch(fieldId) {
15741
          case 1: // MERCHANT_TXN_ID
15742
            return MERCHANT_TXN_ID;
8618 rajveer 15743
          case 2: // IS_DIGITAL
15744
            return IS_DIGITAL;
3430 rajveer 15745
          default:
15746
            return null;
15747
        }
2690 chandransh 15748
      }
15749
 
15750
      /**
15751
       * Find the _Fields constant that matches fieldId, throwing an exception
15752
       * if it is not found.
15753
       */
15754
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15755
        _Fields fields = findByThriftId(fieldId);
15756
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15757
        return fields;
15758
      }
15759
 
15760
      /**
15761
       * Find the _Fields constant that matches name, or null if its not found.
15762
       */
15763
      public static _Fields findByName(String name) {
15764
        return byName.get(name);
15765
      }
15766
 
15767
      private final short _thriftId;
15768
      private final String _fieldName;
15769
 
15770
      _Fields(short thriftId, String fieldName) {
15771
        _thriftId = thriftId;
15772
        _fieldName = fieldName;
15773
      }
15774
 
15775
      public short getThriftFieldId() {
15776
        return _thriftId;
15777
      }
15778
 
15779
      public String getFieldName() {
15780
        return _fieldName;
15781
      }
15782
    }
15783
 
15784
    // isset id assignments
3010 chandransh 15785
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
8618 rajveer 15786
    private static final int __ISDIGITAL_ISSET_ID = 1;
15787
    private BitSet __isset_bit_vector = new BitSet(2);
2690 chandransh 15788
 
3430 rajveer 15789
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2690 chandransh 15790
    static {
3430 rajveer 15791
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15792
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15793
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8618 rajveer 15794
      tmpMap.put(_Fields.IS_DIGITAL, new org.apache.thrift.meta_data.FieldMetaData("isDigital", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15795
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
3430 rajveer 15796
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15797
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(capturePayment_args.class, metaDataMap);
2690 chandransh 15798
    }
15799
 
3010 chandransh 15800
    public capturePayment_args() {
2690 chandransh 15801
    }
15802
 
3010 chandransh 15803
    public capturePayment_args(
8618 rajveer 15804
      long merchantTxnId,
15805
      boolean isDigital)
2690 chandransh 15806
    {
15807
      this();
15808
      this.merchantTxnId = merchantTxnId;
15809
      setMerchantTxnIdIsSet(true);
8618 rajveer 15810
      this.isDigital = isDigital;
15811
      setIsDigitalIsSet(true);
2690 chandransh 15812
    }
15813
 
15814
    /**
15815
     * Performs a deep copy on <i>other</i>.
15816
     */
3010 chandransh 15817
    public capturePayment_args(capturePayment_args other) {
2690 chandransh 15818
      __isset_bit_vector.clear();
15819
      __isset_bit_vector.or(other.__isset_bit_vector);
15820
      this.merchantTxnId = other.merchantTxnId;
8618 rajveer 15821
      this.isDigital = other.isDigital;
2690 chandransh 15822
    }
15823
 
3010 chandransh 15824
    public capturePayment_args deepCopy() {
15825
      return new capturePayment_args(this);
2690 chandransh 15826
    }
15827
 
3430 rajveer 15828
    @Override
15829
    public void clear() {
15830
      setMerchantTxnIdIsSet(false);
15831
      this.merchantTxnId = 0;
8618 rajveer 15832
      setIsDigitalIsSet(false);
15833
      this.isDigital = false;
2690 chandransh 15834
    }
15835
 
15836
    public long getMerchantTxnId() {
15837
      return this.merchantTxnId;
15838
    }
15839
 
3430 rajveer 15840
    public void setMerchantTxnId(long merchantTxnId) {
2690 chandransh 15841
      this.merchantTxnId = merchantTxnId;
15842
      setMerchantTxnIdIsSet(true);
15843
    }
15844
 
15845
    public void unsetMerchantTxnId() {
15846
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
15847
    }
15848
 
3430 rajveer 15849
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
2690 chandransh 15850
    public boolean isSetMerchantTxnId() {
15851
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
15852
    }
15853
 
15854
    public void setMerchantTxnIdIsSet(boolean value) {
15855
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
15856
    }
15857
 
8618 rajveer 15858
    public boolean isIsDigital() {
15859
      return this.isDigital;
15860
    }
15861
 
15862
    public void setIsDigital(boolean isDigital) {
15863
      this.isDigital = isDigital;
15864
      setIsDigitalIsSet(true);
15865
    }
15866
 
15867
    public void unsetIsDigital() {
15868
      __isset_bit_vector.clear(__ISDIGITAL_ISSET_ID);
15869
    }
15870
 
15871
    /** Returns true if field isDigital is set (has been assigned a value) and false otherwise */
15872
    public boolean isSetIsDigital() {
15873
      return __isset_bit_vector.get(__ISDIGITAL_ISSET_ID);
15874
    }
15875
 
15876
    public void setIsDigitalIsSet(boolean value) {
15877
      __isset_bit_vector.set(__ISDIGITAL_ISSET_ID, value);
15878
    }
15879
 
2690 chandransh 15880
    public void setFieldValue(_Fields field, Object value) {
15881
      switch (field) {
15882
      case MERCHANT_TXN_ID:
15883
        if (value == null) {
15884
          unsetMerchantTxnId();
15885
        } else {
15886
          setMerchantTxnId((Long)value);
15887
        }
15888
        break;
15889
 
8618 rajveer 15890
      case IS_DIGITAL:
15891
        if (value == null) {
15892
          unsetIsDigital();
15893
        } else {
15894
          setIsDigital((Boolean)value);
15895
        }
15896
        break;
15897
 
2690 chandransh 15898
      }
15899
    }
15900
 
15901
    public Object getFieldValue(_Fields field) {
15902
      switch (field) {
15903
      case MERCHANT_TXN_ID:
3430 rajveer 15904
        return Long.valueOf(getMerchantTxnId());
2690 chandransh 15905
 
8618 rajveer 15906
      case IS_DIGITAL:
15907
        return Boolean.valueOf(isIsDigital());
15908
 
2690 chandransh 15909
      }
15910
      throw new IllegalStateException();
15911
    }
15912
 
3430 rajveer 15913
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15914
    public boolean isSet(_Fields field) {
15915
      if (field == null) {
15916
        throw new IllegalArgumentException();
15917
      }
2690 chandransh 15918
 
15919
      switch (field) {
15920
      case MERCHANT_TXN_ID:
15921
        return isSetMerchantTxnId();
8618 rajveer 15922
      case IS_DIGITAL:
15923
        return isSetIsDigital();
2690 chandransh 15924
      }
15925
      throw new IllegalStateException();
15926
    }
15927
 
15928
    @Override
15929
    public boolean equals(Object that) {
15930
      if (that == null)
15931
        return false;
3010 chandransh 15932
      if (that instanceof capturePayment_args)
15933
        return this.equals((capturePayment_args)that);
2690 chandransh 15934
      return false;
15935
    }
15936
 
3010 chandransh 15937
    public boolean equals(capturePayment_args that) {
2690 chandransh 15938
      if (that == null)
15939
        return false;
15940
 
15941
      boolean this_present_merchantTxnId = true;
15942
      boolean that_present_merchantTxnId = true;
15943
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
15944
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
15945
          return false;
15946
        if (this.merchantTxnId != that.merchantTxnId)
15947
          return false;
15948
      }
15949
 
8618 rajveer 15950
      boolean this_present_isDigital = true;
15951
      boolean that_present_isDigital = true;
15952
      if (this_present_isDigital || that_present_isDigital) {
15953
        if (!(this_present_isDigital && that_present_isDigital))
15954
          return false;
15955
        if (this.isDigital != that.isDigital)
15956
          return false;
15957
      }
15958
 
2690 chandransh 15959
      return true;
15960
    }
15961
 
15962
    @Override
15963
    public int hashCode() {
15964
      return 0;
15965
    }
15966
 
3010 chandransh 15967
    public int compareTo(capturePayment_args other) {
2690 chandransh 15968
      if (!getClass().equals(other.getClass())) {
15969
        return getClass().getName().compareTo(other.getClass().getName());
15970
      }
15971
 
15972
      int lastComparison = 0;
3010 chandransh 15973
      capturePayment_args typedOther = (capturePayment_args)other;
2690 chandransh 15974
 
3430 rajveer 15975
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
2690 chandransh 15976
      if (lastComparison != 0) {
15977
        return lastComparison;
15978
      }
3430 rajveer 15979
      if (isSetMerchantTxnId()) {
15980
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
15981
        if (lastComparison != 0) {
15982
          return lastComparison;
15983
        }
2690 chandransh 15984
      }
8618 rajveer 15985
      lastComparison = Boolean.valueOf(isSetIsDigital()).compareTo(typedOther.isSetIsDigital());
15986
      if (lastComparison != 0) {
15987
        return lastComparison;
15988
      }
15989
      if (isSetIsDigital()) {
15990
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isDigital, typedOther.isDigital);
15991
        if (lastComparison != 0) {
15992
          return lastComparison;
15993
        }
15994
      }
2690 chandransh 15995
      return 0;
15996
    }
15997
 
3430 rajveer 15998
    public _Fields fieldForId(int fieldId) {
15999
      return _Fields.findByThriftId(fieldId);
16000
    }
16001
 
16002
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16003
      org.apache.thrift.protocol.TField field;
2690 chandransh 16004
      iprot.readStructBegin();
16005
      while (true)
16006
      {
16007
        field = iprot.readFieldBegin();
3430 rajveer 16008
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2690 chandransh 16009
          break;
16010
        }
3430 rajveer 16011
        switch (field.id) {
16012
          case 1: // MERCHANT_TXN_ID
16013
            if (field.type == org.apache.thrift.protocol.TType.I64) {
16014
              this.merchantTxnId = iprot.readI64();
16015
              setMerchantTxnIdIsSet(true);
16016
            } else { 
16017
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16018
            }
16019
            break;
8618 rajveer 16020
          case 2: // IS_DIGITAL
16021
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
16022
              this.isDigital = iprot.readBool();
16023
              setIsDigitalIsSet(true);
16024
            } else { 
16025
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16026
            }
16027
            break;
3430 rajveer 16028
          default:
16029
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2690 chandransh 16030
        }
3430 rajveer 16031
        iprot.readFieldEnd();
2690 chandransh 16032
      }
16033
      iprot.readStructEnd();
16034
      validate();
16035
    }
16036
 
3430 rajveer 16037
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2690 chandransh 16038
      validate();
16039
 
16040
      oprot.writeStructBegin(STRUCT_DESC);
16041
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
16042
      oprot.writeI64(this.merchantTxnId);
16043
      oprot.writeFieldEnd();
8618 rajveer 16044
      oprot.writeFieldBegin(IS_DIGITAL_FIELD_DESC);
16045
      oprot.writeBool(this.isDigital);
16046
      oprot.writeFieldEnd();
2690 chandransh 16047
      oprot.writeFieldStop();
16048
      oprot.writeStructEnd();
16049
    }
16050
 
16051
    @Override
16052
    public String toString() {
3010 chandransh 16053
      StringBuilder sb = new StringBuilder("capturePayment_args(");
2690 chandransh 16054
      boolean first = true;
16055
 
16056
      sb.append("merchantTxnId:");
16057
      sb.append(this.merchantTxnId);
16058
      first = false;
8618 rajveer 16059
      if (!first) sb.append(", ");
16060
      sb.append("isDigital:");
16061
      sb.append(this.isDigital);
16062
      first = false;
2690 chandransh 16063
      sb.append(")");
16064
      return sb.toString();
16065
    }
16066
 
3430 rajveer 16067
    public void validate() throws org.apache.thrift.TException {
2690 chandransh 16068
      // check for required fields
16069
    }
16070
 
3430 rajveer 16071
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16072
      try {
16073
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16074
      } catch (org.apache.thrift.TException te) {
16075
        throw new java.io.IOException(te);
16076
      }
16077
    }
16078
 
16079
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16080
      try {
16081
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16082
      } catch (org.apache.thrift.TException te) {
16083
        throw new java.io.IOException(te);
16084
      }
16085
    }
16086
 
2690 chandransh 16087
  }
16088
 
3430 rajveer 16089
  public static class capturePayment_result implements org.apache.thrift.TBase<capturePayment_result, capturePayment_result._Fields>, java.io.Serializable, Cloneable   {
16090
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("capturePayment_result");
2690 chandransh 16091
 
3430 rajveer 16092
    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);
16093
    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 16094
 
3430 rajveer 16095
    private boolean success; // required
16096
    private PaymentException pe; // required
2690 chandransh 16097
 
16098
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 16099
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2690 chandransh 16100
      SUCCESS((short)0, "success"),
16101
      PE((short)1, "pe");
16102
 
16103
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16104
 
16105
      static {
16106
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16107
          byName.put(field.getFieldName(), field);
16108
        }
16109
      }
16110
 
16111
      /**
16112
       * Find the _Fields constant that matches fieldId, or null if its not found.
16113
       */
16114
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 16115
        switch(fieldId) {
16116
          case 0: // SUCCESS
16117
            return SUCCESS;
16118
          case 1: // PE
16119
            return PE;
16120
          default:
16121
            return null;
16122
        }
2690 chandransh 16123
      }
16124
 
16125
      /**
16126
       * Find the _Fields constant that matches fieldId, throwing an exception
16127
       * if it is not found.
16128
       */
16129
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16130
        _Fields fields = findByThriftId(fieldId);
16131
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16132
        return fields;
16133
      }
16134
 
16135
      /**
16136
       * Find the _Fields constant that matches name, or null if its not found.
16137
       */
16138
      public static _Fields findByName(String name) {
16139
        return byName.get(name);
16140
      }
16141
 
16142
      private final short _thriftId;
16143
      private final String _fieldName;
16144
 
16145
      _Fields(short thriftId, String fieldName) {
16146
        _thriftId = thriftId;
16147
        _fieldName = fieldName;
16148
      }
16149
 
16150
      public short getThriftFieldId() {
16151
        return _thriftId;
16152
      }
16153
 
16154
      public String getFieldName() {
16155
        return _fieldName;
16156
      }
16157
    }
16158
 
16159
    // isset id assignments
16160
    private static final int __SUCCESS_ISSET_ID = 0;
16161
    private BitSet __isset_bit_vector = new BitSet(1);
16162
 
3430 rajveer 16163
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2690 chandransh 16164
    static {
3430 rajveer 16165
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16166
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16167
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
16168
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16169
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
16170
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16171
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(capturePayment_result.class, metaDataMap);
2690 chandransh 16172
    }
16173
 
3010 chandransh 16174
    public capturePayment_result() {
2690 chandransh 16175
    }
16176
 
3010 chandransh 16177
    public capturePayment_result(
16178
      boolean success,
2690 chandransh 16179
      PaymentException pe)
16180
    {
16181
      this();
16182
      this.success = success;
16183
      setSuccessIsSet(true);
16184
      this.pe = pe;
16185
    }
16186
 
16187
    /**
16188
     * Performs a deep copy on <i>other</i>.
16189
     */
3010 chandransh 16190
    public capturePayment_result(capturePayment_result other) {
2690 chandransh 16191
      __isset_bit_vector.clear();
16192
      __isset_bit_vector.or(other.__isset_bit_vector);
16193
      this.success = other.success;
16194
      if (other.isSetPe()) {
16195
        this.pe = new PaymentException(other.pe);
16196
      }
16197
    }
16198
 
3010 chandransh 16199
    public capturePayment_result deepCopy() {
16200
      return new capturePayment_result(this);
2690 chandransh 16201
    }
16202
 
3430 rajveer 16203
    @Override
16204
    public void clear() {
16205
      setSuccessIsSet(false);
16206
      this.success = false;
16207
      this.pe = null;
2690 chandransh 16208
    }
16209
 
3010 chandransh 16210
    public boolean isSuccess() {
2690 chandransh 16211
      return this.success;
16212
    }
16213
 
3430 rajveer 16214
    public void setSuccess(boolean success) {
2690 chandransh 16215
      this.success = success;
16216
      setSuccessIsSet(true);
16217
    }
16218
 
16219
    public void unsetSuccess() {
16220
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
16221
    }
16222
 
3430 rajveer 16223
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2690 chandransh 16224
    public boolean isSetSuccess() {
16225
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
16226
    }
16227
 
16228
    public void setSuccessIsSet(boolean value) {
16229
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
16230
    }
16231
 
16232
    public PaymentException getPe() {
16233
      return this.pe;
16234
    }
16235
 
3430 rajveer 16236
    public void setPe(PaymentException pe) {
2690 chandransh 16237
      this.pe = pe;
16238
    }
16239
 
16240
    public void unsetPe() {
16241
      this.pe = null;
16242
    }
16243
 
3430 rajveer 16244
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2690 chandransh 16245
    public boolean isSetPe() {
16246
      return this.pe != null;
16247
    }
16248
 
16249
    public void setPeIsSet(boolean value) {
16250
      if (!value) {
16251
        this.pe = null;
16252
      }
16253
    }
16254
 
16255
    public void setFieldValue(_Fields field, Object value) {
16256
      switch (field) {
16257
      case SUCCESS:
16258
        if (value == null) {
16259
          unsetSuccess();
16260
        } else {
3010 chandransh 16261
          setSuccess((Boolean)value);
2690 chandransh 16262
        }
16263
        break;
16264
 
16265
      case PE:
16266
        if (value == null) {
16267
          unsetPe();
16268
        } else {
16269
          setPe((PaymentException)value);
16270
        }
16271
        break;
16272
 
16273
      }
16274
    }
16275
 
16276
    public Object getFieldValue(_Fields field) {
16277
      switch (field) {
16278
      case SUCCESS:
3430 rajveer 16279
        return Boolean.valueOf(isSuccess());
2690 chandransh 16280
 
16281
      case PE:
16282
        return getPe();
16283
 
16284
      }
16285
      throw new IllegalStateException();
16286
    }
16287
 
3430 rajveer 16288
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16289
    public boolean isSet(_Fields field) {
16290
      if (field == null) {
16291
        throw new IllegalArgumentException();
16292
      }
2690 chandransh 16293
 
16294
      switch (field) {
16295
      case SUCCESS:
16296
        return isSetSuccess();
16297
      case PE:
16298
        return isSetPe();
16299
      }
16300
      throw new IllegalStateException();
16301
    }
16302
 
16303
    @Override
16304
    public boolean equals(Object that) {
16305
      if (that == null)
16306
        return false;
3010 chandransh 16307
      if (that instanceof capturePayment_result)
16308
        return this.equals((capturePayment_result)that);
2690 chandransh 16309
      return false;
16310
    }
16311
 
3010 chandransh 16312
    public boolean equals(capturePayment_result that) {
2690 chandransh 16313
      if (that == null)
16314
        return false;
16315
 
16316
      boolean this_present_success = true;
16317
      boolean that_present_success = true;
16318
      if (this_present_success || that_present_success) {
16319
        if (!(this_present_success && that_present_success))
16320
          return false;
16321
        if (this.success != that.success)
16322
          return false;
16323
      }
16324
 
16325
      boolean this_present_pe = true && this.isSetPe();
16326
      boolean that_present_pe = true && that.isSetPe();
16327
      if (this_present_pe || that_present_pe) {
16328
        if (!(this_present_pe && that_present_pe))
16329
          return false;
16330
        if (!this.pe.equals(that.pe))
16331
          return false;
16332
      }
16333
 
16334
      return true;
16335
    }
16336
 
16337
    @Override
16338
    public int hashCode() {
16339
      return 0;
16340
    }
16341
 
3010 chandransh 16342
    public int compareTo(capturePayment_result other) {
2690 chandransh 16343
      if (!getClass().equals(other.getClass())) {
16344
        return getClass().getName().compareTo(other.getClass().getName());
16345
      }
16346
 
16347
      int lastComparison = 0;
3010 chandransh 16348
      capturePayment_result typedOther = (capturePayment_result)other;
2690 chandransh 16349
 
3430 rajveer 16350
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2690 chandransh 16351
      if (lastComparison != 0) {
16352
        return lastComparison;
16353
      }
3430 rajveer 16354
      if (isSetSuccess()) {
16355
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
16356
        if (lastComparison != 0) {
16357
          return lastComparison;
16358
        }
2690 chandransh 16359
      }
3430 rajveer 16360
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
2690 chandransh 16361
      if (lastComparison != 0) {
16362
        return lastComparison;
16363
      }
3430 rajveer 16364
      if (isSetPe()) {
16365
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
16366
        if (lastComparison != 0) {
16367
          return lastComparison;
16368
        }
2690 chandransh 16369
      }
16370
      return 0;
16371
    }
16372
 
3430 rajveer 16373
    public _Fields fieldForId(int fieldId) {
16374
      return _Fields.findByThriftId(fieldId);
16375
    }
16376
 
16377
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16378
      org.apache.thrift.protocol.TField field;
2690 chandransh 16379
      iprot.readStructBegin();
16380
      while (true)
16381
      {
16382
        field = iprot.readFieldBegin();
3430 rajveer 16383
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2690 chandransh 16384
          break;
16385
        }
3430 rajveer 16386
        switch (field.id) {
16387
          case 0: // SUCCESS
16388
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
16389
              this.success = iprot.readBool();
16390
              setSuccessIsSet(true);
16391
            } else { 
16392
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16393
            }
16394
            break;
16395
          case 1: // PE
16396
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16397
              this.pe = new PaymentException();
16398
              this.pe.read(iprot);
16399
            } else { 
16400
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16401
            }
16402
            break;
16403
          default:
16404
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2690 chandransh 16405
        }
3430 rajveer 16406
        iprot.readFieldEnd();
2690 chandransh 16407
      }
16408
      iprot.readStructEnd();
16409
      validate();
16410
    }
16411
 
3430 rajveer 16412
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2690 chandransh 16413
      oprot.writeStructBegin(STRUCT_DESC);
16414
 
16415
      if (this.isSetSuccess()) {
16416
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 16417
        oprot.writeBool(this.success);
2690 chandransh 16418
        oprot.writeFieldEnd();
16419
      } else if (this.isSetPe()) {
16420
        oprot.writeFieldBegin(PE_FIELD_DESC);
16421
        this.pe.write(oprot);
16422
        oprot.writeFieldEnd();
16423
      }
16424
      oprot.writeFieldStop();
16425
      oprot.writeStructEnd();
16426
    }
16427
 
16428
    @Override
16429
    public String toString() {
3010 chandransh 16430
      StringBuilder sb = new StringBuilder("capturePayment_result(");
2690 chandransh 16431
      boolean first = true;
16432
 
16433
      sb.append("success:");
16434
      sb.append(this.success);
16435
      first = false;
16436
      if (!first) sb.append(", ");
16437
      sb.append("pe:");
16438
      if (this.pe == null) {
16439
        sb.append("null");
16440
      } else {
16441
        sb.append(this.pe);
16442
      }
16443
      first = false;
16444
      sb.append(")");
16445
      return sb.toString();
16446
    }
16447
 
3430 rajveer 16448
    public void validate() throws org.apache.thrift.TException {
2690 chandransh 16449
      // check for required fields
16450
    }
16451
 
3430 rajveer 16452
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16453
      try {
16454
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16455
      } catch (org.apache.thrift.TException te) {
16456
        throw new java.io.IOException(te);
16457
      }
16458
    }
16459
 
16460
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16461
      try {
16462
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16463
      } catch (org.apache.thrift.TException te) {
16464
        throw new java.io.IOException(te);
16465
      }
16466
    }
16467
 
2690 chandransh 16468
  }
16469
 
6486 rajveer 16470
  public static class refundPayment_args implements org.apache.thrift.TBase<refundPayment_args, refundPayment_args._Fields>, java.io.Serializable, Cloneable   {
16471
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("refundPayment_args");
16472
 
16473
    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);
16474
    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);
16475
    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);
16476
 
16477
    private long merchantTxnId; // required
16478
    private double amount; // required
16479
    private boolean isDigital; // required
16480
 
16481
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16482
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16483
      MERCHANT_TXN_ID((short)1, "merchantTxnId"),
16484
      AMOUNT((short)2, "amount"),
16485
      IS_DIGITAL((short)3, "isDigital");
16486
 
16487
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16488
 
16489
      static {
16490
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16491
          byName.put(field.getFieldName(), field);
16492
        }
16493
      }
16494
 
16495
      /**
16496
       * Find the _Fields constant that matches fieldId, or null if its not found.
16497
       */
16498
      public static _Fields findByThriftId(int fieldId) {
16499
        switch(fieldId) {
16500
          case 1: // MERCHANT_TXN_ID
16501
            return MERCHANT_TXN_ID;
16502
          case 2: // AMOUNT
16503
            return AMOUNT;
16504
          case 3: // IS_DIGITAL
16505
            return IS_DIGITAL;
16506
          default:
16507
            return null;
16508
        }
16509
      }
16510
 
16511
      /**
16512
       * Find the _Fields constant that matches fieldId, throwing an exception
16513
       * if it is not found.
16514
       */
16515
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16516
        _Fields fields = findByThriftId(fieldId);
16517
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16518
        return fields;
16519
      }
16520
 
16521
      /**
16522
       * Find the _Fields constant that matches name, or null if its not found.
16523
       */
16524
      public static _Fields findByName(String name) {
16525
        return byName.get(name);
16526
      }
16527
 
16528
      private final short _thriftId;
16529
      private final String _fieldName;
16530
 
16531
      _Fields(short thriftId, String fieldName) {
16532
        _thriftId = thriftId;
16533
        _fieldName = fieldName;
16534
      }
16535
 
16536
      public short getThriftFieldId() {
16537
        return _thriftId;
16538
      }
16539
 
16540
      public String getFieldName() {
16541
        return _fieldName;
16542
      }
16543
    }
16544
 
16545
    // isset id assignments
16546
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
16547
    private static final int __AMOUNT_ISSET_ID = 1;
16548
    private static final int __ISDIGITAL_ISSET_ID = 2;
16549
    private BitSet __isset_bit_vector = new BitSet(3);
16550
 
16551
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16552
    static {
16553
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16554
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16555
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
16556
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16557
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
16558
      tmpMap.put(_Fields.IS_DIGITAL, new org.apache.thrift.meta_data.FieldMetaData("isDigital", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16559
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
16560
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16561
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(refundPayment_args.class, metaDataMap);
16562
    }
16563
 
16564
    public refundPayment_args() {
16565
    }
16566
 
16567
    public refundPayment_args(
16568
      long merchantTxnId,
16569
      double amount,
16570
      boolean isDigital)
16571
    {
16572
      this();
16573
      this.merchantTxnId = merchantTxnId;
16574
      setMerchantTxnIdIsSet(true);
16575
      this.amount = amount;
16576
      setAmountIsSet(true);
16577
      this.isDigital = isDigital;
16578
      setIsDigitalIsSet(true);
16579
    }
16580
 
16581
    /**
16582
     * Performs a deep copy on <i>other</i>.
16583
     */
16584
    public refundPayment_args(refundPayment_args other) {
16585
      __isset_bit_vector.clear();
16586
      __isset_bit_vector.or(other.__isset_bit_vector);
16587
      this.merchantTxnId = other.merchantTxnId;
16588
      this.amount = other.amount;
16589
      this.isDigital = other.isDigital;
16590
    }
16591
 
16592
    public refundPayment_args deepCopy() {
16593
      return new refundPayment_args(this);
16594
    }
16595
 
16596
    @Override
16597
    public void clear() {
16598
      setMerchantTxnIdIsSet(false);
16599
      this.merchantTxnId = 0;
16600
      setAmountIsSet(false);
16601
      this.amount = 0.0;
16602
      setIsDigitalIsSet(false);
16603
      this.isDigital = false;
16604
    }
16605
 
16606
    public long getMerchantTxnId() {
16607
      return this.merchantTxnId;
16608
    }
16609
 
16610
    public void setMerchantTxnId(long merchantTxnId) {
16611
      this.merchantTxnId = merchantTxnId;
16612
      setMerchantTxnIdIsSet(true);
16613
    }
16614
 
16615
    public void unsetMerchantTxnId() {
16616
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
16617
    }
16618
 
16619
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
16620
    public boolean isSetMerchantTxnId() {
16621
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
16622
    }
16623
 
16624
    public void setMerchantTxnIdIsSet(boolean value) {
16625
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
16626
    }
16627
 
16628
    public double getAmount() {
16629
      return this.amount;
16630
    }
16631
 
16632
    public void setAmount(double amount) {
16633
      this.amount = amount;
16634
      setAmountIsSet(true);
16635
    }
16636
 
16637
    public void unsetAmount() {
16638
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
16639
    }
16640
 
16641
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
16642
    public boolean isSetAmount() {
16643
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
16644
    }
16645
 
16646
    public void setAmountIsSet(boolean value) {
16647
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
16648
    }
16649
 
16650
    public boolean isIsDigital() {
16651
      return this.isDigital;
16652
    }
16653
 
16654
    public void setIsDigital(boolean isDigital) {
16655
      this.isDigital = isDigital;
16656
      setIsDigitalIsSet(true);
16657
    }
16658
 
16659
    public void unsetIsDigital() {
16660
      __isset_bit_vector.clear(__ISDIGITAL_ISSET_ID);
16661
    }
16662
 
16663
    /** Returns true if field isDigital is set (has been assigned a value) and false otherwise */
16664
    public boolean isSetIsDigital() {
16665
      return __isset_bit_vector.get(__ISDIGITAL_ISSET_ID);
16666
    }
16667
 
16668
    public void setIsDigitalIsSet(boolean value) {
16669
      __isset_bit_vector.set(__ISDIGITAL_ISSET_ID, value);
16670
    }
16671
 
16672
    public void setFieldValue(_Fields field, Object value) {
16673
      switch (field) {
16674
      case MERCHANT_TXN_ID:
16675
        if (value == null) {
16676
          unsetMerchantTxnId();
16677
        } else {
16678
          setMerchantTxnId((Long)value);
16679
        }
16680
        break;
16681
 
16682
      case AMOUNT:
16683
        if (value == null) {
16684
          unsetAmount();
16685
        } else {
16686
          setAmount((Double)value);
16687
        }
16688
        break;
16689
 
16690
      case IS_DIGITAL:
16691
        if (value == null) {
16692
          unsetIsDigital();
16693
        } else {
16694
          setIsDigital((Boolean)value);
16695
        }
16696
        break;
16697
 
16698
      }
16699
    }
16700
 
16701
    public Object getFieldValue(_Fields field) {
16702
      switch (field) {
16703
      case MERCHANT_TXN_ID:
16704
        return Long.valueOf(getMerchantTxnId());
16705
 
16706
      case AMOUNT:
16707
        return Double.valueOf(getAmount());
16708
 
16709
      case IS_DIGITAL:
16710
        return Boolean.valueOf(isIsDigital());
16711
 
16712
      }
16713
      throw new IllegalStateException();
16714
    }
16715
 
16716
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16717
    public boolean isSet(_Fields field) {
16718
      if (field == null) {
16719
        throw new IllegalArgumentException();
16720
      }
16721
 
16722
      switch (field) {
16723
      case MERCHANT_TXN_ID:
16724
        return isSetMerchantTxnId();
16725
      case AMOUNT:
16726
        return isSetAmount();
16727
      case IS_DIGITAL:
16728
        return isSetIsDigital();
16729
      }
16730
      throw new IllegalStateException();
16731
    }
16732
 
16733
    @Override
16734
    public boolean equals(Object that) {
16735
      if (that == null)
16736
        return false;
16737
      if (that instanceof refundPayment_args)
16738
        return this.equals((refundPayment_args)that);
16739
      return false;
16740
    }
16741
 
16742
    public boolean equals(refundPayment_args that) {
16743
      if (that == null)
16744
        return false;
16745
 
16746
      boolean this_present_merchantTxnId = true;
16747
      boolean that_present_merchantTxnId = true;
16748
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
16749
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
16750
          return false;
16751
        if (this.merchantTxnId != that.merchantTxnId)
16752
          return false;
16753
      }
16754
 
16755
      boolean this_present_amount = true;
16756
      boolean that_present_amount = true;
16757
      if (this_present_amount || that_present_amount) {
16758
        if (!(this_present_amount && that_present_amount))
16759
          return false;
16760
        if (this.amount != that.amount)
16761
          return false;
16762
      }
16763
 
16764
      boolean this_present_isDigital = true;
16765
      boolean that_present_isDigital = true;
16766
      if (this_present_isDigital || that_present_isDigital) {
16767
        if (!(this_present_isDigital && that_present_isDigital))
16768
          return false;
16769
        if (this.isDigital != that.isDigital)
16770
          return false;
16771
      }
16772
 
16773
      return true;
16774
    }
16775
 
16776
    @Override
16777
    public int hashCode() {
16778
      return 0;
16779
    }
16780
 
16781
    public int compareTo(refundPayment_args other) {
16782
      if (!getClass().equals(other.getClass())) {
16783
        return getClass().getName().compareTo(other.getClass().getName());
16784
      }
16785
 
16786
      int lastComparison = 0;
16787
      refundPayment_args typedOther = (refundPayment_args)other;
16788
 
16789
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
16790
      if (lastComparison != 0) {
16791
        return lastComparison;
16792
      }
16793
      if (isSetMerchantTxnId()) {
16794
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
16795
        if (lastComparison != 0) {
16796
          return lastComparison;
16797
        }
16798
      }
16799
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
16800
      if (lastComparison != 0) {
16801
        return lastComparison;
16802
      }
16803
      if (isSetAmount()) {
16804
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
16805
        if (lastComparison != 0) {
16806
          return lastComparison;
16807
        }
16808
      }
16809
      lastComparison = Boolean.valueOf(isSetIsDigital()).compareTo(typedOther.isSetIsDigital());
16810
      if (lastComparison != 0) {
16811
        return lastComparison;
16812
      }
16813
      if (isSetIsDigital()) {
16814
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isDigital, typedOther.isDigital);
16815
        if (lastComparison != 0) {
16816
          return lastComparison;
16817
        }
16818
      }
16819
      return 0;
16820
    }
16821
 
16822
    public _Fields fieldForId(int fieldId) {
16823
      return _Fields.findByThriftId(fieldId);
16824
    }
16825
 
16826
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16827
      org.apache.thrift.protocol.TField field;
16828
      iprot.readStructBegin();
16829
      while (true)
16830
      {
16831
        field = iprot.readFieldBegin();
16832
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16833
          break;
16834
        }
16835
        switch (field.id) {
16836
          case 1: // MERCHANT_TXN_ID
16837
            if (field.type == org.apache.thrift.protocol.TType.I64) {
16838
              this.merchantTxnId = iprot.readI64();
16839
              setMerchantTxnIdIsSet(true);
16840
            } else { 
16841
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16842
            }
16843
            break;
16844
          case 2: // AMOUNT
16845
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
16846
              this.amount = iprot.readDouble();
16847
              setAmountIsSet(true);
16848
            } else { 
16849
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16850
            }
16851
            break;
16852
          case 3: // IS_DIGITAL
16853
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
16854
              this.isDigital = iprot.readBool();
16855
              setIsDigitalIsSet(true);
16856
            } else { 
16857
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16858
            }
16859
            break;
16860
          default:
16861
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16862
        }
16863
        iprot.readFieldEnd();
16864
      }
16865
      iprot.readStructEnd();
16866
      validate();
16867
    }
16868
 
16869
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16870
      validate();
16871
 
16872
      oprot.writeStructBegin(STRUCT_DESC);
16873
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
16874
      oprot.writeI64(this.merchantTxnId);
16875
      oprot.writeFieldEnd();
16876
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
16877
      oprot.writeDouble(this.amount);
16878
      oprot.writeFieldEnd();
16879
      oprot.writeFieldBegin(IS_DIGITAL_FIELD_DESC);
16880
      oprot.writeBool(this.isDigital);
16881
      oprot.writeFieldEnd();
16882
      oprot.writeFieldStop();
16883
      oprot.writeStructEnd();
16884
    }
16885
 
16886
    @Override
16887
    public String toString() {
16888
      StringBuilder sb = new StringBuilder("refundPayment_args(");
16889
      boolean first = true;
16890
 
16891
      sb.append("merchantTxnId:");
16892
      sb.append(this.merchantTxnId);
16893
      first = false;
16894
      if (!first) sb.append(", ");
16895
      sb.append("amount:");
16896
      sb.append(this.amount);
16897
      first = false;
16898
      if (!first) sb.append(", ");
16899
      sb.append("isDigital:");
16900
      sb.append(this.isDigital);
16901
      first = false;
16902
      sb.append(")");
16903
      return sb.toString();
16904
    }
16905
 
16906
    public void validate() throws org.apache.thrift.TException {
16907
      // check for required fields
16908
    }
16909
 
16910
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16911
      try {
16912
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16913
      } catch (org.apache.thrift.TException te) {
16914
        throw new java.io.IOException(te);
16915
      }
16916
    }
16917
 
16918
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16919
      try {
16920
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16921
      } catch (org.apache.thrift.TException te) {
16922
        throw new java.io.IOException(te);
16923
      }
16924
    }
16925
 
16926
  }
16927
 
16928
  public static class refundPayment_result implements org.apache.thrift.TBase<refundPayment_result, refundPayment_result._Fields>, java.io.Serializable, Cloneable   {
16929
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("refundPayment_result");
16930
 
16931
    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);
16932
    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);
16933
 
16934
    private boolean success; // required
16935
    private PaymentException pe; // required
16936
 
16937
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16938
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16939
      SUCCESS((short)0, "success"),
16940
      PE((short)1, "pe");
16941
 
16942
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16943
 
16944
      static {
16945
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16946
          byName.put(field.getFieldName(), field);
16947
        }
16948
      }
16949
 
16950
      /**
16951
       * Find the _Fields constant that matches fieldId, or null if its not found.
16952
       */
16953
      public static _Fields findByThriftId(int fieldId) {
16954
        switch(fieldId) {
16955
          case 0: // SUCCESS
16956
            return SUCCESS;
16957
          case 1: // PE
16958
            return PE;
16959
          default:
16960
            return null;
16961
        }
16962
      }
16963
 
16964
      /**
16965
       * Find the _Fields constant that matches fieldId, throwing an exception
16966
       * if it is not found.
16967
       */
16968
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16969
        _Fields fields = findByThriftId(fieldId);
16970
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16971
        return fields;
16972
      }
16973
 
16974
      /**
16975
       * Find the _Fields constant that matches name, or null if its not found.
16976
       */
16977
      public static _Fields findByName(String name) {
16978
        return byName.get(name);
16979
      }
16980
 
16981
      private final short _thriftId;
16982
      private final String _fieldName;
16983
 
16984
      _Fields(short thriftId, String fieldName) {
16985
        _thriftId = thriftId;
16986
        _fieldName = fieldName;
16987
      }
16988
 
16989
      public short getThriftFieldId() {
16990
        return _thriftId;
16991
      }
16992
 
16993
      public String getFieldName() {
16994
        return _fieldName;
16995
      }
16996
    }
16997
 
16998
    // isset id assignments
16999
    private static final int __SUCCESS_ISSET_ID = 0;
17000
    private BitSet __isset_bit_vector = new BitSet(1);
17001
 
17002
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17003
    static {
17004
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17005
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17006
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
17007
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17008
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
17009
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17010
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(refundPayment_result.class, metaDataMap);
17011
    }
17012
 
17013
    public refundPayment_result() {
17014
    }
17015
 
17016
    public refundPayment_result(
17017
      boolean success,
17018
      PaymentException pe)
17019
    {
17020
      this();
17021
      this.success = success;
17022
      setSuccessIsSet(true);
17023
      this.pe = pe;
17024
    }
17025
 
17026
    /**
17027
     * Performs a deep copy on <i>other</i>.
17028
     */
17029
    public refundPayment_result(refundPayment_result other) {
17030
      __isset_bit_vector.clear();
17031
      __isset_bit_vector.or(other.__isset_bit_vector);
17032
      this.success = other.success;
17033
      if (other.isSetPe()) {
17034
        this.pe = new PaymentException(other.pe);
17035
      }
17036
    }
17037
 
17038
    public refundPayment_result deepCopy() {
17039
      return new refundPayment_result(this);
17040
    }
17041
 
17042
    @Override
17043
    public void clear() {
17044
      setSuccessIsSet(false);
17045
      this.success = false;
17046
      this.pe = null;
17047
    }
17048
 
17049
    public boolean isSuccess() {
17050
      return this.success;
17051
    }
17052
 
17053
    public void setSuccess(boolean success) {
17054
      this.success = success;
17055
      setSuccessIsSet(true);
17056
    }
17057
 
17058
    public void unsetSuccess() {
17059
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
17060
    }
17061
 
17062
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17063
    public boolean isSetSuccess() {
17064
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
17065
    }
17066
 
17067
    public void setSuccessIsSet(boolean value) {
17068
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
17069
    }
17070
 
17071
    public PaymentException getPe() {
17072
      return this.pe;
17073
    }
17074
 
17075
    public void setPe(PaymentException pe) {
17076
      this.pe = pe;
17077
    }
17078
 
17079
    public void unsetPe() {
17080
      this.pe = null;
17081
    }
17082
 
17083
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
17084
    public boolean isSetPe() {
17085
      return this.pe != null;
17086
    }
17087
 
17088
    public void setPeIsSet(boolean value) {
17089
      if (!value) {
17090
        this.pe = null;
17091
      }
17092
    }
17093
 
17094
    public void setFieldValue(_Fields field, Object value) {
17095
      switch (field) {
17096
      case SUCCESS:
17097
        if (value == null) {
17098
          unsetSuccess();
17099
        } else {
17100
          setSuccess((Boolean)value);
17101
        }
17102
        break;
17103
 
17104
      case PE:
17105
        if (value == null) {
17106
          unsetPe();
17107
        } else {
17108
          setPe((PaymentException)value);
17109
        }
17110
        break;
17111
 
17112
      }
17113
    }
17114
 
17115
    public Object getFieldValue(_Fields field) {
17116
      switch (field) {
17117
      case SUCCESS:
17118
        return Boolean.valueOf(isSuccess());
17119
 
17120
      case PE:
17121
        return getPe();
17122
 
17123
      }
17124
      throw new IllegalStateException();
17125
    }
17126
 
17127
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17128
    public boolean isSet(_Fields field) {
17129
      if (field == null) {
17130
        throw new IllegalArgumentException();
17131
      }
17132
 
17133
      switch (field) {
17134
      case SUCCESS:
17135
        return isSetSuccess();
17136
      case PE:
17137
        return isSetPe();
17138
      }
17139
      throw new IllegalStateException();
17140
    }
17141
 
17142
    @Override
17143
    public boolean equals(Object that) {
17144
      if (that == null)
17145
        return false;
17146
      if (that instanceof refundPayment_result)
17147
        return this.equals((refundPayment_result)that);
17148
      return false;
17149
    }
17150
 
17151
    public boolean equals(refundPayment_result that) {
17152
      if (that == null)
17153
        return false;
17154
 
17155
      boolean this_present_success = true;
17156
      boolean that_present_success = true;
17157
      if (this_present_success || that_present_success) {
17158
        if (!(this_present_success && that_present_success))
17159
          return false;
17160
        if (this.success != that.success)
17161
          return false;
17162
      }
17163
 
17164
      boolean this_present_pe = true && this.isSetPe();
17165
      boolean that_present_pe = true && that.isSetPe();
17166
      if (this_present_pe || that_present_pe) {
17167
        if (!(this_present_pe && that_present_pe))
17168
          return false;
17169
        if (!this.pe.equals(that.pe))
17170
          return false;
17171
      }
17172
 
17173
      return true;
17174
    }
17175
 
17176
    @Override
17177
    public int hashCode() {
17178
      return 0;
17179
    }
17180
 
17181
    public int compareTo(refundPayment_result other) {
17182
      if (!getClass().equals(other.getClass())) {
17183
        return getClass().getName().compareTo(other.getClass().getName());
17184
      }
17185
 
17186
      int lastComparison = 0;
17187
      refundPayment_result typedOther = (refundPayment_result)other;
17188
 
17189
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17190
      if (lastComparison != 0) {
17191
        return lastComparison;
17192
      }
17193
      if (isSetSuccess()) {
17194
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17195
        if (lastComparison != 0) {
17196
          return lastComparison;
17197
        }
17198
      }
17199
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
17200
      if (lastComparison != 0) {
17201
        return lastComparison;
17202
      }
17203
      if (isSetPe()) {
17204
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
17205
        if (lastComparison != 0) {
17206
          return lastComparison;
17207
        }
17208
      }
17209
      return 0;
17210
    }
17211
 
17212
    public _Fields fieldForId(int fieldId) {
17213
      return _Fields.findByThriftId(fieldId);
17214
    }
17215
 
17216
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17217
      org.apache.thrift.protocol.TField field;
17218
      iprot.readStructBegin();
17219
      while (true)
17220
      {
17221
        field = iprot.readFieldBegin();
17222
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17223
          break;
17224
        }
17225
        switch (field.id) {
17226
          case 0: // SUCCESS
17227
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
17228
              this.success = iprot.readBool();
17229
              setSuccessIsSet(true);
17230
            } else { 
17231
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17232
            }
17233
            break;
17234
          case 1: // PE
17235
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
17236
              this.pe = new PaymentException();
17237
              this.pe.read(iprot);
17238
            } else { 
17239
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17240
            }
17241
            break;
17242
          default:
17243
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17244
        }
17245
        iprot.readFieldEnd();
17246
      }
17247
      iprot.readStructEnd();
17248
      validate();
17249
    }
17250
 
17251
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17252
      oprot.writeStructBegin(STRUCT_DESC);
17253
 
17254
      if (this.isSetSuccess()) {
17255
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17256
        oprot.writeBool(this.success);
17257
        oprot.writeFieldEnd();
17258
      } else if (this.isSetPe()) {
17259
        oprot.writeFieldBegin(PE_FIELD_DESC);
17260
        this.pe.write(oprot);
17261
        oprot.writeFieldEnd();
17262
      }
17263
      oprot.writeFieldStop();
17264
      oprot.writeStructEnd();
17265
    }
17266
 
17267
    @Override
17268
    public String toString() {
17269
      StringBuilder sb = new StringBuilder("refundPayment_result(");
17270
      boolean first = true;
17271
 
17272
      sb.append("success:");
17273
      sb.append(this.success);
17274
      first = false;
17275
      if (!first) sb.append(", ");
17276
      sb.append("pe:");
17277
      if (this.pe == null) {
17278
        sb.append("null");
17279
      } else {
17280
        sb.append(this.pe);
17281
      }
17282
      first = false;
17283
      sb.append(")");
17284
      return sb.toString();
17285
    }
17286
 
17287
    public void validate() throws org.apache.thrift.TException {
17288
      // check for required fields
17289
    }
17290
 
17291
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17292
      try {
17293
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17294
      } catch (org.apache.thrift.TException te) {
17295
        throw new java.io.IOException(te);
17296
      }
17297
    }
17298
 
17299
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17300
      try {
17301
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17302
      } catch (org.apache.thrift.TException te) {
17303
        throw new java.io.IOException(te);
17304
      }
17305
    }
17306
 
17307
  }
17308
 
3956 chandransh 17309
  public static class partiallyCapturePayment_args implements org.apache.thrift.TBase<partiallyCapturePayment_args, partiallyCapturePayment_args._Fields>, java.io.Serializable, Cloneable   {
17310
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("partiallyCapturePayment_args");
17311
 
17312
    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);
17313
    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);
17314
    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);
17315
    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);
17316
    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);
17317
 
17318
    private long merchantTxnId; // required
17319
    private double amount; // required
17320
    private String xferBy; // required
17321
    private String xferTxnId; // required
17322
    private long xferDate; // required
17323
 
17324
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17325
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17326
      MERCHANT_TXN_ID((short)1, "merchantTxnId"),
17327
      AMOUNT((short)2, "amount"),
17328
      XFER_BY((short)3, "xferBy"),
17329
      XFER_TXN_ID((short)4, "xferTxnId"),
17330
      XFER_DATE((short)5, "xferDate");
17331
 
17332
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17333
 
17334
      static {
17335
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17336
          byName.put(field.getFieldName(), field);
17337
        }
17338
      }
17339
 
17340
      /**
17341
       * Find the _Fields constant that matches fieldId, or null if its not found.
17342
       */
17343
      public static _Fields findByThriftId(int fieldId) {
17344
        switch(fieldId) {
17345
          case 1: // MERCHANT_TXN_ID
17346
            return MERCHANT_TXN_ID;
17347
          case 2: // AMOUNT
17348
            return AMOUNT;
17349
          case 3: // XFER_BY
17350
            return XFER_BY;
17351
          case 4: // XFER_TXN_ID
17352
            return XFER_TXN_ID;
17353
          case 5: // XFER_DATE
17354
            return XFER_DATE;
17355
          default:
17356
            return null;
17357
        }
17358
      }
17359
 
17360
      /**
17361
       * Find the _Fields constant that matches fieldId, throwing an exception
17362
       * if it is not found.
17363
       */
17364
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17365
        _Fields fields = findByThriftId(fieldId);
17366
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17367
        return fields;
17368
      }
17369
 
17370
      /**
17371
       * Find the _Fields constant that matches name, or null if its not found.
17372
       */
17373
      public static _Fields findByName(String name) {
17374
        return byName.get(name);
17375
      }
17376
 
17377
      private final short _thriftId;
17378
      private final String _fieldName;
17379
 
17380
      _Fields(short thriftId, String fieldName) {
17381
        _thriftId = thriftId;
17382
        _fieldName = fieldName;
17383
      }
17384
 
17385
      public short getThriftFieldId() {
17386
        return _thriftId;
17387
      }
17388
 
17389
      public String getFieldName() {
17390
        return _fieldName;
17391
      }
17392
    }
17393
 
17394
    // isset id assignments
17395
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
17396
    private static final int __AMOUNT_ISSET_ID = 1;
17397
    private static final int __XFERDATE_ISSET_ID = 2;
17398
    private BitSet __isset_bit_vector = new BitSet(3);
17399
 
17400
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17401
    static {
17402
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17403
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17404
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17405
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17406
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
17407
      tmpMap.put(_Fields.XFER_BY, new org.apache.thrift.meta_data.FieldMetaData("xferBy", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17408
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
17409
      tmpMap.put(_Fields.XFER_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("xferTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17410
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
17411
      tmpMap.put(_Fields.XFER_DATE, new org.apache.thrift.meta_data.FieldMetaData("xferDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17412
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17413
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17414
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(partiallyCapturePayment_args.class, metaDataMap);
17415
    }
17416
 
17417
    public partiallyCapturePayment_args() {
17418
    }
17419
 
17420
    public partiallyCapturePayment_args(
17421
      long merchantTxnId,
17422
      double amount,
17423
      String xferBy,
17424
      String xferTxnId,
17425
      long xferDate)
17426
    {
17427
      this();
17428
      this.merchantTxnId = merchantTxnId;
17429
      setMerchantTxnIdIsSet(true);
17430
      this.amount = amount;
17431
      setAmountIsSet(true);
17432
      this.xferBy = xferBy;
17433
      this.xferTxnId = xferTxnId;
17434
      this.xferDate = xferDate;
17435
      setXferDateIsSet(true);
17436
    }
17437
 
17438
    /**
17439
     * Performs a deep copy on <i>other</i>.
17440
     */
17441
    public partiallyCapturePayment_args(partiallyCapturePayment_args other) {
17442
      __isset_bit_vector.clear();
17443
      __isset_bit_vector.or(other.__isset_bit_vector);
17444
      this.merchantTxnId = other.merchantTxnId;
17445
      this.amount = other.amount;
17446
      if (other.isSetXferBy()) {
17447
        this.xferBy = other.xferBy;
17448
      }
17449
      if (other.isSetXferTxnId()) {
17450
        this.xferTxnId = other.xferTxnId;
17451
      }
17452
      this.xferDate = other.xferDate;
17453
    }
17454
 
17455
    public partiallyCapturePayment_args deepCopy() {
17456
      return new partiallyCapturePayment_args(this);
17457
    }
17458
 
17459
    @Override
17460
    public void clear() {
17461
      setMerchantTxnIdIsSet(false);
17462
      this.merchantTxnId = 0;
17463
      setAmountIsSet(false);
17464
      this.amount = 0.0;
17465
      this.xferBy = null;
17466
      this.xferTxnId = null;
17467
      setXferDateIsSet(false);
17468
      this.xferDate = 0;
17469
    }
17470
 
17471
    public long getMerchantTxnId() {
17472
      return this.merchantTxnId;
17473
    }
17474
 
17475
    public void setMerchantTxnId(long merchantTxnId) {
17476
      this.merchantTxnId = merchantTxnId;
17477
      setMerchantTxnIdIsSet(true);
17478
    }
17479
 
17480
    public void unsetMerchantTxnId() {
17481
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
17482
    }
17483
 
17484
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
17485
    public boolean isSetMerchantTxnId() {
17486
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
17487
    }
17488
 
17489
    public void setMerchantTxnIdIsSet(boolean value) {
17490
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
17491
    }
17492
 
17493
    public double getAmount() {
17494
      return this.amount;
17495
    }
17496
 
17497
    public void setAmount(double amount) {
17498
      this.amount = amount;
17499
      setAmountIsSet(true);
17500
    }
17501
 
17502
    public void unsetAmount() {
17503
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
17504
    }
17505
 
17506
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
17507
    public boolean isSetAmount() {
17508
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
17509
    }
17510
 
17511
    public void setAmountIsSet(boolean value) {
17512
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
17513
    }
17514
 
17515
    public String getXferBy() {
17516
      return this.xferBy;
17517
    }
17518
 
17519
    public void setXferBy(String xferBy) {
17520
      this.xferBy = xferBy;
17521
    }
17522
 
17523
    public void unsetXferBy() {
17524
      this.xferBy = null;
17525
    }
17526
 
17527
    /** Returns true if field xferBy is set (has been assigned a value) and false otherwise */
17528
    public boolean isSetXferBy() {
17529
      return this.xferBy != null;
17530
    }
17531
 
17532
    public void setXferByIsSet(boolean value) {
17533
      if (!value) {
17534
        this.xferBy = null;
17535
      }
17536
    }
17537
 
17538
    public String getXferTxnId() {
17539
      return this.xferTxnId;
17540
    }
17541
 
17542
    public void setXferTxnId(String xferTxnId) {
17543
      this.xferTxnId = xferTxnId;
17544
    }
17545
 
17546
    public void unsetXferTxnId() {
17547
      this.xferTxnId = null;
17548
    }
17549
 
17550
    /** Returns true if field xferTxnId is set (has been assigned a value) and false otherwise */
17551
    public boolean isSetXferTxnId() {
17552
      return this.xferTxnId != null;
17553
    }
17554
 
17555
    public void setXferTxnIdIsSet(boolean value) {
17556
      if (!value) {
17557
        this.xferTxnId = null;
17558
      }
17559
    }
17560
 
17561
    public long getXferDate() {
17562
      return this.xferDate;
17563
    }
17564
 
17565
    public void setXferDate(long xferDate) {
17566
      this.xferDate = xferDate;
17567
      setXferDateIsSet(true);
17568
    }
17569
 
17570
    public void unsetXferDate() {
17571
      __isset_bit_vector.clear(__XFERDATE_ISSET_ID);
17572
    }
17573
 
17574
    /** Returns true if field xferDate is set (has been assigned a value) and false otherwise */
17575
    public boolean isSetXferDate() {
17576
      return __isset_bit_vector.get(__XFERDATE_ISSET_ID);
17577
    }
17578
 
17579
    public void setXferDateIsSet(boolean value) {
17580
      __isset_bit_vector.set(__XFERDATE_ISSET_ID, value);
17581
    }
17582
 
17583
    public void setFieldValue(_Fields field, Object value) {
17584
      switch (field) {
17585
      case MERCHANT_TXN_ID:
17586
        if (value == null) {
17587
          unsetMerchantTxnId();
17588
        } else {
17589
          setMerchantTxnId((Long)value);
17590
        }
17591
        break;
17592
 
17593
      case AMOUNT:
17594
        if (value == null) {
17595
          unsetAmount();
17596
        } else {
17597
          setAmount((Double)value);
17598
        }
17599
        break;
17600
 
17601
      case XFER_BY:
17602
        if (value == null) {
17603
          unsetXferBy();
17604
        } else {
17605
          setXferBy((String)value);
17606
        }
17607
        break;
17608
 
17609
      case XFER_TXN_ID:
17610
        if (value == null) {
17611
          unsetXferTxnId();
17612
        } else {
17613
          setXferTxnId((String)value);
17614
        }
17615
        break;
17616
 
17617
      case XFER_DATE:
17618
        if (value == null) {
17619
          unsetXferDate();
17620
        } else {
17621
          setXferDate((Long)value);
17622
        }
17623
        break;
17624
 
17625
      }
17626
    }
17627
 
17628
    public Object getFieldValue(_Fields field) {
17629
      switch (field) {
17630
      case MERCHANT_TXN_ID:
17631
        return Long.valueOf(getMerchantTxnId());
17632
 
17633
      case AMOUNT:
17634
        return Double.valueOf(getAmount());
17635
 
17636
      case XFER_BY:
17637
        return getXferBy();
17638
 
17639
      case XFER_TXN_ID:
17640
        return getXferTxnId();
17641
 
17642
      case XFER_DATE:
17643
        return Long.valueOf(getXferDate());
17644
 
17645
      }
17646
      throw new IllegalStateException();
17647
    }
17648
 
17649
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17650
    public boolean isSet(_Fields field) {
17651
      if (field == null) {
17652
        throw new IllegalArgumentException();
17653
      }
17654
 
17655
      switch (field) {
17656
      case MERCHANT_TXN_ID:
17657
        return isSetMerchantTxnId();
17658
      case AMOUNT:
17659
        return isSetAmount();
17660
      case XFER_BY:
17661
        return isSetXferBy();
17662
      case XFER_TXN_ID:
17663
        return isSetXferTxnId();
17664
      case XFER_DATE:
17665
        return isSetXferDate();
17666
      }
17667
      throw new IllegalStateException();
17668
    }
17669
 
17670
    @Override
17671
    public boolean equals(Object that) {
17672
      if (that == null)
17673
        return false;
17674
      if (that instanceof partiallyCapturePayment_args)
17675
        return this.equals((partiallyCapturePayment_args)that);
17676
      return false;
17677
    }
17678
 
17679
    public boolean equals(partiallyCapturePayment_args that) {
17680
      if (that == null)
17681
        return false;
17682
 
17683
      boolean this_present_merchantTxnId = true;
17684
      boolean that_present_merchantTxnId = true;
17685
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
17686
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
17687
          return false;
17688
        if (this.merchantTxnId != that.merchantTxnId)
17689
          return false;
17690
      }
17691
 
17692
      boolean this_present_amount = true;
17693
      boolean that_present_amount = true;
17694
      if (this_present_amount || that_present_amount) {
17695
        if (!(this_present_amount && that_present_amount))
17696
          return false;
17697
        if (this.amount != that.amount)
17698
          return false;
17699
      }
17700
 
17701
      boolean this_present_xferBy = true && this.isSetXferBy();
17702
      boolean that_present_xferBy = true && that.isSetXferBy();
17703
      if (this_present_xferBy || that_present_xferBy) {
17704
        if (!(this_present_xferBy && that_present_xferBy))
17705
          return false;
17706
        if (!this.xferBy.equals(that.xferBy))
17707
          return false;
17708
      }
17709
 
17710
      boolean this_present_xferTxnId = true && this.isSetXferTxnId();
17711
      boolean that_present_xferTxnId = true && that.isSetXferTxnId();
17712
      if (this_present_xferTxnId || that_present_xferTxnId) {
17713
        if (!(this_present_xferTxnId && that_present_xferTxnId))
17714
          return false;
17715
        if (!this.xferTxnId.equals(that.xferTxnId))
17716
          return false;
17717
      }
17718
 
17719
      boolean this_present_xferDate = true;
17720
      boolean that_present_xferDate = true;
17721
      if (this_present_xferDate || that_present_xferDate) {
17722
        if (!(this_present_xferDate && that_present_xferDate))
17723
          return false;
17724
        if (this.xferDate != that.xferDate)
17725
          return false;
17726
      }
17727
 
17728
      return true;
17729
    }
17730
 
17731
    @Override
17732
    public int hashCode() {
17733
      return 0;
17734
    }
17735
 
17736
    public int compareTo(partiallyCapturePayment_args other) {
17737
      if (!getClass().equals(other.getClass())) {
17738
        return getClass().getName().compareTo(other.getClass().getName());
17739
      }
17740
 
17741
      int lastComparison = 0;
17742
      partiallyCapturePayment_args typedOther = (partiallyCapturePayment_args)other;
17743
 
17744
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
17745
      if (lastComparison != 0) {
17746
        return lastComparison;
17747
      }
17748
      if (isSetMerchantTxnId()) {
17749
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
17750
        if (lastComparison != 0) {
17751
          return lastComparison;
17752
        }
17753
      }
17754
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
17755
      if (lastComparison != 0) {
17756
        return lastComparison;
17757
      }
17758
      if (isSetAmount()) {
17759
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
17760
        if (lastComparison != 0) {
17761
          return lastComparison;
17762
        }
17763
      }
17764
      lastComparison = Boolean.valueOf(isSetXferBy()).compareTo(typedOther.isSetXferBy());
17765
      if (lastComparison != 0) {
17766
        return lastComparison;
17767
      }
17768
      if (isSetXferBy()) {
17769
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferBy, typedOther.xferBy);
17770
        if (lastComparison != 0) {
17771
          return lastComparison;
17772
        }
17773
      }
17774
      lastComparison = Boolean.valueOf(isSetXferTxnId()).compareTo(typedOther.isSetXferTxnId());
17775
      if (lastComparison != 0) {
17776
        return lastComparison;
17777
      }
17778
      if (isSetXferTxnId()) {
17779
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferTxnId, typedOther.xferTxnId);
17780
        if (lastComparison != 0) {
17781
          return lastComparison;
17782
        }
17783
      }
17784
      lastComparison = Boolean.valueOf(isSetXferDate()).compareTo(typedOther.isSetXferDate());
17785
      if (lastComparison != 0) {
17786
        return lastComparison;
17787
      }
17788
      if (isSetXferDate()) {
17789
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferDate, typedOther.xferDate);
17790
        if (lastComparison != 0) {
17791
          return lastComparison;
17792
        }
17793
      }
17794
      return 0;
17795
    }
17796
 
17797
    public _Fields fieldForId(int fieldId) {
17798
      return _Fields.findByThriftId(fieldId);
17799
    }
17800
 
17801
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17802
      org.apache.thrift.protocol.TField field;
17803
      iprot.readStructBegin();
17804
      while (true)
17805
      {
17806
        field = iprot.readFieldBegin();
17807
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17808
          break;
17809
        }
17810
        switch (field.id) {
17811
          case 1: // MERCHANT_TXN_ID
17812
            if (field.type == org.apache.thrift.protocol.TType.I64) {
17813
              this.merchantTxnId = iprot.readI64();
17814
              setMerchantTxnIdIsSet(true);
17815
            } else { 
17816
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17817
            }
17818
            break;
17819
          case 2: // AMOUNT
17820
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
17821
              this.amount = iprot.readDouble();
17822
              setAmountIsSet(true);
17823
            } else { 
17824
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17825
            }
17826
            break;
17827
          case 3: // XFER_BY
17828
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
17829
              this.xferBy = iprot.readString();
17830
            } else { 
17831
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17832
            }
17833
            break;
17834
          case 4: // XFER_TXN_ID
17835
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
17836
              this.xferTxnId = iprot.readString();
17837
            } else { 
17838
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17839
            }
17840
            break;
17841
          case 5: // XFER_DATE
17842
            if (field.type == org.apache.thrift.protocol.TType.I64) {
17843
              this.xferDate = iprot.readI64();
17844
              setXferDateIsSet(true);
17845
            } else { 
17846
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17847
            }
17848
            break;
17849
          default:
17850
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17851
        }
17852
        iprot.readFieldEnd();
17853
      }
17854
      iprot.readStructEnd();
17855
      validate();
17856
    }
17857
 
17858
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17859
      validate();
17860
 
17861
      oprot.writeStructBegin(STRUCT_DESC);
17862
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
17863
      oprot.writeI64(this.merchantTxnId);
17864
      oprot.writeFieldEnd();
17865
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
17866
      oprot.writeDouble(this.amount);
17867
      oprot.writeFieldEnd();
17868
      if (this.xferBy != null) {
17869
        oprot.writeFieldBegin(XFER_BY_FIELD_DESC);
17870
        oprot.writeString(this.xferBy);
17871
        oprot.writeFieldEnd();
17872
      }
17873
      if (this.xferTxnId != null) {
17874
        oprot.writeFieldBegin(XFER_TXN_ID_FIELD_DESC);
17875
        oprot.writeString(this.xferTxnId);
17876
        oprot.writeFieldEnd();
17877
      }
17878
      oprot.writeFieldBegin(XFER_DATE_FIELD_DESC);
17879
      oprot.writeI64(this.xferDate);
17880
      oprot.writeFieldEnd();
17881
      oprot.writeFieldStop();
17882
      oprot.writeStructEnd();
17883
    }
17884
 
17885
    @Override
17886
    public String toString() {
17887
      StringBuilder sb = new StringBuilder("partiallyCapturePayment_args(");
17888
      boolean first = true;
17889
 
17890
      sb.append("merchantTxnId:");
17891
      sb.append(this.merchantTxnId);
17892
      first = false;
17893
      if (!first) sb.append(", ");
17894
      sb.append("amount:");
17895
      sb.append(this.amount);
17896
      first = false;
17897
      if (!first) sb.append(", ");
17898
      sb.append("xferBy:");
17899
      if (this.xferBy == null) {
17900
        sb.append("null");
17901
      } else {
17902
        sb.append(this.xferBy);
17903
      }
17904
      first = false;
17905
      if (!first) sb.append(", ");
17906
      sb.append("xferTxnId:");
17907
      if (this.xferTxnId == null) {
17908
        sb.append("null");
17909
      } else {
17910
        sb.append(this.xferTxnId);
17911
      }
17912
      first = false;
17913
      if (!first) sb.append(", ");
17914
      sb.append("xferDate:");
17915
      sb.append(this.xferDate);
17916
      first = false;
17917
      sb.append(")");
17918
      return sb.toString();
17919
    }
17920
 
17921
    public void validate() throws org.apache.thrift.TException {
17922
      // check for required fields
17923
    }
17924
 
17925
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17926
      try {
17927
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17928
      } catch (org.apache.thrift.TException te) {
17929
        throw new java.io.IOException(te);
17930
      }
17931
    }
17932
 
17933
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17934
      try {
9506 amit.gupta 17935
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
17936
        __isset_bit_vector = new BitSet(1);
3956 chandransh 17937
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17938
      } catch (org.apache.thrift.TException te) {
17939
        throw new java.io.IOException(te);
17940
      }
17941
    }
17942
 
17943
  }
17944
 
17945
  public static class partiallyCapturePayment_result implements org.apache.thrift.TBase<partiallyCapturePayment_result, partiallyCapturePayment_result._Fields>, java.io.Serializable, Cloneable   {
17946
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("partiallyCapturePayment_result");
17947
 
17948
    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);
17949
    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);
17950
 
17951
    private boolean success; // required
17952
    private PaymentException pe; // required
17953
 
17954
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17955
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17956
      SUCCESS((short)0, "success"),
17957
      PE((short)1, "pe");
17958
 
17959
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17960
 
17961
      static {
17962
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17963
          byName.put(field.getFieldName(), field);
17964
        }
17965
      }
17966
 
17967
      /**
17968
       * Find the _Fields constant that matches fieldId, or null if its not found.
17969
       */
17970
      public static _Fields findByThriftId(int fieldId) {
17971
        switch(fieldId) {
17972
          case 0: // SUCCESS
17973
            return SUCCESS;
17974
          case 1: // PE
17975
            return PE;
17976
          default:
17977
            return null;
17978
        }
17979
      }
17980
 
17981
      /**
17982
       * Find the _Fields constant that matches fieldId, throwing an exception
17983
       * if it is not found.
17984
       */
17985
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17986
        _Fields fields = findByThriftId(fieldId);
17987
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17988
        return fields;
17989
      }
17990
 
17991
      /**
17992
       * Find the _Fields constant that matches name, or null if its not found.
17993
       */
17994
      public static _Fields findByName(String name) {
17995
        return byName.get(name);
17996
      }
17997
 
17998
      private final short _thriftId;
17999
      private final String _fieldName;
18000
 
18001
      _Fields(short thriftId, String fieldName) {
18002
        _thriftId = thriftId;
18003
        _fieldName = fieldName;
18004
      }
18005
 
18006
      public short getThriftFieldId() {
18007
        return _thriftId;
18008
      }
18009
 
18010
      public String getFieldName() {
18011
        return _fieldName;
18012
      }
18013
    }
18014
 
18015
    // isset id assignments
18016
    private static final int __SUCCESS_ISSET_ID = 0;
18017
    private BitSet __isset_bit_vector = new BitSet(1);
18018
 
18019
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18020
    static {
18021
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18022
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18023
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
18024
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18025
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
18026
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18027
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(partiallyCapturePayment_result.class, metaDataMap);
18028
    }
18029
 
18030
    public partiallyCapturePayment_result() {
18031
    }
18032
 
18033
    public partiallyCapturePayment_result(
18034
      boolean success,
18035
      PaymentException pe)
18036
    {
18037
      this();
18038
      this.success = success;
18039
      setSuccessIsSet(true);
18040
      this.pe = pe;
18041
    }
18042
 
18043
    /**
18044
     * Performs a deep copy on <i>other</i>.
18045
     */
18046
    public partiallyCapturePayment_result(partiallyCapturePayment_result other) {
18047
      __isset_bit_vector.clear();
18048
      __isset_bit_vector.or(other.__isset_bit_vector);
18049
      this.success = other.success;
18050
      if (other.isSetPe()) {
18051
        this.pe = new PaymentException(other.pe);
18052
      }
18053
    }
18054
 
18055
    public partiallyCapturePayment_result deepCopy() {
18056
      return new partiallyCapturePayment_result(this);
18057
    }
18058
 
18059
    @Override
18060
    public void clear() {
18061
      setSuccessIsSet(false);
18062
      this.success = false;
18063
      this.pe = null;
18064
    }
18065
 
18066
    public boolean isSuccess() {
18067
      return this.success;
18068
    }
18069
 
18070
    public void setSuccess(boolean success) {
18071
      this.success = success;
18072
      setSuccessIsSet(true);
18073
    }
18074
 
18075
    public void unsetSuccess() {
18076
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
18077
    }
18078
 
18079
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
18080
    public boolean isSetSuccess() {
18081
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
18082
    }
18083
 
18084
    public void setSuccessIsSet(boolean value) {
18085
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
18086
    }
18087
 
18088
    public PaymentException getPe() {
18089
      return this.pe;
18090
    }
18091
 
18092
    public void setPe(PaymentException pe) {
18093
      this.pe = pe;
18094
    }
18095
 
18096
    public void unsetPe() {
18097
      this.pe = null;
18098
    }
18099
 
18100
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
18101
    public boolean isSetPe() {
18102
      return this.pe != null;
18103
    }
18104
 
18105
    public void setPeIsSet(boolean value) {
18106
      if (!value) {
18107
        this.pe = null;
18108
      }
18109
    }
18110
 
18111
    public void setFieldValue(_Fields field, Object value) {
18112
      switch (field) {
18113
      case SUCCESS:
18114
        if (value == null) {
18115
          unsetSuccess();
18116
        } else {
18117
          setSuccess((Boolean)value);
18118
        }
18119
        break;
18120
 
18121
      case PE:
18122
        if (value == null) {
18123
          unsetPe();
18124
        } else {
18125
          setPe((PaymentException)value);
18126
        }
18127
        break;
18128
 
18129
      }
18130
    }
18131
 
18132
    public Object getFieldValue(_Fields field) {
18133
      switch (field) {
18134
      case SUCCESS:
18135
        return Boolean.valueOf(isSuccess());
18136
 
18137
      case PE:
18138
        return getPe();
18139
 
18140
      }
18141
      throw new IllegalStateException();
18142
    }
18143
 
18144
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18145
    public boolean isSet(_Fields field) {
18146
      if (field == null) {
18147
        throw new IllegalArgumentException();
18148
      }
18149
 
18150
      switch (field) {
18151
      case SUCCESS:
18152
        return isSetSuccess();
18153
      case PE:
18154
        return isSetPe();
18155
      }
18156
      throw new IllegalStateException();
18157
    }
18158
 
18159
    @Override
18160
    public boolean equals(Object that) {
18161
      if (that == null)
18162
        return false;
18163
      if (that instanceof partiallyCapturePayment_result)
18164
        return this.equals((partiallyCapturePayment_result)that);
18165
      return false;
18166
    }
18167
 
18168
    public boolean equals(partiallyCapturePayment_result that) {
18169
      if (that == null)
18170
        return false;
18171
 
18172
      boolean this_present_success = true;
18173
      boolean that_present_success = true;
18174
      if (this_present_success || that_present_success) {
18175
        if (!(this_present_success && that_present_success))
18176
          return false;
18177
        if (this.success != that.success)
18178
          return false;
18179
      }
18180
 
18181
      boolean this_present_pe = true && this.isSetPe();
18182
      boolean that_present_pe = true && that.isSetPe();
18183
      if (this_present_pe || that_present_pe) {
18184
        if (!(this_present_pe && that_present_pe))
18185
          return false;
18186
        if (!this.pe.equals(that.pe))
18187
          return false;
18188
      }
18189
 
18190
      return true;
18191
    }
18192
 
18193
    @Override
18194
    public int hashCode() {
18195
      return 0;
18196
    }
18197
 
18198
    public int compareTo(partiallyCapturePayment_result other) {
18199
      if (!getClass().equals(other.getClass())) {
18200
        return getClass().getName().compareTo(other.getClass().getName());
18201
      }
18202
 
18203
      int lastComparison = 0;
18204
      partiallyCapturePayment_result typedOther = (partiallyCapturePayment_result)other;
18205
 
18206
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
18207
      if (lastComparison != 0) {
18208
        return lastComparison;
18209
      }
18210
      if (isSetSuccess()) {
18211
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
18212
        if (lastComparison != 0) {
18213
          return lastComparison;
18214
        }
18215
      }
18216
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
18217
      if (lastComparison != 0) {
18218
        return lastComparison;
18219
      }
18220
      if (isSetPe()) {
18221
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
18222
        if (lastComparison != 0) {
18223
          return lastComparison;
18224
        }
18225
      }
18226
      return 0;
18227
    }
18228
 
18229
    public _Fields fieldForId(int fieldId) {
18230
      return _Fields.findByThriftId(fieldId);
18231
    }
18232
 
18233
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18234
      org.apache.thrift.protocol.TField field;
18235
      iprot.readStructBegin();
18236
      while (true)
18237
      {
18238
        field = iprot.readFieldBegin();
18239
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18240
          break;
18241
        }
18242
        switch (field.id) {
18243
          case 0: // SUCCESS
18244
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
18245
              this.success = iprot.readBool();
18246
              setSuccessIsSet(true);
18247
            } else { 
18248
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18249
            }
18250
            break;
18251
          case 1: // PE
18252
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18253
              this.pe = new PaymentException();
18254
              this.pe.read(iprot);
18255
            } else { 
18256
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18257
            }
18258
            break;
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
      if (this.isSetSuccess()) {
18272
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
18273
        oprot.writeBool(this.success);
18274
        oprot.writeFieldEnd();
18275
      } else if (this.isSetPe()) {
18276
        oprot.writeFieldBegin(PE_FIELD_DESC);
18277
        this.pe.write(oprot);
18278
        oprot.writeFieldEnd();
18279
      }
18280
      oprot.writeFieldStop();
18281
      oprot.writeStructEnd();
18282
    }
18283
 
18284
    @Override
18285
    public String toString() {
18286
      StringBuilder sb = new StringBuilder("partiallyCapturePayment_result(");
18287
      boolean first = true;
18288
 
18289
      sb.append("success:");
18290
      sb.append(this.success);
18291
      first = false;
18292
      if (!first) sb.append(", ");
18293
      sb.append("pe:");
18294
      if (this.pe == null) {
18295
        sb.append("null");
18296
      } else {
18297
        sb.append(this.pe);
18298
      }
18299
      first = false;
18300
      sb.append(")");
18301
      return sb.toString();
18302
    }
18303
 
18304
    public void validate() throws org.apache.thrift.TException {
18305
      // check for required fields
18306
    }
18307
 
18308
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18309
      try {
18310
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18311
      } catch (org.apache.thrift.TException te) {
18312
        throw new java.io.IOException(te);
18313
      }
18314
    }
18315
 
18316
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18317
      try {
18318
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18319
      } catch (org.apache.thrift.TException te) {
18320
        throw new java.io.IOException(te);
18321
      }
18322
    }
18323
 
18324
  }
18325
 
4008 mandeep.dh 18326
  public static class getPaymentsRequiringExtraProcessing_args implements org.apache.thrift.TBase<getPaymentsRequiringExtraProcessing_args, getPaymentsRequiringExtraProcessing_args._Fields>, java.io.Serializable, Cloneable   {
18327
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsRequiringExtraProcessing_args");
18328
 
18329
    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);
18330
 
18331
    private ExtraPaymentProcessingType category; // required
18332
 
18333
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18334
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18335
      /**
18336
       * 
18337
       * @see ExtraPaymentProcessingType
18338
       */
18339
      CATEGORY((short)1, "category");
18340
 
18341
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18342
 
18343
      static {
18344
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18345
          byName.put(field.getFieldName(), field);
18346
        }
18347
      }
18348
 
18349
      /**
18350
       * Find the _Fields constant that matches fieldId, or null if its not found.
18351
       */
18352
      public static _Fields findByThriftId(int fieldId) {
18353
        switch(fieldId) {
18354
          case 1: // CATEGORY
18355
            return CATEGORY;
18356
          default:
18357
            return null;
18358
        }
18359
      }
18360
 
18361
      /**
18362
       * Find the _Fields constant that matches fieldId, throwing an exception
18363
       * if it is not found.
18364
       */
18365
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18366
        _Fields fields = findByThriftId(fieldId);
18367
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18368
        return fields;
18369
      }
18370
 
18371
      /**
18372
       * Find the _Fields constant that matches name, or null if its not found.
18373
       */
18374
      public static _Fields findByName(String name) {
18375
        return byName.get(name);
18376
      }
18377
 
18378
      private final short _thriftId;
18379
      private final String _fieldName;
18380
 
18381
      _Fields(short thriftId, String fieldName) {
18382
        _thriftId = thriftId;
18383
        _fieldName = fieldName;
18384
      }
18385
 
18386
      public short getThriftFieldId() {
18387
        return _thriftId;
18388
      }
18389
 
18390
      public String getFieldName() {
18391
        return _fieldName;
18392
      }
18393
    }
18394
 
18395
    // isset id assignments
18396
 
18397
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18398
    static {
18399
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18400
      tmpMap.put(_Fields.CATEGORY, new org.apache.thrift.meta_data.FieldMetaData("category", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18401
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ExtraPaymentProcessingType.class)));
18402
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18403
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsRequiringExtraProcessing_args.class, metaDataMap);
18404
    }
18405
 
18406
    public getPaymentsRequiringExtraProcessing_args() {
18407
    }
18408
 
18409
    public getPaymentsRequiringExtraProcessing_args(
18410
      ExtraPaymentProcessingType category)
18411
    {
18412
      this();
18413
      this.category = category;
18414
    }
18415
 
18416
    /**
18417
     * Performs a deep copy on <i>other</i>.
18418
     */
18419
    public getPaymentsRequiringExtraProcessing_args(getPaymentsRequiringExtraProcessing_args other) {
18420
      if (other.isSetCategory()) {
18421
        this.category = other.category;
18422
      }
18423
    }
18424
 
18425
    public getPaymentsRequiringExtraProcessing_args deepCopy() {
18426
      return new getPaymentsRequiringExtraProcessing_args(this);
18427
    }
18428
 
18429
    @Override
18430
    public void clear() {
18431
      this.category = null;
18432
    }
18433
 
18434
    /**
18435
     * 
18436
     * @see ExtraPaymentProcessingType
18437
     */
18438
    public ExtraPaymentProcessingType getCategory() {
18439
      return this.category;
18440
    }
18441
 
18442
    /**
18443
     * 
18444
     * @see ExtraPaymentProcessingType
18445
     */
18446
    public void setCategory(ExtraPaymentProcessingType category) {
18447
      this.category = category;
18448
    }
18449
 
18450
    public void unsetCategory() {
18451
      this.category = null;
18452
    }
18453
 
18454
    /** Returns true if field category is set (has been assigned a value) and false otherwise */
18455
    public boolean isSetCategory() {
18456
      return this.category != null;
18457
    }
18458
 
18459
    public void setCategoryIsSet(boolean value) {
18460
      if (!value) {
18461
        this.category = null;
18462
      }
18463
    }
18464
 
18465
    public void setFieldValue(_Fields field, Object value) {
18466
      switch (field) {
18467
      case CATEGORY:
18468
        if (value == null) {
18469
          unsetCategory();
18470
        } else {
18471
          setCategory((ExtraPaymentProcessingType)value);
18472
        }
18473
        break;
18474
 
18475
      }
18476
    }
18477
 
18478
    public Object getFieldValue(_Fields field) {
18479
      switch (field) {
18480
      case CATEGORY:
18481
        return getCategory();
18482
 
18483
      }
18484
      throw new IllegalStateException();
18485
    }
18486
 
18487
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18488
    public boolean isSet(_Fields field) {
18489
      if (field == null) {
18490
        throw new IllegalArgumentException();
18491
      }
18492
 
18493
      switch (field) {
18494
      case CATEGORY:
18495
        return isSetCategory();
18496
      }
18497
      throw new IllegalStateException();
18498
    }
18499
 
18500
    @Override
18501
    public boolean equals(Object that) {
18502
      if (that == null)
18503
        return false;
18504
      if (that instanceof getPaymentsRequiringExtraProcessing_args)
18505
        return this.equals((getPaymentsRequiringExtraProcessing_args)that);
18506
      return false;
18507
    }
18508
 
18509
    public boolean equals(getPaymentsRequiringExtraProcessing_args that) {
18510
      if (that == null)
18511
        return false;
18512
 
18513
      boolean this_present_category = true && this.isSetCategory();
18514
      boolean that_present_category = true && that.isSetCategory();
18515
      if (this_present_category || that_present_category) {
18516
        if (!(this_present_category && that_present_category))
18517
          return false;
18518
        if (!this.category.equals(that.category))
18519
          return false;
18520
      }
18521
 
18522
      return true;
18523
    }
18524
 
18525
    @Override
18526
    public int hashCode() {
18527
      return 0;
18528
    }
18529
 
18530
    public int compareTo(getPaymentsRequiringExtraProcessing_args other) {
18531
      if (!getClass().equals(other.getClass())) {
18532
        return getClass().getName().compareTo(other.getClass().getName());
18533
      }
18534
 
18535
      int lastComparison = 0;
18536
      getPaymentsRequiringExtraProcessing_args typedOther = (getPaymentsRequiringExtraProcessing_args)other;
18537
 
18538
      lastComparison = Boolean.valueOf(isSetCategory()).compareTo(typedOther.isSetCategory());
18539
      if (lastComparison != 0) {
18540
        return lastComparison;
18541
      }
18542
      if (isSetCategory()) {
18543
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.category, typedOther.category);
18544
        if (lastComparison != 0) {
18545
          return lastComparison;
18546
        }
18547
      }
18548
      return 0;
18549
    }
18550
 
18551
    public _Fields fieldForId(int fieldId) {
18552
      return _Fields.findByThriftId(fieldId);
18553
    }
18554
 
18555
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18556
      org.apache.thrift.protocol.TField field;
18557
      iprot.readStructBegin();
18558
      while (true)
18559
      {
18560
        field = iprot.readFieldBegin();
18561
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18562
          break;
18563
        }
18564
        switch (field.id) {
18565
          case 1: // CATEGORY
18566
            if (field.type == org.apache.thrift.protocol.TType.I32) {
18567
              this.category = ExtraPaymentProcessingType.findByValue(iprot.readI32());
18568
            } else { 
18569
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18570
            }
18571
            break;
18572
          default:
18573
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18574
        }
18575
        iprot.readFieldEnd();
18576
      }
18577
      iprot.readStructEnd();
18578
      validate();
18579
    }
18580
 
18581
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18582
      validate();
18583
 
18584
      oprot.writeStructBegin(STRUCT_DESC);
18585
      if (this.category != null) {
18586
        oprot.writeFieldBegin(CATEGORY_FIELD_DESC);
18587
        oprot.writeI32(this.category.getValue());
18588
        oprot.writeFieldEnd();
18589
      }
18590
      oprot.writeFieldStop();
18591
      oprot.writeStructEnd();
18592
    }
18593
 
18594
    @Override
18595
    public String toString() {
18596
      StringBuilder sb = new StringBuilder("getPaymentsRequiringExtraProcessing_args(");
18597
      boolean first = true;
18598
 
18599
      sb.append("category:");
18600
      if (this.category == null) {
18601
        sb.append("null");
18602
      } else {
18603
        sb.append(this.category);
18604
      }
18605
      first = false;
18606
      sb.append(")");
18607
      return sb.toString();
18608
    }
18609
 
18610
    public void validate() throws org.apache.thrift.TException {
18611
      // check for required fields
18612
    }
18613
 
18614
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18615
      try {
18616
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18617
      } catch (org.apache.thrift.TException te) {
18618
        throw new java.io.IOException(te);
18619
      }
18620
    }
18621
 
18622
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18623
      try {
18624
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18625
      } catch (org.apache.thrift.TException te) {
18626
        throw new java.io.IOException(te);
18627
      }
18628
    }
18629
 
18630
  }
18631
 
18632
  public static class getPaymentsRequiringExtraProcessing_result implements org.apache.thrift.TBase<getPaymentsRequiringExtraProcessing_result, getPaymentsRequiringExtraProcessing_result._Fields>, java.io.Serializable, Cloneable   {
18633
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsRequiringExtraProcessing_result");
18634
 
18635
    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);
18636
 
18637
    private List<Long> success; // required
18638
 
18639
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18640
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18641
      SUCCESS((short)0, "success");
18642
 
18643
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18644
 
18645
      static {
18646
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18647
          byName.put(field.getFieldName(), field);
18648
        }
18649
      }
18650
 
18651
      /**
18652
       * Find the _Fields constant that matches fieldId, or null if its not found.
18653
       */
18654
      public static _Fields findByThriftId(int fieldId) {
18655
        switch(fieldId) {
18656
          case 0: // SUCCESS
18657
            return SUCCESS;
18658
          default:
18659
            return null;
18660
        }
18661
      }
18662
 
18663
      /**
18664
       * Find the _Fields constant that matches fieldId, throwing an exception
18665
       * if it is not found.
18666
       */
18667
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18668
        _Fields fields = findByThriftId(fieldId);
18669
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18670
        return fields;
18671
      }
18672
 
18673
      /**
18674
       * Find the _Fields constant that matches name, or null if its not found.
18675
       */
18676
      public static _Fields findByName(String name) {
18677
        return byName.get(name);
18678
      }
18679
 
18680
      private final short _thriftId;
18681
      private final String _fieldName;
18682
 
18683
      _Fields(short thriftId, String fieldName) {
18684
        _thriftId = thriftId;
18685
        _fieldName = fieldName;
18686
      }
18687
 
18688
      public short getThriftFieldId() {
18689
        return _thriftId;
18690
      }
18691
 
18692
      public String getFieldName() {
18693
        return _fieldName;
18694
      }
18695
    }
18696
 
18697
    // isset id assignments
18698
 
18699
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18700
    static {
18701
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18702
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18703
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
18704
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
18705
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18706
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsRequiringExtraProcessing_result.class, metaDataMap);
18707
    }
18708
 
18709
    public getPaymentsRequiringExtraProcessing_result() {
18710
    }
18711
 
18712
    public getPaymentsRequiringExtraProcessing_result(
18713
      List<Long> success)
18714
    {
18715
      this();
18716
      this.success = success;
18717
    }
18718
 
18719
    /**
18720
     * Performs a deep copy on <i>other</i>.
18721
     */
18722
    public getPaymentsRequiringExtraProcessing_result(getPaymentsRequiringExtraProcessing_result other) {
18723
      if (other.isSetSuccess()) {
18724
        List<Long> __this__success = new ArrayList<Long>();
18725
        for (Long other_element : other.success) {
18726
          __this__success.add(other_element);
18727
        }
18728
        this.success = __this__success;
18729
      }
18730
    }
18731
 
18732
    public getPaymentsRequiringExtraProcessing_result deepCopy() {
18733
      return new getPaymentsRequiringExtraProcessing_result(this);
18734
    }
18735
 
18736
    @Override
18737
    public void clear() {
18738
      this.success = null;
18739
    }
18740
 
18741
    public int getSuccessSize() {
18742
      return (this.success == null) ? 0 : this.success.size();
18743
    }
18744
 
18745
    public java.util.Iterator<Long> getSuccessIterator() {
18746
      return (this.success == null) ? null : this.success.iterator();
18747
    }
18748
 
18749
    public void addToSuccess(long elem) {
18750
      if (this.success == null) {
18751
        this.success = new ArrayList<Long>();
18752
      }
18753
      this.success.add(elem);
18754
    }
18755
 
18756
    public List<Long> getSuccess() {
18757
      return this.success;
18758
    }
18759
 
18760
    public void setSuccess(List<Long> success) {
18761
      this.success = success;
18762
    }
18763
 
18764
    public void unsetSuccess() {
18765
      this.success = null;
18766
    }
18767
 
18768
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
18769
    public boolean isSetSuccess() {
18770
      return this.success != null;
18771
    }
18772
 
18773
    public void setSuccessIsSet(boolean value) {
18774
      if (!value) {
18775
        this.success = null;
18776
      }
18777
    }
18778
 
18779
    public void setFieldValue(_Fields field, Object value) {
18780
      switch (field) {
18781
      case SUCCESS:
18782
        if (value == null) {
18783
          unsetSuccess();
18784
        } else {
18785
          setSuccess((List<Long>)value);
18786
        }
18787
        break;
18788
 
18789
      }
18790
    }
18791
 
18792
    public Object getFieldValue(_Fields field) {
18793
      switch (field) {
18794
      case SUCCESS:
18795
        return getSuccess();
18796
 
18797
      }
18798
      throw new IllegalStateException();
18799
    }
18800
 
18801
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18802
    public boolean isSet(_Fields field) {
18803
      if (field == null) {
18804
        throw new IllegalArgumentException();
18805
      }
18806
 
18807
      switch (field) {
18808
      case SUCCESS:
18809
        return isSetSuccess();
18810
      }
18811
      throw new IllegalStateException();
18812
    }
18813
 
18814
    @Override
18815
    public boolean equals(Object that) {
18816
      if (that == null)
18817
        return false;
18818
      if (that instanceof getPaymentsRequiringExtraProcessing_result)
18819
        return this.equals((getPaymentsRequiringExtraProcessing_result)that);
18820
      return false;
18821
    }
18822
 
18823
    public boolean equals(getPaymentsRequiringExtraProcessing_result that) {
18824
      if (that == null)
18825
        return false;
18826
 
18827
      boolean this_present_success = true && this.isSetSuccess();
18828
      boolean that_present_success = true && that.isSetSuccess();
18829
      if (this_present_success || that_present_success) {
18830
        if (!(this_present_success && that_present_success))
18831
          return false;
18832
        if (!this.success.equals(that.success))
18833
          return false;
18834
      }
18835
 
18836
      return true;
18837
    }
18838
 
18839
    @Override
18840
    public int hashCode() {
18841
      return 0;
18842
    }
18843
 
18844
    public int compareTo(getPaymentsRequiringExtraProcessing_result other) {
18845
      if (!getClass().equals(other.getClass())) {
18846
        return getClass().getName().compareTo(other.getClass().getName());
18847
      }
18848
 
18849
      int lastComparison = 0;
18850
      getPaymentsRequiringExtraProcessing_result typedOther = (getPaymentsRequiringExtraProcessing_result)other;
18851
 
18852
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
18853
      if (lastComparison != 0) {
18854
        return lastComparison;
18855
      }
18856
      if (isSetSuccess()) {
18857
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
18858
        if (lastComparison != 0) {
18859
          return lastComparison;
18860
        }
18861
      }
18862
      return 0;
18863
    }
18864
 
18865
    public _Fields fieldForId(int fieldId) {
18866
      return _Fields.findByThriftId(fieldId);
18867
    }
18868
 
18869
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18870
      org.apache.thrift.protocol.TField field;
18871
      iprot.readStructBegin();
18872
      while (true)
18873
      {
18874
        field = iprot.readFieldBegin();
18875
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18876
          break;
18877
        }
18878
        switch (field.id) {
18879
          case 0: // SUCCESS
18880
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
18881
              {
7049 anupam.sin 18882
                org.apache.thrift.protocol.TList _list44 = iprot.readListBegin();
18883
                this.success = new ArrayList<Long>(_list44.size);
18884
                for (int _i45 = 0; _i45 < _list44.size; ++_i45)
4008 mandeep.dh 18885
                {
7049 anupam.sin 18886
                  long _elem46; // required
18887
                  _elem46 = iprot.readI64();
18888
                  this.success.add(_elem46);
4008 mandeep.dh 18889
                }
18890
                iprot.readListEnd();
18891
              }
18892
            } else { 
18893
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18894
            }
18895
            break;
18896
          default:
18897
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18898
        }
18899
        iprot.readFieldEnd();
18900
      }
18901
      iprot.readStructEnd();
18902
      validate();
18903
    }
18904
 
18905
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18906
      oprot.writeStructBegin(STRUCT_DESC);
18907
 
18908
      if (this.isSetSuccess()) {
18909
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
18910
        {
18911
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
7049 anupam.sin 18912
          for (long _iter47 : this.success)
4008 mandeep.dh 18913
          {
7049 anupam.sin 18914
            oprot.writeI64(_iter47);
4008 mandeep.dh 18915
          }
18916
          oprot.writeListEnd();
18917
        }
18918
        oprot.writeFieldEnd();
18919
      }
18920
      oprot.writeFieldStop();
18921
      oprot.writeStructEnd();
18922
    }
18923
 
18924
    @Override
18925
    public String toString() {
18926
      StringBuilder sb = new StringBuilder("getPaymentsRequiringExtraProcessing_result(");
18927
      boolean first = true;
18928
 
18929
      sb.append("success:");
18930
      if (this.success == null) {
18931
        sb.append("null");
18932
      } else {
18933
        sb.append(this.success);
18934
      }
18935
      first = false;
18936
      sb.append(")");
18937
      return sb.toString();
18938
    }
18939
 
18940
    public void validate() throws org.apache.thrift.TException {
18941
      // check for required fields
18942
    }
18943
 
18944
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18945
      try {
18946
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18947
      } catch (org.apache.thrift.TException te) {
18948
        throw new java.io.IOException(te);
18949
      }
18950
    }
18951
 
18952
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18953
      try {
18954
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18955
      } catch (org.apache.thrift.TException te) {
18956
        throw new java.io.IOException(te);
18957
      }
18958
    }
18959
 
18960
  }
18961
 
18962
  public static class markPaymentAsProcessed_args implements org.apache.thrift.TBase<markPaymentAsProcessed_args, markPaymentAsProcessed_args._Fields>, java.io.Serializable, Cloneable   {
18963
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markPaymentAsProcessed_args");
18964
 
18965
    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);
18966
    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);
18967
 
18968
    private long paymentId; // required
18969
    private ExtraPaymentProcessingType category; // required
18970
 
18971
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18972
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18973
      PAYMENT_ID((short)1, "paymentId"),
18974
      /**
18975
       * 
18976
       * @see ExtraPaymentProcessingType
18977
       */
18978
      CATEGORY((short)2, "category");
18979
 
18980
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18981
 
18982
      static {
18983
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18984
          byName.put(field.getFieldName(), field);
18985
        }
18986
      }
18987
 
18988
      /**
18989
       * Find the _Fields constant that matches fieldId, or null if its not found.
18990
       */
18991
      public static _Fields findByThriftId(int fieldId) {
18992
        switch(fieldId) {
18993
          case 1: // PAYMENT_ID
18994
            return PAYMENT_ID;
18995
          case 2: // CATEGORY
18996
            return CATEGORY;
18997
          default:
18998
            return null;
18999
        }
19000
      }
19001
 
19002
      /**
19003
       * Find the _Fields constant that matches fieldId, throwing an exception
19004
       * if it is not found.
19005
       */
19006
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19007
        _Fields fields = findByThriftId(fieldId);
19008
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19009
        return fields;
19010
      }
19011
 
19012
      /**
19013
       * Find the _Fields constant that matches name, or null if its not found.
19014
       */
19015
      public static _Fields findByName(String name) {
19016
        return byName.get(name);
19017
      }
19018
 
19019
      private final short _thriftId;
19020
      private final String _fieldName;
19021
 
19022
      _Fields(short thriftId, String fieldName) {
19023
        _thriftId = thriftId;
19024
        _fieldName = fieldName;
19025
      }
19026
 
19027
      public short getThriftFieldId() {
19028
        return _thriftId;
19029
      }
19030
 
19031
      public String getFieldName() {
19032
        return _fieldName;
19033
      }
19034
    }
19035
 
19036
    // isset id assignments
19037
    private static final int __PAYMENTID_ISSET_ID = 0;
19038
    private BitSet __isset_bit_vector = new BitSet(1);
19039
 
19040
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19041
    static {
19042
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19043
      tmpMap.put(_Fields.PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("paymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19044
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19045
      tmpMap.put(_Fields.CATEGORY, new org.apache.thrift.meta_data.FieldMetaData("category", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19046
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ExtraPaymentProcessingType.class)));
19047
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19048
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markPaymentAsProcessed_args.class, metaDataMap);
19049
    }
19050
 
19051
    public markPaymentAsProcessed_args() {
19052
    }
19053
 
19054
    public markPaymentAsProcessed_args(
19055
      long paymentId,
19056
      ExtraPaymentProcessingType category)
19057
    {
19058
      this();
19059
      this.paymentId = paymentId;
19060
      setPaymentIdIsSet(true);
19061
      this.category = category;
19062
    }
19063
 
19064
    /**
19065
     * Performs a deep copy on <i>other</i>.
19066
     */
19067
    public markPaymentAsProcessed_args(markPaymentAsProcessed_args other) {
19068
      __isset_bit_vector.clear();
19069
      __isset_bit_vector.or(other.__isset_bit_vector);
19070
      this.paymentId = other.paymentId;
19071
      if (other.isSetCategory()) {
19072
        this.category = other.category;
19073
      }
19074
    }
19075
 
19076
    public markPaymentAsProcessed_args deepCopy() {
19077
      return new markPaymentAsProcessed_args(this);
19078
    }
19079
 
19080
    @Override
19081
    public void clear() {
19082
      setPaymentIdIsSet(false);
19083
      this.paymentId = 0;
19084
      this.category = null;
19085
    }
19086
 
19087
    public long getPaymentId() {
19088
      return this.paymentId;
19089
    }
19090
 
19091
    public void setPaymentId(long paymentId) {
19092
      this.paymentId = paymentId;
19093
      setPaymentIdIsSet(true);
19094
    }
19095
 
19096
    public void unsetPaymentId() {
19097
      __isset_bit_vector.clear(__PAYMENTID_ISSET_ID);
19098
    }
19099
 
19100
    /** Returns true if field paymentId is set (has been assigned a value) and false otherwise */
19101
    public boolean isSetPaymentId() {
19102
      return __isset_bit_vector.get(__PAYMENTID_ISSET_ID);
19103
    }
19104
 
19105
    public void setPaymentIdIsSet(boolean value) {
19106
      __isset_bit_vector.set(__PAYMENTID_ISSET_ID, value);
19107
    }
19108
 
19109
    /**
19110
     * 
19111
     * @see ExtraPaymentProcessingType
19112
     */
19113
    public ExtraPaymentProcessingType getCategory() {
19114
      return this.category;
19115
    }
19116
 
19117
    /**
19118
     * 
19119
     * @see ExtraPaymentProcessingType
19120
     */
19121
    public void setCategory(ExtraPaymentProcessingType category) {
19122
      this.category = category;
19123
    }
19124
 
19125
    public void unsetCategory() {
19126
      this.category = null;
19127
    }
19128
 
19129
    /** Returns true if field category is set (has been assigned a value) and false otherwise */
19130
    public boolean isSetCategory() {
19131
      return this.category != null;
19132
    }
19133
 
19134
    public void setCategoryIsSet(boolean value) {
19135
      if (!value) {
19136
        this.category = null;
19137
      }
19138
    }
19139
 
19140
    public void setFieldValue(_Fields field, Object value) {
19141
      switch (field) {
19142
      case PAYMENT_ID:
19143
        if (value == null) {
19144
          unsetPaymentId();
19145
        } else {
19146
          setPaymentId((Long)value);
19147
        }
19148
        break;
19149
 
19150
      case CATEGORY:
19151
        if (value == null) {
19152
          unsetCategory();
19153
        } else {
19154
          setCategory((ExtraPaymentProcessingType)value);
19155
        }
19156
        break;
19157
 
19158
      }
19159
    }
19160
 
19161
    public Object getFieldValue(_Fields field) {
19162
      switch (field) {
19163
      case PAYMENT_ID:
19164
        return Long.valueOf(getPaymentId());
19165
 
19166
      case CATEGORY:
19167
        return getCategory();
19168
 
19169
      }
19170
      throw new IllegalStateException();
19171
    }
19172
 
19173
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19174
    public boolean isSet(_Fields field) {
19175
      if (field == null) {
19176
        throw new IllegalArgumentException();
19177
      }
19178
 
19179
      switch (field) {
19180
      case PAYMENT_ID:
19181
        return isSetPaymentId();
19182
      case CATEGORY:
19183
        return isSetCategory();
19184
      }
19185
      throw new IllegalStateException();
19186
    }
19187
 
19188
    @Override
19189
    public boolean equals(Object that) {
19190
      if (that == null)
19191
        return false;
19192
      if (that instanceof markPaymentAsProcessed_args)
19193
        return this.equals((markPaymentAsProcessed_args)that);
19194
      return false;
19195
    }
19196
 
19197
    public boolean equals(markPaymentAsProcessed_args that) {
19198
      if (that == null)
19199
        return false;
19200
 
19201
      boolean this_present_paymentId = true;
19202
      boolean that_present_paymentId = true;
19203
      if (this_present_paymentId || that_present_paymentId) {
19204
        if (!(this_present_paymentId && that_present_paymentId))
19205
          return false;
19206
        if (this.paymentId != that.paymentId)
19207
          return false;
19208
      }
19209
 
19210
      boolean this_present_category = true && this.isSetCategory();
19211
      boolean that_present_category = true && that.isSetCategory();
19212
      if (this_present_category || that_present_category) {
19213
        if (!(this_present_category && that_present_category))
19214
          return false;
19215
        if (!this.category.equals(that.category))
19216
          return false;
19217
      }
19218
 
19219
      return true;
19220
    }
19221
 
19222
    @Override
19223
    public int hashCode() {
19224
      return 0;
19225
    }
19226
 
19227
    public int compareTo(markPaymentAsProcessed_args other) {
19228
      if (!getClass().equals(other.getClass())) {
19229
        return getClass().getName().compareTo(other.getClass().getName());
19230
      }
19231
 
19232
      int lastComparison = 0;
19233
      markPaymentAsProcessed_args typedOther = (markPaymentAsProcessed_args)other;
19234
 
19235
      lastComparison = Boolean.valueOf(isSetPaymentId()).compareTo(typedOther.isSetPaymentId());
19236
      if (lastComparison != 0) {
19237
        return lastComparison;
19238
      }
19239
      if (isSetPaymentId()) {
19240
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.paymentId, typedOther.paymentId);
19241
        if (lastComparison != 0) {
19242
          return lastComparison;
19243
        }
19244
      }
19245
      lastComparison = Boolean.valueOf(isSetCategory()).compareTo(typedOther.isSetCategory());
19246
      if (lastComparison != 0) {
19247
        return lastComparison;
19248
      }
19249
      if (isSetCategory()) {
19250
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.category, typedOther.category);
19251
        if (lastComparison != 0) {
19252
          return lastComparison;
19253
        }
19254
      }
19255
      return 0;
19256
    }
19257
 
19258
    public _Fields fieldForId(int fieldId) {
19259
      return _Fields.findByThriftId(fieldId);
19260
    }
19261
 
19262
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19263
      org.apache.thrift.protocol.TField field;
19264
      iprot.readStructBegin();
19265
      while (true)
19266
      {
19267
        field = iprot.readFieldBegin();
19268
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19269
          break;
19270
        }
19271
        switch (field.id) {
19272
          case 1: // PAYMENT_ID
19273
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19274
              this.paymentId = iprot.readI64();
19275
              setPaymentIdIsSet(true);
19276
            } else { 
19277
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19278
            }
19279
            break;
19280
          case 2: // CATEGORY
19281
            if (field.type == org.apache.thrift.protocol.TType.I32) {
19282
              this.category = ExtraPaymentProcessingType.findByValue(iprot.readI32());
19283
            } else { 
19284
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19285
            }
19286
            break;
19287
          default:
19288
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19289
        }
19290
        iprot.readFieldEnd();
19291
      }
19292
      iprot.readStructEnd();
19293
      validate();
19294
    }
19295
 
19296
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19297
      validate();
19298
 
19299
      oprot.writeStructBegin(STRUCT_DESC);
19300
      oprot.writeFieldBegin(PAYMENT_ID_FIELD_DESC);
19301
      oprot.writeI64(this.paymentId);
19302
      oprot.writeFieldEnd();
19303
      if (this.category != null) {
19304
        oprot.writeFieldBegin(CATEGORY_FIELD_DESC);
19305
        oprot.writeI32(this.category.getValue());
19306
        oprot.writeFieldEnd();
19307
      }
19308
      oprot.writeFieldStop();
19309
      oprot.writeStructEnd();
19310
    }
19311
 
19312
    @Override
19313
    public String toString() {
19314
      StringBuilder sb = new StringBuilder("markPaymentAsProcessed_args(");
19315
      boolean first = true;
19316
 
19317
      sb.append("paymentId:");
19318
      sb.append(this.paymentId);
19319
      first = false;
19320
      if (!first) sb.append(", ");
19321
      sb.append("category:");
19322
      if (this.category == null) {
19323
        sb.append("null");
19324
      } else {
19325
        sb.append(this.category);
19326
      }
19327
      first = false;
19328
      sb.append(")");
19329
      return sb.toString();
19330
    }
19331
 
19332
    public void validate() throws org.apache.thrift.TException {
19333
      // check for required fields
19334
    }
19335
 
19336
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19337
      try {
19338
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19339
      } catch (org.apache.thrift.TException te) {
19340
        throw new java.io.IOException(te);
19341
      }
19342
    }
19343
 
19344
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19345
      try {
19346
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19347
      } catch (org.apache.thrift.TException te) {
19348
        throw new java.io.IOException(te);
19349
      }
19350
    }
19351
 
19352
  }
19353
 
19354
  public static class markPaymentAsProcessed_result implements org.apache.thrift.TBase<markPaymentAsProcessed_result, markPaymentAsProcessed_result._Fields>, java.io.Serializable, Cloneable   {
19355
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markPaymentAsProcessed_result");
19356
 
19357
 
19358
 
19359
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19360
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19361
;
19362
 
19363
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19364
 
19365
      static {
19366
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19367
          byName.put(field.getFieldName(), field);
19368
        }
19369
      }
19370
 
19371
      /**
19372
       * Find the _Fields constant that matches fieldId, or null if its not found.
19373
       */
19374
      public static _Fields findByThriftId(int fieldId) {
19375
        switch(fieldId) {
19376
          default:
19377
            return null;
19378
        }
19379
      }
19380
 
19381
      /**
19382
       * Find the _Fields constant that matches fieldId, throwing an exception
19383
       * if it is not found.
19384
       */
19385
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19386
        _Fields fields = findByThriftId(fieldId);
19387
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19388
        return fields;
19389
      }
19390
 
19391
      /**
19392
       * Find the _Fields constant that matches name, or null if its not found.
19393
       */
19394
      public static _Fields findByName(String name) {
19395
        return byName.get(name);
19396
      }
19397
 
19398
      private final short _thriftId;
19399
      private final String _fieldName;
19400
 
19401
      _Fields(short thriftId, String fieldName) {
19402
        _thriftId = thriftId;
19403
        _fieldName = fieldName;
19404
      }
19405
 
19406
      public short getThriftFieldId() {
19407
        return _thriftId;
19408
      }
19409
 
19410
      public String getFieldName() {
19411
        return _fieldName;
19412
      }
19413
    }
19414
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19415
    static {
19416
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19417
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19418
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markPaymentAsProcessed_result.class, metaDataMap);
19419
    }
19420
 
19421
    public markPaymentAsProcessed_result() {
19422
    }
19423
 
19424
    /**
19425
     * Performs a deep copy on <i>other</i>.
19426
     */
19427
    public markPaymentAsProcessed_result(markPaymentAsProcessed_result other) {
19428
    }
19429
 
19430
    public markPaymentAsProcessed_result deepCopy() {
19431
      return new markPaymentAsProcessed_result(this);
19432
    }
19433
 
19434
    @Override
19435
    public void clear() {
19436
    }
19437
 
19438
    public void setFieldValue(_Fields field, Object value) {
19439
      switch (field) {
19440
      }
19441
    }
19442
 
19443
    public Object getFieldValue(_Fields field) {
19444
      switch (field) {
19445
      }
19446
      throw new IllegalStateException();
19447
    }
19448
 
19449
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19450
    public boolean isSet(_Fields field) {
19451
      if (field == null) {
19452
        throw new IllegalArgumentException();
19453
      }
19454
 
19455
      switch (field) {
19456
      }
19457
      throw new IllegalStateException();
19458
    }
19459
 
19460
    @Override
19461
    public boolean equals(Object that) {
19462
      if (that == null)
19463
        return false;
19464
      if (that instanceof markPaymentAsProcessed_result)
19465
        return this.equals((markPaymentAsProcessed_result)that);
19466
      return false;
19467
    }
19468
 
19469
    public boolean equals(markPaymentAsProcessed_result that) {
19470
      if (that == null)
19471
        return false;
19472
 
19473
      return true;
19474
    }
19475
 
19476
    @Override
19477
    public int hashCode() {
19478
      return 0;
19479
    }
19480
 
19481
    public int compareTo(markPaymentAsProcessed_result other) {
19482
      if (!getClass().equals(other.getClass())) {
19483
        return getClass().getName().compareTo(other.getClass().getName());
19484
      }
19485
 
19486
      int lastComparison = 0;
19487
      markPaymentAsProcessed_result typedOther = (markPaymentAsProcessed_result)other;
19488
 
19489
      return 0;
19490
    }
19491
 
19492
    public _Fields fieldForId(int fieldId) {
19493
      return _Fields.findByThriftId(fieldId);
19494
    }
19495
 
19496
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19497
      org.apache.thrift.protocol.TField field;
19498
      iprot.readStructBegin();
19499
      while (true)
19500
      {
19501
        field = iprot.readFieldBegin();
19502
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19503
          break;
19504
        }
19505
        switch (field.id) {
19506
          default:
19507
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19508
        }
19509
        iprot.readFieldEnd();
19510
      }
19511
      iprot.readStructEnd();
19512
      validate();
19513
    }
19514
 
19515
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19516
      oprot.writeStructBegin(STRUCT_DESC);
19517
 
19518
      oprot.writeFieldStop();
19519
      oprot.writeStructEnd();
19520
    }
19521
 
19522
    @Override
19523
    public String toString() {
19524
      StringBuilder sb = new StringBuilder("markPaymentAsProcessed_result(");
19525
      boolean first = true;
19526
 
19527
      sb.append(")");
19528
      return sb.toString();
19529
    }
19530
 
19531
    public void validate() throws org.apache.thrift.TException {
19532
      // check for required fields
19533
    }
19534
 
19535
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19536
      try {
19537
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19538
      } catch (org.apache.thrift.TException te) {
19539
        throw new java.io.IOException(te);
19540
      }
19541
    }
19542
 
19543
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19544
      try {
19545
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19546
      } catch (org.apache.thrift.TException te) {
19547
        throw new java.io.IOException(te);
19548
      }
19549
    }
19550
 
19551
  }
19552
 
8914 rajveer 19553
  public static class getPaymentStatusAtGateway_args implements org.apache.thrift.TBase<getPaymentStatusAtGateway_args, getPaymentStatusAtGateway_args._Fields>, java.io.Serializable, Cloneable   {
19554
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentStatusAtGateway_args");
8907 rajveer 19555
 
19556
    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);
19557
    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);
19558
    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);
19559
 
19560
    private long merchantTxnId; // required
19561
    private double amount; // required
19562
    private boolean isDigital; // required
19563
 
19564
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19565
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19566
      MERCHANT_TXN_ID((short)1, "merchantTxnId"),
19567
      AMOUNT((short)2, "amount"),
19568
      IS_DIGITAL((short)3, "isDigital");
19569
 
19570
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19571
 
19572
      static {
19573
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19574
          byName.put(field.getFieldName(), field);
19575
        }
19576
      }
19577
 
19578
      /**
19579
       * Find the _Fields constant that matches fieldId, or null if its not found.
19580
       */
19581
      public static _Fields findByThriftId(int fieldId) {
19582
        switch(fieldId) {
19583
          case 1: // MERCHANT_TXN_ID
19584
            return MERCHANT_TXN_ID;
19585
          case 2: // AMOUNT
19586
            return AMOUNT;
19587
          case 3: // IS_DIGITAL
19588
            return IS_DIGITAL;
19589
          default:
19590
            return null;
19591
        }
19592
      }
19593
 
19594
      /**
19595
       * Find the _Fields constant that matches fieldId, throwing an exception
19596
       * if it is not found.
19597
       */
19598
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19599
        _Fields fields = findByThriftId(fieldId);
19600
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19601
        return fields;
19602
      }
19603
 
19604
      /**
19605
       * Find the _Fields constant that matches name, or null if its not found.
19606
       */
19607
      public static _Fields findByName(String name) {
19608
        return byName.get(name);
19609
      }
19610
 
19611
      private final short _thriftId;
19612
      private final String _fieldName;
19613
 
19614
      _Fields(short thriftId, String fieldName) {
19615
        _thriftId = thriftId;
19616
        _fieldName = fieldName;
19617
      }
19618
 
19619
      public short getThriftFieldId() {
19620
        return _thriftId;
19621
      }
19622
 
19623
      public String getFieldName() {
19624
        return _fieldName;
19625
      }
19626
    }
19627
 
19628
    // isset id assignments
19629
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
19630
    private static final int __AMOUNT_ISSET_ID = 1;
19631
    private static final int __ISDIGITAL_ISSET_ID = 2;
19632
    private BitSet __isset_bit_vector = new BitSet(3);
19633
 
19634
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19635
    static {
19636
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19637
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19638
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19639
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19640
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
19641
      tmpMap.put(_Fields.IS_DIGITAL, new org.apache.thrift.meta_data.FieldMetaData("isDigital", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19642
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
19643
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8914 rajveer 19644
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentStatusAtGateway_args.class, metaDataMap);
8907 rajveer 19645
    }
19646
 
8914 rajveer 19647
    public getPaymentStatusAtGateway_args() {
8907 rajveer 19648
    }
19649
 
8914 rajveer 19650
    public getPaymentStatusAtGateway_args(
8907 rajveer 19651
      long merchantTxnId,
19652
      double amount,
19653
      boolean isDigital)
19654
    {
19655
      this();
19656
      this.merchantTxnId = merchantTxnId;
19657
      setMerchantTxnIdIsSet(true);
19658
      this.amount = amount;
19659
      setAmountIsSet(true);
19660
      this.isDigital = isDigital;
19661
      setIsDigitalIsSet(true);
19662
    }
19663
 
19664
    /**
19665
     * Performs a deep copy on <i>other</i>.
19666
     */
8914 rajveer 19667
    public getPaymentStatusAtGateway_args(getPaymentStatusAtGateway_args other) {
8907 rajveer 19668
      __isset_bit_vector.clear();
19669
      __isset_bit_vector.or(other.__isset_bit_vector);
19670
      this.merchantTxnId = other.merchantTxnId;
19671
      this.amount = other.amount;
19672
      this.isDigital = other.isDigital;
19673
    }
19674
 
8914 rajveer 19675
    public getPaymentStatusAtGateway_args deepCopy() {
19676
      return new getPaymentStatusAtGateway_args(this);
8907 rajveer 19677
    }
19678
 
19679
    @Override
19680
    public void clear() {
19681
      setMerchantTxnIdIsSet(false);
19682
      this.merchantTxnId = 0;
19683
      setAmountIsSet(false);
19684
      this.amount = 0.0;
19685
      setIsDigitalIsSet(false);
19686
      this.isDigital = false;
19687
    }
19688
 
19689
    public long getMerchantTxnId() {
19690
      return this.merchantTxnId;
19691
    }
19692
 
19693
    public void setMerchantTxnId(long merchantTxnId) {
19694
      this.merchantTxnId = merchantTxnId;
19695
      setMerchantTxnIdIsSet(true);
19696
    }
19697
 
19698
    public void unsetMerchantTxnId() {
19699
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
19700
    }
19701
 
19702
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
19703
    public boolean isSetMerchantTxnId() {
19704
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
19705
    }
19706
 
19707
    public void setMerchantTxnIdIsSet(boolean value) {
19708
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
19709
    }
19710
 
19711
    public double getAmount() {
19712
      return this.amount;
19713
    }
19714
 
19715
    public void setAmount(double amount) {
19716
      this.amount = amount;
19717
      setAmountIsSet(true);
19718
    }
19719
 
19720
    public void unsetAmount() {
19721
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
19722
    }
19723
 
19724
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
19725
    public boolean isSetAmount() {
19726
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
19727
    }
19728
 
19729
    public void setAmountIsSet(boolean value) {
19730
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
19731
    }
19732
 
19733
    public boolean isIsDigital() {
19734
      return this.isDigital;
19735
    }
19736
 
19737
    public void setIsDigital(boolean isDigital) {
19738
      this.isDigital = isDigital;
19739
      setIsDigitalIsSet(true);
19740
    }
19741
 
19742
    public void unsetIsDigital() {
19743
      __isset_bit_vector.clear(__ISDIGITAL_ISSET_ID);
19744
    }
19745
 
19746
    /** Returns true if field isDigital is set (has been assigned a value) and false otherwise */
19747
    public boolean isSetIsDigital() {
19748
      return __isset_bit_vector.get(__ISDIGITAL_ISSET_ID);
19749
    }
19750
 
19751
    public void setIsDigitalIsSet(boolean value) {
19752
      __isset_bit_vector.set(__ISDIGITAL_ISSET_ID, value);
19753
    }
19754
 
19755
    public void setFieldValue(_Fields field, Object value) {
19756
      switch (field) {
19757
      case MERCHANT_TXN_ID:
19758
        if (value == null) {
19759
          unsetMerchantTxnId();
19760
        } else {
19761
          setMerchantTxnId((Long)value);
19762
        }
19763
        break;
19764
 
19765
      case AMOUNT:
19766
        if (value == null) {
19767
          unsetAmount();
19768
        } else {
19769
          setAmount((Double)value);
19770
        }
19771
        break;
19772
 
19773
      case IS_DIGITAL:
19774
        if (value == null) {
19775
          unsetIsDigital();
19776
        } else {
19777
          setIsDigital((Boolean)value);
19778
        }
19779
        break;
19780
 
19781
      }
19782
    }
19783
 
19784
    public Object getFieldValue(_Fields field) {
19785
      switch (field) {
19786
      case MERCHANT_TXN_ID:
19787
        return Long.valueOf(getMerchantTxnId());
19788
 
19789
      case AMOUNT:
19790
        return Double.valueOf(getAmount());
19791
 
19792
      case IS_DIGITAL:
19793
        return Boolean.valueOf(isIsDigital());
19794
 
19795
      }
19796
      throw new IllegalStateException();
19797
    }
19798
 
19799
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19800
    public boolean isSet(_Fields field) {
19801
      if (field == null) {
19802
        throw new IllegalArgumentException();
19803
      }
19804
 
19805
      switch (field) {
19806
      case MERCHANT_TXN_ID:
19807
        return isSetMerchantTxnId();
19808
      case AMOUNT:
19809
        return isSetAmount();
19810
      case IS_DIGITAL:
19811
        return isSetIsDigital();
19812
      }
19813
      throw new IllegalStateException();
19814
    }
19815
 
19816
    @Override
19817
    public boolean equals(Object that) {
19818
      if (that == null)
19819
        return false;
8914 rajveer 19820
      if (that instanceof getPaymentStatusAtGateway_args)
19821
        return this.equals((getPaymentStatusAtGateway_args)that);
8907 rajveer 19822
      return false;
19823
    }
19824
 
8914 rajveer 19825
    public boolean equals(getPaymentStatusAtGateway_args that) {
8907 rajveer 19826
      if (that == null)
19827
        return false;
19828
 
19829
      boolean this_present_merchantTxnId = true;
19830
      boolean that_present_merchantTxnId = true;
19831
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
19832
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
19833
          return false;
19834
        if (this.merchantTxnId != that.merchantTxnId)
19835
          return false;
19836
      }
19837
 
19838
      boolean this_present_amount = true;
19839
      boolean that_present_amount = true;
19840
      if (this_present_amount || that_present_amount) {
19841
        if (!(this_present_amount && that_present_amount))
19842
          return false;
19843
        if (this.amount != that.amount)
19844
          return false;
19845
      }
19846
 
19847
      boolean this_present_isDigital = true;
19848
      boolean that_present_isDigital = true;
19849
      if (this_present_isDigital || that_present_isDigital) {
19850
        if (!(this_present_isDigital && that_present_isDigital))
19851
          return false;
19852
        if (this.isDigital != that.isDigital)
19853
          return false;
19854
      }
19855
 
19856
      return true;
19857
    }
19858
 
19859
    @Override
19860
    public int hashCode() {
19861
      return 0;
19862
    }
19863
 
8914 rajveer 19864
    public int compareTo(getPaymentStatusAtGateway_args other) {
8907 rajveer 19865
      if (!getClass().equals(other.getClass())) {
19866
        return getClass().getName().compareTo(other.getClass().getName());
19867
      }
19868
 
19869
      int lastComparison = 0;
8914 rajveer 19870
      getPaymentStatusAtGateway_args typedOther = (getPaymentStatusAtGateway_args)other;
8907 rajveer 19871
 
19872
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
19873
      if (lastComparison != 0) {
19874
        return lastComparison;
19875
      }
19876
      if (isSetMerchantTxnId()) {
19877
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
19878
        if (lastComparison != 0) {
19879
          return lastComparison;
19880
        }
19881
      }
19882
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
19883
      if (lastComparison != 0) {
19884
        return lastComparison;
19885
      }
19886
      if (isSetAmount()) {
19887
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
19888
        if (lastComparison != 0) {
19889
          return lastComparison;
19890
        }
19891
      }
19892
      lastComparison = Boolean.valueOf(isSetIsDigital()).compareTo(typedOther.isSetIsDigital());
19893
      if (lastComparison != 0) {
19894
        return lastComparison;
19895
      }
19896
      if (isSetIsDigital()) {
19897
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isDigital, typedOther.isDigital);
19898
        if (lastComparison != 0) {
19899
          return lastComparison;
19900
        }
19901
      }
19902
      return 0;
19903
    }
19904
 
19905
    public _Fields fieldForId(int fieldId) {
19906
      return _Fields.findByThriftId(fieldId);
19907
    }
19908
 
19909
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19910
      org.apache.thrift.protocol.TField field;
19911
      iprot.readStructBegin();
19912
      while (true)
19913
      {
19914
        field = iprot.readFieldBegin();
19915
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19916
          break;
19917
        }
19918
        switch (field.id) {
19919
          case 1: // MERCHANT_TXN_ID
19920
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19921
              this.merchantTxnId = iprot.readI64();
19922
              setMerchantTxnIdIsSet(true);
19923
            } else { 
19924
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19925
            }
19926
            break;
19927
          case 2: // AMOUNT
19928
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
19929
              this.amount = iprot.readDouble();
19930
              setAmountIsSet(true);
19931
            } else { 
19932
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19933
            }
19934
            break;
19935
          case 3: // IS_DIGITAL
19936
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
19937
              this.isDigital = iprot.readBool();
19938
              setIsDigitalIsSet(true);
19939
            } else { 
19940
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19941
            }
19942
            break;
19943
          default:
19944
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19945
        }
19946
        iprot.readFieldEnd();
19947
      }
19948
      iprot.readStructEnd();
19949
      validate();
19950
    }
19951
 
19952
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19953
      validate();
19954
 
19955
      oprot.writeStructBegin(STRUCT_DESC);
19956
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
19957
      oprot.writeI64(this.merchantTxnId);
19958
      oprot.writeFieldEnd();
19959
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
19960
      oprot.writeDouble(this.amount);
19961
      oprot.writeFieldEnd();
19962
      oprot.writeFieldBegin(IS_DIGITAL_FIELD_DESC);
19963
      oprot.writeBool(this.isDigital);
19964
      oprot.writeFieldEnd();
19965
      oprot.writeFieldStop();
19966
      oprot.writeStructEnd();
19967
    }
19968
 
19969
    @Override
19970
    public String toString() {
8914 rajveer 19971
      StringBuilder sb = new StringBuilder("getPaymentStatusAtGateway_args(");
8907 rajveer 19972
      boolean first = true;
19973
 
19974
      sb.append("merchantTxnId:");
19975
      sb.append(this.merchantTxnId);
19976
      first = false;
19977
      if (!first) sb.append(", ");
19978
      sb.append("amount:");
19979
      sb.append(this.amount);
19980
      first = false;
19981
      if (!first) sb.append(", ");
19982
      sb.append("isDigital:");
19983
      sb.append(this.isDigital);
19984
      first = false;
19985
      sb.append(")");
19986
      return sb.toString();
19987
    }
19988
 
19989
    public void validate() throws org.apache.thrift.TException {
19990
      // check for required fields
19991
    }
19992
 
19993
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19994
      try {
19995
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19996
      } catch (org.apache.thrift.TException te) {
19997
        throw new java.io.IOException(te);
19998
      }
19999
    }
20000
 
20001
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20002
      try {
20003
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
20004
        __isset_bit_vector = new BitSet(1);
20005
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20006
      } catch (org.apache.thrift.TException te) {
20007
        throw new java.io.IOException(te);
20008
      }
20009
    }
20010
 
20011
  }
20012
 
8914 rajveer 20013
  public static class getPaymentStatusAtGateway_result implements org.apache.thrift.TBase<getPaymentStatusAtGateway_result, getPaymentStatusAtGateway_result._Fields>, java.io.Serializable, Cloneable   {
20014
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentStatusAtGateway_result");
8907 rajveer 20015
 
8914 rajveer 20016
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I32, (short)0);
8907 rajveer 20017
    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);
20018
 
8914 rajveer 20019
    private PaymentStatus success; // required
8907 rajveer 20020
    private PaymentException pe; // required
20021
 
20022
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20023
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8914 rajveer 20024
      /**
20025
       * 
20026
       * @see PaymentStatus
20027
       */
8907 rajveer 20028
      SUCCESS((short)0, "success"),
20029
      PE((short)1, "pe");
20030
 
20031
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20032
 
20033
      static {
20034
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20035
          byName.put(field.getFieldName(), field);
20036
        }
20037
      }
20038
 
20039
      /**
20040
       * Find the _Fields constant that matches fieldId, or null if its not found.
20041
       */
20042
      public static _Fields findByThriftId(int fieldId) {
20043
        switch(fieldId) {
20044
          case 0: // SUCCESS
20045
            return SUCCESS;
20046
          case 1: // PE
20047
            return PE;
20048
          default:
20049
            return null;
20050
        }
20051
      }
20052
 
20053
      /**
20054
       * Find the _Fields constant that matches fieldId, throwing an exception
20055
       * if it is not found.
20056
       */
20057
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20058
        _Fields fields = findByThriftId(fieldId);
20059
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20060
        return fields;
20061
      }
20062
 
20063
      /**
20064
       * Find the _Fields constant that matches name, or null if its not found.
20065
       */
20066
      public static _Fields findByName(String name) {
20067
        return byName.get(name);
20068
      }
20069
 
20070
      private final short _thriftId;
20071
      private final String _fieldName;
20072
 
20073
      _Fields(short thriftId, String fieldName) {
20074
        _thriftId = thriftId;
20075
        _fieldName = fieldName;
20076
      }
20077
 
20078
      public short getThriftFieldId() {
20079
        return _thriftId;
20080
      }
20081
 
20082
      public String getFieldName() {
20083
        return _fieldName;
20084
      }
20085
    }
20086
 
20087
    // isset id assignments
20088
 
20089
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20090
    static {
20091
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20092
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8914 rajveer 20093
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
8907 rajveer 20094
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20095
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
20096
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8914 rajveer 20097
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentStatusAtGateway_result.class, metaDataMap);
8907 rajveer 20098
    }
20099
 
8914 rajveer 20100
    public getPaymentStatusAtGateway_result() {
8907 rajveer 20101
    }
20102
 
8914 rajveer 20103
    public getPaymentStatusAtGateway_result(
20104
      PaymentStatus success,
8907 rajveer 20105
      PaymentException pe)
20106
    {
20107
      this();
20108
      this.success = success;
20109
      this.pe = pe;
20110
    }
20111
 
20112
    /**
20113
     * Performs a deep copy on <i>other</i>.
20114
     */
8914 rajveer 20115
    public getPaymentStatusAtGateway_result(getPaymentStatusAtGateway_result other) {
20116
      if (other.isSetSuccess()) {
20117
        this.success = other.success;
20118
      }
8907 rajveer 20119
      if (other.isSetPe()) {
20120
        this.pe = new PaymentException(other.pe);
20121
      }
20122
    }
20123
 
8914 rajveer 20124
    public getPaymentStatusAtGateway_result deepCopy() {
20125
      return new getPaymentStatusAtGateway_result(this);
8907 rajveer 20126
    }
20127
 
20128
    @Override
20129
    public void clear() {
8914 rajveer 20130
      this.success = null;
8907 rajveer 20131
      this.pe = null;
20132
    }
20133
 
8914 rajveer 20134
    /**
20135
     * 
20136
     * @see PaymentStatus
20137
     */
20138
    public PaymentStatus getSuccess() {
8907 rajveer 20139
      return this.success;
20140
    }
20141
 
8914 rajveer 20142
    /**
20143
     * 
20144
     * @see PaymentStatus
20145
     */
20146
    public void setSuccess(PaymentStatus success) {
8907 rajveer 20147
      this.success = success;
20148
    }
20149
 
20150
    public void unsetSuccess() {
8914 rajveer 20151
      this.success = null;
8907 rajveer 20152
    }
20153
 
20154
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
20155
    public boolean isSetSuccess() {
8914 rajveer 20156
      return this.success != null;
8907 rajveer 20157
    }
20158
 
20159
    public void setSuccessIsSet(boolean value) {
8914 rajveer 20160
      if (!value) {
20161
        this.success = null;
20162
      }
8907 rajveer 20163
    }
20164
 
20165
    public PaymentException getPe() {
20166
      return this.pe;
20167
    }
20168
 
20169
    public void setPe(PaymentException pe) {
20170
      this.pe = pe;
20171
    }
20172
 
20173
    public void unsetPe() {
20174
      this.pe = null;
20175
    }
20176
 
20177
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
20178
    public boolean isSetPe() {
20179
      return this.pe != null;
20180
    }
20181
 
20182
    public void setPeIsSet(boolean value) {
20183
      if (!value) {
20184
        this.pe = null;
20185
      }
20186
    }
20187
 
20188
    public void setFieldValue(_Fields field, Object value) {
20189
      switch (field) {
20190
      case SUCCESS:
20191
        if (value == null) {
20192
          unsetSuccess();
20193
        } else {
8914 rajveer 20194
          setSuccess((PaymentStatus)value);
8907 rajveer 20195
        }
20196
        break;
20197
 
20198
      case PE:
20199
        if (value == null) {
20200
          unsetPe();
20201
        } else {
20202
          setPe((PaymentException)value);
20203
        }
20204
        break;
20205
 
20206
      }
20207
    }
20208
 
20209
    public Object getFieldValue(_Fields field) {
20210
      switch (field) {
20211
      case SUCCESS:
8914 rajveer 20212
        return getSuccess();
8907 rajveer 20213
 
20214
      case PE:
20215
        return getPe();
20216
 
20217
      }
20218
      throw new IllegalStateException();
20219
    }
20220
 
20221
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20222
    public boolean isSet(_Fields field) {
20223
      if (field == null) {
20224
        throw new IllegalArgumentException();
20225
      }
20226
 
20227
      switch (field) {
20228
      case SUCCESS:
20229
        return isSetSuccess();
20230
      case PE:
20231
        return isSetPe();
20232
      }
20233
      throw new IllegalStateException();
20234
    }
20235
 
20236
    @Override
20237
    public boolean equals(Object that) {
20238
      if (that == null)
20239
        return false;
8914 rajveer 20240
      if (that instanceof getPaymentStatusAtGateway_result)
20241
        return this.equals((getPaymentStatusAtGateway_result)that);
8907 rajveer 20242
      return false;
20243
    }
20244
 
8914 rajveer 20245
    public boolean equals(getPaymentStatusAtGateway_result that) {
8907 rajveer 20246
      if (that == null)
20247
        return false;
20248
 
8914 rajveer 20249
      boolean this_present_success = true && this.isSetSuccess();
20250
      boolean that_present_success = true && that.isSetSuccess();
8907 rajveer 20251
      if (this_present_success || that_present_success) {
20252
        if (!(this_present_success && that_present_success))
20253
          return false;
8914 rajveer 20254
        if (!this.success.equals(that.success))
8907 rajveer 20255
          return false;
20256
      }
20257
 
20258
      boolean this_present_pe = true && this.isSetPe();
20259
      boolean that_present_pe = true && that.isSetPe();
20260
      if (this_present_pe || that_present_pe) {
20261
        if (!(this_present_pe && that_present_pe))
20262
          return false;
20263
        if (!this.pe.equals(that.pe))
20264
          return false;
20265
      }
20266
 
20267
      return true;
20268
    }
20269
 
20270
    @Override
20271
    public int hashCode() {
20272
      return 0;
20273
    }
20274
 
8914 rajveer 20275
    public int compareTo(getPaymentStatusAtGateway_result other) {
8907 rajveer 20276
      if (!getClass().equals(other.getClass())) {
20277
        return getClass().getName().compareTo(other.getClass().getName());
20278
      }
20279
 
20280
      int lastComparison = 0;
8914 rajveer 20281
      getPaymentStatusAtGateway_result typedOther = (getPaymentStatusAtGateway_result)other;
8907 rajveer 20282
 
20283
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
20284
      if (lastComparison != 0) {
20285
        return lastComparison;
20286
      }
20287
      if (isSetSuccess()) {
20288
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
20289
        if (lastComparison != 0) {
20290
          return lastComparison;
20291
        }
20292
      }
20293
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
20294
      if (lastComparison != 0) {
20295
        return lastComparison;
20296
      }
20297
      if (isSetPe()) {
20298
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
20299
        if (lastComparison != 0) {
20300
          return lastComparison;
20301
        }
20302
      }
20303
      return 0;
20304
    }
20305
 
20306
    public _Fields fieldForId(int fieldId) {
20307
      return _Fields.findByThriftId(fieldId);
20308
    }
20309
 
20310
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20311
      org.apache.thrift.protocol.TField field;
20312
      iprot.readStructBegin();
20313
      while (true)
20314
      {
20315
        field = iprot.readFieldBegin();
20316
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20317
          break;
20318
        }
20319
        switch (field.id) {
20320
          case 0: // SUCCESS
8914 rajveer 20321
            if (field.type == org.apache.thrift.protocol.TType.I32) {
20322
              this.success = PaymentStatus.findByValue(iprot.readI32());
8907 rajveer 20323
            } else { 
20324
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20325
            }
20326
            break;
20327
          case 1: // PE
20328
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
20329
              this.pe = new PaymentException();
20330
              this.pe.read(iprot);
20331
            } else { 
20332
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20333
            }
20334
            break;
20335
          default:
20336
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20337
        }
20338
        iprot.readFieldEnd();
20339
      }
20340
      iprot.readStructEnd();
20341
      validate();
20342
    }
20343
 
20344
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20345
      oprot.writeStructBegin(STRUCT_DESC);
20346
 
20347
      if (this.isSetSuccess()) {
20348
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8914 rajveer 20349
        oprot.writeI32(this.success.getValue());
8907 rajveer 20350
        oprot.writeFieldEnd();
20351
      } else if (this.isSetPe()) {
20352
        oprot.writeFieldBegin(PE_FIELD_DESC);
20353
        this.pe.write(oprot);
20354
        oprot.writeFieldEnd();
20355
      }
20356
      oprot.writeFieldStop();
20357
      oprot.writeStructEnd();
20358
    }
20359
 
20360
    @Override
20361
    public String toString() {
8914 rajveer 20362
      StringBuilder sb = new StringBuilder("getPaymentStatusAtGateway_result(");
8907 rajveer 20363
      boolean first = true;
20364
 
20365
      sb.append("success:");
8914 rajveer 20366
      if (this.success == null) {
20367
        sb.append("null");
20368
      } else {
20369
        sb.append(this.success);
20370
      }
8907 rajveer 20371
      first = false;
20372
      if (!first) sb.append(", ");
20373
      sb.append("pe:");
20374
      if (this.pe == null) {
20375
        sb.append("null");
20376
      } else {
20377
        sb.append(this.pe);
20378
      }
20379
      first = false;
20380
      sb.append(")");
20381
      return sb.toString();
20382
    }
20383
 
20384
    public void validate() throws org.apache.thrift.TException {
20385
      // check for required fields
20386
    }
20387
 
20388
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20389
      try {
20390
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20391
      } catch (org.apache.thrift.TException te) {
20392
        throw new java.io.IOException(te);
20393
      }
20394
    }
20395
 
20396
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20397
      try {
20398
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20399
      } catch (org.apache.thrift.TException te) {
20400
        throw new java.io.IOException(te);
20401
      }
20402
    }
20403
 
20404
  }
20405
 
123 ashish 20406
}