Subversion Repositories SmartDukaan

Rev

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

Rev 3451 Rev 3469
Line 416... Line 416...
416
     * @param orderId
416
     * @param orderId
417
     * @param weight
417
     * @param weight
418
     */
418
     */
419
    public Order updateWeight(long orderId, double weight) throws TransactionServiceException, org.apache.thrift.TException;
419
    public Order updateWeight(long orderId, double weight) throws TransactionServiceException, org.apache.thrift.TException;
420
 
420
 
-
 
421
    /**
-
 
422
     * Change the item to be shipped for this order. Also adjusts the reservation in the inventory accordingly.
-
 
423
     * Currently, it also ensures that only a different color of the given item is shipped.
-
 
424
     * 
-
 
425
     * @param orderId
-
 
426
     * @param itemId
-
 
427
     */
-
 
428
    public Order changeItem(long orderId, long itemId) throws TransactionServiceException, org.apache.thrift.TException;
-
 
429
 
-
 
430
    /**
-
 
431
     * Moves the given order to the given warehouse. Also adjusts the inventory reservations accordingly.
-
 
432
     * 
-
 
433
     * @param orderId
-
 
434
     * @param warehouseId
-
 
435
     */
-
 
436
    public Order shiftToWarehouse(long orderId, long warehouseId) throws TransactionServiceException, org.apache.thrift.TException;
-
 
437
 
421
  }
438
  }
422
 
439
 
423
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
440
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
424
 
441
 
425
    public void createTransaction(Transaction transaction, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createTransaction_call> resultHandler) throws org.apache.thrift.TException;
442
    public void createTransaction(Transaction transaction, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createTransaction_call> resultHandler) throws org.apache.thrift.TException;
Line 522... Line 539...
522
 
539
 
523
    public void createPurchaseOrder(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPurchaseOrder_call> resultHandler) throws org.apache.thrift.TException;
540
    public void createPurchaseOrder(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPurchaseOrder_call> resultHandler) throws org.apache.thrift.TException;
524
 
541
 
525
    public void updateWeight(long orderId, double weight, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateWeight_call> resultHandler) throws org.apache.thrift.TException;
542
    public void updateWeight(long orderId, double weight, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateWeight_call> resultHandler) throws org.apache.thrift.TException;
526
 
543
 
-
 
544
    public void changeItem(long orderId, long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.changeItem_call> resultHandler) throws org.apache.thrift.TException;
-
 
545
 
-
 
546
    public void shiftToWarehouse(long orderId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.shiftToWarehouse_call> resultHandler) throws org.apache.thrift.TException;
-
 
547
 
527
  }
548
  }
528
 
549
 
529
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
550
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
530
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
551
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
531
      public Factory() {}
552
      public Factory() {}
Line 1875... Line 1896...
1875
        throw result.ex;
1896
        throw result.ex;
1876
      }
1897
      }
1877
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "updateWeight failed: unknown result");
1898
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "updateWeight failed: unknown result");
1878
    }
1899
    }
1879
 
1900
 
-
 
1901
    public Order changeItem(long orderId, long itemId) throws TransactionServiceException, org.apache.thrift.TException
-
 
1902
    {
-
 
1903
      send_changeItem(orderId, itemId);
-
 
1904
      return recv_changeItem();
-
 
1905
    }
-
 
1906
 
-
 
1907
    public void send_changeItem(long orderId, long itemId) throws org.apache.thrift.TException
-
 
1908
    {
-
 
1909
      changeItem_args args = new changeItem_args();
-
 
1910
      args.setOrderId(orderId);
-
 
1911
      args.setItemId(itemId);
-
 
1912
      sendBase("changeItem", args);
-
 
1913
    }
-
 
1914
 
-
 
1915
    public Order recv_changeItem() throws TransactionServiceException, org.apache.thrift.TException
-
 
1916
    {
-
 
1917
      changeItem_result result = new changeItem_result();
-
 
1918
      receiveBase(result, "changeItem");
-
 
1919
      if (result.isSetSuccess()) {
-
 
1920
        return result.success;
-
 
1921
      }
-
 
1922
      if (result.ex != null) {
-
 
1923
        throw result.ex;
-
 
1924
      }
-
 
1925
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "changeItem failed: unknown result");
-
 
1926
    }
-
 
1927
 
-
 
1928
    public Order shiftToWarehouse(long orderId, long warehouseId) throws TransactionServiceException, org.apache.thrift.TException
-
 
1929
    {
-
 
1930
      send_shiftToWarehouse(orderId, warehouseId);
-
 
1931
      return recv_shiftToWarehouse();
-
 
1932
    }
-
 
1933
 
-
 
1934
    public void send_shiftToWarehouse(long orderId, long warehouseId) throws org.apache.thrift.TException
-
 
1935
    {
-
 
1936
      shiftToWarehouse_args args = new shiftToWarehouse_args();
-
 
1937
      args.setOrderId(orderId);
-
 
1938
      args.setWarehouseId(warehouseId);
-
 
1939
      sendBase("shiftToWarehouse", args);
-
 
1940
    }
-
 
1941
 
-
 
1942
    public Order recv_shiftToWarehouse() throws TransactionServiceException, org.apache.thrift.TException
-
 
1943
    {
-
 
1944
      shiftToWarehouse_result result = new shiftToWarehouse_result();
-
 
1945
      receiveBase(result, "shiftToWarehouse");
-
 
1946
      if (result.isSetSuccess()) {
-
 
1947
        return result.success;
-
 
1948
      }
-
 
1949
      if (result.ex != null) {
-
 
1950
        throw result.ex;
-
 
1951
      }
-
 
1952
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "shiftToWarehouse failed: unknown result");
-
 
1953
    }
-
 
1954
 
1880
  }
1955
  }
1881
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1956
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1882
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1957
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1883
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1958
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1884
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
1959
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
Line 3666... Line 3741...
3666
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
3741
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
3667
        return (new Client(prot)).recv_updateWeight();
3742
        return (new Client(prot)).recv_updateWeight();
3668
      }
3743
      }
3669
    }
3744
    }
3670
 
3745
 
-
 
3746
    public void changeItem(long orderId, long itemId, org.apache.thrift.async.AsyncMethodCallback<changeItem_call> resultHandler) throws org.apache.thrift.TException {
-
 
3747
      checkReady();
-
 
3748
      changeItem_call method_call = new changeItem_call(orderId, itemId, resultHandler, this, ___protocolFactory, ___transport);
-
 
3749
      this.___currentMethod = method_call;
-
 
3750
      ___manager.call(method_call);
-
 
3751
    }
-
 
3752
 
-
 
3753
    public static class changeItem_call extends org.apache.thrift.async.TAsyncMethodCall {
-
 
3754
      private long orderId;
-
 
3755
      private long itemId;
-
 
3756
      public changeItem_call(long orderId, long itemId, org.apache.thrift.async.AsyncMethodCallback<changeItem_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 {
-
 
3757
        super(client, protocolFactory, transport, resultHandler, false);
-
 
3758
        this.orderId = orderId;
-
 
3759
        this.itemId = itemId;
-
 
3760
      }
-
 
3761
 
-
 
3762
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-
 
3763
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("changeItem", org.apache.thrift.protocol.TMessageType.CALL, 0));
-
 
3764
        changeItem_args args = new changeItem_args();
-
 
3765
        args.setOrderId(orderId);
-
 
3766
        args.setItemId(itemId);
-
 
3767
        args.write(prot);
-
 
3768
        prot.writeMessageEnd();
-
 
3769
      }
-
 
3770
 
-
 
3771
      public Order getResult() throws TransactionServiceException, org.apache.thrift.TException {
-
 
3772
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-
 
3773
          throw new IllegalStateException("Method call not finished!");
-
 
3774
        }
-
 
3775
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-
 
3776
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-
 
3777
        return (new Client(prot)).recv_changeItem();
-
 
3778
      }
-
 
3779
    }
-
 
3780
 
-
 
3781
    public void shiftToWarehouse(long orderId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<shiftToWarehouse_call> resultHandler) throws org.apache.thrift.TException {
-
 
3782
      checkReady();
-
 
3783
      shiftToWarehouse_call method_call = new shiftToWarehouse_call(orderId, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
-
 
3784
      this.___currentMethod = method_call;
-
 
3785
      ___manager.call(method_call);
-
 
3786
    }
-
 
3787
 
-
 
3788
    public static class shiftToWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
-
 
3789
      private long orderId;
-
 
3790
      private long warehouseId;
-
 
3791
      public shiftToWarehouse_call(long orderId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<shiftToWarehouse_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 {
-
 
3792
        super(client, protocolFactory, transport, resultHandler, false);
-
 
3793
        this.orderId = orderId;
-
 
3794
        this.warehouseId = warehouseId;
-
 
3795
      }
-
 
3796
 
-
 
3797
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-
 
3798
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("shiftToWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
-
 
3799
        shiftToWarehouse_args args = new shiftToWarehouse_args();
-
 
3800
        args.setOrderId(orderId);
-
 
3801
        args.setWarehouseId(warehouseId);
-
 
3802
        args.write(prot);
-
 
3803
        prot.writeMessageEnd();
-
 
3804
      }
-
 
3805
 
-
 
3806
      public Order getResult() throws TransactionServiceException, org.apache.thrift.TException {
-
 
3807
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-
 
3808
          throw new IllegalStateException("Method call not finished!");
-
 
3809
        }
-
 
3810
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-
 
3811
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-
 
3812
        return (new Client(prot)).recv_shiftToWarehouse();
-
 
3813
      }
-
 
3814
    }
-
 
3815
 
3671
  }
3816
  }
3672
 
3817
 
3673
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
3818
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
3674
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
3819
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
3675
    public Processor(I iface) {
3820
    public Processor(I iface) {
Line 3730... Line 3875...
3730
      processMap.put("getReturnOrders", new getReturnOrders());
3875
      processMap.put("getReturnOrders", new getReturnOrders());
3731
      processMap.put("getReturnOrder", new getReturnOrder());
3876
      processMap.put("getReturnOrder", new getReturnOrder());
3732
      processMap.put("processReturn", new processReturn());
3877
      processMap.put("processReturn", new processReturn());
3733
      processMap.put("createPurchaseOrder", new createPurchaseOrder());
3878
      processMap.put("createPurchaseOrder", new createPurchaseOrder());
3734
      processMap.put("updateWeight", new updateWeight());
3879
      processMap.put("updateWeight", new updateWeight());
-
 
3880
      processMap.put("changeItem", new changeItem());
-
 
3881
      processMap.put("shiftToWarehouse", new shiftToWarehouse());
3735
      return processMap;
3882
      return processMap;
3736
    }
3883
    }
3737
 
3884
 
3738
    private static class createTransaction<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createTransaction_args> {
3885
    private static class createTransaction<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createTransaction_args> {
3739
      public createTransaction() {
3886
      public createTransaction() {
Line 4739... Line 4886...
4739
        }
4886
        }
4740
        return result;
4887
        return result;
4741
      }
4888
      }
4742
    }
4889
    }
4743
 
4890
 
-
 
4891
    private static class changeItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, changeItem_args> {
-
 
4892
      public changeItem() {
-
 
4893
        super("changeItem");
-
 
4894
      }
-
 
4895
 
-
 
4896
      protected changeItem_args getEmptyArgsInstance() {
-
 
4897
        return new changeItem_args();
-
 
4898
      }
-
 
4899
 
-
 
4900
      protected changeItem_result getResult(I iface, changeItem_args args) throws org.apache.thrift.TException {
-
 
4901
        changeItem_result result = new changeItem_result();
-
 
4902
        try {
-
 
4903
          result.success = iface.changeItem(args.orderId, args.itemId);
-
 
4904
        } catch (TransactionServiceException ex) {
-
 
4905
          result.ex = ex;
-
 
4906
        }
-
 
4907
        return result;
-
 
4908
      }
-
 
4909
    }
-
 
4910
 
-
 
4911
    private static class shiftToWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, shiftToWarehouse_args> {
-
 
4912
      public shiftToWarehouse() {
-
 
4913
        super("shiftToWarehouse");
-
 
4914
      }
-
 
4915
 
-
 
4916
      protected shiftToWarehouse_args getEmptyArgsInstance() {
-
 
4917
        return new shiftToWarehouse_args();
-
 
4918
      }
-
 
4919
 
-
 
4920
      protected shiftToWarehouse_result getResult(I iface, shiftToWarehouse_args args) throws org.apache.thrift.TException {
-
 
4921
        shiftToWarehouse_result result = new shiftToWarehouse_result();
-
 
4922
        try {
-
 
4923
          result.success = iface.shiftToWarehouse(args.orderId, args.warehouseId);
-
 
4924
        } catch (TransactionServiceException ex) {
-
 
4925
          result.ex = ex;
-
 
4926
        }
-
 
4927
        return result;
-
 
4928
      }
-
 
4929
    }
-
 
4930
 
4744
  }
4931
  }
4745
 
4932
 
4746
  public static class createTransaction_args implements org.apache.thrift.TBase<createTransaction_args, createTransaction_args._Fields>, java.io.Serializable, Cloneable   {
4933
  public static class createTransaction_args implements org.apache.thrift.TBase<createTransaction_args, createTransaction_args._Fields>, java.io.Serializable, Cloneable   {
4747
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createTransaction_args");
4934
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createTransaction_args");
4748
 
4935
 
Line 28643... Line 28830...
28643
      }
28830
      }
28644
    }
28831
    }
28645
 
28832
 
28646
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
28833
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
28647
      try {
28834
      try {
-
 
28835
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-
 
28836
        __isset_bit_vector = new BitSet(1);
28648
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
28837
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
28649
      } catch (org.apache.thrift.TException te) {
28838
      } catch (org.apache.thrift.TException te) {
28650
        throw new java.io.IOException(te);
28839
        throw new java.io.IOException(te);
28651
      }
28840
      }
28652
    }
28841
    }
Line 42833... Line 43022...
42833
      boolean first = true;
43022
      boolean first = true;
42834
 
43023
 
42835
      sb.append("success:");
43024
      sb.append("success:");
42836
      if (this.success == null) {
43025
      if (this.success == null) {
42837
        sb.append("null");
43026
        sb.append("null");
-
 
43027
      } else {
-
 
43028
        sb.append(this.success);
-
 
43029
      }
-
 
43030
      first = false;
-
 
43031
      if (!first) sb.append(", ");
-
 
43032
      sb.append("ex:");
-
 
43033
      if (this.ex == null) {
-
 
43034
        sb.append("null");
-
 
43035
      } else {
-
 
43036
        sb.append(this.ex);
-
 
43037
      }
-
 
43038
      first = false;
-
 
43039
      sb.append(")");
-
 
43040
      return sb.toString();
-
 
43041
    }
-
 
43042
 
-
 
43043
    public void validate() throws org.apache.thrift.TException {
-
 
43044
      // check for required fields
-
 
43045
    }
-
 
43046
 
-
 
43047
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
43048
      try {
-
 
43049
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
43050
      } catch (org.apache.thrift.TException te) {
-
 
43051
        throw new java.io.IOException(te);
-
 
43052
      }
-
 
43053
    }
-
 
43054
 
-
 
43055
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
43056
      try {
-
 
43057
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
43058
      } catch (org.apache.thrift.TException te) {
-
 
43059
        throw new java.io.IOException(te);
-
 
43060
      }
-
 
43061
    }
-
 
43062
 
-
 
43063
  }
-
 
43064
 
-
 
43065
  public static class changeItem_args implements org.apache.thrift.TBase<changeItem_args, changeItem_args._Fields>, java.io.Serializable, Cloneable   {
-
 
43066
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("changeItem_args");
-
 
43067
 
-
 
43068
    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);
-
 
43069
    private static final org.apache.thrift.protocol.TField ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("itemId", org.apache.thrift.protocol.TType.I64, (short)2);
-
 
43070
 
-
 
43071
    private long orderId; // required
-
 
43072
    private long itemId; // required
-
 
43073
 
-
 
43074
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
43075
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
43076
      ORDER_ID((short)1, "orderId"),
-
 
43077
      ITEM_ID((short)2, "itemId");
-
 
43078
 
-
 
43079
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
43080
 
-
 
43081
      static {
-
 
43082
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
43083
          byName.put(field.getFieldName(), field);
-
 
43084
        }
-
 
43085
      }
-
 
43086
 
-
 
43087
      /**
-
 
43088
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
43089
       */
-
 
43090
      public static _Fields findByThriftId(int fieldId) {
-
 
43091
        switch(fieldId) {
-
 
43092
          case 1: // ORDER_ID
-
 
43093
            return ORDER_ID;
-
 
43094
          case 2: // ITEM_ID
-
 
43095
            return ITEM_ID;
-
 
43096
          default:
-
 
43097
            return null;
-
 
43098
        }
-
 
43099
      }
-
 
43100
 
-
 
43101
      /**
-
 
43102
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
43103
       * if it is not found.
-
 
43104
       */
-
 
43105
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
43106
        _Fields fields = findByThriftId(fieldId);
-
 
43107
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
43108
        return fields;
-
 
43109
      }
-
 
43110
 
-
 
43111
      /**
-
 
43112
       * Find the _Fields constant that matches name, or null if its not found.
-
 
43113
       */
-
 
43114
      public static _Fields findByName(String name) {
-
 
43115
        return byName.get(name);
-
 
43116
      }
-
 
43117
 
-
 
43118
      private final short _thriftId;
-
 
43119
      private final String _fieldName;
-
 
43120
 
-
 
43121
      _Fields(short thriftId, String fieldName) {
-
 
43122
        _thriftId = thriftId;
-
 
43123
        _fieldName = fieldName;
-
 
43124
      }
-
 
43125
 
-
 
43126
      public short getThriftFieldId() {
-
 
43127
        return _thriftId;
-
 
43128
      }
-
 
43129
 
-
 
43130
      public String getFieldName() {
-
 
43131
        return _fieldName;
-
 
43132
      }
-
 
43133
    }
-
 
43134
 
-
 
43135
    // isset id assignments
-
 
43136
    private static final int __ORDERID_ISSET_ID = 0;
-
 
43137
    private static final int __ITEMID_ISSET_ID = 1;
-
 
43138
    private BitSet __isset_bit_vector = new BitSet(2);
-
 
43139
 
-
 
43140
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
43141
    static {
-
 
43142
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
43143
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
43144
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
43145
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
43146
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
43147
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
43148
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(changeItem_args.class, metaDataMap);
-
 
43149
    }
-
 
43150
 
-
 
43151
    public changeItem_args() {
-
 
43152
    }
-
 
43153
 
-
 
43154
    public changeItem_args(
-
 
43155
      long orderId,
-
 
43156
      long itemId)
-
 
43157
    {
-
 
43158
      this();
-
 
43159
      this.orderId = orderId;
-
 
43160
      setOrderIdIsSet(true);
-
 
43161
      this.itemId = itemId;
-
 
43162
      setItemIdIsSet(true);
-
 
43163
    }
-
 
43164
 
-
 
43165
    /**
-
 
43166
     * Performs a deep copy on <i>other</i>.
-
 
43167
     */
-
 
43168
    public changeItem_args(changeItem_args other) {
-
 
43169
      __isset_bit_vector.clear();
-
 
43170
      __isset_bit_vector.or(other.__isset_bit_vector);
-
 
43171
      this.orderId = other.orderId;
-
 
43172
      this.itemId = other.itemId;
-
 
43173
    }
-
 
43174
 
-
 
43175
    public changeItem_args deepCopy() {
-
 
43176
      return new changeItem_args(this);
-
 
43177
    }
-
 
43178
 
-
 
43179
    @Override
-
 
43180
    public void clear() {
-
 
43181
      setOrderIdIsSet(false);
-
 
43182
      this.orderId = 0;
-
 
43183
      setItemIdIsSet(false);
-
 
43184
      this.itemId = 0;
-
 
43185
    }
-
 
43186
 
-
 
43187
    public long getOrderId() {
-
 
43188
      return this.orderId;
-
 
43189
    }
-
 
43190
 
-
 
43191
    public void setOrderId(long orderId) {
-
 
43192
      this.orderId = orderId;
-
 
43193
      setOrderIdIsSet(true);
-
 
43194
    }
-
 
43195
 
-
 
43196
    public void unsetOrderId() {
-
 
43197
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
-
 
43198
    }
-
 
43199
 
-
 
43200
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
-
 
43201
    public boolean isSetOrderId() {
-
 
43202
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
-
 
43203
    }
-
 
43204
 
-
 
43205
    public void setOrderIdIsSet(boolean value) {
-
 
43206
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
-
 
43207
    }
-
 
43208
 
-
 
43209
    public long getItemId() {
-
 
43210
      return this.itemId;
-
 
43211
    }
-
 
43212
 
-
 
43213
    public void setItemId(long itemId) {
-
 
43214
      this.itemId = itemId;
-
 
43215
      setItemIdIsSet(true);
-
 
43216
    }
-
 
43217
 
-
 
43218
    public void unsetItemId() {
-
 
43219
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
-
 
43220
    }
-
 
43221
 
-
 
43222
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
-
 
43223
    public boolean isSetItemId() {
-
 
43224
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
-
 
43225
    }
-
 
43226
 
-
 
43227
    public void setItemIdIsSet(boolean value) {
-
 
43228
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
-
 
43229
    }
-
 
43230
 
-
 
43231
    public void setFieldValue(_Fields field, Object value) {
-
 
43232
      switch (field) {
-
 
43233
      case ORDER_ID:
-
 
43234
        if (value == null) {
-
 
43235
          unsetOrderId();
-
 
43236
        } else {
-
 
43237
          setOrderId((Long)value);
-
 
43238
        }
-
 
43239
        break;
-
 
43240
 
-
 
43241
      case ITEM_ID:
-
 
43242
        if (value == null) {
-
 
43243
          unsetItemId();
-
 
43244
        } else {
-
 
43245
          setItemId((Long)value);
-
 
43246
        }
-
 
43247
        break;
-
 
43248
 
-
 
43249
      }
-
 
43250
    }
-
 
43251
 
-
 
43252
    public Object getFieldValue(_Fields field) {
-
 
43253
      switch (field) {
-
 
43254
      case ORDER_ID:
-
 
43255
        return Long.valueOf(getOrderId());
-
 
43256
 
-
 
43257
      case ITEM_ID:
-
 
43258
        return Long.valueOf(getItemId());
-
 
43259
 
-
 
43260
      }
-
 
43261
      throw new IllegalStateException();
-
 
43262
    }
-
 
43263
 
-
 
43264
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
43265
    public boolean isSet(_Fields field) {
-
 
43266
      if (field == null) {
-
 
43267
        throw new IllegalArgumentException();
-
 
43268
      }
-
 
43269
 
-
 
43270
      switch (field) {
-
 
43271
      case ORDER_ID:
-
 
43272
        return isSetOrderId();
-
 
43273
      case ITEM_ID:
-
 
43274
        return isSetItemId();
-
 
43275
      }
-
 
43276
      throw new IllegalStateException();
-
 
43277
    }
-
 
43278
 
-
 
43279
    @Override
-
 
43280
    public boolean equals(Object that) {
-
 
43281
      if (that == null)
-
 
43282
        return false;
-
 
43283
      if (that instanceof changeItem_args)
-
 
43284
        return this.equals((changeItem_args)that);
-
 
43285
      return false;
-
 
43286
    }
-
 
43287
 
-
 
43288
    public boolean equals(changeItem_args that) {
-
 
43289
      if (that == null)
-
 
43290
        return false;
-
 
43291
 
-
 
43292
      boolean this_present_orderId = true;
-
 
43293
      boolean that_present_orderId = true;
-
 
43294
      if (this_present_orderId || that_present_orderId) {
-
 
43295
        if (!(this_present_orderId && that_present_orderId))
-
 
43296
          return false;
-
 
43297
        if (this.orderId != that.orderId)
-
 
43298
          return false;
-
 
43299
      }
-
 
43300
 
-
 
43301
      boolean this_present_itemId = true;
-
 
43302
      boolean that_present_itemId = true;
-
 
43303
      if (this_present_itemId || that_present_itemId) {
-
 
43304
        if (!(this_present_itemId && that_present_itemId))
-
 
43305
          return false;
-
 
43306
        if (this.itemId != that.itemId)
-
 
43307
          return false;
-
 
43308
      }
-
 
43309
 
-
 
43310
      return true;
-
 
43311
    }
-
 
43312
 
-
 
43313
    @Override
-
 
43314
    public int hashCode() {
-
 
43315
      return 0;
-
 
43316
    }
-
 
43317
 
-
 
43318
    public int compareTo(changeItem_args other) {
-
 
43319
      if (!getClass().equals(other.getClass())) {
-
 
43320
        return getClass().getName().compareTo(other.getClass().getName());
-
 
43321
      }
-
 
43322
 
-
 
43323
      int lastComparison = 0;
-
 
43324
      changeItem_args typedOther = (changeItem_args)other;
-
 
43325
 
-
 
43326
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
-
 
43327
      if (lastComparison != 0) {
-
 
43328
        return lastComparison;
-
 
43329
      }
-
 
43330
      if (isSetOrderId()) {
-
 
43331
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
-
 
43332
        if (lastComparison != 0) {
-
 
43333
          return lastComparison;
-
 
43334
        }
-
 
43335
      }
-
 
43336
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
-
 
43337
      if (lastComparison != 0) {
-
 
43338
        return lastComparison;
-
 
43339
      }
-
 
43340
      if (isSetItemId()) {
-
 
43341
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
-
 
43342
        if (lastComparison != 0) {
-
 
43343
          return lastComparison;
-
 
43344
        }
-
 
43345
      }
-
 
43346
      return 0;
-
 
43347
    }
-
 
43348
 
-
 
43349
    public _Fields fieldForId(int fieldId) {
-
 
43350
      return _Fields.findByThriftId(fieldId);
-
 
43351
    }
-
 
43352
 
-
 
43353
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
43354
      org.apache.thrift.protocol.TField field;
-
 
43355
      iprot.readStructBegin();
-
 
43356
      while (true)
-
 
43357
      {
-
 
43358
        field = iprot.readFieldBegin();
-
 
43359
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
43360
          break;
-
 
43361
        }
-
 
43362
        switch (field.id) {
-
 
43363
          case 1: // ORDER_ID
-
 
43364
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
43365
              this.orderId = iprot.readI64();
-
 
43366
              setOrderIdIsSet(true);
-
 
43367
            } else { 
-
 
43368
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
43369
            }
-
 
43370
            break;
-
 
43371
          case 2: // ITEM_ID
-
 
43372
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
43373
              this.itemId = iprot.readI64();
-
 
43374
              setItemIdIsSet(true);
-
 
43375
            } else { 
-
 
43376
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
43377
            }
-
 
43378
            break;
-
 
43379
          default:
-
 
43380
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
43381
        }
-
 
43382
        iprot.readFieldEnd();
-
 
43383
      }
-
 
43384
      iprot.readStructEnd();
-
 
43385
      validate();
-
 
43386
    }
-
 
43387
 
-
 
43388
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
43389
      validate();
-
 
43390
 
-
 
43391
      oprot.writeStructBegin(STRUCT_DESC);
-
 
43392
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
-
 
43393
      oprot.writeI64(this.orderId);
-
 
43394
      oprot.writeFieldEnd();
-
 
43395
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
-
 
43396
      oprot.writeI64(this.itemId);
-
 
43397
      oprot.writeFieldEnd();
-
 
43398
      oprot.writeFieldStop();
-
 
43399
      oprot.writeStructEnd();
-
 
43400
    }
-
 
43401
 
-
 
43402
    @Override
-
 
43403
    public String toString() {
-
 
43404
      StringBuilder sb = new StringBuilder("changeItem_args(");
-
 
43405
      boolean first = true;
-
 
43406
 
-
 
43407
      sb.append("orderId:");
-
 
43408
      sb.append(this.orderId);
-
 
43409
      first = false;
-
 
43410
      if (!first) sb.append(", ");
-
 
43411
      sb.append("itemId:");
-
 
43412
      sb.append(this.itemId);
-
 
43413
      first = false;
-
 
43414
      sb.append(")");
-
 
43415
      return sb.toString();
-
 
43416
    }
-
 
43417
 
-
 
43418
    public void validate() throws org.apache.thrift.TException {
-
 
43419
      // check for required fields
-
 
43420
    }
-
 
43421
 
-
 
43422
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
43423
      try {
-
 
43424
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
43425
      } catch (org.apache.thrift.TException te) {
-
 
43426
        throw new java.io.IOException(te);
-
 
43427
      }
-
 
43428
    }
-
 
43429
 
-
 
43430
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
43431
      try {
-
 
43432
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
43433
      } catch (org.apache.thrift.TException te) {
-
 
43434
        throw new java.io.IOException(te);
-
 
43435
      }
-
 
43436
    }
-
 
43437
 
-
 
43438
  }
-
 
43439
 
-
 
43440
  public static class changeItem_result implements org.apache.thrift.TBase<changeItem_result, changeItem_result._Fields>, java.io.Serializable, Cloneable   {
-
 
43441
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("changeItem_result");
-
 
43442
 
-
 
43443
    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);
-
 
43444
    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);
-
 
43445
 
-
 
43446
    private Order success; // required
-
 
43447
    private TransactionServiceException ex; // required
-
 
43448
 
-
 
43449
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
43450
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
43451
      SUCCESS((short)0, "success"),
-
 
43452
      EX((short)1, "ex");
-
 
43453
 
-
 
43454
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
43455
 
-
 
43456
      static {
-
 
43457
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
43458
          byName.put(field.getFieldName(), field);
-
 
43459
        }
-
 
43460
      }
-
 
43461
 
-
 
43462
      /**
-
 
43463
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
43464
       */
-
 
43465
      public static _Fields findByThriftId(int fieldId) {
-
 
43466
        switch(fieldId) {
-
 
43467
          case 0: // SUCCESS
-
 
43468
            return SUCCESS;
-
 
43469
          case 1: // EX
-
 
43470
            return EX;
-
 
43471
          default:
-
 
43472
            return null;
-
 
43473
        }
-
 
43474
      }
-
 
43475
 
-
 
43476
      /**
-
 
43477
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
43478
       * if it is not found.
-
 
43479
       */
-
 
43480
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
43481
        _Fields fields = findByThriftId(fieldId);
-
 
43482
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
43483
        return fields;
-
 
43484
      }
-
 
43485
 
-
 
43486
      /**
-
 
43487
       * Find the _Fields constant that matches name, or null if its not found.
-
 
43488
       */
-
 
43489
      public static _Fields findByName(String name) {
-
 
43490
        return byName.get(name);
-
 
43491
      }
-
 
43492
 
-
 
43493
      private final short _thriftId;
-
 
43494
      private final String _fieldName;
-
 
43495
 
-
 
43496
      _Fields(short thriftId, String fieldName) {
-
 
43497
        _thriftId = thriftId;
-
 
43498
        _fieldName = fieldName;
-
 
43499
      }
-
 
43500
 
-
 
43501
      public short getThriftFieldId() {
-
 
43502
        return _thriftId;
-
 
43503
      }
-
 
43504
 
-
 
43505
      public String getFieldName() {
-
 
43506
        return _fieldName;
-
 
43507
      }
-
 
43508
    }
-
 
43509
 
-
 
43510
    // isset id assignments
-
 
43511
 
-
 
43512
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
43513
    static {
-
 
43514
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
43515
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
43516
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Order.class)));
-
 
43517
      tmpMap.put(_Fields.EX, new org.apache.thrift.meta_data.FieldMetaData("ex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
43518
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
-
 
43519
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
43520
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(changeItem_result.class, metaDataMap);
-
 
43521
    }
-
 
43522
 
-
 
43523
    public changeItem_result() {
-
 
43524
    }
-
 
43525
 
-
 
43526
    public changeItem_result(
-
 
43527
      Order success,
-
 
43528
      TransactionServiceException ex)
-
 
43529
    {
-
 
43530
      this();
-
 
43531
      this.success = success;
-
 
43532
      this.ex = ex;
-
 
43533
    }
-
 
43534
 
-
 
43535
    /**
-
 
43536
     * Performs a deep copy on <i>other</i>.
-
 
43537
     */
-
 
43538
    public changeItem_result(changeItem_result other) {
-
 
43539
      if (other.isSetSuccess()) {
-
 
43540
        this.success = new Order(other.success);
-
 
43541
      }
-
 
43542
      if (other.isSetEx()) {
-
 
43543
        this.ex = new TransactionServiceException(other.ex);
-
 
43544
      }
-
 
43545
    }
-
 
43546
 
-
 
43547
    public changeItem_result deepCopy() {
-
 
43548
      return new changeItem_result(this);
-
 
43549
    }
-
 
43550
 
-
 
43551
    @Override
-
 
43552
    public void clear() {
-
 
43553
      this.success = null;
-
 
43554
      this.ex = null;
-
 
43555
    }
-
 
43556
 
-
 
43557
    public Order getSuccess() {
-
 
43558
      return this.success;
-
 
43559
    }
-
 
43560
 
-
 
43561
    public void setSuccess(Order success) {
-
 
43562
      this.success = success;
-
 
43563
    }
-
 
43564
 
-
 
43565
    public void unsetSuccess() {
-
 
43566
      this.success = null;
-
 
43567
    }
-
 
43568
 
-
 
43569
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
-
 
43570
    public boolean isSetSuccess() {
-
 
43571
      return this.success != null;
-
 
43572
    }
-
 
43573
 
-
 
43574
    public void setSuccessIsSet(boolean value) {
-
 
43575
      if (!value) {
-
 
43576
        this.success = null;
-
 
43577
      }
-
 
43578
    }
-
 
43579
 
-
 
43580
    public TransactionServiceException getEx() {
-
 
43581
      return this.ex;
-
 
43582
    }
-
 
43583
 
-
 
43584
    public void setEx(TransactionServiceException ex) {
-
 
43585
      this.ex = ex;
-
 
43586
    }
-
 
43587
 
-
 
43588
    public void unsetEx() {
-
 
43589
      this.ex = null;
-
 
43590
    }
-
 
43591
 
-
 
43592
    /** Returns true if field ex is set (has been assigned a value) and false otherwise */
-
 
43593
    public boolean isSetEx() {
-
 
43594
      return this.ex != null;
-
 
43595
    }
-
 
43596
 
-
 
43597
    public void setExIsSet(boolean value) {
-
 
43598
      if (!value) {
-
 
43599
        this.ex = null;
-
 
43600
      }
-
 
43601
    }
-
 
43602
 
-
 
43603
    public void setFieldValue(_Fields field, Object value) {
-
 
43604
      switch (field) {
-
 
43605
      case SUCCESS:
-
 
43606
        if (value == null) {
-
 
43607
          unsetSuccess();
-
 
43608
        } else {
-
 
43609
          setSuccess((Order)value);
-
 
43610
        }
-
 
43611
        break;
-
 
43612
 
-
 
43613
      case EX:
-
 
43614
        if (value == null) {
-
 
43615
          unsetEx();
-
 
43616
        } else {
-
 
43617
          setEx((TransactionServiceException)value);
-
 
43618
        }
-
 
43619
        break;
-
 
43620
 
-
 
43621
      }
-
 
43622
    }
-
 
43623
 
-
 
43624
    public Object getFieldValue(_Fields field) {
-
 
43625
      switch (field) {
-
 
43626
      case SUCCESS:
-
 
43627
        return getSuccess();
-
 
43628
 
-
 
43629
      case EX:
-
 
43630
        return getEx();
-
 
43631
 
-
 
43632
      }
-
 
43633
      throw new IllegalStateException();
-
 
43634
    }
-
 
43635
 
-
 
43636
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
43637
    public boolean isSet(_Fields field) {
-
 
43638
      if (field == null) {
-
 
43639
        throw new IllegalArgumentException();
-
 
43640
      }
-
 
43641
 
-
 
43642
      switch (field) {
-
 
43643
      case SUCCESS:
-
 
43644
        return isSetSuccess();
-
 
43645
      case EX:
-
 
43646
        return isSetEx();
-
 
43647
      }
-
 
43648
      throw new IllegalStateException();
-
 
43649
    }
-
 
43650
 
-
 
43651
    @Override
-
 
43652
    public boolean equals(Object that) {
-
 
43653
      if (that == null)
-
 
43654
        return false;
-
 
43655
      if (that instanceof changeItem_result)
-
 
43656
        return this.equals((changeItem_result)that);
-
 
43657
      return false;
-
 
43658
    }
-
 
43659
 
-
 
43660
    public boolean equals(changeItem_result that) {
-
 
43661
      if (that == null)
-
 
43662
        return false;
-
 
43663
 
-
 
43664
      boolean this_present_success = true && this.isSetSuccess();
-
 
43665
      boolean that_present_success = true && that.isSetSuccess();
-
 
43666
      if (this_present_success || that_present_success) {
-
 
43667
        if (!(this_present_success && that_present_success))
-
 
43668
          return false;
-
 
43669
        if (!this.success.equals(that.success))
-
 
43670
          return false;
-
 
43671
      }
-
 
43672
 
-
 
43673
      boolean this_present_ex = true && this.isSetEx();
-
 
43674
      boolean that_present_ex = true && that.isSetEx();
-
 
43675
      if (this_present_ex || that_present_ex) {
-
 
43676
        if (!(this_present_ex && that_present_ex))
-
 
43677
          return false;
-
 
43678
        if (!this.ex.equals(that.ex))
-
 
43679
          return false;
-
 
43680
      }
-
 
43681
 
-
 
43682
      return true;
-
 
43683
    }
-
 
43684
 
-
 
43685
    @Override
-
 
43686
    public int hashCode() {
-
 
43687
      return 0;
-
 
43688
    }
-
 
43689
 
-
 
43690
    public int compareTo(changeItem_result other) {
-
 
43691
      if (!getClass().equals(other.getClass())) {
-
 
43692
        return getClass().getName().compareTo(other.getClass().getName());
-
 
43693
      }
-
 
43694
 
-
 
43695
      int lastComparison = 0;
-
 
43696
      changeItem_result typedOther = (changeItem_result)other;
-
 
43697
 
-
 
43698
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
-
 
43699
      if (lastComparison != 0) {
-
 
43700
        return lastComparison;
-
 
43701
      }
-
 
43702
      if (isSetSuccess()) {
-
 
43703
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
-
 
43704
        if (lastComparison != 0) {
-
 
43705
          return lastComparison;
-
 
43706
        }
-
 
43707
      }
-
 
43708
      lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx());
-
 
43709
      if (lastComparison != 0) {
-
 
43710
        return lastComparison;
-
 
43711
      }
-
 
43712
      if (isSetEx()) {
-
 
43713
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex);
-
 
43714
        if (lastComparison != 0) {
-
 
43715
          return lastComparison;
-
 
43716
        }
-
 
43717
      }
-
 
43718
      return 0;
-
 
43719
    }
-
 
43720
 
-
 
43721
    public _Fields fieldForId(int fieldId) {
-
 
43722
      return _Fields.findByThriftId(fieldId);
-
 
43723
    }
-
 
43724
 
-
 
43725
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
43726
      org.apache.thrift.protocol.TField field;
-
 
43727
      iprot.readStructBegin();
-
 
43728
      while (true)
-
 
43729
      {
-
 
43730
        field = iprot.readFieldBegin();
-
 
43731
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
43732
          break;
-
 
43733
        }
-
 
43734
        switch (field.id) {
-
 
43735
          case 0: // SUCCESS
-
 
43736
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
43737
              this.success = new Order();
-
 
43738
              this.success.read(iprot);
-
 
43739
            } else { 
-
 
43740
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
43741
            }
-
 
43742
            break;
-
 
43743
          case 1: // EX
-
 
43744
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
43745
              this.ex = new TransactionServiceException();
-
 
43746
              this.ex.read(iprot);
-
 
43747
            } else { 
-
 
43748
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
43749
            }
-
 
43750
            break;
-
 
43751
          default:
-
 
43752
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
43753
        }
-
 
43754
        iprot.readFieldEnd();
-
 
43755
      }
-
 
43756
      iprot.readStructEnd();
-
 
43757
      validate();
-
 
43758
    }
-
 
43759
 
-
 
43760
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
43761
      oprot.writeStructBegin(STRUCT_DESC);
-
 
43762
 
-
 
43763
      if (this.isSetSuccess()) {
-
 
43764
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
-
 
43765
        this.success.write(oprot);
-
 
43766
        oprot.writeFieldEnd();
-
 
43767
      } else if (this.isSetEx()) {
-
 
43768
        oprot.writeFieldBegin(EX_FIELD_DESC);
-
 
43769
        this.ex.write(oprot);
-
 
43770
        oprot.writeFieldEnd();
-
 
43771
      }
-
 
43772
      oprot.writeFieldStop();
-
 
43773
      oprot.writeStructEnd();
-
 
43774
    }
-
 
43775
 
-
 
43776
    @Override
-
 
43777
    public String toString() {
-
 
43778
      StringBuilder sb = new StringBuilder("changeItem_result(");
-
 
43779
      boolean first = true;
-
 
43780
 
-
 
43781
      sb.append("success:");
-
 
43782
      if (this.success == null) {
-
 
43783
        sb.append("null");
-
 
43784
      } else {
-
 
43785
        sb.append(this.success);
-
 
43786
      }
-
 
43787
      first = false;
-
 
43788
      if (!first) sb.append(", ");
-
 
43789
      sb.append("ex:");
-
 
43790
      if (this.ex == null) {
-
 
43791
        sb.append("null");
-
 
43792
      } else {
-
 
43793
        sb.append(this.ex);
-
 
43794
      }
-
 
43795
      first = false;
-
 
43796
      sb.append(")");
-
 
43797
      return sb.toString();
-
 
43798
    }
-
 
43799
 
-
 
43800
    public void validate() throws org.apache.thrift.TException {
-
 
43801
      // check for required fields
-
 
43802
    }
-
 
43803
 
-
 
43804
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
43805
      try {
-
 
43806
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
43807
      } catch (org.apache.thrift.TException te) {
-
 
43808
        throw new java.io.IOException(te);
-
 
43809
      }
-
 
43810
    }
-
 
43811
 
-
 
43812
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
43813
      try {
-
 
43814
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
43815
      } catch (org.apache.thrift.TException te) {
-
 
43816
        throw new java.io.IOException(te);
-
 
43817
      }
-
 
43818
    }
-
 
43819
 
-
 
43820
  }
-
 
43821
 
-
 
43822
  public static class shiftToWarehouse_args implements org.apache.thrift.TBase<shiftToWarehouse_args, shiftToWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
-
 
43823
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("shiftToWarehouse_args");
-
 
43824
 
-
 
43825
    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);
-
 
43826
    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)2);
-
 
43827
 
-
 
43828
    private long orderId; // required
-
 
43829
    private long warehouseId; // required
-
 
43830
 
-
 
43831
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
43832
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
43833
      ORDER_ID((short)1, "orderId"),
-
 
43834
      WAREHOUSE_ID((short)2, "warehouseId");
-
 
43835
 
-
 
43836
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
43837
 
-
 
43838
      static {
-
 
43839
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
43840
          byName.put(field.getFieldName(), field);
-
 
43841
        }
-
 
43842
      }
-
 
43843
 
-
 
43844
      /**
-
 
43845
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
43846
       */
-
 
43847
      public static _Fields findByThriftId(int fieldId) {
-
 
43848
        switch(fieldId) {
-
 
43849
          case 1: // ORDER_ID
-
 
43850
            return ORDER_ID;
-
 
43851
          case 2: // WAREHOUSE_ID
-
 
43852
            return WAREHOUSE_ID;
-
 
43853
          default:
-
 
43854
            return null;
-
 
43855
        }
-
 
43856
      }
-
 
43857
 
-
 
43858
      /**
-
 
43859
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
43860
       * if it is not found.
-
 
43861
       */
-
 
43862
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
43863
        _Fields fields = findByThriftId(fieldId);
-
 
43864
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
43865
        return fields;
-
 
43866
      }
-
 
43867
 
-
 
43868
      /**
-
 
43869
       * Find the _Fields constant that matches name, or null if its not found.
-
 
43870
       */
-
 
43871
      public static _Fields findByName(String name) {
-
 
43872
        return byName.get(name);
-
 
43873
      }
-
 
43874
 
-
 
43875
      private final short _thriftId;
-
 
43876
      private final String _fieldName;
-
 
43877
 
-
 
43878
      _Fields(short thriftId, String fieldName) {
-
 
43879
        _thriftId = thriftId;
-
 
43880
        _fieldName = fieldName;
-
 
43881
      }
-
 
43882
 
-
 
43883
      public short getThriftFieldId() {
-
 
43884
        return _thriftId;
-
 
43885
      }
-
 
43886
 
-
 
43887
      public String getFieldName() {
-
 
43888
        return _fieldName;
-
 
43889
      }
-
 
43890
    }
-
 
43891
 
-
 
43892
    // isset id assignments
-
 
43893
    private static final int __ORDERID_ISSET_ID = 0;
-
 
43894
    private static final int __WAREHOUSEID_ISSET_ID = 1;
-
 
43895
    private BitSet __isset_bit_vector = new BitSet(2);
-
 
43896
 
-
 
43897
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
43898
    static {
-
 
43899
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
43900
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
43901
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
43902
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
43903
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
43904
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
43905
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(shiftToWarehouse_args.class, metaDataMap);
-
 
43906
    }
-
 
43907
 
-
 
43908
    public shiftToWarehouse_args() {
-
 
43909
    }
-
 
43910
 
-
 
43911
    public shiftToWarehouse_args(
-
 
43912
      long orderId,
-
 
43913
      long warehouseId)
-
 
43914
    {
-
 
43915
      this();
-
 
43916
      this.orderId = orderId;
-
 
43917
      setOrderIdIsSet(true);
-
 
43918
      this.warehouseId = warehouseId;
-
 
43919
      setWarehouseIdIsSet(true);
-
 
43920
    }
-
 
43921
 
-
 
43922
    /**
-
 
43923
     * Performs a deep copy on <i>other</i>.
-
 
43924
     */
-
 
43925
    public shiftToWarehouse_args(shiftToWarehouse_args other) {
-
 
43926
      __isset_bit_vector.clear();
-
 
43927
      __isset_bit_vector.or(other.__isset_bit_vector);
-
 
43928
      this.orderId = other.orderId;
-
 
43929
      this.warehouseId = other.warehouseId;
-
 
43930
    }
-
 
43931
 
-
 
43932
    public shiftToWarehouse_args deepCopy() {
-
 
43933
      return new shiftToWarehouse_args(this);
-
 
43934
    }
-
 
43935
 
-
 
43936
    @Override
-
 
43937
    public void clear() {
-
 
43938
      setOrderIdIsSet(false);
-
 
43939
      this.orderId = 0;
-
 
43940
      setWarehouseIdIsSet(false);
-
 
43941
      this.warehouseId = 0;
-
 
43942
    }
-
 
43943
 
-
 
43944
    public long getOrderId() {
-
 
43945
      return this.orderId;
-
 
43946
    }
-
 
43947
 
-
 
43948
    public void setOrderId(long orderId) {
-
 
43949
      this.orderId = orderId;
-
 
43950
      setOrderIdIsSet(true);
-
 
43951
    }
-
 
43952
 
-
 
43953
    public void unsetOrderId() {
-
 
43954
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
-
 
43955
    }
-
 
43956
 
-
 
43957
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
-
 
43958
    public boolean isSetOrderId() {
-
 
43959
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
-
 
43960
    }
-
 
43961
 
-
 
43962
    public void setOrderIdIsSet(boolean value) {
-
 
43963
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
-
 
43964
    }
-
 
43965
 
-
 
43966
    public long getWarehouseId() {
-
 
43967
      return this.warehouseId;
-
 
43968
    }
-
 
43969
 
-
 
43970
    public void setWarehouseId(long warehouseId) {
-
 
43971
      this.warehouseId = warehouseId;
-
 
43972
      setWarehouseIdIsSet(true);
-
 
43973
    }
-
 
43974
 
-
 
43975
    public void unsetWarehouseId() {
-
 
43976
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
-
 
43977
    }
-
 
43978
 
-
 
43979
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
-
 
43980
    public boolean isSetWarehouseId() {
-
 
43981
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
-
 
43982
    }
-
 
43983
 
-
 
43984
    public void setWarehouseIdIsSet(boolean value) {
-
 
43985
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
-
 
43986
    }
-
 
43987
 
-
 
43988
    public void setFieldValue(_Fields field, Object value) {
-
 
43989
      switch (field) {
-
 
43990
      case ORDER_ID:
-
 
43991
        if (value == null) {
-
 
43992
          unsetOrderId();
-
 
43993
        } else {
-
 
43994
          setOrderId((Long)value);
-
 
43995
        }
-
 
43996
        break;
-
 
43997
 
-
 
43998
      case WAREHOUSE_ID:
-
 
43999
        if (value == null) {
-
 
44000
          unsetWarehouseId();
-
 
44001
        } else {
-
 
44002
          setWarehouseId((Long)value);
-
 
44003
        }
-
 
44004
        break;
-
 
44005
 
-
 
44006
      }
-
 
44007
    }
-
 
44008
 
-
 
44009
    public Object getFieldValue(_Fields field) {
-
 
44010
      switch (field) {
-
 
44011
      case ORDER_ID:
-
 
44012
        return Long.valueOf(getOrderId());
-
 
44013
 
-
 
44014
      case WAREHOUSE_ID:
-
 
44015
        return Long.valueOf(getWarehouseId());
-
 
44016
 
-
 
44017
      }
-
 
44018
      throw new IllegalStateException();
-
 
44019
    }
-
 
44020
 
-
 
44021
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
44022
    public boolean isSet(_Fields field) {
-
 
44023
      if (field == null) {
-
 
44024
        throw new IllegalArgumentException();
-
 
44025
      }
-
 
44026
 
-
 
44027
      switch (field) {
-
 
44028
      case ORDER_ID:
-
 
44029
        return isSetOrderId();
-
 
44030
      case WAREHOUSE_ID:
-
 
44031
        return isSetWarehouseId();
-
 
44032
      }
-
 
44033
      throw new IllegalStateException();
-
 
44034
    }
-
 
44035
 
-
 
44036
    @Override
-
 
44037
    public boolean equals(Object that) {
-
 
44038
      if (that == null)
-
 
44039
        return false;
-
 
44040
      if (that instanceof shiftToWarehouse_args)
-
 
44041
        return this.equals((shiftToWarehouse_args)that);
-
 
44042
      return false;
-
 
44043
    }
-
 
44044
 
-
 
44045
    public boolean equals(shiftToWarehouse_args that) {
-
 
44046
      if (that == null)
-
 
44047
        return false;
-
 
44048
 
-
 
44049
      boolean this_present_orderId = true;
-
 
44050
      boolean that_present_orderId = true;
-
 
44051
      if (this_present_orderId || that_present_orderId) {
-
 
44052
        if (!(this_present_orderId && that_present_orderId))
-
 
44053
          return false;
-
 
44054
        if (this.orderId != that.orderId)
-
 
44055
          return false;
-
 
44056
      }
-
 
44057
 
-
 
44058
      boolean this_present_warehouseId = true;
-
 
44059
      boolean that_present_warehouseId = true;
-
 
44060
      if (this_present_warehouseId || that_present_warehouseId) {
-
 
44061
        if (!(this_present_warehouseId && that_present_warehouseId))
-
 
44062
          return false;
-
 
44063
        if (this.warehouseId != that.warehouseId)
-
 
44064
          return false;
-
 
44065
      }
-
 
44066
 
-
 
44067
      return true;
-
 
44068
    }
-
 
44069
 
-
 
44070
    @Override
-
 
44071
    public int hashCode() {
-
 
44072
      return 0;
-
 
44073
    }
-
 
44074
 
-
 
44075
    public int compareTo(shiftToWarehouse_args other) {
-
 
44076
      if (!getClass().equals(other.getClass())) {
-
 
44077
        return getClass().getName().compareTo(other.getClass().getName());
-
 
44078
      }
-
 
44079
 
-
 
44080
      int lastComparison = 0;
-
 
44081
      shiftToWarehouse_args typedOther = (shiftToWarehouse_args)other;
-
 
44082
 
-
 
44083
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
-
 
44084
      if (lastComparison != 0) {
-
 
44085
        return lastComparison;
-
 
44086
      }
-
 
44087
      if (isSetOrderId()) {
-
 
44088
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
-
 
44089
        if (lastComparison != 0) {
-
 
44090
          return lastComparison;
-
 
44091
        }
-
 
44092
      }
-
 
44093
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
-
 
44094
      if (lastComparison != 0) {
-
 
44095
        return lastComparison;
-
 
44096
      }
-
 
44097
      if (isSetWarehouseId()) {
-
 
44098
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
-
 
44099
        if (lastComparison != 0) {
-
 
44100
          return lastComparison;
-
 
44101
        }
-
 
44102
      }
-
 
44103
      return 0;
-
 
44104
    }
-
 
44105
 
-
 
44106
    public _Fields fieldForId(int fieldId) {
-
 
44107
      return _Fields.findByThriftId(fieldId);
-
 
44108
    }
-
 
44109
 
-
 
44110
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
44111
      org.apache.thrift.protocol.TField field;
-
 
44112
      iprot.readStructBegin();
-
 
44113
      while (true)
-
 
44114
      {
-
 
44115
        field = iprot.readFieldBegin();
-
 
44116
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
44117
          break;
-
 
44118
        }
-
 
44119
        switch (field.id) {
-
 
44120
          case 1: // ORDER_ID
-
 
44121
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
44122
              this.orderId = iprot.readI64();
-
 
44123
              setOrderIdIsSet(true);
-
 
44124
            } else { 
-
 
44125
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
44126
            }
-
 
44127
            break;
-
 
44128
          case 2: // WAREHOUSE_ID
-
 
44129
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
44130
              this.warehouseId = iprot.readI64();
-
 
44131
              setWarehouseIdIsSet(true);
-
 
44132
            } else { 
-
 
44133
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
44134
            }
-
 
44135
            break;
-
 
44136
          default:
-
 
44137
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
44138
        }
-
 
44139
        iprot.readFieldEnd();
-
 
44140
      }
-
 
44141
      iprot.readStructEnd();
-
 
44142
      validate();
-
 
44143
    }
-
 
44144
 
-
 
44145
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
44146
      validate();
-
 
44147
 
-
 
44148
      oprot.writeStructBegin(STRUCT_DESC);
-
 
44149
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
-
 
44150
      oprot.writeI64(this.orderId);
-
 
44151
      oprot.writeFieldEnd();
-
 
44152
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
-
 
44153
      oprot.writeI64(this.warehouseId);
-
 
44154
      oprot.writeFieldEnd();
-
 
44155
      oprot.writeFieldStop();
-
 
44156
      oprot.writeStructEnd();
-
 
44157
    }
-
 
44158
 
-
 
44159
    @Override
-
 
44160
    public String toString() {
-
 
44161
      StringBuilder sb = new StringBuilder("shiftToWarehouse_args(");
-
 
44162
      boolean first = true;
-
 
44163
 
-
 
44164
      sb.append("orderId:");
-
 
44165
      sb.append(this.orderId);
-
 
44166
      first = false;
-
 
44167
      if (!first) sb.append(", ");
-
 
44168
      sb.append("warehouseId:");
-
 
44169
      sb.append(this.warehouseId);
-
 
44170
      first = false;
-
 
44171
      sb.append(")");
-
 
44172
      return sb.toString();
-
 
44173
    }
-
 
44174
 
-
 
44175
    public void validate() throws org.apache.thrift.TException {
-
 
44176
      // check for required fields
-
 
44177
    }
-
 
44178
 
-
 
44179
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
44180
      try {
-
 
44181
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
44182
      } catch (org.apache.thrift.TException te) {
-
 
44183
        throw new java.io.IOException(te);
-
 
44184
      }
-
 
44185
    }
-
 
44186
 
-
 
44187
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
44188
      try {
-
 
44189
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
44190
      } catch (org.apache.thrift.TException te) {
-
 
44191
        throw new java.io.IOException(te);
-
 
44192
      }
-
 
44193
    }
-
 
44194
 
-
 
44195
  }
-
 
44196
 
-
 
44197
  public static class shiftToWarehouse_result implements org.apache.thrift.TBase<shiftToWarehouse_result, shiftToWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
-
 
44198
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("shiftToWarehouse_result");
-
 
44199
 
-
 
44200
    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);
-
 
44201
    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);
-
 
44202
 
-
 
44203
    private Order success; // required
-
 
44204
    private TransactionServiceException ex; // required
-
 
44205
 
-
 
44206
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
44207
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
44208
      SUCCESS((short)0, "success"),
-
 
44209
      EX((short)1, "ex");
-
 
44210
 
-
 
44211
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
44212
 
-
 
44213
      static {
-
 
44214
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
44215
          byName.put(field.getFieldName(), field);
-
 
44216
        }
-
 
44217
      }
-
 
44218
 
-
 
44219
      /**
-
 
44220
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
44221
       */
-
 
44222
      public static _Fields findByThriftId(int fieldId) {
-
 
44223
        switch(fieldId) {
-
 
44224
          case 0: // SUCCESS
-
 
44225
            return SUCCESS;
-
 
44226
          case 1: // EX
-
 
44227
            return EX;
-
 
44228
          default:
-
 
44229
            return null;
-
 
44230
        }
-
 
44231
      }
-
 
44232
 
-
 
44233
      /**
-
 
44234
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
44235
       * if it is not found.
-
 
44236
       */
-
 
44237
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
44238
        _Fields fields = findByThriftId(fieldId);
-
 
44239
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
44240
        return fields;
-
 
44241
      }
-
 
44242
 
-
 
44243
      /**
-
 
44244
       * Find the _Fields constant that matches name, or null if its not found.
-
 
44245
       */
-
 
44246
      public static _Fields findByName(String name) {
-
 
44247
        return byName.get(name);
-
 
44248
      }
-
 
44249
 
-
 
44250
      private final short _thriftId;
-
 
44251
      private final String _fieldName;
-
 
44252
 
-
 
44253
      _Fields(short thriftId, String fieldName) {
-
 
44254
        _thriftId = thriftId;
-
 
44255
        _fieldName = fieldName;
-
 
44256
      }
-
 
44257
 
-
 
44258
      public short getThriftFieldId() {
-
 
44259
        return _thriftId;
-
 
44260
      }
-
 
44261
 
-
 
44262
      public String getFieldName() {
-
 
44263
        return _fieldName;
-
 
44264
      }
-
 
44265
    }
-
 
44266
 
-
 
44267
    // isset id assignments
-
 
44268
 
-
 
44269
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
44270
    static {
-
 
44271
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
44272
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
44273
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Order.class)));
-
 
44274
      tmpMap.put(_Fields.EX, new org.apache.thrift.meta_data.FieldMetaData("ex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
44275
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
-
 
44276
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
44277
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(shiftToWarehouse_result.class, metaDataMap);
-
 
44278
    }
-
 
44279
 
-
 
44280
    public shiftToWarehouse_result() {
-
 
44281
    }
-
 
44282
 
-
 
44283
    public shiftToWarehouse_result(
-
 
44284
      Order success,
-
 
44285
      TransactionServiceException ex)
-
 
44286
    {
-
 
44287
      this();
-
 
44288
      this.success = success;
-
 
44289
      this.ex = ex;
-
 
44290
    }
-
 
44291
 
-
 
44292
    /**
-
 
44293
     * Performs a deep copy on <i>other</i>.
-
 
44294
     */
-
 
44295
    public shiftToWarehouse_result(shiftToWarehouse_result other) {
-
 
44296
      if (other.isSetSuccess()) {
-
 
44297
        this.success = new Order(other.success);
-
 
44298
      }
-
 
44299
      if (other.isSetEx()) {
-
 
44300
        this.ex = new TransactionServiceException(other.ex);
-
 
44301
      }
-
 
44302
    }
-
 
44303
 
-
 
44304
    public shiftToWarehouse_result deepCopy() {
-
 
44305
      return new shiftToWarehouse_result(this);
-
 
44306
    }
-
 
44307
 
-
 
44308
    @Override
-
 
44309
    public void clear() {
-
 
44310
      this.success = null;
-
 
44311
      this.ex = null;
-
 
44312
    }
-
 
44313
 
-
 
44314
    public Order getSuccess() {
-
 
44315
      return this.success;
-
 
44316
    }
-
 
44317
 
-
 
44318
    public void setSuccess(Order success) {
-
 
44319
      this.success = success;
-
 
44320
    }
-
 
44321
 
-
 
44322
    public void unsetSuccess() {
-
 
44323
      this.success = null;
-
 
44324
    }
-
 
44325
 
-
 
44326
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
-
 
44327
    public boolean isSetSuccess() {
-
 
44328
      return this.success != null;
-
 
44329
    }
-
 
44330
 
-
 
44331
    public void setSuccessIsSet(boolean value) {
-
 
44332
      if (!value) {
-
 
44333
        this.success = null;
-
 
44334
      }
-
 
44335
    }
-
 
44336
 
-
 
44337
    public TransactionServiceException getEx() {
-
 
44338
      return this.ex;
-
 
44339
    }
-
 
44340
 
-
 
44341
    public void setEx(TransactionServiceException ex) {
-
 
44342
      this.ex = ex;
-
 
44343
    }
-
 
44344
 
-
 
44345
    public void unsetEx() {
-
 
44346
      this.ex = null;
-
 
44347
    }
-
 
44348
 
-
 
44349
    /** Returns true if field ex is set (has been assigned a value) and false otherwise */
-
 
44350
    public boolean isSetEx() {
-
 
44351
      return this.ex != null;
-
 
44352
    }
-
 
44353
 
-
 
44354
    public void setExIsSet(boolean value) {
-
 
44355
      if (!value) {
-
 
44356
        this.ex = null;
-
 
44357
      }
-
 
44358
    }
-
 
44359
 
-
 
44360
    public void setFieldValue(_Fields field, Object value) {
-
 
44361
      switch (field) {
-
 
44362
      case SUCCESS:
-
 
44363
        if (value == null) {
-
 
44364
          unsetSuccess();
-
 
44365
        } else {
-
 
44366
          setSuccess((Order)value);
-
 
44367
        }
-
 
44368
        break;
-
 
44369
 
-
 
44370
      case EX:
-
 
44371
        if (value == null) {
-
 
44372
          unsetEx();
-
 
44373
        } else {
-
 
44374
          setEx((TransactionServiceException)value);
-
 
44375
        }
-
 
44376
        break;
-
 
44377
 
-
 
44378
      }
-
 
44379
    }
-
 
44380
 
-
 
44381
    public Object getFieldValue(_Fields field) {
-
 
44382
      switch (field) {
-
 
44383
      case SUCCESS:
-
 
44384
        return getSuccess();
-
 
44385
 
-
 
44386
      case EX:
-
 
44387
        return getEx();
-
 
44388
 
-
 
44389
      }
-
 
44390
      throw new IllegalStateException();
-
 
44391
    }
-
 
44392
 
-
 
44393
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
44394
    public boolean isSet(_Fields field) {
-
 
44395
      if (field == null) {
-
 
44396
        throw new IllegalArgumentException();
-
 
44397
      }
-
 
44398
 
-
 
44399
      switch (field) {
-
 
44400
      case SUCCESS:
-
 
44401
        return isSetSuccess();
-
 
44402
      case EX:
-
 
44403
        return isSetEx();
-
 
44404
      }
-
 
44405
      throw new IllegalStateException();
-
 
44406
    }
-
 
44407
 
-
 
44408
    @Override
-
 
44409
    public boolean equals(Object that) {
-
 
44410
      if (that == null)
-
 
44411
        return false;
-
 
44412
      if (that instanceof shiftToWarehouse_result)
-
 
44413
        return this.equals((shiftToWarehouse_result)that);
-
 
44414
      return false;
-
 
44415
    }
-
 
44416
 
-
 
44417
    public boolean equals(shiftToWarehouse_result that) {
-
 
44418
      if (that == null)
-
 
44419
        return false;
-
 
44420
 
-
 
44421
      boolean this_present_success = true && this.isSetSuccess();
-
 
44422
      boolean that_present_success = true && that.isSetSuccess();
-
 
44423
      if (this_present_success || that_present_success) {
-
 
44424
        if (!(this_present_success && that_present_success))
-
 
44425
          return false;
-
 
44426
        if (!this.success.equals(that.success))
-
 
44427
          return false;
-
 
44428
      }
-
 
44429
 
-
 
44430
      boolean this_present_ex = true && this.isSetEx();
-
 
44431
      boolean that_present_ex = true && that.isSetEx();
-
 
44432
      if (this_present_ex || that_present_ex) {
-
 
44433
        if (!(this_present_ex && that_present_ex))
-
 
44434
          return false;
-
 
44435
        if (!this.ex.equals(that.ex))
-
 
44436
          return false;
-
 
44437
      }
-
 
44438
 
-
 
44439
      return true;
-
 
44440
    }
-
 
44441
 
-
 
44442
    @Override
-
 
44443
    public int hashCode() {
-
 
44444
      return 0;
-
 
44445
    }
-
 
44446
 
-
 
44447
    public int compareTo(shiftToWarehouse_result other) {
-
 
44448
      if (!getClass().equals(other.getClass())) {
-
 
44449
        return getClass().getName().compareTo(other.getClass().getName());
-
 
44450
      }
-
 
44451
 
-
 
44452
      int lastComparison = 0;
-
 
44453
      shiftToWarehouse_result typedOther = (shiftToWarehouse_result)other;
-
 
44454
 
-
 
44455
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
-
 
44456
      if (lastComparison != 0) {
-
 
44457
        return lastComparison;
-
 
44458
      }
-
 
44459
      if (isSetSuccess()) {
-
 
44460
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
-
 
44461
        if (lastComparison != 0) {
-
 
44462
          return lastComparison;
-
 
44463
        }
-
 
44464
      }
-
 
44465
      lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx());
-
 
44466
      if (lastComparison != 0) {
-
 
44467
        return lastComparison;
-
 
44468
      }
-
 
44469
      if (isSetEx()) {
-
 
44470
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex);
-
 
44471
        if (lastComparison != 0) {
-
 
44472
          return lastComparison;
-
 
44473
        }
-
 
44474
      }
-
 
44475
      return 0;
-
 
44476
    }
-
 
44477
 
-
 
44478
    public _Fields fieldForId(int fieldId) {
-
 
44479
      return _Fields.findByThriftId(fieldId);
-
 
44480
    }
-
 
44481
 
-
 
44482
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
44483
      org.apache.thrift.protocol.TField field;
-
 
44484
      iprot.readStructBegin();
-
 
44485
      while (true)
-
 
44486
      {
-
 
44487
        field = iprot.readFieldBegin();
-
 
44488
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
44489
          break;
-
 
44490
        }
-
 
44491
        switch (field.id) {
-
 
44492
          case 0: // SUCCESS
-
 
44493
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
44494
              this.success = new Order();
-
 
44495
              this.success.read(iprot);
-
 
44496
            } else { 
-
 
44497
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
44498
            }
-
 
44499
            break;
-
 
44500
          case 1: // EX
-
 
44501
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
44502
              this.ex = new TransactionServiceException();
-
 
44503
              this.ex.read(iprot);
-
 
44504
            } else { 
-
 
44505
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
44506
            }
-
 
44507
            break;
-
 
44508
          default:
-
 
44509
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
44510
        }
-
 
44511
        iprot.readFieldEnd();
-
 
44512
      }
-
 
44513
      iprot.readStructEnd();
-
 
44514
      validate();
-
 
44515
    }
-
 
44516
 
-
 
44517
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
44518
      oprot.writeStructBegin(STRUCT_DESC);
-
 
44519
 
-
 
44520
      if (this.isSetSuccess()) {
-
 
44521
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
-
 
44522
        this.success.write(oprot);
-
 
44523
        oprot.writeFieldEnd();
-
 
44524
      } else if (this.isSetEx()) {
-
 
44525
        oprot.writeFieldBegin(EX_FIELD_DESC);
-
 
44526
        this.ex.write(oprot);
-
 
44527
        oprot.writeFieldEnd();
-
 
44528
      }
-
 
44529
      oprot.writeFieldStop();
-
 
44530
      oprot.writeStructEnd();
-
 
44531
    }
-
 
44532
 
-
 
44533
    @Override
-
 
44534
    public String toString() {
-
 
44535
      StringBuilder sb = new StringBuilder("shiftToWarehouse_result(");
-
 
44536
      boolean first = true;
-
 
44537
 
-
 
44538
      sb.append("success:");
-
 
44539
      if (this.success == null) {
-
 
44540
        sb.append("null");
42838
      } else {
44541
      } else {
42839
        sb.append(this.success);
44542
        sb.append(this.success);
42840
      }
44543
      }
42841
      first = false;
44544
      first = false;
42842
      if (!first) sb.append(", ");
44545
      if (!first) sb.append(", ");