Subversion Repositories SmartDukaan

Rev

Rev 4141 | Rev 4600 | 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
34
     */
3430 rajveer 35
    public long createPayment(long userId, double amount, long gatewayId, long txnId) throws PaymentException, org.apache.thrift.TException;
123 ashish 36
 
695 rajveer 37
    /**
4141 chandransh 38
     * Get all payments for user. If status and gateway are null, they are ignored. Same for times as well.
695 rajveer 39
     * 
40
     * @param userId
41
     * @param fromTime
42
     * @param toTime
43
     * @param status
44
     * @param gatewayId
45
     */
3430 rajveer 46
    public List<Payment> getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException;
123 ashish 47
 
695 rajveer 48
    /**
4141 chandransh 49
     * Get all payments in the given status for the given gateway. If gatewayId is 0, then it is ignored.
695 rajveer 50
     * 
51
     * @param fromTime
52
     * @param toTime
53
     * @param status
54
     * @param gatewayId
55
     */
3430 rajveer 56
    public List<Payment> getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException;
123 ashish 57
 
695 rajveer 58
    /**
4141 chandransh 59
     * Get all payments for the given gateway which were captured between the given dates. If the gatewayId is 0, it's ignored.
695 rajveer 60
     * 
4141 chandransh 61
     * @param fromTime
62
     * @param toTime
63
     * @param gatewayId
64
     */
65
    public List<Payment> getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws PaymentException, org.apache.thrift.TException;
66
 
67
    /**
68
     * Get the gateway for the given id.
695 rajveer 69
     * 
70
     * @param id
71
     */
3430 rajveer 72
    public PaymentGateway getPaymentGateway(long id) throws PaymentException, org.apache.thrift.TException;
420 ashish 73
 
695 rajveer 74
    /**
75
     * Get a particular payment info
76
     * 
77
     * 
78
     * @param id
79
     */
3430 rajveer 80
    public Payment getPayment(long id) throws PaymentException, org.apache.thrift.TException;
420 ashish 81
 
695 rajveer 82
    /**
83
     * Get a particular payment for a transaction. Will raise exception.
84
     * 
85
     * 
86
     * @param txnId
87
     */
3430 rajveer 88
    public List<Payment> getPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException;
420 ashish 89
 
695 rajveer 90
    /**
91
     * mark payment successful and store parameters
92
     * 
93
     * 
94
     * @param id
95
     * @param gatewayPaymentId
96
     * @param sessionId
97
     * @param gatewayTxnStatus
98
     * @param description
99
     * @param gatewayTxnId
100
     * @param authCode
101
     * @param referenceCode
102
     * @param errorCode
103
     * @param status
1119 rajveer 104
     * @param gatewayTxnDate
695 rajveer 105
     * @param attributes
106
     */
3430 rajveer 107
    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 108
 
1629 ankur.sing 109
    /**
1731 ankur.sing 110
     * Returns the minimum and maximum amounts among successful payments.
111
     * List contains two double values, first minimum and second maximum amount.
1629 ankur.sing 112
     */
3430 rajveer 113
    public List<Double> getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException;
1629 ankur.sing 114
 
2462 chandransh 115
    /**
116
     * Initialize the payment pipe for a HDFC payment. The URL the user should be redirected to is returned.
117
     * In case of any processing error, an exception is raised.
118
     * 
119
     * @param merchantPaymentId
120
     */
3430 rajveer 121
    public String initializeHdfcPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException;
2462 chandransh 122
 
2690 chandransh 123
    /**
3616 chandransh 124
     * Initialize the payment pipe for a HDFC EMI payment. The URL the user should be redirected to is returned.
125
     * In case of any processing error, an exception is raised.
126
     * 
127
     * @param merchantPaymentId
128
     */
129
    public String initializeHdfcEmiPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException;
130
 
131
    /**
2690 chandransh 132
     * Create a refund of the given amount corresponding to the given order to be processed through the same
133
     * payment gateway which processed the payment for the corresponding transaction.
134
     * Returns the id of the newly created Refund.
135
     * 
136
     * @param orderId
137
     * @param merchantTxnId
138
     * @param amount
139
     */
3430 rajveer 140
    public long createRefund(long orderId, long merchantTxnId, double amount) throws PaymentException, org.apache.thrift.TException;
2690 chandransh 141
 
3010 chandransh 142
    /**
143
     * Capture the payment for the given merchant transaction id. It processes the last payment for the given
4421 mandeep.dh 144
     * transaction. If the capture attempt failed, the payment is marked as failed. PaymentException with error
145
     * code 104 is	thrown in case no payments are found for the transaction id passed.
146
     * PaymentException is also thrown with error code 106 in case capture was not possible due to connection
147
     * issue. Here, we	payment also gets updated to CAPTURE_INPROCESS state
3010 chandransh 148
     * 
149
     * @param merchantTxnId
150
     */
3430 rajveer 151
    public boolean capturePayment(long merchantTxnId) throws PaymentException, org.apache.thrift.TException;
3010 chandransh 152
 
3956 chandransh 153
    /**
154
     * Adds the given amount to the captured amount of a COD payment.
155
     * Updates the captured amount for the corresponding payment and marks it as PARTIALLY CAPTURED.
156
     * If the captured amount becomes equal to total amount, then the payment status is set as SUCCESS.
157
     * Also sets the name of the entity which transferred the money, the date on which it was transferred
158
     * and the corresponding transaction id.
159
     * 
160
     * Returns false if the payment couldn't be captured.
161
     * Throws exception if no such payment could be found or if the captured amount will exceed the total amount after capturing.
162
     * 
163
     * @param merchantTxnId
164
     * @param amount
165
     * @param xferBy
166
     * @param xferTxnId
167
     * @param xferDate
168
     */
169
    public boolean partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws PaymentException, org.apache.thrift.TException;
170
 
4008 mandeep.dh 171
    /**
172
     * Returns the list of payments that require some extra processing and
173
     * which belong to a particular category. This is currently used by CRM
174
     * application.
175
     * 
176
     * @param category
177
     */
178
    public List<Long> getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException;
179
 
180
    /**
181
     * Marks a particular payment as processed for a particular cateogory.
182
     * It essentially deletes the payment if it is processed for a particular
183
     * category. This is currently used by CRM application.
184
     * 
185
     * @param paymentId
186
     * @param category
187
     */
188
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException;
189
 
123 ashish 190
  }
191
 
3430 rajveer 192
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
193
 
194
    public void createPayment(long userId, double amount, long gatewayId, long txnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPayment_call> resultHandler) throws org.apache.thrift.TException;
195
 
196
    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;
197
 
198
    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;
199
 
4141 chandransh 200
    public void getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentsByCapturedDate_call> resultHandler) throws org.apache.thrift.TException;
201
 
3430 rajveer 202
    public void getPaymentGateway(long id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentGateway_call> resultHandler) throws org.apache.thrift.TException;
203
 
204
    public void getPayment(long id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPayment_call> resultHandler) throws org.apache.thrift.TException;
205
 
206
    public void getPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException;
207
 
208
    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;
209
 
210
    public void getSuccessfulPaymentsAmountRange(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSuccessfulPaymentsAmountRange_call> resultHandler) throws org.apache.thrift.TException;
211
 
212
    public void initializeHdfcPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.initializeHdfcPayment_call> resultHandler) throws org.apache.thrift.TException;
213
 
3616 chandransh 214
    public void initializeHdfcEmiPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.initializeHdfcEmiPayment_call> resultHandler) throws org.apache.thrift.TException;
215
 
3430 rajveer 216
    public void createRefund(long orderId, long merchantTxnId, double amount, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createRefund_call> resultHandler) throws org.apache.thrift.TException;
217
 
218
    public void capturePayment(long merchantTxnId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.capturePayment_call> resultHandler) throws org.apache.thrift.TException;
219
 
3956 chandransh 220
    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;
221
 
4008 mandeep.dh 222
    public void getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPaymentsRequiringExtraProcessing_call> resultHandler) throws org.apache.thrift.TException;
223
 
224
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.markPaymentAsProcessed_call> resultHandler) throws org.apache.thrift.TException;
225
 
3430 rajveer 226
  }
227
 
3374 rajveer 228
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
3430 rajveer 229
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
230
      public Factory() {}
231
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
232
        return new Client(prot);
233
      }
234
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
235
        return new Client(iprot, oprot);
236
      }
237
    }
238
 
239
    public Client(org.apache.thrift.protocol.TProtocol prot)
123 ashish 240
    {
3430 rajveer 241
      super(prot, prot);
123 ashish 242
    }
243
 
3430 rajveer 244
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
3374 rajveer 245
      super(iprot, oprot);
123 ashish 246
    }
247
 
3430 rajveer 248
    public long createPayment(long userId, double amount, long gatewayId, long txnId) throws PaymentException, org.apache.thrift.TException
123 ashish 249
    {
695 rajveer 250
      send_createPayment(userId, amount, gatewayId, txnId);
123 ashish 251
      return recv_createPayment();
252
    }
253
 
3430 rajveer 254
    public void send_createPayment(long userId, double amount, long gatewayId, long txnId) throws org.apache.thrift.TException
123 ashish 255
    {
256
      createPayment_args args = new createPayment_args();
3430 rajveer 257
      args.setUserId(userId);
258
      args.setAmount(amount);
259
      args.setGatewayId(gatewayId);
260
      args.setTxnId(txnId);
261
      sendBase("createPayment", args);
123 ashish 262
    }
263
 
3430 rajveer 264
    public long recv_createPayment() throws PaymentException, org.apache.thrift.TException
123 ashish 265
    {
266
      createPayment_result result = new createPayment_result();
3430 rajveer 267
      receiveBase(result, "createPayment");
123 ashish 268
      if (result.isSetSuccess()) {
269
        return result.success;
270
      }
271
      if (result.pe != null) {
272
        throw result.pe;
273
      }
3430 rajveer 274
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createPayment failed: unknown result");
123 ashish 275
    }
276
 
3430 rajveer 277
    public List<Payment> getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException
123 ashish 278
    {
695 rajveer 279
      send_getPaymentsForUser(userId, fromTime, toTime, status, gatewayId);
123 ashish 280
      return recv_getPaymentsForUser();
281
    }
282
 
3430 rajveer 283
    public void send_getPaymentsForUser(long userId, long fromTime, long toTime, PaymentStatus status, long gatewayId) throws org.apache.thrift.TException
123 ashish 284
    {
285
      getPaymentsForUser_args args = new getPaymentsForUser_args();
3430 rajveer 286
      args.setUserId(userId);
287
      args.setFromTime(fromTime);
288
      args.setToTime(toTime);
289
      args.setStatus(status);
290
      args.setGatewayId(gatewayId);
291
      sendBase("getPaymentsForUser", args);
123 ashish 292
    }
293
 
3430 rajveer 294
    public List<Payment> recv_getPaymentsForUser() throws PaymentException, org.apache.thrift.TException
123 ashish 295
    {
296
      getPaymentsForUser_result result = new getPaymentsForUser_result();
3430 rajveer 297
      receiveBase(result, "getPaymentsForUser");
123 ashish 298
      if (result.isSetSuccess()) {
299
        return result.success;
300
      }
301
      if (result.pe != null) {
302
        throw result.pe;
303
      }
3430 rajveer 304
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsForUser failed: unknown result");
123 ashish 305
    }
306
 
3430 rajveer 307
    public List<Payment> getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws PaymentException, org.apache.thrift.TException
123 ashish 308
    {
695 rajveer 309
      send_getPayments(fromTime, toTime, status, gatewayId);
123 ashish 310
      return recv_getPayments();
311
    }
312
 
3430 rajveer 313
    public void send_getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId) throws org.apache.thrift.TException
123 ashish 314
    {
315
      getPayments_args args = new getPayments_args();
3430 rajveer 316
      args.setFromTime(fromTime);
317
      args.setToTime(toTime);
318
      args.setStatus(status);
319
      args.setGatewayId(gatewayId);
320
      sendBase("getPayments", args);
123 ashish 321
    }
322
 
3430 rajveer 323
    public List<Payment> recv_getPayments() throws PaymentException, org.apache.thrift.TException
123 ashish 324
    {
325
      getPayments_result result = new getPayments_result();
3430 rajveer 326
      receiveBase(result, "getPayments");
123 ashish 327
      if (result.isSetSuccess()) {
328
        return result.success;
329
      }
330
      if (result.pe != null) {
331
        throw result.pe;
332
      }
3430 rajveer 333
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPayments failed: unknown result");
123 ashish 334
    }
335
 
4141 chandransh 336
    public List<Payment> getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws PaymentException, org.apache.thrift.TException
337
    {
338
      send_getPaymentsByCapturedDate(fromTime, toTime, gatewayId);
339
      return recv_getPaymentsByCapturedDate();
340
    }
341
 
342
    public void send_getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId) throws org.apache.thrift.TException
343
    {
344
      getPaymentsByCapturedDate_args args = new getPaymentsByCapturedDate_args();
345
      args.setFromTime(fromTime);
346
      args.setToTime(toTime);
347
      args.setGatewayId(gatewayId);
348
      sendBase("getPaymentsByCapturedDate", args);
349
    }
350
 
351
    public List<Payment> recv_getPaymentsByCapturedDate() throws PaymentException, org.apache.thrift.TException
352
    {
353
      getPaymentsByCapturedDate_result result = new getPaymentsByCapturedDate_result();
354
      receiveBase(result, "getPaymentsByCapturedDate");
355
      if (result.isSetSuccess()) {
356
        return result.success;
357
      }
358
      if (result.pe != null) {
359
        throw result.pe;
360
      }
361
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsByCapturedDate failed: unknown result");
362
    }
363
 
3430 rajveer 364
    public PaymentGateway getPaymentGateway(long id) throws PaymentException, org.apache.thrift.TException
420 ashish 365
    {
366
      send_getPaymentGateway(id);
367
      return recv_getPaymentGateway();
368
    }
369
 
3430 rajveer 370
    public void send_getPaymentGateway(long id) throws org.apache.thrift.TException
420 ashish 371
    {
372
      getPaymentGateway_args args = new getPaymentGateway_args();
3430 rajveer 373
      args.setId(id);
374
      sendBase("getPaymentGateway", args);
420 ashish 375
    }
376
 
3430 rajveer 377
    public PaymentGateway recv_getPaymentGateway() throws PaymentException, org.apache.thrift.TException
420 ashish 378
    {
379
      getPaymentGateway_result result = new getPaymentGateway_result();
3430 rajveer 380
      receiveBase(result, "getPaymentGateway");
420 ashish 381
      if (result.isSetSuccess()) {
382
        return result.success;
383
      }
384
      if (result.pe != null) {
385
        throw result.pe;
386
      }
3430 rajveer 387
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentGateway failed: unknown result");
420 ashish 388
    }
389
 
3430 rajveer 390
    public Payment getPayment(long id) throws PaymentException, org.apache.thrift.TException
420 ashish 391
    {
695 rajveer 392
      send_getPayment(id);
393
      return recv_getPayment();
420 ashish 394
    }
395
 
3430 rajveer 396
    public void send_getPayment(long id) throws org.apache.thrift.TException
420 ashish 397
    {
695 rajveer 398
      getPayment_args args = new getPayment_args();
3430 rajveer 399
      args.setId(id);
400
      sendBase("getPayment", args);
420 ashish 401
    }
402
 
3430 rajveer 403
    public Payment recv_getPayment() throws PaymentException, org.apache.thrift.TException
420 ashish 404
    {
695 rajveer 405
      getPayment_result result = new getPayment_result();
3430 rajveer 406
      receiveBase(result, "getPayment");
695 rajveer 407
      if (result.isSetSuccess()) {
408
        return result.success;
409
      }
420 ashish 410
      if (result.pe != null) {
411
        throw result.pe;
412
      }
3430 rajveer 413
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPayment failed: unknown result");
420 ashish 414
    }
415
 
3430 rajveer 416
    public List<Payment> getPaymentForTxnId(long txnId) throws PaymentException, org.apache.thrift.TException
420 ashish 417
    {
695 rajveer 418
      send_getPaymentForTxnId(txnId);
419
      return recv_getPaymentForTxnId();
420 ashish 420
    }
421
 
3430 rajveer 422
    public void send_getPaymentForTxnId(long txnId) throws org.apache.thrift.TException
420 ashish 423
    {
695 rajveer 424
      getPaymentForTxnId_args args = new getPaymentForTxnId_args();
3430 rajveer 425
      args.setTxnId(txnId);
426
      sendBase("getPaymentForTxnId", args);
420 ashish 427
    }
428
 
3430 rajveer 429
    public List<Payment> recv_getPaymentForTxnId() throws PaymentException, org.apache.thrift.TException
420 ashish 430
    {
695 rajveer 431
      getPaymentForTxnId_result result = new getPaymentForTxnId_result();
3430 rajveer 432
      receiveBase(result, "getPaymentForTxnId");
420 ashish 433
      if (result.isSetSuccess()) {
434
        return result.success;
435
      }
436
      if (result.pe != null) {
437
        throw result.pe;
438
      }
3430 rajveer 439
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentForTxnId failed: unknown result");
420 ashish 440
    }
441
 
3430 rajveer 442
    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 443
    {
1119 rajveer 444
      send_updatePaymentDetails(id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes);
695 rajveer 445
      return recv_updatePaymentDetails();
420 ashish 446
    }
447
 
3430 rajveer 448
    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 449
    {
695 rajveer 450
      updatePaymentDetails_args args = new updatePaymentDetails_args();
3430 rajveer 451
      args.setId(id);
452
      args.setGatewayPaymentId(gatewayPaymentId);
453
      args.setSessionId(sessionId);
454
      args.setGatewayTxnStatus(gatewayTxnStatus);
455
      args.setDescription(description);
456
      args.setGatewayTxnId(gatewayTxnId);
457
      args.setAuthCode(authCode);
458
      args.setReferenceCode(referenceCode);
459
      args.setErrorCode(errorCode);
460
      args.setStatus(status);
461
      args.setGatewayTxnDate(gatewayTxnDate);
462
      args.setAttributes(attributes);
463
      sendBase("updatePaymentDetails", args);
420 ashish 464
    }
465
 
3430 rajveer 466
    public boolean recv_updatePaymentDetails() throws PaymentException, org.apache.thrift.TException
420 ashish 467
    {
695 rajveer 468
      updatePaymentDetails_result result = new updatePaymentDetails_result();
3430 rajveer 469
      receiveBase(result, "updatePaymentDetails");
695 rajveer 470
      if (result.isSetSuccess()) {
471
        return result.success;
472
      }
420 ashish 473
      if (result.pe != null) {
474
        throw result.pe;
475
      }
3430 rajveer 476
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "updatePaymentDetails failed: unknown result");
420 ashish 477
    }
478
 
3430 rajveer 479
    public List<Double> getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 480
    {
1731 ankur.sing 481
      send_getSuccessfulPaymentsAmountRange();
482
      return recv_getSuccessfulPaymentsAmountRange();
1629 ankur.sing 483
    }
484
 
3430 rajveer 485
    public void send_getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 486
    {
1731 ankur.sing 487
      getSuccessfulPaymentsAmountRange_args args = new getSuccessfulPaymentsAmountRange_args();
3430 rajveer 488
      sendBase("getSuccessfulPaymentsAmountRange", args);
1629 ankur.sing 489
    }
490
 
3430 rajveer 491
    public List<Double> recv_getSuccessfulPaymentsAmountRange() throws org.apache.thrift.TException
1629 ankur.sing 492
    {
1731 ankur.sing 493
      getSuccessfulPaymentsAmountRange_result result = new getSuccessfulPaymentsAmountRange_result();
3430 rajveer 494
      receiveBase(result, "getSuccessfulPaymentsAmountRange");
1629 ankur.sing 495
      if (result.isSetSuccess()) {
496
        return result.success;
497
      }
3430 rajveer 498
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getSuccessfulPaymentsAmountRange failed: unknown result");
1629 ankur.sing 499
    }
500
 
3430 rajveer 501
    public String initializeHdfcPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException
2462 chandransh 502
    {
503
      send_initializeHdfcPayment(merchantPaymentId);
504
      return recv_initializeHdfcPayment();
505
    }
506
 
3430 rajveer 507
    public void send_initializeHdfcPayment(long merchantPaymentId) throws org.apache.thrift.TException
2462 chandransh 508
    {
509
      initializeHdfcPayment_args args = new initializeHdfcPayment_args();
3430 rajveer 510
      args.setMerchantPaymentId(merchantPaymentId);
511
      sendBase("initializeHdfcPayment", args);
2462 chandransh 512
    }
513
 
3430 rajveer 514
    public String recv_initializeHdfcPayment() throws PaymentException, org.apache.thrift.TException
2462 chandransh 515
    {
516
      initializeHdfcPayment_result result = new initializeHdfcPayment_result();
3430 rajveer 517
      receiveBase(result, "initializeHdfcPayment");
2462 chandransh 518
      if (result.isSetSuccess()) {
519
        return result.success;
520
      }
521
      if (result.pe != null) {
522
        throw result.pe;
523
      }
3430 rajveer 524
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "initializeHdfcPayment failed: unknown result");
2462 chandransh 525
    }
526
 
3616 chandransh 527
    public String initializeHdfcEmiPayment(long merchantPaymentId) throws PaymentException, org.apache.thrift.TException
528
    {
529
      send_initializeHdfcEmiPayment(merchantPaymentId);
530
      return recv_initializeHdfcEmiPayment();
531
    }
532
 
533
    public void send_initializeHdfcEmiPayment(long merchantPaymentId) throws org.apache.thrift.TException
534
    {
535
      initializeHdfcEmiPayment_args args = new initializeHdfcEmiPayment_args();
536
      args.setMerchantPaymentId(merchantPaymentId);
537
      sendBase("initializeHdfcEmiPayment", args);
538
    }
539
 
540
    public String recv_initializeHdfcEmiPayment() throws PaymentException, org.apache.thrift.TException
541
    {
542
      initializeHdfcEmiPayment_result result = new initializeHdfcEmiPayment_result();
543
      receiveBase(result, "initializeHdfcEmiPayment");
544
      if (result.isSetSuccess()) {
545
        return result.success;
546
      }
547
      if (result.pe != null) {
548
        throw result.pe;
549
      }
550
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "initializeHdfcEmiPayment failed: unknown result");
551
    }
552
 
3430 rajveer 553
    public long createRefund(long orderId, long merchantTxnId, double amount) throws PaymentException, org.apache.thrift.TException
2690 chandransh 554
    {
555
      send_createRefund(orderId, merchantTxnId, amount);
556
      return recv_createRefund();
557
    }
558
 
3430 rajveer 559
    public void send_createRefund(long orderId, long merchantTxnId, double amount) throws org.apache.thrift.TException
2690 chandransh 560
    {
561
      createRefund_args args = new createRefund_args();
3430 rajveer 562
      args.setOrderId(orderId);
563
      args.setMerchantTxnId(merchantTxnId);
564
      args.setAmount(amount);
565
      sendBase("createRefund", args);
2690 chandransh 566
    }
567
 
3430 rajveer 568
    public long recv_createRefund() throws PaymentException, org.apache.thrift.TException
2690 chandransh 569
    {
570
      createRefund_result result = new createRefund_result();
3430 rajveer 571
      receiveBase(result, "createRefund");
2690 chandransh 572
      if (result.isSetSuccess()) {
573
        return result.success;
574
      }
575
      if (result.pe != null) {
576
        throw result.pe;
577
      }
3430 rajveer 578
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createRefund failed: unknown result");
2690 chandransh 579
    }
580
 
3430 rajveer 581
    public boolean capturePayment(long merchantTxnId) throws PaymentException, org.apache.thrift.TException
3010 chandransh 582
    {
583
      send_capturePayment(merchantTxnId);
584
      return recv_capturePayment();
585
    }
586
 
3430 rajveer 587
    public void send_capturePayment(long merchantTxnId) throws org.apache.thrift.TException
3010 chandransh 588
    {
589
      capturePayment_args args = new capturePayment_args();
3430 rajveer 590
      args.setMerchantTxnId(merchantTxnId);
591
      sendBase("capturePayment", args);
3010 chandransh 592
    }
593
 
3430 rajveer 594
    public boolean recv_capturePayment() throws PaymentException, org.apache.thrift.TException
3010 chandransh 595
    {
596
      capturePayment_result result = new capturePayment_result();
3430 rajveer 597
      receiveBase(result, "capturePayment");
3010 chandransh 598
      if (result.isSetSuccess()) {
599
        return result.success;
600
      }
601
      if (result.pe != null) {
602
        throw result.pe;
603
      }
3430 rajveer 604
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "capturePayment failed: unknown result");
3010 chandransh 605
    }
606
 
3956 chandransh 607
    public boolean partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws PaymentException, org.apache.thrift.TException
608
    {
609
      send_partiallyCapturePayment(merchantTxnId, amount, xferBy, xferTxnId, xferDate);
610
      return recv_partiallyCapturePayment();
611
    }
612
 
613
    public void send_partiallyCapturePayment(long merchantTxnId, double amount, String xferBy, String xferTxnId, long xferDate) throws org.apache.thrift.TException
614
    {
615
      partiallyCapturePayment_args args = new partiallyCapturePayment_args();
616
      args.setMerchantTxnId(merchantTxnId);
617
      args.setAmount(amount);
618
      args.setXferBy(xferBy);
619
      args.setXferTxnId(xferTxnId);
620
      args.setXferDate(xferDate);
621
      sendBase("partiallyCapturePayment", args);
622
    }
623
 
624
    public boolean recv_partiallyCapturePayment() throws PaymentException, org.apache.thrift.TException
625
    {
626
      partiallyCapturePayment_result result = new partiallyCapturePayment_result();
627
      receiveBase(result, "partiallyCapturePayment");
628
      if (result.isSetSuccess()) {
629
        return result.success;
630
      }
631
      if (result.pe != null) {
632
        throw result.pe;
633
      }
634
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "partiallyCapturePayment failed: unknown result");
635
    }
636
 
4008 mandeep.dh 637
    public List<Long> getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException
638
    {
639
      send_getPaymentsRequiringExtraProcessing(category);
640
      return recv_getPaymentsRequiringExtraProcessing();
641
    }
642
 
643
    public void send_getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category) throws org.apache.thrift.TException
644
    {
645
      getPaymentsRequiringExtraProcessing_args args = new getPaymentsRequiringExtraProcessing_args();
646
      args.setCategory(category);
647
      sendBase("getPaymentsRequiringExtraProcessing", args);
648
    }
649
 
650
    public List<Long> recv_getPaymentsRequiringExtraProcessing() throws org.apache.thrift.TException
651
    {
652
      getPaymentsRequiringExtraProcessing_result result = new getPaymentsRequiringExtraProcessing_result();
653
      receiveBase(result, "getPaymentsRequiringExtraProcessing");
654
      if (result.isSetSuccess()) {
655
        return result.success;
656
      }
657
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPaymentsRequiringExtraProcessing failed: unknown result");
658
    }
659
 
660
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException
661
    {
662
      send_markPaymentAsProcessed(paymentId, category);
663
      recv_markPaymentAsProcessed();
664
    }
665
 
666
    public void send_markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category) throws org.apache.thrift.TException
667
    {
668
      markPaymentAsProcessed_args args = new markPaymentAsProcessed_args();
669
      args.setPaymentId(paymentId);
670
      args.setCategory(category);
671
      sendBase("markPaymentAsProcessed", args);
672
    }
673
 
674
    public void recv_markPaymentAsProcessed() throws org.apache.thrift.TException
675
    {
676
      markPaymentAsProcessed_result result = new markPaymentAsProcessed_result();
677
      receiveBase(result, "markPaymentAsProcessed");
678
      return;
679
    }
680
 
123 ashish 681
  }
3430 rajveer 682
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
683
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
684
      private org.apache.thrift.async.TAsyncClientManager clientManager;
685
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
686
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
687
        this.clientManager = clientManager;
688
        this.protocolFactory = protocolFactory;
689
      }
690
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
691
        return new AsyncClient(protocolFactory, clientManager, transport);
692
      }
123 ashish 693
    }
694
 
3430 rajveer 695
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
696
      super(protocolFactory, clientManager, transport);
697
    }
123 ashish 698
 
3430 rajveer 699
    public void createPayment(long userId, double amount, long gatewayId, long txnId, org.apache.thrift.async.AsyncMethodCallback<createPayment_call> resultHandler) throws org.apache.thrift.TException {
700
      checkReady();
701
      createPayment_call method_call = new createPayment_call(userId, amount, gatewayId, txnId, resultHandler, this, ___protocolFactory, ___transport);
702
      this.___currentMethod = method_call;
703
      ___manager.call(method_call);
704
    }
705
 
706
    public static class createPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
707
      private long userId;
708
      private double amount;
709
      private long gatewayId;
710
      private long txnId;
711
      public createPayment_call(long userId, double amount, long gatewayId, long txnId, 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 {
712
        super(client, protocolFactory, transport, resultHandler, false);
713
        this.userId = userId;
714
        this.amount = amount;
715
        this.gatewayId = gatewayId;
716
        this.txnId = txnId;
123 ashish 717
      }
3430 rajveer 718
 
719
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
720
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
721
        createPayment_args args = new createPayment_args();
722
        args.setUserId(userId);
723
        args.setAmount(amount);
724
        args.setGatewayId(gatewayId);
725
        args.setTxnId(txnId);
726
        args.write(prot);
727
        prot.writeMessageEnd();
728
      }
729
 
730
      public long getResult() throws PaymentException, org.apache.thrift.TException {
731
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
732
          throw new IllegalStateException("Method call not finished!");
733
        }
734
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
735
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
736
        return (new Client(prot)).recv_createPayment();
737
      }
123 ashish 738
    }
739
 
3430 rajveer 740
    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 {
741
      checkReady();
742
      getPaymentsForUser_call method_call = new getPaymentsForUser_call(userId, fromTime, toTime, status, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
743
      this.___currentMethod = method_call;
744
      ___manager.call(method_call);
745
    }
746
 
747
    public static class getPaymentsForUser_call extends org.apache.thrift.async.TAsyncMethodCall {
748
      private long userId;
749
      private long fromTime;
750
      private long toTime;
751
      private PaymentStatus status;
752
      private long gatewayId;
753
      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 {
754
        super(client, protocolFactory, transport, resultHandler, false);
755
        this.userId = userId;
756
        this.fromTime = fromTime;
757
        this.toTime = toTime;
758
        this.status = status;
759
        this.gatewayId = gatewayId;
760
      }
761
 
762
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
763
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsForUser", org.apache.thrift.protocol.TMessageType.CALL, 0));
764
        getPaymentsForUser_args args = new getPaymentsForUser_args();
765
        args.setUserId(userId);
766
        args.setFromTime(fromTime);
767
        args.setToTime(toTime);
768
        args.setStatus(status);
769
        args.setGatewayId(gatewayId);
770
        args.write(prot);
771
        prot.writeMessageEnd();
772
      }
773
 
774
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
775
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
776
          throw new IllegalStateException("Method call not finished!");
777
        }
778
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
779
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
780
        return (new Client(prot)).recv_getPaymentsForUser();
781
      }
782
    }
783
 
784
    public void getPayments(long fromTime, long toTime, PaymentStatus status, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPayments_call> resultHandler) throws org.apache.thrift.TException {
785
      checkReady();
786
      getPayments_call method_call = new getPayments_call(fromTime, toTime, status, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
787
      this.___currentMethod = method_call;
788
      ___manager.call(method_call);
789
    }
790
 
791
    public static class getPayments_call extends org.apache.thrift.async.TAsyncMethodCall {
792
      private long fromTime;
793
      private long toTime;
794
      private PaymentStatus status;
795
      private long gatewayId;
796
      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 {
797
        super(client, protocolFactory, transport, resultHandler, false);
798
        this.fromTime = fromTime;
799
        this.toTime = toTime;
800
        this.status = status;
801
        this.gatewayId = gatewayId;
802
      }
803
 
804
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
805
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPayments", org.apache.thrift.protocol.TMessageType.CALL, 0));
806
        getPayments_args args = new getPayments_args();
807
        args.setFromTime(fromTime);
808
        args.setToTime(toTime);
809
        args.setStatus(status);
810
        args.setGatewayId(gatewayId);
811
        args.write(prot);
812
        prot.writeMessageEnd();
813
      }
814
 
815
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
816
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
817
          throw new IllegalStateException("Method call not finished!");
818
        }
819
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
820
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
821
        return (new Client(prot)).recv_getPayments();
822
      }
823
    }
824
 
4141 chandransh 825
    public void getPaymentsByCapturedDate(long fromTime, long toTime, long gatewayId, org.apache.thrift.async.AsyncMethodCallback<getPaymentsByCapturedDate_call> resultHandler) throws org.apache.thrift.TException {
826
      checkReady();
827
      getPaymentsByCapturedDate_call method_call = new getPaymentsByCapturedDate_call(fromTime, toTime, gatewayId, resultHandler, this, ___protocolFactory, ___transport);
828
      this.___currentMethod = method_call;
829
      ___manager.call(method_call);
830
    }
831
 
832
    public static class getPaymentsByCapturedDate_call extends org.apache.thrift.async.TAsyncMethodCall {
833
      private long fromTime;
834
      private long toTime;
835
      private long gatewayId;
836
      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 {
837
        super(client, protocolFactory, transport, resultHandler, false);
838
        this.fromTime = fromTime;
839
        this.toTime = toTime;
840
        this.gatewayId = gatewayId;
841
      }
842
 
843
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
844
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsByCapturedDate", org.apache.thrift.protocol.TMessageType.CALL, 0));
845
        getPaymentsByCapturedDate_args args = new getPaymentsByCapturedDate_args();
846
        args.setFromTime(fromTime);
847
        args.setToTime(toTime);
848
        args.setGatewayId(gatewayId);
849
        args.write(prot);
850
        prot.writeMessageEnd();
851
      }
852
 
853
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
854
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
855
          throw new IllegalStateException("Method call not finished!");
856
        }
857
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
858
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
859
        return (new Client(prot)).recv_getPaymentsByCapturedDate();
860
      }
861
    }
862
 
3430 rajveer 863
    public void getPaymentGateway(long id, org.apache.thrift.async.AsyncMethodCallback<getPaymentGateway_call> resultHandler) throws org.apache.thrift.TException {
864
      checkReady();
865
      getPaymentGateway_call method_call = new getPaymentGateway_call(id, resultHandler, this, ___protocolFactory, ___transport);
866
      this.___currentMethod = method_call;
867
      ___manager.call(method_call);
868
    }
869
 
870
    public static class getPaymentGateway_call extends org.apache.thrift.async.TAsyncMethodCall {
871
      private long id;
872
      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 {
873
        super(client, protocolFactory, transport, resultHandler, false);
874
        this.id = id;
875
      }
876
 
877
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
878
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentGateway", org.apache.thrift.protocol.TMessageType.CALL, 0));
879
        getPaymentGateway_args args = new getPaymentGateway_args();
880
        args.setId(id);
881
        args.write(prot);
882
        prot.writeMessageEnd();
883
      }
884
 
885
      public PaymentGateway getResult() throws PaymentException, org.apache.thrift.TException {
886
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
887
          throw new IllegalStateException("Method call not finished!");
888
        }
889
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
890
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
891
        return (new Client(prot)).recv_getPaymentGateway();
892
      }
893
    }
894
 
895
    public void getPayment(long id, org.apache.thrift.async.AsyncMethodCallback<getPayment_call> resultHandler) throws org.apache.thrift.TException {
896
      checkReady();
897
      getPayment_call method_call = new getPayment_call(id, resultHandler, this, ___protocolFactory, ___transport);
898
      this.___currentMethod = method_call;
899
      ___manager.call(method_call);
900
    }
901
 
902
    public static class getPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
903
      private long id;
904
      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 {
905
        super(client, protocolFactory, transport, resultHandler, false);
906
        this.id = id;
907
      }
908
 
909
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
910
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
911
        getPayment_args args = new getPayment_args();
912
        args.setId(id);
913
        args.write(prot);
914
        prot.writeMessageEnd();
915
      }
916
 
917
      public Payment getResult() throws PaymentException, org.apache.thrift.TException {
918
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
919
          throw new IllegalStateException("Method call not finished!");
920
        }
921
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
922
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
923
        return (new Client(prot)).recv_getPayment();
924
      }
925
    }
926
 
927
    public void getPaymentForTxnId(long txnId, org.apache.thrift.async.AsyncMethodCallback<getPaymentForTxnId_call> resultHandler) throws org.apache.thrift.TException {
928
      checkReady();
929
      getPaymentForTxnId_call method_call = new getPaymentForTxnId_call(txnId, resultHandler, this, ___protocolFactory, ___transport);
930
      this.___currentMethod = method_call;
931
      ___manager.call(method_call);
932
    }
933
 
934
    public static class getPaymentForTxnId_call extends org.apache.thrift.async.TAsyncMethodCall {
935
      private long txnId;
936
      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 {
937
        super(client, protocolFactory, transport, resultHandler, false);
938
        this.txnId = txnId;
939
      }
940
 
941
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
942
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentForTxnId", org.apache.thrift.protocol.TMessageType.CALL, 0));
943
        getPaymentForTxnId_args args = new getPaymentForTxnId_args();
944
        args.setTxnId(txnId);
945
        args.write(prot);
946
        prot.writeMessageEnd();
947
      }
948
 
949
      public List<Payment> getResult() throws PaymentException, org.apache.thrift.TException {
950
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
951
          throw new IllegalStateException("Method call not finished!");
952
        }
953
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
954
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
955
        return (new Client(prot)).recv_getPaymentForTxnId();
956
      }
957
    }
958
 
959
    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 {
960
      checkReady();
961
      updatePaymentDetails_call method_call = new updatePaymentDetails_call(id, gatewayPaymentId, sessionId, gatewayTxnStatus, description, gatewayTxnId, authCode, referenceCode, errorCode, status, gatewayTxnDate, attributes, resultHandler, this, ___protocolFactory, ___transport);
962
      this.___currentMethod = method_call;
963
      ___manager.call(method_call);
964
    }
965
 
966
    public static class updatePaymentDetails_call extends org.apache.thrift.async.TAsyncMethodCall {
967
      private long id;
968
      private String gatewayPaymentId;
969
      private String sessionId;
970
      private String gatewayTxnStatus;
971
      private String description;
972
      private String gatewayTxnId;
973
      private String authCode;
974
      private String referenceCode;
975
      private String errorCode;
976
      private PaymentStatus status;
977
      private String gatewayTxnDate;
978
      private List<Attribute> attributes;
979
      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 {
980
        super(client, protocolFactory, transport, resultHandler, false);
981
        this.id = id;
982
        this.gatewayPaymentId = gatewayPaymentId;
983
        this.sessionId = sessionId;
984
        this.gatewayTxnStatus = gatewayTxnStatus;
985
        this.description = description;
986
        this.gatewayTxnId = gatewayTxnId;
987
        this.authCode = authCode;
988
        this.referenceCode = referenceCode;
989
        this.errorCode = errorCode;
990
        this.status = status;
991
        this.gatewayTxnDate = gatewayTxnDate;
992
        this.attributes = attributes;
993
      }
994
 
995
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
996
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updatePaymentDetails", org.apache.thrift.protocol.TMessageType.CALL, 0));
997
        updatePaymentDetails_args args = new updatePaymentDetails_args();
998
        args.setId(id);
999
        args.setGatewayPaymentId(gatewayPaymentId);
1000
        args.setSessionId(sessionId);
1001
        args.setGatewayTxnStatus(gatewayTxnStatus);
1002
        args.setDescription(description);
1003
        args.setGatewayTxnId(gatewayTxnId);
1004
        args.setAuthCode(authCode);
1005
        args.setReferenceCode(referenceCode);
1006
        args.setErrorCode(errorCode);
1007
        args.setStatus(status);
1008
        args.setGatewayTxnDate(gatewayTxnDate);
1009
        args.setAttributes(attributes);
1010
        args.write(prot);
1011
        prot.writeMessageEnd();
1012
      }
1013
 
1014
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1015
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1016
          throw new IllegalStateException("Method call not finished!");
1017
        }
1018
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1019
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1020
        return (new Client(prot)).recv_updatePaymentDetails();
1021
      }
1022
    }
1023
 
1024
    public void getSuccessfulPaymentsAmountRange(org.apache.thrift.async.AsyncMethodCallback<getSuccessfulPaymentsAmountRange_call> resultHandler) throws org.apache.thrift.TException {
1025
      checkReady();
1026
      getSuccessfulPaymentsAmountRange_call method_call = new getSuccessfulPaymentsAmountRange_call(resultHandler, this, ___protocolFactory, ___transport);
1027
      this.___currentMethod = method_call;
1028
      ___manager.call(method_call);
1029
    }
1030
 
1031
    public static class getSuccessfulPaymentsAmountRange_call extends org.apache.thrift.async.TAsyncMethodCall {
1032
      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 {
1033
        super(client, protocolFactory, transport, resultHandler, false);
1034
      }
1035
 
1036
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1037
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getSuccessfulPaymentsAmountRange", org.apache.thrift.protocol.TMessageType.CALL, 0));
1038
        getSuccessfulPaymentsAmountRange_args args = new getSuccessfulPaymentsAmountRange_args();
1039
        args.write(prot);
1040
        prot.writeMessageEnd();
1041
      }
1042
 
1043
      public List<Double> getResult() throws org.apache.thrift.TException {
1044
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1045
          throw new IllegalStateException("Method call not finished!");
1046
        }
1047
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1048
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1049
        return (new Client(prot)).recv_getSuccessfulPaymentsAmountRange();
1050
      }
1051
    }
1052
 
1053
    public void initializeHdfcPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcPayment_call> resultHandler) throws org.apache.thrift.TException {
1054
      checkReady();
1055
      initializeHdfcPayment_call method_call = new initializeHdfcPayment_call(merchantPaymentId, resultHandler, this, ___protocolFactory, ___transport);
1056
      this.___currentMethod = method_call;
1057
      ___manager.call(method_call);
1058
    }
1059
 
1060
    public static class initializeHdfcPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1061
      private long merchantPaymentId;
1062
      public initializeHdfcPayment_call(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcPayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1063
        super(client, protocolFactory, transport, resultHandler, false);
1064
        this.merchantPaymentId = merchantPaymentId;
1065
      }
1066
 
1067
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1068
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("initializeHdfcPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1069
        initializeHdfcPayment_args args = new initializeHdfcPayment_args();
1070
        args.setMerchantPaymentId(merchantPaymentId);
1071
        args.write(prot);
1072
        prot.writeMessageEnd();
1073
      }
1074
 
1075
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1076
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1077
          throw new IllegalStateException("Method call not finished!");
1078
        }
1079
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1080
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1081
        return (new Client(prot)).recv_initializeHdfcPayment();
1082
      }
1083
    }
1084
 
3616 chandransh 1085
    public void initializeHdfcEmiPayment(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcEmiPayment_call> resultHandler) throws org.apache.thrift.TException {
1086
      checkReady();
1087
      initializeHdfcEmiPayment_call method_call = new initializeHdfcEmiPayment_call(merchantPaymentId, resultHandler, this, ___protocolFactory, ___transport);
1088
      this.___currentMethod = method_call;
1089
      ___manager.call(method_call);
1090
    }
1091
 
1092
    public static class initializeHdfcEmiPayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1093
      private long merchantPaymentId;
1094
      public initializeHdfcEmiPayment_call(long merchantPaymentId, org.apache.thrift.async.AsyncMethodCallback<initializeHdfcEmiPayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1095
        super(client, protocolFactory, transport, resultHandler, false);
1096
        this.merchantPaymentId = merchantPaymentId;
1097
      }
1098
 
1099
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1100
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("initializeHdfcEmiPayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1101
        initializeHdfcEmiPayment_args args = new initializeHdfcEmiPayment_args();
1102
        args.setMerchantPaymentId(merchantPaymentId);
1103
        args.write(prot);
1104
        prot.writeMessageEnd();
1105
      }
1106
 
1107
      public String getResult() throws PaymentException, org.apache.thrift.TException {
1108
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1109
          throw new IllegalStateException("Method call not finished!");
1110
        }
1111
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1112
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1113
        return (new Client(prot)).recv_initializeHdfcEmiPayment();
1114
      }
1115
    }
1116
 
3430 rajveer 1117
    public void createRefund(long orderId, long merchantTxnId, double amount, org.apache.thrift.async.AsyncMethodCallback<createRefund_call> resultHandler) throws org.apache.thrift.TException {
1118
      checkReady();
1119
      createRefund_call method_call = new createRefund_call(orderId, merchantTxnId, amount, resultHandler, this, ___protocolFactory, ___transport);
1120
      this.___currentMethod = method_call;
1121
      ___manager.call(method_call);
1122
    }
1123
 
1124
    public static class createRefund_call extends org.apache.thrift.async.TAsyncMethodCall {
1125
      private long orderId;
1126
      private long merchantTxnId;
1127
      private double amount;
1128
      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 {
1129
        super(client, protocolFactory, transport, resultHandler, false);
1130
        this.orderId = orderId;
1131
        this.merchantTxnId = merchantTxnId;
1132
        this.amount = amount;
1133
      }
1134
 
1135
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1136
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createRefund", org.apache.thrift.protocol.TMessageType.CALL, 0));
1137
        createRefund_args args = new createRefund_args();
1138
        args.setOrderId(orderId);
1139
        args.setMerchantTxnId(merchantTxnId);
1140
        args.setAmount(amount);
1141
        args.write(prot);
1142
        prot.writeMessageEnd();
1143
      }
1144
 
1145
      public long getResult() throws PaymentException, org.apache.thrift.TException {
1146
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1147
          throw new IllegalStateException("Method call not finished!");
1148
        }
1149
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1150
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1151
        return (new Client(prot)).recv_createRefund();
1152
      }
1153
    }
1154
 
1155
    public void capturePayment(long merchantTxnId, org.apache.thrift.async.AsyncMethodCallback<capturePayment_call> resultHandler) throws org.apache.thrift.TException {
1156
      checkReady();
1157
      capturePayment_call method_call = new capturePayment_call(merchantTxnId, resultHandler, this, ___protocolFactory, ___transport);
1158
      this.___currentMethod = method_call;
1159
      ___manager.call(method_call);
1160
    }
1161
 
1162
    public static class capturePayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1163
      private long merchantTxnId;
1164
      public capturePayment_call(long merchantTxnId, org.apache.thrift.async.AsyncMethodCallback<capturePayment_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1165
        super(client, protocolFactory, transport, resultHandler, false);
1166
        this.merchantTxnId = merchantTxnId;
1167
      }
1168
 
1169
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1170
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("capturePayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1171
        capturePayment_args args = new capturePayment_args();
1172
        args.setMerchantTxnId(merchantTxnId);
1173
        args.write(prot);
1174
        prot.writeMessageEnd();
1175
      }
1176
 
1177
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1178
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1179
          throw new IllegalStateException("Method call not finished!");
1180
        }
1181
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1182
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1183
        return (new Client(prot)).recv_capturePayment();
1184
      }
1185
    }
1186
 
3956 chandransh 1187
    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 {
1188
      checkReady();
1189
      partiallyCapturePayment_call method_call = new partiallyCapturePayment_call(merchantTxnId, amount, xferBy, xferTxnId, xferDate, resultHandler, this, ___protocolFactory, ___transport);
1190
      this.___currentMethod = method_call;
1191
      ___manager.call(method_call);
1192
    }
1193
 
1194
    public static class partiallyCapturePayment_call extends org.apache.thrift.async.TAsyncMethodCall {
1195
      private long merchantTxnId;
1196
      private double amount;
1197
      private String xferBy;
1198
      private String xferTxnId;
1199
      private long xferDate;
1200
      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 {
1201
        super(client, protocolFactory, transport, resultHandler, false);
1202
        this.merchantTxnId = merchantTxnId;
1203
        this.amount = amount;
1204
        this.xferBy = xferBy;
1205
        this.xferTxnId = xferTxnId;
1206
        this.xferDate = xferDate;
1207
      }
1208
 
1209
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1210
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("partiallyCapturePayment", org.apache.thrift.protocol.TMessageType.CALL, 0));
1211
        partiallyCapturePayment_args args = new partiallyCapturePayment_args();
1212
        args.setMerchantTxnId(merchantTxnId);
1213
        args.setAmount(amount);
1214
        args.setXferBy(xferBy);
1215
        args.setXferTxnId(xferTxnId);
1216
        args.setXferDate(xferDate);
1217
        args.write(prot);
1218
        prot.writeMessageEnd();
1219
      }
1220
 
1221
      public boolean getResult() throws PaymentException, org.apache.thrift.TException {
1222
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1223
          throw new IllegalStateException("Method call not finished!");
1224
        }
1225
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1226
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1227
        return (new Client(prot)).recv_partiallyCapturePayment();
1228
      }
1229
    }
1230
 
4008 mandeep.dh 1231
    public void getPaymentsRequiringExtraProcessing(ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<getPaymentsRequiringExtraProcessing_call> resultHandler) throws org.apache.thrift.TException {
1232
      checkReady();
1233
      getPaymentsRequiringExtraProcessing_call method_call = new getPaymentsRequiringExtraProcessing_call(category, resultHandler, this, ___protocolFactory, ___transport);
1234
      this.___currentMethod = method_call;
1235
      ___manager.call(method_call);
1236
    }
1237
 
1238
    public static class getPaymentsRequiringExtraProcessing_call extends org.apache.thrift.async.TAsyncMethodCall {
1239
      private ExtraPaymentProcessingType category;
1240
      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 {
1241
        super(client, protocolFactory, transport, resultHandler, false);
1242
        this.category = category;
1243
      }
1244
 
1245
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1246
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPaymentsRequiringExtraProcessing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1247
        getPaymentsRequiringExtraProcessing_args args = new getPaymentsRequiringExtraProcessing_args();
1248
        args.setCategory(category);
1249
        args.write(prot);
1250
        prot.writeMessageEnd();
1251
      }
1252
 
1253
      public List<Long> getResult() throws org.apache.thrift.TException {
1254
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1255
          throw new IllegalStateException("Method call not finished!");
1256
        }
1257
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1258
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1259
        return (new Client(prot)).recv_getPaymentsRequiringExtraProcessing();
1260
      }
1261
    }
1262
 
1263
    public void markPaymentAsProcessed(long paymentId, ExtraPaymentProcessingType category, org.apache.thrift.async.AsyncMethodCallback<markPaymentAsProcessed_call> resultHandler) throws org.apache.thrift.TException {
1264
      checkReady();
1265
      markPaymentAsProcessed_call method_call = new markPaymentAsProcessed_call(paymentId, category, resultHandler, this, ___protocolFactory, ___transport);
1266
      this.___currentMethod = method_call;
1267
      ___manager.call(method_call);
1268
    }
1269
 
1270
    public static class markPaymentAsProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
1271
      private long paymentId;
1272
      private ExtraPaymentProcessingType category;
1273
      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 {
1274
        super(client, protocolFactory, transport, resultHandler, false);
1275
        this.paymentId = paymentId;
1276
        this.category = category;
1277
      }
1278
 
1279
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1280
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("markPaymentAsProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
1281
        markPaymentAsProcessed_args args = new markPaymentAsProcessed_args();
1282
        args.setPaymentId(paymentId);
1283
        args.setCategory(category);
1284
        args.write(prot);
1285
        prot.writeMessageEnd();
1286
      }
1287
 
1288
      public void getResult() throws org.apache.thrift.TException {
1289
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1290
          throw new IllegalStateException("Method call not finished!");
1291
        }
1292
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1293
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1294
        (new Client(prot)).recv_markPaymentAsProcessed();
1295
      }
1296
    }
1297
 
3430 rajveer 1298
  }
1299
 
1300
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
1301
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
1302
    public Processor(I iface) {
1303
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
1304
    }
1305
 
1306
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
1307
      super(iface, getProcessMap(processMap));
1308
    }
1309
 
1310
    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) {
1311
      processMap.put("createPayment", new createPayment());
1312
      processMap.put("getPaymentsForUser", new getPaymentsForUser());
1313
      processMap.put("getPayments", new getPayments());
4141 chandransh 1314
      processMap.put("getPaymentsByCapturedDate", new getPaymentsByCapturedDate());
3430 rajveer 1315
      processMap.put("getPaymentGateway", new getPaymentGateway());
1316
      processMap.put("getPayment", new getPayment());
1317
      processMap.put("getPaymentForTxnId", new getPaymentForTxnId());
1318
      processMap.put("updatePaymentDetails", new updatePaymentDetails());
1319
      processMap.put("getSuccessfulPaymentsAmountRange", new getSuccessfulPaymentsAmountRange());
1320
      processMap.put("initializeHdfcPayment", new initializeHdfcPayment());
3616 chandransh 1321
      processMap.put("initializeHdfcEmiPayment", new initializeHdfcEmiPayment());
3430 rajveer 1322
      processMap.put("createRefund", new createRefund());
1323
      processMap.put("capturePayment", new capturePayment());
3956 chandransh 1324
      processMap.put("partiallyCapturePayment", new partiallyCapturePayment());
4008 mandeep.dh 1325
      processMap.put("getPaymentsRequiringExtraProcessing", new getPaymentsRequiringExtraProcessing());
1326
      processMap.put("markPaymentAsProcessed", new markPaymentAsProcessed());
3430 rajveer 1327
      return processMap;
1328
    }
1329
 
1330
    private static class createPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createPayment_args> {
1331
      public createPayment() {
1332
        super("createPayment");
1333
      }
1334
 
1335
      protected createPayment_args getEmptyArgsInstance() {
1336
        return new createPayment_args();
1337
      }
1338
 
1339
      protected createPayment_result getResult(I iface, createPayment_args args) throws org.apache.thrift.TException {
123 ashish 1340
        createPayment_result result = new createPayment_result();
1341
        try {
3430 rajveer 1342
          result.success = iface.createPayment(args.userId, args.amount, args.gatewayId, args.txnId);
420 ashish 1343
          result.setSuccessIsSet(true);
123 ashish 1344
        } catch (PaymentException pe) {
1345
          result.pe = pe;
1346
        }
3430 rajveer 1347
        return result;
123 ashish 1348
      }
1349
    }
1350
 
3430 rajveer 1351
    private static class getPaymentsForUser<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsForUser_args> {
1352
      public getPaymentsForUser() {
1353
        super("getPaymentsForUser");
1354
      }
1355
 
1356
      protected getPaymentsForUser_args getEmptyArgsInstance() {
1357
        return new getPaymentsForUser_args();
1358
      }
1359
 
1360
      protected getPaymentsForUser_result getResult(I iface, getPaymentsForUser_args args) throws org.apache.thrift.TException {
123 ashish 1361
        getPaymentsForUser_result result = new getPaymentsForUser_result();
1362
        try {
3430 rajveer 1363
          result.success = iface.getPaymentsForUser(args.userId, args.fromTime, args.toTime, args.status, args.gatewayId);
123 ashish 1364
        } catch (PaymentException pe) {
1365
          result.pe = pe;
1366
        }
3430 rajveer 1367
        return result;
123 ashish 1368
      }
1369
    }
1370
 
3430 rajveer 1371
    private static class getPayments<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPayments_args> {
1372
      public getPayments() {
1373
        super("getPayments");
1374
      }
1375
 
1376
      protected getPayments_args getEmptyArgsInstance() {
1377
        return new getPayments_args();
1378
      }
1379
 
1380
      protected getPayments_result getResult(I iface, getPayments_args args) throws org.apache.thrift.TException {
123 ashish 1381
        getPayments_result result = new getPayments_result();
1382
        try {
3430 rajveer 1383
          result.success = iface.getPayments(args.fromTime, args.toTime, args.status, args.gatewayId);
123 ashish 1384
        } catch (PaymentException pe) {
1385
          result.pe = pe;
1386
        }
3430 rajveer 1387
        return result;
123 ashish 1388
      }
1389
    }
1390
 
4141 chandransh 1391
    private static class getPaymentsByCapturedDate<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsByCapturedDate_args> {
1392
      public getPaymentsByCapturedDate() {
1393
        super("getPaymentsByCapturedDate");
1394
      }
1395
 
1396
      protected getPaymentsByCapturedDate_args getEmptyArgsInstance() {
1397
        return new getPaymentsByCapturedDate_args();
1398
      }
1399
 
1400
      protected getPaymentsByCapturedDate_result getResult(I iface, getPaymentsByCapturedDate_args args) throws org.apache.thrift.TException {
1401
        getPaymentsByCapturedDate_result result = new getPaymentsByCapturedDate_result();
1402
        try {
1403
          result.success = iface.getPaymentsByCapturedDate(args.fromTime, args.toTime, args.gatewayId);
1404
        } catch (PaymentException pe) {
1405
          result.pe = pe;
1406
        }
1407
        return result;
1408
      }
1409
    }
1410
 
3430 rajveer 1411
    private static class getPaymentGateway<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentGateway_args> {
1412
      public getPaymentGateway() {
1413
        super("getPaymentGateway");
1414
      }
1415
 
1416
      protected getPaymentGateway_args getEmptyArgsInstance() {
1417
        return new getPaymentGateway_args();
1418
      }
1419
 
1420
      protected getPaymentGateway_result getResult(I iface, getPaymentGateway_args args) throws org.apache.thrift.TException {
420 ashish 1421
        getPaymentGateway_result result = new getPaymentGateway_result();
1422
        try {
3430 rajveer 1423
          result.success = iface.getPaymentGateway(args.id);
420 ashish 1424
        } catch (PaymentException pe) {
1425
          result.pe = pe;
1426
        }
3430 rajveer 1427
        return result;
420 ashish 1428
      }
1429
    }
1430
 
3430 rajveer 1431
    private static class getPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPayment_args> {
1432
      public getPayment() {
1433
        super("getPayment");
1434
      }
1435
 
1436
      protected getPayment_args getEmptyArgsInstance() {
1437
        return new getPayment_args();
1438
      }
1439
 
1440
      protected getPayment_result getResult(I iface, getPayment_args args) throws org.apache.thrift.TException {
695 rajveer 1441
        getPayment_result result = new getPayment_result();
420 ashish 1442
        try {
3430 rajveer 1443
          result.success = iface.getPayment(args.id);
420 ashish 1444
        } catch (PaymentException pe) {
1445
          result.pe = pe;
1446
        }
3430 rajveer 1447
        return result;
420 ashish 1448
      }
1449
    }
1450
 
3430 rajveer 1451
    private static class getPaymentForTxnId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentForTxnId_args> {
1452
      public getPaymentForTxnId() {
1453
        super("getPaymentForTxnId");
1454
      }
1455
 
1456
      protected getPaymentForTxnId_args getEmptyArgsInstance() {
1457
        return new getPaymentForTxnId_args();
1458
      }
1459
 
1460
      protected getPaymentForTxnId_result getResult(I iface, getPaymentForTxnId_args args) throws org.apache.thrift.TException {
695 rajveer 1461
        getPaymentForTxnId_result result = new getPaymentForTxnId_result();
420 ashish 1462
        try {
3430 rajveer 1463
          result.success = iface.getPaymentForTxnId(args.txnId);
420 ashish 1464
        } catch (PaymentException pe) {
1465
          result.pe = pe;
1466
        }
3430 rajveer 1467
        return result;
420 ashish 1468
      }
1469
    }
1470
 
3430 rajveer 1471
    private static class updatePaymentDetails<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updatePaymentDetails_args> {
1472
      public updatePaymentDetails() {
1473
        super("updatePaymentDetails");
1474
      }
1475
 
1476
      protected updatePaymentDetails_args getEmptyArgsInstance() {
1477
        return new updatePaymentDetails_args();
1478
      }
1479
 
1480
      protected updatePaymentDetails_result getResult(I iface, updatePaymentDetails_args args) throws org.apache.thrift.TException {
695 rajveer 1481
        updatePaymentDetails_result result = new updatePaymentDetails_result();
420 ashish 1482
        try {
3430 rajveer 1483
          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 1484
          result.setSuccessIsSet(true);
420 ashish 1485
        } catch (PaymentException pe) {
1486
          result.pe = pe;
1487
        }
3430 rajveer 1488
        return result;
420 ashish 1489
      }
1490
    }
1491
 
3430 rajveer 1492
    private static class getSuccessfulPaymentsAmountRange<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getSuccessfulPaymentsAmountRange_args> {
1493
      public getSuccessfulPaymentsAmountRange() {
1494
        super("getSuccessfulPaymentsAmountRange");
1495
      }
1496
 
1497
      protected getSuccessfulPaymentsAmountRange_args getEmptyArgsInstance() {
1498
        return new getSuccessfulPaymentsAmountRange_args();
1499
      }
1500
 
1501
      protected getSuccessfulPaymentsAmountRange_result getResult(I iface, getSuccessfulPaymentsAmountRange_args args) throws org.apache.thrift.TException {
1731 ankur.sing 1502
        getSuccessfulPaymentsAmountRange_result result = new getSuccessfulPaymentsAmountRange_result();
3430 rajveer 1503
        result.success = iface.getSuccessfulPaymentsAmountRange();
1504
        return result;
1629 ankur.sing 1505
      }
1506
    }
1507
 
3430 rajveer 1508
    private static class initializeHdfcPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, initializeHdfcPayment_args> {
1509
      public initializeHdfcPayment() {
1510
        super("initializeHdfcPayment");
1511
      }
1512
 
1513
      protected initializeHdfcPayment_args getEmptyArgsInstance() {
1514
        return new initializeHdfcPayment_args();
1515
      }
1516
 
1517
      protected initializeHdfcPayment_result getResult(I iface, initializeHdfcPayment_args args) throws org.apache.thrift.TException {
2462 chandransh 1518
        initializeHdfcPayment_result result = new initializeHdfcPayment_result();
1519
        try {
3430 rajveer 1520
          result.success = iface.initializeHdfcPayment(args.merchantPaymentId);
2462 chandransh 1521
        } catch (PaymentException pe) {
1522
          result.pe = pe;
1523
        }
3430 rajveer 1524
        return result;
2462 chandransh 1525
      }
1526
    }
1527
 
3616 chandransh 1528
    private static class initializeHdfcEmiPayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, initializeHdfcEmiPayment_args> {
1529
      public initializeHdfcEmiPayment() {
1530
        super("initializeHdfcEmiPayment");
1531
      }
1532
 
1533
      protected initializeHdfcEmiPayment_args getEmptyArgsInstance() {
1534
        return new initializeHdfcEmiPayment_args();
1535
      }
1536
 
1537
      protected initializeHdfcEmiPayment_result getResult(I iface, initializeHdfcEmiPayment_args args) throws org.apache.thrift.TException {
1538
        initializeHdfcEmiPayment_result result = new initializeHdfcEmiPayment_result();
1539
        try {
1540
          result.success = iface.initializeHdfcEmiPayment(args.merchantPaymentId);
1541
        } catch (PaymentException pe) {
1542
          result.pe = pe;
1543
        }
1544
        return result;
1545
      }
1546
    }
1547
 
3430 rajveer 1548
    private static class createRefund<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createRefund_args> {
1549
      public createRefund() {
1550
        super("createRefund");
1551
      }
1552
 
1553
      protected createRefund_args getEmptyArgsInstance() {
1554
        return new createRefund_args();
1555
      }
1556
 
1557
      protected createRefund_result getResult(I iface, createRefund_args args) throws org.apache.thrift.TException {
2690 chandransh 1558
        createRefund_result result = new createRefund_result();
1559
        try {
3430 rajveer 1560
          result.success = iface.createRefund(args.orderId, args.merchantTxnId, args.amount);
2690 chandransh 1561
          result.setSuccessIsSet(true);
1562
        } catch (PaymentException pe) {
1563
          result.pe = pe;
1564
        }
3430 rajveer 1565
        return result;
2690 chandransh 1566
      }
1567
    }
1568
 
3430 rajveer 1569
    private static class capturePayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, capturePayment_args> {
1570
      public capturePayment() {
1571
        super("capturePayment");
1572
      }
1573
 
1574
      protected capturePayment_args getEmptyArgsInstance() {
1575
        return new capturePayment_args();
1576
      }
1577
 
1578
      protected capturePayment_result getResult(I iface, capturePayment_args args) throws org.apache.thrift.TException {
3010 chandransh 1579
        capturePayment_result result = new capturePayment_result();
1580
        try {
3430 rajveer 1581
          result.success = iface.capturePayment(args.merchantTxnId);
3010 chandransh 1582
          result.setSuccessIsSet(true);
1583
        } catch (PaymentException pe) {
1584
          result.pe = pe;
1585
        }
3430 rajveer 1586
        return result;
3010 chandransh 1587
      }
1588
    }
1589
 
3956 chandransh 1590
    private static class partiallyCapturePayment<I extends Iface> extends org.apache.thrift.ProcessFunction<I, partiallyCapturePayment_args> {
1591
      public partiallyCapturePayment() {
1592
        super("partiallyCapturePayment");
1593
      }
1594
 
1595
      protected partiallyCapturePayment_args getEmptyArgsInstance() {
1596
        return new partiallyCapturePayment_args();
1597
      }
1598
 
1599
      protected partiallyCapturePayment_result getResult(I iface, partiallyCapturePayment_args args) throws org.apache.thrift.TException {
1600
        partiallyCapturePayment_result result = new partiallyCapturePayment_result();
1601
        try {
1602
          result.success = iface.partiallyCapturePayment(args.merchantTxnId, args.amount, args.xferBy, args.xferTxnId, args.xferDate);
1603
          result.setSuccessIsSet(true);
1604
        } catch (PaymentException pe) {
1605
          result.pe = pe;
1606
        }
1607
        return result;
1608
      }
1609
    }
1610
 
4008 mandeep.dh 1611
    private static class getPaymentsRequiringExtraProcessing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPaymentsRequiringExtraProcessing_args> {
1612
      public getPaymentsRequiringExtraProcessing() {
1613
        super("getPaymentsRequiringExtraProcessing");
1614
      }
1615
 
1616
      protected getPaymentsRequiringExtraProcessing_args getEmptyArgsInstance() {
1617
        return new getPaymentsRequiringExtraProcessing_args();
1618
      }
1619
 
1620
      protected getPaymentsRequiringExtraProcessing_result getResult(I iface, getPaymentsRequiringExtraProcessing_args args) throws org.apache.thrift.TException {
1621
        getPaymentsRequiringExtraProcessing_result result = new getPaymentsRequiringExtraProcessing_result();
1622
        result.success = iface.getPaymentsRequiringExtraProcessing(args.category);
1623
        return result;
1624
      }
1625
    }
1626
 
1627
    private static class markPaymentAsProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, markPaymentAsProcessed_args> {
1628
      public markPaymentAsProcessed() {
1629
        super("markPaymentAsProcessed");
1630
      }
1631
 
1632
      protected markPaymentAsProcessed_args getEmptyArgsInstance() {
1633
        return new markPaymentAsProcessed_args();
1634
      }
1635
 
1636
      protected markPaymentAsProcessed_result getResult(I iface, markPaymentAsProcessed_args args) throws org.apache.thrift.TException {
1637
        markPaymentAsProcessed_result result = new markPaymentAsProcessed_result();
1638
        iface.markPaymentAsProcessed(args.paymentId, args.category);
1639
        return result;
1640
      }
1641
    }
1642
 
123 ashish 1643
  }
1644
 
3430 rajveer 1645
  public static class createPayment_args implements org.apache.thrift.TBase<createPayment_args, createPayment_args._Fields>, java.io.Serializable, Cloneable   {
1646
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPayment_args");
123 ashish 1647
 
3430 rajveer 1648
    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);
1649
    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);
1650
    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);
1651
    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);
123 ashish 1652
 
3430 rajveer 1653
    private long userId; // required
1654
    private double amount; // required
1655
    private long gatewayId; // required
1656
    private long txnId; // required
123 ashish 1657
 
1658
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 1659
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 1660
      USER_ID((short)1, "userId"),
1661
      AMOUNT((short)2, "amount"),
1662
      GATEWAY_ID((short)3, "gatewayId"),
1663
      TXN_ID((short)4, "txnId");
123 ashish 1664
 
1665
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1666
 
1667
      static {
1668
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1669
          byName.put(field.getFieldName(), field);
1670
        }
1671
      }
1672
 
1673
      /**
1674
       * Find the _Fields constant that matches fieldId, or null if its not found.
1675
       */
1676
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 1677
        switch(fieldId) {
1678
          case 1: // USER_ID
1679
            return USER_ID;
1680
          case 2: // AMOUNT
1681
            return AMOUNT;
1682
          case 3: // GATEWAY_ID
1683
            return GATEWAY_ID;
1684
          case 4: // TXN_ID
1685
            return TXN_ID;
1686
          default:
1687
            return null;
1688
        }
123 ashish 1689
      }
1690
 
1691
      /**
1692
       * Find the _Fields constant that matches fieldId, throwing an exception
1693
       * if it is not found.
1694
       */
1695
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1696
        _Fields fields = findByThriftId(fieldId);
1697
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1698
        return fields;
1699
      }
1700
 
1701
      /**
1702
       * Find the _Fields constant that matches name, or null if its not found.
1703
       */
1704
      public static _Fields findByName(String name) {
1705
        return byName.get(name);
1706
      }
1707
 
1708
      private final short _thriftId;
1709
      private final String _fieldName;
1710
 
1711
      _Fields(short thriftId, String fieldName) {
1712
        _thriftId = thriftId;
1713
        _fieldName = fieldName;
1714
      }
1715
 
1716
      public short getThriftFieldId() {
1717
        return _thriftId;
1718
      }
1719
 
1720
      public String getFieldName() {
1721
        return _fieldName;
1722
      }
1723
    }
1724
 
1725
    // isset id assignments
695 rajveer 1726
    private static final int __USERID_ISSET_ID = 0;
1727
    private static final int __AMOUNT_ISSET_ID = 1;
1728
    private static final int __GATEWAYID_ISSET_ID = 2;
1729
    private static final int __TXNID_ISSET_ID = 3;
420 ashish 1730
    private BitSet __isset_bit_vector = new BitSet(4);
123 ashish 1731
 
3430 rajveer 1732
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 1733
    static {
3430 rajveer 1734
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
1735
      tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1736
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
1737
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1738
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
1739
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1740
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
1741
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1742
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
1743
      metaDataMap = Collections.unmodifiableMap(tmpMap);
1744
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createPayment_args.class, metaDataMap);
123 ashish 1745
    }
1746
 
1747
    public createPayment_args() {
1748
    }
1749
 
1750
    public createPayment_args(
695 rajveer 1751
      long userId,
123 ashish 1752
      double amount,
695 rajveer 1753
      long gatewayId,
1754
      long txnId)
123 ashish 1755
    {
1756
      this();
695 rajveer 1757
      this.userId = userId;
1758
      setUserIdIsSet(true);
123 ashish 1759
      this.amount = amount;
1760
      setAmountIsSet(true);
695 rajveer 1761
      this.gatewayId = gatewayId;
1762
      setGatewayIdIsSet(true);
1763
      this.txnId = txnId;
1764
      setTxnIdIsSet(true);
123 ashish 1765
    }
1766
 
1767
    /**
1768
     * Performs a deep copy on <i>other</i>.
1769
     */
1770
    public createPayment_args(createPayment_args other) {
1771
      __isset_bit_vector.clear();
1772
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 1773
      this.userId = other.userId;
123 ashish 1774
      this.amount = other.amount;
695 rajveer 1775
      this.gatewayId = other.gatewayId;
1776
      this.txnId = other.txnId;
123 ashish 1777
    }
1778
 
1779
    public createPayment_args deepCopy() {
1780
      return new createPayment_args(this);
1781
    }
1782
 
3430 rajveer 1783
    @Override
1784
    public void clear() {
1785
      setUserIdIsSet(false);
1786
      this.userId = 0;
1787
      setAmountIsSet(false);
1788
      this.amount = 0.0;
1789
      setGatewayIdIsSet(false);
1790
      this.gatewayId = 0;
1791
      setTxnIdIsSet(false);
1792
      this.txnId = 0;
123 ashish 1793
    }
1794
 
695 rajveer 1795
    public long getUserId() {
1796
      return this.userId;
123 ashish 1797
    }
1798
 
3430 rajveer 1799
    public void setUserId(long userId) {
695 rajveer 1800
      this.userId = userId;
1801
      setUserIdIsSet(true);
123 ashish 1802
    }
1803
 
695 rajveer 1804
    public void unsetUserId() {
1805
      __isset_bit_vector.clear(__USERID_ISSET_ID);
123 ashish 1806
    }
1807
 
3430 rajveer 1808
    /** Returns true if field userId is set (has been assigned a value) and false otherwise */
695 rajveer 1809
    public boolean isSetUserId() {
1810
      return __isset_bit_vector.get(__USERID_ISSET_ID);
123 ashish 1811
    }
1812
 
695 rajveer 1813
    public void setUserIdIsSet(boolean value) {
1814
      __isset_bit_vector.set(__USERID_ISSET_ID, value);
123 ashish 1815
    }
1816
 
1817
    public double getAmount() {
1818
      return this.amount;
1819
    }
1820
 
3430 rajveer 1821
    public void setAmount(double amount) {
123 ashish 1822
      this.amount = amount;
1823
      setAmountIsSet(true);
1824
    }
1825
 
1826
    public void unsetAmount() {
1827
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
1828
    }
1829
 
3430 rajveer 1830
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
123 ashish 1831
    public boolean isSetAmount() {
1832
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
1833
    }
1834
 
1835
    public void setAmountIsSet(boolean value) {
1836
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
1837
    }
1838
 
695 rajveer 1839
    public long getGatewayId() {
1840
      return this.gatewayId;
123 ashish 1841
    }
1842
 
3430 rajveer 1843
    public void setGatewayId(long gatewayId) {
695 rajveer 1844
      this.gatewayId = gatewayId;
1845
      setGatewayIdIsSet(true);
123 ashish 1846
    }
1847
 
695 rajveer 1848
    public void unsetGatewayId() {
1849
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 1850
    }
1851
 
3430 rajveer 1852
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 1853
    public boolean isSetGatewayId() {
1854
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 1855
    }
1856
 
695 rajveer 1857
    public void setGatewayIdIsSet(boolean value) {
1858
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 1859
    }
1860
 
695 rajveer 1861
    public long getTxnId() {
1862
      return this.txnId;
1863
    }
1864
 
3430 rajveer 1865
    public void setTxnId(long txnId) {
695 rajveer 1866
      this.txnId = txnId;
1867
      setTxnIdIsSet(true);
1868
    }
1869
 
1870
    public void unsetTxnId() {
1871
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
1872
    }
1873
 
3430 rajveer 1874
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
695 rajveer 1875
    public boolean isSetTxnId() {
1876
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
1877
    }
1878
 
1879
    public void setTxnIdIsSet(boolean value) {
1880
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
1881
    }
1882
 
123 ashish 1883
    public void setFieldValue(_Fields field, Object value) {
1884
      switch (field) {
1885
      case USER_ID:
1886
        if (value == null) {
695 rajveer 1887
          unsetUserId();
123 ashish 1888
        } else {
695 rajveer 1889
          setUserId((Long)value);
123 ashish 1890
        }
1891
        break;
1892
 
695 rajveer 1893
      case AMOUNT:
123 ashish 1894
        if (value == null) {
695 rajveer 1895
          unsetAmount();
123 ashish 1896
        } else {
695 rajveer 1897
          setAmount((Double)value);
123 ashish 1898
        }
1899
        break;
1900
 
695 rajveer 1901
      case GATEWAY_ID:
123 ashish 1902
        if (value == null) {
695 rajveer 1903
          unsetGatewayId();
123 ashish 1904
        } else {
695 rajveer 1905
          setGatewayId((Long)value);
123 ashish 1906
        }
1907
        break;
1908
 
695 rajveer 1909
      case TXN_ID:
123 ashish 1910
        if (value == null) {
695 rajveer 1911
          unsetTxnId();
123 ashish 1912
        } else {
695 rajveer 1913
          setTxnId((Long)value);
123 ashish 1914
        }
1915
        break;
1916
 
1917
      }
1918
    }
1919
 
1920
    public Object getFieldValue(_Fields field) {
1921
      switch (field) {
1922
      case USER_ID:
3430 rajveer 1923
        return Long.valueOf(getUserId());
123 ashish 1924
 
1925
      case AMOUNT:
3430 rajveer 1926
        return Double.valueOf(getAmount());
123 ashish 1927
 
420 ashish 1928
      case GATEWAY_ID:
3430 rajveer 1929
        return Long.valueOf(getGatewayId());
123 ashish 1930
 
695 rajveer 1931
      case TXN_ID:
3430 rajveer 1932
        return Long.valueOf(getTxnId());
695 rajveer 1933
 
123 ashish 1934
      }
1935
      throw new IllegalStateException();
1936
    }
1937
 
3430 rajveer 1938
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
1939
    public boolean isSet(_Fields field) {
1940
      if (field == null) {
1941
        throw new IllegalArgumentException();
1942
      }
123 ashish 1943
 
1944
      switch (field) {
1945
      case USER_ID:
695 rajveer 1946
        return isSetUserId();
123 ashish 1947
      case AMOUNT:
1948
        return isSetAmount();
420 ashish 1949
      case GATEWAY_ID:
695 rajveer 1950
        return isSetGatewayId();
1951
      case TXN_ID:
1952
        return isSetTxnId();
123 ashish 1953
      }
1954
      throw new IllegalStateException();
1955
    }
1956
 
1957
    @Override
1958
    public boolean equals(Object that) {
1959
      if (that == null)
1960
        return false;
1961
      if (that instanceof createPayment_args)
1962
        return this.equals((createPayment_args)that);
1963
      return false;
1964
    }
1965
 
1966
    public boolean equals(createPayment_args that) {
1967
      if (that == null)
1968
        return false;
1969
 
695 rajveer 1970
      boolean this_present_userId = true;
1971
      boolean that_present_userId = true;
1972
      if (this_present_userId || that_present_userId) {
1973
        if (!(this_present_userId && that_present_userId))
123 ashish 1974
          return false;
695 rajveer 1975
        if (this.userId != that.userId)
123 ashish 1976
          return false;
1977
      }
1978
 
1979
      boolean this_present_amount = true;
1980
      boolean that_present_amount = true;
1981
      if (this_present_amount || that_present_amount) {
1982
        if (!(this_present_amount && that_present_amount))
1983
          return false;
1984
        if (this.amount != that.amount)
1985
          return false;
1986
      }
1987
 
695 rajveer 1988
      boolean this_present_gatewayId = true;
1989
      boolean that_present_gatewayId = true;
1990
      if (this_present_gatewayId || that_present_gatewayId) {
1991
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 1992
          return false;
695 rajveer 1993
        if (this.gatewayId != that.gatewayId)
123 ashish 1994
          return false;
1995
      }
1996
 
695 rajveer 1997
      boolean this_present_txnId = true;
1998
      boolean that_present_txnId = true;
1999
      if (this_present_txnId || that_present_txnId) {
2000
        if (!(this_present_txnId && that_present_txnId))
2001
          return false;
2002
        if (this.txnId != that.txnId)
2003
          return false;
2004
      }
2005
 
123 ashish 2006
      return true;
2007
    }
2008
 
2009
    @Override
2010
    public int hashCode() {
2011
      return 0;
2012
    }
2013
 
2014
    public int compareTo(createPayment_args other) {
2015
      if (!getClass().equals(other.getClass())) {
2016
        return getClass().getName().compareTo(other.getClass().getName());
2017
      }
2018
 
2019
      int lastComparison = 0;
2020
      createPayment_args typedOther = (createPayment_args)other;
2021
 
3430 rajveer 2022
      lastComparison = Boolean.valueOf(isSetUserId()).compareTo(typedOther.isSetUserId());
123 ashish 2023
      if (lastComparison != 0) {
2024
        return lastComparison;
2025
      }
3430 rajveer 2026
      if (isSetUserId()) {
2027
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userId, typedOther.userId);
2028
        if (lastComparison != 0) {
2029
          return lastComparison;
2030
        }
123 ashish 2031
      }
3430 rajveer 2032
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
123 ashish 2033
      if (lastComparison != 0) {
2034
        return lastComparison;
2035
      }
3430 rajveer 2036
      if (isSetAmount()) {
2037
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
2038
        if (lastComparison != 0) {
2039
          return lastComparison;
2040
        }
123 ashish 2041
      }
3430 rajveer 2042
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 2043
      if (lastComparison != 0) {
2044
        return lastComparison;
2045
      }
3430 rajveer 2046
      if (isSetGatewayId()) {
2047
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
2048
        if (lastComparison != 0) {
2049
          return lastComparison;
2050
        }
123 ashish 2051
      }
3430 rajveer 2052
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
123 ashish 2053
      if (lastComparison != 0) {
2054
        return lastComparison;
2055
      }
3430 rajveer 2056
      if (isSetTxnId()) {
2057
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
2058
        if (lastComparison != 0) {
2059
          return lastComparison;
2060
        }
123 ashish 2061
      }
2062
      return 0;
2063
    }
2064
 
3430 rajveer 2065
    public _Fields fieldForId(int fieldId) {
2066
      return _Fields.findByThriftId(fieldId);
2067
    }
2068
 
2069
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2070
      org.apache.thrift.protocol.TField field;
123 ashish 2071
      iprot.readStructBegin();
2072
      while (true)
2073
      {
2074
        field = iprot.readFieldBegin();
3430 rajveer 2075
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 2076
          break;
2077
        }
3430 rajveer 2078
        switch (field.id) {
2079
          case 1: // USER_ID
2080
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2081
              this.userId = iprot.readI64();
2082
              setUserIdIsSet(true);
2083
            } else { 
2084
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2085
            }
2086
            break;
2087
          case 2: // AMOUNT
2088
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
2089
              this.amount = iprot.readDouble();
2090
              setAmountIsSet(true);
2091
            } else { 
2092
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2093
            }
2094
            break;
2095
          case 3: // GATEWAY_ID
2096
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2097
              this.gatewayId = iprot.readI64();
2098
              setGatewayIdIsSet(true);
2099
            } else { 
2100
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2101
            }
2102
            break;
2103
          case 4: // TXN_ID
2104
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2105
              this.txnId = iprot.readI64();
2106
              setTxnIdIsSet(true);
2107
            } else { 
2108
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2109
            }
2110
            break;
2111
          default:
2112
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 2113
        }
3430 rajveer 2114
        iprot.readFieldEnd();
123 ashish 2115
      }
2116
      iprot.readStructEnd();
2117
      validate();
2118
    }
2119
 
3430 rajveer 2120
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 2121
      validate();
2122
 
2123
      oprot.writeStructBegin(STRUCT_DESC);
2124
      oprot.writeFieldBegin(USER_ID_FIELD_DESC);
695 rajveer 2125
      oprot.writeI64(this.userId);
123 ashish 2126
      oprot.writeFieldEnd();
2127
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
2128
      oprot.writeDouble(this.amount);
2129
      oprot.writeFieldEnd();
420 ashish 2130
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 2131
      oprot.writeI64(this.gatewayId);
420 ashish 2132
      oprot.writeFieldEnd();
695 rajveer 2133
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
2134
      oprot.writeI64(this.txnId);
2135
      oprot.writeFieldEnd();
123 ashish 2136
      oprot.writeFieldStop();
2137
      oprot.writeStructEnd();
2138
    }
2139
 
2140
    @Override
2141
    public String toString() {
2142
      StringBuilder sb = new StringBuilder("createPayment_args(");
2143
      boolean first = true;
2144
 
695 rajveer 2145
      sb.append("userId:");
2146
      sb.append(this.userId);
123 ashish 2147
      first = false;
2148
      if (!first) sb.append(", ");
2149
      sb.append("amount:");
2150
      sb.append(this.amount);
2151
      first = false;
2152
      if (!first) sb.append(", ");
695 rajveer 2153
      sb.append("gatewayId:");
2154
      sb.append(this.gatewayId);
123 ashish 2155
      first = false;
695 rajveer 2156
      if (!first) sb.append(", ");
2157
      sb.append("txnId:");
2158
      sb.append(this.txnId);
2159
      first = false;
123 ashish 2160
      sb.append(")");
2161
      return sb.toString();
2162
    }
2163
 
3430 rajveer 2164
    public void validate() throws org.apache.thrift.TException {
123 ashish 2165
      // check for required fields
2166
    }
2167
 
3430 rajveer 2168
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2169
      try {
2170
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2171
      } catch (org.apache.thrift.TException te) {
2172
        throw new java.io.IOException(te);
2173
      }
2174
    }
2175
 
2176
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2177
      try {
2178
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2179
      } catch (org.apache.thrift.TException te) {
2180
        throw new java.io.IOException(te);
2181
      }
2182
    }
2183
 
123 ashish 2184
  }
2185
 
3430 rajveer 2186
  public static class createPayment_result implements org.apache.thrift.TBase<createPayment_result, createPayment_result._Fields>, java.io.Serializable, Cloneable   {
2187
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPayment_result");
123 ashish 2188
 
3430 rajveer 2189
    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);
2190
    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 2191
 
3430 rajveer 2192
    private long success; // required
2193
    private PaymentException pe; // required
123 ashish 2194
 
2195
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2196
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 2197
      SUCCESS((short)0, "success"),
2198
      PE((short)1, "pe");
2199
 
2200
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2201
 
2202
      static {
2203
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2204
          byName.put(field.getFieldName(), field);
2205
        }
2206
      }
2207
 
2208
      /**
2209
       * Find the _Fields constant that matches fieldId, or null if its not found.
2210
       */
2211
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2212
        switch(fieldId) {
2213
          case 0: // SUCCESS
2214
            return SUCCESS;
2215
          case 1: // PE
2216
            return PE;
2217
          default:
2218
            return null;
2219
        }
123 ashish 2220
      }
2221
 
2222
      /**
2223
       * Find the _Fields constant that matches fieldId, throwing an exception
2224
       * if it is not found.
2225
       */
2226
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2227
        _Fields fields = findByThriftId(fieldId);
2228
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2229
        return fields;
2230
      }
2231
 
2232
      /**
2233
       * Find the _Fields constant that matches name, or null if its not found.
2234
       */
2235
      public static _Fields findByName(String name) {
2236
        return byName.get(name);
2237
      }
2238
 
2239
      private final short _thriftId;
2240
      private final String _fieldName;
2241
 
2242
      _Fields(short thriftId, String fieldName) {
2243
        _thriftId = thriftId;
2244
        _fieldName = fieldName;
2245
      }
2246
 
2247
      public short getThriftFieldId() {
2248
        return _thriftId;
2249
      }
2250
 
2251
      public String getFieldName() {
2252
        return _fieldName;
2253
      }
2254
    }
2255
 
2256
    // isset id assignments
420 ashish 2257
    private static final int __SUCCESS_ISSET_ID = 0;
2258
    private BitSet __isset_bit_vector = new BitSet(1);
123 ashish 2259
 
3430 rajveer 2260
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 2261
    static {
3430 rajveer 2262
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2263
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2264
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2265
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2266
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
2267
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2268
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createPayment_result.class, metaDataMap);
123 ashish 2269
    }
2270
 
2271
    public createPayment_result() {
2272
    }
2273
 
2274
    public createPayment_result(
420 ashish 2275
      long success,
123 ashish 2276
      PaymentException pe)
2277
    {
2278
      this();
2279
      this.success = success;
420 ashish 2280
      setSuccessIsSet(true);
123 ashish 2281
      this.pe = pe;
2282
    }
2283
 
2284
    /**
2285
     * Performs a deep copy on <i>other</i>.
2286
     */
2287
    public createPayment_result(createPayment_result other) {
420 ashish 2288
      __isset_bit_vector.clear();
2289
      __isset_bit_vector.or(other.__isset_bit_vector);
2290
      this.success = other.success;
123 ashish 2291
      if (other.isSetPe()) {
2292
        this.pe = new PaymentException(other.pe);
2293
      }
2294
    }
2295
 
2296
    public createPayment_result deepCopy() {
2297
      return new createPayment_result(this);
2298
    }
2299
 
3430 rajveer 2300
    @Override
2301
    public void clear() {
2302
      setSuccessIsSet(false);
2303
      this.success = 0;
2304
      this.pe = null;
123 ashish 2305
    }
2306
 
420 ashish 2307
    public long getSuccess() {
123 ashish 2308
      return this.success;
2309
    }
2310
 
3430 rajveer 2311
    public void setSuccess(long success) {
123 ashish 2312
      this.success = success;
420 ashish 2313
      setSuccessIsSet(true);
123 ashish 2314
    }
2315
 
2316
    public void unsetSuccess() {
420 ashish 2317
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
123 ashish 2318
    }
2319
 
3430 rajveer 2320
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 2321
    public boolean isSetSuccess() {
420 ashish 2322
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
123 ashish 2323
    }
2324
 
2325
    public void setSuccessIsSet(boolean value) {
420 ashish 2326
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
123 ashish 2327
    }
2328
 
2329
    public PaymentException getPe() {
2330
      return this.pe;
2331
    }
2332
 
3430 rajveer 2333
    public void setPe(PaymentException pe) {
123 ashish 2334
      this.pe = pe;
2335
    }
2336
 
2337
    public void unsetPe() {
2338
      this.pe = null;
2339
    }
2340
 
3430 rajveer 2341
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 2342
    public boolean isSetPe() {
2343
      return this.pe != null;
2344
    }
2345
 
2346
    public void setPeIsSet(boolean value) {
2347
      if (!value) {
2348
        this.pe = null;
2349
      }
2350
    }
2351
 
2352
    public void setFieldValue(_Fields field, Object value) {
2353
      switch (field) {
2354
      case SUCCESS:
2355
        if (value == null) {
2356
          unsetSuccess();
2357
        } else {
420 ashish 2358
          setSuccess((Long)value);
123 ashish 2359
        }
2360
        break;
2361
 
2362
      case PE:
2363
        if (value == null) {
2364
          unsetPe();
2365
        } else {
2366
          setPe((PaymentException)value);
2367
        }
2368
        break;
2369
 
2370
      }
2371
    }
2372
 
2373
    public Object getFieldValue(_Fields field) {
2374
      switch (field) {
2375
      case SUCCESS:
3430 rajveer 2376
        return Long.valueOf(getSuccess());
123 ashish 2377
 
2378
      case PE:
2379
        return getPe();
2380
 
2381
      }
2382
      throw new IllegalStateException();
2383
    }
2384
 
3430 rajveer 2385
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2386
    public boolean isSet(_Fields field) {
2387
      if (field == null) {
2388
        throw new IllegalArgumentException();
2389
      }
123 ashish 2390
 
2391
      switch (field) {
2392
      case SUCCESS:
2393
        return isSetSuccess();
2394
      case PE:
2395
        return isSetPe();
2396
      }
2397
      throw new IllegalStateException();
2398
    }
2399
 
2400
    @Override
2401
    public boolean equals(Object that) {
2402
      if (that == null)
2403
        return false;
2404
      if (that instanceof createPayment_result)
2405
        return this.equals((createPayment_result)that);
2406
      return false;
2407
    }
2408
 
2409
    public boolean equals(createPayment_result that) {
2410
      if (that == null)
2411
        return false;
2412
 
420 ashish 2413
      boolean this_present_success = true;
2414
      boolean that_present_success = true;
123 ashish 2415
      if (this_present_success || that_present_success) {
2416
        if (!(this_present_success && that_present_success))
2417
          return false;
420 ashish 2418
        if (this.success != that.success)
123 ashish 2419
          return false;
2420
      }
2421
 
2422
      boolean this_present_pe = true && this.isSetPe();
2423
      boolean that_present_pe = true && that.isSetPe();
2424
      if (this_present_pe || that_present_pe) {
2425
        if (!(this_present_pe && that_present_pe))
2426
          return false;
2427
        if (!this.pe.equals(that.pe))
2428
          return false;
2429
      }
2430
 
2431
      return true;
2432
    }
2433
 
2434
    @Override
2435
    public int hashCode() {
2436
      return 0;
2437
    }
2438
 
420 ashish 2439
    public int compareTo(createPayment_result other) {
2440
      if (!getClass().equals(other.getClass())) {
2441
        return getClass().getName().compareTo(other.getClass().getName());
2442
      }
2443
 
2444
      int lastComparison = 0;
2445
      createPayment_result typedOther = (createPayment_result)other;
2446
 
3430 rajveer 2447
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
420 ashish 2448
      if (lastComparison != 0) {
2449
        return lastComparison;
2450
      }
3430 rajveer 2451
      if (isSetSuccess()) {
2452
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
2453
        if (lastComparison != 0) {
2454
          return lastComparison;
2455
        }
420 ashish 2456
      }
3430 rajveer 2457
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 2458
      if (lastComparison != 0) {
2459
        return lastComparison;
2460
      }
3430 rajveer 2461
      if (isSetPe()) {
2462
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
2463
        if (lastComparison != 0) {
2464
          return lastComparison;
2465
        }
420 ashish 2466
      }
2467
      return 0;
2468
    }
2469
 
3430 rajveer 2470
    public _Fields fieldForId(int fieldId) {
2471
      return _Fields.findByThriftId(fieldId);
2472
    }
2473
 
2474
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2475
      org.apache.thrift.protocol.TField field;
123 ashish 2476
      iprot.readStructBegin();
2477
      while (true)
2478
      {
2479
        field = iprot.readFieldBegin();
3430 rajveer 2480
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 2481
          break;
2482
        }
3430 rajveer 2483
        switch (field.id) {
2484
          case 0: // SUCCESS
2485
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2486
              this.success = iprot.readI64();
2487
              setSuccessIsSet(true);
2488
            } else { 
2489
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2490
            }
2491
            break;
2492
          case 1: // PE
2493
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
2494
              this.pe = new PaymentException();
2495
              this.pe.read(iprot);
2496
            } else { 
2497
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2498
            }
2499
            break;
2500
          default:
2501
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 2502
        }
3430 rajveer 2503
        iprot.readFieldEnd();
123 ashish 2504
      }
2505
      iprot.readStructEnd();
2506
      validate();
2507
    }
2508
 
3430 rajveer 2509
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 2510
      oprot.writeStructBegin(STRUCT_DESC);
2511
 
2512
      if (this.isSetSuccess()) {
2513
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
420 ashish 2514
        oprot.writeI64(this.success);
123 ashish 2515
        oprot.writeFieldEnd();
2516
      } else if (this.isSetPe()) {
2517
        oprot.writeFieldBegin(PE_FIELD_DESC);
2518
        this.pe.write(oprot);
2519
        oprot.writeFieldEnd();
2520
      }
2521
      oprot.writeFieldStop();
2522
      oprot.writeStructEnd();
2523
    }
2524
 
2525
    @Override
2526
    public String toString() {
2527
      StringBuilder sb = new StringBuilder("createPayment_result(");
2528
      boolean first = true;
2529
 
2530
      sb.append("success:");
420 ashish 2531
      sb.append(this.success);
123 ashish 2532
      first = false;
2533
      if (!first) sb.append(", ");
2534
      sb.append("pe:");
2535
      if (this.pe == null) {
2536
        sb.append("null");
2537
      } else {
2538
        sb.append(this.pe);
2539
      }
2540
      first = false;
2541
      sb.append(")");
2542
      return sb.toString();
2543
    }
2544
 
3430 rajveer 2545
    public void validate() throws org.apache.thrift.TException {
123 ashish 2546
      // check for required fields
2547
    }
2548
 
3430 rajveer 2549
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2550
      try {
2551
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2552
      } catch (org.apache.thrift.TException te) {
2553
        throw new java.io.IOException(te);
2554
      }
2555
    }
2556
 
2557
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2558
      try {
2559
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2560
      } catch (org.apache.thrift.TException te) {
2561
        throw new java.io.IOException(te);
2562
      }
2563
    }
2564
 
123 ashish 2565
  }
2566
 
3430 rajveer 2567
  public static class getPaymentsForUser_args implements org.apache.thrift.TBase<getPaymentsForUser_args, getPaymentsForUser_args._Fields>, java.io.Serializable, Cloneable   {
2568
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsForUser_args");
123 ashish 2569
 
3430 rajveer 2570
    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);
2571
    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);
2572
    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);
2573
    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);
2574
    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 2575
 
3430 rajveer 2576
    private long userId; // required
2577
    private long fromTime; // required
2578
    private long toTime; // required
2579
    private PaymentStatus status; // required
2580
    private long gatewayId; // required
123 ashish 2581
 
2582
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2583
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 2584
      USER_ID((short)1, "userId"),
695 rajveer 2585
      FROM_TIME((short)2, "fromTime"),
2586
      TO_TIME((short)3, "toTime"),
123 ashish 2587
      /**
2588
       * 
2589
       * @see PaymentStatus
2590
       */
2591
      STATUS((short)4, "status"),
695 rajveer 2592
      GATEWAY_ID((short)5, "gatewayId");
123 ashish 2593
 
2594
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2595
 
2596
      static {
2597
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2598
          byName.put(field.getFieldName(), field);
2599
        }
2600
      }
2601
 
2602
      /**
2603
       * Find the _Fields constant that matches fieldId, or null if its not found.
2604
       */
2605
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2606
        switch(fieldId) {
2607
          case 1: // USER_ID
2608
            return USER_ID;
2609
          case 2: // FROM_TIME
2610
            return FROM_TIME;
2611
          case 3: // TO_TIME
2612
            return TO_TIME;
2613
          case 4: // STATUS
2614
            return STATUS;
2615
          case 5: // GATEWAY_ID
2616
            return GATEWAY_ID;
2617
          default:
2618
            return null;
2619
        }
123 ashish 2620
      }
2621
 
2622
      /**
2623
       * Find the _Fields constant that matches fieldId, throwing an exception
2624
       * if it is not found.
2625
       */
2626
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2627
        _Fields fields = findByThriftId(fieldId);
2628
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2629
        return fields;
2630
      }
2631
 
2632
      /**
2633
       * Find the _Fields constant that matches name, or null if its not found.
2634
       */
2635
      public static _Fields findByName(String name) {
2636
        return byName.get(name);
2637
      }
2638
 
2639
      private final short _thriftId;
2640
      private final String _fieldName;
2641
 
2642
      _Fields(short thriftId, String fieldName) {
2643
        _thriftId = thriftId;
2644
        _fieldName = fieldName;
2645
      }
2646
 
2647
      public short getThriftFieldId() {
2648
        return _thriftId;
2649
      }
2650
 
2651
      public String getFieldName() {
2652
        return _fieldName;
2653
      }
2654
    }
2655
 
2656
    // isset id assignments
2657
    private static final int __USERID_ISSET_ID = 0;
695 rajveer 2658
    private static final int __FROMTIME_ISSET_ID = 1;
2659
    private static final int __TOTIME_ISSET_ID = 2;
2660
    private static final int __GATEWAYID_ISSET_ID = 3;
420 ashish 2661
    private BitSet __isset_bit_vector = new BitSet(4);
123 ashish 2662
 
3430 rajveer 2663
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 2664
    static {
3430 rajveer 2665
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2666
      tmpMap.put(_Fields.USER_ID, new org.apache.thrift.meta_data.FieldMetaData("userId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2667
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2668
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2669
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2670
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2671
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2672
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2673
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
2674
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2675
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2676
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2677
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsForUser_args.class, metaDataMap);
123 ashish 2678
    }
2679
 
2680
    public getPaymentsForUser_args() {
2681
    }
2682
 
2683
    public getPaymentsForUser_args(
2684
      long userId,
695 rajveer 2685
      long fromTime,
2686
      long toTime,
123 ashish 2687
      PaymentStatus status,
695 rajveer 2688
      long gatewayId)
123 ashish 2689
    {
2690
      this();
2691
      this.userId = userId;
2692
      setUserIdIsSet(true);
695 rajveer 2693
      this.fromTime = fromTime;
2694
      setFromTimeIsSet(true);
2695
      this.toTime = toTime;
2696
      setToTimeIsSet(true);
123 ashish 2697
      this.status = status;
695 rajveer 2698
      this.gatewayId = gatewayId;
2699
      setGatewayIdIsSet(true);
123 ashish 2700
    }
2701
 
2702
    /**
2703
     * Performs a deep copy on <i>other</i>.
2704
     */
2705
    public getPaymentsForUser_args(getPaymentsForUser_args other) {
2706
      __isset_bit_vector.clear();
2707
      __isset_bit_vector.or(other.__isset_bit_vector);
2708
      this.userId = other.userId;
695 rajveer 2709
      this.fromTime = other.fromTime;
2710
      this.toTime = other.toTime;
123 ashish 2711
      if (other.isSetStatus()) {
2712
        this.status = other.status;
2713
      }
695 rajveer 2714
      this.gatewayId = other.gatewayId;
123 ashish 2715
    }
2716
 
2717
    public getPaymentsForUser_args deepCopy() {
2718
      return new getPaymentsForUser_args(this);
2719
    }
2720
 
3430 rajveer 2721
    @Override
2722
    public void clear() {
2723
      setUserIdIsSet(false);
2724
      this.userId = 0;
2725
      setFromTimeIsSet(false);
2726
      this.fromTime = 0;
2727
      setToTimeIsSet(false);
2728
      this.toTime = 0;
2729
      this.status = null;
2730
      setGatewayIdIsSet(false);
2731
      this.gatewayId = 0;
123 ashish 2732
    }
2733
 
2734
    public long getUserId() {
2735
      return this.userId;
2736
    }
2737
 
3430 rajveer 2738
    public void setUserId(long userId) {
123 ashish 2739
      this.userId = userId;
2740
      setUserIdIsSet(true);
2741
    }
2742
 
2743
    public void unsetUserId() {
2744
      __isset_bit_vector.clear(__USERID_ISSET_ID);
2745
    }
2746
 
3430 rajveer 2747
    /** Returns true if field userId is set (has been assigned a value) and false otherwise */
123 ashish 2748
    public boolean isSetUserId() {
2749
      return __isset_bit_vector.get(__USERID_ISSET_ID);
2750
    }
2751
 
2752
    public void setUserIdIsSet(boolean value) {
2753
      __isset_bit_vector.set(__USERID_ISSET_ID, value);
2754
    }
2755
 
695 rajveer 2756
    public long getFromTime() {
2757
      return this.fromTime;
123 ashish 2758
    }
2759
 
3430 rajveer 2760
    public void setFromTime(long fromTime) {
695 rajveer 2761
      this.fromTime = fromTime;
2762
      setFromTimeIsSet(true);
123 ashish 2763
    }
2764
 
695 rajveer 2765
    public void unsetFromTime() {
2766
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
123 ashish 2767
    }
2768
 
3430 rajveer 2769
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
695 rajveer 2770
    public boolean isSetFromTime() {
2771
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
123 ashish 2772
    }
2773
 
695 rajveer 2774
    public void setFromTimeIsSet(boolean value) {
2775
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
123 ashish 2776
    }
2777
 
695 rajveer 2778
    public long getToTime() {
2779
      return this.toTime;
123 ashish 2780
    }
2781
 
3430 rajveer 2782
    public void setToTime(long toTime) {
695 rajveer 2783
      this.toTime = toTime;
2784
      setToTimeIsSet(true);
123 ashish 2785
    }
2786
 
695 rajveer 2787
    public void unsetToTime() {
2788
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
123 ashish 2789
    }
2790
 
3430 rajveer 2791
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
695 rajveer 2792
    public boolean isSetToTime() {
2793
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
123 ashish 2794
    }
2795
 
695 rajveer 2796
    public void setToTimeIsSet(boolean value) {
2797
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
123 ashish 2798
    }
2799
 
2800
    /**
2801
     * 
2802
     * @see PaymentStatus
2803
     */
2804
    public PaymentStatus getStatus() {
2805
      return this.status;
2806
    }
2807
 
2808
    /**
2809
     * 
2810
     * @see PaymentStatus
2811
     */
3430 rajveer 2812
    public void setStatus(PaymentStatus status) {
123 ashish 2813
      this.status = status;
2814
    }
2815
 
2816
    public void unsetStatus() {
2817
      this.status = null;
2818
    }
2819
 
3430 rajveer 2820
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
123 ashish 2821
    public boolean isSetStatus() {
2822
      return this.status != null;
2823
    }
2824
 
2825
    public void setStatusIsSet(boolean value) {
2826
      if (!value) {
2827
        this.status = null;
2828
      }
2829
    }
2830
 
695 rajveer 2831
    public long getGatewayId() {
2832
      return this.gatewayId;
123 ashish 2833
    }
2834
 
3430 rajveer 2835
    public void setGatewayId(long gatewayId) {
695 rajveer 2836
      this.gatewayId = gatewayId;
2837
      setGatewayIdIsSet(true);
123 ashish 2838
    }
2839
 
695 rajveer 2840
    public void unsetGatewayId() {
2841
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 2842
    }
2843
 
3430 rajveer 2844
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 2845
    public boolean isSetGatewayId() {
2846
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 2847
    }
2848
 
695 rajveer 2849
    public void setGatewayIdIsSet(boolean value) {
2850
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 2851
    }
2852
 
2853
    public void setFieldValue(_Fields field, Object value) {
2854
      switch (field) {
2855
      case USER_ID:
2856
        if (value == null) {
2857
          unsetUserId();
2858
        } else {
2859
          setUserId((Long)value);
2860
        }
2861
        break;
2862
 
2863
      case FROM_TIME:
2864
        if (value == null) {
695 rajveer 2865
          unsetFromTime();
123 ashish 2866
        } else {
695 rajveer 2867
          setFromTime((Long)value);
123 ashish 2868
        }
2869
        break;
2870
 
2871
      case TO_TIME:
2872
        if (value == null) {
695 rajveer 2873
          unsetToTime();
123 ashish 2874
        } else {
695 rajveer 2875
          setToTime((Long)value);
123 ashish 2876
        }
2877
        break;
2878
 
2879
      case STATUS:
2880
        if (value == null) {
2881
          unsetStatus();
2882
        } else {
2883
          setStatus((PaymentStatus)value);
2884
        }
2885
        break;
2886
 
420 ashish 2887
      case GATEWAY_ID:
123 ashish 2888
        if (value == null) {
695 rajveer 2889
          unsetGatewayId();
123 ashish 2890
        } else {
695 rajveer 2891
          setGatewayId((Long)value);
123 ashish 2892
        }
2893
        break;
2894
 
2895
      }
2896
    }
2897
 
2898
    public Object getFieldValue(_Fields field) {
2899
      switch (field) {
2900
      case USER_ID:
3430 rajveer 2901
        return Long.valueOf(getUserId());
123 ashish 2902
 
2903
      case FROM_TIME:
3430 rajveer 2904
        return Long.valueOf(getFromTime());
123 ashish 2905
 
2906
      case TO_TIME:
3430 rajveer 2907
        return Long.valueOf(getToTime());
123 ashish 2908
 
2909
      case STATUS:
2910
        return getStatus();
2911
 
420 ashish 2912
      case GATEWAY_ID:
3430 rajveer 2913
        return Long.valueOf(getGatewayId());
123 ashish 2914
 
2915
      }
2916
      throw new IllegalStateException();
2917
    }
2918
 
3430 rajveer 2919
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2920
    public boolean isSet(_Fields field) {
2921
      if (field == null) {
2922
        throw new IllegalArgumentException();
2923
      }
123 ashish 2924
 
2925
      switch (field) {
2926
      case USER_ID:
2927
        return isSetUserId();
2928
      case FROM_TIME:
695 rajveer 2929
        return isSetFromTime();
123 ashish 2930
      case TO_TIME:
695 rajveer 2931
        return isSetToTime();
123 ashish 2932
      case STATUS:
2933
        return isSetStatus();
420 ashish 2934
      case GATEWAY_ID:
695 rajveer 2935
        return isSetGatewayId();
123 ashish 2936
      }
2937
      throw new IllegalStateException();
2938
    }
2939
 
2940
    @Override
2941
    public boolean equals(Object that) {
2942
      if (that == null)
2943
        return false;
2944
      if (that instanceof getPaymentsForUser_args)
2945
        return this.equals((getPaymentsForUser_args)that);
2946
      return false;
2947
    }
2948
 
2949
    public boolean equals(getPaymentsForUser_args that) {
2950
      if (that == null)
2951
        return false;
2952
 
2953
      boolean this_present_userId = true;
2954
      boolean that_present_userId = true;
2955
      if (this_present_userId || that_present_userId) {
2956
        if (!(this_present_userId && that_present_userId))
2957
          return false;
2958
        if (this.userId != that.userId)
2959
          return false;
2960
      }
2961
 
695 rajveer 2962
      boolean this_present_fromTime = true;
2963
      boolean that_present_fromTime = true;
2964
      if (this_present_fromTime || that_present_fromTime) {
2965
        if (!(this_present_fromTime && that_present_fromTime))
123 ashish 2966
          return false;
695 rajveer 2967
        if (this.fromTime != that.fromTime)
123 ashish 2968
          return false;
2969
      }
2970
 
695 rajveer 2971
      boolean this_present_toTime = true;
2972
      boolean that_present_toTime = true;
2973
      if (this_present_toTime || that_present_toTime) {
2974
        if (!(this_present_toTime && that_present_toTime))
123 ashish 2975
          return false;
695 rajveer 2976
        if (this.toTime != that.toTime)
123 ashish 2977
          return false;
2978
      }
2979
 
2980
      boolean this_present_status = true && this.isSetStatus();
2981
      boolean that_present_status = true && that.isSetStatus();
2982
      if (this_present_status || that_present_status) {
2983
        if (!(this_present_status && that_present_status))
2984
          return false;
2985
        if (!this.status.equals(that.status))
2986
          return false;
2987
      }
2988
 
695 rajveer 2989
      boolean this_present_gatewayId = true;
2990
      boolean that_present_gatewayId = true;
2991
      if (this_present_gatewayId || that_present_gatewayId) {
2992
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 2993
          return false;
695 rajveer 2994
        if (this.gatewayId != that.gatewayId)
123 ashish 2995
          return false;
2996
      }
2997
 
2998
      return true;
2999
    }
3000
 
3001
    @Override
3002
    public int hashCode() {
3003
      return 0;
3004
    }
3005
 
3006
    public int compareTo(getPaymentsForUser_args other) {
3007
      if (!getClass().equals(other.getClass())) {
3008
        return getClass().getName().compareTo(other.getClass().getName());
3009
      }
3010
 
3011
      int lastComparison = 0;
3012
      getPaymentsForUser_args typedOther = (getPaymentsForUser_args)other;
3013
 
3430 rajveer 3014
      lastComparison = Boolean.valueOf(isSetUserId()).compareTo(typedOther.isSetUserId());
123 ashish 3015
      if (lastComparison != 0) {
3016
        return lastComparison;
3017
      }
3430 rajveer 3018
      if (isSetUserId()) {
3019
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.userId, typedOther.userId);
3020
        if (lastComparison != 0) {
3021
          return lastComparison;
3022
        }
123 ashish 3023
      }
3430 rajveer 3024
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
123 ashish 3025
      if (lastComparison != 0) {
3026
        return lastComparison;
3027
      }
3430 rajveer 3028
      if (isSetFromTime()) {
3029
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
3030
        if (lastComparison != 0) {
3031
          return lastComparison;
3032
        }
123 ashish 3033
      }
3430 rajveer 3034
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
123 ashish 3035
      if (lastComparison != 0) {
3036
        return lastComparison;
3037
      }
3430 rajveer 3038
      if (isSetToTime()) {
3039
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
3040
        if (lastComparison != 0) {
3041
          return lastComparison;
3042
        }
123 ashish 3043
      }
3430 rajveer 3044
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
123 ashish 3045
      if (lastComparison != 0) {
3046
        return lastComparison;
3047
      }
3430 rajveer 3048
      if (isSetStatus()) {
3049
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
3050
        if (lastComparison != 0) {
3051
          return lastComparison;
3052
        }
123 ashish 3053
      }
3430 rajveer 3054
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 3055
      if (lastComparison != 0) {
3056
        return lastComparison;
3057
      }
3430 rajveer 3058
      if (isSetGatewayId()) {
3059
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
3060
        if (lastComparison != 0) {
3061
          return lastComparison;
3062
        }
123 ashish 3063
      }
3064
      return 0;
3065
    }
3066
 
3430 rajveer 3067
    public _Fields fieldForId(int fieldId) {
3068
      return _Fields.findByThriftId(fieldId);
3069
    }
3070
 
3071
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3072
      org.apache.thrift.protocol.TField field;
123 ashish 3073
      iprot.readStructBegin();
3074
      while (true)
3075
      {
3076
        field = iprot.readFieldBegin();
3430 rajveer 3077
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 3078
          break;
3079
        }
3430 rajveer 3080
        switch (field.id) {
3081
          case 1: // USER_ID
3082
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3083
              this.userId = iprot.readI64();
3084
              setUserIdIsSet(true);
3085
            } else { 
3086
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3087
            }
3088
            break;
3089
          case 2: // FROM_TIME
3090
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3091
              this.fromTime = iprot.readI64();
3092
              setFromTimeIsSet(true);
3093
            } else { 
3094
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3095
            }
3096
            break;
3097
          case 3: // TO_TIME
3098
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3099
              this.toTime = iprot.readI64();
3100
              setToTimeIsSet(true);
3101
            } else { 
3102
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3103
            }
3104
            break;
3105
          case 4: // STATUS
3106
            if (field.type == org.apache.thrift.protocol.TType.I32) {
3107
              this.status = PaymentStatus.findByValue(iprot.readI32());
3108
            } else { 
3109
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3110
            }
3111
            break;
3112
          case 5: // GATEWAY_ID
3113
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3114
              this.gatewayId = iprot.readI64();
3115
              setGatewayIdIsSet(true);
3116
            } else { 
3117
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3118
            }
3119
            break;
3120
          default:
3121
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 3122
        }
3430 rajveer 3123
        iprot.readFieldEnd();
123 ashish 3124
      }
3125
      iprot.readStructEnd();
3126
      validate();
3127
    }
3128
 
3430 rajveer 3129
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 3130
      validate();
3131
 
3132
      oprot.writeStructBegin(STRUCT_DESC);
3133
      oprot.writeFieldBegin(USER_ID_FIELD_DESC);
3134
      oprot.writeI64(this.userId);
3135
      oprot.writeFieldEnd();
3136
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
695 rajveer 3137
      oprot.writeI64(this.fromTime);
123 ashish 3138
      oprot.writeFieldEnd();
3139
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
695 rajveer 3140
      oprot.writeI64(this.toTime);
123 ashish 3141
      oprot.writeFieldEnd();
3142
      if (this.status != null) {
3143
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
3144
        oprot.writeI32(this.status.getValue());
3145
        oprot.writeFieldEnd();
3146
      }
420 ashish 3147
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 3148
      oprot.writeI64(this.gatewayId);
420 ashish 3149
      oprot.writeFieldEnd();
123 ashish 3150
      oprot.writeFieldStop();
3151
      oprot.writeStructEnd();
3152
    }
3153
 
3154
    @Override
3155
    public String toString() {
3156
      StringBuilder sb = new StringBuilder("getPaymentsForUser_args(");
3157
      boolean first = true;
3158
 
3159
      sb.append("userId:");
3160
      sb.append(this.userId);
3161
      first = false;
3162
      if (!first) sb.append(", ");
695 rajveer 3163
      sb.append("fromTime:");
3164
      sb.append(this.fromTime);
123 ashish 3165
      first = false;
3166
      if (!first) sb.append(", ");
695 rajveer 3167
      sb.append("toTime:");
3168
      sb.append(this.toTime);
123 ashish 3169
      first = false;
3170
      if (!first) sb.append(", ");
3171
      sb.append("status:");
3172
      if (this.status == null) {
3173
        sb.append("null");
3174
      } else {
3175
        sb.append(this.status);
3176
      }
3177
      first = false;
3178
      if (!first) sb.append(", ");
695 rajveer 3179
      sb.append("gatewayId:");
3180
      sb.append(this.gatewayId);
123 ashish 3181
      first = false;
3182
      sb.append(")");
3183
      return sb.toString();
3184
    }
3185
 
3430 rajveer 3186
    public void validate() throws org.apache.thrift.TException {
123 ashish 3187
      // check for required fields
3188
    }
3189
 
3430 rajveer 3190
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3191
      try {
3192
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3193
      } catch (org.apache.thrift.TException te) {
3194
        throw new java.io.IOException(te);
3195
      }
3196
    }
3197
 
3198
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3199
      try {
3200
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3201
      } catch (org.apache.thrift.TException te) {
3202
        throw new java.io.IOException(te);
3203
      }
3204
    }
3205
 
123 ashish 3206
  }
3207
 
3430 rajveer 3208
  public static class getPaymentsForUser_result implements org.apache.thrift.TBase<getPaymentsForUser_result, getPaymentsForUser_result._Fields>, java.io.Serializable, Cloneable   {
3209
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsForUser_result");
123 ashish 3210
 
3430 rajveer 3211
    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);
3212
    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 3213
 
3430 rajveer 3214
    private List<Payment> success; // required
3215
    private PaymentException pe; // required
123 ashish 3216
 
3217
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3218
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 3219
      SUCCESS((short)0, "success"),
3220
      PE((short)1, "pe");
3221
 
3222
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3223
 
3224
      static {
3225
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3226
          byName.put(field.getFieldName(), field);
3227
        }
3228
      }
3229
 
3230
      /**
3231
       * Find the _Fields constant that matches fieldId, or null if its not found.
3232
       */
3233
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3234
        switch(fieldId) {
3235
          case 0: // SUCCESS
3236
            return SUCCESS;
3237
          case 1: // PE
3238
            return PE;
3239
          default:
3240
            return null;
3241
        }
123 ashish 3242
      }
3243
 
3244
      /**
3245
       * Find the _Fields constant that matches fieldId, throwing an exception
3246
       * if it is not found.
3247
       */
3248
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3249
        _Fields fields = findByThriftId(fieldId);
3250
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3251
        return fields;
3252
      }
3253
 
3254
      /**
3255
       * Find the _Fields constant that matches name, or null if its not found.
3256
       */
3257
      public static _Fields findByName(String name) {
3258
        return byName.get(name);
3259
      }
3260
 
3261
      private final short _thriftId;
3262
      private final String _fieldName;
3263
 
3264
      _Fields(short thriftId, String fieldName) {
3265
        _thriftId = thriftId;
3266
        _fieldName = fieldName;
3267
      }
3268
 
3269
      public short getThriftFieldId() {
3270
        return _thriftId;
3271
      }
3272
 
3273
      public String getFieldName() {
3274
        return _fieldName;
3275
      }
3276
    }
3277
 
3278
    // isset id assignments
3279
 
3430 rajveer 3280
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 3281
    static {
3430 rajveer 3282
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3283
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3284
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
3285
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
3286
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3287
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3288
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3289
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsForUser_result.class, metaDataMap);
123 ashish 3290
    }
3291
 
3292
    public getPaymentsForUser_result() {
3293
    }
3294
 
3295
    public getPaymentsForUser_result(
3296
      List<Payment> success,
3297
      PaymentException pe)
3298
    {
3299
      this();
3300
      this.success = success;
3301
      this.pe = pe;
3302
    }
3303
 
3304
    /**
3305
     * Performs a deep copy on <i>other</i>.
3306
     */
3307
    public getPaymentsForUser_result(getPaymentsForUser_result other) {
3308
      if (other.isSetSuccess()) {
3309
        List<Payment> __this__success = new ArrayList<Payment>();
3310
        for (Payment other_element : other.success) {
3311
          __this__success.add(new Payment(other_element));
3312
        }
3313
        this.success = __this__success;
3314
      }
3315
      if (other.isSetPe()) {
3316
        this.pe = new PaymentException(other.pe);
3317
      }
3318
    }
3319
 
3320
    public getPaymentsForUser_result deepCopy() {
3321
      return new getPaymentsForUser_result(this);
3322
    }
3323
 
3430 rajveer 3324
    @Override
3325
    public void clear() {
3326
      this.success = null;
3327
      this.pe = null;
123 ashish 3328
    }
3329
 
3330
    public int getSuccessSize() {
3331
      return (this.success == null) ? 0 : this.success.size();
3332
    }
3333
 
3334
    public java.util.Iterator<Payment> getSuccessIterator() {
3335
      return (this.success == null) ? null : this.success.iterator();
3336
    }
3337
 
3338
    public void addToSuccess(Payment elem) {
3339
      if (this.success == null) {
3340
        this.success = new ArrayList<Payment>();
3341
      }
3342
      this.success.add(elem);
3343
    }
3344
 
3345
    public List<Payment> getSuccess() {
3346
      return this.success;
3347
    }
3348
 
3430 rajveer 3349
    public void setSuccess(List<Payment> success) {
123 ashish 3350
      this.success = success;
3351
    }
3352
 
3353
    public void unsetSuccess() {
3354
      this.success = null;
3355
    }
3356
 
3430 rajveer 3357
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 3358
    public boolean isSetSuccess() {
3359
      return this.success != null;
3360
    }
3361
 
3362
    public void setSuccessIsSet(boolean value) {
3363
      if (!value) {
3364
        this.success = null;
3365
      }
3366
    }
3367
 
3368
    public PaymentException getPe() {
3369
      return this.pe;
3370
    }
3371
 
3430 rajveer 3372
    public void setPe(PaymentException pe) {
123 ashish 3373
      this.pe = pe;
3374
    }
3375
 
3376
    public void unsetPe() {
3377
      this.pe = null;
3378
    }
3379
 
3430 rajveer 3380
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 3381
    public boolean isSetPe() {
3382
      return this.pe != null;
3383
    }
3384
 
3385
    public void setPeIsSet(boolean value) {
3386
      if (!value) {
3387
        this.pe = null;
3388
      }
3389
    }
3390
 
3391
    public void setFieldValue(_Fields field, Object value) {
3392
      switch (field) {
3393
      case SUCCESS:
3394
        if (value == null) {
3395
          unsetSuccess();
3396
        } else {
3397
          setSuccess((List<Payment>)value);
3398
        }
3399
        break;
3400
 
3401
      case PE:
3402
        if (value == null) {
3403
          unsetPe();
3404
        } else {
3405
          setPe((PaymentException)value);
3406
        }
3407
        break;
3408
 
3409
      }
3410
    }
3411
 
3412
    public Object getFieldValue(_Fields field) {
3413
      switch (field) {
3414
      case SUCCESS:
3415
        return getSuccess();
3416
 
3417
      case PE:
3418
        return getPe();
3419
 
3420
      }
3421
      throw new IllegalStateException();
3422
    }
3423
 
3430 rajveer 3424
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3425
    public boolean isSet(_Fields field) {
3426
      if (field == null) {
3427
        throw new IllegalArgumentException();
3428
      }
123 ashish 3429
 
3430
      switch (field) {
3431
      case SUCCESS:
3432
        return isSetSuccess();
3433
      case PE:
3434
        return isSetPe();
3435
      }
3436
      throw new IllegalStateException();
3437
    }
3438
 
3439
    @Override
3440
    public boolean equals(Object that) {
3441
      if (that == null)
3442
        return false;
3443
      if (that instanceof getPaymentsForUser_result)
3444
        return this.equals((getPaymentsForUser_result)that);
3445
      return false;
3446
    }
3447
 
3448
    public boolean equals(getPaymentsForUser_result that) {
3449
      if (that == null)
3450
        return false;
3451
 
3452
      boolean this_present_success = true && this.isSetSuccess();
3453
      boolean that_present_success = true && that.isSetSuccess();
3454
      if (this_present_success || that_present_success) {
3455
        if (!(this_present_success && that_present_success))
3456
          return false;
3457
        if (!this.success.equals(that.success))
3458
          return false;
3459
      }
3460
 
3461
      boolean this_present_pe = true && this.isSetPe();
3462
      boolean that_present_pe = true && that.isSetPe();
3463
      if (this_present_pe || that_present_pe) {
3464
        if (!(this_present_pe && that_present_pe))
3465
          return false;
3466
        if (!this.pe.equals(that.pe))
3467
          return false;
3468
      }
3469
 
3470
      return true;
3471
    }
3472
 
3473
    @Override
3474
    public int hashCode() {
3475
      return 0;
3476
    }
3477
 
695 rajveer 3478
    public int compareTo(getPaymentsForUser_result other) {
123 ashish 3479
      if (!getClass().equals(other.getClass())) {
3480
        return getClass().getName().compareTo(other.getClass().getName());
3481
      }
3482
 
3483
      int lastComparison = 0;
695 rajveer 3484
      getPaymentsForUser_result typedOther = (getPaymentsForUser_result)other;
123 ashish 3485
 
3430 rajveer 3486
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
123 ashish 3487
      if (lastComparison != 0) {
3488
        return lastComparison;
3489
      }
3430 rajveer 3490
      if (isSetSuccess()) {
3491
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3492
        if (lastComparison != 0) {
3493
          return lastComparison;
3494
        }
123 ashish 3495
      }
3430 rajveer 3496
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
123 ashish 3497
      if (lastComparison != 0) {
3498
        return lastComparison;
3499
      }
3430 rajveer 3500
      if (isSetPe()) {
3501
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
3502
        if (lastComparison != 0) {
3503
          return lastComparison;
3504
        }
123 ashish 3505
      }
3506
      return 0;
3507
    }
3508
 
3430 rajveer 3509
    public _Fields fieldForId(int fieldId) {
3510
      return _Fields.findByThriftId(fieldId);
3511
    }
3512
 
3513
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3514
      org.apache.thrift.protocol.TField field;
123 ashish 3515
      iprot.readStructBegin();
3516
      while (true)
3517
      {
3518
        field = iprot.readFieldBegin();
3430 rajveer 3519
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 3520
          break;
3521
        }
3430 rajveer 3522
        switch (field.id) {
3523
          case 0: // SUCCESS
3524
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
3525
              {
3526
                org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
3527
                this.success = new ArrayList<Payment>(_list12.size);
3528
                for (int _i13 = 0; _i13 < _list12.size; ++_i13)
123 ashish 3529
                {
3430 rajveer 3530
                  Payment _elem14; // required
3531
                  _elem14 = new Payment();
3532
                  _elem14.read(iprot);
3533
                  this.success.add(_elem14);
123 ashish 3534
                }
3430 rajveer 3535
                iprot.readListEnd();
123 ashish 3536
              }
3430 rajveer 3537
            } else { 
3538
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3539
            }
3540
            break;
3541
          case 1: // PE
3542
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3543
              this.pe = new PaymentException();
3544
              this.pe.read(iprot);
3545
            } else { 
3546
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3547
            }
3548
            break;
3549
          default:
3550
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 3551
        }
3430 rajveer 3552
        iprot.readFieldEnd();
123 ashish 3553
      }
3554
      iprot.readStructEnd();
3555
      validate();
3556
    }
3557
 
3430 rajveer 3558
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 3559
      oprot.writeStructBegin(STRUCT_DESC);
3560
 
3561
      if (this.isSetSuccess()) {
3562
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3563
        {
3430 rajveer 3564
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
2747 chandransh 3565
          for (Payment _iter15 : this.success)
123 ashish 3566
          {
2747 chandransh 3567
            _iter15.write(oprot);
123 ashish 3568
          }
3569
          oprot.writeListEnd();
3570
        }
3571
        oprot.writeFieldEnd();
3572
      } else if (this.isSetPe()) {
3573
        oprot.writeFieldBegin(PE_FIELD_DESC);
3574
        this.pe.write(oprot);
3575
        oprot.writeFieldEnd();
3576
      }
3577
      oprot.writeFieldStop();
3578
      oprot.writeStructEnd();
3579
    }
3580
 
3581
    @Override
3582
    public String toString() {
695 rajveer 3583
      StringBuilder sb = new StringBuilder("getPaymentsForUser_result(");
123 ashish 3584
      boolean first = true;
3585
 
3586
      sb.append("success:");
3587
      if (this.success == null) {
3588
        sb.append("null");
3589
      } else {
3590
        sb.append(this.success);
3591
      }
3592
      first = false;
3593
      if (!first) sb.append(", ");
3594
      sb.append("pe:");
3595
      if (this.pe == null) {
3596
        sb.append("null");
3597
      } else {
3598
        sb.append(this.pe);
3599
      }
3600
      first = false;
3601
      sb.append(")");
3602
      return sb.toString();
3603
    }
3604
 
3430 rajveer 3605
    public void validate() throws org.apache.thrift.TException {
123 ashish 3606
      // check for required fields
3607
    }
3608
 
3430 rajveer 3609
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3610
      try {
3611
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3612
      } catch (org.apache.thrift.TException te) {
3613
        throw new java.io.IOException(te);
3614
      }
3615
    }
3616
 
3617
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3618
      try {
3619
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3620
      } catch (org.apache.thrift.TException te) {
3621
        throw new java.io.IOException(te);
3622
      }
3623
    }
3624
 
123 ashish 3625
  }
3626
 
3430 rajveer 3627
  public static class getPayments_args implements org.apache.thrift.TBase<getPayments_args, getPayments_args._Fields>, java.io.Serializable, Cloneable   {
3628
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayments_args");
123 ashish 3629
 
3430 rajveer 3630
    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);
3631
    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);
3632
    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);
3633
    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 3634
 
3430 rajveer 3635
    private long fromTime; // required
3636
    private long toTime; // required
3637
    private PaymentStatus status; // required
3638
    private long gatewayId; // required
123 ashish 3639
 
3640
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3641
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 3642
      FROM_TIME((short)1, "fromTime"),
3643
      TO_TIME((short)2, "toTime"),
123 ashish 3644
      /**
3645
       * 
3646
       * @see PaymentStatus
3647
       */
3648
      STATUS((short)3, "status"),
695 rajveer 3649
      GATEWAY_ID((short)4, "gatewayId");
123 ashish 3650
 
3651
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3652
 
3653
      static {
3654
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3655
          byName.put(field.getFieldName(), field);
3656
        }
3657
      }
3658
 
3659
      /**
3660
       * Find the _Fields constant that matches fieldId, or null if its not found.
3661
       */
3662
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3663
        switch(fieldId) {
3664
          case 1: // FROM_TIME
3665
            return FROM_TIME;
3666
          case 2: // TO_TIME
3667
            return TO_TIME;
3668
          case 3: // STATUS
3669
            return STATUS;
3670
          case 4: // GATEWAY_ID
3671
            return GATEWAY_ID;
3672
          default:
3673
            return null;
3674
        }
123 ashish 3675
      }
3676
 
3677
      /**
3678
       * Find the _Fields constant that matches fieldId, throwing an exception
3679
       * if it is not found.
3680
       */
3681
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3682
        _Fields fields = findByThriftId(fieldId);
3683
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3684
        return fields;
3685
      }
3686
 
3687
      /**
3688
       * Find the _Fields constant that matches name, or null if its not found.
3689
       */
3690
      public static _Fields findByName(String name) {
3691
        return byName.get(name);
3692
      }
3693
 
3694
      private final short _thriftId;
3695
      private final String _fieldName;
3696
 
3697
      _Fields(short thriftId, String fieldName) {
3698
        _thriftId = thriftId;
3699
        _fieldName = fieldName;
3700
      }
3701
 
3702
      public short getThriftFieldId() {
3703
        return _thriftId;
3704
      }
3705
 
3706
      public String getFieldName() {
3707
        return _fieldName;
3708
      }
3709
    }
3710
 
3711
    // isset id assignments
695 rajveer 3712
    private static final int __FROMTIME_ISSET_ID = 0;
3713
    private static final int __TOTIME_ISSET_ID = 1;
3714
    private static final int __GATEWAYID_ISSET_ID = 2;
420 ashish 3715
    private BitSet __isset_bit_vector = new BitSet(3);
123 ashish 3716
 
3430 rajveer 3717
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 3718
    static {
3430 rajveer 3719
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3720
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3721
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3722
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3723
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3724
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3725
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
3726
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3727
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3728
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3729
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayments_args.class, metaDataMap);
123 ashish 3730
    }
3731
 
3732
    public getPayments_args() {
3733
    }
3734
 
3735
    public getPayments_args(
695 rajveer 3736
      long fromTime,
3737
      long toTime,
123 ashish 3738
      PaymentStatus status,
695 rajveer 3739
      long gatewayId)
123 ashish 3740
    {
3741
      this();
695 rajveer 3742
      this.fromTime = fromTime;
3743
      setFromTimeIsSet(true);
3744
      this.toTime = toTime;
3745
      setToTimeIsSet(true);
123 ashish 3746
      this.status = status;
695 rajveer 3747
      this.gatewayId = gatewayId;
3748
      setGatewayIdIsSet(true);
123 ashish 3749
    }
3750
 
3751
    /**
3752
     * Performs a deep copy on <i>other</i>.
3753
     */
3754
    public getPayments_args(getPayments_args other) {
3755
      __isset_bit_vector.clear();
3756
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 3757
      this.fromTime = other.fromTime;
3758
      this.toTime = other.toTime;
123 ashish 3759
      if (other.isSetStatus()) {
3760
        this.status = other.status;
3761
      }
695 rajveer 3762
      this.gatewayId = other.gatewayId;
123 ashish 3763
    }
3764
 
3765
    public getPayments_args deepCopy() {
3766
      return new getPayments_args(this);
3767
    }
3768
 
3430 rajveer 3769
    @Override
3770
    public void clear() {
3771
      setFromTimeIsSet(false);
3772
      this.fromTime = 0;
3773
      setToTimeIsSet(false);
3774
      this.toTime = 0;
3775
      this.status = null;
3776
      setGatewayIdIsSet(false);
3777
      this.gatewayId = 0;
123 ashish 3778
    }
3779
 
695 rajveer 3780
    public long getFromTime() {
3781
      return this.fromTime;
123 ashish 3782
    }
3783
 
3430 rajveer 3784
    public void setFromTime(long fromTime) {
695 rajveer 3785
      this.fromTime = fromTime;
3786
      setFromTimeIsSet(true);
123 ashish 3787
    }
3788
 
695 rajveer 3789
    public void unsetFromTime() {
3790
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
123 ashish 3791
    }
3792
 
3430 rajveer 3793
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
695 rajveer 3794
    public boolean isSetFromTime() {
3795
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
123 ashish 3796
    }
3797
 
695 rajveer 3798
    public void setFromTimeIsSet(boolean value) {
3799
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
123 ashish 3800
    }
3801
 
695 rajveer 3802
    public long getToTime() {
3803
      return this.toTime;
123 ashish 3804
    }
3805
 
3430 rajveer 3806
    public void setToTime(long toTime) {
695 rajveer 3807
      this.toTime = toTime;
3808
      setToTimeIsSet(true);
123 ashish 3809
    }
3810
 
695 rajveer 3811
    public void unsetToTime() {
3812
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
123 ashish 3813
    }
3814
 
3430 rajveer 3815
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
695 rajveer 3816
    public boolean isSetToTime() {
3817
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
123 ashish 3818
    }
3819
 
695 rajveer 3820
    public void setToTimeIsSet(boolean value) {
3821
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
123 ashish 3822
    }
3823
 
3824
    /**
3825
     * 
3826
     * @see PaymentStatus
3827
     */
3828
    public PaymentStatus getStatus() {
3829
      return this.status;
3830
    }
3831
 
3832
    /**
3833
     * 
3834
     * @see PaymentStatus
3835
     */
3430 rajveer 3836
    public void setStatus(PaymentStatus status) {
123 ashish 3837
      this.status = status;
3838
    }
3839
 
3840
    public void unsetStatus() {
3841
      this.status = null;
3842
    }
3843
 
3430 rajveer 3844
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
123 ashish 3845
    public boolean isSetStatus() {
3846
      return this.status != null;
3847
    }
3848
 
3849
    public void setStatusIsSet(boolean value) {
3850
      if (!value) {
3851
        this.status = null;
3852
      }
3853
    }
3854
 
695 rajveer 3855
    public long getGatewayId() {
3856
      return this.gatewayId;
123 ashish 3857
    }
3858
 
3430 rajveer 3859
    public void setGatewayId(long gatewayId) {
695 rajveer 3860
      this.gatewayId = gatewayId;
3861
      setGatewayIdIsSet(true);
123 ashish 3862
    }
3863
 
695 rajveer 3864
    public void unsetGatewayId() {
3865
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
123 ashish 3866
    }
3867
 
3430 rajveer 3868
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
695 rajveer 3869
    public boolean isSetGatewayId() {
3870
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
123 ashish 3871
    }
3872
 
695 rajveer 3873
    public void setGatewayIdIsSet(boolean value) {
3874
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
123 ashish 3875
    }
3876
 
3877
    public void setFieldValue(_Fields field, Object value) {
3878
      switch (field) {
3879
      case FROM_TIME:
3880
        if (value == null) {
695 rajveer 3881
          unsetFromTime();
123 ashish 3882
        } else {
695 rajveer 3883
          setFromTime((Long)value);
123 ashish 3884
        }
3885
        break;
3886
 
3887
      case TO_TIME:
3888
        if (value == null) {
695 rajveer 3889
          unsetToTime();
123 ashish 3890
        } else {
695 rajveer 3891
          setToTime((Long)value);
123 ashish 3892
        }
3893
        break;
3894
 
3895
      case STATUS:
3896
        if (value == null) {
3897
          unsetStatus();
3898
        } else {
3899
          setStatus((PaymentStatus)value);
3900
        }
3901
        break;
3902
 
420 ashish 3903
      case GATEWAY_ID:
123 ashish 3904
        if (value == null) {
695 rajveer 3905
          unsetGatewayId();
123 ashish 3906
        } else {
695 rajveer 3907
          setGatewayId((Long)value);
123 ashish 3908
        }
3909
        break;
3910
 
3911
      }
3912
    }
3913
 
3914
    public Object getFieldValue(_Fields field) {
3915
      switch (field) {
3916
      case FROM_TIME:
3430 rajveer 3917
        return Long.valueOf(getFromTime());
123 ashish 3918
 
3919
      case TO_TIME:
3430 rajveer 3920
        return Long.valueOf(getToTime());
123 ashish 3921
 
3922
      case STATUS:
3923
        return getStatus();
3924
 
420 ashish 3925
      case GATEWAY_ID:
3430 rajveer 3926
        return Long.valueOf(getGatewayId());
123 ashish 3927
 
3928
      }
3929
      throw new IllegalStateException();
3930
    }
3931
 
3430 rajveer 3932
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3933
    public boolean isSet(_Fields field) {
3934
      if (field == null) {
3935
        throw new IllegalArgumentException();
3936
      }
123 ashish 3937
 
3938
      switch (field) {
3939
      case FROM_TIME:
695 rajveer 3940
        return isSetFromTime();
123 ashish 3941
      case TO_TIME:
695 rajveer 3942
        return isSetToTime();
123 ashish 3943
      case STATUS:
3944
        return isSetStatus();
420 ashish 3945
      case GATEWAY_ID:
695 rajveer 3946
        return isSetGatewayId();
123 ashish 3947
      }
3948
      throw new IllegalStateException();
3949
    }
3950
 
3951
    @Override
3952
    public boolean equals(Object that) {
3953
      if (that == null)
3954
        return false;
3955
      if (that instanceof getPayments_args)
3956
        return this.equals((getPayments_args)that);
3957
      return false;
3958
    }
3959
 
3960
    public boolean equals(getPayments_args that) {
3961
      if (that == null)
3962
        return false;
3963
 
695 rajveer 3964
      boolean this_present_fromTime = true;
3965
      boolean that_present_fromTime = true;
3966
      if (this_present_fromTime || that_present_fromTime) {
3967
        if (!(this_present_fromTime && that_present_fromTime))
123 ashish 3968
          return false;
695 rajveer 3969
        if (this.fromTime != that.fromTime)
123 ashish 3970
          return false;
3971
      }
3972
 
695 rajveer 3973
      boolean this_present_toTime = true;
3974
      boolean that_present_toTime = true;
3975
      if (this_present_toTime || that_present_toTime) {
3976
        if (!(this_present_toTime && that_present_toTime))
123 ashish 3977
          return false;
695 rajveer 3978
        if (this.toTime != that.toTime)
123 ashish 3979
          return false;
3980
      }
3981
 
3982
      boolean this_present_status = true && this.isSetStatus();
3983
      boolean that_present_status = true && that.isSetStatus();
3984
      if (this_present_status || that_present_status) {
3985
        if (!(this_present_status && that_present_status))
3986
          return false;
3987
        if (!this.status.equals(that.status))
3988
          return false;
3989
      }
3990
 
695 rajveer 3991
      boolean this_present_gatewayId = true;
3992
      boolean that_present_gatewayId = true;
3993
      if (this_present_gatewayId || that_present_gatewayId) {
3994
        if (!(this_present_gatewayId && that_present_gatewayId))
123 ashish 3995
          return false;
695 rajveer 3996
        if (this.gatewayId != that.gatewayId)
123 ashish 3997
          return false;
3998
      }
3999
 
4000
      return true;
4001
    }
4002
 
4003
    @Override
4004
    public int hashCode() {
4005
      return 0;
4006
    }
4007
 
4008
    public int compareTo(getPayments_args other) {
4009
      if (!getClass().equals(other.getClass())) {
4010
        return getClass().getName().compareTo(other.getClass().getName());
4011
      }
4012
 
4013
      int lastComparison = 0;
4014
      getPayments_args typedOther = (getPayments_args)other;
4015
 
3430 rajveer 4016
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
123 ashish 4017
      if (lastComparison != 0) {
4018
        return lastComparison;
4019
      }
3430 rajveer 4020
      if (isSetFromTime()) {
4021
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
4022
        if (lastComparison != 0) {
4023
          return lastComparison;
4024
        }
123 ashish 4025
      }
3430 rajveer 4026
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
123 ashish 4027
      if (lastComparison != 0) {
4028
        return lastComparison;
4029
      }
3430 rajveer 4030
      if (isSetToTime()) {
4031
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
4032
        if (lastComparison != 0) {
4033
          return lastComparison;
4034
        }
123 ashish 4035
      }
3430 rajveer 4036
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
123 ashish 4037
      if (lastComparison != 0) {
4038
        return lastComparison;
4039
      }
3430 rajveer 4040
      if (isSetStatus()) {
4041
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
4042
        if (lastComparison != 0) {
4043
          return lastComparison;
4044
        }
123 ashish 4045
      }
3430 rajveer 4046
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
123 ashish 4047
      if (lastComparison != 0) {
4048
        return lastComparison;
4049
      }
3430 rajveer 4050
      if (isSetGatewayId()) {
4051
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
4052
        if (lastComparison != 0) {
4053
          return lastComparison;
4054
        }
123 ashish 4055
      }
4056
      return 0;
4057
    }
4058
 
3430 rajveer 4059
    public _Fields fieldForId(int fieldId) {
4060
      return _Fields.findByThriftId(fieldId);
4061
    }
4062
 
4063
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4064
      org.apache.thrift.protocol.TField field;
123 ashish 4065
      iprot.readStructBegin();
4066
      while (true)
4067
      {
4068
        field = iprot.readFieldBegin();
3430 rajveer 4069
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 4070
          break;
4071
        }
3430 rajveer 4072
        switch (field.id) {
4073
          case 1: // FROM_TIME
4074
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4075
              this.fromTime = iprot.readI64();
4076
              setFromTimeIsSet(true);
4077
            } else { 
4078
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4079
            }
4080
            break;
4081
          case 2: // TO_TIME
4082
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4083
              this.toTime = iprot.readI64();
4084
              setToTimeIsSet(true);
4085
            } else { 
4086
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4087
            }
4088
            break;
4089
          case 3: // STATUS
4090
            if (field.type == org.apache.thrift.protocol.TType.I32) {
4091
              this.status = PaymentStatus.findByValue(iprot.readI32());
4092
            } else { 
4093
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4094
            }
4095
            break;
4096
          case 4: // GATEWAY_ID
4097
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4098
              this.gatewayId = iprot.readI64();
4099
              setGatewayIdIsSet(true);
4100
            } else { 
4101
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4102
            }
4103
            break;
4104
          default:
4105
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 4106
        }
3430 rajveer 4107
        iprot.readFieldEnd();
123 ashish 4108
      }
4109
      iprot.readStructEnd();
4110
      validate();
4111
    }
4112
 
3430 rajveer 4113
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 4114
      validate();
4115
 
4116
      oprot.writeStructBegin(STRUCT_DESC);
4117
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
695 rajveer 4118
      oprot.writeI64(this.fromTime);
123 ashish 4119
      oprot.writeFieldEnd();
4120
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
695 rajveer 4121
      oprot.writeI64(this.toTime);
123 ashish 4122
      oprot.writeFieldEnd();
4123
      if (this.status != null) {
4124
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
4125
        oprot.writeI32(this.status.getValue());
4126
        oprot.writeFieldEnd();
4127
      }
420 ashish 4128
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
695 rajveer 4129
      oprot.writeI64(this.gatewayId);
420 ashish 4130
      oprot.writeFieldEnd();
123 ashish 4131
      oprot.writeFieldStop();
4132
      oprot.writeStructEnd();
4133
    }
4134
 
4135
    @Override
4136
    public String toString() {
4137
      StringBuilder sb = new StringBuilder("getPayments_args(");
4138
      boolean first = true;
4139
 
695 rajveer 4140
      sb.append("fromTime:");
4141
      sb.append(this.fromTime);
123 ashish 4142
      first = false;
4143
      if (!first) sb.append(", ");
695 rajveer 4144
      sb.append("toTime:");
4145
      sb.append(this.toTime);
123 ashish 4146
      first = false;
4147
      if (!first) sb.append(", ");
4148
      sb.append("status:");
4149
      if (this.status == null) {
4150
        sb.append("null");
4151
      } else {
4152
        sb.append(this.status);
4153
      }
4154
      first = false;
4155
      if (!first) sb.append(", ");
695 rajveer 4156
      sb.append("gatewayId:");
4157
      sb.append(this.gatewayId);
123 ashish 4158
      first = false;
4159
      sb.append(")");
4160
      return sb.toString();
4161
    }
4162
 
3430 rajveer 4163
    public void validate() throws org.apache.thrift.TException {
123 ashish 4164
      // check for required fields
4165
    }
4166
 
3430 rajveer 4167
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4168
      try {
4169
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4170
      } catch (org.apache.thrift.TException te) {
4171
        throw new java.io.IOException(te);
4172
      }
4173
    }
4174
 
4175
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4176
      try {
4177
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4178
      } catch (org.apache.thrift.TException te) {
4179
        throw new java.io.IOException(te);
4180
      }
4181
    }
4182
 
123 ashish 4183
  }
4184
 
3430 rajveer 4185
  public static class getPayments_result implements org.apache.thrift.TBase<getPayments_result, getPayments_result._Fields>, java.io.Serializable, Cloneable   {
4186
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayments_result");
123 ashish 4187
 
3430 rajveer 4188
    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);
4189
    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 4190
 
3430 rajveer 4191
    private List<Payment> success; // required
4192
    private PaymentException pe; // required
123 ashish 4193
 
4194
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4195
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
123 ashish 4196
      SUCCESS((short)0, "success"),
4197
      PE((short)1, "pe");
4198
 
4199
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4200
 
4201
      static {
4202
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4203
          byName.put(field.getFieldName(), field);
4204
        }
4205
      }
4206
 
4207
      /**
4208
       * Find the _Fields constant that matches fieldId, or null if its not found.
4209
       */
4210
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4211
        switch(fieldId) {
4212
          case 0: // SUCCESS
4213
            return SUCCESS;
4214
          case 1: // PE
4215
            return PE;
4216
          default:
4217
            return null;
4218
        }
123 ashish 4219
      }
4220
 
4221
      /**
4222
       * Find the _Fields constant that matches fieldId, throwing an exception
4223
       * if it is not found.
4224
       */
4225
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4226
        _Fields fields = findByThriftId(fieldId);
4227
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4228
        return fields;
4229
      }
4230
 
4231
      /**
4232
       * Find the _Fields constant that matches name, or null if its not found.
4233
       */
4234
      public static _Fields findByName(String name) {
4235
        return byName.get(name);
4236
      }
4237
 
4238
      private final short _thriftId;
4239
      private final String _fieldName;
4240
 
4241
      _Fields(short thriftId, String fieldName) {
4242
        _thriftId = thriftId;
4243
        _fieldName = fieldName;
4244
      }
4245
 
4246
      public short getThriftFieldId() {
4247
        return _thriftId;
4248
      }
4249
 
4250
      public String getFieldName() {
4251
        return _fieldName;
4252
      }
4253
    }
4254
 
4255
    // isset id assignments
4256
 
3430 rajveer 4257
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 4258
    static {
3430 rajveer 4259
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4260
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4261
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
4262
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
4263
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4264
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4265
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4266
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayments_result.class, metaDataMap);
123 ashish 4267
    }
4268
 
4269
    public getPayments_result() {
4270
    }
4271
 
4272
    public getPayments_result(
4273
      List<Payment> success,
4274
      PaymentException pe)
4275
    {
4276
      this();
4277
      this.success = success;
4278
      this.pe = pe;
4279
    }
4280
 
4281
    /**
4282
     * Performs a deep copy on <i>other</i>.
4283
     */
4284
    public getPayments_result(getPayments_result other) {
4285
      if (other.isSetSuccess()) {
4286
        List<Payment> __this__success = new ArrayList<Payment>();
4287
        for (Payment other_element : other.success) {
4288
          __this__success.add(new Payment(other_element));
4289
        }
4290
        this.success = __this__success;
4291
      }
4292
      if (other.isSetPe()) {
4293
        this.pe = new PaymentException(other.pe);
4294
      }
4295
    }
4296
 
4297
    public getPayments_result deepCopy() {
4298
      return new getPayments_result(this);
4299
    }
4300
 
3430 rajveer 4301
    @Override
4302
    public void clear() {
4303
      this.success = null;
4304
      this.pe = null;
123 ashish 4305
    }
4306
 
4307
    public int getSuccessSize() {
4308
      return (this.success == null) ? 0 : this.success.size();
4309
    }
4310
 
4311
    public java.util.Iterator<Payment> getSuccessIterator() {
4312
      return (this.success == null) ? null : this.success.iterator();
4313
    }
4314
 
4315
    public void addToSuccess(Payment elem) {
4316
      if (this.success == null) {
4317
        this.success = new ArrayList<Payment>();
4318
      }
4319
      this.success.add(elem);
4320
    }
4321
 
4322
    public List<Payment> getSuccess() {
4323
      return this.success;
4324
    }
4325
 
3430 rajveer 4326
    public void setSuccess(List<Payment> success) {
123 ashish 4327
      this.success = success;
4328
    }
4329
 
4330
    public void unsetSuccess() {
4331
      this.success = null;
4332
    }
4333
 
3430 rajveer 4334
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
123 ashish 4335
    public boolean isSetSuccess() {
4336
      return this.success != null;
4337
    }
4338
 
4339
    public void setSuccessIsSet(boolean value) {
4340
      if (!value) {
4341
        this.success = null;
4342
      }
4343
    }
4344
 
4345
    public PaymentException getPe() {
4346
      return this.pe;
4347
    }
4348
 
3430 rajveer 4349
    public void setPe(PaymentException pe) {
123 ashish 4350
      this.pe = pe;
4351
    }
4352
 
4353
    public void unsetPe() {
4354
      this.pe = null;
4355
    }
4356
 
3430 rajveer 4357
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
123 ashish 4358
    public boolean isSetPe() {
4359
      return this.pe != null;
4360
    }
4361
 
4362
    public void setPeIsSet(boolean value) {
4363
      if (!value) {
4364
        this.pe = null;
4365
      }
4366
    }
4367
 
4368
    public void setFieldValue(_Fields field, Object value) {
4369
      switch (field) {
4370
      case SUCCESS:
4371
        if (value == null) {
4372
          unsetSuccess();
4373
        } else {
4374
          setSuccess((List<Payment>)value);
4375
        }
4376
        break;
4377
 
4378
      case PE:
4379
        if (value == null) {
4380
          unsetPe();
4381
        } else {
4382
          setPe((PaymentException)value);
4383
        }
4384
        break;
4385
 
4386
      }
4387
    }
4388
 
4389
    public Object getFieldValue(_Fields field) {
4390
      switch (field) {
4391
      case SUCCESS:
4392
        return getSuccess();
4393
 
4394
      case PE:
4395
        return getPe();
4396
 
4397
      }
4398
      throw new IllegalStateException();
4399
    }
4400
 
3430 rajveer 4401
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4402
    public boolean isSet(_Fields field) {
4403
      if (field == null) {
4404
        throw new IllegalArgumentException();
4405
      }
123 ashish 4406
 
4407
      switch (field) {
4408
      case SUCCESS:
4409
        return isSetSuccess();
4410
      case PE:
4411
        return isSetPe();
4412
      }
4413
      throw new IllegalStateException();
4414
    }
4415
 
4416
    @Override
4417
    public boolean equals(Object that) {
4418
      if (that == null)
4419
        return false;
4420
      if (that instanceof getPayments_result)
4421
        return this.equals((getPayments_result)that);
4422
      return false;
4423
    }
4424
 
4425
    public boolean equals(getPayments_result that) {
4426
      if (that == null)
4427
        return false;
4428
 
4429
      boolean this_present_success = true && this.isSetSuccess();
4430
      boolean that_present_success = true && that.isSetSuccess();
4431
      if (this_present_success || that_present_success) {
4432
        if (!(this_present_success && that_present_success))
4433
          return false;
4434
        if (!this.success.equals(that.success))
4435
          return false;
4436
      }
4437
 
4438
      boolean this_present_pe = true && this.isSetPe();
4439
      boolean that_present_pe = true && that.isSetPe();
4440
      if (this_present_pe || that_present_pe) {
4441
        if (!(this_present_pe && that_present_pe))
4442
          return false;
4443
        if (!this.pe.equals(that.pe))
4444
          return false;
4445
      }
4446
 
4447
      return true;
4448
    }
4449
 
4450
    @Override
4451
    public int hashCode() {
4452
      return 0;
4453
    }
4454
 
695 rajveer 4455
    public int compareTo(getPayments_result other) {
123 ashish 4456
      if (!getClass().equals(other.getClass())) {
4457
        return getClass().getName().compareTo(other.getClass().getName());
4458
      }
4459
 
4460
      int lastComparison = 0;
695 rajveer 4461
      getPayments_result typedOther = (getPayments_result)other;
123 ashish 4462
 
3430 rajveer 4463
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
123 ashish 4464
      if (lastComparison != 0) {
4465
        return lastComparison;
4466
      }
3430 rajveer 4467
      if (isSetSuccess()) {
4468
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4469
        if (lastComparison != 0) {
4470
          return lastComparison;
4471
        }
123 ashish 4472
      }
3430 rajveer 4473
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 4474
      if (lastComparison != 0) {
4475
        return lastComparison;
123 ashish 4476
      }
3430 rajveer 4477
      if (isSetPe()) {
4478
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
4479
        if (lastComparison != 0) {
4480
          return lastComparison;
4481
        }
123 ashish 4482
      }
4483
      return 0;
4484
    }
4485
 
3430 rajveer 4486
    public _Fields fieldForId(int fieldId) {
4487
      return _Fields.findByThriftId(fieldId);
4488
    }
4489
 
4490
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4491
      org.apache.thrift.protocol.TField field;
123 ashish 4492
      iprot.readStructBegin();
4493
      while (true)
4494
      {
4495
        field = iprot.readFieldBegin();
3430 rajveer 4496
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 4497
          break;
4498
        }
3430 rajveer 4499
        switch (field.id) {
4500
          case 0: // SUCCESS
4501
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
4502
              {
4503
                org.apache.thrift.protocol.TList _list16 = iprot.readListBegin();
4504
                this.success = new ArrayList<Payment>(_list16.size);
4505
                for (int _i17 = 0; _i17 < _list16.size; ++_i17)
420 ashish 4506
                {
3430 rajveer 4507
                  Payment _elem18; // required
4508
                  _elem18 = new Payment();
4509
                  _elem18.read(iprot);
4510
                  this.success.add(_elem18);
420 ashish 4511
                }
3430 rajveer 4512
                iprot.readListEnd();
123 ashish 4513
              }
3430 rajveer 4514
            } else { 
4515
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4516
            }
4517
            break;
4518
          case 1: // PE
4519
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4520
              this.pe = new PaymentException();
4521
              this.pe.read(iprot);
4522
            } else { 
4523
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4524
            }
4525
            break;
4526
          default:
4527
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 4528
        }
3430 rajveer 4529
        iprot.readFieldEnd();
123 ashish 4530
      }
4531
      iprot.readStructEnd();
4532
      validate();
4533
    }
4534
 
3430 rajveer 4535
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 4536
      oprot.writeStructBegin(STRUCT_DESC);
4537
 
4538
      if (this.isSetSuccess()) {
4539
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
420 ashish 4540
        {
3430 rajveer 4541
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
2747 chandransh 4542
          for (Payment _iter19 : this.success)
420 ashish 4543
          {
2747 chandransh 4544
            _iter19.write(oprot);
420 ashish 4545
          }
4546
          oprot.writeListEnd();
4547
        }
123 ashish 4548
        oprot.writeFieldEnd();
4549
      } else if (this.isSetPe()) {
4550
        oprot.writeFieldBegin(PE_FIELD_DESC);
4551
        this.pe.write(oprot);
4552
        oprot.writeFieldEnd();
4553
      }
4554
      oprot.writeFieldStop();
4555
      oprot.writeStructEnd();
4556
    }
4557
 
4558
    @Override
4559
    public String toString() {
695 rajveer 4560
      StringBuilder sb = new StringBuilder("getPayments_result(");
123 ashish 4561
      boolean first = true;
4562
 
4563
      sb.append("success:");
4564
      if (this.success == null) {
4565
        sb.append("null");
4566
      } else {
4567
        sb.append(this.success);
4568
      }
4569
      first = false;
4570
      if (!first) sb.append(", ");
4571
      sb.append("pe:");
4572
      if (this.pe == null) {
4573
        sb.append("null");
4574
      } else {
4575
        sb.append(this.pe);
4576
      }
4577
      first = false;
4578
      sb.append(")");
4579
      return sb.toString();
4580
    }
4581
 
3430 rajveer 4582
    public void validate() throws org.apache.thrift.TException {
123 ashish 4583
      // check for required fields
4584
    }
4585
 
3430 rajveer 4586
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4587
      try {
4588
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4589
      } catch (org.apache.thrift.TException te) {
4590
        throw new java.io.IOException(te);
4591
      }
4592
    }
4593
 
4594
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4595
      try {
4596
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4597
      } catch (org.apache.thrift.TException te) {
4598
        throw new java.io.IOException(te);
4599
      }
4600
    }
4601
 
123 ashish 4602
  }
4603
 
4141 chandransh 4604
  public static class getPaymentsByCapturedDate_args implements org.apache.thrift.TBase<getPaymentsByCapturedDate_args, getPaymentsByCapturedDate_args._Fields>, java.io.Serializable, Cloneable   {
4605
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsByCapturedDate_args");
4606
 
4607
    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);
4608
    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);
4609
    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);
4610
 
4611
    private long fromTime; // required
4612
    private long toTime; // required
4613
    private long gatewayId; // required
4614
 
4615
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4616
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4617
      FROM_TIME((short)1, "fromTime"),
4618
      TO_TIME((short)2, "toTime"),
4619
      GATEWAY_ID((short)3, "gatewayId");
4620
 
4621
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4622
 
4623
      static {
4624
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4625
          byName.put(field.getFieldName(), field);
4626
        }
4627
      }
4628
 
4629
      /**
4630
       * Find the _Fields constant that matches fieldId, or null if its not found.
4631
       */
4632
      public static _Fields findByThriftId(int fieldId) {
4633
        switch(fieldId) {
4634
          case 1: // FROM_TIME
4635
            return FROM_TIME;
4636
          case 2: // TO_TIME
4637
            return TO_TIME;
4638
          case 3: // GATEWAY_ID
4639
            return GATEWAY_ID;
4640
          default:
4641
            return null;
4642
        }
4643
      }
4644
 
4645
      /**
4646
       * Find the _Fields constant that matches fieldId, throwing an exception
4647
       * if it is not found.
4648
       */
4649
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4650
        _Fields fields = findByThriftId(fieldId);
4651
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4652
        return fields;
4653
      }
4654
 
4655
      /**
4656
       * Find the _Fields constant that matches name, or null if its not found.
4657
       */
4658
      public static _Fields findByName(String name) {
4659
        return byName.get(name);
4660
      }
4661
 
4662
      private final short _thriftId;
4663
      private final String _fieldName;
4664
 
4665
      _Fields(short thriftId, String fieldName) {
4666
        _thriftId = thriftId;
4667
        _fieldName = fieldName;
4668
      }
4669
 
4670
      public short getThriftFieldId() {
4671
        return _thriftId;
4672
      }
4673
 
4674
      public String getFieldName() {
4675
        return _fieldName;
4676
      }
4677
    }
4678
 
4679
    // isset id assignments
4680
    private static final int __FROMTIME_ISSET_ID = 0;
4681
    private static final int __TOTIME_ISSET_ID = 1;
4682
    private static final int __GATEWAYID_ISSET_ID = 2;
4683
    private BitSet __isset_bit_vector = new BitSet(3);
4684
 
4685
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4686
    static {
4687
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4688
      tmpMap.put(_Fields.FROM_TIME, new org.apache.thrift.meta_data.FieldMetaData("fromTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4689
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4690
      tmpMap.put(_Fields.TO_TIME, new org.apache.thrift.meta_data.FieldMetaData("toTime", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4691
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4692
      tmpMap.put(_Fields.GATEWAY_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4693
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4694
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4695
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsByCapturedDate_args.class, metaDataMap);
4696
    }
4697
 
4698
    public getPaymentsByCapturedDate_args() {
4699
    }
4700
 
4701
    public getPaymentsByCapturedDate_args(
4702
      long fromTime,
4703
      long toTime,
4704
      long gatewayId)
4705
    {
4706
      this();
4707
      this.fromTime = fromTime;
4708
      setFromTimeIsSet(true);
4709
      this.toTime = toTime;
4710
      setToTimeIsSet(true);
4711
      this.gatewayId = gatewayId;
4712
      setGatewayIdIsSet(true);
4713
    }
4714
 
4715
    /**
4716
     * Performs a deep copy on <i>other</i>.
4717
     */
4718
    public getPaymentsByCapturedDate_args(getPaymentsByCapturedDate_args other) {
4719
      __isset_bit_vector.clear();
4720
      __isset_bit_vector.or(other.__isset_bit_vector);
4721
      this.fromTime = other.fromTime;
4722
      this.toTime = other.toTime;
4723
      this.gatewayId = other.gatewayId;
4724
    }
4725
 
4726
    public getPaymentsByCapturedDate_args deepCopy() {
4727
      return new getPaymentsByCapturedDate_args(this);
4728
    }
4729
 
4730
    @Override
4731
    public void clear() {
4732
      setFromTimeIsSet(false);
4733
      this.fromTime = 0;
4734
      setToTimeIsSet(false);
4735
      this.toTime = 0;
4736
      setGatewayIdIsSet(false);
4737
      this.gatewayId = 0;
4738
    }
4739
 
4740
    public long getFromTime() {
4741
      return this.fromTime;
4742
    }
4743
 
4744
    public void setFromTime(long fromTime) {
4745
      this.fromTime = fromTime;
4746
      setFromTimeIsSet(true);
4747
    }
4748
 
4749
    public void unsetFromTime() {
4750
      __isset_bit_vector.clear(__FROMTIME_ISSET_ID);
4751
    }
4752
 
4753
    /** Returns true if field fromTime is set (has been assigned a value) and false otherwise */
4754
    public boolean isSetFromTime() {
4755
      return __isset_bit_vector.get(__FROMTIME_ISSET_ID);
4756
    }
4757
 
4758
    public void setFromTimeIsSet(boolean value) {
4759
      __isset_bit_vector.set(__FROMTIME_ISSET_ID, value);
4760
    }
4761
 
4762
    public long getToTime() {
4763
      return this.toTime;
4764
    }
4765
 
4766
    public void setToTime(long toTime) {
4767
      this.toTime = toTime;
4768
      setToTimeIsSet(true);
4769
    }
4770
 
4771
    public void unsetToTime() {
4772
      __isset_bit_vector.clear(__TOTIME_ISSET_ID);
4773
    }
4774
 
4775
    /** Returns true if field toTime is set (has been assigned a value) and false otherwise */
4776
    public boolean isSetToTime() {
4777
      return __isset_bit_vector.get(__TOTIME_ISSET_ID);
4778
    }
4779
 
4780
    public void setToTimeIsSet(boolean value) {
4781
      __isset_bit_vector.set(__TOTIME_ISSET_ID, value);
4782
    }
4783
 
4784
    public long getGatewayId() {
4785
      return this.gatewayId;
4786
    }
4787
 
4788
    public void setGatewayId(long gatewayId) {
4789
      this.gatewayId = gatewayId;
4790
      setGatewayIdIsSet(true);
4791
    }
4792
 
4793
    public void unsetGatewayId() {
4794
      __isset_bit_vector.clear(__GATEWAYID_ISSET_ID);
4795
    }
4796
 
4797
    /** Returns true if field gatewayId is set (has been assigned a value) and false otherwise */
4798
    public boolean isSetGatewayId() {
4799
      return __isset_bit_vector.get(__GATEWAYID_ISSET_ID);
4800
    }
4801
 
4802
    public void setGatewayIdIsSet(boolean value) {
4803
      __isset_bit_vector.set(__GATEWAYID_ISSET_ID, value);
4804
    }
4805
 
4806
    public void setFieldValue(_Fields field, Object value) {
4807
      switch (field) {
4808
      case FROM_TIME:
4809
        if (value == null) {
4810
          unsetFromTime();
4811
        } else {
4812
          setFromTime((Long)value);
4813
        }
4814
        break;
4815
 
4816
      case TO_TIME:
4817
        if (value == null) {
4818
          unsetToTime();
4819
        } else {
4820
          setToTime((Long)value);
4821
        }
4822
        break;
4823
 
4824
      case GATEWAY_ID:
4825
        if (value == null) {
4826
          unsetGatewayId();
4827
        } else {
4828
          setGatewayId((Long)value);
4829
        }
4830
        break;
4831
 
4832
      }
4833
    }
4834
 
4835
    public Object getFieldValue(_Fields field) {
4836
      switch (field) {
4837
      case FROM_TIME:
4838
        return Long.valueOf(getFromTime());
4839
 
4840
      case TO_TIME:
4841
        return Long.valueOf(getToTime());
4842
 
4843
      case GATEWAY_ID:
4844
        return Long.valueOf(getGatewayId());
4845
 
4846
      }
4847
      throw new IllegalStateException();
4848
    }
4849
 
4850
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4851
    public boolean isSet(_Fields field) {
4852
      if (field == null) {
4853
        throw new IllegalArgumentException();
4854
      }
4855
 
4856
      switch (field) {
4857
      case FROM_TIME:
4858
        return isSetFromTime();
4859
      case TO_TIME:
4860
        return isSetToTime();
4861
      case GATEWAY_ID:
4862
        return isSetGatewayId();
4863
      }
4864
      throw new IllegalStateException();
4865
    }
4866
 
4867
    @Override
4868
    public boolean equals(Object that) {
4869
      if (that == null)
4870
        return false;
4871
      if (that instanceof getPaymentsByCapturedDate_args)
4872
        return this.equals((getPaymentsByCapturedDate_args)that);
4873
      return false;
4874
    }
4875
 
4876
    public boolean equals(getPaymentsByCapturedDate_args that) {
4877
      if (that == null)
4878
        return false;
4879
 
4880
      boolean this_present_fromTime = true;
4881
      boolean that_present_fromTime = true;
4882
      if (this_present_fromTime || that_present_fromTime) {
4883
        if (!(this_present_fromTime && that_present_fromTime))
4884
          return false;
4885
        if (this.fromTime != that.fromTime)
4886
          return false;
4887
      }
4888
 
4889
      boolean this_present_toTime = true;
4890
      boolean that_present_toTime = true;
4891
      if (this_present_toTime || that_present_toTime) {
4892
        if (!(this_present_toTime && that_present_toTime))
4893
          return false;
4894
        if (this.toTime != that.toTime)
4895
          return false;
4896
      }
4897
 
4898
      boolean this_present_gatewayId = true;
4899
      boolean that_present_gatewayId = true;
4900
      if (this_present_gatewayId || that_present_gatewayId) {
4901
        if (!(this_present_gatewayId && that_present_gatewayId))
4902
          return false;
4903
        if (this.gatewayId != that.gatewayId)
4904
          return false;
4905
      }
4906
 
4907
      return true;
4908
    }
4909
 
4910
    @Override
4911
    public int hashCode() {
4912
      return 0;
4913
    }
4914
 
4915
    public int compareTo(getPaymentsByCapturedDate_args other) {
4916
      if (!getClass().equals(other.getClass())) {
4917
        return getClass().getName().compareTo(other.getClass().getName());
4918
      }
4919
 
4920
      int lastComparison = 0;
4921
      getPaymentsByCapturedDate_args typedOther = (getPaymentsByCapturedDate_args)other;
4922
 
4923
      lastComparison = Boolean.valueOf(isSetFromTime()).compareTo(typedOther.isSetFromTime());
4924
      if (lastComparison != 0) {
4925
        return lastComparison;
4926
      }
4927
      if (isSetFromTime()) {
4928
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromTime, typedOther.fromTime);
4929
        if (lastComparison != 0) {
4930
          return lastComparison;
4931
        }
4932
      }
4933
      lastComparison = Boolean.valueOf(isSetToTime()).compareTo(typedOther.isSetToTime());
4934
      if (lastComparison != 0) {
4935
        return lastComparison;
4936
      }
4937
      if (isSetToTime()) {
4938
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toTime, typedOther.toTime);
4939
        if (lastComparison != 0) {
4940
          return lastComparison;
4941
        }
4942
      }
4943
      lastComparison = Boolean.valueOf(isSetGatewayId()).compareTo(typedOther.isSetGatewayId());
4944
      if (lastComparison != 0) {
4945
        return lastComparison;
4946
      }
4947
      if (isSetGatewayId()) {
4948
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayId, typedOther.gatewayId);
4949
        if (lastComparison != 0) {
4950
          return lastComparison;
4951
        }
4952
      }
4953
      return 0;
4954
    }
4955
 
4956
    public _Fields fieldForId(int fieldId) {
4957
      return _Fields.findByThriftId(fieldId);
4958
    }
4959
 
4960
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4961
      org.apache.thrift.protocol.TField field;
4962
      iprot.readStructBegin();
4963
      while (true)
4964
      {
4965
        field = iprot.readFieldBegin();
4966
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4967
          break;
4968
        }
4969
        switch (field.id) {
4970
          case 1: // FROM_TIME
4971
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4972
              this.fromTime = iprot.readI64();
4973
              setFromTimeIsSet(true);
4974
            } else { 
4975
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4976
            }
4977
            break;
4978
          case 2: // TO_TIME
4979
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4980
              this.toTime = iprot.readI64();
4981
              setToTimeIsSet(true);
4982
            } else { 
4983
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4984
            }
4985
            break;
4986
          case 3: // GATEWAY_ID
4987
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4988
              this.gatewayId = iprot.readI64();
4989
              setGatewayIdIsSet(true);
4990
            } else { 
4991
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4992
            }
4993
            break;
4994
          default:
4995
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4996
        }
4997
        iprot.readFieldEnd();
4998
      }
4999
      iprot.readStructEnd();
5000
      validate();
5001
    }
5002
 
5003
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5004
      validate();
5005
 
5006
      oprot.writeStructBegin(STRUCT_DESC);
5007
      oprot.writeFieldBegin(FROM_TIME_FIELD_DESC);
5008
      oprot.writeI64(this.fromTime);
5009
      oprot.writeFieldEnd();
5010
      oprot.writeFieldBegin(TO_TIME_FIELD_DESC);
5011
      oprot.writeI64(this.toTime);
5012
      oprot.writeFieldEnd();
5013
      oprot.writeFieldBegin(GATEWAY_ID_FIELD_DESC);
5014
      oprot.writeI64(this.gatewayId);
5015
      oprot.writeFieldEnd();
5016
      oprot.writeFieldStop();
5017
      oprot.writeStructEnd();
5018
    }
5019
 
5020
    @Override
5021
    public String toString() {
5022
      StringBuilder sb = new StringBuilder("getPaymentsByCapturedDate_args(");
5023
      boolean first = true;
5024
 
5025
      sb.append("fromTime:");
5026
      sb.append(this.fromTime);
5027
      first = false;
5028
      if (!first) sb.append(", ");
5029
      sb.append("toTime:");
5030
      sb.append(this.toTime);
5031
      first = false;
5032
      if (!first) sb.append(", ");
5033
      sb.append("gatewayId:");
5034
      sb.append(this.gatewayId);
5035
      first = false;
5036
      sb.append(")");
5037
      return sb.toString();
5038
    }
5039
 
5040
    public void validate() throws org.apache.thrift.TException {
5041
      // check for required fields
5042
    }
5043
 
5044
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5045
      try {
5046
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5047
      } catch (org.apache.thrift.TException te) {
5048
        throw new java.io.IOException(te);
5049
      }
5050
    }
5051
 
5052
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5053
      try {
5054
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5055
      } catch (org.apache.thrift.TException te) {
5056
        throw new java.io.IOException(te);
5057
      }
5058
    }
5059
 
5060
  }
5061
 
5062
  public static class getPaymentsByCapturedDate_result implements org.apache.thrift.TBase<getPaymentsByCapturedDate_result, getPaymentsByCapturedDate_result._Fields>, java.io.Serializable, Cloneable   {
5063
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsByCapturedDate_result");
5064
 
5065
    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);
5066
    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);
5067
 
5068
    private List<Payment> success; // required
5069
    private PaymentException pe; // required
5070
 
5071
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5072
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5073
      SUCCESS((short)0, "success"),
5074
      PE((short)1, "pe");
5075
 
5076
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5077
 
5078
      static {
5079
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5080
          byName.put(field.getFieldName(), field);
5081
        }
5082
      }
5083
 
5084
      /**
5085
       * Find the _Fields constant that matches fieldId, or null if its not found.
5086
       */
5087
      public static _Fields findByThriftId(int fieldId) {
5088
        switch(fieldId) {
5089
          case 0: // SUCCESS
5090
            return SUCCESS;
5091
          case 1: // PE
5092
            return PE;
5093
          default:
5094
            return null;
5095
        }
5096
      }
5097
 
5098
      /**
5099
       * Find the _Fields constant that matches fieldId, throwing an exception
5100
       * if it is not found.
5101
       */
5102
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5103
        _Fields fields = findByThriftId(fieldId);
5104
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5105
        return fields;
5106
      }
5107
 
5108
      /**
5109
       * Find the _Fields constant that matches name, or null if its not found.
5110
       */
5111
      public static _Fields findByName(String name) {
5112
        return byName.get(name);
5113
      }
5114
 
5115
      private final short _thriftId;
5116
      private final String _fieldName;
5117
 
5118
      _Fields(short thriftId, String fieldName) {
5119
        _thriftId = thriftId;
5120
        _fieldName = fieldName;
5121
      }
5122
 
5123
      public short getThriftFieldId() {
5124
        return _thriftId;
5125
      }
5126
 
5127
      public String getFieldName() {
5128
        return _fieldName;
5129
      }
5130
    }
5131
 
5132
    // isset id assignments
5133
 
5134
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5135
    static {
5136
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5137
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5138
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
5139
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
5140
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5141
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5142
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5143
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsByCapturedDate_result.class, metaDataMap);
5144
    }
5145
 
5146
    public getPaymentsByCapturedDate_result() {
5147
    }
5148
 
5149
    public getPaymentsByCapturedDate_result(
5150
      List<Payment> success,
5151
      PaymentException pe)
5152
    {
5153
      this();
5154
      this.success = success;
5155
      this.pe = pe;
5156
    }
5157
 
5158
    /**
5159
     * Performs a deep copy on <i>other</i>.
5160
     */
5161
    public getPaymentsByCapturedDate_result(getPaymentsByCapturedDate_result other) {
5162
      if (other.isSetSuccess()) {
5163
        List<Payment> __this__success = new ArrayList<Payment>();
5164
        for (Payment other_element : other.success) {
5165
          __this__success.add(new Payment(other_element));
5166
        }
5167
        this.success = __this__success;
5168
      }
5169
      if (other.isSetPe()) {
5170
        this.pe = new PaymentException(other.pe);
5171
      }
5172
    }
5173
 
5174
    public getPaymentsByCapturedDate_result deepCopy() {
5175
      return new getPaymentsByCapturedDate_result(this);
5176
    }
5177
 
5178
    @Override
5179
    public void clear() {
5180
      this.success = null;
5181
      this.pe = null;
5182
    }
5183
 
5184
    public int getSuccessSize() {
5185
      return (this.success == null) ? 0 : this.success.size();
5186
    }
5187
 
5188
    public java.util.Iterator<Payment> getSuccessIterator() {
5189
      return (this.success == null) ? null : this.success.iterator();
5190
    }
5191
 
5192
    public void addToSuccess(Payment elem) {
5193
      if (this.success == null) {
5194
        this.success = new ArrayList<Payment>();
5195
      }
5196
      this.success.add(elem);
5197
    }
5198
 
5199
    public List<Payment> getSuccess() {
5200
      return this.success;
5201
    }
5202
 
5203
    public void setSuccess(List<Payment> success) {
5204
      this.success = success;
5205
    }
5206
 
5207
    public void unsetSuccess() {
5208
      this.success = null;
5209
    }
5210
 
5211
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
5212
    public boolean isSetSuccess() {
5213
      return this.success != null;
5214
    }
5215
 
5216
    public void setSuccessIsSet(boolean value) {
5217
      if (!value) {
5218
        this.success = null;
5219
      }
5220
    }
5221
 
5222
    public PaymentException getPe() {
5223
      return this.pe;
5224
    }
5225
 
5226
    public void setPe(PaymentException pe) {
5227
      this.pe = pe;
5228
    }
5229
 
5230
    public void unsetPe() {
5231
      this.pe = null;
5232
    }
5233
 
5234
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
5235
    public boolean isSetPe() {
5236
      return this.pe != null;
5237
    }
5238
 
5239
    public void setPeIsSet(boolean value) {
5240
      if (!value) {
5241
        this.pe = null;
5242
      }
5243
    }
5244
 
5245
    public void setFieldValue(_Fields field, Object value) {
5246
      switch (field) {
5247
      case SUCCESS:
5248
        if (value == null) {
5249
          unsetSuccess();
5250
        } else {
5251
          setSuccess((List<Payment>)value);
5252
        }
5253
        break;
5254
 
5255
      case PE:
5256
        if (value == null) {
5257
          unsetPe();
5258
        } else {
5259
          setPe((PaymentException)value);
5260
        }
5261
        break;
5262
 
5263
      }
5264
    }
5265
 
5266
    public Object getFieldValue(_Fields field) {
5267
      switch (field) {
5268
      case SUCCESS:
5269
        return getSuccess();
5270
 
5271
      case PE:
5272
        return getPe();
5273
 
5274
      }
5275
      throw new IllegalStateException();
5276
    }
5277
 
5278
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5279
    public boolean isSet(_Fields field) {
5280
      if (field == null) {
5281
        throw new IllegalArgumentException();
5282
      }
5283
 
5284
      switch (field) {
5285
      case SUCCESS:
5286
        return isSetSuccess();
5287
      case PE:
5288
        return isSetPe();
5289
      }
5290
      throw new IllegalStateException();
5291
    }
5292
 
5293
    @Override
5294
    public boolean equals(Object that) {
5295
      if (that == null)
5296
        return false;
5297
      if (that instanceof getPaymentsByCapturedDate_result)
5298
        return this.equals((getPaymentsByCapturedDate_result)that);
5299
      return false;
5300
    }
5301
 
5302
    public boolean equals(getPaymentsByCapturedDate_result that) {
5303
      if (that == null)
5304
        return false;
5305
 
5306
      boolean this_present_success = true && this.isSetSuccess();
5307
      boolean that_present_success = true && that.isSetSuccess();
5308
      if (this_present_success || that_present_success) {
5309
        if (!(this_present_success && that_present_success))
5310
          return false;
5311
        if (!this.success.equals(that.success))
5312
          return false;
5313
      }
5314
 
5315
      boolean this_present_pe = true && this.isSetPe();
5316
      boolean that_present_pe = true && that.isSetPe();
5317
      if (this_present_pe || that_present_pe) {
5318
        if (!(this_present_pe && that_present_pe))
5319
          return false;
5320
        if (!this.pe.equals(that.pe))
5321
          return false;
5322
      }
5323
 
5324
      return true;
5325
    }
5326
 
5327
    @Override
5328
    public int hashCode() {
5329
      return 0;
5330
    }
5331
 
5332
    public int compareTo(getPaymentsByCapturedDate_result other) {
5333
      if (!getClass().equals(other.getClass())) {
5334
        return getClass().getName().compareTo(other.getClass().getName());
5335
      }
5336
 
5337
      int lastComparison = 0;
5338
      getPaymentsByCapturedDate_result typedOther = (getPaymentsByCapturedDate_result)other;
5339
 
5340
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
5341
      if (lastComparison != 0) {
5342
        return lastComparison;
5343
      }
5344
      if (isSetSuccess()) {
5345
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
5346
        if (lastComparison != 0) {
5347
          return lastComparison;
5348
        }
5349
      }
5350
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
5351
      if (lastComparison != 0) {
5352
        return lastComparison;
5353
      }
5354
      if (isSetPe()) {
5355
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
5356
        if (lastComparison != 0) {
5357
          return lastComparison;
5358
        }
5359
      }
5360
      return 0;
5361
    }
5362
 
5363
    public _Fields fieldForId(int fieldId) {
5364
      return _Fields.findByThriftId(fieldId);
5365
    }
5366
 
5367
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5368
      org.apache.thrift.protocol.TField field;
5369
      iprot.readStructBegin();
5370
      while (true)
5371
      {
5372
        field = iprot.readFieldBegin();
5373
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5374
          break;
5375
        }
5376
        switch (field.id) {
5377
          case 0: // SUCCESS
5378
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
5379
              {
5380
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
5381
                this.success = new ArrayList<Payment>(_list20.size);
5382
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
5383
                {
5384
                  Payment _elem22; // required
5385
                  _elem22 = new Payment();
5386
                  _elem22.read(iprot);
5387
                  this.success.add(_elem22);
5388
                }
5389
                iprot.readListEnd();
5390
              }
5391
            } else { 
5392
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5393
            }
5394
            break;
5395
          case 1: // PE
5396
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5397
              this.pe = new PaymentException();
5398
              this.pe.read(iprot);
5399
            } else { 
5400
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5401
            }
5402
            break;
5403
          default:
5404
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5405
        }
5406
        iprot.readFieldEnd();
5407
      }
5408
      iprot.readStructEnd();
5409
      validate();
5410
    }
5411
 
5412
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5413
      oprot.writeStructBegin(STRUCT_DESC);
5414
 
5415
      if (this.isSetSuccess()) {
5416
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
5417
        {
5418
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
5419
          for (Payment _iter23 : this.success)
5420
          {
5421
            _iter23.write(oprot);
5422
          }
5423
          oprot.writeListEnd();
5424
        }
5425
        oprot.writeFieldEnd();
5426
      } else if (this.isSetPe()) {
5427
        oprot.writeFieldBegin(PE_FIELD_DESC);
5428
        this.pe.write(oprot);
5429
        oprot.writeFieldEnd();
5430
      }
5431
      oprot.writeFieldStop();
5432
      oprot.writeStructEnd();
5433
    }
5434
 
5435
    @Override
5436
    public String toString() {
5437
      StringBuilder sb = new StringBuilder("getPaymentsByCapturedDate_result(");
5438
      boolean first = true;
5439
 
5440
      sb.append("success:");
5441
      if (this.success == null) {
5442
        sb.append("null");
5443
      } else {
5444
        sb.append(this.success);
5445
      }
5446
      first = false;
5447
      if (!first) sb.append(", ");
5448
      sb.append("pe:");
5449
      if (this.pe == null) {
5450
        sb.append("null");
5451
      } else {
5452
        sb.append(this.pe);
5453
      }
5454
      first = false;
5455
      sb.append(")");
5456
      return sb.toString();
5457
    }
5458
 
5459
    public void validate() throws org.apache.thrift.TException {
5460
      // check for required fields
5461
    }
5462
 
5463
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5464
      try {
5465
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5466
      } catch (org.apache.thrift.TException te) {
5467
        throw new java.io.IOException(te);
5468
      }
5469
    }
5470
 
5471
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5472
      try {
5473
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5474
      } catch (org.apache.thrift.TException te) {
5475
        throw new java.io.IOException(te);
5476
      }
5477
    }
5478
 
5479
  }
5480
 
3430 rajveer 5481
  public static class getPaymentGateway_args implements org.apache.thrift.TBase<getPaymentGateway_args, getPaymentGateway_args._Fields>, java.io.Serializable, Cloneable   {
5482
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentGateway_args");
123 ashish 5483
 
3430 rajveer 5484
    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 5485
 
3430 rajveer 5486
    private long id; // required
123 ashish 5487
 
5488
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5489
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 5490
      ID((short)1, "id");
123 ashish 5491
 
5492
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5493
 
5494
      static {
5495
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5496
          byName.put(field.getFieldName(), field);
5497
        }
5498
      }
5499
 
5500
      /**
5501
       * Find the _Fields constant that matches fieldId, or null if its not found.
5502
       */
5503
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 5504
        switch(fieldId) {
5505
          case 1: // ID
5506
            return ID;
5507
          default:
5508
            return null;
5509
        }
123 ashish 5510
      }
5511
 
5512
      /**
5513
       * Find the _Fields constant that matches fieldId, throwing an exception
5514
       * if it is not found.
5515
       */
5516
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5517
        _Fields fields = findByThriftId(fieldId);
5518
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5519
        return fields;
5520
      }
5521
 
5522
      /**
5523
       * Find the _Fields constant that matches name, or null if its not found.
5524
       */
5525
      public static _Fields findByName(String name) {
5526
        return byName.get(name);
5527
      }
5528
 
5529
      private final short _thriftId;
5530
      private final String _fieldName;
5531
 
5532
      _Fields(short thriftId, String fieldName) {
5533
        _thriftId = thriftId;
5534
        _fieldName = fieldName;
5535
      }
5536
 
5537
      public short getThriftFieldId() {
5538
        return _thriftId;
5539
      }
5540
 
5541
      public String getFieldName() {
5542
        return _fieldName;
5543
      }
5544
    }
5545
 
5546
    // isset id assignments
420 ashish 5547
    private static final int __ID_ISSET_ID = 0;
123 ashish 5548
    private BitSet __isset_bit_vector = new BitSet(1);
5549
 
3430 rajveer 5550
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
123 ashish 5551
    static {
3430 rajveer 5552
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5553
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5554
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5555
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5556
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentGateway_args.class, metaDataMap);
123 ashish 5557
    }
5558
 
695 rajveer 5559
    public getPaymentGateway_args() {
123 ashish 5560
    }
5561
 
695 rajveer 5562
    public getPaymentGateway_args(
5563
      long id)
123 ashish 5564
    {
5565
      this();
420 ashish 5566
      this.id = id;
5567
      setIdIsSet(true);
123 ashish 5568
    }
5569
 
5570
    /**
5571
     * Performs a deep copy on <i>other</i>.
5572
     */
695 rajveer 5573
    public getPaymentGateway_args(getPaymentGateway_args other) {
123 ashish 5574
      __isset_bit_vector.clear();
5575
      __isset_bit_vector.or(other.__isset_bit_vector);
420 ashish 5576
      this.id = other.id;
123 ashish 5577
    }
5578
 
695 rajveer 5579
    public getPaymentGateway_args deepCopy() {
5580
      return new getPaymentGateway_args(this);
123 ashish 5581
    }
5582
 
3430 rajveer 5583
    @Override
5584
    public void clear() {
5585
      setIdIsSet(false);
5586
      this.id = 0;
123 ashish 5587
    }
5588
 
420 ashish 5589
    public long getId() {
5590
      return this.id;
123 ashish 5591
    }
5592
 
3430 rajveer 5593
    public void setId(long id) {
420 ashish 5594
      this.id = id;
5595
      setIdIsSet(true);
123 ashish 5596
    }
5597
 
420 ashish 5598
    public void unsetId() {
5599
      __isset_bit_vector.clear(__ID_ISSET_ID);
123 ashish 5600
    }
5601
 
3430 rajveer 5602
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 5603
    public boolean isSetId() {
5604
      return __isset_bit_vector.get(__ID_ISSET_ID);
123 ashish 5605
    }
5606
 
420 ashish 5607
    public void setIdIsSet(boolean value) {
5608
      __isset_bit_vector.set(__ID_ISSET_ID, value);
123 ashish 5609
    }
5610
 
5611
    public void setFieldValue(_Fields field, Object value) {
5612
      switch (field) {
420 ashish 5613
      case ID:
123 ashish 5614
        if (value == null) {
420 ashish 5615
          unsetId();
123 ashish 5616
        } else {
420 ashish 5617
          setId((Long)value);
123 ashish 5618
        }
5619
        break;
5620
 
5621
      }
5622
    }
5623
 
5624
    public Object getFieldValue(_Fields field) {
5625
      switch (field) {
420 ashish 5626
      case ID:
3430 rajveer 5627
        return Long.valueOf(getId());
123 ashish 5628
 
5629
      }
5630
      throw new IllegalStateException();
5631
    }
5632
 
3430 rajveer 5633
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5634
    public boolean isSet(_Fields field) {
5635
      if (field == null) {
5636
        throw new IllegalArgumentException();
5637
      }
123 ashish 5638
 
5639
      switch (field) {
420 ashish 5640
      case ID:
5641
        return isSetId();
123 ashish 5642
      }
5643
      throw new IllegalStateException();
5644
    }
5645
 
5646
    @Override
5647
    public boolean equals(Object that) {
5648
      if (that == null)
5649
        return false;
695 rajveer 5650
      if (that instanceof getPaymentGateway_args)
5651
        return this.equals((getPaymentGateway_args)that);
123 ashish 5652
      return false;
5653
    }
5654
 
695 rajveer 5655
    public boolean equals(getPaymentGateway_args that) {
123 ashish 5656
      if (that == null)
5657
        return false;
5658
 
420 ashish 5659
      boolean this_present_id = true;
5660
      boolean that_present_id = true;
5661
      if (this_present_id || that_present_id) {
5662
        if (!(this_present_id && that_present_id))
123 ashish 5663
          return false;
420 ashish 5664
        if (this.id != that.id)
123 ashish 5665
          return false;
5666
      }
5667
 
5668
      return true;
5669
    }
5670
 
5671
    @Override
5672
    public int hashCode() {
5673
      return 0;
5674
    }
5675
 
695 rajveer 5676
    public int compareTo(getPaymentGateway_args other) {
123 ashish 5677
      if (!getClass().equals(other.getClass())) {
5678
        return getClass().getName().compareTo(other.getClass().getName());
5679
      }
5680
 
5681
      int lastComparison = 0;
695 rajveer 5682
      getPaymentGateway_args typedOther = (getPaymentGateway_args)other;
123 ashish 5683
 
3430 rajveer 5684
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
123 ashish 5685
      if (lastComparison != 0) {
5686
        return lastComparison;
5687
      }
3430 rajveer 5688
      if (isSetId()) {
5689
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
5690
        if (lastComparison != 0) {
5691
          return lastComparison;
5692
        }
123 ashish 5693
      }
5694
      return 0;
5695
    }
5696
 
3430 rajveer 5697
    public _Fields fieldForId(int fieldId) {
5698
      return _Fields.findByThriftId(fieldId);
5699
    }
5700
 
5701
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5702
      org.apache.thrift.protocol.TField field;
123 ashish 5703
      iprot.readStructBegin();
5704
      while (true)
5705
      {
5706
        field = iprot.readFieldBegin();
3430 rajveer 5707
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
123 ashish 5708
          break;
5709
        }
3430 rajveer 5710
        switch (field.id) {
5711
          case 1: // ID
5712
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5713
              this.id = iprot.readI64();
5714
              setIdIsSet(true);
5715
            } else { 
5716
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5717
            }
5718
            break;
5719
          default:
5720
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
123 ashish 5721
        }
3430 rajveer 5722
        iprot.readFieldEnd();
123 ashish 5723
      }
5724
      iprot.readStructEnd();
5725
      validate();
5726
    }
5727
 
3430 rajveer 5728
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
123 ashish 5729
      validate();
5730
 
5731
      oprot.writeStructBegin(STRUCT_DESC);
420 ashish 5732
      oprot.writeFieldBegin(ID_FIELD_DESC);
5733
      oprot.writeI64(this.id);
123 ashish 5734
      oprot.writeFieldEnd();
5735
      oprot.writeFieldStop();
5736
      oprot.writeStructEnd();
5737
    }
5738
 
5739
    @Override
5740
    public String toString() {
695 rajveer 5741
      StringBuilder sb = new StringBuilder("getPaymentGateway_args(");
123 ashish 5742
      boolean first = true;
5743
 
420 ashish 5744
      sb.append("id:");
5745
      sb.append(this.id);
123 ashish 5746
      first = false;
5747
      sb.append(")");
5748
      return sb.toString();
5749
    }
5750
 
3430 rajveer 5751
    public void validate() throws org.apache.thrift.TException {
123 ashish 5752
      // check for required fields
5753
    }
5754
 
3430 rajveer 5755
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5756
      try {
5757
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5758
      } catch (org.apache.thrift.TException te) {
5759
        throw new java.io.IOException(te);
5760
      }
5761
    }
5762
 
5763
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5764
      try {
5765
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5766
        __isset_bit_vector = new BitSet(1);
5767
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5768
      } catch (org.apache.thrift.TException te) {
5769
        throw new java.io.IOException(te);
5770
      }
5771
    }
5772
 
123 ashish 5773
  }
5774
 
3430 rajveer 5775
  public static class getPaymentGateway_result implements org.apache.thrift.TBase<getPaymentGateway_result, getPaymentGateway_result._Fields>, java.io.Serializable, Cloneable   {
5776
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentGateway_result");
123 ashish 5777
 
3430 rajveer 5778
    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);
5779
    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 5780
 
3430 rajveer 5781
    private PaymentGateway success; // required
5782
    private PaymentException pe; // required
123 ashish 5783
 
5784
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5785
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 5786
      SUCCESS((short)0, "success"),
5787
      PE((short)1, "pe");
5788
 
5789
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5790
 
5791
      static {
5792
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5793
          byName.put(field.getFieldName(), field);
5794
        }
5795
      }
5796
 
5797
      /**
5798
       * Find the _Fields constant that matches fieldId, or null if its not found.
5799
       */
5800
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 5801
        switch(fieldId) {
5802
          case 0: // SUCCESS
5803
            return SUCCESS;
5804
          case 1: // PE
5805
            return PE;
5806
          default:
5807
            return null;
5808
        }
420 ashish 5809
      }
5810
 
5811
      /**
5812
       * Find the _Fields constant that matches fieldId, throwing an exception
5813
       * if it is not found.
5814
       */
5815
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5816
        _Fields fields = findByThriftId(fieldId);
5817
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5818
        return fields;
5819
      }
5820
 
5821
      /**
5822
       * Find the _Fields constant that matches name, or null if its not found.
5823
       */
5824
      public static _Fields findByName(String name) {
5825
        return byName.get(name);
5826
      }
5827
 
5828
      private final short _thriftId;
5829
      private final String _fieldName;
5830
 
5831
      _Fields(short thriftId, String fieldName) {
5832
        _thriftId = thriftId;
5833
        _fieldName = fieldName;
5834
      }
5835
 
5836
      public short getThriftFieldId() {
5837
        return _thriftId;
5838
      }
5839
 
5840
      public String getFieldName() {
5841
        return _fieldName;
5842
      }
5843
    }
5844
 
5845
    // isset id assignments
5846
 
3430 rajveer 5847
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 5848
    static {
3430 rajveer 5849
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5850
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5851
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, PaymentGateway.class)));
5852
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5853
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5854
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5855
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentGateway_result.class, metaDataMap);
420 ashish 5856
    }
5857
 
695 rajveer 5858
    public getPaymentGateway_result() {
420 ashish 5859
    }
5860
 
695 rajveer 5861
    public getPaymentGateway_result(
5862
      PaymentGateway success,
420 ashish 5863
      PaymentException pe)
5864
    {
5865
      this();
5866
      this.success = success;
5867
      this.pe = pe;
5868
    }
5869
 
5870
    /**
5871
     * Performs a deep copy on <i>other</i>.
5872
     */
695 rajveer 5873
    public getPaymentGateway_result(getPaymentGateway_result other) {
420 ashish 5874
      if (other.isSetSuccess()) {
695 rajveer 5875
        this.success = new PaymentGateway(other.success);
420 ashish 5876
      }
5877
      if (other.isSetPe()) {
5878
        this.pe = new PaymentException(other.pe);
5879
      }
5880
    }
5881
 
695 rajveer 5882
    public getPaymentGateway_result deepCopy() {
5883
      return new getPaymentGateway_result(this);
420 ashish 5884
    }
5885
 
3430 rajveer 5886
    @Override
5887
    public void clear() {
5888
      this.success = null;
5889
      this.pe = null;
420 ashish 5890
    }
5891
 
695 rajveer 5892
    public PaymentGateway getSuccess() {
420 ashish 5893
      return this.success;
5894
    }
5895
 
3430 rajveer 5896
    public void setSuccess(PaymentGateway success) {
420 ashish 5897
      this.success = success;
5898
    }
5899
 
5900
    public void unsetSuccess() {
5901
      this.success = null;
5902
    }
5903
 
3430 rajveer 5904
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 5905
    public boolean isSetSuccess() {
5906
      return this.success != null;
5907
    }
5908
 
5909
    public void setSuccessIsSet(boolean value) {
5910
      if (!value) {
5911
        this.success = null;
5912
      }
5913
    }
5914
 
5915
    public PaymentException getPe() {
5916
      return this.pe;
5917
    }
5918
 
3430 rajveer 5919
    public void setPe(PaymentException pe) {
420 ashish 5920
      this.pe = pe;
5921
    }
5922
 
5923
    public void unsetPe() {
5924
      this.pe = null;
5925
    }
5926
 
3430 rajveer 5927
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 5928
    public boolean isSetPe() {
5929
      return this.pe != null;
5930
    }
5931
 
5932
    public void setPeIsSet(boolean value) {
5933
      if (!value) {
5934
        this.pe = null;
5935
      }
5936
    }
5937
 
5938
    public void setFieldValue(_Fields field, Object value) {
5939
      switch (field) {
5940
      case SUCCESS:
5941
        if (value == null) {
5942
          unsetSuccess();
5943
        } else {
695 rajveer 5944
          setSuccess((PaymentGateway)value);
420 ashish 5945
        }
5946
        break;
5947
 
5948
      case PE:
5949
        if (value == null) {
5950
          unsetPe();
5951
        } else {
5952
          setPe((PaymentException)value);
5953
        }
5954
        break;
5955
 
5956
      }
5957
    }
5958
 
5959
    public Object getFieldValue(_Fields field) {
5960
      switch (field) {
5961
      case SUCCESS:
5962
        return getSuccess();
5963
 
5964
      case PE:
5965
        return getPe();
5966
 
5967
      }
5968
      throw new IllegalStateException();
5969
    }
5970
 
3430 rajveer 5971
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5972
    public boolean isSet(_Fields field) {
5973
      if (field == null) {
5974
        throw new IllegalArgumentException();
5975
      }
420 ashish 5976
 
5977
      switch (field) {
5978
      case SUCCESS:
5979
        return isSetSuccess();
5980
      case PE:
5981
        return isSetPe();
5982
      }
5983
      throw new IllegalStateException();
5984
    }
5985
 
5986
    @Override
5987
    public boolean equals(Object that) {
5988
      if (that == null)
5989
        return false;
695 rajveer 5990
      if (that instanceof getPaymentGateway_result)
5991
        return this.equals((getPaymentGateway_result)that);
420 ashish 5992
      return false;
5993
    }
5994
 
695 rajveer 5995
    public boolean equals(getPaymentGateway_result that) {
420 ashish 5996
      if (that == null)
5997
        return false;
5998
 
5999
      boolean this_present_success = true && this.isSetSuccess();
6000
      boolean that_present_success = true && that.isSetSuccess();
6001
      if (this_present_success || that_present_success) {
6002
        if (!(this_present_success && that_present_success))
6003
          return false;
6004
        if (!this.success.equals(that.success))
6005
          return false;
6006
      }
6007
 
6008
      boolean this_present_pe = true && this.isSetPe();
6009
      boolean that_present_pe = true && that.isSetPe();
6010
      if (this_present_pe || that_present_pe) {
6011
        if (!(this_present_pe && that_present_pe))
6012
          return false;
6013
        if (!this.pe.equals(that.pe))
6014
          return false;
6015
      }
6016
 
6017
      return true;
6018
    }
6019
 
6020
    @Override
6021
    public int hashCode() {
6022
      return 0;
6023
    }
6024
 
695 rajveer 6025
    public int compareTo(getPaymentGateway_result other) {
6026
      if (!getClass().equals(other.getClass())) {
6027
        return getClass().getName().compareTo(other.getClass().getName());
6028
      }
6029
 
6030
      int lastComparison = 0;
6031
      getPaymentGateway_result typedOther = (getPaymentGateway_result)other;
6032
 
3430 rajveer 6033
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 6034
      if (lastComparison != 0) {
6035
        return lastComparison;
6036
      }
3430 rajveer 6037
      if (isSetSuccess()) {
6038
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6039
        if (lastComparison != 0) {
6040
          return lastComparison;
6041
        }
695 rajveer 6042
      }
3430 rajveer 6043
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 6044
      if (lastComparison != 0) {
6045
        return lastComparison;
6046
      }
3430 rajveer 6047
      if (isSetPe()) {
6048
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
6049
        if (lastComparison != 0) {
6050
          return lastComparison;
6051
        }
695 rajveer 6052
      }
6053
      return 0;
6054
    }
6055
 
3430 rajveer 6056
    public _Fields fieldForId(int fieldId) {
6057
      return _Fields.findByThriftId(fieldId);
6058
    }
6059
 
6060
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6061
      org.apache.thrift.protocol.TField field;
420 ashish 6062
      iprot.readStructBegin();
6063
      while (true)
6064
      {
6065
        field = iprot.readFieldBegin();
3430 rajveer 6066
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 6067
          break;
6068
        }
3430 rajveer 6069
        switch (field.id) {
6070
          case 0: // SUCCESS
6071
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6072
              this.success = new PaymentGateway();
6073
              this.success.read(iprot);
6074
            } else { 
6075
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6076
            }
6077
            break;
6078
          case 1: // PE
6079
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6080
              this.pe = new PaymentException();
6081
              this.pe.read(iprot);
6082
            } else { 
6083
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6084
            }
6085
            break;
6086
          default:
6087
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 6088
        }
3430 rajveer 6089
        iprot.readFieldEnd();
420 ashish 6090
      }
6091
      iprot.readStructEnd();
6092
      validate();
6093
    }
6094
 
3430 rajveer 6095
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 6096
      oprot.writeStructBegin(STRUCT_DESC);
6097
 
6098
      if (this.isSetSuccess()) {
6099
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
695 rajveer 6100
        this.success.write(oprot);
420 ashish 6101
        oprot.writeFieldEnd();
6102
      } else if (this.isSetPe()) {
6103
        oprot.writeFieldBegin(PE_FIELD_DESC);
6104
        this.pe.write(oprot);
6105
        oprot.writeFieldEnd();
6106
      }
6107
      oprot.writeFieldStop();
6108
      oprot.writeStructEnd();
6109
    }
6110
 
6111
    @Override
6112
    public String toString() {
695 rajveer 6113
      StringBuilder sb = new StringBuilder("getPaymentGateway_result(");
420 ashish 6114
      boolean first = true;
6115
 
6116
      sb.append("success:");
6117
      if (this.success == null) {
6118
        sb.append("null");
6119
      } else {
6120
        sb.append(this.success);
6121
      }
6122
      first = false;
6123
      if (!first) sb.append(", ");
6124
      sb.append("pe:");
6125
      if (this.pe == null) {
6126
        sb.append("null");
6127
      } else {
6128
        sb.append(this.pe);
6129
      }
6130
      first = false;
6131
      sb.append(")");
6132
      return sb.toString();
6133
    }
6134
 
3430 rajveer 6135
    public void validate() throws org.apache.thrift.TException {
420 ashish 6136
      // check for required fields
6137
    }
6138
 
3430 rajveer 6139
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6140
      try {
6141
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6142
      } catch (org.apache.thrift.TException te) {
6143
        throw new java.io.IOException(te);
6144
      }
6145
    }
6146
 
6147
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6148
      try {
6149
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6150
      } catch (org.apache.thrift.TException te) {
6151
        throw new java.io.IOException(te);
6152
      }
6153
    }
6154
 
420 ashish 6155
  }
6156
 
3430 rajveer 6157
  public static class getPayment_args implements org.apache.thrift.TBase<getPayment_args, getPayment_args._Fields>, java.io.Serializable, Cloneable   {
6158
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayment_args");
420 ashish 6159
 
3430 rajveer 6160
    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 6161
 
3430 rajveer 6162
    private long id; // required
420 ashish 6163
 
6164
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6165
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 6166
      ID((short)1, "id");
6167
 
6168
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6169
 
6170
      static {
6171
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6172
          byName.put(field.getFieldName(), field);
6173
        }
6174
      }
6175
 
6176
      /**
6177
       * Find the _Fields constant that matches fieldId, or null if its not found.
6178
       */
6179
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6180
        switch(fieldId) {
6181
          case 1: // ID
6182
            return ID;
6183
          default:
6184
            return null;
6185
        }
420 ashish 6186
      }
6187
 
6188
      /**
6189
       * Find the _Fields constant that matches fieldId, throwing an exception
6190
       * if it is not found.
6191
       */
6192
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6193
        _Fields fields = findByThriftId(fieldId);
6194
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6195
        return fields;
6196
      }
6197
 
6198
      /**
6199
       * Find the _Fields constant that matches name, or null if its not found.
6200
       */
6201
      public static _Fields findByName(String name) {
6202
        return byName.get(name);
6203
      }
6204
 
6205
      private final short _thriftId;
6206
      private final String _fieldName;
6207
 
6208
      _Fields(short thriftId, String fieldName) {
6209
        _thriftId = thriftId;
6210
        _fieldName = fieldName;
6211
      }
6212
 
6213
      public short getThriftFieldId() {
6214
        return _thriftId;
6215
      }
6216
 
6217
      public String getFieldName() {
6218
        return _fieldName;
6219
      }
6220
    }
6221
 
6222
    // isset id assignments
6223
    private static final int __ID_ISSET_ID = 0;
6224
    private BitSet __isset_bit_vector = new BitSet(1);
6225
 
3430 rajveer 6226
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 6227
    static {
3430 rajveer 6228
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6229
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6230
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6231
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6232
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayment_args.class, metaDataMap);
420 ashish 6233
    }
6234
 
695 rajveer 6235
    public getPayment_args() {
420 ashish 6236
    }
6237
 
695 rajveer 6238
    public getPayment_args(
420 ashish 6239
      long id)
6240
    {
6241
      this();
6242
      this.id = id;
6243
      setIdIsSet(true);
6244
    }
6245
 
6246
    /**
6247
     * Performs a deep copy on <i>other</i>.
6248
     */
695 rajveer 6249
    public getPayment_args(getPayment_args other) {
420 ashish 6250
      __isset_bit_vector.clear();
6251
      __isset_bit_vector.or(other.__isset_bit_vector);
6252
      this.id = other.id;
6253
    }
6254
 
695 rajveer 6255
    public getPayment_args deepCopy() {
6256
      return new getPayment_args(this);
420 ashish 6257
    }
6258
 
3430 rajveer 6259
    @Override
6260
    public void clear() {
6261
      setIdIsSet(false);
6262
      this.id = 0;
420 ashish 6263
    }
6264
 
6265
    public long getId() {
6266
      return this.id;
6267
    }
6268
 
3430 rajveer 6269
    public void setId(long id) {
420 ashish 6270
      this.id = id;
6271
      setIdIsSet(true);
6272
    }
6273
 
6274
    public void unsetId() {
6275
      __isset_bit_vector.clear(__ID_ISSET_ID);
6276
    }
6277
 
3430 rajveer 6278
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 6279
    public boolean isSetId() {
6280
      return __isset_bit_vector.get(__ID_ISSET_ID);
6281
    }
6282
 
6283
    public void setIdIsSet(boolean value) {
6284
      __isset_bit_vector.set(__ID_ISSET_ID, value);
6285
    }
6286
 
6287
    public void setFieldValue(_Fields field, Object value) {
6288
      switch (field) {
6289
      case ID:
6290
        if (value == null) {
6291
          unsetId();
6292
        } else {
6293
          setId((Long)value);
6294
        }
6295
        break;
6296
 
6297
      }
6298
    }
6299
 
6300
    public Object getFieldValue(_Fields field) {
6301
      switch (field) {
6302
      case ID:
3430 rajveer 6303
        return Long.valueOf(getId());
420 ashish 6304
 
6305
      }
6306
      throw new IllegalStateException();
6307
    }
6308
 
3430 rajveer 6309
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6310
    public boolean isSet(_Fields field) {
6311
      if (field == null) {
6312
        throw new IllegalArgumentException();
6313
      }
420 ashish 6314
 
6315
      switch (field) {
6316
      case ID:
6317
        return isSetId();
6318
      }
6319
      throw new IllegalStateException();
6320
    }
6321
 
6322
    @Override
6323
    public boolean equals(Object that) {
6324
      if (that == null)
6325
        return false;
695 rajveer 6326
      if (that instanceof getPayment_args)
6327
        return this.equals((getPayment_args)that);
420 ashish 6328
      return false;
6329
    }
6330
 
695 rajveer 6331
    public boolean equals(getPayment_args that) {
420 ashish 6332
      if (that == null)
6333
        return false;
6334
 
6335
      boolean this_present_id = true;
6336
      boolean that_present_id = true;
6337
      if (this_present_id || that_present_id) {
6338
        if (!(this_present_id && that_present_id))
6339
          return false;
6340
        if (this.id != that.id)
6341
          return false;
6342
      }
6343
 
6344
      return true;
6345
    }
6346
 
6347
    @Override
6348
    public int hashCode() {
6349
      return 0;
6350
    }
6351
 
695 rajveer 6352
    public int compareTo(getPayment_args other) {
420 ashish 6353
      if (!getClass().equals(other.getClass())) {
6354
        return getClass().getName().compareTo(other.getClass().getName());
6355
      }
6356
 
6357
      int lastComparison = 0;
695 rajveer 6358
      getPayment_args typedOther = (getPayment_args)other;
420 ashish 6359
 
3430 rajveer 6360
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
420 ashish 6361
      if (lastComparison != 0) {
6362
        return lastComparison;
6363
      }
3430 rajveer 6364
      if (isSetId()) {
6365
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
6366
        if (lastComparison != 0) {
6367
          return lastComparison;
6368
        }
420 ashish 6369
      }
6370
      return 0;
6371
    }
6372
 
3430 rajveer 6373
    public _Fields fieldForId(int fieldId) {
6374
      return _Fields.findByThriftId(fieldId);
6375
    }
6376
 
6377
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6378
      org.apache.thrift.protocol.TField field;
420 ashish 6379
      iprot.readStructBegin();
6380
      while (true)
6381
      {
6382
        field = iprot.readFieldBegin();
3430 rajveer 6383
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 6384
          break;
6385
        }
3430 rajveer 6386
        switch (field.id) {
6387
          case 1: // ID
6388
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6389
              this.id = iprot.readI64();
6390
              setIdIsSet(true);
6391
            } else { 
6392
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6393
            }
6394
            break;
6395
          default:
6396
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 6397
        }
3430 rajveer 6398
        iprot.readFieldEnd();
420 ashish 6399
      }
6400
      iprot.readStructEnd();
6401
      validate();
6402
    }
6403
 
3430 rajveer 6404
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 6405
      validate();
6406
 
6407
      oprot.writeStructBegin(STRUCT_DESC);
6408
      oprot.writeFieldBegin(ID_FIELD_DESC);
6409
      oprot.writeI64(this.id);
6410
      oprot.writeFieldEnd();
6411
      oprot.writeFieldStop();
6412
      oprot.writeStructEnd();
6413
    }
6414
 
6415
    @Override
6416
    public String toString() {
695 rajveer 6417
      StringBuilder sb = new StringBuilder("getPayment_args(");
420 ashish 6418
      boolean first = true;
6419
 
6420
      sb.append("id:");
6421
      sb.append(this.id);
6422
      first = false;
6423
      sb.append(")");
6424
      return sb.toString();
6425
    }
6426
 
3430 rajveer 6427
    public void validate() throws org.apache.thrift.TException {
420 ashish 6428
      // check for required fields
6429
    }
6430
 
3430 rajveer 6431
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6432
      try {
6433
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6434
      } catch (org.apache.thrift.TException te) {
6435
        throw new java.io.IOException(te);
6436
      }
6437
    }
6438
 
6439
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6440
      try {
6441
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6442
        __isset_bit_vector = new BitSet(1);
6443
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6444
      } catch (org.apache.thrift.TException te) {
6445
        throw new java.io.IOException(te);
6446
      }
6447
    }
6448
 
420 ashish 6449
  }
6450
 
3430 rajveer 6451
  public static class getPayment_result implements org.apache.thrift.TBase<getPayment_result, getPayment_result._Fields>, java.io.Serializable, Cloneable   {
6452
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPayment_result");
420 ashish 6453
 
3430 rajveer 6454
    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);
6455
    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 6456
 
3430 rajveer 6457
    private Payment success; // required
6458
    private PaymentException pe; // required
420 ashish 6459
 
6460
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6461
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 6462
      SUCCESS((short)0, "success"),
6463
      PE((short)1, "pe");
6464
 
6465
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6466
 
6467
      static {
6468
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6469
          byName.put(field.getFieldName(), field);
6470
        }
6471
      }
6472
 
6473
      /**
6474
       * Find the _Fields constant that matches fieldId, or null if its not found.
6475
       */
6476
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6477
        switch(fieldId) {
6478
          case 0: // SUCCESS
6479
            return SUCCESS;
6480
          case 1: // PE
6481
            return PE;
6482
          default:
6483
            return null;
6484
        }
420 ashish 6485
      }
6486
 
6487
      /**
6488
       * Find the _Fields constant that matches fieldId, throwing an exception
6489
       * if it is not found.
6490
       */
6491
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6492
        _Fields fields = findByThriftId(fieldId);
6493
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6494
        return fields;
6495
      }
6496
 
6497
      /**
6498
       * Find the _Fields constant that matches name, or null if its not found.
6499
       */
6500
      public static _Fields findByName(String name) {
6501
        return byName.get(name);
6502
      }
6503
 
6504
      private final short _thriftId;
6505
      private final String _fieldName;
6506
 
6507
      _Fields(short thriftId, String fieldName) {
6508
        _thriftId = thriftId;
6509
        _fieldName = fieldName;
6510
      }
6511
 
6512
      public short getThriftFieldId() {
6513
        return _thriftId;
6514
      }
6515
 
6516
      public String getFieldName() {
6517
        return _fieldName;
6518
      }
6519
    }
6520
 
6521
    // isset id assignments
6522
 
3430 rajveer 6523
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 6524
    static {
3430 rajveer 6525
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6526
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6527
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class)));
6528
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6529
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6530
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6531
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPayment_result.class, metaDataMap);
420 ashish 6532
    }
6533
 
695 rajveer 6534
    public getPayment_result() {
420 ashish 6535
    }
6536
 
695 rajveer 6537
    public getPayment_result(
6538
      Payment success,
420 ashish 6539
      PaymentException pe)
6540
    {
6541
      this();
6542
      this.success = success;
6543
      this.pe = pe;
6544
    }
6545
 
6546
    /**
6547
     * Performs a deep copy on <i>other</i>.
6548
     */
695 rajveer 6549
    public getPayment_result(getPayment_result other) {
420 ashish 6550
      if (other.isSetSuccess()) {
695 rajveer 6551
        this.success = new Payment(other.success);
420 ashish 6552
      }
6553
      if (other.isSetPe()) {
6554
        this.pe = new PaymentException(other.pe);
6555
      }
6556
    }
6557
 
695 rajveer 6558
    public getPayment_result deepCopy() {
6559
      return new getPayment_result(this);
420 ashish 6560
    }
6561
 
3430 rajveer 6562
    @Override
6563
    public void clear() {
6564
      this.success = null;
6565
      this.pe = null;
420 ashish 6566
    }
6567
 
695 rajveer 6568
    public Payment getSuccess() {
420 ashish 6569
      return this.success;
6570
    }
6571
 
3430 rajveer 6572
    public void setSuccess(Payment success) {
420 ashish 6573
      this.success = success;
6574
    }
6575
 
6576
    public void unsetSuccess() {
6577
      this.success = null;
6578
    }
6579
 
3430 rajveer 6580
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 6581
    public boolean isSetSuccess() {
6582
      return this.success != null;
6583
    }
6584
 
6585
    public void setSuccessIsSet(boolean value) {
6586
      if (!value) {
6587
        this.success = null;
6588
      }
6589
    }
6590
 
6591
    public PaymentException getPe() {
6592
      return this.pe;
6593
    }
6594
 
3430 rajveer 6595
    public void setPe(PaymentException pe) {
420 ashish 6596
      this.pe = pe;
6597
    }
6598
 
6599
    public void unsetPe() {
6600
      this.pe = null;
6601
    }
6602
 
3430 rajveer 6603
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 6604
    public boolean isSetPe() {
6605
      return this.pe != null;
6606
    }
6607
 
6608
    public void setPeIsSet(boolean value) {
6609
      if (!value) {
6610
        this.pe = null;
6611
      }
6612
    }
6613
 
6614
    public void setFieldValue(_Fields field, Object value) {
6615
      switch (field) {
6616
      case SUCCESS:
6617
        if (value == null) {
6618
          unsetSuccess();
6619
        } else {
695 rajveer 6620
          setSuccess((Payment)value);
420 ashish 6621
        }
6622
        break;
6623
 
6624
      case PE:
6625
        if (value == null) {
6626
          unsetPe();
6627
        } else {
6628
          setPe((PaymentException)value);
6629
        }
6630
        break;
6631
 
6632
      }
6633
    }
6634
 
6635
    public Object getFieldValue(_Fields field) {
6636
      switch (field) {
6637
      case SUCCESS:
6638
        return getSuccess();
6639
 
6640
      case PE:
6641
        return getPe();
6642
 
6643
      }
6644
      throw new IllegalStateException();
6645
    }
6646
 
3430 rajveer 6647
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6648
    public boolean isSet(_Fields field) {
6649
      if (field == null) {
6650
        throw new IllegalArgumentException();
6651
      }
420 ashish 6652
 
6653
      switch (field) {
6654
      case SUCCESS:
6655
        return isSetSuccess();
6656
      case PE:
6657
        return isSetPe();
6658
      }
6659
      throw new IllegalStateException();
6660
    }
6661
 
6662
    @Override
6663
    public boolean equals(Object that) {
6664
      if (that == null)
6665
        return false;
695 rajveer 6666
      if (that instanceof getPayment_result)
6667
        return this.equals((getPayment_result)that);
420 ashish 6668
      return false;
6669
    }
6670
 
695 rajveer 6671
    public boolean equals(getPayment_result that) {
420 ashish 6672
      if (that == null)
6673
        return false;
6674
 
6675
      boolean this_present_success = true && this.isSetSuccess();
6676
      boolean that_present_success = true && that.isSetSuccess();
6677
      if (this_present_success || that_present_success) {
6678
        if (!(this_present_success && that_present_success))
6679
          return false;
6680
        if (!this.success.equals(that.success))
6681
          return false;
6682
      }
6683
 
6684
      boolean this_present_pe = true && this.isSetPe();
6685
      boolean that_present_pe = true && that.isSetPe();
6686
      if (this_present_pe || that_present_pe) {
6687
        if (!(this_present_pe && that_present_pe))
6688
          return false;
6689
        if (!this.pe.equals(that.pe))
6690
          return false;
6691
      }
6692
 
6693
      return true;
6694
    }
6695
 
6696
    @Override
6697
    public int hashCode() {
6698
      return 0;
6699
    }
6700
 
695 rajveer 6701
    public int compareTo(getPayment_result other) {
420 ashish 6702
      if (!getClass().equals(other.getClass())) {
6703
        return getClass().getName().compareTo(other.getClass().getName());
6704
      }
6705
 
6706
      int lastComparison = 0;
695 rajveer 6707
      getPayment_result typedOther = (getPayment_result)other;
420 ashish 6708
 
3430 rajveer 6709
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
420 ashish 6710
      if (lastComparison != 0) {
6711
        return lastComparison;
6712
      }
3430 rajveer 6713
      if (isSetSuccess()) {
6714
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6715
        if (lastComparison != 0) {
6716
          return lastComparison;
6717
        }
420 ashish 6718
      }
3430 rajveer 6719
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 6720
      if (lastComparison != 0) {
6721
        return lastComparison;
6722
      }
3430 rajveer 6723
      if (isSetPe()) {
6724
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
6725
        if (lastComparison != 0) {
6726
          return lastComparison;
6727
        }
420 ashish 6728
      }
6729
      return 0;
6730
    }
6731
 
3430 rajveer 6732
    public _Fields fieldForId(int fieldId) {
6733
      return _Fields.findByThriftId(fieldId);
6734
    }
6735
 
6736
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6737
      org.apache.thrift.protocol.TField field;
420 ashish 6738
      iprot.readStructBegin();
6739
      while (true)
6740
      {
6741
        field = iprot.readFieldBegin();
3430 rajveer 6742
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 6743
          break;
6744
        }
3430 rajveer 6745
        switch (field.id) {
6746
          case 0: // SUCCESS
6747
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6748
              this.success = new Payment();
6749
              this.success.read(iprot);
6750
            } else { 
6751
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6752
            }
6753
            break;
6754
          case 1: // PE
6755
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6756
              this.pe = new PaymentException();
6757
              this.pe.read(iprot);
6758
            } else { 
6759
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6760
            }
6761
            break;
6762
          default:
6763
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 6764
        }
3430 rajveer 6765
        iprot.readFieldEnd();
420 ashish 6766
      }
6767
      iprot.readStructEnd();
6768
      validate();
6769
    }
6770
 
3430 rajveer 6771
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 6772
      oprot.writeStructBegin(STRUCT_DESC);
6773
 
695 rajveer 6774
      if (this.isSetSuccess()) {
6775
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
6776
        this.success.write(oprot);
6777
        oprot.writeFieldEnd();
6778
      } else if (this.isSetPe()) {
420 ashish 6779
        oprot.writeFieldBegin(PE_FIELD_DESC);
6780
        this.pe.write(oprot);
6781
        oprot.writeFieldEnd();
6782
      }
6783
      oprot.writeFieldStop();
6784
      oprot.writeStructEnd();
6785
    }
6786
 
6787
    @Override
6788
    public String toString() {
695 rajveer 6789
      StringBuilder sb = new StringBuilder("getPayment_result(");
420 ashish 6790
      boolean first = true;
6791
 
695 rajveer 6792
      sb.append("success:");
6793
      if (this.success == null) {
6794
        sb.append("null");
6795
      } else {
6796
        sb.append(this.success);
6797
      }
6798
      first = false;
6799
      if (!first) sb.append(", ");
420 ashish 6800
      sb.append("pe:");
6801
      if (this.pe == null) {
6802
        sb.append("null");
6803
      } else {
6804
        sb.append(this.pe);
6805
      }
6806
      first = false;
6807
      sb.append(")");
6808
      return sb.toString();
6809
    }
6810
 
3430 rajveer 6811
    public void validate() throws org.apache.thrift.TException {
420 ashish 6812
      // check for required fields
6813
    }
6814
 
3430 rajveer 6815
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6816
      try {
6817
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6818
      } catch (org.apache.thrift.TException te) {
6819
        throw new java.io.IOException(te);
6820
      }
6821
    }
6822
 
6823
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6824
      try {
6825
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6826
      } catch (org.apache.thrift.TException te) {
6827
        throw new java.io.IOException(te);
6828
      }
6829
    }
6830
 
420 ashish 6831
  }
6832
 
3430 rajveer 6833
  public static class getPaymentForTxnId_args implements org.apache.thrift.TBase<getPaymentForTxnId_args, getPaymentForTxnId_args._Fields>, java.io.Serializable, Cloneable   {
6834
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForTxnId_args");
420 ashish 6835
 
3430 rajveer 6836
    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 6837
 
3430 rajveer 6838
    private long txnId; // required
420 ashish 6839
 
6840
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6841
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 6842
      TXN_ID((short)1, "txnId");
420 ashish 6843
 
6844
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6845
 
6846
      static {
6847
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6848
          byName.put(field.getFieldName(), field);
6849
        }
6850
      }
6851
 
6852
      /**
6853
       * Find the _Fields constant that matches fieldId, or null if its not found.
6854
       */
6855
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6856
        switch(fieldId) {
6857
          case 1: // TXN_ID
6858
            return TXN_ID;
6859
          default:
6860
            return null;
6861
        }
420 ashish 6862
      }
6863
 
6864
      /**
6865
       * Find the _Fields constant that matches fieldId, throwing an exception
6866
       * if it is not found.
6867
       */
6868
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6869
        _Fields fields = findByThriftId(fieldId);
6870
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6871
        return fields;
6872
      }
6873
 
6874
      /**
6875
       * Find the _Fields constant that matches name, or null if its not found.
6876
       */
6877
      public static _Fields findByName(String name) {
6878
        return byName.get(name);
6879
      }
6880
 
6881
      private final short _thriftId;
6882
      private final String _fieldName;
6883
 
6884
      _Fields(short thriftId, String fieldName) {
6885
        _thriftId = thriftId;
6886
        _fieldName = fieldName;
6887
      }
6888
 
6889
      public short getThriftFieldId() {
6890
        return _thriftId;
6891
      }
6892
 
6893
      public String getFieldName() {
6894
        return _fieldName;
6895
      }
6896
    }
6897
 
6898
    // isset id assignments
695 rajveer 6899
    private static final int __TXNID_ISSET_ID = 0;
420 ashish 6900
    private BitSet __isset_bit_vector = new BitSet(1);
6901
 
3430 rajveer 6902
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 6903
    static {
3430 rajveer 6904
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6905
      tmpMap.put(_Fields.TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("txnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6906
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6907
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6908
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForTxnId_args.class, metaDataMap);
420 ashish 6909
    }
6910
 
695 rajveer 6911
    public getPaymentForTxnId_args() {
420 ashish 6912
    }
6913
 
695 rajveer 6914
    public getPaymentForTxnId_args(
6915
      long txnId)
420 ashish 6916
    {
6917
      this();
695 rajveer 6918
      this.txnId = txnId;
6919
      setTxnIdIsSet(true);
420 ashish 6920
    }
6921
 
6922
    /**
6923
     * Performs a deep copy on <i>other</i>.
6924
     */
695 rajveer 6925
    public getPaymentForTxnId_args(getPaymentForTxnId_args other) {
420 ashish 6926
      __isset_bit_vector.clear();
6927
      __isset_bit_vector.or(other.__isset_bit_vector);
695 rajveer 6928
      this.txnId = other.txnId;
420 ashish 6929
    }
6930
 
695 rajveer 6931
    public getPaymentForTxnId_args deepCopy() {
6932
      return new getPaymentForTxnId_args(this);
420 ashish 6933
    }
6934
 
3430 rajveer 6935
    @Override
6936
    public void clear() {
6937
      setTxnIdIsSet(false);
6938
      this.txnId = 0;
420 ashish 6939
    }
6940
 
695 rajveer 6941
    public long getTxnId() {
6942
      return this.txnId;
420 ashish 6943
    }
6944
 
3430 rajveer 6945
    public void setTxnId(long txnId) {
695 rajveer 6946
      this.txnId = txnId;
6947
      setTxnIdIsSet(true);
420 ashish 6948
    }
6949
 
695 rajveer 6950
    public void unsetTxnId() {
6951
      __isset_bit_vector.clear(__TXNID_ISSET_ID);
420 ashish 6952
    }
6953
 
3430 rajveer 6954
    /** Returns true if field txnId is set (has been assigned a value) and false otherwise */
695 rajveer 6955
    public boolean isSetTxnId() {
6956
      return __isset_bit_vector.get(__TXNID_ISSET_ID);
420 ashish 6957
    }
6958
 
695 rajveer 6959
    public void setTxnIdIsSet(boolean value) {
6960
      __isset_bit_vector.set(__TXNID_ISSET_ID, value);
420 ashish 6961
    }
6962
 
6963
    public void setFieldValue(_Fields field, Object value) {
6964
      switch (field) {
695 rajveer 6965
      case TXN_ID:
420 ashish 6966
        if (value == null) {
695 rajveer 6967
          unsetTxnId();
420 ashish 6968
        } else {
695 rajveer 6969
          setTxnId((Long)value);
420 ashish 6970
        }
6971
        break;
6972
 
6973
      }
6974
    }
6975
 
6976
    public Object getFieldValue(_Fields field) {
6977
      switch (field) {
695 rajveer 6978
      case TXN_ID:
3430 rajveer 6979
        return Long.valueOf(getTxnId());
420 ashish 6980
 
6981
      }
6982
      throw new IllegalStateException();
6983
    }
6984
 
3430 rajveer 6985
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6986
    public boolean isSet(_Fields field) {
6987
      if (field == null) {
6988
        throw new IllegalArgumentException();
6989
      }
420 ashish 6990
 
6991
      switch (field) {
695 rajveer 6992
      case TXN_ID:
6993
        return isSetTxnId();
420 ashish 6994
      }
6995
      throw new IllegalStateException();
6996
    }
6997
 
6998
    @Override
6999
    public boolean equals(Object that) {
7000
      if (that == null)
7001
        return false;
695 rajveer 7002
      if (that instanceof getPaymentForTxnId_args)
7003
        return this.equals((getPaymentForTxnId_args)that);
420 ashish 7004
      return false;
7005
    }
7006
 
695 rajveer 7007
    public boolean equals(getPaymentForTxnId_args that) {
420 ashish 7008
      if (that == null)
7009
        return false;
7010
 
695 rajveer 7011
      boolean this_present_txnId = true;
7012
      boolean that_present_txnId = true;
7013
      if (this_present_txnId || that_present_txnId) {
7014
        if (!(this_present_txnId && that_present_txnId))
420 ashish 7015
          return false;
695 rajveer 7016
        if (this.txnId != that.txnId)
420 ashish 7017
          return false;
7018
      }
7019
 
7020
      return true;
7021
    }
7022
 
7023
    @Override
7024
    public int hashCode() {
7025
      return 0;
7026
    }
7027
 
695 rajveer 7028
    public int compareTo(getPaymentForTxnId_args other) {
420 ashish 7029
      if (!getClass().equals(other.getClass())) {
7030
        return getClass().getName().compareTo(other.getClass().getName());
7031
      }
7032
 
7033
      int lastComparison = 0;
695 rajveer 7034
      getPaymentForTxnId_args typedOther = (getPaymentForTxnId_args)other;
420 ashish 7035
 
3430 rajveer 7036
      lastComparison = Boolean.valueOf(isSetTxnId()).compareTo(typedOther.isSetTxnId());
420 ashish 7037
      if (lastComparison != 0) {
7038
        return lastComparison;
7039
      }
3430 rajveer 7040
      if (isSetTxnId()) {
7041
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.txnId, typedOther.txnId);
7042
        if (lastComparison != 0) {
7043
          return lastComparison;
7044
        }
420 ashish 7045
      }
7046
      return 0;
7047
    }
7048
 
3430 rajveer 7049
    public _Fields fieldForId(int fieldId) {
7050
      return _Fields.findByThriftId(fieldId);
7051
    }
7052
 
7053
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7054
      org.apache.thrift.protocol.TField field;
420 ashish 7055
      iprot.readStructBegin();
7056
      while (true)
7057
      {
7058
        field = iprot.readFieldBegin();
3430 rajveer 7059
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 7060
          break;
7061
        }
3430 rajveer 7062
        switch (field.id) {
7063
          case 1: // TXN_ID
7064
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7065
              this.txnId = iprot.readI64();
7066
              setTxnIdIsSet(true);
7067
            } else { 
7068
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7069
            }
7070
            break;
7071
          default:
7072
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 7073
        }
3430 rajveer 7074
        iprot.readFieldEnd();
420 ashish 7075
      }
7076
      iprot.readStructEnd();
7077
      validate();
7078
    }
7079
 
3430 rajveer 7080
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 7081
      validate();
7082
 
7083
      oprot.writeStructBegin(STRUCT_DESC);
695 rajveer 7084
      oprot.writeFieldBegin(TXN_ID_FIELD_DESC);
7085
      oprot.writeI64(this.txnId);
420 ashish 7086
      oprot.writeFieldEnd();
7087
      oprot.writeFieldStop();
7088
      oprot.writeStructEnd();
7089
    }
7090
 
7091
    @Override
7092
    public String toString() {
695 rajveer 7093
      StringBuilder sb = new StringBuilder("getPaymentForTxnId_args(");
420 ashish 7094
      boolean first = true;
7095
 
695 rajveer 7096
      sb.append("txnId:");
7097
      sb.append(this.txnId);
420 ashish 7098
      first = false;
7099
      sb.append(")");
7100
      return sb.toString();
7101
    }
7102
 
3430 rajveer 7103
    public void validate() throws org.apache.thrift.TException {
420 ashish 7104
      // check for required fields
7105
    }
7106
 
3430 rajveer 7107
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7108
      try {
7109
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7110
      } catch (org.apache.thrift.TException te) {
7111
        throw new java.io.IOException(te);
7112
      }
7113
    }
7114
 
7115
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7116
      try {
7117
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7118
        __isset_bit_vector = new BitSet(1);
7119
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7120
      } catch (org.apache.thrift.TException te) {
7121
        throw new java.io.IOException(te);
7122
      }
7123
    }
7124
 
420 ashish 7125
  }
7126
 
3430 rajveer 7127
  public static class getPaymentForTxnId_result implements org.apache.thrift.TBase<getPaymentForTxnId_result, getPaymentForTxnId_result._Fields>, java.io.Serializable, Cloneable   {
7128
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentForTxnId_result");
420 ashish 7129
 
3430 rajveer 7130
    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);
7131
    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 7132
 
3430 rajveer 7133
    private List<Payment> success; // required
7134
    private PaymentException pe; // required
420 ashish 7135
 
7136
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7137
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 7138
      SUCCESS((short)0, "success"),
7139
      PE((short)1, "pe");
7140
 
7141
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7142
 
7143
      static {
7144
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7145
          byName.put(field.getFieldName(), field);
7146
        }
7147
      }
7148
 
7149
      /**
7150
       * Find the _Fields constant that matches fieldId, or null if its not found.
7151
       */
7152
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7153
        switch(fieldId) {
7154
          case 0: // SUCCESS
7155
            return SUCCESS;
7156
          case 1: // PE
7157
            return PE;
7158
          default:
7159
            return null;
7160
        }
420 ashish 7161
      }
7162
 
7163
      /**
7164
       * Find the _Fields constant that matches fieldId, throwing an exception
7165
       * if it is not found.
7166
       */
7167
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7168
        _Fields fields = findByThriftId(fieldId);
7169
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7170
        return fields;
7171
      }
7172
 
7173
      /**
7174
       * Find the _Fields constant that matches name, or null if its not found.
7175
       */
7176
      public static _Fields findByName(String name) {
7177
        return byName.get(name);
7178
      }
7179
 
7180
      private final short _thriftId;
7181
      private final String _fieldName;
7182
 
7183
      _Fields(short thriftId, String fieldName) {
7184
        _thriftId = thriftId;
7185
        _fieldName = fieldName;
7186
      }
7187
 
7188
      public short getThriftFieldId() {
7189
        return _thriftId;
7190
      }
7191
 
7192
      public String getFieldName() {
7193
        return _fieldName;
7194
      }
7195
    }
7196
 
7197
    // isset id assignments
7198
 
3430 rajveer 7199
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 7200
    static {
3430 rajveer 7201
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7202
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7203
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
7204
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Payment.class))));
7205
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7206
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7207
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7208
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentForTxnId_result.class, metaDataMap);
420 ashish 7209
    }
7210
 
695 rajveer 7211
    public getPaymentForTxnId_result() {
420 ashish 7212
    }
7213
 
695 rajveer 7214
    public getPaymentForTxnId_result(
7215
      List<Payment> success,
420 ashish 7216
      PaymentException pe)
7217
    {
7218
      this();
7219
      this.success = success;
7220
      this.pe = pe;
7221
    }
7222
 
7223
    /**
7224
     * Performs a deep copy on <i>other</i>.
7225
     */
695 rajveer 7226
    public getPaymentForTxnId_result(getPaymentForTxnId_result other) {
420 ashish 7227
      if (other.isSetSuccess()) {
695 rajveer 7228
        List<Payment> __this__success = new ArrayList<Payment>();
7229
        for (Payment other_element : other.success) {
7230
          __this__success.add(new Payment(other_element));
7231
        }
7232
        this.success = __this__success;
420 ashish 7233
      }
7234
      if (other.isSetPe()) {
7235
        this.pe = new PaymentException(other.pe);
7236
      }
7237
    }
7238
 
695 rajveer 7239
    public getPaymentForTxnId_result deepCopy() {
7240
      return new getPaymentForTxnId_result(this);
420 ashish 7241
    }
7242
 
3430 rajveer 7243
    @Override
7244
    public void clear() {
7245
      this.success = null;
7246
      this.pe = null;
420 ashish 7247
    }
7248
 
695 rajveer 7249
    public int getSuccessSize() {
7250
      return (this.success == null) ? 0 : this.success.size();
7251
    }
7252
 
7253
    public java.util.Iterator<Payment> getSuccessIterator() {
7254
      return (this.success == null) ? null : this.success.iterator();
7255
    }
7256
 
7257
    public void addToSuccess(Payment elem) {
7258
      if (this.success == null) {
7259
        this.success = new ArrayList<Payment>();
7260
      }
7261
      this.success.add(elem);
7262
    }
7263
 
7264
    public List<Payment> getSuccess() {
420 ashish 7265
      return this.success;
7266
    }
7267
 
3430 rajveer 7268
    public void setSuccess(List<Payment> success) {
420 ashish 7269
      this.success = success;
7270
    }
7271
 
7272
    public void unsetSuccess() {
7273
      this.success = null;
7274
    }
7275
 
3430 rajveer 7276
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
420 ashish 7277
    public boolean isSetSuccess() {
7278
      return this.success != null;
7279
    }
7280
 
7281
    public void setSuccessIsSet(boolean value) {
7282
      if (!value) {
7283
        this.success = null;
7284
      }
7285
    }
7286
 
7287
    public PaymentException getPe() {
7288
      return this.pe;
7289
    }
7290
 
3430 rajveer 7291
    public void setPe(PaymentException pe) {
420 ashish 7292
      this.pe = pe;
7293
    }
7294
 
7295
    public void unsetPe() {
7296
      this.pe = null;
7297
    }
7298
 
3430 rajveer 7299
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 7300
    public boolean isSetPe() {
7301
      return this.pe != null;
7302
    }
7303
 
7304
    public void setPeIsSet(boolean value) {
7305
      if (!value) {
7306
        this.pe = null;
7307
      }
7308
    }
7309
 
7310
    public void setFieldValue(_Fields field, Object value) {
7311
      switch (field) {
7312
      case SUCCESS:
7313
        if (value == null) {
7314
          unsetSuccess();
7315
        } else {
695 rajveer 7316
          setSuccess((List<Payment>)value);
420 ashish 7317
        }
7318
        break;
7319
 
7320
      case PE:
7321
        if (value == null) {
7322
          unsetPe();
7323
        } else {
7324
          setPe((PaymentException)value);
7325
        }
7326
        break;
7327
 
7328
      }
7329
    }
7330
 
7331
    public Object getFieldValue(_Fields field) {
7332
      switch (field) {
7333
      case SUCCESS:
7334
        return getSuccess();
7335
 
7336
      case PE:
7337
        return getPe();
7338
 
7339
      }
7340
      throw new IllegalStateException();
7341
    }
7342
 
3430 rajveer 7343
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7344
    public boolean isSet(_Fields field) {
7345
      if (field == null) {
7346
        throw new IllegalArgumentException();
7347
      }
420 ashish 7348
 
7349
      switch (field) {
7350
      case SUCCESS:
7351
        return isSetSuccess();
7352
      case PE:
7353
        return isSetPe();
7354
      }
7355
      throw new IllegalStateException();
7356
    }
7357
 
7358
    @Override
7359
    public boolean equals(Object that) {
7360
      if (that == null)
7361
        return false;
695 rajveer 7362
      if (that instanceof getPaymentForTxnId_result)
7363
        return this.equals((getPaymentForTxnId_result)that);
420 ashish 7364
      return false;
7365
    }
7366
 
695 rajveer 7367
    public boolean equals(getPaymentForTxnId_result that) {
420 ashish 7368
      if (that == null)
7369
        return false;
7370
 
7371
      boolean this_present_success = true && this.isSetSuccess();
7372
      boolean that_present_success = true && that.isSetSuccess();
7373
      if (this_present_success || that_present_success) {
7374
        if (!(this_present_success && that_present_success))
7375
          return false;
7376
        if (!this.success.equals(that.success))
7377
          return false;
7378
      }
7379
 
7380
      boolean this_present_pe = true && this.isSetPe();
7381
      boolean that_present_pe = true && that.isSetPe();
7382
      if (this_present_pe || that_present_pe) {
7383
        if (!(this_present_pe && that_present_pe))
7384
          return false;
7385
        if (!this.pe.equals(that.pe))
7386
          return false;
7387
      }
7388
 
7389
      return true;
7390
    }
7391
 
7392
    @Override
7393
    public int hashCode() {
7394
      return 0;
7395
    }
7396
 
695 rajveer 7397
    public int compareTo(getPaymentForTxnId_result other) {
7398
      if (!getClass().equals(other.getClass())) {
7399
        return getClass().getName().compareTo(other.getClass().getName());
7400
      }
7401
 
7402
      int lastComparison = 0;
7403
      getPaymentForTxnId_result typedOther = (getPaymentForTxnId_result)other;
7404
 
3430 rajveer 7405
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 7406
      if (lastComparison != 0) {
7407
        return lastComparison;
7408
      }
3430 rajveer 7409
      if (isSetSuccess()) {
7410
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7411
        if (lastComparison != 0) {
7412
          return lastComparison;
7413
        }
695 rajveer 7414
      }
3430 rajveer 7415
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
695 rajveer 7416
      if (lastComparison != 0) {
7417
        return lastComparison;
7418
      }
3430 rajveer 7419
      if (isSetPe()) {
7420
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
7421
        if (lastComparison != 0) {
7422
          return lastComparison;
7423
        }
695 rajveer 7424
      }
7425
      return 0;
7426
    }
7427
 
3430 rajveer 7428
    public _Fields fieldForId(int fieldId) {
7429
      return _Fields.findByThriftId(fieldId);
7430
    }
7431
 
7432
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7433
      org.apache.thrift.protocol.TField field;
420 ashish 7434
      iprot.readStructBegin();
7435
      while (true)
7436
      {
7437
        field = iprot.readFieldBegin();
3430 rajveer 7438
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 7439
          break;
7440
        }
3430 rajveer 7441
        switch (field.id) {
7442
          case 0: // SUCCESS
7443
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
7444
              {
4141 chandransh 7445
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
7446
                this.success = new ArrayList<Payment>(_list24.size);
7447
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
695 rajveer 7448
                {
4141 chandransh 7449
                  Payment _elem26; // required
7450
                  _elem26 = new Payment();
7451
                  _elem26.read(iprot);
7452
                  this.success.add(_elem26);
695 rajveer 7453
                }
3430 rajveer 7454
                iprot.readListEnd();
420 ashish 7455
              }
3430 rajveer 7456
            } else { 
7457
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7458
            }
7459
            break;
7460
          case 1: // PE
7461
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7462
              this.pe = new PaymentException();
7463
              this.pe.read(iprot);
7464
            } else { 
7465
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7466
            }
7467
            break;
7468
          default:
7469
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 7470
        }
3430 rajveer 7471
        iprot.readFieldEnd();
420 ashish 7472
      }
7473
      iprot.readStructEnd();
7474
      validate();
7475
    }
7476
 
3430 rajveer 7477
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 7478
      oprot.writeStructBegin(STRUCT_DESC);
7479
 
7480
      if (this.isSetSuccess()) {
7481
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
695 rajveer 7482
        {
3430 rajveer 7483
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
4141 chandransh 7484
          for (Payment _iter27 : this.success)
695 rajveer 7485
          {
4141 chandransh 7486
            _iter27.write(oprot);
695 rajveer 7487
          }
7488
          oprot.writeListEnd();
7489
        }
420 ashish 7490
        oprot.writeFieldEnd();
7491
      } else if (this.isSetPe()) {
7492
        oprot.writeFieldBegin(PE_FIELD_DESC);
7493
        this.pe.write(oprot);
7494
        oprot.writeFieldEnd();
7495
      }
7496
      oprot.writeFieldStop();
7497
      oprot.writeStructEnd();
7498
    }
7499
 
7500
    @Override
7501
    public String toString() {
695 rajveer 7502
      StringBuilder sb = new StringBuilder("getPaymentForTxnId_result(");
420 ashish 7503
      boolean first = true;
7504
 
7505
      sb.append("success:");
7506
      if (this.success == null) {
7507
        sb.append("null");
7508
      } else {
7509
        sb.append(this.success);
7510
      }
7511
      first = false;
7512
      if (!first) sb.append(", ");
7513
      sb.append("pe:");
7514
      if (this.pe == null) {
7515
        sb.append("null");
7516
      } else {
7517
        sb.append(this.pe);
7518
      }
7519
      first = false;
7520
      sb.append(")");
7521
      return sb.toString();
7522
    }
7523
 
3430 rajveer 7524
    public void validate() throws org.apache.thrift.TException {
420 ashish 7525
      // check for required fields
7526
    }
7527
 
3430 rajveer 7528
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7529
      try {
7530
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7531
      } catch (org.apache.thrift.TException te) {
7532
        throw new java.io.IOException(te);
7533
      }
7534
    }
7535
 
7536
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7537
      try {
7538
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7539
      } catch (org.apache.thrift.TException te) {
7540
        throw new java.io.IOException(te);
7541
      }
7542
    }
7543
 
420 ashish 7544
  }
7545
 
3430 rajveer 7546
  public static class updatePaymentDetails_args implements org.apache.thrift.TBase<updatePaymentDetails_args, updatePaymentDetails_args._Fields>, java.io.Serializable, Cloneable   {
7547
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updatePaymentDetails_args");
420 ashish 7548
 
3430 rajveer 7549
    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);
7550
    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);
7551
    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);
7552
    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);
7553
    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);
7554
    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);
7555
    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);
7556
    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);
7557
    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);
7558
    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);
7559
    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);
7560
    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 7561
 
3430 rajveer 7562
    private long id; // required
7563
    private String gatewayPaymentId; // required
7564
    private String sessionId; // required
7565
    private String gatewayTxnStatus; // required
7566
    private String description; // required
7567
    private String gatewayTxnId; // required
7568
    private String authCode; // required
7569
    private String referenceCode; // required
7570
    private String errorCode; // required
7571
    private PaymentStatus status; // required
7572
    private String gatewayTxnDate; // required
7573
    private List<Attribute> attributes; // required
420 ashish 7574
 
7575
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7576
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
420 ashish 7577
      ID((short)1, "id"),
695 rajveer 7578
      GATEWAY_PAYMENT_ID((short)2, "gatewayPaymentId"),
7579
      SESSION_ID((short)3, "sessionId"),
7580
      GATEWAY_TXN_STATUS((short)4, "gatewayTxnStatus"),
7581
      DESCRIPTION((short)5, "description"),
7582
      GATEWAY_TXN_ID((short)6, "gatewayTxnId"),
7583
      AUTH_CODE((short)7, "authCode"),
7584
      REFERENCE_CODE((short)8, "referenceCode"),
7585
      ERROR_CODE((short)9, "errorCode"),
7586
      /**
7587
       * 
7588
       * @see PaymentStatus
7589
       */
7590
      STATUS((short)10, "status"),
1119 rajveer 7591
      GATEWAY_TXN_DATE((short)11, "gatewayTxnDate"),
7592
      ATTRIBUTES((short)12, "attributes");
420 ashish 7593
 
7594
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7595
 
7596
      static {
7597
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7598
          byName.put(field.getFieldName(), field);
7599
        }
7600
      }
7601
 
7602
      /**
7603
       * Find the _Fields constant that matches fieldId, or null if its not found.
7604
       */
7605
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7606
        switch(fieldId) {
7607
          case 1: // ID
7608
            return ID;
7609
          case 2: // GATEWAY_PAYMENT_ID
7610
            return GATEWAY_PAYMENT_ID;
7611
          case 3: // SESSION_ID
7612
            return SESSION_ID;
7613
          case 4: // GATEWAY_TXN_STATUS
7614
            return GATEWAY_TXN_STATUS;
7615
          case 5: // DESCRIPTION
7616
            return DESCRIPTION;
7617
          case 6: // GATEWAY_TXN_ID
7618
            return GATEWAY_TXN_ID;
7619
          case 7: // AUTH_CODE
7620
            return AUTH_CODE;
7621
          case 8: // REFERENCE_CODE
7622
            return REFERENCE_CODE;
7623
          case 9: // ERROR_CODE
7624
            return ERROR_CODE;
7625
          case 10: // STATUS
7626
            return STATUS;
7627
          case 11: // GATEWAY_TXN_DATE
7628
            return GATEWAY_TXN_DATE;
7629
          case 12: // ATTRIBUTES
7630
            return ATTRIBUTES;
7631
          default:
7632
            return null;
7633
        }
420 ashish 7634
      }
7635
 
7636
      /**
7637
       * Find the _Fields constant that matches fieldId, throwing an exception
7638
       * if it is not found.
7639
       */
7640
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7641
        _Fields fields = findByThriftId(fieldId);
7642
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7643
        return fields;
7644
      }
7645
 
7646
      /**
7647
       * Find the _Fields constant that matches name, or null if its not found.
7648
       */
7649
      public static _Fields findByName(String name) {
7650
        return byName.get(name);
7651
      }
7652
 
7653
      private final short _thriftId;
7654
      private final String _fieldName;
7655
 
7656
      _Fields(short thriftId, String fieldName) {
7657
        _thriftId = thriftId;
7658
        _fieldName = fieldName;
7659
      }
7660
 
7661
      public short getThriftFieldId() {
7662
        return _thriftId;
7663
      }
7664
 
7665
      public String getFieldName() {
7666
        return _fieldName;
7667
      }
7668
    }
7669
 
7670
    // isset id assignments
7671
    private static final int __ID_ISSET_ID = 0;
7672
    private BitSet __isset_bit_vector = new BitSet(1);
7673
 
3430 rajveer 7674
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 7675
    static {
3430 rajveer 7676
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7677
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7678
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7679
      tmpMap.put(_Fields.GATEWAY_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7680
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7681
      tmpMap.put(_Fields.SESSION_ID, new org.apache.thrift.meta_data.FieldMetaData("sessionId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7682
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7683
      tmpMap.put(_Fields.GATEWAY_TXN_STATUS, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnStatus", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7684
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7685
      tmpMap.put(_Fields.DESCRIPTION, new org.apache.thrift.meta_data.FieldMetaData("description", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7686
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7687
      tmpMap.put(_Fields.GATEWAY_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7688
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7689
      tmpMap.put(_Fields.AUTH_CODE, new org.apache.thrift.meta_data.FieldMetaData("authCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7690
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7691
      tmpMap.put(_Fields.REFERENCE_CODE, new org.apache.thrift.meta_data.FieldMetaData("referenceCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7692
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7693
      tmpMap.put(_Fields.ERROR_CODE, new org.apache.thrift.meta_data.FieldMetaData("errorCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7694
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7695
      tmpMap.put(_Fields.STATUS, new org.apache.thrift.meta_data.FieldMetaData("status", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7696
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, PaymentStatus.class)));
7697
      tmpMap.put(_Fields.GATEWAY_TXN_DATE, new org.apache.thrift.meta_data.FieldMetaData("gatewayTxnDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7698
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7699
      tmpMap.put(_Fields.ATTRIBUTES, new org.apache.thrift.meta_data.FieldMetaData("attributes", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7700
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
7701
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Attribute.class))));
7702
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7703
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updatePaymentDetails_args.class, metaDataMap);
420 ashish 7704
    }
7705
 
695 rajveer 7706
    public updatePaymentDetails_args() {
420 ashish 7707
    }
7708
 
695 rajveer 7709
    public updatePaymentDetails_args(
420 ashish 7710
      long id,
695 rajveer 7711
      String gatewayPaymentId,
7712
      String sessionId,
7713
      String gatewayTxnStatus,
7714
      String description,
7715
      String gatewayTxnId,
7716
      String authCode,
7717
      String referenceCode,
7718
      String errorCode,
7719
      PaymentStatus status,
1119 rajveer 7720
      String gatewayTxnDate,
695 rajveer 7721
      List<Attribute> attributes)
420 ashish 7722
    {
7723
      this();
7724
      this.id = id;
7725
      setIdIsSet(true);
695 rajveer 7726
      this.gatewayPaymentId = gatewayPaymentId;
7727
      this.sessionId = sessionId;
7728
      this.gatewayTxnStatus = gatewayTxnStatus;
7729
      this.description = description;
7730
      this.gatewayTxnId = gatewayTxnId;
7731
      this.authCode = authCode;
7732
      this.referenceCode = referenceCode;
7733
      this.errorCode = errorCode;
7734
      this.status = status;
1119 rajveer 7735
      this.gatewayTxnDate = gatewayTxnDate;
695 rajveer 7736
      this.attributes = attributes;
420 ashish 7737
    }
7738
 
7739
    /**
7740
     * Performs a deep copy on <i>other</i>.
7741
     */
695 rajveer 7742
    public updatePaymentDetails_args(updatePaymentDetails_args other) {
420 ashish 7743
      __isset_bit_vector.clear();
7744
      __isset_bit_vector.or(other.__isset_bit_vector);
7745
      this.id = other.id;
695 rajveer 7746
      if (other.isSetGatewayPaymentId()) {
7747
        this.gatewayPaymentId = other.gatewayPaymentId;
420 ashish 7748
      }
695 rajveer 7749
      if (other.isSetSessionId()) {
7750
        this.sessionId = other.sessionId;
420 ashish 7751
      }
695 rajveer 7752
      if (other.isSetGatewayTxnStatus()) {
7753
        this.gatewayTxnStatus = other.gatewayTxnStatus;
420 ashish 7754
      }
695 rajveer 7755
      if (other.isSetDescription()) {
7756
        this.description = other.description;
420 ashish 7757
      }
695 rajveer 7758
      if (other.isSetGatewayTxnId()) {
7759
        this.gatewayTxnId = other.gatewayTxnId;
420 ashish 7760
      }
695 rajveer 7761
      if (other.isSetAuthCode()) {
7762
        this.authCode = other.authCode;
420 ashish 7763
      }
695 rajveer 7764
      if (other.isSetReferenceCode()) {
7765
        this.referenceCode = other.referenceCode;
420 ashish 7766
      }
695 rajveer 7767
      if (other.isSetErrorCode()) {
7768
        this.errorCode = other.errorCode;
7769
      }
7770
      if (other.isSetStatus()) {
7771
        this.status = other.status;
7772
      }
1119 rajveer 7773
      if (other.isSetGatewayTxnDate()) {
7774
        this.gatewayTxnDate = other.gatewayTxnDate;
7775
      }
695 rajveer 7776
      if (other.isSetAttributes()) {
7777
        List<Attribute> __this__attributes = new ArrayList<Attribute>();
7778
        for (Attribute other_element : other.attributes) {
7779
          __this__attributes.add(new Attribute(other_element));
7780
        }
7781
        this.attributes = __this__attributes;
7782
      }
420 ashish 7783
    }
7784
 
695 rajveer 7785
    public updatePaymentDetails_args deepCopy() {
7786
      return new updatePaymentDetails_args(this);
420 ashish 7787
    }
7788
 
3430 rajveer 7789
    @Override
7790
    public void clear() {
7791
      setIdIsSet(false);
7792
      this.id = 0;
7793
      this.gatewayPaymentId = null;
7794
      this.sessionId = null;
7795
      this.gatewayTxnStatus = null;
7796
      this.description = null;
7797
      this.gatewayTxnId = null;
7798
      this.authCode = null;
7799
      this.referenceCode = null;
7800
      this.errorCode = null;
7801
      this.status = null;
7802
      this.gatewayTxnDate = null;
7803
      this.attributes = null;
420 ashish 7804
    }
7805
 
7806
    public long getId() {
7807
      return this.id;
7808
    }
7809
 
3430 rajveer 7810
    public void setId(long id) {
420 ashish 7811
      this.id = id;
7812
      setIdIsSet(true);
7813
    }
7814
 
7815
    public void unsetId() {
7816
      __isset_bit_vector.clear(__ID_ISSET_ID);
7817
    }
7818
 
3430 rajveer 7819
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
420 ashish 7820
    public boolean isSetId() {
7821
      return __isset_bit_vector.get(__ID_ISSET_ID);
7822
    }
7823
 
7824
    public void setIdIsSet(boolean value) {
7825
      __isset_bit_vector.set(__ID_ISSET_ID, value);
7826
    }
7827
 
695 rajveer 7828
    public String getGatewayPaymentId() {
7829
      return this.gatewayPaymentId;
420 ashish 7830
    }
7831
 
3430 rajveer 7832
    public void setGatewayPaymentId(String gatewayPaymentId) {
695 rajveer 7833
      this.gatewayPaymentId = gatewayPaymentId;
420 ashish 7834
    }
7835
 
695 rajveer 7836
    public void unsetGatewayPaymentId() {
7837
      this.gatewayPaymentId = null;
420 ashish 7838
    }
7839
 
3430 rajveer 7840
    /** Returns true if field gatewayPaymentId is set (has been assigned a value) and false otherwise */
695 rajveer 7841
    public boolean isSetGatewayPaymentId() {
7842
      return this.gatewayPaymentId != null;
420 ashish 7843
    }
7844
 
695 rajveer 7845
    public void setGatewayPaymentIdIsSet(boolean value) {
420 ashish 7846
      if (!value) {
695 rajveer 7847
        this.gatewayPaymentId = null;
420 ashish 7848
      }
7849
    }
7850
 
695 rajveer 7851
    public String getSessionId() {
7852
      return this.sessionId;
420 ashish 7853
    }
7854
 
3430 rajveer 7855
    public void setSessionId(String sessionId) {
695 rajveer 7856
      this.sessionId = sessionId;
420 ashish 7857
    }
7858
 
695 rajveer 7859
    public void unsetSessionId() {
7860
      this.sessionId = null;
420 ashish 7861
    }
7862
 
3430 rajveer 7863
    /** Returns true if field sessionId is set (has been assigned a value) and false otherwise */
695 rajveer 7864
    public boolean isSetSessionId() {
7865
      return this.sessionId != null;
420 ashish 7866
    }
7867
 
695 rajveer 7868
    public void setSessionIdIsSet(boolean value) {
420 ashish 7869
      if (!value) {
695 rajveer 7870
        this.sessionId = null;
420 ashish 7871
      }
7872
    }
7873
 
695 rajveer 7874
    public String getGatewayTxnStatus() {
7875
      return this.gatewayTxnStatus;
420 ashish 7876
    }
7877
 
3430 rajveer 7878
    public void setGatewayTxnStatus(String gatewayTxnStatus) {
695 rajveer 7879
      this.gatewayTxnStatus = gatewayTxnStatus;
420 ashish 7880
    }
7881
 
695 rajveer 7882
    public void unsetGatewayTxnStatus() {
7883
      this.gatewayTxnStatus = null;
420 ashish 7884
    }
7885
 
3430 rajveer 7886
    /** Returns true if field gatewayTxnStatus is set (has been assigned a value) and false otherwise */
695 rajveer 7887
    public boolean isSetGatewayTxnStatus() {
7888
      return this.gatewayTxnStatus != null;
420 ashish 7889
    }
7890
 
695 rajveer 7891
    public void setGatewayTxnStatusIsSet(boolean value) {
420 ashish 7892
      if (!value) {
695 rajveer 7893
        this.gatewayTxnStatus = null;
420 ashish 7894
      }
7895
    }
7896
 
695 rajveer 7897
    public String getDescription() {
7898
      return this.description;
420 ashish 7899
    }
7900
 
3430 rajveer 7901
    public void setDescription(String description) {
695 rajveer 7902
      this.description = description;
420 ashish 7903
    }
7904
 
695 rajveer 7905
    public void unsetDescription() {
7906
      this.description = null;
420 ashish 7907
    }
7908
 
3430 rajveer 7909
    /** Returns true if field description is set (has been assigned a value) and false otherwise */
695 rajveer 7910
    public boolean isSetDescription() {
7911
      return this.description != null;
420 ashish 7912
    }
7913
 
695 rajveer 7914
    public void setDescriptionIsSet(boolean value) {
420 ashish 7915
      if (!value) {
695 rajveer 7916
        this.description = null;
420 ashish 7917
      }
7918
    }
7919
 
695 rajveer 7920
    public String getGatewayTxnId() {
7921
      return this.gatewayTxnId;
420 ashish 7922
    }
7923
 
3430 rajveer 7924
    public void setGatewayTxnId(String gatewayTxnId) {
695 rajveer 7925
      this.gatewayTxnId = gatewayTxnId;
420 ashish 7926
    }
7927
 
695 rajveer 7928
    public void unsetGatewayTxnId() {
7929
      this.gatewayTxnId = null;
420 ashish 7930
    }
7931
 
3430 rajveer 7932
    /** Returns true if field gatewayTxnId is set (has been assigned a value) and false otherwise */
695 rajveer 7933
    public boolean isSetGatewayTxnId() {
7934
      return this.gatewayTxnId != null;
420 ashish 7935
    }
7936
 
695 rajveer 7937
    public void setGatewayTxnIdIsSet(boolean value) {
420 ashish 7938
      if (!value) {
695 rajveer 7939
        this.gatewayTxnId = null;
420 ashish 7940
      }
7941
    }
7942
 
695 rajveer 7943
    public String getAuthCode() {
7944
      return this.authCode;
420 ashish 7945
    }
7946
 
3430 rajveer 7947
    public void setAuthCode(String authCode) {
695 rajveer 7948
      this.authCode = authCode;
420 ashish 7949
    }
7950
 
695 rajveer 7951
    public void unsetAuthCode() {
7952
      this.authCode = null;
420 ashish 7953
    }
7954
 
3430 rajveer 7955
    /** Returns true if field authCode is set (has been assigned a value) and false otherwise */
695 rajveer 7956
    public boolean isSetAuthCode() {
7957
      return this.authCode != null;
420 ashish 7958
    }
7959
 
695 rajveer 7960
    public void setAuthCodeIsSet(boolean value) {
420 ashish 7961
      if (!value) {
695 rajveer 7962
        this.authCode = null;
420 ashish 7963
      }
7964
    }
7965
 
695 rajveer 7966
    public String getReferenceCode() {
7967
      return this.referenceCode;
420 ashish 7968
    }
7969
 
3430 rajveer 7970
    public void setReferenceCode(String referenceCode) {
695 rajveer 7971
      this.referenceCode = referenceCode;
420 ashish 7972
    }
7973
 
695 rajveer 7974
    public void unsetReferenceCode() {
7975
      this.referenceCode = null;
420 ashish 7976
    }
7977
 
3430 rajveer 7978
    /** Returns true if field referenceCode is set (has been assigned a value) and false otherwise */
695 rajveer 7979
    public boolean isSetReferenceCode() {
7980
      return this.referenceCode != null;
420 ashish 7981
    }
7982
 
695 rajveer 7983
    public void setReferenceCodeIsSet(boolean value) {
420 ashish 7984
      if (!value) {
695 rajveer 7985
        this.referenceCode = null;
420 ashish 7986
      }
7987
    }
7988
 
695 rajveer 7989
    public String getErrorCode() {
7990
      return this.errorCode;
7991
    }
7992
 
3430 rajveer 7993
    public void setErrorCode(String errorCode) {
695 rajveer 7994
      this.errorCode = errorCode;
7995
    }
7996
 
7997
    public void unsetErrorCode() {
7998
      this.errorCode = null;
7999
    }
8000
 
3430 rajveer 8001
    /** Returns true if field errorCode is set (has been assigned a value) and false otherwise */
695 rajveer 8002
    public boolean isSetErrorCode() {
8003
      return this.errorCode != null;
8004
    }
8005
 
8006
    public void setErrorCodeIsSet(boolean value) {
8007
      if (!value) {
8008
        this.errorCode = null;
8009
      }
8010
    }
8011
 
8012
    /**
8013
     * 
8014
     * @see PaymentStatus
8015
     */
8016
    public PaymentStatus getStatus() {
8017
      return this.status;
8018
    }
8019
 
8020
    /**
8021
     * 
8022
     * @see PaymentStatus
8023
     */
3430 rajveer 8024
    public void setStatus(PaymentStatus status) {
695 rajveer 8025
      this.status = status;
8026
    }
8027
 
8028
    public void unsetStatus() {
8029
      this.status = null;
8030
    }
8031
 
3430 rajveer 8032
    /** Returns true if field status is set (has been assigned a value) and false otherwise */
695 rajveer 8033
    public boolean isSetStatus() {
8034
      return this.status != null;
8035
    }
8036
 
8037
    public void setStatusIsSet(boolean value) {
8038
      if (!value) {
8039
        this.status = null;
8040
      }
8041
    }
8042
 
1119 rajveer 8043
    public String getGatewayTxnDate() {
8044
      return this.gatewayTxnDate;
8045
    }
8046
 
3430 rajveer 8047
    public void setGatewayTxnDate(String gatewayTxnDate) {
1119 rajveer 8048
      this.gatewayTxnDate = gatewayTxnDate;
8049
    }
8050
 
8051
    public void unsetGatewayTxnDate() {
8052
      this.gatewayTxnDate = null;
8053
    }
8054
 
3430 rajveer 8055
    /** Returns true if field gatewayTxnDate is set (has been assigned a value) and false otherwise */
1119 rajveer 8056
    public boolean isSetGatewayTxnDate() {
8057
      return this.gatewayTxnDate != null;
8058
    }
8059
 
8060
    public void setGatewayTxnDateIsSet(boolean value) {
8061
      if (!value) {
8062
        this.gatewayTxnDate = null;
8063
      }
8064
    }
8065
 
695 rajveer 8066
    public int getAttributesSize() {
8067
      return (this.attributes == null) ? 0 : this.attributes.size();
8068
    }
8069
 
8070
    public java.util.Iterator<Attribute> getAttributesIterator() {
8071
      return (this.attributes == null) ? null : this.attributes.iterator();
8072
    }
8073
 
8074
    public void addToAttributes(Attribute elem) {
8075
      if (this.attributes == null) {
8076
        this.attributes = new ArrayList<Attribute>();
8077
      }
8078
      this.attributes.add(elem);
8079
    }
8080
 
8081
    public List<Attribute> getAttributes() {
8082
      return this.attributes;
8083
    }
8084
 
3430 rajveer 8085
    public void setAttributes(List<Attribute> attributes) {
695 rajveer 8086
      this.attributes = attributes;
8087
    }
8088
 
8089
    public void unsetAttributes() {
8090
      this.attributes = null;
8091
    }
8092
 
3430 rajveer 8093
    /** Returns true if field attributes is set (has been assigned a value) and false otherwise */
695 rajveer 8094
    public boolean isSetAttributes() {
8095
      return this.attributes != null;
8096
    }
8097
 
8098
    public void setAttributesIsSet(boolean value) {
8099
      if (!value) {
8100
        this.attributes = null;
8101
      }
8102
    }
8103
 
420 ashish 8104
    public void setFieldValue(_Fields field, Object value) {
8105
      switch (field) {
8106
      case ID:
8107
        if (value == null) {
8108
          unsetId();
8109
        } else {
8110
          setId((Long)value);
8111
        }
8112
        break;
8113
 
695 rajveer 8114
      case GATEWAY_PAYMENT_ID:
420 ashish 8115
        if (value == null) {
695 rajveer 8116
          unsetGatewayPaymentId();
420 ashish 8117
        } else {
695 rajveer 8118
          setGatewayPaymentId((String)value);
420 ashish 8119
        }
8120
        break;
8121
 
695 rajveer 8122
      case SESSION_ID:
420 ashish 8123
        if (value == null) {
695 rajveer 8124
          unsetSessionId();
420 ashish 8125
        } else {
695 rajveer 8126
          setSessionId((String)value);
420 ashish 8127
        }
8128
        break;
8129
 
695 rajveer 8130
      case GATEWAY_TXN_STATUS:
420 ashish 8131
        if (value == null) {
695 rajveer 8132
          unsetGatewayTxnStatus();
420 ashish 8133
        } else {
695 rajveer 8134
          setGatewayTxnStatus((String)value);
420 ashish 8135
        }
8136
        break;
8137
 
695 rajveer 8138
      case DESCRIPTION:
420 ashish 8139
        if (value == null) {
695 rajveer 8140
          unsetDescription();
420 ashish 8141
        } else {
695 rajveer 8142
          setDescription((String)value);
420 ashish 8143
        }
8144
        break;
8145
 
695 rajveer 8146
      case GATEWAY_TXN_ID:
420 ashish 8147
        if (value == null) {
695 rajveer 8148
          unsetGatewayTxnId();
420 ashish 8149
        } else {
695 rajveer 8150
          setGatewayTxnId((String)value);
420 ashish 8151
        }
8152
        break;
8153
 
8154
      case AUTH_CODE:
8155
        if (value == null) {
695 rajveer 8156
          unsetAuthCode();
420 ashish 8157
        } else {
695 rajveer 8158
          setAuthCode((String)value);
420 ashish 8159
        }
8160
        break;
8161
 
695 rajveer 8162
      case REFERENCE_CODE:
420 ashish 8163
        if (value == null) {
695 rajveer 8164
          unsetReferenceCode();
420 ashish 8165
        } else {
695 rajveer 8166
          setReferenceCode((String)value);
420 ashish 8167
        }
8168
        break;
8169
 
695 rajveer 8170
      case ERROR_CODE:
8171
        if (value == null) {
8172
          unsetErrorCode();
8173
        } else {
8174
          setErrorCode((String)value);
8175
        }
8176
        break;
8177
 
8178
      case STATUS:
8179
        if (value == null) {
8180
          unsetStatus();
8181
        } else {
8182
          setStatus((PaymentStatus)value);
8183
        }
8184
        break;
8185
 
1119 rajveer 8186
      case GATEWAY_TXN_DATE:
8187
        if (value == null) {
8188
          unsetGatewayTxnDate();
8189
        } else {
8190
          setGatewayTxnDate((String)value);
8191
        }
8192
        break;
8193
 
695 rajveer 8194
      case ATTRIBUTES:
8195
        if (value == null) {
8196
          unsetAttributes();
8197
        } else {
8198
          setAttributes((List<Attribute>)value);
8199
        }
8200
        break;
8201
 
420 ashish 8202
      }
8203
    }
8204
 
8205
    public Object getFieldValue(_Fields field) {
8206
      switch (field) {
8207
      case ID:
3430 rajveer 8208
        return Long.valueOf(getId());
420 ashish 8209
 
695 rajveer 8210
      case GATEWAY_PAYMENT_ID:
8211
        return getGatewayPaymentId();
420 ashish 8212
 
695 rajveer 8213
      case SESSION_ID:
8214
        return getSessionId();
420 ashish 8215
 
695 rajveer 8216
      case GATEWAY_TXN_STATUS:
8217
        return getGatewayTxnStatus();
420 ashish 8218
 
695 rajveer 8219
      case DESCRIPTION:
8220
        return getDescription();
420 ashish 8221
 
695 rajveer 8222
      case GATEWAY_TXN_ID:
8223
        return getGatewayTxnId();
420 ashish 8224
 
8225
      case AUTH_CODE:
695 rajveer 8226
        return getAuthCode();
420 ashish 8227
 
695 rajveer 8228
      case REFERENCE_CODE:
8229
        return getReferenceCode();
420 ashish 8230
 
695 rajveer 8231
      case ERROR_CODE:
8232
        return getErrorCode();
8233
 
8234
      case STATUS:
8235
        return getStatus();
8236
 
1119 rajveer 8237
      case GATEWAY_TXN_DATE:
8238
        return getGatewayTxnDate();
8239
 
695 rajveer 8240
      case ATTRIBUTES:
8241
        return getAttributes();
8242
 
420 ashish 8243
      }
8244
      throw new IllegalStateException();
8245
    }
8246
 
3430 rajveer 8247
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8248
    public boolean isSet(_Fields field) {
8249
      if (field == null) {
8250
        throw new IllegalArgumentException();
8251
      }
420 ashish 8252
 
8253
      switch (field) {
8254
      case ID:
8255
        return isSetId();
695 rajveer 8256
      case GATEWAY_PAYMENT_ID:
8257
        return isSetGatewayPaymentId();
420 ashish 8258
      case SESSION_ID:
695 rajveer 8259
        return isSetSessionId();
8260
      case GATEWAY_TXN_STATUS:
8261
        return isSetGatewayTxnStatus();
8262
      case DESCRIPTION:
8263
        return isSetDescription();
8264
      case GATEWAY_TXN_ID:
8265
        return isSetGatewayTxnId();
420 ashish 8266
      case AUTH_CODE:
695 rajveer 8267
        return isSetAuthCode();
8268
      case REFERENCE_CODE:
8269
        return isSetReferenceCode();
8270
      case ERROR_CODE:
8271
        return isSetErrorCode();
8272
      case STATUS:
8273
        return isSetStatus();
1119 rajveer 8274
      case GATEWAY_TXN_DATE:
8275
        return isSetGatewayTxnDate();
695 rajveer 8276
      case ATTRIBUTES:
8277
        return isSetAttributes();
420 ashish 8278
      }
8279
      throw new IllegalStateException();
8280
    }
8281
 
8282
    @Override
8283
    public boolean equals(Object that) {
8284
      if (that == null)
8285
        return false;
695 rajveer 8286
      if (that instanceof updatePaymentDetails_args)
8287
        return this.equals((updatePaymentDetails_args)that);
420 ashish 8288
      return false;
8289
    }
8290
 
695 rajveer 8291
    public boolean equals(updatePaymentDetails_args that) {
420 ashish 8292
      if (that == null)
8293
        return false;
8294
 
8295
      boolean this_present_id = true;
8296
      boolean that_present_id = true;
8297
      if (this_present_id || that_present_id) {
8298
        if (!(this_present_id && that_present_id))
8299
          return false;
8300
        if (this.id != that.id)
8301
          return false;
8302
      }
8303
 
695 rajveer 8304
      boolean this_present_gatewayPaymentId = true && this.isSetGatewayPaymentId();
8305
      boolean that_present_gatewayPaymentId = true && that.isSetGatewayPaymentId();
8306
      if (this_present_gatewayPaymentId || that_present_gatewayPaymentId) {
8307
        if (!(this_present_gatewayPaymentId && that_present_gatewayPaymentId))
420 ashish 8308
          return false;
695 rajveer 8309
        if (!this.gatewayPaymentId.equals(that.gatewayPaymentId))
420 ashish 8310
          return false;
8311
      }
8312
 
695 rajveer 8313
      boolean this_present_sessionId = true && this.isSetSessionId();
8314
      boolean that_present_sessionId = true && that.isSetSessionId();
8315
      if (this_present_sessionId || that_present_sessionId) {
8316
        if (!(this_present_sessionId && that_present_sessionId))
420 ashish 8317
          return false;
695 rajveer 8318
        if (!this.sessionId.equals(that.sessionId))
420 ashish 8319
          return false;
8320
      }
8321
 
695 rajveer 8322
      boolean this_present_gatewayTxnStatus = true && this.isSetGatewayTxnStatus();
8323
      boolean that_present_gatewayTxnStatus = true && that.isSetGatewayTxnStatus();
8324
      if (this_present_gatewayTxnStatus || that_present_gatewayTxnStatus) {
8325
        if (!(this_present_gatewayTxnStatus && that_present_gatewayTxnStatus))
420 ashish 8326
          return false;
695 rajveer 8327
        if (!this.gatewayTxnStatus.equals(that.gatewayTxnStatus))
420 ashish 8328
          return false;
8329
      }
8330
 
695 rajveer 8331
      boolean this_present_description = true && this.isSetDescription();
8332
      boolean that_present_description = true && that.isSetDescription();
8333
      if (this_present_description || that_present_description) {
8334
        if (!(this_present_description && that_present_description))
420 ashish 8335
          return false;
695 rajveer 8336
        if (!this.description.equals(that.description))
420 ashish 8337
          return false;
8338
      }
8339
 
695 rajveer 8340
      boolean this_present_gatewayTxnId = true && this.isSetGatewayTxnId();
8341
      boolean that_present_gatewayTxnId = true && that.isSetGatewayTxnId();
8342
      if (this_present_gatewayTxnId || that_present_gatewayTxnId) {
8343
        if (!(this_present_gatewayTxnId && that_present_gatewayTxnId))
420 ashish 8344
          return false;
695 rajveer 8345
        if (!this.gatewayTxnId.equals(that.gatewayTxnId))
420 ashish 8346
          return false;
8347
      }
8348
 
695 rajveer 8349
      boolean this_present_authCode = true && this.isSetAuthCode();
8350
      boolean that_present_authCode = true && that.isSetAuthCode();
8351
      if (this_present_authCode || that_present_authCode) {
8352
        if (!(this_present_authCode && that_present_authCode))
420 ashish 8353
          return false;
695 rajveer 8354
        if (!this.authCode.equals(that.authCode))
420 ashish 8355
          return false;
8356
      }
8357
 
695 rajveer 8358
      boolean this_present_referenceCode = true && this.isSetReferenceCode();
8359
      boolean that_present_referenceCode = true && that.isSetReferenceCode();
8360
      if (this_present_referenceCode || that_present_referenceCode) {
8361
        if (!(this_present_referenceCode && that_present_referenceCode))
420 ashish 8362
          return false;
695 rajveer 8363
        if (!this.referenceCode.equals(that.referenceCode))
420 ashish 8364
          return false;
8365
      }
8366
 
695 rajveer 8367
      boolean this_present_errorCode = true && this.isSetErrorCode();
8368
      boolean that_present_errorCode = true && that.isSetErrorCode();
8369
      if (this_present_errorCode || that_present_errorCode) {
8370
        if (!(this_present_errorCode && that_present_errorCode))
8371
          return false;
8372
        if (!this.errorCode.equals(that.errorCode))
8373
          return false;
8374
      }
8375
 
8376
      boolean this_present_status = true && this.isSetStatus();
8377
      boolean that_present_status = true && that.isSetStatus();
8378
      if (this_present_status || that_present_status) {
8379
        if (!(this_present_status && that_present_status))
8380
          return false;
8381
        if (!this.status.equals(that.status))
8382
          return false;
8383
      }
8384
 
1119 rajveer 8385
      boolean this_present_gatewayTxnDate = true && this.isSetGatewayTxnDate();
8386
      boolean that_present_gatewayTxnDate = true && that.isSetGatewayTxnDate();
8387
      if (this_present_gatewayTxnDate || that_present_gatewayTxnDate) {
8388
        if (!(this_present_gatewayTxnDate && that_present_gatewayTxnDate))
8389
          return false;
8390
        if (!this.gatewayTxnDate.equals(that.gatewayTxnDate))
8391
          return false;
8392
      }
8393
 
695 rajveer 8394
      boolean this_present_attributes = true && this.isSetAttributes();
8395
      boolean that_present_attributes = true && that.isSetAttributes();
8396
      if (this_present_attributes || that_present_attributes) {
8397
        if (!(this_present_attributes && that_present_attributes))
8398
          return false;
8399
        if (!this.attributes.equals(that.attributes))
8400
          return false;
8401
      }
8402
 
420 ashish 8403
      return true;
8404
    }
8405
 
8406
    @Override
8407
    public int hashCode() {
8408
      return 0;
8409
    }
8410
 
695 rajveer 8411
    public int compareTo(updatePaymentDetails_args other) {
420 ashish 8412
      if (!getClass().equals(other.getClass())) {
8413
        return getClass().getName().compareTo(other.getClass().getName());
8414
      }
8415
 
8416
      int lastComparison = 0;
695 rajveer 8417
      updatePaymentDetails_args typedOther = (updatePaymentDetails_args)other;
420 ashish 8418
 
3430 rajveer 8419
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
420 ashish 8420
      if (lastComparison != 0) {
8421
        return lastComparison;
8422
      }
3430 rajveer 8423
      if (isSetId()) {
8424
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
8425
        if (lastComparison != 0) {
8426
          return lastComparison;
8427
        }
420 ashish 8428
      }
3430 rajveer 8429
      lastComparison = Boolean.valueOf(isSetGatewayPaymentId()).compareTo(typedOther.isSetGatewayPaymentId());
420 ashish 8430
      if (lastComparison != 0) {
8431
        return lastComparison;
8432
      }
3430 rajveer 8433
      if (isSetGatewayPaymentId()) {
8434
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayPaymentId, typedOther.gatewayPaymentId);
8435
        if (lastComparison != 0) {
8436
          return lastComparison;
8437
        }
420 ashish 8438
      }
3430 rajveer 8439
      lastComparison = Boolean.valueOf(isSetSessionId()).compareTo(typedOther.isSetSessionId());
420 ashish 8440
      if (lastComparison != 0) {
8441
        return lastComparison;
8442
      }
3430 rajveer 8443
      if (isSetSessionId()) {
8444
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sessionId, typedOther.sessionId);
8445
        if (lastComparison != 0) {
8446
          return lastComparison;
8447
        }
420 ashish 8448
      }
3430 rajveer 8449
      lastComparison = Boolean.valueOf(isSetGatewayTxnStatus()).compareTo(typedOther.isSetGatewayTxnStatus());
420 ashish 8450
      if (lastComparison != 0) {
8451
        return lastComparison;
8452
      }
3430 rajveer 8453
      if (isSetGatewayTxnStatus()) {
8454
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnStatus, typedOther.gatewayTxnStatus);
8455
        if (lastComparison != 0) {
8456
          return lastComparison;
8457
        }
420 ashish 8458
      }
3430 rajveer 8459
      lastComparison = Boolean.valueOf(isSetDescription()).compareTo(typedOther.isSetDescription());
420 ashish 8460
      if (lastComparison != 0) {
8461
        return lastComparison;
8462
      }
3430 rajveer 8463
      if (isSetDescription()) {
8464
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.description, typedOther.description);
8465
        if (lastComparison != 0) {
8466
          return lastComparison;
8467
        }
420 ashish 8468
      }
3430 rajveer 8469
      lastComparison = Boolean.valueOf(isSetGatewayTxnId()).compareTo(typedOther.isSetGatewayTxnId());
420 ashish 8470
      if (lastComparison != 0) {
8471
        return lastComparison;
8472
      }
3430 rajveer 8473
      if (isSetGatewayTxnId()) {
8474
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnId, typedOther.gatewayTxnId);
8475
        if (lastComparison != 0) {
8476
          return lastComparison;
8477
        }
420 ashish 8478
      }
3430 rajveer 8479
      lastComparison = Boolean.valueOf(isSetAuthCode()).compareTo(typedOther.isSetAuthCode());
420 ashish 8480
      if (lastComparison != 0) {
8481
        return lastComparison;
8482
      }
3430 rajveer 8483
      if (isSetAuthCode()) {
8484
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.authCode, typedOther.authCode);
8485
        if (lastComparison != 0) {
8486
          return lastComparison;
8487
        }
420 ashish 8488
      }
3430 rajveer 8489
      lastComparison = Boolean.valueOf(isSetReferenceCode()).compareTo(typedOther.isSetReferenceCode());
420 ashish 8490
      if (lastComparison != 0) {
8491
        return lastComparison;
8492
      }
3430 rajveer 8493
      if (isSetReferenceCode()) {
8494
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.referenceCode, typedOther.referenceCode);
8495
        if (lastComparison != 0) {
8496
          return lastComparison;
8497
        }
420 ashish 8498
      }
3430 rajveer 8499
      lastComparison = Boolean.valueOf(isSetErrorCode()).compareTo(typedOther.isSetErrorCode());
695 rajveer 8500
      if (lastComparison != 0) {
8501
        return lastComparison;
8502
      }
3430 rajveer 8503
      if (isSetErrorCode()) {
8504
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.errorCode, typedOther.errorCode);
8505
        if (lastComparison != 0) {
8506
          return lastComparison;
8507
        }
695 rajveer 8508
      }
3430 rajveer 8509
      lastComparison = Boolean.valueOf(isSetStatus()).compareTo(typedOther.isSetStatus());
695 rajveer 8510
      if (lastComparison != 0) {
8511
        return lastComparison;
8512
      }
3430 rajveer 8513
      if (isSetStatus()) {
8514
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.status, typedOther.status);
8515
        if (lastComparison != 0) {
8516
          return lastComparison;
8517
        }
695 rajveer 8518
      }
3430 rajveer 8519
      lastComparison = Boolean.valueOf(isSetGatewayTxnDate()).compareTo(typedOther.isSetGatewayTxnDate());
1119 rajveer 8520
      if (lastComparison != 0) {
8521
        return lastComparison;
8522
      }
3430 rajveer 8523
      if (isSetGatewayTxnDate()) {
8524
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.gatewayTxnDate, typedOther.gatewayTxnDate);
8525
        if (lastComparison != 0) {
8526
          return lastComparison;
8527
        }
1119 rajveer 8528
      }
3430 rajveer 8529
      lastComparison = Boolean.valueOf(isSetAttributes()).compareTo(typedOther.isSetAttributes());
695 rajveer 8530
      if (lastComparison != 0) {
8531
        return lastComparison;
8532
      }
3430 rajveer 8533
      if (isSetAttributes()) {
8534
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.attributes, typedOther.attributes);
8535
        if (lastComparison != 0) {
8536
          return lastComparison;
8537
        }
695 rajveer 8538
      }
420 ashish 8539
      return 0;
8540
    }
8541
 
3430 rajveer 8542
    public _Fields fieldForId(int fieldId) {
8543
      return _Fields.findByThriftId(fieldId);
8544
    }
8545
 
8546
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8547
      org.apache.thrift.protocol.TField field;
420 ashish 8548
      iprot.readStructBegin();
8549
      while (true)
8550
      {
8551
        field = iprot.readFieldBegin();
3430 rajveer 8552
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 8553
          break;
8554
        }
3430 rajveer 8555
        switch (field.id) {
8556
          case 1: // ID
8557
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8558
              this.id = iprot.readI64();
8559
              setIdIsSet(true);
8560
            } else { 
8561
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8562
            }
8563
            break;
8564
          case 2: // GATEWAY_PAYMENT_ID
8565
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8566
              this.gatewayPaymentId = iprot.readString();
8567
            } else { 
8568
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8569
            }
8570
            break;
8571
          case 3: // SESSION_ID
8572
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8573
              this.sessionId = iprot.readString();
8574
            } else { 
8575
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8576
            }
8577
            break;
8578
          case 4: // GATEWAY_TXN_STATUS
8579
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8580
              this.gatewayTxnStatus = iprot.readString();
8581
            } else { 
8582
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8583
            }
8584
            break;
8585
          case 5: // DESCRIPTION
8586
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8587
              this.description = iprot.readString();
8588
            } else { 
8589
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8590
            }
8591
            break;
8592
          case 6: // GATEWAY_TXN_ID
8593
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8594
              this.gatewayTxnId = iprot.readString();
8595
            } else { 
8596
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8597
            }
8598
            break;
8599
          case 7: // AUTH_CODE
8600
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8601
              this.authCode = iprot.readString();
8602
            } else { 
8603
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8604
            }
8605
            break;
8606
          case 8: // REFERENCE_CODE
8607
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8608
              this.referenceCode = iprot.readString();
8609
            } else { 
8610
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8611
            }
8612
            break;
8613
          case 9: // ERROR_CODE
8614
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8615
              this.errorCode = iprot.readString();
8616
            } else { 
8617
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8618
            }
8619
            break;
8620
          case 10: // STATUS
8621
            if (field.type == org.apache.thrift.protocol.TType.I32) {
8622
              this.status = PaymentStatus.findByValue(iprot.readI32());
8623
            } else { 
8624
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8625
            }
8626
            break;
8627
          case 11: // GATEWAY_TXN_DATE
8628
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8629
              this.gatewayTxnDate = iprot.readString();
8630
            } else { 
8631
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8632
            }
8633
            break;
8634
          case 12: // ATTRIBUTES
8635
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
8636
              {
4141 chandransh 8637
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
8638
                this.attributes = new ArrayList<Attribute>(_list28.size);
8639
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
695 rajveer 8640
                {
4141 chandransh 8641
                  Attribute _elem30; // required
8642
                  _elem30 = new Attribute();
8643
                  _elem30.read(iprot);
8644
                  this.attributes.add(_elem30);
695 rajveer 8645
                }
3430 rajveer 8646
                iprot.readListEnd();
695 rajveer 8647
              }
3430 rajveer 8648
            } else { 
8649
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8650
            }
8651
            break;
8652
          default:
8653
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 8654
        }
3430 rajveer 8655
        iprot.readFieldEnd();
420 ashish 8656
      }
8657
      iprot.readStructEnd();
8658
      validate();
8659
    }
8660
 
3430 rajveer 8661
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 8662
      validate();
8663
 
8664
      oprot.writeStructBegin(STRUCT_DESC);
8665
      oprot.writeFieldBegin(ID_FIELD_DESC);
8666
      oprot.writeI64(this.id);
8667
      oprot.writeFieldEnd();
695 rajveer 8668
      if (this.gatewayPaymentId != null) {
8669
        oprot.writeFieldBegin(GATEWAY_PAYMENT_ID_FIELD_DESC);
8670
        oprot.writeString(this.gatewayPaymentId);
420 ashish 8671
        oprot.writeFieldEnd();
8672
      }
695 rajveer 8673
      if (this.sessionId != null) {
8674
        oprot.writeFieldBegin(SESSION_ID_FIELD_DESC);
8675
        oprot.writeString(this.sessionId);
420 ashish 8676
        oprot.writeFieldEnd();
8677
      }
695 rajveer 8678
      if (this.gatewayTxnStatus != null) {
8679
        oprot.writeFieldBegin(GATEWAY_TXN_STATUS_FIELD_DESC);
8680
        oprot.writeString(this.gatewayTxnStatus);
420 ashish 8681
        oprot.writeFieldEnd();
8682
      }
695 rajveer 8683
      if (this.description != null) {
8684
        oprot.writeFieldBegin(DESCRIPTION_FIELD_DESC);
8685
        oprot.writeString(this.description);
420 ashish 8686
        oprot.writeFieldEnd();
8687
      }
695 rajveer 8688
      if (this.gatewayTxnId != null) {
8689
        oprot.writeFieldBegin(GATEWAY_TXN_ID_FIELD_DESC);
8690
        oprot.writeString(this.gatewayTxnId);
420 ashish 8691
        oprot.writeFieldEnd();
8692
      }
695 rajveer 8693
      if (this.authCode != null) {
420 ashish 8694
        oprot.writeFieldBegin(AUTH_CODE_FIELD_DESC);
695 rajveer 8695
        oprot.writeString(this.authCode);
420 ashish 8696
        oprot.writeFieldEnd();
8697
      }
695 rajveer 8698
      if (this.referenceCode != null) {
8699
        oprot.writeFieldBegin(REFERENCE_CODE_FIELD_DESC);
8700
        oprot.writeString(this.referenceCode);
420 ashish 8701
        oprot.writeFieldEnd();
8702
      }
695 rajveer 8703
      if (this.errorCode != null) {
8704
        oprot.writeFieldBegin(ERROR_CODE_FIELD_DESC);
8705
        oprot.writeString(this.errorCode);
8706
        oprot.writeFieldEnd();
8707
      }
8708
      if (this.status != null) {
8709
        oprot.writeFieldBegin(STATUS_FIELD_DESC);
8710
        oprot.writeI32(this.status.getValue());
8711
        oprot.writeFieldEnd();
8712
      }
1119 rajveer 8713
      if (this.gatewayTxnDate != null) {
8714
        oprot.writeFieldBegin(GATEWAY_TXN_DATE_FIELD_DESC);
8715
        oprot.writeString(this.gatewayTxnDate);
8716
        oprot.writeFieldEnd();
8717
      }
695 rajveer 8718
      if (this.attributes != null) {
8719
        oprot.writeFieldBegin(ATTRIBUTES_FIELD_DESC);
8720
        {
3430 rajveer 8721
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.attributes.size()));
4141 chandransh 8722
          for (Attribute _iter31 : this.attributes)
695 rajveer 8723
          {
4141 chandransh 8724
            _iter31.write(oprot);
695 rajveer 8725
          }
8726
          oprot.writeListEnd();
8727
        }
8728
        oprot.writeFieldEnd();
8729
      }
420 ashish 8730
      oprot.writeFieldStop();
8731
      oprot.writeStructEnd();
8732
    }
8733
 
8734
    @Override
8735
    public String toString() {
695 rajveer 8736
      StringBuilder sb = new StringBuilder("updatePaymentDetails_args(");
420 ashish 8737
      boolean first = true;
8738
 
8739
      sb.append("id:");
8740
      sb.append(this.id);
8741
      first = false;
8742
      if (!first) sb.append(", ");
695 rajveer 8743
      sb.append("gatewayPaymentId:");
8744
      if (this.gatewayPaymentId == null) {
420 ashish 8745
        sb.append("null");
8746
      } else {
695 rajveer 8747
        sb.append(this.gatewayPaymentId);
420 ashish 8748
      }
8749
      first = false;
8750
      if (!first) sb.append(", ");
695 rajveer 8751
      sb.append("sessionId:");
8752
      if (this.sessionId == null) {
420 ashish 8753
        sb.append("null");
8754
      } else {
695 rajveer 8755
        sb.append(this.sessionId);
420 ashish 8756
      }
8757
      first = false;
8758
      if (!first) sb.append(", ");
695 rajveer 8759
      sb.append("gatewayTxnStatus:");
8760
      if (this.gatewayTxnStatus == null) {
420 ashish 8761
        sb.append("null");
8762
      } else {
695 rajveer 8763
        sb.append(this.gatewayTxnStatus);
420 ashish 8764
      }
8765
      first = false;
8766
      if (!first) sb.append(", ");
695 rajveer 8767
      sb.append("description:");
8768
      if (this.description == null) {
420 ashish 8769
        sb.append("null");
8770
      } else {
695 rajveer 8771
        sb.append(this.description);
420 ashish 8772
      }
8773
      first = false;
8774
      if (!first) sb.append(", ");
695 rajveer 8775
      sb.append("gatewayTxnId:");
8776
      if (this.gatewayTxnId == null) {
420 ashish 8777
        sb.append("null");
8778
      } else {
695 rajveer 8779
        sb.append(this.gatewayTxnId);
420 ashish 8780
      }
8781
      first = false;
8782
      if (!first) sb.append(", ");
695 rajveer 8783
      sb.append("authCode:");
8784
      if (this.authCode == null) {
420 ashish 8785
        sb.append("null");
8786
      } else {
695 rajveer 8787
        sb.append(this.authCode);
420 ashish 8788
      }
8789
      first = false;
8790
      if (!first) sb.append(", ");
695 rajveer 8791
      sb.append("referenceCode:");
8792
      if (this.referenceCode == null) {
420 ashish 8793
        sb.append("null");
8794
      } else {
695 rajveer 8795
        sb.append(this.referenceCode);
420 ashish 8796
      }
8797
      first = false;
695 rajveer 8798
      if (!first) sb.append(", ");
8799
      sb.append("errorCode:");
8800
      if (this.errorCode == null) {
8801
        sb.append("null");
8802
      } else {
8803
        sb.append(this.errorCode);
8804
      }
8805
      first = false;
8806
      if (!first) sb.append(", ");
8807
      sb.append("status:");
8808
      if (this.status == null) {
8809
        sb.append("null");
8810
      } else {
8811
        sb.append(this.status);
8812
      }
8813
      first = false;
8814
      if (!first) sb.append(", ");
1119 rajveer 8815
      sb.append("gatewayTxnDate:");
8816
      if (this.gatewayTxnDate == null) {
8817
        sb.append("null");
8818
      } else {
8819
        sb.append(this.gatewayTxnDate);
8820
      }
8821
      first = false;
8822
      if (!first) sb.append(", ");
695 rajveer 8823
      sb.append("attributes:");
8824
      if (this.attributes == null) {
8825
        sb.append("null");
8826
      } else {
8827
        sb.append(this.attributes);
8828
      }
8829
      first = false;
420 ashish 8830
      sb.append(")");
8831
      return sb.toString();
8832
    }
8833
 
3430 rajveer 8834
    public void validate() throws org.apache.thrift.TException {
420 ashish 8835
      // check for required fields
8836
    }
8837
 
3430 rajveer 8838
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8839
      try {
8840
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8841
      } catch (org.apache.thrift.TException te) {
8842
        throw new java.io.IOException(te);
8843
      }
8844
    }
8845
 
8846
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8847
      try {
8848
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8849
        __isset_bit_vector = new BitSet(1);
8850
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8851
      } catch (org.apache.thrift.TException te) {
8852
        throw new java.io.IOException(te);
8853
      }
8854
    }
8855
 
420 ashish 8856
  }
8857
 
3430 rajveer 8858
  public static class updatePaymentDetails_result implements org.apache.thrift.TBase<updatePaymentDetails_result, updatePaymentDetails_result._Fields>, java.io.Serializable, Cloneable   {
8859
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updatePaymentDetails_result");
420 ashish 8860
 
3430 rajveer 8861
    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);
8862
    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 8863
 
3430 rajveer 8864
    private boolean success; // required
8865
    private PaymentException pe; // required
420 ashish 8866
 
8867
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 8868
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
695 rajveer 8869
      SUCCESS((short)0, "success"),
420 ashish 8870
      PE((short)1, "pe");
8871
 
8872
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8873
 
8874
      static {
8875
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8876
          byName.put(field.getFieldName(), field);
8877
        }
8878
      }
8879
 
8880
      /**
8881
       * Find the _Fields constant that matches fieldId, or null if its not found.
8882
       */
8883
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 8884
        switch(fieldId) {
8885
          case 0: // SUCCESS
8886
            return SUCCESS;
8887
          case 1: // PE
8888
            return PE;
8889
          default:
8890
            return null;
8891
        }
420 ashish 8892
      }
8893
 
8894
      /**
8895
       * Find the _Fields constant that matches fieldId, throwing an exception
8896
       * if it is not found.
8897
       */
8898
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8899
        _Fields fields = findByThriftId(fieldId);
8900
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8901
        return fields;
8902
      }
8903
 
8904
      /**
8905
       * Find the _Fields constant that matches name, or null if its not found.
8906
       */
8907
      public static _Fields findByName(String name) {
8908
        return byName.get(name);
8909
      }
8910
 
8911
      private final short _thriftId;
8912
      private final String _fieldName;
8913
 
8914
      _Fields(short thriftId, String fieldName) {
8915
        _thriftId = thriftId;
8916
        _fieldName = fieldName;
8917
      }
8918
 
8919
      public short getThriftFieldId() {
8920
        return _thriftId;
8921
      }
8922
 
8923
      public String getFieldName() {
8924
        return _fieldName;
8925
      }
8926
    }
8927
 
8928
    // isset id assignments
695 rajveer 8929
    private static final int __SUCCESS_ISSET_ID = 0;
8930
    private BitSet __isset_bit_vector = new BitSet(1);
420 ashish 8931
 
3430 rajveer 8932
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
420 ashish 8933
    static {
3430 rajveer 8934
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8935
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8936
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
8937
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8938
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8939
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8940
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updatePaymentDetails_result.class, metaDataMap);
420 ashish 8941
    }
8942
 
695 rajveer 8943
    public updatePaymentDetails_result() {
420 ashish 8944
    }
8945
 
695 rajveer 8946
    public updatePaymentDetails_result(
8947
      boolean success,
420 ashish 8948
      PaymentException pe)
8949
    {
8950
      this();
695 rajveer 8951
      this.success = success;
8952
      setSuccessIsSet(true);
420 ashish 8953
      this.pe = pe;
8954
    }
8955
 
8956
    /**
8957
     * Performs a deep copy on <i>other</i>.
8958
     */
695 rajveer 8959
    public updatePaymentDetails_result(updatePaymentDetails_result other) {
8960
      __isset_bit_vector.clear();
8961
      __isset_bit_vector.or(other.__isset_bit_vector);
8962
      this.success = other.success;
420 ashish 8963
      if (other.isSetPe()) {
8964
        this.pe = new PaymentException(other.pe);
8965
      }
8966
    }
8967
 
695 rajveer 8968
    public updatePaymentDetails_result deepCopy() {
8969
      return new updatePaymentDetails_result(this);
420 ashish 8970
    }
8971
 
3430 rajveer 8972
    @Override
8973
    public void clear() {
8974
      setSuccessIsSet(false);
8975
      this.success = false;
8976
      this.pe = null;
420 ashish 8977
    }
8978
 
695 rajveer 8979
    public boolean isSuccess() {
8980
      return this.success;
8981
    }
8982
 
3430 rajveer 8983
    public void setSuccess(boolean success) {
695 rajveer 8984
      this.success = success;
8985
      setSuccessIsSet(true);
8986
    }
8987
 
8988
    public void unsetSuccess() {
8989
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
8990
    }
8991
 
3430 rajveer 8992
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
695 rajveer 8993
    public boolean isSetSuccess() {
8994
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
8995
    }
8996
 
8997
    public void setSuccessIsSet(boolean value) {
8998
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
8999
    }
9000
 
420 ashish 9001
    public PaymentException getPe() {
9002
      return this.pe;
9003
    }
9004
 
3430 rajveer 9005
    public void setPe(PaymentException pe) {
420 ashish 9006
      this.pe = pe;
9007
    }
9008
 
9009
    public void unsetPe() {
9010
      this.pe = null;
9011
    }
9012
 
3430 rajveer 9013
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
420 ashish 9014
    public boolean isSetPe() {
9015
      return this.pe != null;
9016
    }
9017
 
9018
    public void setPeIsSet(boolean value) {
9019
      if (!value) {
9020
        this.pe = null;
9021
      }
9022
    }
9023
 
9024
    public void setFieldValue(_Fields field, Object value) {
9025
      switch (field) {
695 rajveer 9026
      case SUCCESS:
9027
        if (value == null) {
9028
          unsetSuccess();
9029
        } else {
9030
          setSuccess((Boolean)value);
9031
        }
9032
        break;
9033
 
420 ashish 9034
      case PE:
9035
        if (value == null) {
9036
          unsetPe();
9037
        } else {
9038
          setPe((PaymentException)value);
9039
        }
9040
        break;
9041
 
9042
      }
9043
    }
9044
 
9045
    public Object getFieldValue(_Fields field) {
9046
      switch (field) {
695 rajveer 9047
      case SUCCESS:
3430 rajveer 9048
        return Boolean.valueOf(isSuccess());
695 rajveer 9049
 
420 ashish 9050
      case PE:
9051
        return getPe();
9052
 
9053
      }
9054
      throw new IllegalStateException();
9055
    }
9056
 
3430 rajveer 9057
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9058
    public boolean isSet(_Fields field) {
9059
      if (field == null) {
9060
        throw new IllegalArgumentException();
9061
      }
420 ashish 9062
 
9063
      switch (field) {
695 rajveer 9064
      case SUCCESS:
9065
        return isSetSuccess();
420 ashish 9066
      case PE:
9067
        return isSetPe();
9068
      }
9069
      throw new IllegalStateException();
9070
    }
9071
 
9072
    @Override
9073
    public boolean equals(Object that) {
9074
      if (that == null)
9075
        return false;
695 rajveer 9076
      if (that instanceof updatePaymentDetails_result)
9077
        return this.equals((updatePaymentDetails_result)that);
420 ashish 9078
      return false;
9079
    }
9080
 
695 rajveer 9081
    public boolean equals(updatePaymentDetails_result that) {
420 ashish 9082
      if (that == null)
9083
        return false;
9084
 
695 rajveer 9085
      boolean this_present_success = true;
9086
      boolean that_present_success = true;
9087
      if (this_present_success || that_present_success) {
9088
        if (!(this_present_success && that_present_success))
9089
          return false;
9090
        if (this.success != that.success)
9091
          return false;
9092
      }
9093
 
420 ashish 9094
      boolean this_present_pe = true && this.isSetPe();
9095
      boolean that_present_pe = true && that.isSetPe();
9096
      if (this_present_pe || that_present_pe) {
9097
        if (!(this_present_pe && that_present_pe))
9098
          return false;
9099
        if (!this.pe.equals(that.pe))
9100
          return false;
9101
      }
9102
 
9103
      return true;
9104
    }
9105
 
9106
    @Override
9107
    public int hashCode() {
9108
      return 0;
9109
    }
9110
 
695 rajveer 9111
    public int compareTo(updatePaymentDetails_result other) {
420 ashish 9112
      if (!getClass().equals(other.getClass())) {
9113
        return getClass().getName().compareTo(other.getClass().getName());
9114
      }
9115
 
9116
      int lastComparison = 0;
695 rajveer 9117
      updatePaymentDetails_result typedOther = (updatePaymentDetails_result)other;
420 ashish 9118
 
3430 rajveer 9119
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
695 rajveer 9120
      if (lastComparison != 0) {
9121
        return lastComparison;
9122
      }
3430 rajveer 9123
      if (isSetSuccess()) {
9124
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9125
        if (lastComparison != 0) {
9126
          return lastComparison;
9127
        }
695 rajveer 9128
      }
3430 rajveer 9129
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
420 ashish 9130
      if (lastComparison != 0) {
9131
        return lastComparison;
9132
      }
3430 rajveer 9133
      if (isSetPe()) {
9134
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
9135
        if (lastComparison != 0) {
9136
          return lastComparison;
9137
        }
420 ashish 9138
      }
9139
      return 0;
9140
    }
9141
 
3430 rajveer 9142
    public _Fields fieldForId(int fieldId) {
9143
      return _Fields.findByThriftId(fieldId);
9144
    }
9145
 
9146
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9147
      org.apache.thrift.protocol.TField field;
420 ashish 9148
      iprot.readStructBegin();
9149
      while (true)
9150
      {
9151
        field = iprot.readFieldBegin();
3430 rajveer 9152
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
420 ashish 9153
          break;
9154
        }
3430 rajveer 9155
        switch (field.id) {
9156
          case 0: // SUCCESS
9157
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
9158
              this.success = iprot.readBool();
9159
              setSuccessIsSet(true);
9160
            } else { 
9161
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9162
            }
9163
            break;
9164
          case 1: // PE
9165
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9166
              this.pe = new PaymentException();
9167
              this.pe.read(iprot);
9168
            } else { 
9169
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9170
            }
9171
            break;
9172
          default:
9173
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
420 ashish 9174
        }
3430 rajveer 9175
        iprot.readFieldEnd();
420 ashish 9176
      }
9177
      iprot.readStructEnd();
9178
      validate();
9179
    }
9180
 
3430 rajveer 9181
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
420 ashish 9182
      oprot.writeStructBegin(STRUCT_DESC);
9183
 
695 rajveer 9184
      if (this.isSetSuccess()) {
9185
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9186
        oprot.writeBool(this.success);
9187
        oprot.writeFieldEnd();
9188
      } else if (this.isSetPe()) {
420 ashish 9189
        oprot.writeFieldBegin(PE_FIELD_DESC);
9190
        this.pe.write(oprot);
9191
        oprot.writeFieldEnd();
9192
      }
9193
      oprot.writeFieldStop();
9194
      oprot.writeStructEnd();
9195
    }
9196
 
9197
    @Override
9198
    public String toString() {
695 rajveer 9199
      StringBuilder sb = new StringBuilder("updatePaymentDetails_result(");
420 ashish 9200
      boolean first = true;
9201
 
695 rajveer 9202
      sb.append("success:");
9203
      sb.append(this.success);
9204
      first = false;
9205
      if (!first) sb.append(", ");
420 ashish 9206
      sb.append("pe:");
9207
      if (this.pe == null) {
9208
        sb.append("null");
9209
      } else {
9210
        sb.append(this.pe);
9211
      }
9212
      first = false;
9213
      sb.append(")");
9214
      return sb.toString();
9215
    }
9216
 
3430 rajveer 9217
    public void validate() throws org.apache.thrift.TException {
420 ashish 9218
      // check for required fields
9219
    }
9220
 
3430 rajveer 9221
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9222
      try {
9223
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9224
      } catch (org.apache.thrift.TException te) {
9225
        throw new java.io.IOException(te);
9226
      }
9227
    }
9228
 
9229
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9230
      try {
9231
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9232
      } catch (org.apache.thrift.TException te) {
9233
        throw new java.io.IOException(te);
9234
      }
9235
    }
9236
 
420 ashish 9237
  }
9238
 
3430 rajveer 9239
  public static class getSuccessfulPaymentsAmountRange_args implements org.apache.thrift.TBase<getSuccessfulPaymentsAmountRange_args, getSuccessfulPaymentsAmountRange_args._Fields>, java.io.Serializable, Cloneable   {
9240
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentsAmountRange_args");
1629 ankur.sing 9241
 
9242
 
9243
 
9244
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 9245
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1629 ankur.sing 9246
;
9247
 
9248
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9249
 
9250
      static {
9251
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9252
          byName.put(field.getFieldName(), field);
9253
        }
9254
      }
9255
 
9256
      /**
9257
       * Find the _Fields constant that matches fieldId, or null if its not found.
9258
       */
9259
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 9260
        switch(fieldId) {
9261
          default:
9262
            return null;
9263
        }
1629 ankur.sing 9264
      }
9265
 
9266
      /**
9267
       * Find the _Fields constant that matches fieldId, throwing an exception
9268
       * if it is not found.
9269
       */
9270
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9271
        _Fields fields = findByThriftId(fieldId);
9272
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9273
        return fields;
9274
      }
9275
 
9276
      /**
9277
       * Find the _Fields constant that matches name, or null if its not found.
9278
       */
9279
      public static _Fields findByName(String name) {
9280
        return byName.get(name);
9281
      }
9282
 
9283
      private final short _thriftId;
9284
      private final String _fieldName;
9285
 
9286
      _Fields(short thriftId, String fieldName) {
9287
        _thriftId = thriftId;
9288
        _fieldName = fieldName;
9289
      }
9290
 
9291
      public short getThriftFieldId() {
9292
        return _thriftId;
9293
      }
9294
 
9295
      public String getFieldName() {
9296
        return _fieldName;
9297
      }
9298
    }
3430 rajveer 9299
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1629 ankur.sing 9300
    static {
3430 rajveer 9301
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9302
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9303
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentsAmountRange_args.class, metaDataMap);
1629 ankur.sing 9304
    }
9305
 
1731 ankur.sing 9306
    public getSuccessfulPaymentsAmountRange_args() {
1629 ankur.sing 9307
    }
9308
 
9309
    /**
9310
     * Performs a deep copy on <i>other</i>.
9311
     */
1731 ankur.sing 9312
    public getSuccessfulPaymentsAmountRange_args(getSuccessfulPaymentsAmountRange_args other) {
1629 ankur.sing 9313
    }
9314
 
1731 ankur.sing 9315
    public getSuccessfulPaymentsAmountRange_args deepCopy() {
9316
      return new getSuccessfulPaymentsAmountRange_args(this);
1629 ankur.sing 9317
    }
9318
 
3430 rajveer 9319
    @Override
9320
    public void clear() {
1629 ankur.sing 9321
    }
9322
 
9323
    public void setFieldValue(_Fields field, Object value) {
9324
      switch (field) {
9325
      }
9326
    }
9327
 
9328
    public Object getFieldValue(_Fields field) {
9329
      switch (field) {
9330
      }
9331
      throw new IllegalStateException();
9332
    }
9333
 
3430 rajveer 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
      }
1629 ankur.sing 9339
 
9340
      switch (field) {
9341
      }
9342
      throw new IllegalStateException();
9343
    }
9344
 
9345
    @Override
9346
    public boolean equals(Object that) {
9347
      if (that == null)
9348
        return false;
1731 ankur.sing 9349
      if (that instanceof getSuccessfulPaymentsAmountRange_args)
9350
        return this.equals((getSuccessfulPaymentsAmountRange_args)that);
1629 ankur.sing 9351
      return false;
9352
    }
9353
 
1731 ankur.sing 9354
    public boolean equals(getSuccessfulPaymentsAmountRange_args that) {
1629 ankur.sing 9355
      if (that == null)
9356
        return false;
9357
 
9358
      return true;
9359
    }
9360
 
9361
    @Override
9362
    public int hashCode() {
9363
      return 0;
9364
    }
9365
 
1731 ankur.sing 9366
    public int compareTo(getSuccessfulPaymentsAmountRange_args other) {
1629 ankur.sing 9367
      if (!getClass().equals(other.getClass())) {
9368
        return getClass().getName().compareTo(other.getClass().getName());
9369
      }
9370
 
9371
      int lastComparison = 0;
1731 ankur.sing 9372
      getSuccessfulPaymentsAmountRange_args typedOther = (getSuccessfulPaymentsAmountRange_args)other;
1629 ankur.sing 9373
 
9374
      return 0;
9375
    }
9376
 
3430 rajveer 9377
    public _Fields fieldForId(int fieldId) {
9378
      return _Fields.findByThriftId(fieldId);
9379
    }
9380
 
9381
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9382
      org.apache.thrift.protocol.TField field;
1629 ankur.sing 9383
      iprot.readStructBegin();
9384
      while (true)
9385
      {
9386
        field = iprot.readFieldBegin();
3430 rajveer 9387
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1629 ankur.sing 9388
          break;
9389
        }
3430 rajveer 9390
        switch (field.id) {
9391
          default:
9392
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1629 ankur.sing 9393
        }
3430 rajveer 9394
        iprot.readFieldEnd();
1629 ankur.sing 9395
      }
9396
      iprot.readStructEnd();
9397
      validate();
9398
    }
9399
 
3430 rajveer 9400
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1629 ankur.sing 9401
      validate();
9402
 
9403
      oprot.writeStructBegin(STRUCT_DESC);
9404
      oprot.writeFieldStop();
9405
      oprot.writeStructEnd();
9406
    }
9407
 
9408
    @Override
9409
    public String toString() {
1731 ankur.sing 9410
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentsAmountRange_args(");
1629 ankur.sing 9411
      boolean first = true;
9412
 
9413
      sb.append(")");
9414
      return sb.toString();
9415
    }
9416
 
3430 rajveer 9417
    public void validate() throws org.apache.thrift.TException {
1629 ankur.sing 9418
      // check for required fields
9419
    }
9420
 
3430 rajveer 9421
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9422
      try {
9423
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9424
      } catch (org.apache.thrift.TException te) {
9425
        throw new java.io.IOException(te);
9426
      }
9427
    }
9428
 
9429
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9430
      try {
9431
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9432
      } catch (org.apache.thrift.TException te) {
9433
        throw new java.io.IOException(te);
9434
      }
9435
    }
9436
 
1629 ankur.sing 9437
  }
9438
 
3430 rajveer 9439
  public static class getSuccessfulPaymentsAmountRange_result implements org.apache.thrift.TBase<getSuccessfulPaymentsAmountRange_result, getSuccessfulPaymentsAmountRange_result._Fields>, java.io.Serializable, Cloneable   {
9440
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getSuccessfulPaymentsAmountRange_result");
1629 ankur.sing 9441
 
3430 rajveer 9442
    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 9443
 
3430 rajveer 9444
    private List<Double> success; // required
1629 ankur.sing 9445
 
9446
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 9447
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1629 ankur.sing 9448
      SUCCESS((short)0, "success");
9449
 
9450
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9451
 
9452
      static {
9453
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9454
          byName.put(field.getFieldName(), field);
9455
        }
9456
      }
9457
 
9458
      /**
9459
       * Find the _Fields constant that matches fieldId, or null if its not found.
9460
       */
9461
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 9462
        switch(fieldId) {
9463
          case 0: // SUCCESS
9464
            return SUCCESS;
9465
          default:
9466
            return null;
9467
        }
1629 ankur.sing 9468
      }
9469
 
9470
      /**
9471
       * Find the _Fields constant that matches fieldId, throwing an exception
9472
       * if it is not found.
9473
       */
9474
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9475
        _Fields fields = findByThriftId(fieldId);
9476
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9477
        return fields;
9478
      }
9479
 
9480
      /**
9481
       * Find the _Fields constant that matches name, or null if its not found.
9482
       */
9483
      public static _Fields findByName(String name) {
9484
        return byName.get(name);
9485
      }
9486
 
9487
      private final short _thriftId;
9488
      private final String _fieldName;
9489
 
9490
      _Fields(short thriftId, String fieldName) {
9491
        _thriftId = thriftId;
9492
        _fieldName = fieldName;
9493
      }
9494
 
9495
      public short getThriftFieldId() {
9496
        return _thriftId;
9497
      }
9498
 
9499
      public String getFieldName() {
9500
        return _fieldName;
9501
      }
9502
    }
9503
 
9504
    // isset id assignments
9505
 
3430 rajveer 9506
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1629 ankur.sing 9507
    static {
3430 rajveer 9508
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9509
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9510
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9511
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE))));
9512
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9513
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getSuccessfulPaymentsAmountRange_result.class, metaDataMap);
1629 ankur.sing 9514
    }
9515
 
1731 ankur.sing 9516
    public getSuccessfulPaymentsAmountRange_result() {
1629 ankur.sing 9517
    }
9518
 
1731 ankur.sing 9519
    public getSuccessfulPaymentsAmountRange_result(
9520
      List<Double> success)
1629 ankur.sing 9521
    {
9522
      this();
9523
      this.success = success;
9524
    }
9525
 
9526
    /**
9527
     * Performs a deep copy on <i>other</i>.
9528
     */
1731 ankur.sing 9529
    public getSuccessfulPaymentsAmountRange_result(getSuccessfulPaymentsAmountRange_result other) {
9530
      if (other.isSetSuccess()) {
9531
        List<Double> __this__success = new ArrayList<Double>();
9532
        for (Double other_element : other.success) {
9533
          __this__success.add(other_element);
1629 ankur.sing 9534
        }
1731 ankur.sing 9535
        this.success = __this__success;
1629 ankur.sing 9536
      }
9537
    }
9538
 
1731 ankur.sing 9539
    public getSuccessfulPaymentsAmountRange_result deepCopy() {
9540
      return new getSuccessfulPaymentsAmountRange_result(this);
1629 ankur.sing 9541
    }
9542
 
3430 rajveer 9543
    @Override
9544
    public void clear() {
9545
      this.success = null;
1629 ankur.sing 9546
    }
9547
 
1731 ankur.sing 9548
    public int getSuccessSize() {
9549
      return (this.success == null) ? 0 : this.success.size();
1629 ankur.sing 9550
    }
9551
 
1731 ankur.sing 9552
    public java.util.Iterator<Double> getSuccessIterator() {
9553
      return (this.success == null) ? null : this.success.iterator();
1629 ankur.sing 9554
    }
9555
 
1731 ankur.sing 9556
    public void addToSuccess(double elem) {
9557
      if (this.success == null) {
9558
        this.success = new ArrayList<Double>();
1629 ankur.sing 9559
      }
1731 ankur.sing 9560
      this.success.add(elem);
1629 ankur.sing 9561
    }
9562
 
1731 ankur.sing 9563
    public List<Double> getSuccess() {
1629 ankur.sing 9564
      return this.success;
9565
    }
9566
 
3430 rajveer 9567
    public void setSuccess(List<Double> success) {
1629 ankur.sing 9568
      this.success = success;
9569
    }
9570
 
9571
    public void unsetSuccess() {
1731 ankur.sing 9572
      this.success = null;
1629 ankur.sing 9573
    }
9574
 
3430 rajveer 9575
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
1629 ankur.sing 9576
    public boolean isSetSuccess() {
1731 ankur.sing 9577
      return this.success != null;
1629 ankur.sing 9578
    }
9579
 
9580
    public void setSuccessIsSet(boolean value) {
1731 ankur.sing 9581
      if (!value) {
9582
        this.success = null;
9583
      }
1629 ankur.sing 9584
    }
9585
 
9586
    public void setFieldValue(_Fields field, Object value) {
9587
      switch (field) {
9588
      case SUCCESS:
9589
        if (value == null) {
9590
          unsetSuccess();
9591
        } else {
1731 ankur.sing 9592
          setSuccess((List<Double>)value);
1629 ankur.sing 9593
        }
9594
        break;
9595
 
9596
      }
9597
    }
9598
 
9599
    public Object getFieldValue(_Fields field) {
9600
      switch (field) {
9601
      case SUCCESS:
1731 ankur.sing 9602
        return getSuccess();
1629 ankur.sing 9603
 
9604
      }
9605
      throw new IllegalStateException();
9606
    }
9607
 
3430 rajveer 9608
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9609
    public boolean isSet(_Fields field) {
9610
      if (field == null) {
9611
        throw new IllegalArgumentException();
9612
      }
1629 ankur.sing 9613
 
9614
      switch (field) {
9615
      case SUCCESS:
9616
        return isSetSuccess();
9617
      }
9618
      throw new IllegalStateException();
9619
    }
9620
 
9621
    @Override
9622
    public boolean equals(Object that) {
9623
      if (that == null)
9624
        return false;
1731 ankur.sing 9625
      if (that instanceof getSuccessfulPaymentsAmountRange_result)
9626
        return this.equals((getSuccessfulPaymentsAmountRange_result)that);
1629 ankur.sing 9627
      return false;
9628
    }
9629
 
1731 ankur.sing 9630
    public boolean equals(getSuccessfulPaymentsAmountRange_result that) {
1629 ankur.sing 9631
      if (that == null)
9632
        return false;
9633
 
1731 ankur.sing 9634
      boolean this_present_success = true && this.isSetSuccess();
9635
      boolean that_present_success = true && that.isSetSuccess();
1629 ankur.sing 9636
      if (this_present_success || that_present_success) {
9637
        if (!(this_present_success && that_present_success))
9638
          return false;
1731 ankur.sing 9639
        if (!this.success.equals(that.success))
1629 ankur.sing 9640
          return false;
9641
      }
9642
 
9643
      return true;
9644
    }
9645
 
9646
    @Override
9647
    public int hashCode() {
9648
      return 0;
9649
    }
9650
 
1731 ankur.sing 9651
    public int compareTo(getSuccessfulPaymentsAmountRange_result other) {
1629 ankur.sing 9652
      if (!getClass().equals(other.getClass())) {
9653
        return getClass().getName().compareTo(other.getClass().getName());
9654
      }
9655
 
9656
      int lastComparison = 0;
1731 ankur.sing 9657
      getSuccessfulPaymentsAmountRange_result typedOther = (getSuccessfulPaymentsAmountRange_result)other;
1629 ankur.sing 9658
 
3430 rajveer 9659
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
1629 ankur.sing 9660
      if (lastComparison != 0) {
9661
        return lastComparison;
9662
      }
3430 rajveer 9663
      if (isSetSuccess()) {
9664
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9665
        if (lastComparison != 0) {
9666
          return lastComparison;
9667
        }
1629 ankur.sing 9668
      }
9669
      return 0;
9670
    }
9671
 
3430 rajveer 9672
    public _Fields fieldForId(int fieldId) {
9673
      return _Fields.findByThriftId(fieldId);
9674
    }
9675
 
9676
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9677
      org.apache.thrift.protocol.TField field;
1629 ankur.sing 9678
      iprot.readStructBegin();
9679
      while (true)
9680
      {
9681
        field = iprot.readFieldBegin();
3430 rajveer 9682
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1629 ankur.sing 9683
          break;
9684
        }
3430 rajveer 9685
        switch (field.id) {
9686
          case 0: // SUCCESS
9687
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9688
              {
4141 chandransh 9689
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
9690
                this.success = new ArrayList<Double>(_list32.size);
9691
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
1731 ankur.sing 9692
                {
4141 chandransh 9693
                  double _elem34; // required
9694
                  _elem34 = iprot.readDouble();
9695
                  this.success.add(_elem34);
1731 ankur.sing 9696
                }
3430 rajveer 9697
                iprot.readListEnd();
1629 ankur.sing 9698
              }
3430 rajveer 9699
            } else { 
9700
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9701
            }
9702
            break;
9703
          default:
9704
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1629 ankur.sing 9705
        }
3430 rajveer 9706
        iprot.readFieldEnd();
1629 ankur.sing 9707
      }
9708
      iprot.readStructEnd();
9709
      validate();
9710
    }
9711
 
3430 rajveer 9712
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1629 ankur.sing 9713
      oprot.writeStructBegin(STRUCT_DESC);
9714
 
9715
      if (this.isSetSuccess()) {
9716
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
1731 ankur.sing 9717
        {
3430 rajveer 9718
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.DOUBLE, this.success.size()));
4141 chandransh 9719
          for (double _iter35 : this.success)
1731 ankur.sing 9720
          {
4141 chandransh 9721
            oprot.writeDouble(_iter35);
1731 ankur.sing 9722
          }
9723
          oprot.writeListEnd();
9724
        }
1629 ankur.sing 9725
        oprot.writeFieldEnd();
9726
      }
9727
      oprot.writeFieldStop();
9728
      oprot.writeStructEnd();
9729
    }
9730
 
9731
    @Override
9732
    public String toString() {
1731 ankur.sing 9733
      StringBuilder sb = new StringBuilder("getSuccessfulPaymentsAmountRange_result(");
1629 ankur.sing 9734
      boolean first = true;
9735
 
9736
      sb.append("success:");
1731 ankur.sing 9737
      if (this.success == null) {
9738
        sb.append("null");
9739
      } else {
9740
        sb.append(this.success);
9741
      }
1629 ankur.sing 9742
      first = false;
9743
      sb.append(")");
9744
      return sb.toString();
9745
    }
9746
 
3430 rajveer 9747
    public void validate() throws org.apache.thrift.TException {
1629 ankur.sing 9748
      // check for required fields
9749
    }
9750
 
3430 rajveer 9751
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9752
      try {
9753
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9754
      } catch (org.apache.thrift.TException te) {
9755
        throw new java.io.IOException(te);
9756
      }
9757
    }
9758
 
9759
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9760
      try {
9761
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9762
      } catch (org.apache.thrift.TException te) {
9763
        throw new java.io.IOException(te);
9764
      }
9765
    }
9766
 
1629 ankur.sing 9767
  }
9768
 
3430 rajveer 9769
  public static class initializeHdfcPayment_args implements org.apache.thrift.TBase<initializeHdfcPayment_args, initializeHdfcPayment_args._Fields>, java.io.Serializable, Cloneable   {
9770
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcPayment_args");
2462 chandransh 9771
 
3430 rajveer 9772
    private static final org.apache.thrift.protocol.TField MERCHANT_PAYMENT_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantPaymentId", org.apache.thrift.protocol.TType.I64, (short)1);
2462 chandransh 9773
 
3430 rajveer 9774
    private long merchantPaymentId; // required
2462 chandransh 9775
 
9776
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 9777
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 9778
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId");
9779
 
9780
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9781
 
9782
      static {
9783
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9784
          byName.put(field.getFieldName(), field);
9785
        }
9786
      }
9787
 
9788
      /**
9789
       * Find the _Fields constant that matches fieldId, or null if its not found.
9790
       */
9791
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 9792
        switch(fieldId) {
9793
          case 1: // MERCHANT_PAYMENT_ID
9794
            return MERCHANT_PAYMENT_ID;
9795
          default:
9796
            return null;
9797
        }
2462 chandransh 9798
      }
9799
 
9800
      /**
9801
       * Find the _Fields constant that matches fieldId, throwing an exception
9802
       * if it is not found.
9803
       */
9804
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9805
        _Fields fields = findByThriftId(fieldId);
9806
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9807
        return fields;
9808
      }
9809
 
9810
      /**
9811
       * Find the _Fields constant that matches name, or null if its not found.
9812
       */
9813
      public static _Fields findByName(String name) {
9814
        return byName.get(name);
9815
      }
9816
 
9817
      private final short _thriftId;
9818
      private final String _fieldName;
9819
 
9820
      _Fields(short thriftId, String fieldName) {
9821
        _thriftId = thriftId;
9822
        _fieldName = fieldName;
9823
      }
9824
 
9825
      public short getThriftFieldId() {
9826
        return _thriftId;
9827
      }
9828
 
9829
      public String getFieldName() {
9830
        return _fieldName;
9831
      }
9832
    }
9833
 
9834
    // isset id assignments
9835
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
9836
    private BitSet __isset_bit_vector = new BitSet(1);
9837
 
3430 rajveer 9838
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 9839
    static {
3430 rajveer 9840
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9841
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9842
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
9843
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9844
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcPayment_args.class, metaDataMap);
2462 chandransh 9845
    }
9846
 
3010 chandransh 9847
    public initializeHdfcPayment_args() {
2462 chandransh 9848
    }
9849
 
3010 chandransh 9850
    public initializeHdfcPayment_args(
2462 chandransh 9851
      long merchantPaymentId)
9852
    {
9853
      this();
9854
      this.merchantPaymentId = merchantPaymentId;
9855
      setMerchantPaymentIdIsSet(true);
9856
    }
9857
 
9858
    /**
9859
     * Performs a deep copy on <i>other</i>.
9860
     */
3010 chandransh 9861
    public initializeHdfcPayment_args(initializeHdfcPayment_args other) {
2462 chandransh 9862
      __isset_bit_vector.clear();
9863
      __isset_bit_vector.or(other.__isset_bit_vector);
9864
      this.merchantPaymentId = other.merchantPaymentId;
9865
    }
9866
 
3010 chandransh 9867
    public initializeHdfcPayment_args deepCopy() {
9868
      return new initializeHdfcPayment_args(this);
2462 chandransh 9869
    }
9870
 
3430 rajveer 9871
    @Override
9872
    public void clear() {
9873
      setMerchantPaymentIdIsSet(false);
9874
      this.merchantPaymentId = 0;
2462 chandransh 9875
    }
9876
 
9877
    public long getMerchantPaymentId() {
9878
      return this.merchantPaymentId;
9879
    }
9880
 
3430 rajveer 9881
    public void setMerchantPaymentId(long merchantPaymentId) {
2462 chandransh 9882
      this.merchantPaymentId = merchantPaymentId;
9883
      setMerchantPaymentIdIsSet(true);
9884
    }
9885
 
9886
    public void unsetMerchantPaymentId() {
9887
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
9888
    }
9889
 
3430 rajveer 9890
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
2462 chandransh 9891
    public boolean isSetMerchantPaymentId() {
9892
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
9893
    }
9894
 
9895
    public void setMerchantPaymentIdIsSet(boolean value) {
9896
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
9897
    }
9898
 
9899
    public void setFieldValue(_Fields field, Object value) {
9900
      switch (field) {
9901
      case MERCHANT_PAYMENT_ID:
9902
        if (value == null) {
9903
          unsetMerchantPaymentId();
9904
        } else {
9905
          setMerchantPaymentId((Long)value);
9906
        }
9907
        break;
9908
 
9909
      }
9910
    }
9911
 
9912
    public Object getFieldValue(_Fields field) {
9913
      switch (field) {
9914
      case MERCHANT_PAYMENT_ID:
3430 rajveer 9915
        return Long.valueOf(getMerchantPaymentId());
2462 chandransh 9916
 
9917
      }
9918
      throw new IllegalStateException();
9919
    }
9920
 
3430 rajveer 9921
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9922
    public boolean isSet(_Fields field) {
9923
      if (field == null) {
9924
        throw new IllegalArgumentException();
9925
      }
2462 chandransh 9926
 
9927
      switch (field) {
9928
      case MERCHANT_PAYMENT_ID:
9929
        return isSetMerchantPaymentId();
9930
      }
9931
      throw new IllegalStateException();
9932
    }
9933
 
9934
    @Override
9935
    public boolean equals(Object that) {
9936
      if (that == null)
9937
        return false;
3010 chandransh 9938
      if (that instanceof initializeHdfcPayment_args)
9939
        return this.equals((initializeHdfcPayment_args)that);
2462 chandransh 9940
      return false;
9941
    }
9942
 
3010 chandransh 9943
    public boolean equals(initializeHdfcPayment_args that) {
2462 chandransh 9944
      if (that == null)
9945
        return false;
9946
 
9947
      boolean this_present_merchantPaymentId = true;
9948
      boolean that_present_merchantPaymentId = true;
9949
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
9950
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
9951
          return false;
9952
        if (this.merchantPaymentId != that.merchantPaymentId)
9953
          return false;
9954
      }
9955
 
9956
      return true;
9957
    }
9958
 
9959
    @Override
9960
    public int hashCode() {
9961
      return 0;
9962
    }
9963
 
3010 chandransh 9964
    public int compareTo(initializeHdfcPayment_args other) {
2462 chandransh 9965
      if (!getClass().equals(other.getClass())) {
9966
        return getClass().getName().compareTo(other.getClass().getName());
9967
      }
9968
 
9969
      int lastComparison = 0;
3010 chandransh 9970
      initializeHdfcPayment_args typedOther = (initializeHdfcPayment_args)other;
2462 chandransh 9971
 
3430 rajveer 9972
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
2462 chandransh 9973
      if (lastComparison != 0) {
9974
        return lastComparison;
9975
      }
3430 rajveer 9976
      if (isSetMerchantPaymentId()) {
9977
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
9978
        if (lastComparison != 0) {
9979
          return lastComparison;
9980
        }
2462 chandransh 9981
      }
9982
      return 0;
9983
    }
9984
 
3430 rajveer 9985
    public _Fields fieldForId(int fieldId) {
9986
      return _Fields.findByThriftId(fieldId);
9987
    }
9988
 
9989
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9990
      org.apache.thrift.protocol.TField field;
2462 chandransh 9991
      iprot.readStructBegin();
9992
      while (true)
9993
      {
9994
        field = iprot.readFieldBegin();
3430 rajveer 9995
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 9996
          break;
9997
        }
3430 rajveer 9998
        switch (field.id) {
9999
          case 1: // MERCHANT_PAYMENT_ID
10000
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10001
              this.merchantPaymentId = iprot.readI64();
10002
              setMerchantPaymentIdIsSet(true);
10003
            } else { 
10004
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10005
            }
10006
            break;
10007
          default:
10008
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 10009
        }
3430 rajveer 10010
        iprot.readFieldEnd();
2462 chandransh 10011
      }
10012
      iprot.readStructEnd();
10013
      validate();
10014
    }
10015
 
3430 rajveer 10016
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 10017
      validate();
10018
 
10019
      oprot.writeStructBegin(STRUCT_DESC);
10020
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
10021
      oprot.writeI64(this.merchantPaymentId);
10022
      oprot.writeFieldEnd();
10023
      oprot.writeFieldStop();
10024
      oprot.writeStructEnd();
10025
    }
10026
 
10027
    @Override
10028
    public String toString() {
3010 chandransh 10029
      StringBuilder sb = new StringBuilder("initializeHdfcPayment_args(");
2462 chandransh 10030
      boolean first = true;
10031
 
10032
      sb.append("merchantPaymentId:");
10033
      sb.append(this.merchantPaymentId);
10034
      first = false;
10035
      sb.append(")");
10036
      return sb.toString();
10037
    }
10038
 
3430 rajveer 10039
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 10040
      // check for required fields
10041
    }
10042
 
3430 rajveer 10043
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10044
      try {
10045
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10046
      } catch (org.apache.thrift.TException te) {
10047
        throw new java.io.IOException(te);
10048
      }
10049
    }
10050
 
10051
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10052
      try {
10053
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10054
      } catch (org.apache.thrift.TException te) {
10055
        throw new java.io.IOException(te);
10056
      }
10057
    }
10058
 
2462 chandransh 10059
  }
10060
 
3430 rajveer 10061
  public static class initializeHdfcPayment_result implements org.apache.thrift.TBase<initializeHdfcPayment_result, initializeHdfcPayment_result._Fields>, java.io.Serializable, Cloneable   {
10062
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcPayment_result");
2462 chandransh 10063
 
3430 rajveer 10064
    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);
10065
    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 10066
 
3430 rajveer 10067
    private String success; // required
10068
    private PaymentException pe; // required
2462 chandransh 10069
 
10070
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 10071
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 10072
      SUCCESS((short)0, "success"),
10073
      PE((short)1, "pe");
10074
 
10075
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10076
 
10077
      static {
10078
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10079
          byName.put(field.getFieldName(), field);
10080
        }
10081
      }
10082
 
10083
      /**
10084
       * Find the _Fields constant that matches fieldId, or null if its not found.
10085
       */
10086
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 10087
        switch(fieldId) {
10088
          case 0: // SUCCESS
10089
            return SUCCESS;
10090
          case 1: // PE
10091
            return PE;
10092
          default:
10093
            return null;
10094
        }
2462 chandransh 10095
      }
10096
 
10097
      /**
10098
       * Find the _Fields constant that matches fieldId, throwing an exception
10099
       * if it is not found.
10100
       */
10101
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10102
        _Fields fields = findByThriftId(fieldId);
10103
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10104
        return fields;
10105
      }
10106
 
10107
      /**
10108
       * Find the _Fields constant that matches name, or null if its not found.
10109
       */
10110
      public static _Fields findByName(String name) {
10111
        return byName.get(name);
10112
      }
10113
 
10114
      private final short _thriftId;
10115
      private final String _fieldName;
10116
 
10117
      _Fields(short thriftId, String fieldName) {
10118
        _thriftId = thriftId;
10119
        _fieldName = fieldName;
10120
      }
10121
 
10122
      public short getThriftFieldId() {
10123
        return _thriftId;
10124
      }
10125
 
10126
      public String getFieldName() {
10127
        return _fieldName;
10128
      }
10129
    }
10130
 
10131
    // isset id assignments
10132
 
3430 rajveer 10133
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 10134
    static {
3430 rajveer 10135
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10136
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10137
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10138
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10139
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10140
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10141
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcPayment_result.class, metaDataMap);
2462 chandransh 10142
    }
10143
 
3010 chandransh 10144
    public initializeHdfcPayment_result() {
2462 chandransh 10145
    }
10146
 
3010 chandransh 10147
    public initializeHdfcPayment_result(
10148
      String success,
2462 chandransh 10149
      PaymentException pe)
10150
    {
10151
      this();
10152
      this.success = success;
10153
      this.pe = pe;
10154
    }
10155
 
10156
    /**
10157
     * Performs a deep copy on <i>other</i>.
10158
     */
3010 chandransh 10159
    public initializeHdfcPayment_result(initializeHdfcPayment_result other) {
2462 chandransh 10160
      if (other.isSetSuccess()) {
3010 chandransh 10161
        this.success = other.success;
2462 chandransh 10162
      }
10163
      if (other.isSetPe()) {
10164
        this.pe = new PaymentException(other.pe);
10165
      }
10166
    }
10167
 
3010 chandransh 10168
    public initializeHdfcPayment_result deepCopy() {
10169
      return new initializeHdfcPayment_result(this);
2462 chandransh 10170
    }
10171
 
3430 rajveer 10172
    @Override
10173
    public void clear() {
10174
      this.success = null;
10175
      this.pe = null;
2462 chandransh 10176
    }
10177
 
3010 chandransh 10178
    public String getSuccess() {
2462 chandransh 10179
      return this.success;
10180
    }
10181
 
3430 rajveer 10182
    public void setSuccess(String success) {
2462 chandransh 10183
      this.success = success;
10184
    }
10185
 
10186
    public void unsetSuccess() {
10187
      this.success = null;
10188
    }
10189
 
3430 rajveer 10190
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2462 chandransh 10191
    public boolean isSetSuccess() {
10192
      return this.success != null;
10193
    }
10194
 
10195
    public void setSuccessIsSet(boolean value) {
10196
      if (!value) {
10197
        this.success = null;
10198
      }
10199
    }
10200
 
10201
    public PaymentException getPe() {
10202
      return this.pe;
10203
    }
10204
 
3430 rajveer 10205
    public void setPe(PaymentException pe) {
2462 chandransh 10206
      this.pe = pe;
10207
    }
10208
 
10209
    public void unsetPe() {
10210
      this.pe = null;
10211
    }
10212
 
3430 rajveer 10213
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2462 chandransh 10214
    public boolean isSetPe() {
10215
      return this.pe != null;
10216
    }
10217
 
10218
    public void setPeIsSet(boolean value) {
10219
      if (!value) {
10220
        this.pe = null;
10221
      }
10222
    }
10223
 
10224
    public void setFieldValue(_Fields field, Object value) {
10225
      switch (field) {
10226
      case SUCCESS:
10227
        if (value == null) {
10228
          unsetSuccess();
10229
        } else {
3010 chandransh 10230
          setSuccess((String)value);
2462 chandransh 10231
        }
10232
        break;
10233
 
10234
      case PE:
10235
        if (value == null) {
10236
          unsetPe();
10237
        } else {
10238
          setPe((PaymentException)value);
10239
        }
10240
        break;
10241
 
10242
      }
10243
    }
10244
 
10245
    public Object getFieldValue(_Fields field) {
10246
      switch (field) {
10247
      case SUCCESS:
10248
        return getSuccess();
10249
 
10250
      case PE:
10251
        return getPe();
10252
 
10253
      }
10254
      throw new IllegalStateException();
10255
    }
10256
 
3430 rajveer 10257
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10258
    public boolean isSet(_Fields field) {
10259
      if (field == null) {
10260
        throw new IllegalArgumentException();
10261
      }
2462 chandransh 10262
 
10263
      switch (field) {
10264
      case SUCCESS:
10265
        return isSetSuccess();
10266
      case PE:
10267
        return isSetPe();
10268
      }
10269
      throw new IllegalStateException();
10270
    }
10271
 
10272
    @Override
10273
    public boolean equals(Object that) {
10274
      if (that == null)
10275
        return false;
3010 chandransh 10276
      if (that instanceof initializeHdfcPayment_result)
10277
        return this.equals((initializeHdfcPayment_result)that);
2462 chandransh 10278
      return false;
10279
    }
10280
 
3010 chandransh 10281
    public boolean equals(initializeHdfcPayment_result that) {
2462 chandransh 10282
      if (that == null)
10283
        return false;
10284
 
10285
      boolean this_present_success = true && this.isSetSuccess();
10286
      boolean that_present_success = true && that.isSetSuccess();
10287
      if (this_present_success || that_present_success) {
10288
        if (!(this_present_success && that_present_success))
10289
          return false;
10290
        if (!this.success.equals(that.success))
10291
          return false;
10292
      }
10293
 
10294
      boolean this_present_pe = true && this.isSetPe();
10295
      boolean that_present_pe = true && that.isSetPe();
10296
      if (this_present_pe || that_present_pe) {
10297
        if (!(this_present_pe && that_present_pe))
10298
          return false;
10299
        if (!this.pe.equals(that.pe))
10300
          return false;
10301
      }
10302
 
10303
      return true;
10304
    }
10305
 
10306
    @Override
10307
    public int hashCode() {
10308
      return 0;
10309
    }
10310
 
3010 chandransh 10311
    public int compareTo(initializeHdfcPayment_result other) {
10312
      if (!getClass().equals(other.getClass())) {
10313
        return getClass().getName().compareTo(other.getClass().getName());
10314
      }
10315
 
10316
      int lastComparison = 0;
10317
      initializeHdfcPayment_result typedOther = (initializeHdfcPayment_result)other;
10318
 
3430 rajveer 10319
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3010 chandransh 10320
      if (lastComparison != 0) {
10321
        return lastComparison;
10322
      }
3430 rajveer 10323
      if (isSetSuccess()) {
10324
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10325
        if (lastComparison != 0) {
10326
          return lastComparison;
10327
        }
3010 chandransh 10328
      }
3430 rajveer 10329
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
3010 chandransh 10330
      if (lastComparison != 0) {
10331
        return lastComparison;
10332
      }
3430 rajveer 10333
      if (isSetPe()) {
10334
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
10335
        if (lastComparison != 0) {
10336
          return lastComparison;
10337
        }
3010 chandransh 10338
      }
10339
      return 0;
10340
    }
10341
 
3430 rajveer 10342
    public _Fields fieldForId(int fieldId) {
10343
      return _Fields.findByThriftId(fieldId);
10344
    }
10345
 
10346
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10347
      org.apache.thrift.protocol.TField field;
2462 chandransh 10348
      iprot.readStructBegin();
10349
      while (true)
10350
      {
10351
        field = iprot.readFieldBegin();
3430 rajveer 10352
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 10353
          break;
10354
        }
3430 rajveer 10355
        switch (field.id) {
10356
          case 0: // SUCCESS
10357
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
10358
              this.success = iprot.readString();
10359
            } else { 
10360
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10361
            }
10362
            break;
10363
          case 1: // PE
10364
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10365
              this.pe = new PaymentException();
10366
              this.pe.read(iprot);
10367
            } else { 
10368
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10369
            }
10370
            break;
10371
          default:
10372
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 10373
        }
3430 rajveer 10374
        iprot.readFieldEnd();
2462 chandransh 10375
      }
10376
      iprot.readStructEnd();
10377
      validate();
10378
    }
10379
 
3430 rajveer 10380
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 10381
      oprot.writeStructBegin(STRUCT_DESC);
10382
 
10383
      if (this.isSetSuccess()) {
10384
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 10385
        oprot.writeString(this.success);
2462 chandransh 10386
        oprot.writeFieldEnd();
10387
      } else if (this.isSetPe()) {
10388
        oprot.writeFieldBegin(PE_FIELD_DESC);
10389
        this.pe.write(oprot);
10390
        oprot.writeFieldEnd();
10391
      }
10392
      oprot.writeFieldStop();
10393
      oprot.writeStructEnd();
10394
    }
10395
 
10396
    @Override
10397
    public String toString() {
3010 chandransh 10398
      StringBuilder sb = new StringBuilder("initializeHdfcPayment_result(");
2462 chandransh 10399
      boolean first = true;
10400
 
10401
      sb.append("success:");
10402
      if (this.success == null) {
10403
        sb.append("null");
10404
      } else {
10405
        sb.append(this.success);
10406
      }
10407
      first = false;
10408
      if (!first) sb.append(", ");
10409
      sb.append("pe:");
10410
      if (this.pe == null) {
10411
        sb.append("null");
10412
      } else {
10413
        sb.append(this.pe);
10414
      }
10415
      first = false;
10416
      sb.append(")");
10417
      return sb.toString();
10418
    }
10419
 
3430 rajveer 10420
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 10421
      // check for required fields
10422
    }
10423
 
3430 rajveer 10424
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10425
      try {
10426
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10427
      } catch (org.apache.thrift.TException te) {
10428
        throw new java.io.IOException(te);
10429
      }
10430
    }
10431
 
10432
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10433
      try {
10434
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10435
      } catch (org.apache.thrift.TException te) {
10436
        throw new java.io.IOException(te);
10437
      }
10438
    }
10439
 
2462 chandransh 10440
  }
10441
 
3616 chandransh 10442
  public static class initializeHdfcEmiPayment_args implements org.apache.thrift.TBase<initializeHdfcEmiPayment_args, initializeHdfcEmiPayment_args._Fields>, java.io.Serializable, Cloneable   {
10443
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcEmiPayment_args");
10444
 
10445
    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);
10446
 
10447
    private long merchantPaymentId; // required
10448
 
10449
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10450
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10451
      MERCHANT_PAYMENT_ID((short)1, "merchantPaymentId");
10452
 
10453
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10454
 
10455
      static {
10456
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10457
          byName.put(field.getFieldName(), field);
10458
        }
10459
      }
10460
 
10461
      /**
10462
       * Find the _Fields constant that matches fieldId, or null if its not found.
10463
       */
10464
      public static _Fields findByThriftId(int fieldId) {
10465
        switch(fieldId) {
10466
          case 1: // MERCHANT_PAYMENT_ID
10467
            return MERCHANT_PAYMENT_ID;
10468
          default:
10469
            return null;
10470
        }
10471
      }
10472
 
10473
      /**
10474
       * Find the _Fields constant that matches fieldId, throwing an exception
10475
       * if it is not found.
10476
       */
10477
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10478
        _Fields fields = findByThriftId(fieldId);
10479
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10480
        return fields;
10481
      }
10482
 
10483
      /**
10484
       * Find the _Fields constant that matches name, or null if its not found.
10485
       */
10486
      public static _Fields findByName(String name) {
10487
        return byName.get(name);
10488
      }
10489
 
10490
      private final short _thriftId;
10491
      private final String _fieldName;
10492
 
10493
      _Fields(short thriftId, String fieldName) {
10494
        _thriftId = thriftId;
10495
        _fieldName = fieldName;
10496
      }
10497
 
10498
      public short getThriftFieldId() {
10499
        return _thriftId;
10500
      }
10501
 
10502
      public String getFieldName() {
10503
        return _fieldName;
10504
      }
10505
    }
10506
 
10507
    // isset id assignments
10508
    private static final int __MERCHANTPAYMENTID_ISSET_ID = 0;
10509
    private BitSet __isset_bit_vector = new BitSet(1);
10510
 
10511
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10512
    static {
10513
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10514
      tmpMap.put(_Fields.MERCHANT_PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantPaymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10515
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10516
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10517
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcEmiPayment_args.class, metaDataMap);
10518
    }
10519
 
10520
    public initializeHdfcEmiPayment_args() {
10521
    }
10522
 
10523
    public initializeHdfcEmiPayment_args(
10524
      long merchantPaymentId)
10525
    {
10526
      this();
10527
      this.merchantPaymentId = merchantPaymentId;
10528
      setMerchantPaymentIdIsSet(true);
10529
    }
10530
 
10531
    /**
10532
     * Performs a deep copy on <i>other</i>.
10533
     */
10534
    public initializeHdfcEmiPayment_args(initializeHdfcEmiPayment_args other) {
10535
      __isset_bit_vector.clear();
10536
      __isset_bit_vector.or(other.__isset_bit_vector);
10537
      this.merchantPaymentId = other.merchantPaymentId;
10538
    }
10539
 
10540
    public initializeHdfcEmiPayment_args deepCopy() {
10541
      return new initializeHdfcEmiPayment_args(this);
10542
    }
10543
 
10544
    @Override
10545
    public void clear() {
10546
      setMerchantPaymentIdIsSet(false);
10547
      this.merchantPaymentId = 0;
10548
    }
10549
 
10550
    public long getMerchantPaymentId() {
10551
      return this.merchantPaymentId;
10552
    }
10553
 
10554
    public void setMerchantPaymentId(long merchantPaymentId) {
10555
      this.merchantPaymentId = merchantPaymentId;
10556
      setMerchantPaymentIdIsSet(true);
10557
    }
10558
 
10559
    public void unsetMerchantPaymentId() {
10560
      __isset_bit_vector.clear(__MERCHANTPAYMENTID_ISSET_ID);
10561
    }
10562
 
10563
    /** Returns true if field merchantPaymentId is set (has been assigned a value) and false otherwise */
10564
    public boolean isSetMerchantPaymentId() {
10565
      return __isset_bit_vector.get(__MERCHANTPAYMENTID_ISSET_ID);
10566
    }
10567
 
10568
    public void setMerchantPaymentIdIsSet(boolean value) {
10569
      __isset_bit_vector.set(__MERCHANTPAYMENTID_ISSET_ID, value);
10570
    }
10571
 
10572
    public void setFieldValue(_Fields field, Object value) {
10573
      switch (field) {
10574
      case MERCHANT_PAYMENT_ID:
10575
        if (value == null) {
10576
          unsetMerchantPaymentId();
10577
        } else {
10578
          setMerchantPaymentId((Long)value);
10579
        }
10580
        break;
10581
 
10582
      }
10583
    }
10584
 
10585
    public Object getFieldValue(_Fields field) {
10586
      switch (field) {
10587
      case MERCHANT_PAYMENT_ID:
10588
        return Long.valueOf(getMerchantPaymentId());
10589
 
10590
      }
10591
      throw new IllegalStateException();
10592
    }
10593
 
10594
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10595
    public boolean isSet(_Fields field) {
10596
      if (field == null) {
10597
        throw new IllegalArgumentException();
10598
      }
10599
 
10600
      switch (field) {
10601
      case MERCHANT_PAYMENT_ID:
10602
        return isSetMerchantPaymentId();
10603
      }
10604
      throw new IllegalStateException();
10605
    }
10606
 
10607
    @Override
10608
    public boolean equals(Object that) {
10609
      if (that == null)
10610
        return false;
10611
      if (that instanceof initializeHdfcEmiPayment_args)
10612
        return this.equals((initializeHdfcEmiPayment_args)that);
10613
      return false;
10614
    }
10615
 
10616
    public boolean equals(initializeHdfcEmiPayment_args that) {
10617
      if (that == null)
10618
        return false;
10619
 
10620
      boolean this_present_merchantPaymentId = true;
10621
      boolean that_present_merchantPaymentId = true;
10622
      if (this_present_merchantPaymentId || that_present_merchantPaymentId) {
10623
        if (!(this_present_merchantPaymentId && that_present_merchantPaymentId))
10624
          return false;
10625
        if (this.merchantPaymentId != that.merchantPaymentId)
10626
          return false;
10627
      }
10628
 
10629
      return true;
10630
    }
10631
 
10632
    @Override
10633
    public int hashCode() {
10634
      return 0;
10635
    }
10636
 
10637
    public int compareTo(initializeHdfcEmiPayment_args other) {
10638
      if (!getClass().equals(other.getClass())) {
10639
        return getClass().getName().compareTo(other.getClass().getName());
10640
      }
10641
 
10642
      int lastComparison = 0;
10643
      initializeHdfcEmiPayment_args typedOther = (initializeHdfcEmiPayment_args)other;
10644
 
10645
      lastComparison = Boolean.valueOf(isSetMerchantPaymentId()).compareTo(typedOther.isSetMerchantPaymentId());
10646
      if (lastComparison != 0) {
10647
        return lastComparison;
10648
      }
10649
      if (isSetMerchantPaymentId()) {
10650
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantPaymentId, typedOther.merchantPaymentId);
10651
        if (lastComparison != 0) {
10652
          return lastComparison;
10653
        }
10654
      }
10655
      return 0;
10656
    }
10657
 
10658
    public _Fields fieldForId(int fieldId) {
10659
      return _Fields.findByThriftId(fieldId);
10660
    }
10661
 
10662
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10663
      org.apache.thrift.protocol.TField field;
10664
      iprot.readStructBegin();
10665
      while (true)
10666
      {
10667
        field = iprot.readFieldBegin();
10668
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10669
          break;
10670
        }
10671
        switch (field.id) {
10672
          case 1: // MERCHANT_PAYMENT_ID
10673
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10674
              this.merchantPaymentId = iprot.readI64();
10675
              setMerchantPaymentIdIsSet(true);
10676
            } else { 
10677
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10678
            }
10679
            break;
10680
          default:
10681
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10682
        }
10683
        iprot.readFieldEnd();
10684
      }
10685
      iprot.readStructEnd();
10686
      validate();
10687
    }
10688
 
10689
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10690
      validate();
10691
 
10692
      oprot.writeStructBegin(STRUCT_DESC);
10693
      oprot.writeFieldBegin(MERCHANT_PAYMENT_ID_FIELD_DESC);
10694
      oprot.writeI64(this.merchantPaymentId);
10695
      oprot.writeFieldEnd();
10696
      oprot.writeFieldStop();
10697
      oprot.writeStructEnd();
10698
    }
10699
 
10700
    @Override
10701
    public String toString() {
10702
      StringBuilder sb = new StringBuilder("initializeHdfcEmiPayment_args(");
10703
      boolean first = true;
10704
 
10705
      sb.append("merchantPaymentId:");
10706
      sb.append(this.merchantPaymentId);
10707
      first = false;
10708
      sb.append(")");
10709
      return sb.toString();
10710
    }
10711
 
10712
    public void validate() throws org.apache.thrift.TException {
10713
      // check for required fields
10714
    }
10715
 
10716
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10717
      try {
10718
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10719
      } catch (org.apache.thrift.TException te) {
10720
        throw new java.io.IOException(te);
10721
      }
10722
    }
10723
 
10724
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10725
      try {
10726
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10727
      } catch (org.apache.thrift.TException te) {
10728
        throw new java.io.IOException(te);
10729
      }
10730
    }
10731
 
10732
  }
10733
 
10734
  public static class initializeHdfcEmiPayment_result implements org.apache.thrift.TBase<initializeHdfcEmiPayment_result, initializeHdfcEmiPayment_result._Fields>, java.io.Serializable, Cloneable   {
10735
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("initializeHdfcEmiPayment_result");
10736
 
10737
    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);
10738
    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);
10739
 
10740
    private String success; // required
10741
    private PaymentException pe; // required
10742
 
10743
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10744
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10745
      SUCCESS((short)0, "success"),
10746
      PE((short)1, "pe");
10747
 
10748
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10749
 
10750
      static {
10751
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10752
          byName.put(field.getFieldName(), field);
10753
        }
10754
      }
10755
 
10756
      /**
10757
       * Find the _Fields constant that matches fieldId, or null if its not found.
10758
       */
10759
      public static _Fields findByThriftId(int fieldId) {
10760
        switch(fieldId) {
10761
          case 0: // SUCCESS
10762
            return SUCCESS;
10763
          case 1: // PE
10764
            return PE;
10765
          default:
10766
            return null;
10767
        }
10768
      }
10769
 
10770
      /**
10771
       * Find the _Fields constant that matches fieldId, throwing an exception
10772
       * if it is not found.
10773
       */
10774
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10775
        _Fields fields = findByThriftId(fieldId);
10776
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10777
        return fields;
10778
      }
10779
 
10780
      /**
10781
       * Find the _Fields constant that matches name, or null if its not found.
10782
       */
10783
      public static _Fields findByName(String name) {
10784
        return byName.get(name);
10785
      }
10786
 
10787
      private final short _thriftId;
10788
      private final String _fieldName;
10789
 
10790
      _Fields(short thriftId, String fieldName) {
10791
        _thriftId = thriftId;
10792
        _fieldName = fieldName;
10793
      }
10794
 
10795
      public short getThriftFieldId() {
10796
        return _thriftId;
10797
      }
10798
 
10799
      public String getFieldName() {
10800
        return _fieldName;
10801
      }
10802
    }
10803
 
10804
    // isset id assignments
10805
 
10806
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10807
    static {
10808
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10809
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10810
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
10811
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10812
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10813
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10814
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(initializeHdfcEmiPayment_result.class, metaDataMap);
10815
    }
10816
 
10817
    public initializeHdfcEmiPayment_result() {
10818
    }
10819
 
10820
    public initializeHdfcEmiPayment_result(
10821
      String success,
10822
      PaymentException pe)
10823
    {
10824
      this();
10825
      this.success = success;
10826
      this.pe = pe;
10827
    }
10828
 
10829
    /**
10830
     * Performs a deep copy on <i>other</i>.
10831
     */
10832
    public initializeHdfcEmiPayment_result(initializeHdfcEmiPayment_result other) {
10833
      if (other.isSetSuccess()) {
10834
        this.success = other.success;
10835
      }
10836
      if (other.isSetPe()) {
10837
        this.pe = new PaymentException(other.pe);
10838
      }
10839
    }
10840
 
10841
    public initializeHdfcEmiPayment_result deepCopy() {
10842
      return new initializeHdfcEmiPayment_result(this);
10843
    }
10844
 
10845
    @Override
10846
    public void clear() {
10847
      this.success = null;
10848
      this.pe = null;
10849
    }
10850
 
10851
    public String getSuccess() {
10852
      return this.success;
10853
    }
10854
 
10855
    public void setSuccess(String success) {
10856
      this.success = success;
10857
    }
10858
 
10859
    public void unsetSuccess() {
10860
      this.success = null;
10861
    }
10862
 
10863
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10864
    public boolean isSetSuccess() {
10865
      return this.success != null;
10866
    }
10867
 
10868
    public void setSuccessIsSet(boolean value) {
10869
      if (!value) {
10870
        this.success = null;
10871
      }
10872
    }
10873
 
10874
    public PaymentException getPe() {
10875
      return this.pe;
10876
    }
10877
 
10878
    public void setPe(PaymentException pe) {
10879
      this.pe = pe;
10880
    }
10881
 
10882
    public void unsetPe() {
10883
      this.pe = null;
10884
    }
10885
 
10886
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
10887
    public boolean isSetPe() {
10888
      return this.pe != null;
10889
    }
10890
 
10891
    public void setPeIsSet(boolean value) {
10892
      if (!value) {
10893
        this.pe = null;
10894
      }
10895
    }
10896
 
10897
    public void setFieldValue(_Fields field, Object value) {
10898
      switch (field) {
10899
      case SUCCESS:
10900
        if (value == null) {
10901
          unsetSuccess();
10902
        } else {
10903
          setSuccess((String)value);
10904
        }
10905
        break;
10906
 
10907
      case PE:
10908
        if (value == null) {
10909
          unsetPe();
10910
        } else {
10911
          setPe((PaymentException)value);
10912
        }
10913
        break;
10914
 
10915
      }
10916
    }
10917
 
10918
    public Object getFieldValue(_Fields field) {
10919
      switch (field) {
10920
      case SUCCESS:
10921
        return getSuccess();
10922
 
10923
      case PE:
10924
        return getPe();
10925
 
10926
      }
10927
      throw new IllegalStateException();
10928
    }
10929
 
10930
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10931
    public boolean isSet(_Fields field) {
10932
      if (field == null) {
10933
        throw new IllegalArgumentException();
10934
      }
10935
 
10936
      switch (field) {
10937
      case SUCCESS:
10938
        return isSetSuccess();
10939
      case PE:
10940
        return isSetPe();
10941
      }
10942
      throw new IllegalStateException();
10943
    }
10944
 
10945
    @Override
10946
    public boolean equals(Object that) {
10947
      if (that == null)
10948
        return false;
10949
      if (that instanceof initializeHdfcEmiPayment_result)
10950
        return this.equals((initializeHdfcEmiPayment_result)that);
10951
      return false;
10952
    }
10953
 
10954
    public boolean equals(initializeHdfcEmiPayment_result that) {
10955
      if (that == null)
10956
        return false;
10957
 
10958
      boolean this_present_success = true && this.isSetSuccess();
10959
      boolean that_present_success = true && that.isSetSuccess();
10960
      if (this_present_success || that_present_success) {
10961
        if (!(this_present_success && that_present_success))
10962
          return false;
10963
        if (!this.success.equals(that.success))
10964
          return false;
10965
      }
10966
 
10967
      boolean this_present_pe = true && this.isSetPe();
10968
      boolean that_present_pe = true && that.isSetPe();
10969
      if (this_present_pe || that_present_pe) {
10970
        if (!(this_present_pe && that_present_pe))
10971
          return false;
10972
        if (!this.pe.equals(that.pe))
10973
          return false;
10974
      }
10975
 
10976
      return true;
10977
    }
10978
 
10979
    @Override
10980
    public int hashCode() {
10981
      return 0;
10982
    }
10983
 
10984
    public int compareTo(initializeHdfcEmiPayment_result other) {
10985
      if (!getClass().equals(other.getClass())) {
10986
        return getClass().getName().compareTo(other.getClass().getName());
10987
      }
10988
 
10989
      int lastComparison = 0;
10990
      initializeHdfcEmiPayment_result typedOther = (initializeHdfcEmiPayment_result)other;
10991
 
10992
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10993
      if (lastComparison != 0) {
10994
        return lastComparison;
10995
      }
10996
      if (isSetSuccess()) {
10997
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10998
        if (lastComparison != 0) {
10999
          return lastComparison;
11000
        }
11001
      }
11002
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
11003
      if (lastComparison != 0) {
11004
        return lastComparison;
11005
      }
11006
      if (isSetPe()) {
11007
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
11008
        if (lastComparison != 0) {
11009
          return lastComparison;
11010
        }
11011
      }
11012
      return 0;
11013
    }
11014
 
11015
    public _Fields fieldForId(int fieldId) {
11016
      return _Fields.findByThriftId(fieldId);
11017
    }
11018
 
11019
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11020
      org.apache.thrift.protocol.TField field;
11021
      iprot.readStructBegin();
11022
      while (true)
11023
      {
11024
        field = iprot.readFieldBegin();
11025
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11026
          break;
11027
        }
11028
        switch (field.id) {
11029
          case 0: // SUCCESS
11030
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
11031
              this.success = iprot.readString();
11032
            } else { 
11033
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11034
            }
11035
            break;
11036
          case 1: // PE
11037
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11038
              this.pe = new PaymentException();
11039
              this.pe.read(iprot);
11040
            } else { 
11041
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11042
            }
11043
            break;
11044
          default:
11045
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11046
        }
11047
        iprot.readFieldEnd();
11048
      }
11049
      iprot.readStructEnd();
11050
      validate();
11051
    }
11052
 
11053
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11054
      oprot.writeStructBegin(STRUCT_DESC);
11055
 
11056
      if (this.isSetSuccess()) {
11057
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11058
        oprot.writeString(this.success);
11059
        oprot.writeFieldEnd();
11060
      } else if (this.isSetPe()) {
11061
        oprot.writeFieldBegin(PE_FIELD_DESC);
11062
        this.pe.write(oprot);
11063
        oprot.writeFieldEnd();
11064
      }
11065
      oprot.writeFieldStop();
11066
      oprot.writeStructEnd();
11067
    }
11068
 
11069
    @Override
11070
    public String toString() {
11071
      StringBuilder sb = new StringBuilder("initializeHdfcEmiPayment_result(");
11072
      boolean first = true;
11073
 
11074
      sb.append("success:");
11075
      if (this.success == null) {
11076
        sb.append("null");
11077
      } else {
11078
        sb.append(this.success);
11079
      }
11080
      first = false;
11081
      if (!first) sb.append(", ");
11082
      sb.append("pe:");
11083
      if (this.pe == null) {
11084
        sb.append("null");
11085
      } else {
11086
        sb.append(this.pe);
11087
      }
11088
      first = false;
11089
      sb.append(")");
11090
      return sb.toString();
11091
    }
11092
 
11093
    public void validate() throws org.apache.thrift.TException {
11094
      // check for required fields
11095
    }
11096
 
11097
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11098
      try {
11099
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11100
      } catch (org.apache.thrift.TException te) {
11101
        throw new java.io.IOException(te);
11102
      }
11103
    }
11104
 
11105
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11106
      try {
11107
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11108
      } catch (org.apache.thrift.TException te) {
11109
        throw new java.io.IOException(te);
11110
      }
11111
    }
11112
 
11113
  }
11114
 
3430 rajveer 11115
  public static class createRefund_args implements org.apache.thrift.TBase<createRefund_args, createRefund_args._Fields>, java.io.Serializable, Cloneable   {
11116
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createRefund_args");
2462 chandransh 11117
 
3430 rajveer 11118
    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);
11119
    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);
11120
    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 11121
 
3430 rajveer 11122
    private long orderId; // required
11123
    private long merchantTxnId; // required
11124
    private double amount; // required
2462 chandransh 11125
 
11126
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11127
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3010 chandransh 11128
      ORDER_ID((short)1, "orderId"),
11129
      MERCHANT_TXN_ID((short)2, "merchantTxnId"),
11130
      AMOUNT((short)3, "amount");
2462 chandransh 11131
 
11132
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11133
 
11134
      static {
11135
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11136
          byName.put(field.getFieldName(), field);
11137
        }
11138
      }
11139
 
11140
      /**
11141
       * Find the _Fields constant that matches fieldId, or null if its not found.
11142
       */
11143
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11144
        switch(fieldId) {
11145
          case 1: // ORDER_ID
11146
            return ORDER_ID;
11147
          case 2: // MERCHANT_TXN_ID
11148
            return MERCHANT_TXN_ID;
11149
          case 3: // AMOUNT
11150
            return AMOUNT;
11151
          default:
11152
            return null;
11153
        }
2462 chandransh 11154
      }
11155
 
11156
      /**
11157
       * Find the _Fields constant that matches fieldId, throwing an exception
11158
       * if it is not found.
11159
       */
11160
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11161
        _Fields fields = findByThriftId(fieldId);
11162
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11163
        return fields;
11164
      }
11165
 
11166
      /**
11167
       * Find the _Fields constant that matches name, or null if its not found.
11168
       */
11169
      public static _Fields findByName(String name) {
11170
        return byName.get(name);
11171
      }
11172
 
11173
      private final short _thriftId;
11174
      private final String _fieldName;
11175
 
11176
      _Fields(short thriftId, String fieldName) {
11177
        _thriftId = thriftId;
11178
        _fieldName = fieldName;
11179
      }
11180
 
11181
      public short getThriftFieldId() {
11182
        return _thriftId;
11183
      }
11184
 
11185
      public String getFieldName() {
11186
        return _fieldName;
11187
      }
11188
    }
11189
 
11190
    // isset id assignments
3010 chandransh 11191
    private static final int __ORDERID_ISSET_ID = 0;
11192
    private static final int __MERCHANTTXNID_ISSET_ID = 1;
11193
    private static final int __AMOUNT_ISSET_ID = 2;
11194
    private BitSet __isset_bit_vector = new BitSet(3);
2462 chandransh 11195
 
3430 rajveer 11196
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 11197
    static {
3430 rajveer 11198
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11199
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11200
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11201
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11202
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11203
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11204
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
11205
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11206
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createRefund_args.class, metaDataMap);
2462 chandransh 11207
    }
11208
 
3010 chandransh 11209
    public createRefund_args() {
2462 chandransh 11210
    }
11211
 
3010 chandransh 11212
    public createRefund_args(
11213
      long orderId,
11214
      long merchantTxnId,
11215
      double amount)
2462 chandransh 11216
    {
11217
      this();
3010 chandransh 11218
      this.orderId = orderId;
11219
      setOrderIdIsSet(true);
11220
      this.merchantTxnId = merchantTxnId;
11221
      setMerchantTxnIdIsSet(true);
11222
      this.amount = amount;
11223
      setAmountIsSet(true);
2462 chandransh 11224
    }
11225
 
11226
    /**
11227
     * Performs a deep copy on <i>other</i>.
11228
     */
3010 chandransh 11229
    public createRefund_args(createRefund_args other) {
2462 chandransh 11230
      __isset_bit_vector.clear();
11231
      __isset_bit_vector.or(other.__isset_bit_vector);
3010 chandransh 11232
      this.orderId = other.orderId;
11233
      this.merchantTxnId = other.merchantTxnId;
11234
      this.amount = other.amount;
2462 chandransh 11235
    }
11236
 
3010 chandransh 11237
    public createRefund_args deepCopy() {
11238
      return new createRefund_args(this);
2462 chandransh 11239
    }
11240
 
3430 rajveer 11241
    @Override
11242
    public void clear() {
11243
      setOrderIdIsSet(false);
11244
      this.orderId = 0;
11245
      setMerchantTxnIdIsSet(false);
11246
      this.merchantTxnId = 0;
11247
      setAmountIsSet(false);
11248
      this.amount = 0.0;
2462 chandransh 11249
    }
11250
 
3010 chandransh 11251
    public long getOrderId() {
11252
      return this.orderId;
2462 chandransh 11253
    }
11254
 
3430 rajveer 11255
    public void setOrderId(long orderId) {
3010 chandransh 11256
      this.orderId = orderId;
11257
      setOrderIdIsSet(true);
2462 chandransh 11258
    }
11259
 
3010 chandransh 11260
    public void unsetOrderId() {
11261
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
2462 chandransh 11262
    }
11263
 
3430 rajveer 11264
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
3010 chandransh 11265
    public boolean isSetOrderId() {
11266
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
2462 chandransh 11267
    }
11268
 
3010 chandransh 11269
    public void setOrderIdIsSet(boolean value) {
11270
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
2462 chandransh 11271
    }
11272
 
3010 chandransh 11273
    public long getMerchantTxnId() {
11274
      return this.merchantTxnId;
11275
    }
11276
 
3430 rajveer 11277
    public void setMerchantTxnId(long merchantTxnId) {
3010 chandransh 11278
      this.merchantTxnId = merchantTxnId;
11279
      setMerchantTxnIdIsSet(true);
11280
    }
11281
 
11282
    public void unsetMerchantTxnId() {
11283
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
11284
    }
11285
 
3430 rajveer 11286
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
3010 chandransh 11287
    public boolean isSetMerchantTxnId() {
11288
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
11289
    }
11290
 
11291
    public void setMerchantTxnIdIsSet(boolean value) {
11292
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
11293
    }
11294
 
11295
    public double getAmount() {
11296
      return this.amount;
11297
    }
11298
 
3430 rajveer 11299
    public void setAmount(double amount) {
3010 chandransh 11300
      this.amount = amount;
11301
      setAmountIsSet(true);
11302
    }
11303
 
11304
    public void unsetAmount() {
11305
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
11306
    }
11307
 
3430 rajveer 11308
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
3010 chandransh 11309
    public boolean isSetAmount() {
11310
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
11311
    }
11312
 
11313
    public void setAmountIsSet(boolean value) {
11314
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
11315
    }
11316
 
2462 chandransh 11317
    public void setFieldValue(_Fields field, Object value) {
11318
      switch (field) {
3010 chandransh 11319
      case ORDER_ID:
2462 chandransh 11320
        if (value == null) {
3010 chandransh 11321
          unsetOrderId();
2462 chandransh 11322
        } else {
3010 chandransh 11323
          setOrderId((Long)value);
2462 chandransh 11324
        }
11325
        break;
11326
 
3010 chandransh 11327
      case MERCHANT_TXN_ID:
11328
        if (value == null) {
11329
          unsetMerchantTxnId();
11330
        } else {
11331
          setMerchantTxnId((Long)value);
11332
        }
11333
        break;
11334
 
11335
      case AMOUNT:
11336
        if (value == null) {
11337
          unsetAmount();
11338
        } else {
11339
          setAmount((Double)value);
11340
        }
11341
        break;
11342
 
2462 chandransh 11343
      }
11344
    }
11345
 
11346
    public Object getFieldValue(_Fields field) {
11347
      switch (field) {
3010 chandransh 11348
      case ORDER_ID:
3430 rajveer 11349
        return Long.valueOf(getOrderId());
2462 chandransh 11350
 
3010 chandransh 11351
      case MERCHANT_TXN_ID:
3430 rajveer 11352
        return Long.valueOf(getMerchantTxnId());
3010 chandransh 11353
 
11354
      case AMOUNT:
3430 rajveer 11355
        return Double.valueOf(getAmount());
3010 chandransh 11356
 
2462 chandransh 11357
      }
11358
      throw new IllegalStateException();
11359
    }
11360
 
3430 rajveer 11361
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11362
    public boolean isSet(_Fields field) {
11363
      if (field == null) {
11364
        throw new IllegalArgumentException();
11365
      }
2462 chandransh 11366
 
11367
      switch (field) {
3010 chandransh 11368
      case ORDER_ID:
11369
        return isSetOrderId();
11370
      case MERCHANT_TXN_ID:
11371
        return isSetMerchantTxnId();
11372
      case AMOUNT:
11373
        return isSetAmount();
2462 chandransh 11374
      }
11375
      throw new IllegalStateException();
11376
    }
11377
 
11378
    @Override
11379
    public boolean equals(Object that) {
11380
      if (that == null)
11381
        return false;
3010 chandransh 11382
      if (that instanceof createRefund_args)
11383
        return this.equals((createRefund_args)that);
2462 chandransh 11384
      return false;
11385
    }
11386
 
3010 chandransh 11387
    public boolean equals(createRefund_args that) {
2462 chandransh 11388
      if (that == null)
11389
        return false;
11390
 
3010 chandransh 11391
      boolean this_present_orderId = true;
11392
      boolean that_present_orderId = true;
11393
      if (this_present_orderId || that_present_orderId) {
11394
        if (!(this_present_orderId && that_present_orderId))
2462 chandransh 11395
          return false;
3010 chandransh 11396
        if (this.orderId != that.orderId)
2462 chandransh 11397
          return false;
11398
      }
11399
 
3010 chandransh 11400
      boolean this_present_merchantTxnId = true;
11401
      boolean that_present_merchantTxnId = true;
11402
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
11403
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
11404
          return false;
11405
        if (this.merchantTxnId != that.merchantTxnId)
11406
          return false;
11407
      }
11408
 
11409
      boolean this_present_amount = true;
11410
      boolean that_present_amount = true;
11411
      if (this_present_amount || that_present_amount) {
11412
        if (!(this_present_amount && that_present_amount))
11413
          return false;
11414
        if (this.amount != that.amount)
11415
          return false;
11416
      }
11417
 
2462 chandransh 11418
      return true;
11419
    }
11420
 
11421
    @Override
11422
    public int hashCode() {
11423
      return 0;
11424
    }
11425
 
3010 chandransh 11426
    public int compareTo(createRefund_args other) {
2462 chandransh 11427
      if (!getClass().equals(other.getClass())) {
11428
        return getClass().getName().compareTo(other.getClass().getName());
11429
      }
11430
 
11431
      int lastComparison = 0;
3010 chandransh 11432
      createRefund_args typedOther = (createRefund_args)other;
2462 chandransh 11433
 
3430 rajveer 11434
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
2462 chandransh 11435
      if (lastComparison != 0) {
11436
        return lastComparison;
11437
      }
3430 rajveer 11438
      if (isSetOrderId()) {
11439
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
11440
        if (lastComparison != 0) {
11441
          return lastComparison;
11442
        }
2462 chandransh 11443
      }
3430 rajveer 11444
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
3010 chandransh 11445
      if (lastComparison != 0) {
11446
        return lastComparison;
11447
      }
3430 rajveer 11448
      if (isSetMerchantTxnId()) {
11449
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
11450
        if (lastComparison != 0) {
11451
          return lastComparison;
11452
        }
3010 chandransh 11453
      }
3430 rajveer 11454
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
3010 chandransh 11455
      if (lastComparison != 0) {
11456
        return lastComparison;
11457
      }
3430 rajveer 11458
      if (isSetAmount()) {
11459
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
11460
        if (lastComparison != 0) {
11461
          return lastComparison;
11462
        }
3010 chandransh 11463
      }
2462 chandransh 11464
      return 0;
11465
    }
11466
 
3430 rajveer 11467
    public _Fields fieldForId(int fieldId) {
11468
      return _Fields.findByThriftId(fieldId);
11469
    }
11470
 
11471
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11472
      org.apache.thrift.protocol.TField field;
2462 chandransh 11473
      iprot.readStructBegin();
11474
      while (true)
11475
      {
11476
        field = iprot.readFieldBegin();
3430 rajveer 11477
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 11478
          break;
11479
        }
3430 rajveer 11480
        switch (field.id) {
11481
          case 1: // ORDER_ID
11482
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11483
              this.orderId = iprot.readI64();
11484
              setOrderIdIsSet(true);
11485
            } else { 
11486
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11487
            }
11488
            break;
11489
          case 2: // MERCHANT_TXN_ID
11490
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11491
              this.merchantTxnId = iprot.readI64();
11492
              setMerchantTxnIdIsSet(true);
11493
            } else { 
11494
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11495
            }
11496
            break;
11497
          case 3: // AMOUNT
11498
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
11499
              this.amount = iprot.readDouble();
11500
              setAmountIsSet(true);
11501
            } else { 
11502
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11503
            }
11504
            break;
11505
          default:
11506
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 11507
        }
3430 rajveer 11508
        iprot.readFieldEnd();
2462 chandransh 11509
      }
11510
      iprot.readStructEnd();
11511
      validate();
11512
    }
11513
 
3430 rajveer 11514
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 11515
      validate();
11516
 
11517
      oprot.writeStructBegin(STRUCT_DESC);
3010 chandransh 11518
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
11519
      oprot.writeI64(this.orderId);
2462 chandransh 11520
      oprot.writeFieldEnd();
3010 chandransh 11521
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
11522
      oprot.writeI64(this.merchantTxnId);
11523
      oprot.writeFieldEnd();
11524
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
11525
      oprot.writeDouble(this.amount);
11526
      oprot.writeFieldEnd();
2462 chandransh 11527
      oprot.writeFieldStop();
11528
      oprot.writeStructEnd();
11529
    }
11530
 
11531
    @Override
11532
    public String toString() {
3010 chandransh 11533
      StringBuilder sb = new StringBuilder("createRefund_args(");
2462 chandransh 11534
      boolean first = true;
11535
 
3010 chandransh 11536
      sb.append("orderId:");
11537
      sb.append(this.orderId);
2462 chandransh 11538
      first = false;
3010 chandransh 11539
      if (!first) sb.append(", ");
11540
      sb.append("merchantTxnId:");
11541
      sb.append(this.merchantTxnId);
11542
      first = false;
11543
      if (!first) sb.append(", ");
11544
      sb.append("amount:");
11545
      sb.append(this.amount);
11546
      first = false;
2462 chandransh 11547
      sb.append(")");
11548
      return sb.toString();
11549
    }
11550
 
3430 rajveer 11551
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 11552
      // check for required fields
11553
    }
11554
 
3430 rajveer 11555
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11556
      try {
11557
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11558
      } catch (org.apache.thrift.TException te) {
11559
        throw new java.io.IOException(te);
11560
      }
11561
    }
11562
 
11563
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11564
      try {
11565
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11566
      } catch (org.apache.thrift.TException te) {
11567
        throw new java.io.IOException(te);
11568
      }
11569
    }
11570
 
2462 chandransh 11571
  }
11572
 
3430 rajveer 11573
  public static class createRefund_result implements org.apache.thrift.TBase<createRefund_result, createRefund_result._Fields>, java.io.Serializable, Cloneable   {
11574
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createRefund_result");
2462 chandransh 11575
 
3430 rajveer 11576
    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);
11577
    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 11578
 
3430 rajveer 11579
    private long success; // required
11580
    private PaymentException pe; // required
2462 chandransh 11581
 
11582
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11583
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2462 chandransh 11584
      SUCCESS((short)0, "success"),
11585
      PE((short)1, "pe");
11586
 
11587
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11588
 
11589
      static {
11590
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11591
          byName.put(field.getFieldName(), field);
11592
        }
11593
      }
11594
 
11595
      /**
11596
       * Find the _Fields constant that matches fieldId, or null if its not found.
11597
       */
11598
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11599
        switch(fieldId) {
11600
          case 0: // SUCCESS
11601
            return SUCCESS;
11602
          case 1: // PE
11603
            return PE;
11604
          default:
11605
            return null;
11606
        }
2462 chandransh 11607
      }
11608
 
11609
      /**
11610
       * Find the _Fields constant that matches fieldId, throwing an exception
11611
       * if it is not found.
11612
       */
11613
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11614
        _Fields fields = findByThriftId(fieldId);
11615
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11616
        return fields;
11617
      }
11618
 
11619
      /**
11620
       * Find the _Fields constant that matches name, or null if its not found.
11621
       */
11622
      public static _Fields findByName(String name) {
11623
        return byName.get(name);
11624
      }
11625
 
11626
      private final short _thriftId;
11627
      private final String _fieldName;
11628
 
11629
      _Fields(short thriftId, String fieldName) {
11630
        _thriftId = thriftId;
11631
        _fieldName = fieldName;
11632
      }
11633
 
11634
      public short getThriftFieldId() {
11635
        return _thriftId;
11636
      }
11637
 
11638
      public String getFieldName() {
11639
        return _fieldName;
11640
      }
11641
    }
11642
 
11643
    // isset id assignments
3010 chandransh 11644
    private static final int __SUCCESS_ISSET_ID = 0;
11645
    private BitSet __isset_bit_vector = new BitSet(1);
2462 chandransh 11646
 
3430 rajveer 11647
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2462 chandransh 11648
    static {
3430 rajveer 11649
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11650
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11651
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11652
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11653
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11654
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11655
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createRefund_result.class, metaDataMap);
2462 chandransh 11656
    }
11657
 
3010 chandransh 11658
    public createRefund_result() {
2462 chandransh 11659
    }
11660
 
3010 chandransh 11661
    public createRefund_result(
11662
      long success,
2462 chandransh 11663
      PaymentException pe)
11664
    {
11665
      this();
11666
      this.success = success;
3010 chandransh 11667
      setSuccessIsSet(true);
2462 chandransh 11668
      this.pe = pe;
11669
    }
11670
 
11671
    /**
11672
     * Performs a deep copy on <i>other</i>.
11673
     */
3010 chandransh 11674
    public createRefund_result(createRefund_result other) {
11675
      __isset_bit_vector.clear();
11676
      __isset_bit_vector.or(other.__isset_bit_vector);
11677
      this.success = other.success;
2462 chandransh 11678
      if (other.isSetPe()) {
11679
        this.pe = new PaymentException(other.pe);
11680
      }
11681
    }
11682
 
3010 chandransh 11683
    public createRefund_result deepCopy() {
11684
      return new createRefund_result(this);
2462 chandransh 11685
    }
11686
 
3430 rajveer 11687
    @Override
11688
    public void clear() {
11689
      setSuccessIsSet(false);
11690
      this.success = 0;
11691
      this.pe = null;
2462 chandransh 11692
    }
11693
 
3010 chandransh 11694
    public long getSuccess() {
2462 chandransh 11695
      return this.success;
11696
    }
11697
 
3430 rajveer 11698
    public void setSuccess(long success) {
2462 chandransh 11699
      this.success = success;
3010 chandransh 11700
      setSuccessIsSet(true);
2462 chandransh 11701
    }
11702
 
11703
    public void unsetSuccess() {
3010 chandransh 11704
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
2462 chandransh 11705
    }
11706
 
3430 rajveer 11707
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2462 chandransh 11708
    public boolean isSetSuccess() {
3010 chandransh 11709
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
2462 chandransh 11710
    }
11711
 
11712
    public void setSuccessIsSet(boolean value) {
3010 chandransh 11713
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
2462 chandransh 11714
    }
11715
 
11716
    public PaymentException getPe() {
11717
      return this.pe;
11718
    }
11719
 
3430 rajveer 11720
    public void setPe(PaymentException pe) {
2462 chandransh 11721
      this.pe = pe;
11722
    }
11723
 
11724
    public void unsetPe() {
11725
      this.pe = null;
11726
    }
11727
 
3430 rajveer 11728
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2462 chandransh 11729
    public boolean isSetPe() {
11730
      return this.pe != null;
11731
    }
11732
 
11733
    public void setPeIsSet(boolean value) {
11734
      if (!value) {
11735
        this.pe = null;
11736
      }
11737
    }
11738
 
11739
    public void setFieldValue(_Fields field, Object value) {
11740
      switch (field) {
11741
      case SUCCESS:
11742
        if (value == null) {
11743
          unsetSuccess();
11744
        } else {
3010 chandransh 11745
          setSuccess((Long)value);
2462 chandransh 11746
        }
11747
        break;
11748
 
11749
      case PE:
11750
        if (value == null) {
11751
          unsetPe();
11752
        } else {
11753
          setPe((PaymentException)value);
11754
        }
11755
        break;
11756
 
11757
      }
11758
    }
11759
 
11760
    public Object getFieldValue(_Fields field) {
11761
      switch (field) {
11762
      case SUCCESS:
3430 rajveer 11763
        return Long.valueOf(getSuccess());
2462 chandransh 11764
 
11765
      case PE:
11766
        return getPe();
11767
 
11768
      }
11769
      throw new IllegalStateException();
11770
    }
11771
 
3430 rajveer 11772
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11773
    public boolean isSet(_Fields field) {
11774
      if (field == null) {
11775
        throw new IllegalArgumentException();
11776
      }
2462 chandransh 11777
 
11778
      switch (field) {
11779
      case SUCCESS:
11780
        return isSetSuccess();
11781
      case PE:
11782
        return isSetPe();
11783
      }
11784
      throw new IllegalStateException();
11785
    }
11786
 
11787
    @Override
11788
    public boolean equals(Object that) {
11789
      if (that == null)
11790
        return false;
3010 chandransh 11791
      if (that instanceof createRefund_result)
11792
        return this.equals((createRefund_result)that);
2462 chandransh 11793
      return false;
11794
    }
11795
 
3010 chandransh 11796
    public boolean equals(createRefund_result that) {
2462 chandransh 11797
      if (that == null)
11798
        return false;
11799
 
3010 chandransh 11800
      boolean this_present_success = true;
11801
      boolean that_present_success = true;
2462 chandransh 11802
      if (this_present_success || that_present_success) {
11803
        if (!(this_present_success && that_present_success))
11804
          return false;
3010 chandransh 11805
        if (this.success != that.success)
2462 chandransh 11806
          return false;
11807
      }
11808
 
11809
      boolean this_present_pe = true && this.isSetPe();
11810
      boolean that_present_pe = true && that.isSetPe();
11811
      if (this_present_pe || that_present_pe) {
11812
        if (!(this_present_pe && that_present_pe))
11813
          return false;
11814
        if (!this.pe.equals(that.pe))
11815
          return false;
11816
      }
11817
 
11818
      return true;
11819
    }
11820
 
11821
    @Override
11822
    public int hashCode() {
11823
      return 0;
11824
    }
11825
 
3010 chandransh 11826
    public int compareTo(createRefund_result other) {
2462 chandransh 11827
      if (!getClass().equals(other.getClass())) {
11828
        return getClass().getName().compareTo(other.getClass().getName());
11829
      }
11830
 
11831
      int lastComparison = 0;
3010 chandransh 11832
      createRefund_result typedOther = (createRefund_result)other;
2462 chandransh 11833
 
3430 rajveer 11834
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2462 chandransh 11835
      if (lastComparison != 0) {
11836
        return lastComparison;
11837
      }
3430 rajveer 11838
      if (isSetSuccess()) {
11839
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11840
        if (lastComparison != 0) {
11841
          return lastComparison;
11842
        }
2462 chandransh 11843
      }
3430 rajveer 11844
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
2462 chandransh 11845
      if (lastComparison != 0) {
11846
        return lastComparison;
11847
      }
3430 rajveer 11848
      if (isSetPe()) {
11849
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
11850
        if (lastComparison != 0) {
11851
          return lastComparison;
11852
        }
2462 chandransh 11853
      }
11854
      return 0;
11855
    }
11856
 
3430 rajveer 11857
    public _Fields fieldForId(int fieldId) {
11858
      return _Fields.findByThriftId(fieldId);
11859
    }
11860
 
11861
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11862
      org.apache.thrift.protocol.TField field;
2462 chandransh 11863
      iprot.readStructBegin();
11864
      while (true)
11865
      {
11866
        field = iprot.readFieldBegin();
3430 rajveer 11867
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2462 chandransh 11868
          break;
11869
        }
3430 rajveer 11870
        switch (field.id) {
11871
          case 0: // SUCCESS
11872
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11873
              this.success = iprot.readI64();
11874
              setSuccessIsSet(true);
11875
            } else { 
11876
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11877
            }
11878
            break;
11879
          case 1: // PE
11880
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11881
              this.pe = new PaymentException();
11882
              this.pe.read(iprot);
11883
            } else { 
11884
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11885
            }
11886
            break;
11887
          default:
11888
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2462 chandransh 11889
        }
3430 rajveer 11890
        iprot.readFieldEnd();
2462 chandransh 11891
      }
11892
      iprot.readStructEnd();
11893
      validate();
11894
    }
11895
 
3430 rajveer 11896
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2462 chandransh 11897
      oprot.writeStructBegin(STRUCT_DESC);
11898
 
11899
      if (this.isSetSuccess()) {
11900
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 11901
        oprot.writeI64(this.success);
2462 chandransh 11902
        oprot.writeFieldEnd();
11903
      } else if (this.isSetPe()) {
11904
        oprot.writeFieldBegin(PE_FIELD_DESC);
11905
        this.pe.write(oprot);
11906
        oprot.writeFieldEnd();
11907
      }
11908
      oprot.writeFieldStop();
11909
      oprot.writeStructEnd();
11910
    }
11911
 
11912
    @Override
11913
    public String toString() {
3010 chandransh 11914
      StringBuilder sb = new StringBuilder("createRefund_result(");
2462 chandransh 11915
      boolean first = true;
11916
 
11917
      sb.append("success:");
3010 chandransh 11918
      sb.append(this.success);
2462 chandransh 11919
      first = false;
11920
      if (!first) sb.append(", ");
11921
      sb.append("pe:");
11922
      if (this.pe == null) {
11923
        sb.append("null");
11924
      } else {
11925
        sb.append(this.pe);
11926
      }
11927
      first = false;
11928
      sb.append(")");
11929
      return sb.toString();
11930
    }
11931
 
3430 rajveer 11932
    public void validate() throws org.apache.thrift.TException {
2462 chandransh 11933
      // check for required fields
11934
    }
11935
 
3430 rajveer 11936
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11937
      try {
11938
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11939
      } catch (org.apache.thrift.TException te) {
11940
        throw new java.io.IOException(te);
11941
      }
11942
    }
11943
 
11944
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11945
      try {
11946
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11947
      } catch (org.apache.thrift.TException te) {
11948
        throw new java.io.IOException(te);
11949
      }
11950
    }
11951
 
2462 chandransh 11952
  }
11953
 
3430 rajveer 11954
  public static class capturePayment_args implements org.apache.thrift.TBase<capturePayment_args, capturePayment_args._Fields>, java.io.Serializable, Cloneable   {
11955
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("capturePayment_args");
2690 chandransh 11956
 
3430 rajveer 11957
    private static final org.apache.thrift.protocol.TField MERCHANT_TXN_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("merchantTxnId", org.apache.thrift.protocol.TType.I64, (short)1);
2690 chandransh 11958
 
3430 rajveer 11959
    private long merchantTxnId; // required
2690 chandransh 11960
 
11961
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 11962
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3010 chandransh 11963
      MERCHANT_TXN_ID((short)1, "merchantTxnId");
2690 chandransh 11964
 
11965
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11966
 
11967
      static {
11968
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11969
          byName.put(field.getFieldName(), field);
11970
        }
11971
      }
11972
 
11973
      /**
11974
       * Find the _Fields constant that matches fieldId, or null if its not found.
11975
       */
11976
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 11977
        switch(fieldId) {
11978
          case 1: // MERCHANT_TXN_ID
11979
            return MERCHANT_TXN_ID;
11980
          default:
11981
            return null;
11982
        }
2690 chandransh 11983
      }
11984
 
11985
      /**
11986
       * Find the _Fields constant that matches fieldId, throwing an exception
11987
       * if it is not found.
11988
       */
11989
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11990
        _Fields fields = findByThriftId(fieldId);
11991
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11992
        return fields;
11993
      }
11994
 
11995
      /**
11996
       * Find the _Fields constant that matches name, or null if its not found.
11997
       */
11998
      public static _Fields findByName(String name) {
11999
        return byName.get(name);
12000
      }
12001
 
12002
      private final short _thriftId;
12003
      private final String _fieldName;
12004
 
12005
      _Fields(short thriftId, String fieldName) {
12006
        _thriftId = thriftId;
12007
        _fieldName = fieldName;
12008
      }
12009
 
12010
      public short getThriftFieldId() {
12011
        return _thriftId;
12012
      }
12013
 
12014
      public String getFieldName() {
12015
        return _fieldName;
12016
      }
12017
    }
12018
 
12019
    // isset id assignments
3010 chandransh 12020
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
12021
    private BitSet __isset_bit_vector = new BitSet(1);
2690 chandransh 12022
 
3430 rajveer 12023
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2690 chandransh 12024
    static {
3430 rajveer 12025
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12026
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12027
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12028
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12029
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(capturePayment_args.class, metaDataMap);
2690 chandransh 12030
    }
12031
 
3010 chandransh 12032
    public capturePayment_args() {
2690 chandransh 12033
    }
12034
 
3010 chandransh 12035
    public capturePayment_args(
12036
      long merchantTxnId)
2690 chandransh 12037
    {
12038
      this();
12039
      this.merchantTxnId = merchantTxnId;
12040
      setMerchantTxnIdIsSet(true);
12041
    }
12042
 
12043
    /**
12044
     * Performs a deep copy on <i>other</i>.
12045
     */
3010 chandransh 12046
    public capturePayment_args(capturePayment_args other) {
2690 chandransh 12047
      __isset_bit_vector.clear();
12048
      __isset_bit_vector.or(other.__isset_bit_vector);
12049
      this.merchantTxnId = other.merchantTxnId;
12050
    }
12051
 
3010 chandransh 12052
    public capturePayment_args deepCopy() {
12053
      return new capturePayment_args(this);
2690 chandransh 12054
    }
12055
 
3430 rajveer 12056
    @Override
12057
    public void clear() {
12058
      setMerchantTxnIdIsSet(false);
12059
      this.merchantTxnId = 0;
2690 chandransh 12060
    }
12061
 
12062
    public long getMerchantTxnId() {
12063
      return this.merchantTxnId;
12064
    }
12065
 
3430 rajveer 12066
    public void setMerchantTxnId(long merchantTxnId) {
2690 chandransh 12067
      this.merchantTxnId = merchantTxnId;
12068
      setMerchantTxnIdIsSet(true);
12069
    }
12070
 
12071
    public void unsetMerchantTxnId() {
12072
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
12073
    }
12074
 
3430 rajveer 12075
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
2690 chandransh 12076
    public boolean isSetMerchantTxnId() {
12077
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
12078
    }
12079
 
12080
    public void setMerchantTxnIdIsSet(boolean value) {
12081
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
12082
    }
12083
 
12084
    public void setFieldValue(_Fields field, Object value) {
12085
      switch (field) {
12086
      case MERCHANT_TXN_ID:
12087
        if (value == null) {
12088
          unsetMerchantTxnId();
12089
        } else {
12090
          setMerchantTxnId((Long)value);
12091
        }
12092
        break;
12093
 
12094
      }
12095
    }
12096
 
12097
    public Object getFieldValue(_Fields field) {
12098
      switch (field) {
12099
      case MERCHANT_TXN_ID:
3430 rajveer 12100
        return Long.valueOf(getMerchantTxnId());
2690 chandransh 12101
 
12102
      }
12103
      throw new IllegalStateException();
12104
    }
12105
 
3430 rajveer 12106
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12107
    public boolean isSet(_Fields field) {
12108
      if (field == null) {
12109
        throw new IllegalArgumentException();
12110
      }
2690 chandransh 12111
 
12112
      switch (field) {
12113
      case MERCHANT_TXN_ID:
12114
        return isSetMerchantTxnId();
12115
      }
12116
      throw new IllegalStateException();
12117
    }
12118
 
12119
    @Override
12120
    public boolean equals(Object that) {
12121
      if (that == null)
12122
        return false;
3010 chandransh 12123
      if (that instanceof capturePayment_args)
12124
        return this.equals((capturePayment_args)that);
2690 chandransh 12125
      return false;
12126
    }
12127
 
3010 chandransh 12128
    public boolean equals(capturePayment_args that) {
2690 chandransh 12129
      if (that == null)
12130
        return false;
12131
 
12132
      boolean this_present_merchantTxnId = true;
12133
      boolean that_present_merchantTxnId = true;
12134
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
12135
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
12136
          return false;
12137
        if (this.merchantTxnId != that.merchantTxnId)
12138
          return false;
12139
      }
12140
 
12141
      return true;
12142
    }
12143
 
12144
    @Override
12145
    public int hashCode() {
12146
      return 0;
12147
    }
12148
 
3010 chandransh 12149
    public int compareTo(capturePayment_args other) {
2690 chandransh 12150
      if (!getClass().equals(other.getClass())) {
12151
        return getClass().getName().compareTo(other.getClass().getName());
12152
      }
12153
 
12154
      int lastComparison = 0;
3010 chandransh 12155
      capturePayment_args typedOther = (capturePayment_args)other;
2690 chandransh 12156
 
3430 rajveer 12157
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
2690 chandransh 12158
      if (lastComparison != 0) {
12159
        return lastComparison;
12160
      }
3430 rajveer 12161
      if (isSetMerchantTxnId()) {
12162
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
12163
        if (lastComparison != 0) {
12164
          return lastComparison;
12165
        }
2690 chandransh 12166
      }
12167
      return 0;
12168
    }
12169
 
3430 rajveer 12170
    public _Fields fieldForId(int fieldId) {
12171
      return _Fields.findByThriftId(fieldId);
12172
    }
12173
 
12174
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12175
      org.apache.thrift.protocol.TField field;
2690 chandransh 12176
      iprot.readStructBegin();
12177
      while (true)
12178
      {
12179
        field = iprot.readFieldBegin();
3430 rajveer 12180
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2690 chandransh 12181
          break;
12182
        }
3430 rajveer 12183
        switch (field.id) {
12184
          case 1: // MERCHANT_TXN_ID
12185
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12186
              this.merchantTxnId = iprot.readI64();
12187
              setMerchantTxnIdIsSet(true);
12188
            } else { 
12189
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12190
            }
12191
            break;
12192
          default:
12193
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2690 chandransh 12194
        }
3430 rajveer 12195
        iprot.readFieldEnd();
2690 chandransh 12196
      }
12197
      iprot.readStructEnd();
12198
      validate();
12199
    }
12200
 
3430 rajveer 12201
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2690 chandransh 12202
      validate();
12203
 
12204
      oprot.writeStructBegin(STRUCT_DESC);
12205
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
12206
      oprot.writeI64(this.merchantTxnId);
12207
      oprot.writeFieldEnd();
12208
      oprot.writeFieldStop();
12209
      oprot.writeStructEnd();
12210
    }
12211
 
12212
    @Override
12213
    public String toString() {
3010 chandransh 12214
      StringBuilder sb = new StringBuilder("capturePayment_args(");
2690 chandransh 12215
      boolean first = true;
12216
 
12217
      sb.append("merchantTxnId:");
12218
      sb.append(this.merchantTxnId);
12219
      first = false;
12220
      sb.append(")");
12221
      return sb.toString();
12222
    }
12223
 
3430 rajveer 12224
    public void validate() throws org.apache.thrift.TException {
2690 chandransh 12225
      // check for required fields
12226
    }
12227
 
3430 rajveer 12228
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12229
      try {
12230
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12231
      } catch (org.apache.thrift.TException te) {
12232
        throw new java.io.IOException(te);
12233
      }
12234
    }
12235
 
12236
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12237
      try {
12238
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12239
      } catch (org.apache.thrift.TException te) {
12240
        throw new java.io.IOException(te);
12241
      }
12242
    }
12243
 
2690 chandransh 12244
  }
12245
 
3430 rajveer 12246
  public static class capturePayment_result implements org.apache.thrift.TBase<capturePayment_result, capturePayment_result._Fields>, java.io.Serializable, Cloneable   {
12247
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("capturePayment_result");
2690 chandransh 12248
 
3430 rajveer 12249
    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);
12250
    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 12251
 
3430 rajveer 12252
    private boolean success; // required
12253
    private PaymentException pe; // required
2690 chandransh 12254
 
12255
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 12256
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2690 chandransh 12257
      SUCCESS((short)0, "success"),
12258
      PE((short)1, "pe");
12259
 
12260
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12261
 
12262
      static {
12263
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12264
          byName.put(field.getFieldName(), field);
12265
        }
12266
      }
12267
 
12268
      /**
12269
       * Find the _Fields constant that matches fieldId, or null if its not found.
12270
       */
12271
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 12272
        switch(fieldId) {
12273
          case 0: // SUCCESS
12274
            return SUCCESS;
12275
          case 1: // PE
12276
            return PE;
12277
          default:
12278
            return null;
12279
        }
2690 chandransh 12280
      }
12281
 
12282
      /**
12283
       * Find the _Fields constant that matches fieldId, throwing an exception
12284
       * if it is not found.
12285
       */
12286
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12287
        _Fields fields = findByThriftId(fieldId);
12288
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12289
        return fields;
12290
      }
12291
 
12292
      /**
12293
       * Find the _Fields constant that matches name, or null if its not found.
12294
       */
12295
      public static _Fields findByName(String name) {
12296
        return byName.get(name);
12297
      }
12298
 
12299
      private final short _thriftId;
12300
      private final String _fieldName;
12301
 
12302
      _Fields(short thriftId, String fieldName) {
12303
        _thriftId = thriftId;
12304
        _fieldName = fieldName;
12305
      }
12306
 
12307
      public short getThriftFieldId() {
12308
        return _thriftId;
12309
      }
12310
 
12311
      public String getFieldName() {
12312
        return _fieldName;
12313
      }
12314
    }
12315
 
12316
    // isset id assignments
12317
    private static final int __SUCCESS_ISSET_ID = 0;
12318
    private BitSet __isset_bit_vector = new BitSet(1);
12319
 
3430 rajveer 12320
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2690 chandransh 12321
    static {
3430 rajveer 12322
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12323
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12324
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
12325
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12326
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
12327
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12328
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(capturePayment_result.class, metaDataMap);
2690 chandransh 12329
    }
12330
 
3010 chandransh 12331
    public capturePayment_result() {
2690 chandransh 12332
    }
12333
 
3010 chandransh 12334
    public capturePayment_result(
12335
      boolean success,
2690 chandransh 12336
      PaymentException pe)
12337
    {
12338
      this();
12339
      this.success = success;
12340
      setSuccessIsSet(true);
12341
      this.pe = pe;
12342
    }
12343
 
12344
    /**
12345
     * Performs a deep copy on <i>other</i>.
12346
     */
3010 chandransh 12347
    public capturePayment_result(capturePayment_result other) {
2690 chandransh 12348
      __isset_bit_vector.clear();
12349
      __isset_bit_vector.or(other.__isset_bit_vector);
12350
      this.success = other.success;
12351
      if (other.isSetPe()) {
12352
        this.pe = new PaymentException(other.pe);
12353
      }
12354
    }
12355
 
3010 chandransh 12356
    public capturePayment_result deepCopy() {
12357
      return new capturePayment_result(this);
2690 chandransh 12358
    }
12359
 
3430 rajveer 12360
    @Override
12361
    public void clear() {
12362
      setSuccessIsSet(false);
12363
      this.success = false;
12364
      this.pe = null;
2690 chandransh 12365
    }
12366
 
3010 chandransh 12367
    public boolean isSuccess() {
2690 chandransh 12368
      return this.success;
12369
    }
12370
 
3430 rajveer 12371
    public void setSuccess(boolean success) {
2690 chandransh 12372
      this.success = success;
12373
      setSuccessIsSet(true);
12374
    }
12375
 
12376
    public void unsetSuccess() {
12377
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
12378
    }
12379
 
3430 rajveer 12380
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2690 chandransh 12381
    public boolean isSetSuccess() {
12382
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
12383
    }
12384
 
12385
    public void setSuccessIsSet(boolean value) {
12386
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
12387
    }
12388
 
12389
    public PaymentException getPe() {
12390
      return this.pe;
12391
    }
12392
 
3430 rajveer 12393
    public void setPe(PaymentException pe) {
2690 chandransh 12394
      this.pe = pe;
12395
    }
12396
 
12397
    public void unsetPe() {
12398
      this.pe = null;
12399
    }
12400
 
3430 rajveer 12401
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
2690 chandransh 12402
    public boolean isSetPe() {
12403
      return this.pe != null;
12404
    }
12405
 
12406
    public void setPeIsSet(boolean value) {
12407
      if (!value) {
12408
        this.pe = null;
12409
      }
12410
    }
12411
 
12412
    public void setFieldValue(_Fields field, Object value) {
12413
      switch (field) {
12414
      case SUCCESS:
12415
        if (value == null) {
12416
          unsetSuccess();
12417
        } else {
3010 chandransh 12418
          setSuccess((Boolean)value);
2690 chandransh 12419
        }
12420
        break;
12421
 
12422
      case PE:
12423
        if (value == null) {
12424
          unsetPe();
12425
        } else {
12426
          setPe((PaymentException)value);
12427
        }
12428
        break;
12429
 
12430
      }
12431
    }
12432
 
12433
    public Object getFieldValue(_Fields field) {
12434
      switch (field) {
12435
      case SUCCESS:
3430 rajveer 12436
        return Boolean.valueOf(isSuccess());
2690 chandransh 12437
 
12438
      case PE:
12439
        return getPe();
12440
 
12441
      }
12442
      throw new IllegalStateException();
12443
    }
12444
 
3430 rajveer 12445
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12446
    public boolean isSet(_Fields field) {
12447
      if (field == null) {
12448
        throw new IllegalArgumentException();
12449
      }
2690 chandransh 12450
 
12451
      switch (field) {
12452
      case SUCCESS:
12453
        return isSetSuccess();
12454
      case PE:
12455
        return isSetPe();
12456
      }
12457
      throw new IllegalStateException();
12458
    }
12459
 
12460
    @Override
12461
    public boolean equals(Object that) {
12462
      if (that == null)
12463
        return false;
3010 chandransh 12464
      if (that instanceof capturePayment_result)
12465
        return this.equals((capturePayment_result)that);
2690 chandransh 12466
      return false;
12467
    }
12468
 
3010 chandransh 12469
    public boolean equals(capturePayment_result that) {
2690 chandransh 12470
      if (that == null)
12471
        return false;
12472
 
12473
      boolean this_present_success = true;
12474
      boolean that_present_success = true;
12475
      if (this_present_success || that_present_success) {
12476
        if (!(this_present_success && that_present_success))
12477
          return false;
12478
        if (this.success != that.success)
12479
          return false;
12480
      }
12481
 
12482
      boolean this_present_pe = true && this.isSetPe();
12483
      boolean that_present_pe = true && that.isSetPe();
12484
      if (this_present_pe || that_present_pe) {
12485
        if (!(this_present_pe && that_present_pe))
12486
          return false;
12487
        if (!this.pe.equals(that.pe))
12488
          return false;
12489
      }
12490
 
12491
      return true;
12492
    }
12493
 
12494
    @Override
12495
    public int hashCode() {
12496
      return 0;
12497
    }
12498
 
3010 chandransh 12499
    public int compareTo(capturePayment_result other) {
2690 chandransh 12500
      if (!getClass().equals(other.getClass())) {
12501
        return getClass().getName().compareTo(other.getClass().getName());
12502
      }
12503
 
12504
      int lastComparison = 0;
3010 chandransh 12505
      capturePayment_result typedOther = (capturePayment_result)other;
2690 chandransh 12506
 
3430 rajveer 12507
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2690 chandransh 12508
      if (lastComparison != 0) {
12509
        return lastComparison;
12510
      }
3430 rajveer 12511
      if (isSetSuccess()) {
12512
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12513
        if (lastComparison != 0) {
12514
          return lastComparison;
12515
        }
2690 chandransh 12516
      }
3430 rajveer 12517
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
2690 chandransh 12518
      if (lastComparison != 0) {
12519
        return lastComparison;
12520
      }
3430 rajveer 12521
      if (isSetPe()) {
12522
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
12523
        if (lastComparison != 0) {
12524
          return lastComparison;
12525
        }
2690 chandransh 12526
      }
12527
      return 0;
12528
    }
12529
 
3430 rajveer 12530
    public _Fields fieldForId(int fieldId) {
12531
      return _Fields.findByThriftId(fieldId);
12532
    }
12533
 
12534
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12535
      org.apache.thrift.protocol.TField field;
2690 chandransh 12536
      iprot.readStructBegin();
12537
      while (true)
12538
      {
12539
        field = iprot.readFieldBegin();
3430 rajveer 12540
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2690 chandransh 12541
          break;
12542
        }
3430 rajveer 12543
        switch (field.id) {
12544
          case 0: // SUCCESS
12545
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
12546
              this.success = iprot.readBool();
12547
              setSuccessIsSet(true);
12548
            } else { 
12549
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12550
            }
12551
            break;
12552
          case 1: // PE
12553
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
12554
              this.pe = new PaymentException();
12555
              this.pe.read(iprot);
12556
            } else { 
12557
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12558
            }
12559
            break;
12560
          default:
12561
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2690 chandransh 12562
        }
3430 rajveer 12563
        iprot.readFieldEnd();
2690 chandransh 12564
      }
12565
      iprot.readStructEnd();
12566
      validate();
12567
    }
12568
 
3430 rajveer 12569
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2690 chandransh 12570
      oprot.writeStructBegin(STRUCT_DESC);
12571
 
12572
      if (this.isSetSuccess()) {
12573
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3010 chandransh 12574
        oprot.writeBool(this.success);
2690 chandransh 12575
        oprot.writeFieldEnd();
12576
      } else if (this.isSetPe()) {
12577
        oprot.writeFieldBegin(PE_FIELD_DESC);
12578
        this.pe.write(oprot);
12579
        oprot.writeFieldEnd();
12580
      }
12581
      oprot.writeFieldStop();
12582
      oprot.writeStructEnd();
12583
    }
12584
 
12585
    @Override
12586
    public String toString() {
3010 chandransh 12587
      StringBuilder sb = new StringBuilder("capturePayment_result(");
2690 chandransh 12588
      boolean first = true;
12589
 
12590
      sb.append("success:");
12591
      sb.append(this.success);
12592
      first = false;
12593
      if (!first) sb.append(", ");
12594
      sb.append("pe:");
12595
      if (this.pe == null) {
12596
        sb.append("null");
12597
      } else {
12598
        sb.append(this.pe);
12599
      }
12600
      first = false;
12601
      sb.append(")");
12602
      return sb.toString();
12603
    }
12604
 
3430 rajveer 12605
    public void validate() throws org.apache.thrift.TException {
2690 chandransh 12606
      // check for required fields
12607
    }
12608
 
3430 rajveer 12609
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12610
      try {
12611
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12612
      } catch (org.apache.thrift.TException te) {
12613
        throw new java.io.IOException(te);
12614
      }
12615
    }
12616
 
12617
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12618
      try {
12619
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12620
      } catch (org.apache.thrift.TException te) {
12621
        throw new java.io.IOException(te);
12622
      }
12623
    }
12624
 
2690 chandransh 12625
  }
12626
 
3956 chandransh 12627
  public static class partiallyCapturePayment_args implements org.apache.thrift.TBase<partiallyCapturePayment_args, partiallyCapturePayment_args._Fields>, java.io.Serializable, Cloneable   {
12628
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("partiallyCapturePayment_args");
12629
 
12630
    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);
12631
    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);
12632
    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);
12633
    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);
12634
    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);
12635
 
12636
    private long merchantTxnId; // required
12637
    private double amount; // required
12638
    private String xferBy; // required
12639
    private String xferTxnId; // required
12640
    private long xferDate; // required
12641
 
12642
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12643
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12644
      MERCHANT_TXN_ID((short)1, "merchantTxnId"),
12645
      AMOUNT((short)2, "amount"),
12646
      XFER_BY((short)3, "xferBy"),
12647
      XFER_TXN_ID((short)4, "xferTxnId"),
12648
      XFER_DATE((short)5, "xferDate");
12649
 
12650
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12651
 
12652
      static {
12653
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12654
          byName.put(field.getFieldName(), field);
12655
        }
12656
      }
12657
 
12658
      /**
12659
       * Find the _Fields constant that matches fieldId, or null if its not found.
12660
       */
12661
      public static _Fields findByThriftId(int fieldId) {
12662
        switch(fieldId) {
12663
          case 1: // MERCHANT_TXN_ID
12664
            return MERCHANT_TXN_ID;
12665
          case 2: // AMOUNT
12666
            return AMOUNT;
12667
          case 3: // XFER_BY
12668
            return XFER_BY;
12669
          case 4: // XFER_TXN_ID
12670
            return XFER_TXN_ID;
12671
          case 5: // XFER_DATE
12672
            return XFER_DATE;
12673
          default:
12674
            return null;
12675
        }
12676
      }
12677
 
12678
      /**
12679
       * Find the _Fields constant that matches fieldId, throwing an exception
12680
       * if it is not found.
12681
       */
12682
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12683
        _Fields fields = findByThriftId(fieldId);
12684
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12685
        return fields;
12686
      }
12687
 
12688
      /**
12689
       * Find the _Fields constant that matches name, or null if its not found.
12690
       */
12691
      public static _Fields findByName(String name) {
12692
        return byName.get(name);
12693
      }
12694
 
12695
      private final short _thriftId;
12696
      private final String _fieldName;
12697
 
12698
      _Fields(short thriftId, String fieldName) {
12699
        _thriftId = thriftId;
12700
        _fieldName = fieldName;
12701
      }
12702
 
12703
      public short getThriftFieldId() {
12704
        return _thriftId;
12705
      }
12706
 
12707
      public String getFieldName() {
12708
        return _fieldName;
12709
      }
12710
    }
12711
 
12712
    // isset id assignments
12713
    private static final int __MERCHANTTXNID_ISSET_ID = 0;
12714
    private static final int __AMOUNT_ISSET_ID = 1;
12715
    private static final int __XFERDATE_ISSET_ID = 2;
12716
    private BitSet __isset_bit_vector = new BitSet(3);
12717
 
12718
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12719
    static {
12720
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12721
      tmpMap.put(_Fields.MERCHANT_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("merchantTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12722
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12723
      tmpMap.put(_Fields.AMOUNT, new org.apache.thrift.meta_data.FieldMetaData("amount", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12724
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
12725
      tmpMap.put(_Fields.XFER_BY, new org.apache.thrift.meta_data.FieldMetaData("xferBy", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12726
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
12727
      tmpMap.put(_Fields.XFER_TXN_ID, new org.apache.thrift.meta_data.FieldMetaData("xferTxnId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12728
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
12729
      tmpMap.put(_Fields.XFER_DATE, new org.apache.thrift.meta_data.FieldMetaData("xferDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12730
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12731
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12732
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(partiallyCapturePayment_args.class, metaDataMap);
12733
    }
12734
 
12735
    public partiallyCapturePayment_args() {
12736
    }
12737
 
12738
    public partiallyCapturePayment_args(
12739
      long merchantTxnId,
12740
      double amount,
12741
      String xferBy,
12742
      String xferTxnId,
12743
      long xferDate)
12744
    {
12745
      this();
12746
      this.merchantTxnId = merchantTxnId;
12747
      setMerchantTxnIdIsSet(true);
12748
      this.amount = amount;
12749
      setAmountIsSet(true);
12750
      this.xferBy = xferBy;
12751
      this.xferTxnId = xferTxnId;
12752
      this.xferDate = xferDate;
12753
      setXferDateIsSet(true);
12754
    }
12755
 
12756
    /**
12757
     * Performs a deep copy on <i>other</i>.
12758
     */
12759
    public partiallyCapturePayment_args(partiallyCapturePayment_args other) {
12760
      __isset_bit_vector.clear();
12761
      __isset_bit_vector.or(other.__isset_bit_vector);
12762
      this.merchantTxnId = other.merchantTxnId;
12763
      this.amount = other.amount;
12764
      if (other.isSetXferBy()) {
12765
        this.xferBy = other.xferBy;
12766
      }
12767
      if (other.isSetXferTxnId()) {
12768
        this.xferTxnId = other.xferTxnId;
12769
      }
12770
      this.xferDate = other.xferDate;
12771
    }
12772
 
12773
    public partiallyCapturePayment_args deepCopy() {
12774
      return new partiallyCapturePayment_args(this);
12775
    }
12776
 
12777
    @Override
12778
    public void clear() {
12779
      setMerchantTxnIdIsSet(false);
12780
      this.merchantTxnId = 0;
12781
      setAmountIsSet(false);
12782
      this.amount = 0.0;
12783
      this.xferBy = null;
12784
      this.xferTxnId = null;
12785
      setXferDateIsSet(false);
12786
      this.xferDate = 0;
12787
    }
12788
 
12789
    public long getMerchantTxnId() {
12790
      return this.merchantTxnId;
12791
    }
12792
 
12793
    public void setMerchantTxnId(long merchantTxnId) {
12794
      this.merchantTxnId = merchantTxnId;
12795
      setMerchantTxnIdIsSet(true);
12796
    }
12797
 
12798
    public void unsetMerchantTxnId() {
12799
      __isset_bit_vector.clear(__MERCHANTTXNID_ISSET_ID);
12800
    }
12801
 
12802
    /** Returns true if field merchantTxnId is set (has been assigned a value) and false otherwise */
12803
    public boolean isSetMerchantTxnId() {
12804
      return __isset_bit_vector.get(__MERCHANTTXNID_ISSET_ID);
12805
    }
12806
 
12807
    public void setMerchantTxnIdIsSet(boolean value) {
12808
      __isset_bit_vector.set(__MERCHANTTXNID_ISSET_ID, value);
12809
    }
12810
 
12811
    public double getAmount() {
12812
      return this.amount;
12813
    }
12814
 
12815
    public void setAmount(double amount) {
12816
      this.amount = amount;
12817
      setAmountIsSet(true);
12818
    }
12819
 
12820
    public void unsetAmount() {
12821
      __isset_bit_vector.clear(__AMOUNT_ISSET_ID);
12822
    }
12823
 
12824
    /** Returns true if field amount is set (has been assigned a value) and false otherwise */
12825
    public boolean isSetAmount() {
12826
      return __isset_bit_vector.get(__AMOUNT_ISSET_ID);
12827
    }
12828
 
12829
    public void setAmountIsSet(boolean value) {
12830
      __isset_bit_vector.set(__AMOUNT_ISSET_ID, value);
12831
    }
12832
 
12833
    public String getXferBy() {
12834
      return this.xferBy;
12835
    }
12836
 
12837
    public void setXferBy(String xferBy) {
12838
      this.xferBy = xferBy;
12839
    }
12840
 
12841
    public void unsetXferBy() {
12842
      this.xferBy = null;
12843
    }
12844
 
12845
    /** Returns true if field xferBy is set (has been assigned a value) and false otherwise */
12846
    public boolean isSetXferBy() {
12847
      return this.xferBy != null;
12848
    }
12849
 
12850
    public void setXferByIsSet(boolean value) {
12851
      if (!value) {
12852
        this.xferBy = null;
12853
      }
12854
    }
12855
 
12856
    public String getXferTxnId() {
12857
      return this.xferTxnId;
12858
    }
12859
 
12860
    public void setXferTxnId(String xferTxnId) {
12861
      this.xferTxnId = xferTxnId;
12862
    }
12863
 
12864
    public void unsetXferTxnId() {
12865
      this.xferTxnId = null;
12866
    }
12867
 
12868
    /** Returns true if field xferTxnId is set (has been assigned a value) and false otherwise */
12869
    public boolean isSetXferTxnId() {
12870
      return this.xferTxnId != null;
12871
    }
12872
 
12873
    public void setXferTxnIdIsSet(boolean value) {
12874
      if (!value) {
12875
        this.xferTxnId = null;
12876
      }
12877
    }
12878
 
12879
    public long getXferDate() {
12880
      return this.xferDate;
12881
    }
12882
 
12883
    public void setXferDate(long xferDate) {
12884
      this.xferDate = xferDate;
12885
      setXferDateIsSet(true);
12886
    }
12887
 
12888
    public void unsetXferDate() {
12889
      __isset_bit_vector.clear(__XFERDATE_ISSET_ID);
12890
    }
12891
 
12892
    /** Returns true if field xferDate is set (has been assigned a value) and false otherwise */
12893
    public boolean isSetXferDate() {
12894
      return __isset_bit_vector.get(__XFERDATE_ISSET_ID);
12895
    }
12896
 
12897
    public void setXferDateIsSet(boolean value) {
12898
      __isset_bit_vector.set(__XFERDATE_ISSET_ID, value);
12899
    }
12900
 
12901
    public void setFieldValue(_Fields field, Object value) {
12902
      switch (field) {
12903
      case MERCHANT_TXN_ID:
12904
        if (value == null) {
12905
          unsetMerchantTxnId();
12906
        } else {
12907
          setMerchantTxnId((Long)value);
12908
        }
12909
        break;
12910
 
12911
      case AMOUNT:
12912
        if (value == null) {
12913
          unsetAmount();
12914
        } else {
12915
          setAmount((Double)value);
12916
        }
12917
        break;
12918
 
12919
      case XFER_BY:
12920
        if (value == null) {
12921
          unsetXferBy();
12922
        } else {
12923
          setXferBy((String)value);
12924
        }
12925
        break;
12926
 
12927
      case XFER_TXN_ID:
12928
        if (value == null) {
12929
          unsetXferTxnId();
12930
        } else {
12931
          setXferTxnId((String)value);
12932
        }
12933
        break;
12934
 
12935
      case XFER_DATE:
12936
        if (value == null) {
12937
          unsetXferDate();
12938
        } else {
12939
          setXferDate((Long)value);
12940
        }
12941
        break;
12942
 
12943
      }
12944
    }
12945
 
12946
    public Object getFieldValue(_Fields field) {
12947
      switch (field) {
12948
      case MERCHANT_TXN_ID:
12949
        return Long.valueOf(getMerchantTxnId());
12950
 
12951
      case AMOUNT:
12952
        return Double.valueOf(getAmount());
12953
 
12954
      case XFER_BY:
12955
        return getXferBy();
12956
 
12957
      case XFER_TXN_ID:
12958
        return getXferTxnId();
12959
 
12960
      case XFER_DATE:
12961
        return Long.valueOf(getXferDate());
12962
 
12963
      }
12964
      throw new IllegalStateException();
12965
    }
12966
 
12967
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12968
    public boolean isSet(_Fields field) {
12969
      if (field == null) {
12970
        throw new IllegalArgumentException();
12971
      }
12972
 
12973
      switch (field) {
12974
      case MERCHANT_TXN_ID:
12975
        return isSetMerchantTxnId();
12976
      case AMOUNT:
12977
        return isSetAmount();
12978
      case XFER_BY:
12979
        return isSetXferBy();
12980
      case XFER_TXN_ID:
12981
        return isSetXferTxnId();
12982
      case XFER_DATE:
12983
        return isSetXferDate();
12984
      }
12985
      throw new IllegalStateException();
12986
    }
12987
 
12988
    @Override
12989
    public boolean equals(Object that) {
12990
      if (that == null)
12991
        return false;
12992
      if (that instanceof partiallyCapturePayment_args)
12993
        return this.equals((partiallyCapturePayment_args)that);
12994
      return false;
12995
    }
12996
 
12997
    public boolean equals(partiallyCapturePayment_args that) {
12998
      if (that == null)
12999
        return false;
13000
 
13001
      boolean this_present_merchantTxnId = true;
13002
      boolean that_present_merchantTxnId = true;
13003
      if (this_present_merchantTxnId || that_present_merchantTxnId) {
13004
        if (!(this_present_merchantTxnId && that_present_merchantTxnId))
13005
          return false;
13006
        if (this.merchantTxnId != that.merchantTxnId)
13007
          return false;
13008
      }
13009
 
13010
      boolean this_present_amount = true;
13011
      boolean that_present_amount = true;
13012
      if (this_present_amount || that_present_amount) {
13013
        if (!(this_present_amount && that_present_amount))
13014
          return false;
13015
        if (this.amount != that.amount)
13016
          return false;
13017
      }
13018
 
13019
      boolean this_present_xferBy = true && this.isSetXferBy();
13020
      boolean that_present_xferBy = true && that.isSetXferBy();
13021
      if (this_present_xferBy || that_present_xferBy) {
13022
        if (!(this_present_xferBy && that_present_xferBy))
13023
          return false;
13024
        if (!this.xferBy.equals(that.xferBy))
13025
          return false;
13026
      }
13027
 
13028
      boolean this_present_xferTxnId = true && this.isSetXferTxnId();
13029
      boolean that_present_xferTxnId = true && that.isSetXferTxnId();
13030
      if (this_present_xferTxnId || that_present_xferTxnId) {
13031
        if (!(this_present_xferTxnId && that_present_xferTxnId))
13032
          return false;
13033
        if (!this.xferTxnId.equals(that.xferTxnId))
13034
          return false;
13035
      }
13036
 
13037
      boolean this_present_xferDate = true;
13038
      boolean that_present_xferDate = true;
13039
      if (this_present_xferDate || that_present_xferDate) {
13040
        if (!(this_present_xferDate && that_present_xferDate))
13041
          return false;
13042
        if (this.xferDate != that.xferDate)
13043
          return false;
13044
      }
13045
 
13046
      return true;
13047
    }
13048
 
13049
    @Override
13050
    public int hashCode() {
13051
      return 0;
13052
    }
13053
 
13054
    public int compareTo(partiallyCapturePayment_args other) {
13055
      if (!getClass().equals(other.getClass())) {
13056
        return getClass().getName().compareTo(other.getClass().getName());
13057
      }
13058
 
13059
      int lastComparison = 0;
13060
      partiallyCapturePayment_args typedOther = (partiallyCapturePayment_args)other;
13061
 
13062
      lastComparison = Boolean.valueOf(isSetMerchantTxnId()).compareTo(typedOther.isSetMerchantTxnId());
13063
      if (lastComparison != 0) {
13064
        return lastComparison;
13065
      }
13066
      if (isSetMerchantTxnId()) {
13067
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.merchantTxnId, typedOther.merchantTxnId);
13068
        if (lastComparison != 0) {
13069
          return lastComparison;
13070
        }
13071
      }
13072
      lastComparison = Boolean.valueOf(isSetAmount()).compareTo(typedOther.isSetAmount());
13073
      if (lastComparison != 0) {
13074
        return lastComparison;
13075
      }
13076
      if (isSetAmount()) {
13077
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.amount, typedOther.amount);
13078
        if (lastComparison != 0) {
13079
          return lastComparison;
13080
        }
13081
      }
13082
      lastComparison = Boolean.valueOf(isSetXferBy()).compareTo(typedOther.isSetXferBy());
13083
      if (lastComparison != 0) {
13084
        return lastComparison;
13085
      }
13086
      if (isSetXferBy()) {
13087
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferBy, typedOther.xferBy);
13088
        if (lastComparison != 0) {
13089
          return lastComparison;
13090
        }
13091
      }
13092
      lastComparison = Boolean.valueOf(isSetXferTxnId()).compareTo(typedOther.isSetXferTxnId());
13093
      if (lastComparison != 0) {
13094
        return lastComparison;
13095
      }
13096
      if (isSetXferTxnId()) {
13097
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferTxnId, typedOther.xferTxnId);
13098
        if (lastComparison != 0) {
13099
          return lastComparison;
13100
        }
13101
      }
13102
      lastComparison = Boolean.valueOf(isSetXferDate()).compareTo(typedOther.isSetXferDate());
13103
      if (lastComparison != 0) {
13104
        return lastComparison;
13105
      }
13106
      if (isSetXferDate()) {
13107
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.xferDate, typedOther.xferDate);
13108
        if (lastComparison != 0) {
13109
          return lastComparison;
13110
        }
13111
      }
13112
      return 0;
13113
    }
13114
 
13115
    public _Fields fieldForId(int fieldId) {
13116
      return _Fields.findByThriftId(fieldId);
13117
    }
13118
 
13119
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13120
      org.apache.thrift.protocol.TField field;
13121
      iprot.readStructBegin();
13122
      while (true)
13123
      {
13124
        field = iprot.readFieldBegin();
13125
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13126
          break;
13127
        }
13128
        switch (field.id) {
13129
          case 1: // MERCHANT_TXN_ID
13130
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13131
              this.merchantTxnId = iprot.readI64();
13132
              setMerchantTxnIdIsSet(true);
13133
            } else { 
13134
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13135
            }
13136
            break;
13137
          case 2: // AMOUNT
13138
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
13139
              this.amount = iprot.readDouble();
13140
              setAmountIsSet(true);
13141
            } else { 
13142
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13143
            }
13144
            break;
13145
          case 3: // XFER_BY
13146
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
13147
              this.xferBy = iprot.readString();
13148
            } else { 
13149
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13150
            }
13151
            break;
13152
          case 4: // XFER_TXN_ID
13153
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
13154
              this.xferTxnId = iprot.readString();
13155
            } else { 
13156
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13157
            }
13158
            break;
13159
          case 5: // XFER_DATE
13160
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13161
              this.xferDate = iprot.readI64();
13162
              setXferDateIsSet(true);
13163
            } else { 
13164
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13165
            }
13166
            break;
13167
          default:
13168
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13169
        }
13170
        iprot.readFieldEnd();
13171
      }
13172
      iprot.readStructEnd();
13173
      validate();
13174
    }
13175
 
13176
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13177
      validate();
13178
 
13179
      oprot.writeStructBegin(STRUCT_DESC);
13180
      oprot.writeFieldBegin(MERCHANT_TXN_ID_FIELD_DESC);
13181
      oprot.writeI64(this.merchantTxnId);
13182
      oprot.writeFieldEnd();
13183
      oprot.writeFieldBegin(AMOUNT_FIELD_DESC);
13184
      oprot.writeDouble(this.amount);
13185
      oprot.writeFieldEnd();
13186
      if (this.xferBy != null) {
13187
        oprot.writeFieldBegin(XFER_BY_FIELD_DESC);
13188
        oprot.writeString(this.xferBy);
13189
        oprot.writeFieldEnd();
13190
      }
13191
      if (this.xferTxnId != null) {
13192
        oprot.writeFieldBegin(XFER_TXN_ID_FIELD_DESC);
13193
        oprot.writeString(this.xferTxnId);
13194
        oprot.writeFieldEnd();
13195
      }
13196
      oprot.writeFieldBegin(XFER_DATE_FIELD_DESC);
13197
      oprot.writeI64(this.xferDate);
13198
      oprot.writeFieldEnd();
13199
      oprot.writeFieldStop();
13200
      oprot.writeStructEnd();
13201
    }
13202
 
13203
    @Override
13204
    public String toString() {
13205
      StringBuilder sb = new StringBuilder("partiallyCapturePayment_args(");
13206
      boolean first = true;
13207
 
13208
      sb.append("merchantTxnId:");
13209
      sb.append(this.merchantTxnId);
13210
      first = false;
13211
      if (!first) sb.append(", ");
13212
      sb.append("amount:");
13213
      sb.append(this.amount);
13214
      first = false;
13215
      if (!first) sb.append(", ");
13216
      sb.append("xferBy:");
13217
      if (this.xferBy == null) {
13218
        sb.append("null");
13219
      } else {
13220
        sb.append(this.xferBy);
13221
      }
13222
      first = false;
13223
      if (!first) sb.append(", ");
13224
      sb.append("xferTxnId:");
13225
      if (this.xferTxnId == null) {
13226
        sb.append("null");
13227
      } else {
13228
        sb.append(this.xferTxnId);
13229
      }
13230
      first = false;
13231
      if (!first) sb.append(", ");
13232
      sb.append("xferDate:");
13233
      sb.append(this.xferDate);
13234
      first = false;
13235
      sb.append(")");
13236
      return sb.toString();
13237
    }
13238
 
13239
    public void validate() throws org.apache.thrift.TException {
13240
      // check for required fields
13241
    }
13242
 
13243
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13244
      try {
13245
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13246
      } catch (org.apache.thrift.TException te) {
13247
        throw new java.io.IOException(te);
13248
      }
13249
    }
13250
 
13251
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13252
      try {
13253
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13254
      } catch (org.apache.thrift.TException te) {
13255
        throw new java.io.IOException(te);
13256
      }
13257
    }
13258
 
13259
  }
13260
 
13261
  public static class partiallyCapturePayment_result implements org.apache.thrift.TBase<partiallyCapturePayment_result, partiallyCapturePayment_result._Fields>, java.io.Serializable, Cloneable   {
13262
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("partiallyCapturePayment_result");
13263
 
13264
    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);
13265
    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);
13266
 
13267
    private boolean success; // required
13268
    private PaymentException pe; // required
13269
 
13270
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13271
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13272
      SUCCESS((short)0, "success"),
13273
      PE((short)1, "pe");
13274
 
13275
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13276
 
13277
      static {
13278
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13279
          byName.put(field.getFieldName(), field);
13280
        }
13281
      }
13282
 
13283
      /**
13284
       * Find the _Fields constant that matches fieldId, or null if its not found.
13285
       */
13286
      public static _Fields findByThriftId(int fieldId) {
13287
        switch(fieldId) {
13288
          case 0: // SUCCESS
13289
            return SUCCESS;
13290
          case 1: // PE
13291
            return PE;
13292
          default:
13293
            return null;
13294
        }
13295
      }
13296
 
13297
      /**
13298
       * Find the _Fields constant that matches fieldId, throwing an exception
13299
       * if it is not found.
13300
       */
13301
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13302
        _Fields fields = findByThriftId(fieldId);
13303
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13304
        return fields;
13305
      }
13306
 
13307
      /**
13308
       * Find the _Fields constant that matches name, or null if its not found.
13309
       */
13310
      public static _Fields findByName(String name) {
13311
        return byName.get(name);
13312
      }
13313
 
13314
      private final short _thriftId;
13315
      private final String _fieldName;
13316
 
13317
      _Fields(short thriftId, String fieldName) {
13318
        _thriftId = thriftId;
13319
        _fieldName = fieldName;
13320
      }
13321
 
13322
      public short getThriftFieldId() {
13323
        return _thriftId;
13324
      }
13325
 
13326
      public String getFieldName() {
13327
        return _fieldName;
13328
      }
13329
    }
13330
 
13331
    // isset id assignments
13332
    private static final int __SUCCESS_ISSET_ID = 0;
13333
    private BitSet __isset_bit_vector = new BitSet(1);
13334
 
13335
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13336
    static {
13337
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13338
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13339
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
13340
      tmpMap.put(_Fields.PE, new org.apache.thrift.meta_data.FieldMetaData("pe", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13341
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
13342
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13343
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(partiallyCapturePayment_result.class, metaDataMap);
13344
    }
13345
 
13346
    public partiallyCapturePayment_result() {
13347
    }
13348
 
13349
    public partiallyCapturePayment_result(
13350
      boolean success,
13351
      PaymentException pe)
13352
    {
13353
      this();
13354
      this.success = success;
13355
      setSuccessIsSet(true);
13356
      this.pe = pe;
13357
    }
13358
 
13359
    /**
13360
     * Performs a deep copy on <i>other</i>.
13361
     */
13362
    public partiallyCapturePayment_result(partiallyCapturePayment_result other) {
13363
      __isset_bit_vector.clear();
13364
      __isset_bit_vector.or(other.__isset_bit_vector);
13365
      this.success = other.success;
13366
      if (other.isSetPe()) {
13367
        this.pe = new PaymentException(other.pe);
13368
      }
13369
    }
13370
 
13371
    public partiallyCapturePayment_result deepCopy() {
13372
      return new partiallyCapturePayment_result(this);
13373
    }
13374
 
13375
    @Override
13376
    public void clear() {
13377
      setSuccessIsSet(false);
13378
      this.success = false;
13379
      this.pe = null;
13380
    }
13381
 
13382
    public boolean isSuccess() {
13383
      return this.success;
13384
    }
13385
 
13386
    public void setSuccess(boolean success) {
13387
      this.success = success;
13388
      setSuccessIsSet(true);
13389
    }
13390
 
13391
    public void unsetSuccess() {
13392
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
13393
    }
13394
 
13395
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13396
    public boolean isSetSuccess() {
13397
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
13398
    }
13399
 
13400
    public void setSuccessIsSet(boolean value) {
13401
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
13402
    }
13403
 
13404
    public PaymentException getPe() {
13405
      return this.pe;
13406
    }
13407
 
13408
    public void setPe(PaymentException pe) {
13409
      this.pe = pe;
13410
    }
13411
 
13412
    public void unsetPe() {
13413
      this.pe = null;
13414
    }
13415
 
13416
    /** Returns true if field pe is set (has been assigned a value) and false otherwise */
13417
    public boolean isSetPe() {
13418
      return this.pe != null;
13419
    }
13420
 
13421
    public void setPeIsSet(boolean value) {
13422
      if (!value) {
13423
        this.pe = null;
13424
      }
13425
    }
13426
 
13427
    public void setFieldValue(_Fields field, Object value) {
13428
      switch (field) {
13429
      case SUCCESS:
13430
        if (value == null) {
13431
          unsetSuccess();
13432
        } else {
13433
          setSuccess((Boolean)value);
13434
        }
13435
        break;
13436
 
13437
      case PE:
13438
        if (value == null) {
13439
          unsetPe();
13440
        } else {
13441
          setPe((PaymentException)value);
13442
        }
13443
        break;
13444
 
13445
      }
13446
    }
13447
 
13448
    public Object getFieldValue(_Fields field) {
13449
      switch (field) {
13450
      case SUCCESS:
13451
        return Boolean.valueOf(isSuccess());
13452
 
13453
      case PE:
13454
        return getPe();
13455
 
13456
      }
13457
      throw new IllegalStateException();
13458
    }
13459
 
13460
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13461
    public boolean isSet(_Fields field) {
13462
      if (field == null) {
13463
        throw new IllegalArgumentException();
13464
      }
13465
 
13466
      switch (field) {
13467
      case SUCCESS:
13468
        return isSetSuccess();
13469
      case PE:
13470
        return isSetPe();
13471
      }
13472
      throw new IllegalStateException();
13473
    }
13474
 
13475
    @Override
13476
    public boolean equals(Object that) {
13477
      if (that == null)
13478
        return false;
13479
      if (that instanceof partiallyCapturePayment_result)
13480
        return this.equals((partiallyCapturePayment_result)that);
13481
      return false;
13482
    }
13483
 
13484
    public boolean equals(partiallyCapturePayment_result that) {
13485
      if (that == null)
13486
        return false;
13487
 
13488
      boolean this_present_success = true;
13489
      boolean that_present_success = true;
13490
      if (this_present_success || that_present_success) {
13491
        if (!(this_present_success && that_present_success))
13492
          return false;
13493
        if (this.success != that.success)
13494
          return false;
13495
      }
13496
 
13497
      boolean this_present_pe = true && this.isSetPe();
13498
      boolean that_present_pe = true && that.isSetPe();
13499
      if (this_present_pe || that_present_pe) {
13500
        if (!(this_present_pe && that_present_pe))
13501
          return false;
13502
        if (!this.pe.equals(that.pe))
13503
          return false;
13504
      }
13505
 
13506
      return true;
13507
    }
13508
 
13509
    @Override
13510
    public int hashCode() {
13511
      return 0;
13512
    }
13513
 
13514
    public int compareTo(partiallyCapturePayment_result other) {
13515
      if (!getClass().equals(other.getClass())) {
13516
        return getClass().getName().compareTo(other.getClass().getName());
13517
      }
13518
 
13519
      int lastComparison = 0;
13520
      partiallyCapturePayment_result typedOther = (partiallyCapturePayment_result)other;
13521
 
13522
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13523
      if (lastComparison != 0) {
13524
        return lastComparison;
13525
      }
13526
      if (isSetSuccess()) {
13527
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13528
        if (lastComparison != 0) {
13529
          return lastComparison;
13530
        }
13531
      }
13532
      lastComparison = Boolean.valueOf(isSetPe()).compareTo(typedOther.isSetPe());
13533
      if (lastComparison != 0) {
13534
        return lastComparison;
13535
      }
13536
      if (isSetPe()) {
13537
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pe, typedOther.pe);
13538
        if (lastComparison != 0) {
13539
          return lastComparison;
13540
        }
13541
      }
13542
      return 0;
13543
    }
13544
 
13545
    public _Fields fieldForId(int fieldId) {
13546
      return _Fields.findByThriftId(fieldId);
13547
    }
13548
 
13549
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13550
      org.apache.thrift.protocol.TField field;
13551
      iprot.readStructBegin();
13552
      while (true)
13553
      {
13554
        field = iprot.readFieldBegin();
13555
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13556
          break;
13557
        }
13558
        switch (field.id) {
13559
          case 0: // SUCCESS
13560
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
13561
              this.success = iprot.readBool();
13562
              setSuccessIsSet(true);
13563
            } else { 
13564
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13565
            }
13566
            break;
13567
          case 1: // PE
13568
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13569
              this.pe = new PaymentException();
13570
              this.pe.read(iprot);
13571
            } else { 
13572
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13573
            }
13574
            break;
13575
          default:
13576
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13577
        }
13578
        iprot.readFieldEnd();
13579
      }
13580
      iprot.readStructEnd();
13581
      validate();
13582
    }
13583
 
13584
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13585
      oprot.writeStructBegin(STRUCT_DESC);
13586
 
13587
      if (this.isSetSuccess()) {
13588
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13589
        oprot.writeBool(this.success);
13590
        oprot.writeFieldEnd();
13591
      } else if (this.isSetPe()) {
13592
        oprot.writeFieldBegin(PE_FIELD_DESC);
13593
        this.pe.write(oprot);
13594
        oprot.writeFieldEnd();
13595
      }
13596
      oprot.writeFieldStop();
13597
      oprot.writeStructEnd();
13598
    }
13599
 
13600
    @Override
13601
    public String toString() {
13602
      StringBuilder sb = new StringBuilder("partiallyCapturePayment_result(");
13603
      boolean first = true;
13604
 
13605
      sb.append("success:");
13606
      sb.append(this.success);
13607
      first = false;
13608
      if (!first) sb.append(", ");
13609
      sb.append("pe:");
13610
      if (this.pe == null) {
13611
        sb.append("null");
13612
      } else {
13613
        sb.append(this.pe);
13614
      }
13615
      first = false;
13616
      sb.append(")");
13617
      return sb.toString();
13618
    }
13619
 
13620
    public void validate() throws org.apache.thrift.TException {
13621
      // check for required fields
13622
    }
13623
 
13624
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13625
      try {
13626
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13627
      } catch (org.apache.thrift.TException te) {
13628
        throw new java.io.IOException(te);
13629
      }
13630
    }
13631
 
13632
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13633
      try {
13634
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13635
      } catch (org.apache.thrift.TException te) {
13636
        throw new java.io.IOException(te);
13637
      }
13638
    }
13639
 
13640
  }
13641
 
4008 mandeep.dh 13642
  public static class getPaymentsRequiringExtraProcessing_args implements org.apache.thrift.TBase<getPaymentsRequiringExtraProcessing_args, getPaymentsRequiringExtraProcessing_args._Fields>, java.io.Serializable, Cloneable   {
13643
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsRequiringExtraProcessing_args");
13644
 
13645
    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);
13646
 
13647
    private ExtraPaymentProcessingType category; // required
13648
 
13649
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13650
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13651
      /**
13652
       * 
13653
       * @see ExtraPaymentProcessingType
13654
       */
13655
      CATEGORY((short)1, "category");
13656
 
13657
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13658
 
13659
      static {
13660
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13661
          byName.put(field.getFieldName(), field);
13662
        }
13663
      }
13664
 
13665
      /**
13666
       * Find the _Fields constant that matches fieldId, or null if its not found.
13667
       */
13668
      public static _Fields findByThriftId(int fieldId) {
13669
        switch(fieldId) {
13670
          case 1: // CATEGORY
13671
            return CATEGORY;
13672
          default:
13673
            return null;
13674
        }
13675
      }
13676
 
13677
      /**
13678
       * Find the _Fields constant that matches fieldId, throwing an exception
13679
       * if it is not found.
13680
       */
13681
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13682
        _Fields fields = findByThriftId(fieldId);
13683
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13684
        return fields;
13685
      }
13686
 
13687
      /**
13688
       * Find the _Fields constant that matches name, or null if its not found.
13689
       */
13690
      public static _Fields findByName(String name) {
13691
        return byName.get(name);
13692
      }
13693
 
13694
      private final short _thriftId;
13695
      private final String _fieldName;
13696
 
13697
      _Fields(short thriftId, String fieldName) {
13698
        _thriftId = thriftId;
13699
        _fieldName = fieldName;
13700
      }
13701
 
13702
      public short getThriftFieldId() {
13703
        return _thriftId;
13704
      }
13705
 
13706
      public String getFieldName() {
13707
        return _fieldName;
13708
      }
13709
    }
13710
 
13711
    // isset id assignments
13712
 
13713
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13714
    static {
13715
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13716
      tmpMap.put(_Fields.CATEGORY, new org.apache.thrift.meta_data.FieldMetaData("category", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13717
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ExtraPaymentProcessingType.class)));
13718
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13719
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsRequiringExtraProcessing_args.class, metaDataMap);
13720
    }
13721
 
13722
    public getPaymentsRequiringExtraProcessing_args() {
13723
    }
13724
 
13725
    public getPaymentsRequiringExtraProcessing_args(
13726
      ExtraPaymentProcessingType category)
13727
    {
13728
      this();
13729
      this.category = category;
13730
    }
13731
 
13732
    /**
13733
     * Performs a deep copy on <i>other</i>.
13734
     */
13735
    public getPaymentsRequiringExtraProcessing_args(getPaymentsRequiringExtraProcessing_args other) {
13736
      if (other.isSetCategory()) {
13737
        this.category = other.category;
13738
      }
13739
    }
13740
 
13741
    public getPaymentsRequiringExtraProcessing_args deepCopy() {
13742
      return new getPaymentsRequiringExtraProcessing_args(this);
13743
    }
13744
 
13745
    @Override
13746
    public void clear() {
13747
      this.category = null;
13748
    }
13749
 
13750
    /**
13751
     * 
13752
     * @see ExtraPaymentProcessingType
13753
     */
13754
    public ExtraPaymentProcessingType getCategory() {
13755
      return this.category;
13756
    }
13757
 
13758
    /**
13759
     * 
13760
     * @see ExtraPaymentProcessingType
13761
     */
13762
    public void setCategory(ExtraPaymentProcessingType category) {
13763
      this.category = category;
13764
    }
13765
 
13766
    public void unsetCategory() {
13767
      this.category = null;
13768
    }
13769
 
13770
    /** Returns true if field category is set (has been assigned a value) and false otherwise */
13771
    public boolean isSetCategory() {
13772
      return this.category != null;
13773
    }
13774
 
13775
    public void setCategoryIsSet(boolean value) {
13776
      if (!value) {
13777
        this.category = null;
13778
      }
13779
    }
13780
 
13781
    public void setFieldValue(_Fields field, Object value) {
13782
      switch (field) {
13783
      case CATEGORY:
13784
        if (value == null) {
13785
          unsetCategory();
13786
        } else {
13787
          setCategory((ExtraPaymentProcessingType)value);
13788
        }
13789
        break;
13790
 
13791
      }
13792
    }
13793
 
13794
    public Object getFieldValue(_Fields field) {
13795
      switch (field) {
13796
      case CATEGORY:
13797
        return getCategory();
13798
 
13799
      }
13800
      throw new IllegalStateException();
13801
    }
13802
 
13803
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13804
    public boolean isSet(_Fields field) {
13805
      if (field == null) {
13806
        throw new IllegalArgumentException();
13807
      }
13808
 
13809
      switch (field) {
13810
      case CATEGORY:
13811
        return isSetCategory();
13812
      }
13813
      throw new IllegalStateException();
13814
    }
13815
 
13816
    @Override
13817
    public boolean equals(Object that) {
13818
      if (that == null)
13819
        return false;
13820
      if (that instanceof getPaymentsRequiringExtraProcessing_args)
13821
        return this.equals((getPaymentsRequiringExtraProcessing_args)that);
13822
      return false;
13823
    }
13824
 
13825
    public boolean equals(getPaymentsRequiringExtraProcessing_args that) {
13826
      if (that == null)
13827
        return false;
13828
 
13829
      boolean this_present_category = true && this.isSetCategory();
13830
      boolean that_present_category = true && that.isSetCategory();
13831
      if (this_present_category || that_present_category) {
13832
        if (!(this_present_category && that_present_category))
13833
          return false;
13834
        if (!this.category.equals(that.category))
13835
          return false;
13836
      }
13837
 
13838
      return true;
13839
    }
13840
 
13841
    @Override
13842
    public int hashCode() {
13843
      return 0;
13844
    }
13845
 
13846
    public int compareTo(getPaymentsRequiringExtraProcessing_args other) {
13847
      if (!getClass().equals(other.getClass())) {
13848
        return getClass().getName().compareTo(other.getClass().getName());
13849
      }
13850
 
13851
      int lastComparison = 0;
13852
      getPaymentsRequiringExtraProcessing_args typedOther = (getPaymentsRequiringExtraProcessing_args)other;
13853
 
13854
      lastComparison = Boolean.valueOf(isSetCategory()).compareTo(typedOther.isSetCategory());
13855
      if (lastComparison != 0) {
13856
        return lastComparison;
13857
      }
13858
      if (isSetCategory()) {
13859
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.category, typedOther.category);
13860
        if (lastComparison != 0) {
13861
          return lastComparison;
13862
        }
13863
      }
13864
      return 0;
13865
    }
13866
 
13867
    public _Fields fieldForId(int fieldId) {
13868
      return _Fields.findByThriftId(fieldId);
13869
    }
13870
 
13871
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13872
      org.apache.thrift.protocol.TField field;
13873
      iprot.readStructBegin();
13874
      while (true)
13875
      {
13876
        field = iprot.readFieldBegin();
13877
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13878
          break;
13879
        }
13880
        switch (field.id) {
13881
          case 1: // CATEGORY
13882
            if (field.type == org.apache.thrift.protocol.TType.I32) {
13883
              this.category = ExtraPaymentProcessingType.findByValue(iprot.readI32());
13884
            } else { 
13885
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13886
            }
13887
            break;
13888
          default:
13889
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13890
        }
13891
        iprot.readFieldEnd();
13892
      }
13893
      iprot.readStructEnd();
13894
      validate();
13895
    }
13896
 
13897
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13898
      validate();
13899
 
13900
      oprot.writeStructBegin(STRUCT_DESC);
13901
      if (this.category != null) {
13902
        oprot.writeFieldBegin(CATEGORY_FIELD_DESC);
13903
        oprot.writeI32(this.category.getValue());
13904
        oprot.writeFieldEnd();
13905
      }
13906
      oprot.writeFieldStop();
13907
      oprot.writeStructEnd();
13908
    }
13909
 
13910
    @Override
13911
    public String toString() {
13912
      StringBuilder sb = new StringBuilder("getPaymentsRequiringExtraProcessing_args(");
13913
      boolean first = true;
13914
 
13915
      sb.append("category:");
13916
      if (this.category == null) {
13917
        sb.append("null");
13918
      } else {
13919
        sb.append(this.category);
13920
      }
13921
      first = false;
13922
      sb.append(")");
13923
      return sb.toString();
13924
    }
13925
 
13926
    public void validate() throws org.apache.thrift.TException {
13927
      // check for required fields
13928
    }
13929
 
13930
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13931
      try {
13932
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13933
      } catch (org.apache.thrift.TException te) {
13934
        throw new java.io.IOException(te);
13935
      }
13936
    }
13937
 
13938
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13939
      try {
13940
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13941
      } catch (org.apache.thrift.TException te) {
13942
        throw new java.io.IOException(te);
13943
      }
13944
    }
13945
 
13946
  }
13947
 
13948
  public static class getPaymentsRequiringExtraProcessing_result implements org.apache.thrift.TBase<getPaymentsRequiringExtraProcessing_result, getPaymentsRequiringExtraProcessing_result._Fields>, java.io.Serializable, Cloneable   {
13949
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPaymentsRequiringExtraProcessing_result");
13950
 
13951
    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);
13952
 
13953
    private List<Long> success; // required
13954
 
13955
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13956
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13957
      SUCCESS((short)0, "success");
13958
 
13959
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13960
 
13961
      static {
13962
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13963
          byName.put(field.getFieldName(), field);
13964
        }
13965
      }
13966
 
13967
      /**
13968
       * Find the _Fields constant that matches fieldId, or null if its not found.
13969
       */
13970
      public static _Fields findByThriftId(int fieldId) {
13971
        switch(fieldId) {
13972
          case 0: // SUCCESS
13973
            return SUCCESS;
13974
          default:
13975
            return null;
13976
        }
13977
      }
13978
 
13979
      /**
13980
       * Find the _Fields constant that matches fieldId, throwing an exception
13981
       * if it is not found.
13982
       */
13983
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13984
        _Fields fields = findByThriftId(fieldId);
13985
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13986
        return fields;
13987
      }
13988
 
13989
      /**
13990
       * Find the _Fields constant that matches name, or null if its not found.
13991
       */
13992
      public static _Fields findByName(String name) {
13993
        return byName.get(name);
13994
      }
13995
 
13996
      private final short _thriftId;
13997
      private final String _fieldName;
13998
 
13999
      _Fields(short thriftId, String fieldName) {
14000
        _thriftId = thriftId;
14001
        _fieldName = fieldName;
14002
      }
14003
 
14004
      public short getThriftFieldId() {
14005
        return _thriftId;
14006
      }
14007
 
14008
      public String getFieldName() {
14009
        return _fieldName;
14010
      }
14011
    }
14012
 
14013
    // isset id assignments
14014
 
14015
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14016
    static {
14017
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14018
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14019
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
14020
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
14021
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14022
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPaymentsRequiringExtraProcessing_result.class, metaDataMap);
14023
    }
14024
 
14025
    public getPaymentsRequiringExtraProcessing_result() {
14026
    }
14027
 
14028
    public getPaymentsRequiringExtraProcessing_result(
14029
      List<Long> success)
14030
    {
14031
      this();
14032
      this.success = success;
14033
    }
14034
 
14035
    /**
14036
     * Performs a deep copy on <i>other</i>.
14037
     */
14038
    public getPaymentsRequiringExtraProcessing_result(getPaymentsRequiringExtraProcessing_result other) {
14039
      if (other.isSetSuccess()) {
14040
        List<Long> __this__success = new ArrayList<Long>();
14041
        for (Long other_element : other.success) {
14042
          __this__success.add(other_element);
14043
        }
14044
        this.success = __this__success;
14045
      }
14046
    }
14047
 
14048
    public getPaymentsRequiringExtraProcessing_result deepCopy() {
14049
      return new getPaymentsRequiringExtraProcessing_result(this);
14050
    }
14051
 
14052
    @Override
14053
    public void clear() {
14054
      this.success = null;
14055
    }
14056
 
14057
    public int getSuccessSize() {
14058
      return (this.success == null) ? 0 : this.success.size();
14059
    }
14060
 
14061
    public java.util.Iterator<Long> getSuccessIterator() {
14062
      return (this.success == null) ? null : this.success.iterator();
14063
    }
14064
 
14065
    public void addToSuccess(long elem) {
14066
      if (this.success == null) {
14067
        this.success = new ArrayList<Long>();
14068
      }
14069
      this.success.add(elem);
14070
    }
14071
 
14072
    public List<Long> getSuccess() {
14073
      return this.success;
14074
    }
14075
 
14076
    public void setSuccess(List<Long> success) {
14077
      this.success = success;
14078
    }
14079
 
14080
    public void unsetSuccess() {
14081
      this.success = null;
14082
    }
14083
 
14084
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
14085
    public boolean isSetSuccess() {
14086
      return this.success != null;
14087
    }
14088
 
14089
    public void setSuccessIsSet(boolean value) {
14090
      if (!value) {
14091
        this.success = null;
14092
      }
14093
    }
14094
 
14095
    public void setFieldValue(_Fields field, Object value) {
14096
      switch (field) {
14097
      case SUCCESS:
14098
        if (value == null) {
14099
          unsetSuccess();
14100
        } else {
14101
          setSuccess((List<Long>)value);
14102
        }
14103
        break;
14104
 
14105
      }
14106
    }
14107
 
14108
    public Object getFieldValue(_Fields field) {
14109
      switch (field) {
14110
      case SUCCESS:
14111
        return getSuccess();
14112
 
14113
      }
14114
      throw new IllegalStateException();
14115
    }
14116
 
14117
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14118
    public boolean isSet(_Fields field) {
14119
      if (field == null) {
14120
        throw new IllegalArgumentException();
14121
      }
14122
 
14123
      switch (field) {
14124
      case SUCCESS:
14125
        return isSetSuccess();
14126
      }
14127
      throw new IllegalStateException();
14128
    }
14129
 
14130
    @Override
14131
    public boolean equals(Object that) {
14132
      if (that == null)
14133
        return false;
14134
      if (that instanceof getPaymentsRequiringExtraProcessing_result)
14135
        return this.equals((getPaymentsRequiringExtraProcessing_result)that);
14136
      return false;
14137
    }
14138
 
14139
    public boolean equals(getPaymentsRequiringExtraProcessing_result that) {
14140
      if (that == null)
14141
        return false;
14142
 
14143
      boolean this_present_success = true && this.isSetSuccess();
14144
      boolean that_present_success = true && that.isSetSuccess();
14145
      if (this_present_success || that_present_success) {
14146
        if (!(this_present_success && that_present_success))
14147
          return false;
14148
        if (!this.success.equals(that.success))
14149
          return false;
14150
      }
14151
 
14152
      return true;
14153
    }
14154
 
14155
    @Override
14156
    public int hashCode() {
14157
      return 0;
14158
    }
14159
 
14160
    public int compareTo(getPaymentsRequiringExtraProcessing_result other) {
14161
      if (!getClass().equals(other.getClass())) {
14162
        return getClass().getName().compareTo(other.getClass().getName());
14163
      }
14164
 
14165
      int lastComparison = 0;
14166
      getPaymentsRequiringExtraProcessing_result typedOther = (getPaymentsRequiringExtraProcessing_result)other;
14167
 
14168
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
14169
      if (lastComparison != 0) {
14170
        return lastComparison;
14171
      }
14172
      if (isSetSuccess()) {
14173
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14174
        if (lastComparison != 0) {
14175
          return lastComparison;
14176
        }
14177
      }
14178
      return 0;
14179
    }
14180
 
14181
    public _Fields fieldForId(int fieldId) {
14182
      return _Fields.findByThriftId(fieldId);
14183
    }
14184
 
14185
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14186
      org.apache.thrift.protocol.TField field;
14187
      iprot.readStructBegin();
14188
      while (true)
14189
      {
14190
        field = iprot.readFieldBegin();
14191
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14192
          break;
14193
        }
14194
        switch (field.id) {
14195
          case 0: // SUCCESS
14196
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
14197
              {
4141 chandransh 14198
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
14199
                this.success = new ArrayList<Long>(_list36.size);
14200
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
4008 mandeep.dh 14201
                {
4141 chandransh 14202
                  long _elem38; // required
14203
                  _elem38 = iprot.readI64();
14204
                  this.success.add(_elem38);
4008 mandeep.dh 14205
                }
14206
                iprot.readListEnd();
14207
              }
14208
            } else { 
14209
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14210
            }
14211
            break;
14212
          default:
14213
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14214
        }
14215
        iprot.readFieldEnd();
14216
      }
14217
      iprot.readStructEnd();
14218
      validate();
14219
    }
14220
 
14221
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14222
      oprot.writeStructBegin(STRUCT_DESC);
14223
 
14224
      if (this.isSetSuccess()) {
14225
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
14226
        {
14227
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
4141 chandransh 14228
          for (long _iter39 : this.success)
4008 mandeep.dh 14229
          {
4141 chandransh 14230
            oprot.writeI64(_iter39);
4008 mandeep.dh 14231
          }
14232
          oprot.writeListEnd();
14233
        }
14234
        oprot.writeFieldEnd();
14235
      }
14236
      oprot.writeFieldStop();
14237
      oprot.writeStructEnd();
14238
    }
14239
 
14240
    @Override
14241
    public String toString() {
14242
      StringBuilder sb = new StringBuilder("getPaymentsRequiringExtraProcessing_result(");
14243
      boolean first = true;
14244
 
14245
      sb.append("success:");
14246
      if (this.success == null) {
14247
        sb.append("null");
14248
      } else {
14249
        sb.append(this.success);
14250
      }
14251
      first = false;
14252
      sb.append(")");
14253
      return sb.toString();
14254
    }
14255
 
14256
    public void validate() throws org.apache.thrift.TException {
14257
      // check for required fields
14258
    }
14259
 
14260
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14261
      try {
14262
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14263
      } catch (org.apache.thrift.TException te) {
14264
        throw new java.io.IOException(te);
14265
      }
14266
    }
14267
 
14268
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14269
      try {
14270
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14271
      } catch (org.apache.thrift.TException te) {
14272
        throw new java.io.IOException(te);
14273
      }
14274
    }
14275
 
14276
  }
14277
 
14278
  public static class markPaymentAsProcessed_args implements org.apache.thrift.TBase<markPaymentAsProcessed_args, markPaymentAsProcessed_args._Fields>, java.io.Serializable, Cloneable   {
14279
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markPaymentAsProcessed_args");
14280
 
14281
    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);
14282
    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);
14283
 
14284
    private long paymentId; // required
14285
    private ExtraPaymentProcessingType category; // required
14286
 
14287
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14288
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14289
      PAYMENT_ID((short)1, "paymentId"),
14290
      /**
14291
       * 
14292
       * @see ExtraPaymentProcessingType
14293
       */
14294
      CATEGORY((short)2, "category");
14295
 
14296
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14297
 
14298
      static {
14299
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14300
          byName.put(field.getFieldName(), field);
14301
        }
14302
      }
14303
 
14304
      /**
14305
       * Find the _Fields constant that matches fieldId, or null if its not found.
14306
       */
14307
      public static _Fields findByThriftId(int fieldId) {
14308
        switch(fieldId) {
14309
          case 1: // PAYMENT_ID
14310
            return PAYMENT_ID;
14311
          case 2: // CATEGORY
14312
            return CATEGORY;
14313
          default:
14314
            return null;
14315
        }
14316
      }
14317
 
14318
      /**
14319
       * Find the _Fields constant that matches fieldId, throwing an exception
14320
       * if it is not found.
14321
       */
14322
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14323
        _Fields fields = findByThriftId(fieldId);
14324
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14325
        return fields;
14326
      }
14327
 
14328
      /**
14329
       * Find the _Fields constant that matches name, or null if its not found.
14330
       */
14331
      public static _Fields findByName(String name) {
14332
        return byName.get(name);
14333
      }
14334
 
14335
      private final short _thriftId;
14336
      private final String _fieldName;
14337
 
14338
      _Fields(short thriftId, String fieldName) {
14339
        _thriftId = thriftId;
14340
        _fieldName = fieldName;
14341
      }
14342
 
14343
      public short getThriftFieldId() {
14344
        return _thriftId;
14345
      }
14346
 
14347
      public String getFieldName() {
14348
        return _fieldName;
14349
      }
14350
    }
14351
 
14352
    // isset id assignments
14353
    private static final int __PAYMENTID_ISSET_ID = 0;
14354
    private BitSet __isset_bit_vector = new BitSet(1);
14355
 
14356
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14357
    static {
14358
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14359
      tmpMap.put(_Fields.PAYMENT_ID, new org.apache.thrift.meta_data.FieldMetaData("paymentId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14360
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14361
      tmpMap.put(_Fields.CATEGORY, new org.apache.thrift.meta_data.FieldMetaData("category", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14362
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ExtraPaymentProcessingType.class)));
14363
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14364
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markPaymentAsProcessed_args.class, metaDataMap);
14365
    }
14366
 
14367
    public markPaymentAsProcessed_args() {
14368
    }
14369
 
14370
    public markPaymentAsProcessed_args(
14371
      long paymentId,
14372
      ExtraPaymentProcessingType category)
14373
    {
14374
      this();
14375
      this.paymentId = paymentId;
14376
      setPaymentIdIsSet(true);
14377
      this.category = category;
14378
    }
14379
 
14380
    /**
14381
     * Performs a deep copy on <i>other</i>.
14382
     */
14383
    public markPaymentAsProcessed_args(markPaymentAsProcessed_args other) {
14384
      __isset_bit_vector.clear();
14385
      __isset_bit_vector.or(other.__isset_bit_vector);
14386
      this.paymentId = other.paymentId;
14387
      if (other.isSetCategory()) {
14388
        this.category = other.category;
14389
      }
14390
    }
14391
 
14392
    public markPaymentAsProcessed_args deepCopy() {
14393
      return new markPaymentAsProcessed_args(this);
14394
    }
14395
 
14396
    @Override
14397
    public void clear() {
14398
      setPaymentIdIsSet(false);
14399
      this.paymentId = 0;
14400
      this.category = null;
14401
    }
14402
 
14403
    public long getPaymentId() {
14404
      return this.paymentId;
14405
    }
14406
 
14407
    public void setPaymentId(long paymentId) {
14408
      this.paymentId = paymentId;
14409
      setPaymentIdIsSet(true);
14410
    }
14411
 
14412
    public void unsetPaymentId() {
14413
      __isset_bit_vector.clear(__PAYMENTID_ISSET_ID);
14414
    }
14415
 
14416
    /** Returns true if field paymentId is set (has been assigned a value) and false otherwise */
14417
    public boolean isSetPaymentId() {
14418
      return __isset_bit_vector.get(__PAYMENTID_ISSET_ID);
14419
    }
14420
 
14421
    public void setPaymentIdIsSet(boolean value) {
14422
      __isset_bit_vector.set(__PAYMENTID_ISSET_ID, value);
14423
    }
14424
 
14425
    /**
14426
     * 
14427
     * @see ExtraPaymentProcessingType
14428
     */
14429
    public ExtraPaymentProcessingType getCategory() {
14430
      return this.category;
14431
    }
14432
 
14433
    /**
14434
     * 
14435
     * @see ExtraPaymentProcessingType
14436
     */
14437
    public void setCategory(ExtraPaymentProcessingType category) {
14438
      this.category = category;
14439
    }
14440
 
14441
    public void unsetCategory() {
14442
      this.category = null;
14443
    }
14444
 
14445
    /** Returns true if field category is set (has been assigned a value) and false otherwise */
14446
    public boolean isSetCategory() {
14447
      return this.category != null;
14448
    }
14449
 
14450
    public void setCategoryIsSet(boolean value) {
14451
      if (!value) {
14452
        this.category = null;
14453
      }
14454
    }
14455
 
14456
    public void setFieldValue(_Fields field, Object value) {
14457
      switch (field) {
14458
      case PAYMENT_ID:
14459
        if (value == null) {
14460
          unsetPaymentId();
14461
        } else {
14462
          setPaymentId((Long)value);
14463
        }
14464
        break;
14465
 
14466
      case CATEGORY:
14467
        if (value == null) {
14468
          unsetCategory();
14469
        } else {
14470
          setCategory((ExtraPaymentProcessingType)value);
14471
        }
14472
        break;
14473
 
14474
      }
14475
    }
14476
 
14477
    public Object getFieldValue(_Fields field) {
14478
      switch (field) {
14479
      case PAYMENT_ID:
14480
        return Long.valueOf(getPaymentId());
14481
 
14482
      case CATEGORY:
14483
        return getCategory();
14484
 
14485
      }
14486
      throw new IllegalStateException();
14487
    }
14488
 
14489
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14490
    public boolean isSet(_Fields field) {
14491
      if (field == null) {
14492
        throw new IllegalArgumentException();
14493
      }
14494
 
14495
      switch (field) {
14496
      case PAYMENT_ID:
14497
        return isSetPaymentId();
14498
      case CATEGORY:
14499
        return isSetCategory();
14500
      }
14501
      throw new IllegalStateException();
14502
    }
14503
 
14504
    @Override
14505
    public boolean equals(Object that) {
14506
      if (that == null)
14507
        return false;
14508
      if (that instanceof markPaymentAsProcessed_args)
14509
        return this.equals((markPaymentAsProcessed_args)that);
14510
      return false;
14511
    }
14512
 
14513
    public boolean equals(markPaymentAsProcessed_args that) {
14514
      if (that == null)
14515
        return false;
14516
 
14517
      boolean this_present_paymentId = true;
14518
      boolean that_present_paymentId = true;
14519
      if (this_present_paymentId || that_present_paymentId) {
14520
        if (!(this_present_paymentId && that_present_paymentId))
14521
          return false;
14522
        if (this.paymentId != that.paymentId)
14523
          return false;
14524
      }
14525
 
14526
      boolean this_present_category = true && this.isSetCategory();
14527
      boolean that_present_category = true && that.isSetCategory();
14528
      if (this_present_category || that_present_category) {
14529
        if (!(this_present_category && that_present_category))
14530
          return false;
14531
        if (!this.category.equals(that.category))
14532
          return false;
14533
      }
14534
 
14535
      return true;
14536
    }
14537
 
14538
    @Override
14539
    public int hashCode() {
14540
      return 0;
14541
    }
14542
 
14543
    public int compareTo(markPaymentAsProcessed_args other) {
14544
      if (!getClass().equals(other.getClass())) {
14545
        return getClass().getName().compareTo(other.getClass().getName());
14546
      }
14547
 
14548
      int lastComparison = 0;
14549
      markPaymentAsProcessed_args typedOther = (markPaymentAsProcessed_args)other;
14550
 
14551
      lastComparison = Boolean.valueOf(isSetPaymentId()).compareTo(typedOther.isSetPaymentId());
14552
      if (lastComparison != 0) {
14553
        return lastComparison;
14554
      }
14555
      if (isSetPaymentId()) {
14556
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.paymentId, typedOther.paymentId);
14557
        if (lastComparison != 0) {
14558
          return lastComparison;
14559
        }
14560
      }
14561
      lastComparison = Boolean.valueOf(isSetCategory()).compareTo(typedOther.isSetCategory());
14562
      if (lastComparison != 0) {
14563
        return lastComparison;
14564
      }
14565
      if (isSetCategory()) {
14566
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.category, typedOther.category);
14567
        if (lastComparison != 0) {
14568
          return lastComparison;
14569
        }
14570
      }
14571
      return 0;
14572
    }
14573
 
14574
    public _Fields fieldForId(int fieldId) {
14575
      return _Fields.findByThriftId(fieldId);
14576
    }
14577
 
14578
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14579
      org.apache.thrift.protocol.TField field;
14580
      iprot.readStructBegin();
14581
      while (true)
14582
      {
14583
        field = iprot.readFieldBegin();
14584
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14585
          break;
14586
        }
14587
        switch (field.id) {
14588
          case 1: // PAYMENT_ID
14589
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14590
              this.paymentId = iprot.readI64();
14591
              setPaymentIdIsSet(true);
14592
            } else { 
14593
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14594
            }
14595
            break;
14596
          case 2: // CATEGORY
14597
            if (field.type == org.apache.thrift.protocol.TType.I32) {
14598
              this.category = ExtraPaymentProcessingType.findByValue(iprot.readI32());
14599
            } else { 
14600
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14601
            }
14602
            break;
14603
          default:
14604
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14605
        }
14606
        iprot.readFieldEnd();
14607
      }
14608
      iprot.readStructEnd();
14609
      validate();
14610
    }
14611
 
14612
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14613
      validate();
14614
 
14615
      oprot.writeStructBegin(STRUCT_DESC);
14616
      oprot.writeFieldBegin(PAYMENT_ID_FIELD_DESC);
14617
      oprot.writeI64(this.paymentId);
14618
      oprot.writeFieldEnd();
14619
      if (this.category != null) {
14620
        oprot.writeFieldBegin(CATEGORY_FIELD_DESC);
14621
        oprot.writeI32(this.category.getValue());
14622
        oprot.writeFieldEnd();
14623
      }
14624
      oprot.writeFieldStop();
14625
      oprot.writeStructEnd();
14626
    }
14627
 
14628
    @Override
14629
    public String toString() {
14630
      StringBuilder sb = new StringBuilder("markPaymentAsProcessed_args(");
14631
      boolean first = true;
14632
 
14633
      sb.append("paymentId:");
14634
      sb.append(this.paymentId);
14635
      first = false;
14636
      if (!first) sb.append(", ");
14637
      sb.append("category:");
14638
      if (this.category == null) {
14639
        sb.append("null");
14640
      } else {
14641
        sb.append(this.category);
14642
      }
14643
      first = false;
14644
      sb.append(")");
14645
      return sb.toString();
14646
    }
14647
 
14648
    public void validate() throws org.apache.thrift.TException {
14649
      // check for required fields
14650
    }
14651
 
14652
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14653
      try {
14654
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14655
      } catch (org.apache.thrift.TException te) {
14656
        throw new java.io.IOException(te);
14657
      }
14658
    }
14659
 
14660
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14661
      try {
14662
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14663
      } catch (org.apache.thrift.TException te) {
14664
        throw new java.io.IOException(te);
14665
      }
14666
    }
14667
 
14668
  }
14669
 
14670
  public static class markPaymentAsProcessed_result implements org.apache.thrift.TBase<markPaymentAsProcessed_result, markPaymentAsProcessed_result._Fields>, java.io.Serializable, Cloneable   {
14671
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markPaymentAsProcessed_result");
14672
 
14673
 
14674
 
14675
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14676
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14677
;
14678
 
14679
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14680
 
14681
      static {
14682
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14683
          byName.put(field.getFieldName(), field);
14684
        }
14685
      }
14686
 
14687
      /**
14688
       * Find the _Fields constant that matches fieldId, or null if its not found.
14689
       */
14690
      public static _Fields findByThriftId(int fieldId) {
14691
        switch(fieldId) {
14692
          default:
14693
            return null;
14694
        }
14695
      }
14696
 
14697
      /**
14698
       * Find the _Fields constant that matches fieldId, throwing an exception
14699
       * if it is not found.
14700
       */
14701
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14702
        _Fields fields = findByThriftId(fieldId);
14703
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14704
        return fields;
14705
      }
14706
 
14707
      /**
14708
       * Find the _Fields constant that matches name, or null if its not found.
14709
       */
14710
      public static _Fields findByName(String name) {
14711
        return byName.get(name);
14712
      }
14713
 
14714
      private final short _thriftId;
14715
      private final String _fieldName;
14716
 
14717
      _Fields(short thriftId, String fieldName) {
14718
        _thriftId = thriftId;
14719
        _fieldName = fieldName;
14720
      }
14721
 
14722
      public short getThriftFieldId() {
14723
        return _thriftId;
14724
      }
14725
 
14726
      public String getFieldName() {
14727
        return _fieldName;
14728
      }
14729
    }
14730
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14731
    static {
14732
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14733
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14734
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markPaymentAsProcessed_result.class, metaDataMap);
14735
    }
14736
 
14737
    public markPaymentAsProcessed_result() {
14738
    }
14739
 
14740
    /**
14741
     * Performs a deep copy on <i>other</i>.
14742
     */
14743
    public markPaymentAsProcessed_result(markPaymentAsProcessed_result other) {
14744
    }
14745
 
14746
    public markPaymentAsProcessed_result deepCopy() {
14747
      return new markPaymentAsProcessed_result(this);
14748
    }
14749
 
14750
    @Override
14751
    public void clear() {
14752
    }
14753
 
14754
    public void setFieldValue(_Fields field, Object value) {
14755
      switch (field) {
14756
      }
14757
    }
14758
 
14759
    public Object getFieldValue(_Fields field) {
14760
      switch (field) {
14761
      }
14762
      throw new IllegalStateException();
14763
    }
14764
 
14765
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14766
    public boolean isSet(_Fields field) {
14767
      if (field == null) {
14768
        throw new IllegalArgumentException();
14769
      }
14770
 
14771
      switch (field) {
14772
      }
14773
      throw new IllegalStateException();
14774
    }
14775
 
14776
    @Override
14777
    public boolean equals(Object that) {
14778
      if (that == null)
14779
        return false;
14780
      if (that instanceof markPaymentAsProcessed_result)
14781
        return this.equals((markPaymentAsProcessed_result)that);
14782
      return false;
14783
    }
14784
 
14785
    public boolean equals(markPaymentAsProcessed_result that) {
14786
      if (that == null)
14787
        return false;
14788
 
14789
      return true;
14790
    }
14791
 
14792
    @Override
14793
    public int hashCode() {
14794
      return 0;
14795
    }
14796
 
14797
    public int compareTo(markPaymentAsProcessed_result other) {
14798
      if (!getClass().equals(other.getClass())) {
14799
        return getClass().getName().compareTo(other.getClass().getName());
14800
      }
14801
 
14802
      int lastComparison = 0;
14803
      markPaymentAsProcessed_result typedOther = (markPaymentAsProcessed_result)other;
14804
 
14805
      return 0;
14806
    }
14807
 
14808
    public _Fields fieldForId(int fieldId) {
14809
      return _Fields.findByThriftId(fieldId);
14810
    }
14811
 
14812
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14813
      org.apache.thrift.protocol.TField field;
14814
      iprot.readStructBegin();
14815
      while (true)
14816
      {
14817
        field = iprot.readFieldBegin();
14818
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14819
          break;
14820
        }
14821
        switch (field.id) {
14822
          default:
14823
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14824
        }
14825
        iprot.readFieldEnd();
14826
      }
14827
      iprot.readStructEnd();
14828
      validate();
14829
    }
14830
 
14831
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14832
      oprot.writeStructBegin(STRUCT_DESC);
14833
 
14834
      oprot.writeFieldStop();
14835
      oprot.writeStructEnd();
14836
    }
14837
 
14838
    @Override
14839
    public String toString() {
14840
      StringBuilder sb = new StringBuilder("markPaymentAsProcessed_result(");
14841
      boolean first = true;
14842
 
14843
      sb.append(")");
14844
      return sb.toString();
14845
    }
14846
 
14847
    public void validate() throws org.apache.thrift.TException {
14848
      // check for required fields
14849
    }
14850
 
14851
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14852
      try {
14853
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14854
      } catch (org.apache.thrift.TException te) {
14855
        throw new java.io.IOException(te);
14856
      }
14857
    }
14858
 
14859
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14860
      try {
14861
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14862
      } catch (org.apache.thrift.TException te) {
14863
        throw new java.io.IOException(te);
14864
      }
14865
    }
14866
 
14867
  }
14868
 
123 ashish 14869
}