Subversion Repositories SmartDukaan

Rev

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

Rev 5591 Rev 6385
Line 78... Line 78...
78
     * @param open
78
     * @param open
79
     */
79
     */
80
    public List<Purchase> getAllPurchases(long purchaseOrderId, boolean open) throws PurchaseServiceException, org.apache.thrift.TException;
80
    public List<Purchase> getAllPurchases(long purchaseOrderId, boolean open) throws PurchaseServiceException, org.apache.thrift.TException;
81
 
81
 
82
    /**
82
    /**
-
 
83
     * Returns all purchases for the given purchase order. Throws an exception if no such purchase order exists
-
 
84
     * 
-
 
85
     * @param purchaseOrderId
-
 
86
     */
-
 
87
    public List<Purchase> getPurchasesForPO(long purchaseOrderId) throws PurchaseServiceException, org.apache.thrift.TException;
-
 
88
 
-
 
89
    /**
83
     * Returns the purchase order object for a given purchase
90
     * Returns the purchase order object for a given purchase
84
     * 
91
     * 
85
     * @param purchaseId
92
     * @param purchaseId
86
     */
93
     */
87
    public PurchaseOrder getPurchaseOrderForPurchase(long purchaseId) throws org.apache.thrift.TException;
94
    public PurchaseOrder getPurchaseOrderForPurchase(long purchaseId) throws org.apache.thrift.TException;
Line 167... Line 174...
167
 
174
 
168
    public void closePurchase(long purchaseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.closePurchase_call> resultHandler) throws org.apache.thrift.TException;
175
    public void closePurchase(long purchaseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.closePurchase_call> resultHandler) throws org.apache.thrift.TException;
169
 
176
 
170
    public void getAllPurchases(long purchaseOrderId, boolean open, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllPurchases_call> resultHandler) throws org.apache.thrift.TException;
177
    public void getAllPurchases(long purchaseOrderId, boolean open, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllPurchases_call> resultHandler) throws org.apache.thrift.TException;
171
 
178
 
-
 
179
    public void getPurchasesForPO(long purchaseOrderId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPurchasesForPO_call> resultHandler) throws org.apache.thrift.TException;
-
 
180
 
172
    public void getPurchaseOrderForPurchase(long purchaseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPurchaseOrderForPurchase_call> resultHandler) throws org.apache.thrift.TException;
181
    public void getPurchaseOrderForPurchase(long purchaseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPurchaseOrderForPurchase_call> resultHandler) throws org.apache.thrift.TException;
173
 
182
 
174
    public void getPendingPurchaseOrders(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPendingPurchaseOrders_call> resultHandler) throws org.apache.thrift.TException;
183
    public void getPendingPurchaseOrders(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPendingPurchaseOrders_call> resultHandler) throws org.apache.thrift.TException;
175
 
184
 
176
    public void getSuppliers(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSuppliers_call> resultHandler) throws org.apache.thrift.TException;
185
    public void getSuppliers(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getSuppliers_call> resultHandler) throws org.apache.thrift.TException;
Line 394... Line 403...
394
        throw result.e;
403
        throw result.e;
395
      }
404
      }
396
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllPurchases failed: unknown result");
405
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllPurchases failed: unknown result");
397
    }
406
    }
398
 
407
 
-
 
408
    public List<Purchase> getPurchasesForPO(long purchaseOrderId) throws PurchaseServiceException, org.apache.thrift.TException
-
 
409
    {
-
 
410
      send_getPurchasesForPO(purchaseOrderId);
-
 
411
      return recv_getPurchasesForPO();
-
 
412
    }
-
 
413
 
-
 
414
    public void send_getPurchasesForPO(long purchaseOrderId) throws org.apache.thrift.TException
-
 
415
    {
-
 
416
      getPurchasesForPO_args args = new getPurchasesForPO_args();
-
 
417
      args.setPurchaseOrderId(purchaseOrderId);
-
 
418
      sendBase("getPurchasesForPO", args);
-
 
419
    }
-
 
420
 
-
 
421
    public List<Purchase> recv_getPurchasesForPO() throws PurchaseServiceException, org.apache.thrift.TException
-
 
422
    {
-
 
423
      getPurchasesForPO_result result = new getPurchasesForPO_result();
-
 
424
      receiveBase(result, "getPurchasesForPO");
-
 
425
      if (result.isSetSuccess()) {
-
 
426
        return result.success;
-
 
427
      }
-
 
428
      if (result.e != null) {
-
 
429
        throw result.e;
-
 
430
      }
-
 
431
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPurchasesForPO failed: unknown result");
-
 
432
    }
-
 
433
 
399
    public PurchaseOrder getPurchaseOrderForPurchase(long purchaseId) throws org.apache.thrift.TException
434
    public PurchaseOrder getPurchaseOrderForPurchase(long purchaseId) throws org.apache.thrift.TException
400
    {
435
    {
401
      send_getPurchaseOrderForPurchase(purchaseId);
436
      send_getPurchaseOrderForPurchase(purchaseId);
402
      return recv_getPurchaseOrderForPurchase();
437
      return recv_getPurchaseOrderForPurchase();
403
    }
438
    }
Line 881... Line 916...
881
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
916
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
882
        return (new Client(prot)).recv_getAllPurchases();
917
        return (new Client(prot)).recv_getAllPurchases();
883
      }
918
      }
884
    }
919
    }
885
 
920
 
-
 
921
    public void getPurchasesForPO(long purchaseOrderId, org.apache.thrift.async.AsyncMethodCallback<getPurchasesForPO_call> resultHandler) throws org.apache.thrift.TException {
-
 
922
      checkReady();
-
 
923
      getPurchasesForPO_call method_call = new getPurchasesForPO_call(purchaseOrderId, resultHandler, this, ___protocolFactory, ___transport);
-
 
924
      this.___currentMethod = method_call;
-
 
925
      ___manager.call(method_call);
-
 
926
    }
-
 
927
 
-
 
928
    public static class getPurchasesForPO_call extends org.apache.thrift.async.TAsyncMethodCall {
-
 
929
      private long purchaseOrderId;
-
 
930
      public getPurchasesForPO_call(long purchaseOrderId, org.apache.thrift.async.AsyncMethodCallback<getPurchasesForPO_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 {
-
 
931
        super(client, protocolFactory, transport, resultHandler, false);
-
 
932
        this.purchaseOrderId = purchaseOrderId;
-
 
933
      }
-
 
934
 
-
 
935
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-
 
936
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPurchasesForPO", org.apache.thrift.protocol.TMessageType.CALL, 0));
-
 
937
        getPurchasesForPO_args args = new getPurchasesForPO_args();
-
 
938
        args.setPurchaseOrderId(purchaseOrderId);
-
 
939
        args.write(prot);
-
 
940
        prot.writeMessageEnd();
-
 
941
      }
-
 
942
 
-
 
943
      public List<Purchase> getResult() throws PurchaseServiceException, org.apache.thrift.TException {
-
 
944
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-
 
945
          throw new IllegalStateException("Method call not finished!");
-
 
946
        }
-
 
947
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-
 
948
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-
 
949
        return (new Client(prot)).recv_getPurchasesForPO();
-
 
950
      }
-
 
951
    }
-
 
952
 
886
    public void getPurchaseOrderForPurchase(long purchaseId, org.apache.thrift.async.AsyncMethodCallback<getPurchaseOrderForPurchase_call> resultHandler) throws org.apache.thrift.TException {
953
    public void getPurchaseOrderForPurchase(long purchaseId, org.apache.thrift.async.AsyncMethodCallback<getPurchaseOrderForPurchase_call> resultHandler) throws org.apache.thrift.TException {
887
      checkReady();
954
      checkReady();
888
      getPurchaseOrderForPurchase_call method_call = new getPurchaseOrderForPurchase_call(purchaseId, resultHandler, this, ___protocolFactory, ___transport);
955
      getPurchaseOrderForPurchase_call method_call = new getPurchaseOrderForPurchase_call(purchaseId, resultHandler, this, ___protocolFactory, ___transport);
889
      this.___currentMethod = method_call;
956
      this.___currentMethod = method_call;
890
      ___manager.call(method_call);
957
      ___manager.call(method_call);
Line 1230... Line 1297...
1230
      processMap.put("getAllPurchaseOrders", new getAllPurchaseOrders());
1297
      processMap.put("getAllPurchaseOrders", new getAllPurchaseOrders());
1231
      processMap.put("getSupplier", new getSupplier());
1298
      processMap.put("getSupplier", new getSupplier());
1232
      processMap.put("startPurchase", new startPurchase());
1299
      processMap.put("startPurchase", new startPurchase());
1233
      processMap.put("closePurchase", new closePurchase());
1300
      processMap.put("closePurchase", new closePurchase());
1234
      processMap.put("getAllPurchases", new getAllPurchases());
1301
      processMap.put("getAllPurchases", new getAllPurchases());
-
 
1302
      processMap.put("getPurchasesForPO", new getPurchasesForPO());
1235
      processMap.put("getPurchaseOrderForPurchase", new getPurchaseOrderForPurchase());
1303
      processMap.put("getPurchaseOrderForPurchase", new getPurchaseOrderForPurchase());
1236
      processMap.put("getPendingPurchaseOrders", new getPendingPurchaseOrders());
1304
      processMap.put("getPendingPurchaseOrders", new getPendingPurchaseOrders());
1237
      processMap.put("getSuppliers", new getSuppliers());
1305
      processMap.put("getSuppliers", new getSuppliers());
1238
      processMap.put("fulfillPO", new fulfillPO());
1306
      processMap.put("fulfillPO", new fulfillPO());
1239
      processMap.put("updatePurchaseOrder", new updatePurchaseOrder());
1307
      processMap.put("updatePurchaseOrder", new updatePurchaseOrder());
Line 1386... Line 1454...
1386
        }
1454
        }
1387
        return result;
1455
        return result;
1388
      }
1456
      }
1389
    }
1457
    }
1390
 
1458
 
-
 
1459
    private static class getPurchasesForPO<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPurchasesForPO_args> {
-
 
1460
      public getPurchasesForPO() {
-
 
1461
        super("getPurchasesForPO");
-
 
1462
      }
-
 
1463
 
-
 
1464
      protected getPurchasesForPO_args getEmptyArgsInstance() {
-
 
1465
        return new getPurchasesForPO_args();
-
 
1466
      }
-
 
1467
 
-
 
1468
      protected getPurchasesForPO_result getResult(I iface, getPurchasesForPO_args args) throws org.apache.thrift.TException {
-
 
1469
        getPurchasesForPO_result result = new getPurchasesForPO_result();
-
 
1470
        try {
-
 
1471
          result.success = iface.getPurchasesForPO(args.purchaseOrderId);
-
 
1472
        } catch (PurchaseServiceException e) {
-
 
1473
          result.e = e;
-
 
1474
        }
-
 
1475
        return result;
-
 
1476
      }
-
 
1477
    }
-
 
1478
 
1391
    private static class getPurchaseOrderForPurchase<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPurchaseOrderForPurchase_args> {
1479
    private static class getPurchaseOrderForPurchase<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPurchaseOrderForPurchase_args> {
1392
      public getPurchaseOrderForPurchase() {
1480
      public getPurchaseOrderForPurchase() {
1393
        super("getPurchaseOrderForPurchase");
1481
        super("getPurchaseOrderForPurchase");
1394
      }
1482
      }
1395
 
1483
 
Line 6634... Line 6722...
6634
      }
6722
      }
6635
    }
6723
    }
6636
 
6724
 
6637
  }
6725
  }
6638
 
6726
 
-
 
6727
  public static class getPurchasesForPO_args implements org.apache.thrift.TBase<getPurchasesForPO_args, getPurchasesForPO_args._Fields>, java.io.Serializable, Cloneable   {
-
 
6728
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPurchasesForPO_args");
-
 
6729
 
-
 
6730
    private static final org.apache.thrift.protocol.TField PURCHASE_ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("purchaseOrderId", org.apache.thrift.protocol.TType.I64, (short)1);
-
 
6731
 
-
 
6732
    private long purchaseOrderId; // required
-
 
6733
 
-
 
6734
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
6735
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
6736
      PURCHASE_ORDER_ID((short)1, "purchaseOrderId");
-
 
6737
 
-
 
6738
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
6739
 
-
 
6740
      static {
-
 
6741
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
6742
          byName.put(field.getFieldName(), field);
-
 
6743
        }
-
 
6744
      }
-
 
6745
 
-
 
6746
      /**
-
 
6747
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
6748
       */
-
 
6749
      public static _Fields findByThriftId(int fieldId) {
-
 
6750
        switch(fieldId) {
-
 
6751
          case 1: // PURCHASE_ORDER_ID
-
 
6752
            return PURCHASE_ORDER_ID;
-
 
6753
          default:
-
 
6754
            return null;
-
 
6755
        }
-
 
6756
      }
-
 
6757
 
-
 
6758
      /**
-
 
6759
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
6760
       * if it is not found.
-
 
6761
       */
-
 
6762
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
6763
        _Fields fields = findByThriftId(fieldId);
-
 
6764
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
6765
        return fields;
-
 
6766
      }
-
 
6767
 
-
 
6768
      /**
-
 
6769
       * Find the _Fields constant that matches name, or null if its not found.
-
 
6770
       */
-
 
6771
      public static _Fields findByName(String name) {
-
 
6772
        return byName.get(name);
-
 
6773
      }
-
 
6774
 
-
 
6775
      private final short _thriftId;
-
 
6776
      private final String _fieldName;
-
 
6777
 
-
 
6778
      _Fields(short thriftId, String fieldName) {
-
 
6779
        _thriftId = thriftId;
-
 
6780
        _fieldName = fieldName;
-
 
6781
      }
-
 
6782
 
-
 
6783
      public short getThriftFieldId() {
-
 
6784
        return _thriftId;
-
 
6785
      }
-
 
6786
 
-
 
6787
      public String getFieldName() {
-
 
6788
        return _fieldName;
-
 
6789
      }
-
 
6790
    }
-
 
6791
 
-
 
6792
    // isset id assignments
-
 
6793
    private static final int __PURCHASEORDERID_ISSET_ID = 0;
-
 
6794
    private BitSet __isset_bit_vector = new BitSet(1);
-
 
6795
 
-
 
6796
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
6797
    static {
-
 
6798
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
6799
      tmpMap.put(_Fields.PURCHASE_ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("purchaseOrderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
6800
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
6801
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
6802
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPurchasesForPO_args.class, metaDataMap);
-
 
6803
    }
-
 
6804
 
-
 
6805
    public getPurchasesForPO_args() {
-
 
6806
    }
-
 
6807
 
-
 
6808
    public getPurchasesForPO_args(
-
 
6809
      long purchaseOrderId)
-
 
6810
    {
-
 
6811
      this();
-
 
6812
      this.purchaseOrderId = purchaseOrderId;
-
 
6813
      setPurchaseOrderIdIsSet(true);
-
 
6814
    }
-
 
6815
 
-
 
6816
    /**
-
 
6817
     * Performs a deep copy on <i>other</i>.
-
 
6818
     */
-
 
6819
    public getPurchasesForPO_args(getPurchasesForPO_args other) {
-
 
6820
      __isset_bit_vector.clear();
-
 
6821
      __isset_bit_vector.or(other.__isset_bit_vector);
-
 
6822
      this.purchaseOrderId = other.purchaseOrderId;
-
 
6823
    }
-
 
6824
 
-
 
6825
    public getPurchasesForPO_args deepCopy() {
-
 
6826
      return new getPurchasesForPO_args(this);
-
 
6827
    }
-
 
6828
 
-
 
6829
    @Override
-
 
6830
    public void clear() {
-
 
6831
      setPurchaseOrderIdIsSet(false);
-
 
6832
      this.purchaseOrderId = 0;
-
 
6833
    }
-
 
6834
 
-
 
6835
    public long getPurchaseOrderId() {
-
 
6836
      return this.purchaseOrderId;
-
 
6837
    }
-
 
6838
 
-
 
6839
    public void setPurchaseOrderId(long purchaseOrderId) {
-
 
6840
      this.purchaseOrderId = purchaseOrderId;
-
 
6841
      setPurchaseOrderIdIsSet(true);
-
 
6842
    }
-
 
6843
 
-
 
6844
    public void unsetPurchaseOrderId() {
-
 
6845
      __isset_bit_vector.clear(__PURCHASEORDERID_ISSET_ID);
-
 
6846
    }
-
 
6847
 
-
 
6848
    /** Returns true if field purchaseOrderId is set (has been assigned a value) and false otherwise */
-
 
6849
    public boolean isSetPurchaseOrderId() {
-
 
6850
      return __isset_bit_vector.get(__PURCHASEORDERID_ISSET_ID);
-
 
6851
    }
-
 
6852
 
-
 
6853
    public void setPurchaseOrderIdIsSet(boolean value) {
-
 
6854
      __isset_bit_vector.set(__PURCHASEORDERID_ISSET_ID, value);
-
 
6855
    }
-
 
6856
 
-
 
6857
    public void setFieldValue(_Fields field, Object value) {
-
 
6858
      switch (field) {
-
 
6859
      case PURCHASE_ORDER_ID:
-
 
6860
        if (value == null) {
-
 
6861
          unsetPurchaseOrderId();
-
 
6862
        } else {
-
 
6863
          setPurchaseOrderId((Long)value);
-
 
6864
        }
-
 
6865
        break;
-
 
6866
 
-
 
6867
      }
-
 
6868
    }
-
 
6869
 
-
 
6870
    public Object getFieldValue(_Fields field) {
-
 
6871
      switch (field) {
-
 
6872
      case PURCHASE_ORDER_ID:
-
 
6873
        return Long.valueOf(getPurchaseOrderId());
-
 
6874
 
-
 
6875
      }
-
 
6876
      throw new IllegalStateException();
-
 
6877
    }
-
 
6878
 
-
 
6879
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
6880
    public boolean isSet(_Fields field) {
-
 
6881
      if (field == null) {
-
 
6882
        throw new IllegalArgumentException();
-
 
6883
      }
-
 
6884
 
-
 
6885
      switch (field) {
-
 
6886
      case PURCHASE_ORDER_ID:
-
 
6887
        return isSetPurchaseOrderId();
-
 
6888
      }
-
 
6889
      throw new IllegalStateException();
-
 
6890
    }
-
 
6891
 
-
 
6892
    @Override
-
 
6893
    public boolean equals(Object that) {
-
 
6894
      if (that == null)
-
 
6895
        return false;
-
 
6896
      if (that instanceof getPurchasesForPO_args)
-
 
6897
        return this.equals((getPurchasesForPO_args)that);
-
 
6898
      return false;
-
 
6899
    }
-
 
6900
 
-
 
6901
    public boolean equals(getPurchasesForPO_args that) {
-
 
6902
      if (that == null)
-
 
6903
        return false;
-
 
6904
 
-
 
6905
      boolean this_present_purchaseOrderId = true;
-
 
6906
      boolean that_present_purchaseOrderId = true;
-
 
6907
      if (this_present_purchaseOrderId || that_present_purchaseOrderId) {
-
 
6908
        if (!(this_present_purchaseOrderId && that_present_purchaseOrderId))
-
 
6909
          return false;
-
 
6910
        if (this.purchaseOrderId != that.purchaseOrderId)
-
 
6911
          return false;
-
 
6912
      }
-
 
6913
 
-
 
6914
      return true;
-
 
6915
    }
-
 
6916
 
-
 
6917
    @Override
-
 
6918
    public int hashCode() {
-
 
6919
      return 0;
-
 
6920
    }
-
 
6921
 
-
 
6922
    public int compareTo(getPurchasesForPO_args other) {
-
 
6923
      if (!getClass().equals(other.getClass())) {
-
 
6924
        return getClass().getName().compareTo(other.getClass().getName());
-
 
6925
      }
-
 
6926
 
-
 
6927
      int lastComparison = 0;
-
 
6928
      getPurchasesForPO_args typedOther = (getPurchasesForPO_args)other;
-
 
6929
 
-
 
6930
      lastComparison = Boolean.valueOf(isSetPurchaseOrderId()).compareTo(typedOther.isSetPurchaseOrderId());
-
 
6931
      if (lastComparison != 0) {
-
 
6932
        return lastComparison;
-
 
6933
      }
-
 
6934
      if (isSetPurchaseOrderId()) {
-
 
6935
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.purchaseOrderId, typedOther.purchaseOrderId);
-
 
6936
        if (lastComparison != 0) {
-
 
6937
          return lastComparison;
-
 
6938
        }
-
 
6939
      }
-
 
6940
      return 0;
-
 
6941
    }
-
 
6942
 
-
 
6943
    public _Fields fieldForId(int fieldId) {
-
 
6944
      return _Fields.findByThriftId(fieldId);
-
 
6945
    }
-
 
6946
 
-
 
6947
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
6948
      org.apache.thrift.protocol.TField field;
-
 
6949
      iprot.readStructBegin();
-
 
6950
      while (true)
-
 
6951
      {
-
 
6952
        field = iprot.readFieldBegin();
-
 
6953
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
6954
          break;
-
 
6955
        }
-
 
6956
        switch (field.id) {
-
 
6957
          case 1: // PURCHASE_ORDER_ID
-
 
6958
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
6959
              this.purchaseOrderId = iprot.readI64();
-
 
6960
              setPurchaseOrderIdIsSet(true);
-
 
6961
            } else { 
-
 
6962
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
6963
            }
-
 
6964
            break;
-
 
6965
          default:
-
 
6966
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
6967
        }
-
 
6968
        iprot.readFieldEnd();
-
 
6969
      }
-
 
6970
      iprot.readStructEnd();
-
 
6971
      validate();
-
 
6972
    }
-
 
6973
 
-
 
6974
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
6975
      validate();
-
 
6976
 
-
 
6977
      oprot.writeStructBegin(STRUCT_DESC);
-
 
6978
      oprot.writeFieldBegin(PURCHASE_ORDER_ID_FIELD_DESC);
-
 
6979
      oprot.writeI64(this.purchaseOrderId);
-
 
6980
      oprot.writeFieldEnd();
-
 
6981
      oprot.writeFieldStop();
-
 
6982
      oprot.writeStructEnd();
-
 
6983
    }
-
 
6984
 
-
 
6985
    @Override
-
 
6986
    public String toString() {
-
 
6987
      StringBuilder sb = new StringBuilder("getPurchasesForPO_args(");
-
 
6988
      boolean first = true;
-
 
6989
 
-
 
6990
      sb.append("purchaseOrderId:");
-
 
6991
      sb.append(this.purchaseOrderId);
-
 
6992
      first = false;
-
 
6993
      sb.append(")");
-
 
6994
      return sb.toString();
-
 
6995
    }
-
 
6996
 
-
 
6997
    public void validate() throws org.apache.thrift.TException {
-
 
6998
      // check for required fields
-
 
6999
    }
-
 
7000
 
-
 
7001
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
7002
      try {
-
 
7003
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
7004
      } catch (org.apache.thrift.TException te) {
-
 
7005
        throw new java.io.IOException(te);
-
 
7006
      }
-
 
7007
    }
-
 
7008
 
-
 
7009
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
7010
      try {
-
 
7011
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-
 
7012
        __isset_bit_vector = new BitSet(1);
-
 
7013
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
7014
      } catch (org.apache.thrift.TException te) {
-
 
7015
        throw new java.io.IOException(te);
-
 
7016
      }
-
 
7017
    }
-
 
7018
 
-
 
7019
  }
-
 
7020
 
-
 
7021
  public static class getPurchasesForPO_result implements org.apache.thrift.TBase<getPurchasesForPO_result, getPurchasesForPO_result._Fields>, java.io.Serializable, Cloneable   {
-
 
7022
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPurchasesForPO_result");
-
 
7023
 
-
 
7024
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
-
 
7025
    private static final org.apache.thrift.protocol.TField E_FIELD_DESC = new org.apache.thrift.protocol.TField("e", org.apache.thrift.protocol.TType.STRUCT, (short)1);
-
 
7026
 
-
 
7027
    private List<Purchase> success; // required
-
 
7028
    private PurchaseServiceException e; // required
-
 
7029
 
-
 
7030
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
7031
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
7032
      SUCCESS((short)0, "success"),
-
 
7033
      E((short)1, "e");
-
 
7034
 
-
 
7035
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
7036
 
-
 
7037
      static {
-
 
7038
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
7039
          byName.put(field.getFieldName(), field);
-
 
7040
        }
-
 
7041
      }
-
 
7042
 
-
 
7043
      /**
-
 
7044
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
7045
       */
-
 
7046
      public static _Fields findByThriftId(int fieldId) {
-
 
7047
        switch(fieldId) {
-
 
7048
          case 0: // SUCCESS
-
 
7049
            return SUCCESS;
-
 
7050
          case 1: // E
-
 
7051
            return E;
-
 
7052
          default:
-
 
7053
            return null;
-
 
7054
        }
-
 
7055
      }
-
 
7056
 
-
 
7057
      /**
-
 
7058
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
7059
       * if it is not found.
-
 
7060
       */
-
 
7061
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
7062
        _Fields fields = findByThriftId(fieldId);
-
 
7063
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
7064
        return fields;
-
 
7065
      }
-
 
7066
 
-
 
7067
      /**
-
 
7068
       * Find the _Fields constant that matches name, or null if its not found.
-
 
7069
       */
-
 
7070
      public static _Fields findByName(String name) {
-
 
7071
        return byName.get(name);
-
 
7072
      }
-
 
7073
 
-
 
7074
      private final short _thriftId;
-
 
7075
      private final String _fieldName;
-
 
7076
 
-
 
7077
      _Fields(short thriftId, String fieldName) {
-
 
7078
        _thriftId = thriftId;
-
 
7079
        _fieldName = fieldName;
-
 
7080
      }
-
 
7081
 
-
 
7082
      public short getThriftFieldId() {
-
 
7083
        return _thriftId;
-
 
7084
      }
-
 
7085
 
-
 
7086
      public String getFieldName() {
-
 
7087
        return _fieldName;
-
 
7088
      }
-
 
7089
    }
-
 
7090
 
-
 
7091
    // isset id assignments
-
 
7092
 
-
 
7093
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
7094
    static {
-
 
7095
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
7096
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
7097
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
-
 
7098
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Purchase.class))));
-
 
7099
      tmpMap.put(_Fields.E, new org.apache.thrift.meta_data.FieldMetaData("e", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
7100
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
-
 
7101
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
7102
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPurchasesForPO_result.class, metaDataMap);
-
 
7103
    }
-
 
7104
 
-
 
7105
    public getPurchasesForPO_result() {
-
 
7106
    }
-
 
7107
 
-
 
7108
    public getPurchasesForPO_result(
-
 
7109
      List<Purchase> success,
-
 
7110
      PurchaseServiceException e)
-
 
7111
    {
-
 
7112
      this();
-
 
7113
      this.success = success;
-
 
7114
      this.e = e;
-
 
7115
    }
-
 
7116
 
-
 
7117
    /**
-
 
7118
     * Performs a deep copy on <i>other</i>.
-
 
7119
     */
-
 
7120
    public getPurchasesForPO_result(getPurchasesForPO_result other) {
-
 
7121
      if (other.isSetSuccess()) {
-
 
7122
        List<Purchase> __this__success = new ArrayList<Purchase>();
-
 
7123
        for (Purchase other_element : other.success) {
-
 
7124
          __this__success.add(new Purchase(other_element));
-
 
7125
        }
-
 
7126
        this.success = __this__success;
-
 
7127
      }
-
 
7128
      if (other.isSetE()) {
-
 
7129
        this.e = new PurchaseServiceException(other.e);
-
 
7130
      }
-
 
7131
    }
-
 
7132
 
-
 
7133
    public getPurchasesForPO_result deepCopy() {
-
 
7134
      return new getPurchasesForPO_result(this);
-
 
7135
    }
-
 
7136
 
-
 
7137
    @Override
-
 
7138
    public void clear() {
-
 
7139
      this.success = null;
-
 
7140
      this.e = null;
-
 
7141
    }
-
 
7142
 
-
 
7143
    public int getSuccessSize() {
-
 
7144
      return (this.success == null) ? 0 : this.success.size();
-
 
7145
    }
-
 
7146
 
-
 
7147
    public java.util.Iterator<Purchase> getSuccessIterator() {
-
 
7148
      return (this.success == null) ? null : this.success.iterator();
-
 
7149
    }
-
 
7150
 
-
 
7151
    public void addToSuccess(Purchase elem) {
-
 
7152
      if (this.success == null) {
-
 
7153
        this.success = new ArrayList<Purchase>();
-
 
7154
      }
-
 
7155
      this.success.add(elem);
-
 
7156
    }
-
 
7157
 
-
 
7158
    public List<Purchase> getSuccess() {
-
 
7159
      return this.success;
-
 
7160
    }
-
 
7161
 
-
 
7162
    public void setSuccess(List<Purchase> success) {
-
 
7163
      this.success = success;
-
 
7164
    }
-
 
7165
 
-
 
7166
    public void unsetSuccess() {
-
 
7167
      this.success = null;
-
 
7168
    }
-
 
7169
 
-
 
7170
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
-
 
7171
    public boolean isSetSuccess() {
-
 
7172
      return this.success != null;
-
 
7173
    }
-
 
7174
 
-
 
7175
    public void setSuccessIsSet(boolean value) {
-
 
7176
      if (!value) {
-
 
7177
        this.success = null;
-
 
7178
      }
-
 
7179
    }
-
 
7180
 
-
 
7181
    public PurchaseServiceException getE() {
-
 
7182
      return this.e;
-
 
7183
    }
-
 
7184
 
-
 
7185
    public void setE(PurchaseServiceException e) {
-
 
7186
      this.e = e;
-
 
7187
    }
-
 
7188
 
-
 
7189
    public void unsetE() {
-
 
7190
      this.e = null;
-
 
7191
    }
-
 
7192
 
-
 
7193
    /** Returns true if field e is set (has been assigned a value) and false otherwise */
-
 
7194
    public boolean isSetE() {
-
 
7195
      return this.e != null;
-
 
7196
    }
-
 
7197
 
-
 
7198
    public void setEIsSet(boolean value) {
-
 
7199
      if (!value) {
-
 
7200
        this.e = null;
-
 
7201
      }
-
 
7202
    }
-
 
7203
 
-
 
7204
    public void setFieldValue(_Fields field, Object value) {
-
 
7205
      switch (field) {
-
 
7206
      case SUCCESS:
-
 
7207
        if (value == null) {
-
 
7208
          unsetSuccess();
-
 
7209
        } else {
-
 
7210
          setSuccess((List<Purchase>)value);
-
 
7211
        }
-
 
7212
        break;
-
 
7213
 
-
 
7214
      case E:
-
 
7215
        if (value == null) {
-
 
7216
          unsetE();
-
 
7217
        } else {
-
 
7218
          setE((PurchaseServiceException)value);
-
 
7219
        }
-
 
7220
        break;
-
 
7221
 
-
 
7222
      }
-
 
7223
    }
-
 
7224
 
-
 
7225
    public Object getFieldValue(_Fields field) {
-
 
7226
      switch (field) {
-
 
7227
      case SUCCESS:
-
 
7228
        return getSuccess();
-
 
7229
 
-
 
7230
      case E:
-
 
7231
        return getE();
-
 
7232
 
-
 
7233
      }
-
 
7234
      throw new IllegalStateException();
-
 
7235
    }
-
 
7236
 
-
 
7237
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
7238
    public boolean isSet(_Fields field) {
-
 
7239
      if (field == null) {
-
 
7240
        throw new IllegalArgumentException();
-
 
7241
      }
-
 
7242
 
-
 
7243
      switch (field) {
-
 
7244
      case SUCCESS:
-
 
7245
        return isSetSuccess();
-
 
7246
      case E:
-
 
7247
        return isSetE();
-
 
7248
      }
-
 
7249
      throw new IllegalStateException();
-
 
7250
    }
-
 
7251
 
-
 
7252
    @Override
-
 
7253
    public boolean equals(Object that) {
-
 
7254
      if (that == null)
-
 
7255
        return false;
-
 
7256
      if (that instanceof getPurchasesForPO_result)
-
 
7257
        return this.equals((getPurchasesForPO_result)that);
-
 
7258
      return false;
-
 
7259
    }
-
 
7260
 
-
 
7261
    public boolean equals(getPurchasesForPO_result that) {
-
 
7262
      if (that == null)
-
 
7263
        return false;
-
 
7264
 
-
 
7265
      boolean this_present_success = true && this.isSetSuccess();
-
 
7266
      boolean that_present_success = true && that.isSetSuccess();
-
 
7267
      if (this_present_success || that_present_success) {
-
 
7268
        if (!(this_present_success && that_present_success))
-
 
7269
          return false;
-
 
7270
        if (!this.success.equals(that.success))
-
 
7271
          return false;
-
 
7272
      }
-
 
7273
 
-
 
7274
      boolean this_present_e = true && this.isSetE();
-
 
7275
      boolean that_present_e = true && that.isSetE();
-
 
7276
      if (this_present_e || that_present_e) {
-
 
7277
        if (!(this_present_e && that_present_e))
-
 
7278
          return false;
-
 
7279
        if (!this.e.equals(that.e))
-
 
7280
          return false;
-
 
7281
      }
-
 
7282
 
-
 
7283
      return true;
-
 
7284
    }
-
 
7285
 
-
 
7286
    @Override
-
 
7287
    public int hashCode() {
-
 
7288
      return 0;
-
 
7289
    }
-
 
7290
 
-
 
7291
    public int compareTo(getPurchasesForPO_result other) {
-
 
7292
      if (!getClass().equals(other.getClass())) {
-
 
7293
        return getClass().getName().compareTo(other.getClass().getName());
-
 
7294
      }
-
 
7295
 
-
 
7296
      int lastComparison = 0;
-
 
7297
      getPurchasesForPO_result typedOther = (getPurchasesForPO_result)other;
-
 
7298
 
-
 
7299
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
-
 
7300
      if (lastComparison != 0) {
-
 
7301
        return lastComparison;
-
 
7302
      }
-
 
7303
      if (isSetSuccess()) {
-
 
7304
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
-
 
7305
        if (lastComparison != 0) {
-
 
7306
          return lastComparison;
-
 
7307
        }
-
 
7308
      }
-
 
7309
      lastComparison = Boolean.valueOf(isSetE()).compareTo(typedOther.isSetE());
-
 
7310
      if (lastComparison != 0) {
-
 
7311
        return lastComparison;
-
 
7312
      }
-
 
7313
      if (isSetE()) {
-
 
7314
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.e, typedOther.e);
-
 
7315
        if (lastComparison != 0) {
-
 
7316
          return lastComparison;
-
 
7317
        }
-
 
7318
      }
-
 
7319
      return 0;
-
 
7320
    }
-
 
7321
 
-
 
7322
    public _Fields fieldForId(int fieldId) {
-
 
7323
      return _Fields.findByThriftId(fieldId);
-
 
7324
    }
-
 
7325
 
-
 
7326
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
7327
      org.apache.thrift.protocol.TField field;
-
 
7328
      iprot.readStructBegin();
-
 
7329
      while (true)
-
 
7330
      {
-
 
7331
        field = iprot.readFieldBegin();
-
 
7332
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
7333
          break;
-
 
7334
        }
-
 
7335
        switch (field.id) {
-
 
7336
          case 0: // SUCCESS
-
 
7337
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
-
 
7338
              {
-
 
7339
                org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
-
 
7340
                this.success = new ArrayList<Purchase>(_list12.size);
-
 
7341
                for (int _i13 = 0; _i13 < _list12.size; ++_i13)
-
 
7342
                {
-
 
7343
                  Purchase _elem14; // required
-
 
7344
                  _elem14 = new Purchase();
-
 
7345
                  _elem14.read(iprot);
-
 
7346
                  this.success.add(_elem14);
-
 
7347
                }
-
 
7348
                iprot.readListEnd();
-
 
7349
              }
-
 
7350
            } else { 
-
 
7351
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
7352
            }
-
 
7353
            break;
-
 
7354
          case 1: // E
-
 
7355
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
7356
              this.e = new PurchaseServiceException();
-
 
7357
              this.e.read(iprot);
-
 
7358
            } else { 
-
 
7359
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
7360
            }
-
 
7361
            break;
-
 
7362
          default:
-
 
7363
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
7364
        }
-
 
7365
        iprot.readFieldEnd();
-
 
7366
      }
-
 
7367
      iprot.readStructEnd();
-
 
7368
      validate();
-
 
7369
    }
-
 
7370
 
-
 
7371
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
7372
      oprot.writeStructBegin(STRUCT_DESC);
-
 
7373
 
-
 
7374
      if (this.isSetSuccess()) {
-
 
7375
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
-
 
7376
        {
-
 
7377
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
-
 
7378
          for (Purchase _iter15 : this.success)
-
 
7379
          {
-
 
7380
            _iter15.write(oprot);
-
 
7381
          }
-
 
7382
          oprot.writeListEnd();
-
 
7383
        }
-
 
7384
        oprot.writeFieldEnd();
-
 
7385
      } else if (this.isSetE()) {
-
 
7386
        oprot.writeFieldBegin(E_FIELD_DESC);
-
 
7387
        this.e.write(oprot);
-
 
7388
        oprot.writeFieldEnd();
-
 
7389
      }
-
 
7390
      oprot.writeFieldStop();
-
 
7391
      oprot.writeStructEnd();
-
 
7392
    }
-
 
7393
 
-
 
7394
    @Override
-
 
7395
    public String toString() {
-
 
7396
      StringBuilder sb = new StringBuilder("getPurchasesForPO_result(");
-
 
7397
      boolean first = true;
-
 
7398
 
-
 
7399
      sb.append("success:");
-
 
7400
      if (this.success == null) {
-
 
7401
        sb.append("null");
-
 
7402
      } else {
-
 
7403
        sb.append(this.success);
-
 
7404
      }
-
 
7405
      first = false;
-
 
7406
      if (!first) sb.append(", ");
-
 
7407
      sb.append("e:");
-
 
7408
      if (this.e == null) {
-
 
7409
        sb.append("null");
-
 
7410
      } else {
-
 
7411
        sb.append(this.e);
-
 
7412
      }
-
 
7413
      first = false;
-
 
7414
      sb.append(")");
-
 
7415
      return sb.toString();
-
 
7416
    }
-
 
7417
 
-
 
7418
    public void validate() throws org.apache.thrift.TException {
-
 
7419
      // check for required fields
-
 
7420
    }
-
 
7421
 
-
 
7422
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
7423
      try {
-
 
7424
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
7425
      } catch (org.apache.thrift.TException te) {
-
 
7426
        throw new java.io.IOException(te);
-
 
7427
      }
-
 
7428
    }
-
 
7429
 
-
 
7430
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
7431
      try {
-
 
7432
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
7433
      } catch (org.apache.thrift.TException te) {
-
 
7434
        throw new java.io.IOException(te);
-
 
7435
      }
-
 
7436
    }
-
 
7437
 
-
 
7438
  }
-
 
7439
 
6639
  public static class getPurchaseOrderForPurchase_args implements org.apache.thrift.TBase<getPurchaseOrderForPurchase_args, getPurchaseOrderForPurchase_args._Fields>, java.io.Serializable, Cloneable   {
7440
  public static class getPurchaseOrderForPurchase_args implements org.apache.thrift.TBase<getPurchaseOrderForPurchase_args, getPurchaseOrderForPurchase_args._Fields>, java.io.Serializable, Cloneable   {
6640
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPurchaseOrderForPurchase_args");
7441
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPurchaseOrderForPurchase_args");
6641
 
7442
 
6642
    private static final org.apache.thrift.protocol.TField PURCHASE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("purchaseId", org.apache.thrift.protocol.TType.I64, (short)1);
7443
    private static final org.apache.thrift.protocol.TField PURCHASE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("purchaseId", org.apache.thrift.protocol.TType.I64, (short)1);
6643
 
7444
 
Line 7834... Line 8635...
7834
        }
8635
        }
7835
        switch (field.id) {
8636
        switch (field.id) {
7836
          case 0: // SUCCESS
8637
          case 0: // SUCCESS
7837
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
8638
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
7838
              {
8639
              {
7839
                org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
8640
                org.apache.thrift.protocol.TList _list16 = iprot.readListBegin();
7840
                this.success = new ArrayList<PurchaseOrder>(_list12.size);
8641
                this.success = new ArrayList<PurchaseOrder>(_list16.size);
7841
                for (int _i13 = 0; _i13 < _list12.size; ++_i13)
8642
                for (int _i17 = 0; _i17 < _list16.size; ++_i17)
7842
                {
8643
                {
7843
                  PurchaseOrder _elem14; // required
8644
                  PurchaseOrder _elem18; // required
7844
                  _elem14 = new PurchaseOrder();
8645
                  _elem18 = new PurchaseOrder();
7845
                  _elem14.read(iprot);
8646
                  _elem18.read(iprot);
7846
                  this.success.add(_elem14);
8647
                  this.success.add(_elem18);
7847
                }
8648
                }
7848
                iprot.readListEnd();
8649
                iprot.readListEnd();
7849
              }
8650
              }
7850
            } else { 
8651
            } else { 
7851
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8652
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
Line 7873... Line 8674...
7873
 
8674
 
7874
      if (this.isSetSuccess()) {
8675
      if (this.isSetSuccess()) {
7875
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8676
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7876
        {
8677
        {
7877
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
8678
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
7878
          for (PurchaseOrder _iter15 : this.success)
8679
          for (PurchaseOrder _iter19 : this.success)
7879
          {
8680
          {
7880
            _iter15.write(oprot);
8681
            _iter19.write(oprot);
7881
          }
8682
          }
7882
          oprot.writeListEnd();
8683
          oprot.writeListEnd();
7883
        }
8684
        }
7884
        oprot.writeFieldEnd();
8685
        oprot.writeFieldEnd();
7885
      } else if (this.isSetE()) {
8686
      } else if (this.isSetE()) {
Line 8453... Line 9254...
8453
        }
9254
        }
8454
        switch (field.id) {
9255
        switch (field.id) {
8455
          case 0: // SUCCESS
9256
          case 0: // SUCCESS
8456
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9257
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
8457
              {
9258
              {
8458
                org.apache.thrift.protocol.TList _list16 = iprot.readListBegin();
9259
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
8459
                this.success = new ArrayList<Supplier>(_list16.size);
9260
                this.success = new ArrayList<Supplier>(_list20.size);
8460
                for (int _i17 = 0; _i17 < _list16.size; ++_i17)
9261
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
8461
                {
9262
                {
8462
                  Supplier _elem18; // required
9263
                  Supplier _elem22; // required
8463
                  _elem18 = new Supplier();
9264
                  _elem22 = new Supplier();
8464
                  _elem18.read(iprot);
9265
                  _elem22.read(iprot);
8465
                  this.success.add(_elem18);
9266
                  this.success.add(_elem22);
8466
                }
9267
                }
8467
                iprot.readListEnd();
9268
                iprot.readListEnd();
8468
              }
9269
              }
8469
            } else { 
9270
            } else { 
8470
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9271
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
Line 8492... Line 9293...
8492
 
9293
 
8493
      if (this.isSetSuccess()) {
9294
      if (this.isSetSuccess()) {
8494
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9295
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8495
        {
9296
        {
8496
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
9297
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
8497
          for (Supplier _iter19 : this.success)
9298
          for (Supplier _iter23 : this.success)
8498
          {
9299
          {
8499
            _iter19.write(oprot);
9300
            _iter23.write(oprot);
8500
          }
9301
          }
8501
          oprot.writeListEnd();
9302
          oprot.writeListEnd();
8502
        }
9303
        }
8503
        oprot.writeFieldEnd();
9304
        oprot.writeFieldEnd();
8504
      } else if (this.isSetE()) {
9305
      } else if (this.isSetE()) {
Line 11195... Line 11996...
11195
        }
11996
        }
11196
        switch (field.id) {
11997
        switch (field.id) {
11197
          case 0: // SUCCESS
11998
          case 0: // SUCCESS
11198
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11999
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11199
              {
12000
              {
11200
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
12001
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
11201
                this.success = new ArrayList<Invoice>(_list20.size);
12002
                this.success = new ArrayList<Invoice>(_list24.size);
11202
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
12003
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
11203
                {
12004
                {
11204
                  Invoice _elem22; // required
12005
                  Invoice _elem26; // required
11205
                  _elem22 = new Invoice();
12006
                  _elem26 = new Invoice();
11206
                  _elem22.read(iprot);
12007
                  _elem26.read(iprot);
11207
                  this.success.add(_elem22);
12008
                  this.success.add(_elem26);
11208
                }
12009
                }
11209
                iprot.readListEnd();
12010
                iprot.readListEnd();
11210
              }
12011
              }
11211
            } else { 
12012
            } else { 
11212
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12013
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
Line 11226... Line 12027...
11226
 
12027
 
11227
      if (this.isSetSuccess()) {
12028
      if (this.isSetSuccess()) {
11228
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12029
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11229
        {
12030
        {
11230
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
12031
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
11231
          for (Invoice _iter23 : this.success)
12032
          for (Invoice _iter27 : this.success)
11232
          {
12033
          {
11233
            _iter23.write(oprot);
12034
            _iter27.write(oprot);
11234
          }
12035
          }
11235
          oprot.writeListEnd();
12036
          oprot.writeListEnd();
11236
        }
12037
        }
11237
        oprot.writeFieldEnd();
12038
        oprot.writeFieldEnd();
11238
      }
12039
      }