Subversion Repositories SmartDukaan

Rev

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

Rev 9829 Rev 9925
Line 228... Line 228...
228
     * @param id
228
     * @param id
229
     * @param warehouseId
229
     * @param warehouseId
230
     */
230
     */
231
    public void changeWarehouseForPO(long id, long warehouseId) throws PurchaseServiceException, org.apache.thrift.TException;
231
    public void changeWarehouseForPO(long id, long warehouseId) throws PurchaseServiceException, org.apache.thrift.TException;
232
 
232
 
-
 
233
    /**
-
 
234
     * Change status of PO
-
 
235
     * 
-
 
236
     * @param id
-
 
237
     * @param poStatus
-
 
238
     */
-
 
239
    public void changePOStatus(long id, POStatus poStatus) throws PurchaseServiceException, org.apache.thrift.TException;
-
 
240
 
233
  }
241
  }
234
 
242
 
235
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
243
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
236
 
244
 
237
    public void createPurchaseOrder(PurchaseOrder purchaseOrder, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPurchaseOrder_call> resultHandler) throws org.apache.thrift.TException;
245
    public void createPurchaseOrder(PurchaseOrder purchaseOrder, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createPurchaseOrder_call> resultHandler) throws org.apache.thrift.TException;
Line 288... Line 296...
288
 
296
 
289
    public void isInvoiceReceived(String invoiceNumber, long supplierId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.isInvoiceReceived_call> resultHandler) throws org.apache.thrift.TException;
297
    public void isInvoiceReceived(String invoiceNumber, long supplierId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.isInvoiceReceived_call> resultHandler) throws org.apache.thrift.TException;
290
 
298
 
291
    public void changeWarehouseForPO(long id, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.changeWarehouseForPO_call> resultHandler) throws org.apache.thrift.TException;
299
    public void changeWarehouseForPO(long id, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.changeWarehouseForPO_call> resultHandler) throws org.apache.thrift.TException;
292
 
300
 
-
 
301
    public void changePOStatus(long id, POStatus poStatus, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.changePOStatus_call> resultHandler) throws org.apache.thrift.TException;
-
 
302
 
293
  }
303
  }
294
 
304
 
295
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
305
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
296
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
306
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
297
      public Factory() {}
307
      public Factory() {}
Line 989... Line 999...
989
        throw result.e;
999
        throw result.e;
990
      }
1000
      }
991
      return;
1001
      return;
992
    }
1002
    }
993
 
1003
 
-
 
1004
    public void changePOStatus(long id, POStatus poStatus) throws PurchaseServiceException, org.apache.thrift.TException
-
 
1005
    {
-
 
1006
      send_changePOStatus(id, poStatus);
-
 
1007
      recv_changePOStatus();
-
 
1008
    }
-
 
1009
 
-
 
1010
    public void send_changePOStatus(long id, POStatus poStatus) throws org.apache.thrift.TException
-
 
1011
    {
-
 
1012
      changePOStatus_args args = new changePOStatus_args();
-
 
1013
      args.setId(id);
-
 
1014
      args.setPoStatus(poStatus);
-
 
1015
      sendBase("changePOStatus", args);
-
 
1016
    }
-
 
1017
 
-
 
1018
    public void recv_changePOStatus() throws PurchaseServiceException, org.apache.thrift.TException
-
 
1019
    {
-
 
1020
      changePOStatus_result result = new changePOStatus_result();
-
 
1021
      receiveBase(result, "changePOStatus");
-
 
1022
      if (result.e != null) {
-
 
1023
        throw result.e;
-
 
1024
      }
-
 
1025
      return;
-
 
1026
    }
-
 
1027
 
994
  }
1028
  }
995
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1029
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
996
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1030
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
997
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1031
      private org.apache.thrift.async.TAsyncClientManager clientManager;
998
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
1032
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
Line 1945... Line 1979...
1945
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1979
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1946
        (new Client(prot)).recv_changeWarehouseForPO();
1980
        (new Client(prot)).recv_changeWarehouseForPO();
1947
      }
1981
      }
1948
    }
1982
    }
1949
 
1983
 
-
 
1984
    public void changePOStatus(long id, POStatus poStatus, org.apache.thrift.async.AsyncMethodCallback<changePOStatus_call> resultHandler) throws org.apache.thrift.TException {
-
 
1985
      checkReady();
-
 
1986
      changePOStatus_call method_call = new changePOStatus_call(id, poStatus, resultHandler, this, ___protocolFactory, ___transport);
-
 
1987
      this.___currentMethod = method_call;
-
 
1988
      ___manager.call(method_call);
-
 
1989
    }
-
 
1990
 
-
 
1991
    public static class changePOStatus_call extends org.apache.thrift.async.TAsyncMethodCall {
-
 
1992
      private long id;
-
 
1993
      private POStatus poStatus;
-
 
1994
      public changePOStatus_call(long id, POStatus poStatus, org.apache.thrift.async.AsyncMethodCallback<changePOStatus_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 {
-
 
1995
        super(client, protocolFactory, transport, resultHandler, false);
-
 
1996
        this.id = id;
-
 
1997
        this.poStatus = poStatus;
-
 
1998
      }
-
 
1999
 
-
 
2000
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-
 
2001
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("changePOStatus", org.apache.thrift.protocol.TMessageType.CALL, 0));
-
 
2002
        changePOStatus_args args = new changePOStatus_args();
-
 
2003
        args.setId(id);
-
 
2004
        args.setPoStatus(poStatus);
-
 
2005
        args.write(prot);
-
 
2006
        prot.writeMessageEnd();
-
 
2007
      }
-
 
2008
 
-
 
2009
      public void getResult() throws PurchaseServiceException, org.apache.thrift.TException {
-
 
2010
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-
 
2011
          throw new IllegalStateException("Method call not finished!");
-
 
2012
        }
-
 
2013
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-
 
2014
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-
 
2015
        (new Client(prot)).recv_changePOStatus();
-
 
2016
      }
-
 
2017
    }
-
 
2018
 
1950
  }
2019
  }
1951
 
2020
 
1952
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
2021
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
1953
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
2022
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
1954
    public Processor(I iface) {
2023
    public Processor(I iface) {
Line 1986... Line 2055...
1986
      processMap.put("createPurchaseForOurExtBilling", new createPurchaseForOurExtBilling());
2055
      processMap.put("createPurchaseForOurExtBilling", new createPurchaseForOurExtBilling());
1987
      processMap.put("fulfillPOForExtBilling", new fulfillPOForExtBilling());
2056
      processMap.put("fulfillPOForExtBilling", new fulfillPOForExtBilling());
1988
      processMap.put("closePO", new closePO());
2057
      processMap.put("closePO", new closePO());
1989
      processMap.put("isInvoiceReceived", new isInvoiceReceived());
2058
      processMap.put("isInvoiceReceived", new isInvoiceReceived());
1990
      processMap.put("changeWarehouseForPO", new changeWarehouseForPO());
2059
      processMap.put("changeWarehouseForPO", new changeWarehouseForPO());
-
 
2060
      processMap.put("changePOStatus", new changePOStatus());
1991
      return processMap;
2061
      return processMap;
1992
    }
2062
    }
1993
 
2063
 
1994
    private static class createPurchaseOrder<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createPurchaseOrder_args> {
2064
    private static class createPurchaseOrder<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createPurchaseOrder_args> {
1995
      public createPurchaseOrder() {
2065
      public createPurchaseOrder() {
Line 2507... Line 2577...
2507
        }
2577
        }
2508
        return result;
2578
        return result;
2509
      }
2579
      }
2510
    }
2580
    }
2511
 
2581
 
-
 
2582
    private static class changePOStatus<I extends Iface> extends org.apache.thrift.ProcessFunction<I, changePOStatus_args> {
-
 
2583
      public changePOStatus() {
-
 
2584
        super("changePOStatus");
-
 
2585
      }
-
 
2586
 
-
 
2587
      protected changePOStatus_args getEmptyArgsInstance() {
-
 
2588
        return new changePOStatus_args();
-
 
2589
      }
-
 
2590
 
-
 
2591
      protected changePOStatus_result getResult(I iface, changePOStatus_args args) throws org.apache.thrift.TException {
-
 
2592
        changePOStatus_result result = new changePOStatus_result();
-
 
2593
        try {
-
 
2594
          iface.changePOStatus(args.id, args.poStatus);
-
 
2595
        } catch (PurchaseServiceException e) {
-
 
2596
          result.e = e;
-
 
2597
        }
-
 
2598
        return result;
-
 
2599
      }
-
 
2600
    }
-
 
2601
 
2512
  }
2602
  }
2513
 
2603
 
2514
  public static class createPurchaseOrder_args implements org.apache.thrift.TBase<createPurchaseOrder_args, createPurchaseOrder_args._Fields>, java.io.Serializable, Cloneable   {
2604
  public static class createPurchaseOrder_args implements org.apache.thrift.TBase<createPurchaseOrder_args, createPurchaseOrder_args._Fields>, java.io.Serializable, Cloneable   {
2515
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPurchaseOrder_args");
2605
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createPurchaseOrder_args");
2516
 
2606
 
Line 21027... Line 21117...
21027
      boolean first = true;
21117
      boolean first = true;
21028
 
21118
 
21029
      sb.append("e:");
21119
      sb.append("e:");
21030
      if (this.e == null) {
21120
      if (this.e == null) {
21031
        sb.append("null");
21121
        sb.append("null");
-
 
21122
      } else {
-
 
21123
        sb.append(this.e);
-
 
21124
      }
-
 
21125
      first = false;
-
 
21126
      sb.append(")");
-
 
21127
      return sb.toString();
-
 
21128
    }
-
 
21129
 
-
 
21130
    public void validate() throws org.apache.thrift.TException {
-
 
21131
      // check for required fields
-
 
21132
    }
-
 
21133
 
-
 
21134
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
21135
      try {
-
 
21136
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
21137
      } catch (org.apache.thrift.TException te) {
-
 
21138
        throw new java.io.IOException(te);
-
 
21139
      }
-
 
21140
    }
-
 
21141
 
-
 
21142
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
21143
      try {
-
 
21144
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
21145
      } catch (org.apache.thrift.TException te) {
-
 
21146
        throw new java.io.IOException(te);
-
 
21147
      }
-
 
21148
    }
-
 
21149
 
-
 
21150
  }
-
 
21151
 
-
 
21152
  public static class changePOStatus_args implements org.apache.thrift.TBase<changePOStatus_args, changePOStatus_args._Fields>, java.io.Serializable, Cloneable   {
-
 
21153
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("changePOStatus_args");
-
 
21154
 
-
 
21155
    private static final org.apache.thrift.protocol.TField ID_FIELD_DESC = new org.apache.thrift.protocol.TField("id", org.apache.thrift.protocol.TType.I64, (short)1);
-
 
21156
    private static final org.apache.thrift.protocol.TField PO_STATUS_FIELD_DESC = new org.apache.thrift.protocol.TField("poStatus", org.apache.thrift.protocol.TType.I32, (short)2);
-
 
21157
 
-
 
21158
    private long id; // required
-
 
21159
    private POStatus poStatus; // required
-
 
21160
 
-
 
21161
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
21162
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
21163
      ID((short)1, "id"),
-
 
21164
      /**
-
 
21165
       * 
-
 
21166
       * @see POStatus
-
 
21167
       */
-
 
21168
      PO_STATUS((short)2, "poStatus");
-
 
21169
 
-
 
21170
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
21171
 
-
 
21172
      static {
-
 
21173
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
21174
          byName.put(field.getFieldName(), field);
-
 
21175
        }
-
 
21176
      }
-
 
21177
 
-
 
21178
      /**
-
 
21179
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
21180
       */
-
 
21181
      public static _Fields findByThriftId(int fieldId) {
-
 
21182
        switch(fieldId) {
-
 
21183
          case 1: // ID
-
 
21184
            return ID;
-
 
21185
          case 2: // PO_STATUS
-
 
21186
            return PO_STATUS;
-
 
21187
          default:
-
 
21188
            return null;
-
 
21189
        }
-
 
21190
      }
-
 
21191
 
-
 
21192
      /**
-
 
21193
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
21194
       * if it is not found.
-
 
21195
       */
-
 
21196
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
21197
        _Fields fields = findByThriftId(fieldId);
-
 
21198
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
21199
        return fields;
-
 
21200
      }
-
 
21201
 
-
 
21202
      /**
-
 
21203
       * Find the _Fields constant that matches name, or null if its not found.
-
 
21204
       */
-
 
21205
      public static _Fields findByName(String name) {
-
 
21206
        return byName.get(name);
-
 
21207
      }
-
 
21208
 
-
 
21209
      private final short _thriftId;
-
 
21210
      private final String _fieldName;
-
 
21211
 
-
 
21212
      _Fields(short thriftId, String fieldName) {
-
 
21213
        _thriftId = thriftId;
-
 
21214
        _fieldName = fieldName;
-
 
21215
      }
-
 
21216
 
-
 
21217
      public short getThriftFieldId() {
-
 
21218
        return _thriftId;
-
 
21219
      }
-
 
21220
 
-
 
21221
      public String getFieldName() {
-
 
21222
        return _fieldName;
-
 
21223
      }
-
 
21224
    }
-
 
21225
 
-
 
21226
    // isset id assignments
-
 
21227
    private static final int __ID_ISSET_ID = 0;
-
 
21228
    private BitSet __isset_bit_vector = new BitSet(1);
-
 
21229
 
-
 
21230
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
21231
    static {
-
 
21232
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
21233
      tmpMap.put(_Fields.ID, new org.apache.thrift.meta_data.FieldMetaData("id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
21234
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
21235
      tmpMap.put(_Fields.PO_STATUS, new org.apache.thrift.meta_data.FieldMetaData("poStatus", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
21236
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, POStatus.class)));
-
 
21237
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
21238
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(changePOStatus_args.class, metaDataMap);
-
 
21239
    }
-
 
21240
 
-
 
21241
    public changePOStatus_args() {
-
 
21242
    }
-
 
21243
 
-
 
21244
    public changePOStatus_args(
-
 
21245
      long id,
-
 
21246
      POStatus poStatus)
-
 
21247
    {
-
 
21248
      this();
-
 
21249
      this.id = id;
-
 
21250
      setIdIsSet(true);
-
 
21251
      this.poStatus = poStatus;
-
 
21252
    }
-
 
21253
 
-
 
21254
    /**
-
 
21255
     * Performs a deep copy on <i>other</i>.
-
 
21256
     */
-
 
21257
    public changePOStatus_args(changePOStatus_args other) {
-
 
21258
      __isset_bit_vector.clear();
-
 
21259
      __isset_bit_vector.or(other.__isset_bit_vector);
-
 
21260
      this.id = other.id;
-
 
21261
      if (other.isSetPoStatus()) {
-
 
21262
        this.poStatus = other.poStatus;
-
 
21263
      }
-
 
21264
    }
-
 
21265
 
-
 
21266
    public changePOStatus_args deepCopy() {
-
 
21267
      return new changePOStatus_args(this);
-
 
21268
    }
-
 
21269
 
-
 
21270
    @Override
-
 
21271
    public void clear() {
-
 
21272
      setIdIsSet(false);
-
 
21273
      this.id = 0;
-
 
21274
      this.poStatus = null;
-
 
21275
    }
-
 
21276
 
-
 
21277
    public long getId() {
-
 
21278
      return this.id;
-
 
21279
    }
-
 
21280
 
-
 
21281
    public void setId(long id) {
-
 
21282
      this.id = id;
-
 
21283
      setIdIsSet(true);
-
 
21284
    }
-
 
21285
 
-
 
21286
    public void unsetId() {
-
 
21287
      __isset_bit_vector.clear(__ID_ISSET_ID);
-
 
21288
    }
-
 
21289
 
-
 
21290
    /** Returns true if field id is set (has been assigned a value) and false otherwise */
-
 
21291
    public boolean isSetId() {
-
 
21292
      return __isset_bit_vector.get(__ID_ISSET_ID);
-
 
21293
    }
-
 
21294
 
-
 
21295
    public void setIdIsSet(boolean value) {
-
 
21296
      __isset_bit_vector.set(__ID_ISSET_ID, value);
-
 
21297
    }
-
 
21298
 
-
 
21299
    /**
-
 
21300
     * 
-
 
21301
     * @see POStatus
-
 
21302
     */
-
 
21303
    public POStatus getPoStatus() {
-
 
21304
      return this.poStatus;
-
 
21305
    }
-
 
21306
 
-
 
21307
    /**
-
 
21308
     * 
-
 
21309
     * @see POStatus
-
 
21310
     */
-
 
21311
    public void setPoStatus(POStatus poStatus) {
-
 
21312
      this.poStatus = poStatus;
-
 
21313
    }
-
 
21314
 
-
 
21315
    public void unsetPoStatus() {
-
 
21316
      this.poStatus = null;
-
 
21317
    }
-
 
21318
 
-
 
21319
    /** Returns true if field poStatus is set (has been assigned a value) and false otherwise */
-
 
21320
    public boolean isSetPoStatus() {
-
 
21321
      return this.poStatus != null;
-
 
21322
    }
-
 
21323
 
-
 
21324
    public void setPoStatusIsSet(boolean value) {
-
 
21325
      if (!value) {
-
 
21326
        this.poStatus = null;
-
 
21327
      }
-
 
21328
    }
-
 
21329
 
-
 
21330
    public void setFieldValue(_Fields field, Object value) {
-
 
21331
      switch (field) {
-
 
21332
      case ID:
-
 
21333
        if (value == null) {
-
 
21334
          unsetId();
-
 
21335
        } else {
-
 
21336
          setId((Long)value);
-
 
21337
        }
-
 
21338
        break;
-
 
21339
 
-
 
21340
      case PO_STATUS:
-
 
21341
        if (value == null) {
-
 
21342
          unsetPoStatus();
-
 
21343
        } else {
-
 
21344
          setPoStatus((POStatus)value);
-
 
21345
        }
-
 
21346
        break;
-
 
21347
 
-
 
21348
      }
-
 
21349
    }
-
 
21350
 
-
 
21351
    public Object getFieldValue(_Fields field) {
-
 
21352
      switch (field) {
-
 
21353
      case ID:
-
 
21354
        return Long.valueOf(getId());
-
 
21355
 
-
 
21356
      case PO_STATUS:
-
 
21357
        return getPoStatus();
-
 
21358
 
-
 
21359
      }
-
 
21360
      throw new IllegalStateException();
-
 
21361
    }
-
 
21362
 
-
 
21363
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
21364
    public boolean isSet(_Fields field) {
-
 
21365
      if (field == null) {
-
 
21366
        throw new IllegalArgumentException();
-
 
21367
      }
-
 
21368
 
-
 
21369
      switch (field) {
-
 
21370
      case ID:
-
 
21371
        return isSetId();
-
 
21372
      case PO_STATUS:
-
 
21373
        return isSetPoStatus();
-
 
21374
      }
-
 
21375
      throw new IllegalStateException();
-
 
21376
    }
-
 
21377
 
-
 
21378
    @Override
-
 
21379
    public boolean equals(Object that) {
-
 
21380
      if (that == null)
-
 
21381
        return false;
-
 
21382
      if (that instanceof changePOStatus_args)
-
 
21383
        return this.equals((changePOStatus_args)that);
-
 
21384
      return false;
-
 
21385
    }
-
 
21386
 
-
 
21387
    public boolean equals(changePOStatus_args that) {
-
 
21388
      if (that == null)
-
 
21389
        return false;
-
 
21390
 
-
 
21391
      boolean this_present_id = true;
-
 
21392
      boolean that_present_id = true;
-
 
21393
      if (this_present_id || that_present_id) {
-
 
21394
        if (!(this_present_id && that_present_id))
-
 
21395
          return false;
-
 
21396
        if (this.id != that.id)
-
 
21397
          return false;
-
 
21398
      }
-
 
21399
 
-
 
21400
      boolean this_present_poStatus = true && this.isSetPoStatus();
-
 
21401
      boolean that_present_poStatus = true && that.isSetPoStatus();
-
 
21402
      if (this_present_poStatus || that_present_poStatus) {
-
 
21403
        if (!(this_present_poStatus && that_present_poStatus))
-
 
21404
          return false;
-
 
21405
        if (!this.poStatus.equals(that.poStatus))
-
 
21406
          return false;
-
 
21407
      }
-
 
21408
 
-
 
21409
      return true;
-
 
21410
    }
-
 
21411
 
-
 
21412
    @Override
-
 
21413
    public int hashCode() {
-
 
21414
      return 0;
-
 
21415
    }
-
 
21416
 
-
 
21417
    public int compareTo(changePOStatus_args other) {
-
 
21418
      if (!getClass().equals(other.getClass())) {
-
 
21419
        return getClass().getName().compareTo(other.getClass().getName());
-
 
21420
      }
-
 
21421
 
-
 
21422
      int lastComparison = 0;
-
 
21423
      changePOStatus_args typedOther = (changePOStatus_args)other;
-
 
21424
 
-
 
21425
      lastComparison = Boolean.valueOf(isSetId()).compareTo(typedOther.isSetId());
-
 
21426
      if (lastComparison != 0) {
-
 
21427
        return lastComparison;
-
 
21428
      }
-
 
21429
      if (isSetId()) {
-
 
21430
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.id, typedOther.id);
-
 
21431
        if (lastComparison != 0) {
-
 
21432
          return lastComparison;
-
 
21433
        }
-
 
21434
      }
-
 
21435
      lastComparison = Boolean.valueOf(isSetPoStatus()).compareTo(typedOther.isSetPoStatus());
-
 
21436
      if (lastComparison != 0) {
-
 
21437
        return lastComparison;
-
 
21438
      }
-
 
21439
      if (isSetPoStatus()) {
-
 
21440
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.poStatus, typedOther.poStatus);
-
 
21441
        if (lastComparison != 0) {
-
 
21442
          return lastComparison;
-
 
21443
        }
-
 
21444
      }
-
 
21445
      return 0;
-
 
21446
    }
-
 
21447
 
-
 
21448
    public _Fields fieldForId(int fieldId) {
-
 
21449
      return _Fields.findByThriftId(fieldId);
-
 
21450
    }
-
 
21451
 
-
 
21452
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
21453
      org.apache.thrift.protocol.TField field;
-
 
21454
      iprot.readStructBegin();
-
 
21455
      while (true)
-
 
21456
      {
-
 
21457
        field = iprot.readFieldBegin();
-
 
21458
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
21459
          break;
-
 
21460
        }
-
 
21461
        switch (field.id) {
-
 
21462
          case 1: // ID
-
 
21463
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
21464
              this.id = iprot.readI64();
-
 
21465
              setIdIsSet(true);
-
 
21466
            } else { 
-
 
21467
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
21468
            }
-
 
21469
            break;
-
 
21470
          case 2: // PO_STATUS
-
 
21471
            if (field.type == org.apache.thrift.protocol.TType.I32) {
-
 
21472
              this.poStatus = POStatus.findByValue(iprot.readI32());
-
 
21473
            } else { 
-
 
21474
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
21475
            }
-
 
21476
            break;
-
 
21477
          default:
-
 
21478
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
21479
        }
-
 
21480
        iprot.readFieldEnd();
-
 
21481
      }
-
 
21482
      iprot.readStructEnd();
-
 
21483
      validate();
-
 
21484
    }
-
 
21485
 
-
 
21486
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
21487
      validate();
-
 
21488
 
-
 
21489
      oprot.writeStructBegin(STRUCT_DESC);
-
 
21490
      oprot.writeFieldBegin(ID_FIELD_DESC);
-
 
21491
      oprot.writeI64(this.id);
-
 
21492
      oprot.writeFieldEnd();
-
 
21493
      if (this.poStatus != null) {
-
 
21494
        oprot.writeFieldBegin(PO_STATUS_FIELD_DESC);
-
 
21495
        oprot.writeI32(this.poStatus.getValue());
-
 
21496
        oprot.writeFieldEnd();
-
 
21497
      }
-
 
21498
      oprot.writeFieldStop();
-
 
21499
      oprot.writeStructEnd();
-
 
21500
    }
-
 
21501
 
-
 
21502
    @Override
-
 
21503
    public String toString() {
-
 
21504
      StringBuilder sb = new StringBuilder("changePOStatus_args(");
-
 
21505
      boolean first = true;
-
 
21506
 
-
 
21507
      sb.append("id:");
-
 
21508
      sb.append(this.id);
-
 
21509
      first = false;
-
 
21510
      if (!first) sb.append(", ");
-
 
21511
      sb.append("poStatus:");
-
 
21512
      if (this.poStatus == null) {
-
 
21513
        sb.append("null");
-
 
21514
      } else {
-
 
21515
        sb.append(this.poStatus);
-
 
21516
      }
-
 
21517
      first = false;
-
 
21518
      sb.append(")");
-
 
21519
      return sb.toString();
-
 
21520
    }
-
 
21521
 
-
 
21522
    public void validate() throws org.apache.thrift.TException {
-
 
21523
      // check for required fields
-
 
21524
    }
-
 
21525
 
-
 
21526
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
21527
      try {
-
 
21528
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
21529
      } catch (org.apache.thrift.TException te) {
-
 
21530
        throw new java.io.IOException(te);
-
 
21531
      }
-
 
21532
    }
-
 
21533
 
-
 
21534
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
21535
      try {
-
 
21536
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-
 
21537
        __isset_bit_vector = new BitSet(1);
-
 
21538
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
21539
      } catch (org.apache.thrift.TException te) {
-
 
21540
        throw new java.io.IOException(te);
-
 
21541
      }
-
 
21542
    }
-
 
21543
 
-
 
21544
  }
-
 
21545
 
-
 
21546
  public static class changePOStatus_result implements org.apache.thrift.TBase<changePOStatus_result, changePOStatus_result._Fields>, java.io.Serializable, Cloneable   {
-
 
21547
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("changePOStatus_result");
-
 
21548
 
-
 
21549
    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);
-
 
21550
 
-
 
21551
    private PurchaseServiceException e; // required
-
 
21552
 
-
 
21553
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
21554
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
21555
      E((short)1, "e");
-
 
21556
 
-
 
21557
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
21558
 
-
 
21559
      static {
-
 
21560
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
21561
          byName.put(field.getFieldName(), field);
-
 
21562
        }
-
 
21563
      }
-
 
21564
 
-
 
21565
      /**
-
 
21566
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
21567
       */
-
 
21568
      public static _Fields findByThriftId(int fieldId) {
-
 
21569
        switch(fieldId) {
-
 
21570
          case 1: // E
-
 
21571
            return E;
-
 
21572
          default:
-
 
21573
            return null;
-
 
21574
        }
-
 
21575
      }
-
 
21576
 
-
 
21577
      /**
-
 
21578
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
21579
       * if it is not found.
-
 
21580
       */
-
 
21581
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
21582
        _Fields fields = findByThriftId(fieldId);
-
 
21583
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
21584
        return fields;
-
 
21585
      }
-
 
21586
 
-
 
21587
      /**
-
 
21588
       * Find the _Fields constant that matches name, or null if its not found.
-
 
21589
       */
-
 
21590
      public static _Fields findByName(String name) {
-
 
21591
        return byName.get(name);
-
 
21592
      }
-
 
21593
 
-
 
21594
      private final short _thriftId;
-
 
21595
      private final String _fieldName;
-
 
21596
 
-
 
21597
      _Fields(short thriftId, String fieldName) {
-
 
21598
        _thriftId = thriftId;
-
 
21599
        _fieldName = fieldName;
-
 
21600
      }
-
 
21601
 
-
 
21602
      public short getThriftFieldId() {
-
 
21603
        return _thriftId;
-
 
21604
      }
-
 
21605
 
-
 
21606
      public String getFieldName() {
-
 
21607
        return _fieldName;
-
 
21608
      }
-
 
21609
    }
-
 
21610
 
-
 
21611
    // isset id assignments
-
 
21612
 
-
 
21613
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
21614
    static {
-
 
21615
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
21616
      tmpMap.put(_Fields.E, new org.apache.thrift.meta_data.FieldMetaData("e", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
21617
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
-
 
21618
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
21619
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(changePOStatus_result.class, metaDataMap);
-
 
21620
    }
-
 
21621
 
-
 
21622
    public changePOStatus_result() {
-
 
21623
    }
-
 
21624
 
-
 
21625
    public changePOStatus_result(
-
 
21626
      PurchaseServiceException e)
-
 
21627
    {
-
 
21628
      this();
-
 
21629
      this.e = e;
-
 
21630
    }
-
 
21631
 
-
 
21632
    /**
-
 
21633
     * Performs a deep copy on <i>other</i>.
-
 
21634
     */
-
 
21635
    public changePOStatus_result(changePOStatus_result other) {
-
 
21636
      if (other.isSetE()) {
-
 
21637
        this.e = new PurchaseServiceException(other.e);
-
 
21638
      }
-
 
21639
    }
-
 
21640
 
-
 
21641
    public changePOStatus_result deepCopy() {
-
 
21642
      return new changePOStatus_result(this);
-
 
21643
    }
-
 
21644
 
-
 
21645
    @Override
-
 
21646
    public void clear() {
-
 
21647
      this.e = null;
-
 
21648
    }
-
 
21649
 
-
 
21650
    public PurchaseServiceException getE() {
-
 
21651
      return this.e;
-
 
21652
    }
-
 
21653
 
-
 
21654
    public void setE(PurchaseServiceException e) {
-
 
21655
      this.e = e;
-
 
21656
    }
-
 
21657
 
-
 
21658
    public void unsetE() {
-
 
21659
      this.e = null;
-
 
21660
    }
-
 
21661
 
-
 
21662
    /** Returns true if field e is set (has been assigned a value) and false otherwise */
-
 
21663
    public boolean isSetE() {
-
 
21664
      return this.e != null;
-
 
21665
    }
-
 
21666
 
-
 
21667
    public void setEIsSet(boolean value) {
-
 
21668
      if (!value) {
-
 
21669
        this.e = null;
-
 
21670
      }
-
 
21671
    }
-
 
21672
 
-
 
21673
    public void setFieldValue(_Fields field, Object value) {
-
 
21674
      switch (field) {
-
 
21675
      case E:
-
 
21676
        if (value == null) {
-
 
21677
          unsetE();
-
 
21678
        } else {
-
 
21679
          setE((PurchaseServiceException)value);
-
 
21680
        }
-
 
21681
        break;
-
 
21682
 
-
 
21683
      }
-
 
21684
    }
-
 
21685
 
-
 
21686
    public Object getFieldValue(_Fields field) {
-
 
21687
      switch (field) {
-
 
21688
      case E:
-
 
21689
        return getE();
-
 
21690
 
-
 
21691
      }
-
 
21692
      throw new IllegalStateException();
-
 
21693
    }
-
 
21694
 
-
 
21695
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
21696
    public boolean isSet(_Fields field) {
-
 
21697
      if (field == null) {
-
 
21698
        throw new IllegalArgumentException();
-
 
21699
      }
-
 
21700
 
-
 
21701
      switch (field) {
-
 
21702
      case E:
-
 
21703
        return isSetE();
-
 
21704
      }
-
 
21705
      throw new IllegalStateException();
-
 
21706
    }
-
 
21707
 
-
 
21708
    @Override
-
 
21709
    public boolean equals(Object that) {
-
 
21710
      if (that == null)
-
 
21711
        return false;
-
 
21712
      if (that instanceof changePOStatus_result)
-
 
21713
        return this.equals((changePOStatus_result)that);
-
 
21714
      return false;
-
 
21715
    }
-
 
21716
 
-
 
21717
    public boolean equals(changePOStatus_result that) {
-
 
21718
      if (that == null)
-
 
21719
        return false;
-
 
21720
 
-
 
21721
      boolean this_present_e = true && this.isSetE();
-
 
21722
      boolean that_present_e = true && that.isSetE();
-
 
21723
      if (this_present_e || that_present_e) {
-
 
21724
        if (!(this_present_e && that_present_e))
-
 
21725
          return false;
-
 
21726
        if (!this.e.equals(that.e))
-
 
21727
          return false;
-
 
21728
      }
-
 
21729
 
-
 
21730
      return true;
-
 
21731
    }
-
 
21732
 
-
 
21733
    @Override
-
 
21734
    public int hashCode() {
-
 
21735
      return 0;
-
 
21736
    }
-
 
21737
 
-
 
21738
    public int compareTo(changePOStatus_result other) {
-
 
21739
      if (!getClass().equals(other.getClass())) {
-
 
21740
        return getClass().getName().compareTo(other.getClass().getName());
-
 
21741
      }
-
 
21742
 
-
 
21743
      int lastComparison = 0;
-
 
21744
      changePOStatus_result typedOther = (changePOStatus_result)other;
-
 
21745
 
-
 
21746
      lastComparison = Boolean.valueOf(isSetE()).compareTo(typedOther.isSetE());
-
 
21747
      if (lastComparison != 0) {
-
 
21748
        return lastComparison;
-
 
21749
      }
-
 
21750
      if (isSetE()) {
-
 
21751
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.e, typedOther.e);
-
 
21752
        if (lastComparison != 0) {
-
 
21753
          return lastComparison;
-
 
21754
        }
-
 
21755
      }
-
 
21756
      return 0;
-
 
21757
    }
-
 
21758
 
-
 
21759
    public _Fields fieldForId(int fieldId) {
-
 
21760
      return _Fields.findByThriftId(fieldId);
-
 
21761
    }
-
 
21762
 
-
 
21763
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
21764
      org.apache.thrift.protocol.TField field;
-
 
21765
      iprot.readStructBegin();
-
 
21766
      while (true)
-
 
21767
      {
-
 
21768
        field = iprot.readFieldBegin();
-
 
21769
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
21770
          break;
-
 
21771
        }
-
 
21772
        switch (field.id) {
-
 
21773
          case 1: // E
-
 
21774
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
-
 
21775
              this.e = new PurchaseServiceException();
-
 
21776
              this.e.read(iprot);
-
 
21777
            } else { 
-
 
21778
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
21779
            }
-
 
21780
            break;
-
 
21781
          default:
-
 
21782
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
21783
        }
-
 
21784
        iprot.readFieldEnd();
-
 
21785
      }
-
 
21786
      iprot.readStructEnd();
-
 
21787
      validate();
-
 
21788
    }
-
 
21789
 
-
 
21790
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
21791
      oprot.writeStructBegin(STRUCT_DESC);
-
 
21792
 
-
 
21793
      if (this.isSetE()) {
-
 
21794
        oprot.writeFieldBegin(E_FIELD_DESC);
-
 
21795
        this.e.write(oprot);
-
 
21796
        oprot.writeFieldEnd();
-
 
21797
      }
-
 
21798
      oprot.writeFieldStop();
-
 
21799
      oprot.writeStructEnd();
-
 
21800
    }
-
 
21801
 
-
 
21802
    @Override
-
 
21803
    public String toString() {
-
 
21804
      StringBuilder sb = new StringBuilder("changePOStatus_result(");
-
 
21805
      boolean first = true;
-
 
21806
 
-
 
21807
      sb.append("e:");
-
 
21808
      if (this.e == null) {
-
 
21809
        sb.append("null");
21032
      } else {
21810
      } else {
21033
        sb.append(this.e);
21811
        sb.append(this.e);
21034
      }
21812
      }
21035
      first = false;
21813
      first = false;
21036
      sb.append(")");
21814
      sb.append(")");