Subversion Repositories SmartDukaan

Rev

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

Rev 11173 Rev 12280
Line 369... Line 369...
369
 
369
 
370
    public List<FlipkartInventorySnapshot> getFlipkartInventorySnapshot() throws org.apache.thrift.TException;
370
    public List<FlipkartInventorySnapshot> getFlipkartInventorySnapshot() throws org.apache.thrift.TException;
371
 
371
 
372
    public FlipkartInventorySnapshot getFlipkartlInventoryForItem(long item_id) throws org.apache.thrift.TException;
372
    public FlipkartInventorySnapshot getFlipkartlInventoryForItem(long item_id) throws org.apache.thrift.TException;
373
 
373
 
374
    public Map<Long,String> getStateMaster() throws org.apache.thrift.TException;
374
    public Map<Long,StateInfo> getStateMaster() throws org.apache.thrift.TException;
375
 
375
 
376
    public void updateSnapdealStockAtEOD(List<SnapdealStockAtEOD> allsnapdealstock) throws org.apache.thrift.TException;
376
    public void updateSnapdealStockAtEOD(List<SnapdealStockAtEOD> allsnapdealstock) throws org.apache.thrift.TException;
377
 
377
 
378
    public void updateFlipkartStockAtEOD(List<FlipkartStockAtEOD> allflipkartstock) throws org.apache.thrift.TException;
378
    public void updateFlipkartStockAtEOD(List<FlipkartStockAtEOD> allflipkartstock) throws org.apache.thrift.TException;
379
 
379
 
Line 2338... Line 2338...
2338
        return result.success;
2338
        return result.success;
2339
      }
2339
      }
2340
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getFlipkartlInventoryForItem failed: unknown result");
2340
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getFlipkartlInventoryForItem failed: unknown result");
2341
    }
2341
    }
2342
 
2342
 
2343
    public Map<Long,String> getStateMaster() throws org.apache.thrift.TException
2343
    public Map<Long,StateInfo> getStateMaster() throws org.apache.thrift.TException
2344
    {
2344
    {
2345
      send_getStateMaster();
2345
      send_getStateMaster();
2346
      return recv_getStateMaster();
2346
      return recv_getStateMaster();
2347
    }
2347
    }
2348
 
2348
 
Line 2350... Line 2350...
2350
    {
2350
    {
2351
      getStateMaster_args args = new getStateMaster_args();
2351
      getStateMaster_args args = new getStateMaster_args();
2352
      sendBase("getStateMaster", args);
2352
      sendBase("getStateMaster", args);
2353
    }
2353
    }
2354
 
2354
 
2355
    public Map<Long,String> recv_getStateMaster() throws org.apache.thrift.TException
2355
    public Map<Long,StateInfo> recv_getStateMaster() throws org.apache.thrift.TException
2356
    {
2356
    {
2357
      getStateMaster_result result = new getStateMaster_result();
2357
      getStateMaster_result result = new getStateMaster_result();
2358
      receiveBase(result, "getStateMaster");
2358
      receiveBase(result, "getStateMaster");
2359
      if (result.isSetSuccess()) {
2359
      if (result.isSetSuccess()) {
2360
        return result.success;
2360
        return result.success;
Line 4987... Line 4987...
4987
        getStateMaster_args args = new getStateMaster_args();
4987
        getStateMaster_args args = new getStateMaster_args();
4988
        args.write(prot);
4988
        args.write(prot);
4989
        prot.writeMessageEnd();
4989
        prot.writeMessageEnd();
4990
      }
4990
      }
4991
 
4991
 
4992
      public Map<Long,String> getResult() throws org.apache.thrift.TException {
4992
      public Map<Long,StateInfo> getResult() throws org.apache.thrift.TException {
4993
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
4993
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
4994
          throw new IllegalStateException("Method call not finished!");
4994
          throw new IllegalStateException("Method call not finished!");
4995
        }
4995
        }
4996
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
4996
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
4997
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
4997
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
Line 56464... Line 56464...
56464
  public static class getStateMaster_result implements org.apache.thrift.TBase<getStateMaster_result, getStateMaster_result._Fields>, java.io.Serializable, Cloneable   {
56464
  public static class getStateMaster_result implements org.apache.thrift.TBase<getStateMaster_result, getStateMaster_result._Fields>, java.io.Serializable, Cloneable   {
56465
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getStateMaster_result");
56465
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getStateMaster_result");
56466
 
56466
 
56467
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.MAP, (short)0);
56467
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.MAP, (short)0);
56468
 
56468
 
56469
    private Map<Long,String> success; // required
56469
    private Map<Long,StateInfo> success; // required
56470
 
56470
 
56471
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
56471
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
56472
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
56472
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
56473
      SUCCESS((short)0, "success");
56473
      SUCCESS((short)0, "success");
56474
 
56474
 
Line 56532... Line 56532...
56532
    static {
56532
    static {
56533
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
56533
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
56534
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
56534
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
56535
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
56535
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
56536
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
56536
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
56537
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
56537
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, StateInfo.class))));
56538
      metaDataMap = Collections.unmodifiableMap(tmpMap);
56538
      metaDataMap = Collections.unmodifiableMap(tmpMap);
56539
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getStateMaster_result.class, metaDataMap);
56539
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getStateMaster_result.class, metaDataMap);
56540
    }
56540
    }
56541
 
56541
 
56542
    public getStateMaster_result() {
56542
    public getStateMaster_result() {
56543
    }
56543
    }
56544
 
56544
 
56545
    public getStateMaster_result(
56545
    public getStateMaster_result(
56546
      Map<Long,String> success)
56546
      Map<Long,StateInfo> success)
56547
    {
56547
    {
56548
      this();
56548
      this();
56549
      this.success = success;
56549
      this.success = success;
56550
    }
56550
    }
56551
 
56551
 
56552
    /**
56552
    /**
56553
     * Performs a deep copy on <i>other</i>.
56553
     * Performs a deep copy on <i>other</i>.
56554
     */
56554
     */
56555
    public getStateMaster_result(getStateMaster_result other) {
56555
    public getStateMaster_result(getStateMaster_result other) {
56556
      if (other.isSetSuccess()) {
56556
      if (other.isSetSuccess()) {
56557
        Map<Long,String> __this__success = new HashMap<Long,String>();
56557
        Map<Long,StateInfo> __this__success = new HashMap<Long,StateInfo>();
56558
        for (Map.Entry<Long, String> other_element : other.success.entrySet()) {
56558
        for (Map.Entry<Long, StateInfo> other_element : other.success.entrySet()) {
56559
 
56559
 
56560
          Long other_element_key = other_element.getKey();
56560
          Long other_element_key = other_element.getKey();
56561
          String other_element_value = other_element.getValue();
56561
          StateInfo other_element_value = other_element.getValue();
56562
 
56562
 
56563
          Long __this__success_copy_key = other_element_key;
56563
          Long __this__success_copy_key = other_element_key;
56564
 
56564
 
56565
          String __this__success_copy_value = other_element_value;
56565
          StateInfo __this__success_copy_value = new StateInfo(other_element_value);
56566
 
56566
 
56567
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
56567
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
56568
        }
56568
        }
56569
        this.success = __this__success;
56569
        this.success = __this__success;
56570
      }
56570
      }
Line 56581... Line 56581...
56581
 
56581
 
56582
    public int getSuccessSize() {
56582
    public int getSuccessSize() {
56583
      return (this.success == null) ? 0 : this.success.size();
56583
      return (this.success == null) ? 0 : this.success.size();
56584
    }
56584
    }
56585
 
56585
 
56586
    public void putToSuccess(long key, String val) {
56586
    public void putToSuccess(long key, StateInfo val) {
56587
      if (this.success == null) {
56587
      if (this.success == null) {
56588
        this.success = new HashMap<Long,String>();
56588
        this.success = new HashMap<Long,StateInfo>();
56589
      }
56589
      }
56590
      this.success.put(key, val);
56590
      this.success.put(key, val);
56591
    }
56591
    }
56592
 
56592
 
56593
    public Map<Long,String> getSuccess() {
56593
    public Map<Long,StateInfo> getSuccess() {
56594
      return this.success;
56594
      return this.success;
56595
    }
56595
    }
56596
 
56596
 
56597
    public void setSuccess(Map<Long,String> success) {
56597
    public void setSuccess(Map<Long,StateInfo> success) {
56598
      this.success = success;
56598
      this.success = success;
56599
    }
56599
    }
56600
 
56600
 
56601
    public void unsetSuccess() {
56601
    public void unsetSuccess() {
56602
      this.success = null;
56602
      this.success = null;
Line 56617... Line 56617...
56617
      switch (field) {
56617
      switch (field) {
56618
      case SUCCESS:
56618
      case SUCCESS:
56619
        if (value == null) {
56619
        if (value == null) {
56620
          unsetSuccess();
56620
          unsetSuccess();
56621
        } else {
56621
        } else {
56622
          setSuccess((Map<Long,String>)value);
56622
          setSuccess((Map<Long,StateInfo>)value);
56623
        }
56623
        }
56624
        break;
56624
        break;
56625
 
56625
 
56626
      }
56626
      }
56627
    }
56627
    }
Line 56715... Line 56715...
56715
        switch (field.id) {
56715
        switch (field.id) {
56716
          case 0: // SUCCESS
56716
          case 0: // SUCCESS
56717
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
56717
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
56718
              {
56718
              {
56719
                org.apache.thrift.protocol.TMap _map179 = iprot.readMapBegin();
56719
                org.apache.thrift.protocol.TMap _map179 = iprot.readMapBegin();
56720
                this.success = new HashMap<Long,String>(2*_map179.size);
56720
                this.success = new HashMap<Long,StateInfo>(2*_map179.size);
56721
                for (int _i180 = 0; _i180 < _map179.size; ++_i180)
56721
                for (int _i180 = 0; _i180 < _map179.size; ++_i180)
56722
                {
56722
                {
56723
                  long _key181; // required
56723
                  long _key181; // required
56724
                  String _val182; // required
56724
                  StateInfo _val182; // required
56725
                  _key181 = iprot.readI64();
56725
                  _key181 = iprot.readI64();
56726
                  _val182 = iprot.readString();
56726
                  _val182 = new StateInfo();
-
 
56727
                  _val182.read(iprot);
56727
                  this.success.put(_key181, _val182);
56728
                  this.success.put(_key181, _val182);
56728
                }
56729
                }
56729
                iprot.readMapEnd();
56730
                iprot.readMapEnd();
56730
              }
56731
              }
56731
            } else { 
56732
            } else { 
Line 56745... Line 56746...
56745
      oprot.writeStructBegin(STRUCT_DESC);
56746
      oprot.writeStructBegin(STRUCT_DESC);
56746
 
56747
 
56747
      if (this.isSetSuccess()) {
56748
      if (this.isSetSuccess()) {
56748
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
56749
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
56749
        {
56750
        {
56750
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.STRING, this.success.size()));
56751
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
56751
          for (Map.Entry<Long, String> _iter183 : this.success.entrySet())
56752
          for (Map.Entry<Long, StateInfo> _iter183 : this.success.entrySet())
56752
          {
56753
          {
56753
            oprot.writeI64(_iter183.getKey());
56754
            oprot.writeI64(_iter183.getKey());
56754
            oprot.writeString(_iter183.getValue());
56755
            _iter183.getValue().write(oprot);
56755
          }
56756
          }
56756
          oprot.writeMapEnd();
56757
          oprot.writeMapEnd();
56757
        }
56758
        }
56758
        oprot.writeFieldEnd();
56759
        oprot.writeFieldEnd();
56759
      }
56760
      }