Subversion Repositories SmartDukaan

Rev

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

Rev 4555 Rev 4622
Line 134... Line 134...
134
     * @param itemNumber
134
     * @param itemNumber
135
     * @param itemId
135
     * @param itemId
136
     */
136
     */
137
    public void createItemNumberMapping(String itemNumber, long itemId) throws org.apache.thrift.TException;
137
    public void createItemNumberMapping(String itemNumber, long itemId) throws org.apache.thrift.TException;
138
 
138
 
-
 
139
    /**
-
 
140
     * Get itemNumber mappings for itemId
-
 
141
     * 
-
 
142
     * @param itemId
-
 
143
     */
-
 
144
    public List<String> getItemNumbers(long itemId) throws org.apache.thrift.TException;
-
 
145
 
139
  }
146
  }
140
 
147
 
141
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
148
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
142
 
149
 
143
    public void createSerializedInventoryItem(long itemId, String serialNumber, long purchaseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createSerializedInventoryItem_call> resultHandler) throws org.apache.thrift.TException;
150
    public void createSerializedInventoryItem(long itemId, String serialNumber, long purchaseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createSerializedInventoryItem_call> resultHandler) throws org.apache.thrift.TException;
Line 164... Line 171...
164
 
171
 
165
    public void scanForOrder(long inventoryItemId, ScanType type, long quantity, long orderId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanForOrder_call> resultHandler) throws org.apache.thrift.TException;
172
    public void scanForOrder(long inventoryItemId, ScanType type, long quantity, long orderId, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanForOrder_call> resultHandler) throws org.apache.thrift.TException;
166
 
173
 
167
    public void createItemNumberMapping(String itemNumber, long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createItemNumberMapping_call> resultHandler) throws org.apache.thrift.TException;
174
    public void createItemNumberMapping(String itemNumber, long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createItemNumberMapping_call> resultHandler) throws org.apache.thrift.TException;
168
 
175
 
-
 
176
    public void getItemNumbers(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemNumbers_call> resultHandler) throws org.apache.thrift.TException;
-
 
177
 
169
  }
178
  }
170
 
179
 
171
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
180
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
172
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
181
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
173
      public Factory() {}
182
      public Factory() {}
Line 518... Line 527...
518
      createItemNumberMapping_result result = new createItemNumberMapping_result();
527
      createItemNumberMapping_result result = new createItemNumberMapping_result();
519
      receiveBase(result, "createItemNumberMapping");
528
      receiveBase(result, "createItemNumberMapping");
520
      return;
529
      return;
521
    }
530
    }
522
 
531
 
-
 
532
    public List<String> getItemNumbers(long itemId) throws org.apache.thrift.TException
-
 
533
    {
-
 
534
      send_getItemNumbers(itemId);
-
 
535
      return recv_getItemNumbers();
-
 
536
    }
-
 
537
 
-
 
538
    public void send_getItemNumbers(long itemId) throws org.apache.thrift.TException
-
 
539
    {
-
 
540
      getItemNumbers_args args = new getItemNumbers_args();
-
 
541
      args.setItemId(itemId);
-
 
542
      sendBase("getItemNumbers", args);
-
 
543
    }
-
 
544
 
-
 
545
    public List<String> recv_getItemNumbers() throws org.apache.thrift.TException
-
 
546
    {
-
 
547
      getItemNumbers_result result = new getItemNumbers_result();
-
 
548
      receiveBase(result, "getItemNumbers");
-
 
549
      if (result.isSetSuccess()) {
-
 
550
        return result.success;
-
 
551
      }
-
 
552
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemNumbers failed: unknown result");
-
 
553
    }
-
 
554
 
523
  }
555
  }
524
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
556
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
525
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
557
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
526
      private org.apache.thrift.async.TAsyncClientManager clientManager;
558
      private org.apache.thrift.async.TAsyncClientManager clientManager;
527
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
559
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
Line 1015... Line 1047...
1015
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1047
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1016
        (new Client(prot)).recv_createItemNumberMapping();
1048
        (new Client(prot)).recv_createItemNumberMapping();
1017
      }
1049
      }
1018
    }
1050
    }
1019
 
1051
 
-
 
1052
    public void getItemNumbers(long itemId, org.apache.thrift.async.AsyncMethodCallback<getItemNumbers_call> resultHandler) throws org.apache.thrift.TException {
-
 
1053
      checkReady();
-
 
1054
      getItemNumbers_call method_call = new getItemNumbers_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
-
 
1055
      this.___currentMethod = method_call;
-
 
1056
      ___manager.call(method_call);
-
 
1057
    }
-
 
1058
 
-
 
1059
    public static class getItemNumbers_call extends org.apache.thrift.async.TAsyncMethodCall {
-
 
1060
      private long itemId;
-
 
1061
      public getItemNumbers_call(long itemId, org.apache.thrift.async.AsyncMethodCallback<getItemNumbers_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 {
-
 
1062
        super(client, protocolFactory, transport, resultHandler, false);
-
 
1063
        this.itemId = itemId;
-
 
1064
      }
-
 
1065
 
-
 
1066
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
-
 
1067
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemNumbers", org.apache.thrift.protocol.TMessageType.CALL, 0));
-
 
1068
        getItemNumbers_args args = new getItemNumbers_args();
-
 
1069
        args.setItemId(itemId);
-
 
1070
        args.write(prot);
-
 
1071
        prot.writeMessageEnd();
-
 
1072
      }
-
 
1073
 
-
 
1074
      public List<String> getResult() throws org.apache.thrift.TException {
-
 
1075
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
-
 
1076
          throw new IllegalStateException("Method call not finished!");
-
 
1077
        }
-
 
1078
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
-
 
1079
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
-
 
1080
        return (new Client(prot)).recv_getItemNumbers();
-
 
1081
      }
-
 
1082
    }
-
 
1083
 
1020
  }
1084
  }
1021
 
1085
 
1022
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
1086
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
1023
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
1087
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
1024
    public Processor(I iface) {
1088
    public Processor(I iface) {
Line 1041... Line 1105...
1041
      processMap.put("scanSerializedItem", new scanSerializedItem());
1105
      processMap.put("scanSerializedItem", new scanSerializedItem());
1042
      processMap.put("scan", new scan());
1106
      processMap.put("scan", new scan());
1043
      processMap.put("scanSerializedItemForOrder", new scanSerializedItemForOrder());
1107
      processMap.put("scanSerializedItemForOrder", new scanSerializedItemForOrder());
1044
      processMap.put("scanForOrder", new scanForOrder());
1108
      processMap.put("scanForOrder", new scanForOrder());
1045
      processMap.put("createItemNumberMapping", new createItemNumberMapping());
1109
      processMap.put("createItemNumberMapping", new createItemNumberMapping());
-
 
1110
      processMap.put("getItemNumbers", new getItemNumbers());
1046
      return processMap;
1111
      return processMap;
1047
    }
1112
    }
1048
 
1113
 
1049
    private static class createSerializedInventoryItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createSerializedInventoryItem_args> {
1114
    private static class createSerializedInventoryItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createSerializedInventoryItem_args> {
1050
      public createSerializedInventoryItem() {
1115
      public createSerializedInventoryItem() {
Line 1284... Line 1349...
1284
        iface.createItemNumberMapping(args.itemNumber, args.itemId);
1349
        iface.createItemNumberMapping(args.itemNumber, args.itemId);
1285
        return result;
1350
        return result;
1286
      }
1351
      }
1287
    }
1352
    }
1288
 
1353
 
-
 
1354
    private static class getItemNumbers<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemNumbers_args> {
-
 
1355
      public getItemNumbers() {
-
 
1356
        super("getItemNumbers");
-
 
1357
      }
-
 
1358
 
-
 
1359
      protected getItemNumbers_args getEmptyArgsInstance() {
-
 
1360
        return new getItemNumbers_args();
-
 
1361
      }
-
 
1362
 
-
 
1363
      protected getItemNumbers_result getResult(I iface, getItemNumbers_args args) throws org.apache.thrift.TException {
-
 
1364
        getItemNumbers_result result = new getItemNumbers_result();
-
 
1365
        result.success = iface.getItemNumbers(args.itemId);
-
 
1366
        return result;
-
 
1367
      }
-
 
1368
    }
-
 
1369
 
1289
  }
1370
  }
1290
 
1371
 
1291
  public static class createSerializedInventoryItem_args implements org.apache.thrift.TBase<createSerializedInventoryItem_args, createSerializedInventoryItem_args._Fields>, java.io.Serializable, Cloneable   {
1372
  public static class createSerializedInventoryItem_args implements org.apache.thrift.TBase<createSerializedInventoryItem_args, createSerializedInventoryItem_args._Fields>, java.io.Serializable, Cloneable   {
1292
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createSerializedInventoryItem_args");
1373
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createSerializedInventoryItem_args");
1293
 
1374
 
Line 11236... Line 11317...
11236
      sb.append(")");
11317
      sb.append(")");
11237
      return sb.toString();
11318
      return sb.toString();
11238
    }
11319
    }
11239
 
11320
 
11240
    public void validate() throws org.apache.thrift.TException {
11321
    public void validate() throws org.apache.thrift.TException {
-
 
11322
      // check for required fields
-
 
11323
    }
-
 
11324
 
-
 
11325
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
11326
      try {
-
 
11327
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
11328
      } catch (org.apache.thrift.TException te) {
-
 
11329
        throw new java.io.IOException(te);
-
 
11330
      }
-
 
11331
    }
-
 
11332
 
-
 
11333
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
11334
      try {
-
 
11335
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
11336
      } catch (org.apache.thrift.TException te) {
-
 
11337
        throw new java.io.IOException(te);
-
 
11338
      }
-
 
11339
    }
-
 
11340
 
-
 
11341
  }
-
 
11342
 
-
 
11343
  public static class getItemNumbers_args implements org.apache.thrift.TBase<getItemNumbers_args, getItemNumbers_args._Fields>, java.io.Serializable, Cloneable   {
-
 
11344
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemNumbers_args");
-
 
11345
 
-
 
11346
    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)1);
-
 
11347
 
-
 
11348
    private long itemId; // required
-
 
11349
 
-
 
11350
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
11351
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
11352
      ITEM_ID((short)1, "itemId");
-
 
11353
 
-
 
11354
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
11355
 
-
 
11356
      static {
-
 
11357
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
11358
          byName.put(field.getFieldName(), field);
-
 
11359
        }
-
 
11360
      }
-
 
11361
 
-
 
11362
      /**
-
 
11363
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
11364
       */
-
 
11365
      public static _Fields findByThriftId(int fieldId) {
-
 
11366
        switch(fieldId) {
-
 
11367
          case 1: // ITEM_ID
-
 
11368
            return ITEM_ID;
-
 
11369
          default:
-
 
11370
            return null;
-
 
11371
        }
-
 
11372
      }
-
 
11373
 
-
 
11374
      /**
-
 
11375
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
11376
       * if it is not found.
-
 
11377
       */
-
 
11378
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
11379
        _Fields fields = findByThriftId(fieldId);
-
 
11380
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
11381
        return fields;
-
 
11382
      }
-
 
11383
 
-
 
11384
      /**
-
 
11385
       * Find the _Fields constant that matches name, or null if its not found.
-
 
11386
       */
-
 
11387
      public static _Fields findByName(String name) {
-
 
11388
        return byName.get(name);
-
 
11389
      }
-
 
11390
 
-
 
11391
      private final short _thriftId;
-
 
11392
      private final String _fieldName;
-
 
11393
 
-
 
11394
      _Fields(short thriftId, String fieldName) {
-
 
11395
        _thriftId = thriftId;
-
 
11396
        _fieldName = fieldName;
-
 
11397
      }
-
 
11398
 
-
 
11399
      public short getThriftFieldId() {
-
 
11400
        return _thriftId;
-
 
11401
      }
-
 
11402
 
-
 
11403
      public String getFieldName() {
-
 
11404
        return _fieldName;
-
 
11405
      }
-
 
11406
    }
-
 
11407
 
-
 
11408
    // isset id assignments
-
 
11409
    private static final int __ITEMID_ISSET_ID = 0;
-
 
11410
    private BitSet __isset_bit_vector = new BitSet(1);
-
 
11411
 
-
 
11412
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
11413
    static {
-
 
11414
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
11415
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
11416
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
11417
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
11418
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemNumbers_args.class, metaDataMap);
-
 
11419
    }
-
 
11420
 
-
 
11421
    public getItemNumbers_args() {
-
 
11422
    }
-
 
11423
 
-
 
11424
    public getItemNumbers_args(
-
 
11425
      long itemId)
-
 
11426
    {
-
 
11427
      this();
-
 
11428
      this.itemId = itemId;
-
 
11429
      setItemIdIsSet(true);
-
 
11430
    }
-
 
11431
 
-
 
11432
    /**
-
 
11433
     * Performs a deep copy on <i>other</i>.
-
 
11434
     */
-
 
11435
    public getItemNumbers_args(getItemNumbers_args other) {
-
 
11436
      __isset_bit_vector.clear();
-
 
11437
      __isset_bit_vector.or(other.__isset_bit_vector);
-
 
11438
      this.itemId = other.itemId;
-
 
11439
    }
-
 
11440
 
-
 
11441
    public getItemNumbers_args deepCopy() {
-
 
11442
      return new getItemNumbers_args(this);
-
 
11443
    }
-
 
11444
 
-
 
11445
    @Override
-
 
11446
    public void clear() {
-
 
11447
      setItemIdIsSet(false);
-
 
11448
      this.itemId = 0;
-
 
11449
    }
-
 
11450
 
-
 
11451
    public long getItemId() {
-
 
11452
      return this.itemId;
-
 
11453
    }
-
 
11454
 
-
 
11455
    public void setItemId(long itemId) {
-
 
11456
      this.itemId = itemId;
-
 
11457
      setItemIdIsSet(true);
-
 
11458
    }
-
 
11459
 
-
 
11460
    public void unsetItemId() {
-
 
11461
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
-
 
11462
    }
-
 
11463
 
-
 
11464
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
-
 
11465
    public boolean isSetItemId() {
-
 
11466
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
-
 
11467
    }
-
 
11468
 
-
 
11469
    public void setItemIdIsSet(boolean value) {
-
 
11470
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
-
 
11471
    }
-
 
11472
 
-
 
11473
    public void setFieldValue(_Fields field, Object value) {
-
 
11474
      switch (field) {
-
 
11475
      case ITEM_ID:
-
 
11476
        if (value == null) {
-
 
11477
          unsetItemId();
-
 
11478
        } else {
-
 
11479
          setItemId((Long)value);
-
 
11480
        }
-
 
11481
        break;
-
 
11482
 
-
 
11483
      }
-
 
11484
    }
-
 
11485
 
-
 
11486
    public Object getFieldValue(_Fields field) {
-
 
11487
      switch (field) {
-
 
11488
      case ITEM_ID:
-
 
11489
        return Long.valueOf(getItemId());
-
 
11490
 
-
 
11491
      }
-
 
11492
      throw new IllegalStateException();
-
 
11493
    }
-
 
11494
 
-
 
11495
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
11496
    public boolean isSet(_Fields field) {
-
 
11497
      if (field == null) {
-
 
11498
        throw new IllegalArgumentException();
-
 
11499
      }
-
 
11500
 
-
 
11501
      switch (field) {
-
 
11502
      case ITEM_ID:
-
 
11503
        return isSetItemId();
-
 
11504
      }
-
 
11505
      throw new IllegalStateException();
-
 
11506
    }
-
 
11507
 
-
 
11508
    @Override
-
 
11509
    public boolean equals(Object that) {
-
 
11510
      if (that == null)
-
 
11511
        return false;
-
 
11512
      if (that instanceof getItemNumbers_args)
-
 
11513
        return this.equals((getItemNumbers_args)that);
-
 
11514
      return false;
-
 
11515
    }
-
 
11516
 
-
 
11517
    public boolean equals(getItemNumbers_args that) {
-
 
11518
      if (that == null)
-
 
11519
        return false;
-
 
11520
 
-
 
11521
      boolean this_present_itemId = true;
-
 
11522
      boolean that_present_itemId = true;
-
 
11523
      if (this_present_itemId || that_present_itemId) {
-
 
11524
        if (!(this_present_itemId && that_present_itemId))
-
 
11525
          return false;
-
 
11526
        if (this.itemId != that.itemId)
-
 
11527
          return false;
-
 
11528
      }
-
 
11529
 
-
 
11530
      return true;
-
 
11531
    }
-
 
11532
 
-
 
11533
    @Override
-
 
11534
    public int hashCode() {
-
 
11535
      return 0;
-
 
11536
    }
-
 
11537
 
-
 
11538
    public int compareTo(getItemNumbers_args other) {
-
 
11539
      if (!getClass().equals(other.getClass())) {
-
 
11540
        return getClass().getName().compareTo(other.getClass().getName());
-
 
11541
      }
-
 
11542
 
-
 
11543
      int lastComparison = 0;
-
 
11544
      getItemNumbers_args typedOther = (getItemNumbers_args)other;
-
 
11545
 
-
 
11546
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
-
 
11547
      if (lastComparison != 0) {
-
 
11548
        return lastComparison;
-
 
11549
      }
-
 
11550
      if (isSetItemId()) {
-
 
11551
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
-
 
11552
        if (lastComparison != 0) {
-
 
11553
          return lastComparison;
-
 
11554
        }
-
 
11555
      }
-
 
11556
      return 0;
-
 
11557
    }
-
 
11558
 
-
 
11559
    public _Fields fieldForId(int fieldId) {
-
 
11560
      return _Fields.findByThriftId(fieldId);
-
 
11561
    }
-
 
11562
 
-
 
11563
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
11564
      org.apache.thrift.protocol.TField field;
-
 
11565
      iprot.readStructBegin();
-
 
11566
      while (true)
-
 
11567
      {
-
 
11568
        field = iprot.readFieldBegin();
-
 
11569
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
11570
          break;
-
 
11571
        }
-
 
11572
        switch (field.id) {
-
 
11573
          case 1: // ITEM_ID
-
 
11574
            if (field.type == org.apache.thrift.protocol.TType.I64) {
-
 
11575
              this.itemId = iprot.readI64();
-
 
11576
              setItemIdIsSet(true);
-
 
11577
            } else { 
-
 
11578
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
11579
            }
-
 
11580
            break;
-
 
11581
          default:
-
 
11582
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
11583
        }
-
 
11584
        iprot.readFieldEnd();
-
 
11585
      }
-
 
11586
      iprot.readStructEnd();
-
 
11587
      validate();
-
 
11588
    }
-
 
11589
 
-
 
11590
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
11591
      validate();
-
 
11592
 
-
 
11593
      oprot.writeStructBegin(STRUCT_DESC);
-
 
11594
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
-
 
11595
      oprot.writeI64(this.itemId);
-
 
11596
      oprot.writeFieldEnd();
-
 
11597
      oprot.writeFieldStop();
-
 
11598
      oprot.writeStructEnd();
-
 
11599
    }
-
 
11600
 
-
 
11601
    @Override
-
 
11602
    public String toString() {
-
 
11603
      StringBuilder sb = new StringBuilder("getItemNumbers_args(");
-
 
11604
      boolean first = true;
-
 
11605
 
-
 
11606
      sb.append("itemId:");
-
 
11607
      sb.append(this.itemId);
-
 
11608
      first = false;
-
 
11609
      sb.append(")");
-
 
11610
      return sb.toString();
-
 
11611
    }
-
 
11612
 
-
 
11613
    public void validate() throws org.apache.thrift.TException {
-
 
11614
      // check for required fields
-
 
11615
    }
-
 
11616
 
-
 
11617
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
11618
      try {
-
 
11619
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
11620
      } catch (org.apache.thrift.TException te) {
-
 
11621
        throw new java.io.IOException(te);
-
 
11622
      }
-
 
11623
    }
-
 
11624
 
-
 
11625
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
11626
      try {
-
 
11627
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-
 
11628
        __isset_bit_vector = new BitSet(1);
-
 
11629
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
11630
      } catch (org.apache.thrift.TException te) {
-
 
11631
        throw new java.io.IOException(te);
-
 
11632
      }
-
 
11633
    }
-
 
11634
 
-
 
11635
  }
-
 
11636
 
-
 
11637
  public static class getItemNumbers_result implements org.apache.thrift.TBase<getItemNumbers_result, getItemNumbers_result._Fields>, java.io.Serializable, Cloneable   {
-
 
11638
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemNumbers_result");
-
 
11639
 
-
 
11640
    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);
-
 
11641
 
-
 
11642
    private List<String> success; // required
-
 
11643
 
-
 
11644
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
-
 
11645
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
-
 
11646
      SUCCESS((short)0, "success");
-
 
11647
 
-
 
11648
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
-
 
11649
 
-
 
11650
      static {
-
 
11651
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
-
 
11652
          byName.put(field.getFieldName(), field);
-
 
11653
        }
-
 
11654
      }
-
 
11655
 
-
 
11656
      /**
-
 
11657
       * Find the _Fields constant that matches fieldId, or null if its not found.
-
 
11658
       */
-
 
11659
      public static _Fields findByThriftId(int fieldId) {
-
 
11660
        switch(fieldId) {
-
 
11661
          case 0: // SUCCESS
-
 
11662
            return SUCCESS;
-
 
11663
          default:
-
 
11664
            return null;
-
 
11665
        }
-
 
11666
      }
-
 
11667
 
-
 
11668
      /**
-
 
11669
       * Find the _Fields constant that matches fieldId, throwing an exception
-
 
11670
       * if it is not found.
-
 
11671
       */
-
 
11672
      public static _Fields findByThriftIdOrThrow(int fieldId) {
-
 
11673
        _Fields fields = findByThriftId(fieldId);
-
 
11674
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
-
 
11675
        return fields;
-
 
11676
      }
-
 
11677
 
-
 
11678
      /**
-
 
11679
       * Find the _Fields constant that matches name, or null if its not found.
-
 
11680
       */
-
 
11681
      public static _Fields findByName(String name) {
-
 
11682
        return byName.get(name);
-
 
11683
      }
-
 
11684
 
-
 
11685
      private final short _thriftId;
-
 
11686
      private final String _fieldName;
-
 
11687
 
-
 
11688
      _Fields(short thriftId, String fieldName) {
-
 
11689
        _thriftId = thriftId;
-
 
11690
        _fieldName = fieldName;
-
 
11691
      }
-
 
11692
 
-
 
11693
      public short getThriftFieldId() {
-
 
11694
        return _thriftId;
-
 
11695
      }
-
 
11696
 
-
 
11697
      public String getFieldName() {
-
 
11698
        return _fieldName;
-
 
11699
      }
-
 
11700
    }
-
 
11701
 
-
 
11702
    // isset id assignments
-
 
11703
 
-
 
11704
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
-
 
11705
    static {
-
 
11706
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
11707
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
11708
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
-
 
11709
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
-
 
11710
      metaDataMap = Collections.unmodifiableMap(tmpMap);
-
 
11711
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemNumbers_result.class, metaDataMap);
-
 
11712
    }
-
 
11713
 
-
 
11714
    public getItemNumbers_result() {
-
 
11715
    }
-
 
11716
 
-
 
11717
    public getItemNumbers_result(
-
 
11718
      List<String> success)
-
 
11719
    {
-
 
11720
      this();
-
 
11721
      this.success = success;
-
 
11722
    }
-
 
11723
 
-
 
11724
    /**
-
 
11725
     * Performs a deep copy on <i>other</i>.
-
 
11726
     */
-
 
11727
    public getItemNumbers_result(getItemNumbers_result other) {
-
 
11728
      if (other.isSetSuccess()) {
-
 
11729
        List<String> __this__success = new ArrayList<String>();
-
 
11730
        for (String other_element : other.success) {
-
 
11731
          __this__success.add(other_element);
-
 
11732
        }
-
 
11733
        this.success = __this__success;
-
 
11734
      }
-
 
11735
    }
-
 
11736
 
-
 
11737
    public getItemNumbers_result deepCopy() {
-
 
11738
      return new getItemNumbers_result(this);
-
 
11739
    }
-
 
11740
 
-
 
11741
    @Override
-
 
11742
    public void clear() {
-
 
11743
      this.success = null;
-
 
11744
    }
-
 
11745
 
-
 
11746
    public int getSuccessSize() {
-
 
11747
      return (this.success == null) ? 0 : this.success.size();
-
 
11748
    }
-
 
11749
 
-
 
11750
    public java.util.Iterator<String> getSuccessIterator() {
-
 
11751
      return (this.success == null) ? null : this.success.iterator();
-
 
11752
    }
-
 
11753
 
-
 
11754
    public void addToSuccess(String elem) {
-
 
11755
      if (this.success == null) {
-
 
11756
        this.success = new ArrayList<String>();
-
 
11757
      }
-
 
11758
      this.success.add(elem);
-
 
11759
    }
-
 
11760
 
-
 
11761
    public List<String> getSuccess() {
-
 
11762
      return this.success;
-
 
11763
    }
-
 
11764
 
-
 
11765
    public void setSuccess(List<String> success) {
-
 
11766
      this.success = success;
-
 
11767
    }
-
 
11768
 
-
 
11769
    public void unsetSuccess() {
-
 
11770
      this.success = null;
-
 
11771
    }
-
 
11772
 
-
 
11773
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
-
 
11774
    public boolean isSetSuccess() {
-
 
11775
      return this.success != null;
-
 
11776
    }
-
 
11777
 
-
 
11778
    public void setSuccessIsSet(boolean value) {
-
 
11779
      if (!value) {
-
 
11780
        this.success = null;
-
 
11781
      }
-
 
11782
    }
-
 
11783
 
-
 
11784
    public void setFieldValue(_Fields field, Object value) {
-
 
11785
      switch (field) {
-
 
11786
      case SUCCESS:
-
 
11787
        if (value == null) {
-
 
11788
          unsetSuccess();
-
 
11789
        } else {
-
 
11790
          setSuccess((List<String>)value);
-
 
11791
        }
-
 
11792
        break;
-
 
11793
 
-
 
11794
      }
-
 
11795
    }
-
 
11796
 
-
 
11797
    public Object getFieldValue(_Fields field) {
-
 
11798
      switch (field) {
-
 
11799
      case SUCCESS:
-
 
11800
        return getSuccess();
-
 
11801
 
-
 
11802
      }
-
 
11803
      throw new IllegalStateException();
-
 
11804
    }
-
 
11805
 
-
 
11806
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
-
 
11807
    public boolean isSet(_Fields field) {
-
 
11808
      if (field == null) {
-
 
11809
        throw new IllegalArgumentException();
-
 
11810
      }
-
 
11811
 
-
 
11812
      switch (field) {
-
 
11813
      case SUCCESS:
-
 
11814
        return isSetSuccess();
-
 
11815
      }
-
 
11816
      throw new IllegalStateException();
-
 
11817
    }
-
 
11818
 
-
 
11819
    @Override
-
 
11820
    public boolean equals(Object that) {
-
 
11821
      if (that == null)
-
 
11822
        return false;
-
 
11823
      if (that instanceof getItemNumbers_result)
-
 
11824
        return this.equals((getItemNumbers_result)that);
-
 
11825
      return false;
-
 
11826
    }
-
 
11827
 
-
 
11828
    public boolean equals(getItemNumbers_result that) {
-
 
11829
      if (that == null)
-
 
11830
        return false;
-
 
11831
 
-
 
11832
      boolean this_present_success = true && this.isSetSuccess();
-
 
11833
      boolean that_present_success = true && that.isSetSuccess();
-
 
11834
      if (this_present_success || that_present_success) {
-
 
11835
        if (!(this_present_success && that_present_success))
-
 
11836
          return false;
-
 
11837
        if (!this.success.equals(that.success))
-
 
11838
          return false;
-
 
11839
      }
-
 
11840
 
-
 
11841
      return true;
-
 
11842
    }
-
 
11843
 
-
 
11844
    @Override
-
 
11845
    public int hashCode() {
-
 
11846
      return 0;
-
 
11847
    }
-
 
11848
 
-
 
11849
    public int compareTo(getItemNumbers_result other) {
-
 
11850
      if (!getClass().equals(other.getClass())) {
-
 
11851
        return getClass().getName().compareTo(other.getClass().getName());
-
 
11852
      }
-
 
11853
 
-
 
11854
      int lastComparison = 0;
-
 
11855
      getItemNumbers_result typedOther = (getItemNumbers_result)other;
-
 
11856
 
-
 
11857
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
-
 
11858
      if (lastComparison != 0) {
-
 
11859
        return lastComparison;
-
 
11860
      }
-
 
11861
      if (isSetSuccess()) {
-
 
11862
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
-
 
11863
        if (lastComparison != 0) {
-
 
11864
          return lastComparison;
-
 
11865
        }
-
 
11866
      }
-
 
11867
      return 0;
-
 
11868
    }
-
 
11869
 
-
 
11870
    public _Fields fieldForId(int fieldId) {
-
 
11871
      return _Fields.findByThriftId(fieldId);
-
 
11872
    }
-
 
11873
 
-
 
11874
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
-
 
11875
      org.apache.thrift.protocol.TField field;
-
 
11876
      iprot.readStructBegin();
-
 
11877
      while (true)
-
 
11878
      {
-
 
11879
        field = iprot.readFieldBegin();
-
 
11880
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
-
 
11881
          break;
-
 
11882
        }
-
 
11883
        switch (field.id) {
-
 
11884
          case 0: // SUCCESS
-
 
11885
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
-
 
11886
              {
-
 
11887
                org.apache.thrift.protocol.TList _list16 = iprot.readListBegin();
-
 
11888
                this.success = new ArrayList<String>(_list16.size);
-
 
11889
                for (int _i17 = 0; _i17 < _list16.size; ++_i17)
-
 
11890
                {
-
 
11891
                  String _elem18; // required
-
 
11892
                  _elem18 = iprot.readString();
-
 
11893
                  this.success.add(_elem18);
-
 
11894
                }
-
 
11895
                iprot.readListEnd();
-
 
11896
              }
-
 
11897
            } else { 
-
 
11898
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
11899
            }
-
 
11900
            break;
-
 
11901
          default:
-
 
11902
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
-
 
11903
        }
-
 
11904
        iprot.readFieldEnd();
-
 
11905
      }
-
 
11906
      iprot.readStructEnd();
-
 
11907
      validate();
-
 
11908
    }
-
 
11909
 
-
 
11910
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
-
 
11911
      oprot.writeStructBegin(STRUCT_DESC);
-
 
11912
 
-
 
11913
      if (this.isSetSuccess()) {
-
 
11914
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
-
 
11915
        {
-
 
11916
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, this.success.size()));
-
 
11917
          for (String _iter19 : this.success)
-
 
11918
          {
-
 
11919
            oprot.writeString(_iter19);
-
 
11920
          }
-
 
11921
          oprot.writeListEnd();
-
 
11922
        }
-
 
11923
        oprot.writeFieldEnd();
-
 
11924
      }
-
 
11925
      oprot.writeFieldStop();
-
 
11926
      oprot.writeStructEnd();
-
 
11927
    }
-
 
11928
 
-
 
11929
    @Override
-
 
11930
    public String toString() {
-
 
11931
      StringBuilder sb = new StringBuilder("getItemNumbers_result(");
-
 
11932
      boolean first = true;
-
 
11933
 
-
 
11934
      sb.append("success:");
-
 
11935
      if (this.success == null) {
-
 
11936
        sb.append("null");
-
 
11937
      } else {
-
 
11938
        sb.append(this.success);
-
 
11939
      }
-
 
11940
      first = false;
-
 
11941
      sb.append(")");
-
 
11942
      return sb.toString();
-
 
11943
    }
-
 
11944
 
-
 
11945
    public void validate() throws org.apache.thrift.TException {
11241
      // check for required fields
11946
      // check for required fields
11242
    }
11947
    }
11243
 
11948
 
11244
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11949
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11245
      try {
11950
      try {