Subversion Repositories SmartDukaan

Rev

Rev 3430 | Rev 3469 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3430 Rev 3451
Line 50... Line 50...
50
     */
50
     */
51
    public List<Order> getOrdersByBillingDate(OrderStatus status, long start_billing_date, long end_billing_date, long warehouse_id) throws TransactionServiceException, org.apache.thrift.TException;
51
    public List<Order> getOrdersByBillingDate(OrderStatus status, long start_billing_date, long end_billing_date, long warehouse_id) throws TransactionServiceException, org.apache.thrift.TException;
52
 
52
 
53
    /**
53
    /**
54
     * Returns orders for a particular provider and warehouse which were shipped between the given dates.
54
     * Returns orders for a particular provider and warehouse which were shipped between the given dates.
-
 
55
     * Returned orders comprise of COD orders if cod parameter is true. It comprises of prepaid orders otherwise.
55
     * Pass providerId and warehouseId as -1 to ignore both the parameters.
56
     * Pass providerId and warehouseId as -1 to ignore both these parameters.
56
     * 
57
     * 
57
     * @param fromShippingDate
58
     * @param fromShippingDate
58
     * @param toShippingDate
59
     * @param toShippingDate
59
     * @param providerId
60
     * @param providerId
60
     * @param warehouseId
61
     * @param warehouseId
-
 
62
     * @param cod
61
     */
63
     */
62
    public List<Order> getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId) throws TransactionServiceException, org.apache.thrift.TException;
64
    public List<Order> getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, boolean cod) throws TransactionServiceException, org.apache.thrift.TException;
63
 
65
 
64
    /**
66
    /**
65
     * Returns order ids for orders which can be returned
67
     * Returns order ids for orders which can be returned
66
     * 
68
     * 
67
     * @param customer_id
69
     * @param customer_id
Line 406... Line 408...
406
     * 
408
     * 
407
     * @param warehouseId
409
     * @param warehouseId
408
     */
410
     */
409
    public long createPurchaseOrder(long warehouseId) throws TransactionServiceException, org.apache.thrift.TException;
411
    public long createPurchaseOrder(long warehouseId) throws TransactionServiceException, org.apache.thrift.TException;
410
 
412
 
-
 
413
    /**
-
 
414
     * Set the weight of the given order to the provided value. Will attempt to update the weight of the item in the catalog as well.
-
 
415
     * 
-
 
416
     * @param orderId
-
 
417
     * @param weight
-
 
418
     */
-
 
419
    public Order updateWeight(long orderId, double weight) throws TransactionServiceException, org.apache.thrift.TException;
-
 
420
 
411
  }
421
  }
412
 
422
 
413
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
423
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
414
 
424
 
415
    public void createTransaction(Transaction transaction, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createTransaction_call> resultHandler) throws org.apache.thrift.TException;
425
    public void createTransaction(Transaction transaction, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createTransaction_call> resultHandler) throws org.apache.thrift.TException;
Line 428... Line 438...
428
 
438
 
429
    public void getAllOrders(OrderStatus status, long from_date, long to_date, long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllOrders_call> resultHandler) throws org.apache.thrift.TException;
439
    public void getAllOrders(OrderStatus status, long from_date, long to_date, long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllOrders_call> resultHandler) throws org.apache.thrift.TException;
430
 
440
 
431
    public void getOrdersByBillingDate(OrderStatus status, long start_billing_date, long end_billing_date, long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getOrdersByBillingDate_call> resultHandler) throws org.apache.thrift.TException;
441
    public void getOrdersByBillingDate(OrderStatus status, long start_billing_date, long end_billing_date, long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getOrdersByBillingDate_call> resultHandler) throws org.apache.thrift.TException;
432
 
442
 
433
    public void getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getOrdersByShippingDate_call> resultHandler) throws org.apache.thrift.TException;
443
    public void getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, boolean cod, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getOrdersByShippingDate_call> resultHandler) throws org.apache.thrift.TException;
434
 
444
 
435
    public void getReturnableOrdersForCustomer(long customer_id, long limit, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getReturnableOrdersForCustomer_call> resultHandler) throws org.apache.thrift.TException;
445
    public void getReturnableOrdersForCustomer(long customer_id, long limit, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getReturnableOrdersForCustomer_call> resultHandler) throws org.apache.thrift.TException;
436
 
446
 
437
    public void getCancellableOrdersForCustomer(long customer_id, long limit, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getCancellableOrdersForCustomer_call> resultHandler) throws org.apache.thrift.TException;
447
    public void getCancellableOrdersForCustomer(long customer_id, long limit, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getCancellableOrdersForCustomer_call> resultHandler) throws org.apache.thrift.TException;
438
 
448
 
Line 510... Line 520...
510
 
520
 
511
    public void processReturn(long returnOrderId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.processReturn_call> resultHandler) throws org.apache.thrift.TException;
521
    public void processReturn(long returnOrderId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.processReturn_call> resultHandler) throws org.apache.thrift.TException;
512
 
522
 
513
    public void createPurchaseOrder(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPurchaseOrder_call> resultHandler) throws org.apache.thrift.TException;
523
    public void createPurchaseOrder(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPurchaseOrder_call> resultHandler) throws org.apache.thrift.TException;
514
 
524
 
-
 
525
    public void updateWeight(long orderId, double weight, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateWeight_call> resultHandler) throws org.apache.thrift.TException;
-
 
526
 
515
  }
527
  }
516
 
528
 
517
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
529
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
518
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
530
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
519
      public Factory() {}
531
      public Factory() {}
Line 777... Line 789...
777
        throw result.ex;
789
        throw result.ex;
778
      }
790
      }
779
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getOrdersByBillingDate failed: unknown result");
791
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getOrdersByBillingDate failed: unknown result");
780
    }
792
    }
781
 
793
 
782
    public List<Order> getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId) throws TransactionServiceException, org.apache.thrift.TException
794
    public List<Order> getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, boolean cod) throws TransactionServiceException, org.apache.thrift.TException
783
    {
795
    {
784
      send_getOrdersByShippingDate(fromShippingDate, toShippingDate, providerId, warehouseId);
796
      send_getOrdersByShippingDate(fromShippingDate, toShippingDate, providerId, warehouseId, cod);
785
      return recv_getOrdersByShippingDate();
797
      return recv_getOrdersByShippingDate();
786
    }
798
    }
787
 
799
 
788
    public void send_getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId) throws org.apache.thrift.TException
800
    public void send_getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, boolean cod) throws org.apache.thrift.TException
789
    {
801
    {
790
      getOrdersByShippingDate_args args = new getOrdersByShippingDate_args();
802
      getOrdersByShippingDate_args args = new getOrdersByShippingDate_args();
791
      args.setFromShippingDate(fromShippingDate);
803
      args.setFromShippingDate(fromShippingDate);
792
      args.setToShippingDate(toShippingDate);
804
      args.setToShippingDate(toShippingDate);
793
      args.setProviderId(providerId);
805
      args.setProviderId(providerId);
794
      args.setWarehouseId(warehouseId);
806
      args.setWarehouseId(warehouseId);
-
 
807
      args.setCod(cod);
795
      sendBase("getOrdersByShippingDate", args);
808
      sendBase("getOrdersByShippingDate", args);
796
    }
809
    }
797
 
810
 
798
    public List<Order> recv_getOrdersByShippingDate() throws TransactionServiceException, org.apache.thrift.TException
811
    public List<Order> recv_getOrdersByShippingDate() throws TransactionServiceException, org.apache.thrift.TException
799
    {
812
    {
Line 1835... Line 1848...
1835
        throw result.ex;
1848
        throw result.ex;
1836
      }
1849
      }
1837
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createPurchaseOrder failed: unknown result");
1850
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "createPurchaseOrder failed: unknown result");
1838
    }
1851
    }
1839
 
1852
 
-
 
1853
    public Order updateWeight(long orderId, double weight) throws TransactionServiceException, org.apache.thrift.TException
-
 
1854
    {
-
 
1855
      send_updateWeight(orderId, weight);
-
 
1856
      return recv_updateWeight();
-
 
1857
    }
-
 
1858
 
-
 
1859
    public void send_updateWeight(long orderId, double weight) throws org.apache.thrift.TException
-
 
1860
    {
-
 
1861
      updateWeight_args args = new updateWeight_args();
-
 
1862
      args.setOrderId(orderId);
-
 
1863
      args.setWeight(weight);
-
 
1864
      sendBase("updateWeight", args);
-
 
1865
    }
-
 
1866
 
-
 
1867
    public Order recv_updateWeight() throws TransactionServiceException, org.apache.thrift.TException
-
 
1868
    {
-
 
1869
      updateWeight_result result = new updateWeight_result();
-
 
1870
      receiveBase(result, "updateWeight");
-
 
1871
      if (result.isSetSuccess()) {
-
 
1872
        return result.success;
-
 
1873
      }
-
 
1874
      if (result.ex != null) {
-
 
1875
        throw result.ex;
-
 
1876
      }
-
 
1877
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "updateWeight failed: unknown result");
-
 
1878
    }
-
 
1879
 
1840
  }
1880
  }
1841
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1881
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1842
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1882
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1843
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1883
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1844
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
1884
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
Line 2174... Line 2214...
2174
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2214
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2175
        return (new Client(prot)).recv_getOrdersByBillingDate();
2215
        return (new Client(prot)).recv_getOrdersByBillingDate();
2176
      }
2216
      }
2177
    }
2217
    }
2178
 
2218
 
2179
    public void getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getOrdersByShippingDate_call> resultHandler) throws org.apache.thrift.TException {
2219
    public void getOrdersByShippingDate(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, boolean cod, org.apache.thrift.async.AsyncMethodCallback<getOrdersByShippingDate_call> resultHandler) throws org.apache.thrift.TException {
2180
      checkReady();
2220
      checkReady();
2181
      getOrdersByShippingDate_call method_call = new getOrdersByShippingDate_call(fromShippingDate, toShippingDate, providerId, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2221
      getOrdersByShippingDate_call method_call = new getOrdersByShippingDate_call(fromShippingDate, toShippingDate, providerId, warehouseId, cod, resultHandler, this, ___protocolFactory, ___transport);
2182
      this.___currentMethod = method_call;
2222
      this.___currentMethod = method_call;
2183
      ___manager.call(method_call);
2223
      ___manager.call(method_call);
2184
    }
2224
    }
2185
 
2225
 
2186
    public static class getOrdersByShippingDate_call extends org.apache.thrift.async.TAsyncMethodCall {
2226
    public static class getOrdersByShippingDate_call extends org.apache.thrift.async.TAsyncMethodCall {
2187
      private long fromShippingDate;
2227
      private long fromShippingDate;
2188
      private long toShippingDate;
2228
      private long toShippingDate;
2189
      private long providerId;
2229
      private long providerId;
2190
      private long warehouseId;
2230
      private long warehouseId;
-
 
2231
      private boolean cod;
2191
      public getOrdersByShippingDate_call(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getOrdersByShippingDate_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 {
2232
      public getOrdersByShippingDate_call(long fromShippingDate, long toShippingDate, long providerId, long warehouseId, boolean cod, org.apache.thrift.async.AsyncMethodCallback<getOrdersByShippingDate_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 {
2192
        super(client, protocolFactory, transport, resultHandler, false);
2233
        super(client, protocolFactory, transport, resultHandler, false);
2193
        this.fromShippingDate = fromShippingDate;
2234
        this.fromShippingDate = fromShippingDate;
2194
        this.toShippingDate = toShippingDate;
2235
        this.toShippingDate = toShippingDate;
2195
        this.providerId = providerId;
2236
        this.providerId = providerId;
2196
        this.warehouseId = warehouseId;
2237
        this.warehouseId = warehouseId;
-
 
2238
        this.cod = cod;
2197
      }
2239
      }
2198
 
2240
 
2199
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2241
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2200
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getOrdersByShippingDate", org.apache.thrift.protocol.TMessageType.CALL, 0));
2242
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getOrdersByShippingDate", org.apache.thrift.protocol.TMessageType.CALL, 0));
2201
        getOrdersByShippingDate_args args = new getOrdersByShippingDate_args();
2243
        getOrdersByShippingDate_args args = new getOrdersByShippingDate_args();
2202
        args.setFromShippingDate(fromShippingDate);
2244
        args.setFromShippingDate(fromShippingDate);
2203
        args.setToShippingDate(toShippingDate);
2245
        args.setToShippingDate(toShippingDate);
2204
        args.setProviderId(providerId);
2246
        args.setProviderId(providerId);
2205
        args.setWarehouseId(warehouseId);
2247
        args.setWarehouseId(warehouseId);
-
 
2248
        args.setCod(cod);
2206
        args.write(prot);
2249
        args.write(prot);
2207
        prot.writeMessageEnd();
2250
        prot.writeMessageEnd();
2208
      }
2251
      }
2209
 
2252
 
2210
      public List<Order> getResult() throws TransactionServiceException, org.apache.thrift.TException {
2253
      public List<Order> getResult() throws TransactionServiceException, org.apache.thrift.TException {
Line 3588... Line 3631...
3588
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
3631
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
3589
        return (new Client(prot)).recv_createPurchaseOrder();
3632
        return (new Client(prot)).recv_createPurchaseOrder();
3590
      }
3633
      }
3591
    }
3634
    }
3592
 
3635
 
-
 
3636
    public void updateWeight(long orderId, double weight, org.apache.thrift.async.AsyncMethodCallback<updateWeight_call> resultHandler) throws org.apache.thrift.TException {
-
 
3637
      checkReady();
-
 
3638
      updateWeight_call method_call = new updateWeight_call(orderId, weight, resultHandler, this, ___protocolFactory, ___transport);
-
 
3639
      this.___currentMethod = method_call;
-
 
3640
      ___manager.call(method_call);
-
 
3641
    }
-
 
3642
 
-
 
3643
    public static class updateWeight_call extends org.apache.thrift.async.TAsyncMethodCall {
-
 
3644
      private long orderId;
-
 
3645
      private double weight;
-
 
3646
      public updateWeight_call(long orderId, double weight, org.apache.thrift.async.AsyncMethodCallback<updateWeight_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 {
-
 
3647
        super(client, protocolFactory, transport, resultHandler, false);
-
 
3648
        this.orderId = orderId;
-
 
3649
        this.weight = weight;
-
 
3650
      }
-
 
3651
 
-
 
3652
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-
 
3653
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateWeight", org.apache.thrift.protocol.TMessageType.CALL, 0));
-
 
3654
        updateWeight_args args = new updateWeight_args();
-
 
3655
        args.setOrderId(orderId);
-
 
3656
        args.setWeight(weight);
-
 
3657
        args.write(prot);
-
 
3658
        prot.writeMessageEnd();
-
 
3659
      }
-
 
3660
 
-
 
3661
      public Order getResult() throws TransactionServiceException, org.apache.thrift.TException {
-
 
3662
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-
 
3663
          throw new IllegalStateException("Method call not finished!");
-
 
3664
        }
-
 
3665
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-
 
3666
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-
 
3667
        return (new Client(prot)).recv_updateWeight();
-
 
3668
      }
-
 
3669
    }
-
 
3670
 
3593
  }
3671
  }
3594
 
3672
 
3595
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
3673
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
3596
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
3674
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
3597
    public Processor(I iface) {
3675
    public Processor(I iface) {
Line 3651... Line 3729...
3651
      processMap.put("refundOrder", new refundOrder());
3729
      processMap.put("refundOrder", new refundOrder());
3652
      processMap.put("getReturnOrders", new getReturnOrders());
3730
      processMap.put("getReturnOrders", new getReturnOrders());
3653
      processMap.put("getReturnOrder", new getReturnOrder());
3731
      processMap.put("getReturnOrder", new getReturnOrder());
3654
      processMap.put("processReturn", new processReturn());
3732
      processMap.put("processReturn", new processReturn());
3655
      processMap.put("createPurchaseOrder", new createPurchaseOrder());
3733
      processMap.put("createPurchaseOrder", new createPurchaseOrder());
-
 
3734
      processMap.put("updateWeight", new updateWeight());
3656
      return processMap;
3735
      return processMap;
3657
    }
3736
    }
3658
 
3737
 
3659
    private static class createTransaction<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createTransaction_args> {
3738
    private static class createTransaction<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createTransaction_args> {
3660
      public createTransaction() {
3739
      public createTransaction() {
Line 3849... Line 3928...
3849
      }
3928
      }
3850
 
3929
 
3851
      protected getOrdersByShippingDate_result getResult(I iface, getOrdersByShippingDate_args args) throws org.apache.thrift.TException {
3930
      protected getOrdersByShippingDate_result getResult(I iface, getOrdersByShippingDate_args args) throws org.apache.thrift.TException {
3852
        getOrdersByShippingDate_result result = new getOrdersByShippingDate_result();
3931
        getOrdersByShippingDate_result result = new getOrdersByShippingDate_result();
3853
        try {
3932
        try {
3854
          result.success = iface.getOrdersByShippingDate(args.fromShippingDate, args.toShippingDate, args.providerId, args.warehouseId);
3933
          result.success = iface.getOrdersByShippingDate(args.fromShippingDate, args.toShippingDate, args.providerId, args.warehouseId, args.cod);
3855
        } catch (TransactionServiceException ex) {
3934
        } catch (TransactionServiceException ex) {
3856
          result.ex = ex;
3935
          result.ex = ex;
3857
        }
3936
        }
3858
        return result;
3937
        return result;
3859
      }
3938
      }
Line 4640... Line 4719...
4640
        }
4719
        }
4641
        return result;
4720
        return result;
4642
      }
4721
      }
4643
    }
4722
    }
4644
 
4723
 
-
 
4724
    private static class updateWeight<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateWeight_args> {
-
 
4725
      public updateWeight() {
-
 
4726
        super("updateWeight");
-
 
4727
      }
-
 
4728
 
-
 
4729
      protected updateWeight_args getEmptyArgsInstance() {
-
 
4730
        return new updateWeight_args();
-
 
4731
      }
-
 
4732
 
-
 
4733
      protected updateWeight_result getResult(I iface, updateWeight_args args) throws org.apache.thrift.TException {
-
 
4734
        updateWeight_result result = new updateWeight_result();
-
 
4735
        try {
-
 
4736
          result.success = iface.updateWeight(args.orderId, args.weight);
-
 
4737
        } catch (TransactionServiceException ex) {
-
 
4738
          result.ex = ex;
-
 
4739
        }
-
 
4740
        return result;
-
 
4741
      }
-
 
4742
    }
-
 
4743
 
4645
  }
4744
  }
4646
 
4745
 
4647
  public static class createTransaction_args implements org.apache.thrift.TBase<createTransaction_args, createTransaction_args._Fields>, java.io.Serializable, Cloneable   {
4746
  public static class createTransaction_args implements org.apache.thrift.TBase<createTransaction_args, createTransaction_args._Fields>, java.io.Serializable, Cloneable   {
4648
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createTransaction_args");
4747
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createTransaction_args");
4649
 
4748
 
Line 11876... Line 11975...
11876
 
11975
 
11877
    private static final org.apache.thrift.protocol.TField FROM_SHIPPING_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("fromShippingDate", org.apache.thrift.protocol.TType.I64, (short)1);
11976
    private static final org.apache.thrift.protocol.TField FROM_SHIPPING_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("fromShippingDate", org.apache.thrift.protocol.TType.I64, (short)1);
11878
    private static final org.apache.thrift.protocol.TField TO_SHIPPING_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("toShippingDate", org.apache.thrift.protocol.TType.I64, (short)2);
11977
    private static final org.apache.thrift.protocol.TField TO_SHIPPING_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("toShippingDate", org.apache.thrift.protocol.TType.I64, (short)2);
11879
    private static final org.apache.thrift.protocol.TField PROVIDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("providerId", org.apache.thrift.protocol.TType.I64, (short)3);
11978
    private static final org.apache.thrift.protocol.TField PROVIDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("providerId", org.apache.thrift.protocol.TType.I64, (short)3);
11880
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouseId", org.apache.thrift.protocol.TType.I64, (short)4);
11979
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouseId", org.apache.thrift.protocol.TType.I64, (short)4);
-
 
11980
    private static final org.apache.thrift.protocol.TField COD_FIELD_DESC = new org.apache.thrift.protocol.TField("cod", org.apache.thrift.protocol.TType.BOOL, (short)5);
11881
 
11981
 
11882
    private long fromShippingDate; // required
11982
    private long fromShippingDate; // required
11883
    private long toShippingDate; // required
11983
    private long toShippingDate; // required
11884
    private long providerId; // required
11984
    private long providerId; // required
11885
    private long warehouseId; // required
11985
    private long warehouseId; // required
-
 
11986
    private boolean cod; // required
11886
 
11987
 
11887
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11988
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11888
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11989
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11889
      FROM_SHIPPING_DATE((short)1, "fromShippingDate"),
11990
      FROM_SHIPPING_DATE((short)1, "fromShippingDate"),
11890
      TO_SHIPPING_DATE((short)2, "toShippingDate"),
11991
      TO_SHIPPING_DATE((short)2, "toShippingDate"),
11891
      PROVIDER_ID((short)3, "providerId"),
11992
      PROVIDER_ID((short)3, "providerId"),
11892
      WAREHOUSE_ID((short)4, "warehouseId");
11993
      WAREHOUSE_ID((short)4, "warehouseId"),
-
 
11994
      COD((short)5, "cod");
11893
 
11995
 
11894
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11996
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11895
 
11997
 
11896
      static {
11998
      static {
11897
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11999
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
Line 11910... Line 12012...
11910
            return TO_SHIPPING_DATE;
12012
            return TO_SHIPPING_DATE;
11911
          case 3: // PROVIDER_ID
12013
          case 3: // PROVIDER_ID
11912
            return PROVIDER_ID;
12014
            return PROVIDER_ID;
11913
          case 4: // WAREHOUSE_ID
12015
          case 4: // WAREHOUSE_ID
11914
            return WAREHOUSE_ID;
12016
            return WAREHOUSE_ID;
-
 
12017
          case 5: // COD
-
 
12018
            return COD;
11915
          default:
12019
          default:
11916
            return null;
12020
            return null;
11917
        }
12021
        }
11918
      }
12022
      }
11919
 
12023
 
Line 11954... Line 12058...
11954
    // isset id assignments
12058
    // isset id assignments
11955
    private static final int __FROMSHIPPINGDATE_ISSET_ID = 0;
12059
    private static final int __FROMSHIPPINGDATE_ISSET_ID = 0;
11956
    private static final int __TOSHIPPINGDATE_ISSET_ID = 1;
12060
    private static final int __TOSHIPPINGDATE_ISSET_ID = 1;
11957
    private static final int __PROVIDERID_ISSET_ID = 2;
12061
    private static final int __PROVIDERID_ISSET_ID = 2;
11958
    private static final int __WAREHOUSEID_ISSET_ID = 3;
12062
    private static final int __WAREHOUSEID_ISSET_ID = 3;
-
 
12063
    private static final int __COD_ISSET_ID = 4;
11959
    private BitSet __isset_bit_vector = new BitSet(4);
12064
    private BitSet __isset_bit_vector = new BitSet(5);
11960
 
12065
 
11961
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12066
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11962
    static {
12067
    static {
11963
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12068
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11964
      tmpMap.put(_Fields.FROM_SHIPPING_DATE, new org.apache.thrift.meta_data.FieldMetaData("fromShippingDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12069
      tmpMap.put(_Fields.FROM_SHIPPING_DATE, new org.apache.thrift.meta_data.FieldMetaData("fromShippingDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
Line 11967... Line 12072...
11967
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12072
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11968
      tmpMap.put(_Fields.PROVIDER_ID, new org.apache.thrift.meta_data.FieldMetaData("providerId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12073
      tmpMap.put(_Fields.PROVIDER_ID, new org.apache.thrift.meta_data.FieldMetaData("providerId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11969
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12074
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11970
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12075
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11971
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12076
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
12077
      tmpMap.put(_Fields.COD, new org.apache.thrift.meta_data.FieldMetaData("cod", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
12078
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
11972
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12079
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11973
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getOrdersByShippingDate_args.class, metaDataMap);
12080
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getOrdersByShippingDate_args.class, metaDataMap);
11974
    }
12081
    }
11975
 
12082
 
11976
    public getOrdersByShippingDate_args() {
12083
    public getOrdersByShippingDate_args() {
Line 11978... Line 12085...
11978
 
12085
 
11979
    public getOrdersByShippingDate_args(
12086
    public getOrdersByShippingDate_args(
11980
      long fromShippingDate,
12087
      long fromShippingDate,
11981
      long toShippingDate,
12088
      long toShippingDate,
11982
      long providerId,
12089
      long providerId,
11983
      long warehouseId)
12090
      long warehouseId,
-
 
12091
      boolean cod)
11984
    {
12092
    {
11985
      this();
12093
      this();
11986
      this.fromShippingDate = fromShippingDate;
12094
      this.fromShippingDate = fromShippingDate;
11987
      setFromShippingDateIsSet(true);
12095
      setFromShippingDateIsSet(true);
11988
      this.toShippingDate = toShippingDate;
12096
      this.toShippingDate = toShippingDate;
11989
      setToShippingDateIsSet(true);
12097
      setToShippingDateIsSet(true);
11990
      this.providerId = providerId;
12098
      this.providerId = providerId;
11991
      setProviderIdIsSet(true);
12099
      setProviderIdIsSet(true);
11992
      this.warehouseId = warehouseId;
12100
      this.warehouseId = warehouseId;
11993
      setWarehouseIdIsSet(true);
12101
      setWarehouseIdIsSet(true);
-
 
12102
      this.cod = cod;
-
 
12103
      setCodIsSet(true);
11994
    }
12104
    }
11995
 
12105
 
11996
    /**
12106
    /**
11997
     * Performs a deep copy on <i>other</i>.
12107
     * Performs a deep copy on <i>other</i>.
11998
     */
12108
     */
Line 12001... Line 12111...
12001
      __isset_bit_vector.or(other.__isset_bit_vector);
12111
      __isset_bit_vector.or(other.__isset_bit_vector);
12002
      this.fromShippingDate = other.fromShippingDate;
12112
      this.fromShippingDate = other.fromShippingDate;
12003
      this.toShippingDate = other.toShippingDate;
12113
      this.toShippingDate = other.toShippingDate;
12004
      this.providerId = other.providerId;
12114
      this.providerId = other.providerId;
12005
      this.warehouseId = other.warehouseId;
12115
      this.warehouseId = other.warehouseId;
-
 
12116
      this.cod = other.cod;
12006
    }
12117
    }
12007
 
12118
 
12008
    public getOrdersByShippingDate_args deepCopy() {
12119
    public getOrdersByShippingDate_args deepCopy() {
12009
      return new getOrdersByShippingDate_args(this);
12120
      return new getOrdersByShippingDate_args(this);
12010
    }
12121
    }
Line 12017... Line 12128...
12017
      this.toShippingDate = 0;
12128
      this.toShippingDate = 0;
12018
      setProviderIdIsSet(false);
12129
      setProviderIdIsSet(false);
12019
      this.providerId = 0;
12130
      this.providerId = 0;
12020
      setWarehouseIdIsSet(false);
12131
      setWarehouseIdIsSet(false);
12021
      this.warehouseId = 0;
12132
      this.warehouseId = 0;
-
 
12133
      setCodIsSet(false);
-
 
12134
      this.cod = false;
12022
    }
12135
    }
12023
 
12136
 
12024
    public long getFromShippingDate() {
12137
    public long getFromShippingDate() {
12025
      return this.fromShippingDate;
12138
      return this.fromShippingDate;
12026
    }
12139
    }
Line 12107... Line 12220...
12107
 
12220
 
12108
    public void setWarehouseIdIsSet(boolean value) {
12221
    public void setWarehouseIdIsSet(boolean value) {
12109
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12222
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12110
    }
12223
    }
12111
 
12224
 
-
 
12225
    public boolean isCod() {
-
 
12226
      return this.cod;
-
 
12227
    }
-
 
12228
 
-
 
12229
    public void setCod(boolean cod) {
-
 
12230
      this.cod = cod;
-
 
12231
      setCodIsSet(true);
-
 
12232
    }
-
 
12233
 
-
 
12234
    public void unsetCod() {
-
 
12235
      __isset_bit_vector.clear(__COD_ISSET_ID);
-
 
12236
    }
-
 
12237
 
-
 
12238
    /** Returns true if field cod is set (has been assigned a value) and false otherwise */
-
 
12239
    public boolean isSetCod() {
-
 
12240
      return __isset_bit_vector.get(__COD_ISSET_ID);
-
 
12241
    }
-
 
12242
 
-
 
12243
    public void setCodIsSet(boolean value) {
-
 
12244
      __isset_bit_vector.set(__COD_ISSET_ID, value);
-
 
12245
    }
-
 
12246
 
12112
    public void setFieldValue(_Fields field, Object value) {
12247
    public void setFieldValue(_Fields field, Object value) {
12113
      switch (field) {
12248
      switch (field) {
12114
      case FROM_SHIPPING_DATE:
12249
      case FROM_SHIPPING_DATE:
12115
        if (value == null) {
12250
        if (value == null) {
12116
          unsetFromShippingDate();
12251
          unsetFromShippingDate();
Line 12141... Line 12276...
12141
        } else {
12276
        } else {
12142
          setWarehouseId((Long)value);
12277
          setWarehouseId((Long)value);
12143
        }
12278
        }
12144
        break;
12279
        break;
12145
 
12280
 
-
 
12281
      case COD:
-
 
12282
        if (value == null) {
-
 
12283
          unsetCod();
-
 
12284
        } else {
-
 
12285
          setCod((Boolean)value);
-
 
12286
        }
-
 
12287
        break;
-
 
12288
 
12146
      }
12289
      }
12147
    }
12290
    }
12148
 
12291
 
12149
    public Object getFieldValue(_Fields field) {
12292
    public Object getFieldValue(_Fields field) {
12150
      switch (field) {
12293
      switch (field) {
Line 12158... Line 12301...
12158
        return Long.valueOf(getProviderId());
12301
        return Long.valueOf(getProviderId());
12159
 
12302
 
12160
      case WAREHOUSE_ID:
12303
      case WAREHOUSE_ID:
12161
        return Long.valueOf(getWarehouseId());
12304
        return Long.valueOf(getWarehouseId());
12162
 
12305
 
-
 
12306
      case COD:
-
 
12307
        return Boolean.valueOf(isCod());
-
 
12308
 
12163
      }
12309
      }
12164
      throw new IllegalStateException();
12310
      throw new IllegalStateException();
12165
    }
12311
    }
12166
 
12312
 
12167
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12313
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
Line 12177... Line 12323...
12177
        return isSetToShippingDate();
12323
        return isSetToShippingDate();
12178
      case PROVIDER_ID:
12324
      case PROVIDER_ID:
12179
        return isSetProviderId();
12325
        return isSetProviderId();
12180
      case WAREHOUSE_ID:
12326
      case WAREHOUSE_ID:
12181
        return isSetWarehouseId();
12327
        return isSetWarehouseId();
-
 
12328
      case COD:
-
 
12329
        return isSetCod();
12182
      }
12330
      }
12183
      throw new IllegalStateException();
12331
      throw new IllegalStateException();
12184
    }
12332
    }
12185
 
12333
 
12186
    @Override
12334
    @Override
Line 12230... Line 12378...
12230
          return false;
12378
          return false;
12231
        if (this.warehouseId != that.warehouseId)
12379
        if (this.warehouseId != that.warehouseId)
12232
          return false;
12380
          return false;
12233
      }
12381
      }
12234
 
12382
 
-
 
12383
      boolean this_present_cod = true;
-
 
12384
      boolean that_present_cod = true;
-
 
12385
      if (this_present_cod || that_present_cod) {
-
 
12386
        if (!(this_present_cod && that_present_cod))
-
 
12387
          return false;
-
 
12388
        if (this.cod != that.cod)
-
 
12389
          return false;
-
 
12390
      }
-
 
12391
 
12235
      return true;
12392
      return true;
12236
    }
12393
    }
12237
 
12394
 
12238
    @Override
12395
    @Override
12239
    public int hashCode() {
12396
    public int hashCode() {
Line 12286... Line 12443...
12286
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
12443
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
12287
        if (lastComparison != 0) {
12444
        if (lastComparison != 0) {
12288
          return lastComparison;
12445
          return lastComparison;
12289
        }
12446
        }
12290
      }
12447
      }
-
 
12448
      lastComparison = Boolean.valueOf(isSetCod()).compareTo(typedOther.isSetCod());
-
 
12449
      if (lastComparison != 0) {
-
 
12450
        return lastComparison;
-
 
12451
      }
-
 
12452
      if (isSetCod()) {
-
 
12453
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cod, typedOther.cod);
-
 
12454
        if (lastComparison != 0) {
-
 
12455
          return lastComparison;
-
 
12456
        }
-
 
12457
      }
12291
      return 0;
12458
      return 0;
12292
    }
12459
    }
12293
 
12460
 
12294
    public _Fields fieldForId(int fieldId) {
12461
    public _Fields fieldForId(int fieldId) {
12295
      return _Fields.findByThriftId(fieldId);
12462
      return _Fields.findByThriftId(fieldId);
Line 12335... Line 12502...
12335
              setWarehouseIdIsSet(true);
12502
              setWarehouseIdIsSet(true);
12336
            } else { 
12503
            } else { 
12337
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12504
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12338
            }
12505
            }
12339
            break;
12506
            break;
-
 
12507
          case 5: // COD
-
 
12508
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
-
 
12509
              this.cod = iprot.readBool();
-
 
12510
              setCodIsSet(true);
-
 
12511
            } else { 
-
 
12512
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
12513
            }
-
 
12514
            break;
12340
          default:
12515
          default:
12341
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12516
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12342
        }
12517
        }
12343
        iprot.readFieldEnd();
12518
        iprot.readFieldEnd();
12344
      }
12519
      }
Line 12360... Line 12535...
12360
      oprot.writeI64(this.providerId);
12535
      oprot.writeI64(this.providerId);
12361
      oprot.writeFieldEnd();
12536
      oprot.writeFieldEnd();
12362
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
12537
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
12363
      oprot.writeI64(this.warehouseId);
12538
      oprot.writeI64(this.warehouseId);
12364
      oprot.writeFieldEnd();
12539
      oprot.writeFieldEnd();
-
 
12540
      oprot.writeFieldBegin(COD_FIELD_DESC);
-
 
12541
      oprot.writeBool(this.cod);
-
 
12542
      oprot.writeFieldEnd();
12365
      oprot.writeFieldStop();
12543
      oprot.writeFieldStop();
12366
      oprot.writeStructEnd();
12544
      oprot.writeStructEnd();
12367
    }
12545
    }
12368
 
12546
 
12369
    @Override
12547
    @Override
Line 12384... Line 12562...
12384
      first = false;
12562
      first = false;
12385
      if (!first) sb.append(", ");
12563
      if (!first) sb.append(", ");
12386
      sb.append("warehouseId:");
12564
      sb.append("warehouseId:");
12387
      sb.append(this.warehouseId);
12565
      sb.append(this.warehouseId);
12388
      first = false;
12566
      first = false;
-
 
12567
      if (!first) sb.append(", ");
-
 
12568
      sb.append("cod:");
-
 
12569
      sb.append(this.cod);
-
 
12570
      first = false;
12389
      sb.append(")");
12571
      sb.append(")");
12390
      return sb.toString();
12572
      return sb.toString();
12391
    }
12573
    }
12392
 
12574
 
12393
    public void validate() throws org.apache.thrift.TException {
12575
    public void validate() throws org.apache.thrift.TException {
Line 41902... Line 42084...
41902
      first = false;
42084
      first = false;
41903
      if (!first) sb.append(", ");
42085
      if (!first) sb.append(", ");
41904
      sb.append("ex:");
42086
      sb.append("ex:");
41905
      if (this.ex == null) {
42087
      if (this.ex == null) {
41906
        sb.append("null");
42088
        sb.append("null");
-
 
42089
      } else {
-
 
42090
        sb.append(this.ex);
-
 
42091
      }
-
 
42092
      first = false;
-
 
42093
      sb.append(")");
-
 
42094
      return sb.toString();
-
 
42095
    }
-
 
42096
 
-
 
42097
    public void validate() throws org.apache.thrift.TException {
-
 
42098
      // check for required fields
-
 
42099
    }
-
 
42100
 
-
 
42101
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
42102
      try {
-
 
42103
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
42104
      } catch (org.apache.thrift.TException te) {
-
 
42105
        throw new java.io.IOException(te);
-
 
42106
      }
-
 
42107
    }
-
 
42108
 
-
 
42109
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
42110
      try {
-
 
42111
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
42112
      } catch (org.apache.thrift.TException te) {
-
 
42113
        throw new java.io.IOException(te);
-
 
42114
      }
-
 
42115
    }
-
 
42116
 
-
 
42117
  }
-
 
42118
 
-
 
42119
  public static class updateWeight_args implements org.apache.thrift.TBase<updateWeight_args, updateWeight_args._Fields>, java.io.Serializable, Cloneable   {
-
 
42120
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateWeight_args");
-
 
42121
 
-
 
42122
    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);
-
 
42123
    private static final org.apache.thrift.protocol.TField WEIGHT_FIELD_DESC = new org.apache.thrift.protocol.TField("weight", org.apache.thrift.protocol.TType.DOUBLE, (short)2);
-
 
42124
 
-
 
42125
    private long orderId; // required
-
 
42126
    private double weight; // required
-
 
42127
 
-
 
42128
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
42129
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
42130
      ORDER_ID((short)1, "orderId"),
-
 
42131
      WEIGHT((short)2, "weight");
-
 
42132
 
-
 
42133
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
42134
 
-
 
42135
      static {
-
 
42136
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
42137
          byName.put(field.getFieldName(), field);
-
 
42138
        }
-
 
42139
      }
-
 
42140
 
-
 
42141
      /**
-
 
42142
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
42143
       */
-
 
42144
      public static _Fields findByThriftId(int fieldId) {
-
 
42145
        switch(fieldId) {
-
 
42146
          case 1: // ORDER_ID
-
 
42147
            return ORDER_ID;
-
 
42148
          case 2: // WEIGHT
-
 
42149
            return WEIGHT;
-
 
42150
          default:
-
 
42151
            return null;
-
 
42152
        }
-
 
42153
      }
-
 
42154
 
-
 
42155
      /**
-
 
42156
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
42157
       * if it is not found.
-
 
42158
       */
-
 
42159
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
42160
        _Fields fields = findByThriftId(fieldId);
-
 
42161
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
42162
        return fields;
-
 
42163
      }
-
 
42164
 
-
 
42165
      /**
-
 
42166
       * Find the _Fields constant that matches name, or null if its not found.
-
 
42167
       */
-
 
42168
      public static _Fields findByName(String name) {
-
 
42169
        return byName.get(name);
-
 
42170
      }
-
 
42171
 
-
 
42172
      private final short _thriftId;
-
 
42173
      private final String _fieldName;
-
 
42174
 
-
 
42175
      _Fields(short thriftId, String fieldName) {
-
 
42176
        _thriftId = thriftId;
-
 
42177
        _fieldName = fieldName;
-
 
42178
      }
-
 
42179
 
-
 
42180
      public short getThriftFieldId() {
-
 
42181
        return _thriftId;
-
 
42182
      }
-
 
42183
 
-
 
42184
      public String getFieldName() {
-
 
42185
        return _fieldName;
-
 
42186
      }
-
 
42187
    }
-
 
42188
 
-
 
42189
    // isset id assignments
-
 
42190
    private static final int __ORDERID_ISSET_ID = 0;
-
 
42191
    private static final int __WEIGHT_ISSET_ID = 1;
-
 
42192
    private BitSet __isset_bit_vector = new BitSet(2);
-
 
42193
 
-
 
42194
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
42195
    static {
-
 
42196
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
42197
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
42198
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
42199
      tmpMap.put(_Fields.WEIGHT, new org.apache.thrift.meta_data.FieldMetaData("weight", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
42200
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
-
 
42201
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
42202
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateWeight_args.class, metaDataMap);
-
 
42203
    }
-
 
42204
 
-
 
42205
    public updateWeight_args() {
-
 
42206
    }
-
 
42207
 
-
 
42208
    public updateWeight_args(
-
 
42209
      long orderId,
-
 
42210
      double weight)
-
 
42211
    {
-
 
42212
      this();
-
 
42213
      this.orderId = orderId;
-
 
42214
      setOrderIdIsSet(true);
-
 
42215
      this.weight = weight;
-
 
42216
      setWeightIsSet(true);
-
 
42217
    }
-
 
42218
 
-
 
42219
    /**
-
 
42220
     * Performs a deep copy on <i>other</i>.
-
 
42221
     */
-
 
42222
    public updateWeight_args(updateWeight_args other) {
-
 
42223
      __isset_bit_vector.clear();
-
 
42224
      __isset_bit_vector.or(other.__isset_bit_vector);
-
 
42225
      this.orderId = other.orderId;
-
 
42226
      this.weight = other.weight;
-
 
42227
    }
-
 
42228
 
-
 
42229
    public updateWeight_args deepCopy() {
-
 
42230
      return new updateWeight_args(this);
-
 
42231
    }
-
 
42232
 
-
 
42233
    @Override
-
 
42234
    public void clear() {
-
 
42235
      setOrderIdIsSet(false);
-
 
42236
      this.orderId = 0;
-
 
42237
      setWeightIsSet(false);
-
 
42238
      this.weight = 0.0;
-
 
42239
    }
-
 
42240
 
-
 
42241
    public long getOrderId() {
-
 
42242
      return this.orderId;
-
 
42243
    }
-
 
42244
 
-
 
42245
    public void setOrderId(long orderId) {
-
 
42246
      this.orderId = orderId;
-
 
42247
      setOrderIdIsSet(true);
-
 
42248
    }
-
 
42249
 
-
 
42250
    public void unsetOrderId() {
-
 
42251
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
-
 
42252
    }
-
 
42253
 
-
 
42254
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
-
 
42255
    public boolean isSetOrderId() {
-
 
42256
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
-
 
42257
    }
-
 
42258
 
-
 
42259
    public void setOrderIdIsSet(boolean value) {
-
 
42260
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
-
 
42261
    }
-
 
42262
 
-
 
42263
    public double getWeight() {
-
 
42264
      return this.weight;
-
 
42265
    }
-
 
42266
 
-
 
42267
    public void setWeight(double weight) {
-
 
42268
      this.weight = weight;
-
 
42269
      setWeightIsSet(true);
-
 
42270
    }
-
 
42271
 
-
 
42272
    public void unsetWeight() {
-
 
42273
      __isset_bit_vector.clear(__WEIGHT_ISSET_ID);
-
 
42274
    }
-
 
42275
 
-
 
42276
    /** Returns true if field weight is set (has been assigned a value) and false otherwise */
-
 
42277
    public boolean isSetWeight() {
-
 
42278
      return __isset_bit_vector.get(__WEIGHT_ISSET_ID);
-
 
42279
    }
-
 
42280
 
-
 
42281
    public void setWeightIsSet(boolean value) {
-
 
42282
      __isset_bit_vector.set(__WEIGHT_ISSET_ID, value);
-
 
42283
    }
-
 
42284
 
-
 
42285
    public void setFieldValue(_Fields field, Object value) {
-
 
42286
      switch (field) {
-
 
42287
      case ORDER_ID:
-
 
42288
        if (value == null) {
-
 
42289
          unsetOrderId();
-
 
42290
        } else {
-
 
42291
          setOrderId((Long)value);
-
 
42292
        }
-
 
42293
        break;
-
 
42294
 
-
 
42295
      case WEIGHT:
-
 
42296
        if (value == null) {
-
 
42297
          unsetWeight();
-
 
42298
        } else {
-
 
42299
          setWeight((Double)value);
-
 
42300
        }
-
 
42301
        break;
-
 
42302
 
-
 
42303
      }
-
 
42304
    }
-
 
42305
 
-
 
42306
    public Object getFieldValue(_Fields field) {
-
 
42307
      switch (field) {
-
 
42308
      case ORDER_ID:
-
 
42309
        return Long.valueOf(getOrderId());
-
 
42310
 
-
 
42311
      case WEIGHT:
-
 
42312
        return Double.valueOf(getWeight());
-
 
42313
 
-
 
42314
      }
-
 
42315
      throw new IllegalStateException();
-
 
42316
    }
-
 
42317
 
-
 
42318
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
42319
    public boolean isSet(_Fields field) {
-
 
42320
      if (field == null) {
-
 
42321
        throw new IllegalArgumentException();
-
 
42322
      }
-
 
42323
 
-
 
42324
      switch (field) {
-
 
42325
      case ORDER_ID:
-
 
42326
        return isSetOrderId();
-
 
42327
      case WEIGHT:
-
 
42328
        return isSetWeight();
-
 
42329
      }
-
 
42330
      throw new IllegalStateException();
-
 
42331
    }
-
 
42332
 
-
 
42333
    @Override
-
 
42334
    public boolean equals(Object that) {
-
 
42335
      if (that == null)
-
 
42336
        return false;
-
 
42337
      if (that instanceof updateWeight_args)
-
 
42338
        return this.equals((updateWeight_args)that);
-
 
42339
      return false;
-
 
42340
    }
-
 
42341
 
-
 
42342
    public boolean equals(updateWeight_args that) {
-
 
42343
      if (that == null)
-
 
42344
        return false;
-
 
42345
 
-
 
42346
      boolean this_present_orderId = true;
-
 
42347
      boolean that_present_orderId = true;
-
 
42348
      if (this_present_orderId || that_present_orderId) {
-
 
42349
        if (!(this_present_orderId && that_present_orderId))
-
 
42350
          return false;
-
 
42351
        if (this.orderId != that.orderId)
-
 
42352
          return false;
-
 
42353
      }
-
 
42354
 
-
 
42355
      boolean this_present_weight = true;
-
 
42356
      boolean that_present_weight = true;
-
 
42357
      if (this_present_weight || that_present_weight) {
-
 
42358
        if (!(this_present_weight && that_present_weight))
-
 
42359
          return false;
-
 
42360
        if (this.weight != that.weight)
-
 
42361
          return false;
-
 
42362
      }
-
 
42363
 
-
 
42364
      return true;
-
 
42365
    }
-
 
42366
 
-
 
42367
    @Override
-
 
42368
    public int hashCode() {
-
 
42369
      return 0;
-
 
42370
    }
-
 
42371
 
-
 
42372
    public int compareTo(updateWeight_args other) {
-
 
42373
      if (!getClass().equals(other.getClass())) {
-
 
42374
        return getClass().getName().compareTo(other.getClass().getName());
-
 
42375
      }
-
 
42376
 
-
 
42377
      int lastComparison = 0;
-
 
42378
      updateWeight_args typedOther = (updateWeight_args)other;
-
 
42379
 
-
 
42380
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
-
 
42381
      if (lastComparison != 0) {
-
 
42382
        return lastComparison;
-
 
42383
      }
-
 
42384
      if (isSetOrderId()) {
-
 
42385
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
-
 
42386
        if (lastComparison != 0) {
-
 
42387
          return lastComparison;
-
 
42388
        }
-
 
42389
      }
-
 
42390
      lastComparison = Boolean.valueOf(isSetWeight()).compareTo(typedOther.isSetWeight());
-
 
42391
      if (lastComparison != 0) {
-
 
42392
        return lastComparison;
-
 
42393
      }
-
 
42394
      if (isSetWeight()) {
-
 
42395
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.weight, typedOther.weight);
-
 
42396
        if (lastComparison != 0) {
-
 
42397
          return lastComparison;
-
 
42398
        }
-
 
42399
      }
-
 
42400
      return 0;
-
 
42401
    }
-
 
42402
 
-
 
42403
    public _Fields fieldForId(int fieldId) {
-
 
42404
      return _Fields.findByThriftId(fieldId);
-
 
42405
    }
-
 
42406
 
-
 
42407
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
42408
      org.apache.thrift.protocol.TField field;
-
 
42409
      iprot.readStructBegin();
-
 
42410
      while (true)
-
 
42411
      {
-
 
42412
        field = iprot.readFieldBegin();
-
 
42413
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
42414
          break;
-
 
42415
        }
-
 
42416
        switch (field.id) {
-
 
42417
          case 1: // ORDER_ID
-
 
42418
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
42419
              this.orderId = iprot.readI64();
-
 
42420
              setOrderIdIsSet(true);
-
 
42421
            } else { 
-
 
42422
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
42423
            }
-
 
42424
            break;
-
 
42425
          case 2: // WEIGHT
-
 
42426
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
-
 
42427
              this.weight = iprot.readDouble();
-
 
42428
              setWeightIsSet(true);
-
 
42429
            } else { 
-
 
42430
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
42431
            }
-
 
42432
            break;
-
 
42433
          default:
-
 
42434
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
42435
        }
-
 
42436
        iprot.readFieldEnd();
-
 
42437
      }
-
 
42438
      iprot.readStructEnd();
-
 
42439
      validate();
-
 
42440
    }
-
 
42441
 
-
 
42442
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
42443
      validate();
-
 
42444
 
-
 
42445
      oprot.writeStructBegin(STRUCT_DESC);
-
 
42446
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
-
 
42447
      oprot.writeI64(this.orderId);
-
 
42448
      oprot.writeFieldEnd();
-
 
42449
      oprot.writeFieldBegin(WEIGHT_FIELD_DESC);
-
 
42450
      oprot.writeDouble(this.weight);
-
 
42451
      oprot.writeFieldEnd();
-
 
42452
      oprot.writeFieldStop();
-
 
42453
      oprot.writeStructEnd();
-
 
42454
    }
-
 
42455
 
-
 
42456
    @Override
-
 
42457
    public String toString() {
-
 
42458
      StringBuilder sb = new StringBuilder("updateWeight_args(");
-
 
42459
      boolean first = true;
-
 
42460
 
-
 
42461
      sb.append("orderId:");
-
 
42462
      sb.append(this.orderId);
-
 
42463
      first = false;
-
 
42464
      if (!first) sb.append(", ");
-
 
42465
      sb.append("weight:");
-
 
42466
      sb.append(this.weight);
-
 
42467
      first = false;
-
 
42468
      sb.append(")");
-
 
42469
      return sb.toString();
-
 
42470
    }
-
 
42471
 
-
 
42472
    public void validate() throws org.apache.thrift.TException {
-
 
42473
      // check for required fields
-
 
42474
    }
-
 
42475
 
-
 
42476
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
42477
      try {
-
 
42478
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
42479
      } catch (org.apache.thrift.TException te) {
-
 
42480
        throw new java.io.IOException(te);
-
 
42481
      }
-
 
42482
    }
-
 
42483
 
-
 
42484
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
42485
      try {
-
 
42486
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
42487
      } catch (org.apache.thrift.TException te) {
-
 
42488
        throw new java.io.IOException(te);
-
 
42489
      }
-
 
42490
    }
-
 
42491
 
-
 
42492
  }
-
 
42493
 
-
 
42494
  public static class updateWeight_result implements org.apache.thrift.TBase<updateWeight_result, updateWeight_result._Fields>, java.io.Serializable, Cloneable   {
-
 
42495
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateWeight_result");
-
 
42496
 
-
 
42497
    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);
-
 
42498
    private static final org.apache.thrift.protocol.TField EX_FIELD_DESC = new org.apache.thrift.protocol.TField("ex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
-
 
42499
 
-
 
42500
    private Order success; // required
-
 
42501
    private TransactionServiceException ex; // required
-
 
42502
 
-
 
42503
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
42504
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
42505
      SUCCESS((short)0, "success"),
-
 
42506
      EX((short)1, "ex");
-
 
42507
 
-
 
42508
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
42509
 
-
 
42510
      static {
-
 
42511
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
42512
          byName.put(field.getFieldName(), field);
-
 
42513
        }
-
 
42514
      }
-
 
42515
 
-
 
42516
      /**
-
 
42517
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
42518
       */
-
 
42519
      public static _Fields findByThriftId(int fieldId) {
-
 
42520
        switch(fieldId) {
-
 
42521
          case 0: // SUCCESS
-
 
42522
            return SUCCESS;
-
 
42523
          case 1: // EX
-
 
42524
            return EX;
-
 
42525
          default:
-
 
42526
            return null;
-
 
42527
        }
-
 
42528
      }
-
 
42529
 
-
 
42530
      /**
-
 
42531
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
42532
       * if it is not found.
-
 
42533
       */
-
 
42534
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
42535
        _Fields fields = findByThriftId(fieldId);
-
 
42536
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
42537
        return fields;
-
 
42538
      }
-
 
42539
 
-
 
42540
      /**
-
 
42541
       * Find the _Fields constant that matches name, or null if its not found.
-
 
42542
       */
-
 
42543
      public static _Fields findByName(String name) {
-
 
42544
        return byName.get(name);
-
 
42545
      }
-
 
42546
 
-
 
42547
      private final short _thriftId;
-
 
42548
      private final String _fieldName;
-
 
42549
 
-
 
42550
      _Fields(short thriftId, String fieldName) {
-
 
42551
        _thriftId = thriftId;
-
 
42552
        _fieldName = fieldName;
-
 
42553
      }
-
 
42554
 
-
 
42555
      public short getThriftFieldId() {
-
 
42556
        return _thriftId;
-
 
42557
      }
-
 
42558
 
-
 
42559
      public String getFieldName() {
-
 
42560
        return _fieldName;
-
 
42561
      }
-
 
42562
    }
-
 
42563
 
-
 
42564
    // isset id assignments
-
 
42565
 
-
 
42566
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
42567
    static {
-
 
42568
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
42569
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
42570
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Order.class)));
-
 
42571
      tmpMap.put(_Fields.EX, new org.apache.thrift.meta_data.FieldMetaData("ex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
42572
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
-
 
42573
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
42574
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateWeight_result.class, metaDataMap);
-
 
42575
    }
-
 
42576
 
-
 
42577
    public updateWeight_result() {
-
 
42578
    }
-
 
42579
 
-
 
42580
    public updateWeight_result(
-
 
42581
      Order success,
-
 
42582
      TransactionServiceException ex)
-
 
42583
    {
-
 
42584
      this();
-
 
42585
      this.success = success;
-
 
42586
      this.ex = ex;
-
 
42587
    }
-
 
42588
 
-
 
42589
    /**
-
 
42590
     * Performs a deep copy on <i>other</i>.
-
 
42591
     */
-
 
42592
    public updateWeight_result(updateWeight_result other) {
-
 
42593
      if (other.isSetSuccess()) {
-
 
42594
        this.success = new Order(other.success);
-
 
42595
      }
-
 
42596
      if (other.isSetEx()) {
-
 
42597
        this.ex = new TransactionServiceException(other.ex);
-
 
42598
      }
-
 
42599
    }
-
 
42600
 
-
 
42601
    public updateWeight_result deepCopy() {
-
 
42602
      return new updateWeight_result(this);
-
 
42603
    }
-
 
42604
 
-
 
42605
    @Override
-
 
42606
    public void clear() {
-
 
42607
      this.success = null;
-
 
42608
      this.ex = null;
-
 
42609
    }
-
 
42610
 
-
 
42611
    public Order getSuccess() {
-
 
42612
      return this.success;
-
 
42613
    }
-
 
42614
 
-
 
42615
    public void setSuccess(Order success) {
-
 
42616
      this.success = success;
-
 
42617
    }
-
 
42618
 
-
 
42619
    public void unsetSuccess() {
-
 
42620
      this.success = null;
-
 
42621
    }
-
 
42622
 
-
 
42623
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
-
 
42624
    public boolean isSetSuccess() {
-
 
42625
      return this.success != null;
-
 
42626
    }
-
 
42627
 
-
 
42628
    public void setSuccessIsSet(boolean value) {
-
 
42629
      if (!value) {
-
 
42630
        this.success = null;
-
 
42631
      }
-
 
42632
    }
-
 
42633
 
-
 
42634
    public TransactionServiceException getEx() {
-
 
42635
      return this.ex;
-
 
42636
    }
-
 
42637
 
-
 
42638
    public void setEx(TransactionServiceException ex) {
-
 
42639
      this.ex = ex;
-
 
42640
    }
-
 
42641
 
-
 
42642
    public void unsetEx() {
-
 
42643
      this.ex = null;
-
 
42644
    }
-
 
42645
 
-
 
42646
    /** Returns true if field ex is set (has been assigned a value) and false otherwise */
-
 
42647
    public boolean isSetEx() {
-
 
42648
      return this.ex != null;
-
 
42649
    }
-
 
42650
 
-
 
42651
    public void setExIsSet(boolean value) {
-
 
42652
      if (!value) {
-
 
42653
        this.ex = null;
-
 
42654
      }
-
 
42655
    }
-
 
42656
 
-
 
42657
    public void setFieldValue(_Fields field, Object value) {
-
 
42658
      switch (field) {
-
 
42659
      case SUCCESS:
-
 
42660
        if (value == null) {
-
 
42661
          unsetSuccess();
-
 
42662
        } else {
-
 
42663
          setSuccess((Order)value);
-
 
42664
        }
-
 
42665
        break;
-
 
42666
 
-
 
42667
      case EX:
-
 
42668
        if (value == null) {
-
 
42669
          unsetEx();
-
 
42670
        } else {
-
 
42671
          setEx((TransactionServiceException)value);
-
 
42672
        }
-
 
42673
        break;
-
 
42674
 
-
 
42675
      }
-
 
42676
    }
-
 
42677
 
-
 
42678
    public Object getFieldValue(_Fields field) {
-
 
42679
      switch (field) {
-
 
42680
      case SUCCESS:
-
 
42681
        return getSuccess();
-
 
42682
 
-
 
42683
      case EX:
-
 
42684
        return getEx();
-
 
42685
 
-
 
42686
      }
-
 
42687
      throw new IllegalStateException();
-
 
42688
    }
-
 
42689
 
-
 
42690
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
42691
    public boolean isSet(_Fields field) {
-
 
42692
      if (field == null) {
-
 
42693
        throw new IllegalArgumentException();
-
 
42694
      }
-
 
42695
 
-
 
42696
      switch (field) {
-
 
42697
      case SUCCESS:
-
 
42698
        return isSetSuccess();
-
 
42699
      case EX:
-
 
42700
        return isSetEx();
-
 
42701
      }
-
 
42702
      throw new IllegalStateException();
-
 
42703
    }
-
 
42704
 
-
 
42705
    @Override
-
 
42706
    public boolean equals(Object that) {
-
 
42707
      if (that == null)
-
 
42708
        return false;
-
 
42709
      if (that instanceof updateWeight_result)
-
 
42710
        return this.equals((updateWeight_result)that);
-
 
42711
      return false;
-
 
42712
    }
-
 
42713
 
-
 
42714
    public boolean equals(updateWeight_result that) {
-
 
42715
      if (that == null)
-
 
42716
        return false;
-
 
42717
 
-
 
42718
      boolean this_present_success = true && this.isSetSuccess();
-
 
42719
      boolean that_present_success = true && that.isSetSuccess();
-
 
42720
      if (this_present_success || that_present_success) {
-
 
42721
        if (!(this_present_success && that_present_success))
-
 
42722
          return false;
-
 
42723
        if (!this.success.equals(that.success))
-
 
42724
          return false;
-
 
42725
      }
-
 
42726
 
-
 
42727
      boolean this_present_ex = true && this.isSetEx();
-
 
42728
      boolean that_present_ex = true && that.isSetEx();
-
 
42729
      if (this_present_ex || that_present_ex) {
-
 
42730
        if (!(this_present_ex && that_present_ex))
-
 
42731
          return false;
-
 
42732
        if (!this.ex.equals(that.ex))
-
 
42733
          return false;
-
 
42734
      }
-
 
42735
 
-
 
42736
      return true;
-
 
42737
    }
-
 
42738
 
-
 
42739
    @Override
-
 
42740
    public int hashCode() {
-
 
42741
      return 0;
-
 
42742
    }
-
 
42743
 
-
 
42744
    public int compareTo(updateWeight_result other) {
-
 
42745
      if (!getClass().equals(other.getClass())) {
-
 
42746
        return getClass().getName().compareTo(other.getClass().getName());
-
 
42747
      }
-
 
42748
 
-
 
42749
      int lastComparison = 0;
-
 
42750
      updateWeight_result typedOther = (updateWeight_result)other;
-
 
42751
 
-
 
42752
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
-
 
42753
      if (lastComparison != 0) {
-
 
42754
        return lastComparison;
-
 
42755
      }
-
 
42756
      if (isSetSuccess()) {
-
 
42757
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
-
 
42758
        if (lastComparison != 0) {
-
 
42759
          return lastComparison;
-
 
42760
        }
-
 
42761
      }
-
 
42762
      lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx());
-
 
42763
      if (lastComparison != 0) {
-
 
42764
        return lastComparison;
-
 
42765
      }
-
 
42766
      if (isSetEx()) {
-
 
42767
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex);
-
 
42768
        if (lastComparison != 0) {
-
 
42769
          return lastComparison;
-
 
42770
        }
-
 
42771
      }
-
 
42772
      return 0;
-
 
42773
    }
-
 
42774
 
-
 
42775
    public _Fields fieldForId(int fieldId) {
-
 
42776
      return _Fields.findByThriftId(fieldId);
-
 
42777
    }
-
 
42778
 
-
 
42779
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
42780
      org.apache.thrift.protocol.TField field;
-
 
42781
      iprot.readStructBegin();
-
 
42782
      while (true)
-
 
42783
      {
-
 
42784
        field = iprot.readFieldBegin();
-
 
42785
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
42786
          break;
-
 
42787
        }
-
 
42788
        switch (field.id) {
-
 
42789
          case 0: // SUCCESS
-
 
42790
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
42791
              this.success = new Order();
-
 
42792
              this.success.read(iprot);
-
 
42793
            } else { 
-
 
42794
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
42795
            }
-
 
42796
            break;
-
 
42797
          case 1: // EX
-
 
42798
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
42799
              this.ex = new TransactionServiceException();
-
 
42800
              this.ex.read(iprot);
-
 
42801
            } else { 
-
 
42802
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
42803
            }
-
 
42804
            break;
-
 
42805
          default:
-
 
42806
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
42807
        }
-
 
42808
        iprot.readFieldEnd();
-
 
42809
      }
-
 
42810
      iprot.readStructEnd();
-
 
42811
      validate();
-
 
42812
    }
-
 
42813
 
-
 
42814
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
42815
      oprot.writeStructBegin(STRUCT_DESC);
-
 
42816
 
-
 
42817
      if (this.isSetSuccess()) {
-
 
42818
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
-
 
42819
        this.success.write(oprot);
-
 
42820
        oprot.writeFieldEnd();
-
 
42821
      } else if (this.isSetEx()) {
-
 
42822
        oprot.writeFieldBegin(EX_FIELD_DESC);
-
 
42823
        this.ex.write(oprot);
-
 
42824
        oprot.writeFieldEnd();
-
 
42825
      }
-
 
42826
      oprot.writeFieldStop();
-
 
42827
      oprot.writeStructEnd();
-
 
42828
    }
-
 
42829
 
-
 
42830
    @Override
-
 
42831
    public String toString() {
-
 
42832
      StringBuilder sb = new StringBuilder("updateWeight_result(");
-
 
42833
      boolean first = true;
-
 
42834
 
-
 
42835
      sb.append("success:");
-
 
42836
      if (this.success == null) {
-
 
42837
        sb.append("null");
-
 
42838
      } else {
-
 
42839
        sb.append(this.success);
-
 
42840
      }
-
 
42841
      first = false;
-
 
42842
      if (!first) sb.append(", ");
-
 
42843
      sb.append("ex:");
-
 
42844
      if (this.ex == null) {
-
 
42845
        sb.append("null");
41907
      } else {
42846
      } else {
41908
        sb.append(this.ex);
42847
        sb.append(this.ex);
41909
      }
42848
      }
41910
      first = false;
42849
      first = false;
41911
      sb.append(")");
42850
      sb.append(")");