Package org.apache.blur.thirdparty.thrift_0_9_0.protocol

Examples of org.apache.blur.thirdparty.thrift_0_9_0.protocol.TTupleProtocol


      }
    }

    @Override
    public void read(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, User struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol iprot = (TTupleProtocol) prot;
      BitSet incoming = iprot.readBitSet(2);
      if (incoming.get(0)) {
        struct.username = iprot.readString();
        struct.setUsernameIsSet(true);
      }
      if (incoming.get(1)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map6 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, iprot.readI32());
          struct.attributes = new HashMap<String,String>(2*_map6.size);
          for (int _i7 = 0; _i7 < _map6.size; ++_i7)
          {
            String _key8; // optional
            String _val9; // required
            _key8 = iprot.readString();
            _val9 = iprot.readString();
            struct.attributes.put(_key8, _val9);
          }
        }
        struct.setAttributesIsSet(true);
      }
View Full Code Here


  private static class MetricTupleScheme extends TupleScheme<Metric> {

    @Override
    public void write(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, Metric struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol oprot = (TTupleProtocol) prot;
      BitSet optionals = new BitSet();
      if (struct.isSetName()) {
        optionals.set(0);
      }
      if (struct.isSetStrMap()) {
        optionals.set(1);
      }
      if (struct.isSetLongMap()) {
        optionals.set(2);
      }
      if (struct.isSetDoubleMap()) {
        optionals.set(3);
      }
      oprot.writeBitSet(optionals, 4);
      if (struct.isSetName()) {
        oprot.writeString(struct.name);
      }
      if (struct.isSetStrMap()) {
        {
          oprot.writeI32(struct.strMap.size());
          for (Map.Entry<String, String> _iter217 : struct.strMap.entrySet())
          {
            oprot.writeString(_iter217.getKey());
            oprot.writeString(_iter217.getValue());
          }
        }
      }
      if (struct.isSetLongMap()) {
        {
          oprot.writeI32(struct.longMap.size());
          for (Map.Entry<String, Long> _iter218 : struct.longMap.entrySet())
          {
            oprot.writeString(_iter218.getKey());
            oprot.writeI64(_iter218.getValue());
          }
        }
      }
      if (struct.isSetDoubleMap()) {
        {
          oprot.writeI32(struct.doubleMap.size());
          for (Map.Entry<String, Double> _iter219 : struct.doubleMap.entrySet())
          {
            oprot.writeString(_iter219.getKey());
            oprot.writeDouble(_iter219.getValue());
          }
        }
      }
    }
View Full Code Here

      }
    }

    @Override
    public void read(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, Metric struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol iprot = (TTupleProtocol) prot;
      BitSet incoming = iprot.readBitSet(4);
      if (incoming.get(0)) {
        struct.name = iprot.readString();
        struct.setNameIsSet(true);
      }
      if (incoming.get(1)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map220 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, iprot.readI32());
          struct.strMap = new HashMap<String,String>(2*_map220.size);
          for (int _i221 = 0; _i221 < _map220.size; ++_i221)
          {
            String _key222; // optional
            String _val223; // required
            _key222 = iprot.readString();
            _val223 = iprot.readString();
            struct.strMap.put(_key222, _val223);
          }
        }
        struct.setStrMapIsSet(true);
      }
      if (incoming.get(2)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map224 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.I64, iprot.readI32());
          struct.longMap = new HashMap<String,Long>(2*_map224.size);
          for (int _i225 = 0; _i225 < _map224.size; ++_i225)
          {
            String _key226; // optional
            long _val227; // required
            _key226 = iprot.readString();
            _val227 = iprot.readI64();
            struct.longMap.put(_key226, _val227);
          }
        }
        struct.setLongMapIsSet(true);
      }
      if (incoming.get(3)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map228 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.DOUBLE, iprot.readI32());
          struct.doubleMap = new HashMap<String,Double>(2*_map228.size);
          for (int _i229 = 0; _i229 < _map228.size; ++_i229)
          {
            String _key230; // optional
            double _val231; // required
            _key230 = iprot.readString();
            _val231 = iprot.readDouble();
            struct.doubleMap.put(_key230, _val231);
          }
        }
        struct.setDoubleMapIsSet(true);
      }
View Full Code Here

  private static class RowMutationTupleScheme extends TupleScheme<RowMutation> {

    @Override
    public void write(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, RowMutation struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol oprot = (TTupleProtocol) prot;
      BitSet optionals = new BitSet();
      if (struct.isSetTable()) {
        optionals.set(0);
      }
      if (struct.isSetRowId()) {
        optionals.set(1);
      }
      if (struct.isSetRowMutationType()) {
        optionals.set(2);
      }
      if (struct.isSetRecordMutations()) {
        optionals.set(3);
      }
      oprot.writeBitSet(optionals, 4);
      if (struct.isSetTable()) {
        oprot.writeString(struct.table);
      }
      if (struct.isSetRowId()) {
        oprot.writeString(struct.rowId);
      }
      if (struct.isSetRowMutationType()) {
        oprot.writeI32(struct.rowMutationType.getValue());
      }
      if (struct.isSetRecordMutations()) {
        {
          oprot.writeI32(struct.recordMutations.size());
          for (RecordMutation _iter122 : struct.recordMutations)
          {
            _iter122.write(oprot);
          }
        }
View Full Code Here

      }
    }

    @Override
    public void read(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, RowMutation struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol iprot = (TTupleProtocol) prot;
      BitSet incoming = iprot.readBitSet(4);
      if (incoming.get(0)) {
        struct.table = iprot.readString();
        struct.setTableIsSet(true);
      }
      if (incoming.get(1)) {
        struct.rowId = iprot.readString();
        struct.setRowIdIsSet(true);
      }
      if (incoming.get(2)) {
        struct.rowMutationType = RowMutationType.findByValue(iprot.readI32());
        struct.setRowMutationTypeIsSet(true);
      }
      if (incoming.get(3)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TList _list123 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TList(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRUCT, iprot.readI32());
          struct.recordMutations = new ArrayList<RecordMutation>(_list123.size);
          for (int _i124 = 0; _i124 < _list123.size; ++_i124)
          {
            RecordMutation _elem125; // required
            _elem125 = new RecordMutation();
View Full Code Here

  private static class TableDescriptorTupleScheme extends TupleScheme<TableDescriptor> {

    @Override
    public void write(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, TableDescriptor struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol oprot = (TTupleProtocol) prot;
      BitSet optionals = new BitSet();
      if (struct.isSetEnabled()) {
        optionals.set(0);
      }
      if (struct.isSetShardCount()) {
        optionals.set(1);
      }
      if (struct.isSetTableUri()) {
        optionals.set(2);
      }
      if (struct.isSetCluster()) {
        optionals.set(3);
      }
      if (struct.isSetName()) {
        optionals.set(4);
      }
      if (struct.isSetSimilarityClass()) {
        optionals.set(5);
      }
      if (struct.isSetBlockCaching()) {
        optionals.set(6);
      }
      if (struct.isSetBlockCachingFileTypes()) {
        optionals.set(7);
      }
      if (struct.isSetReadOnly()) {
        optionals.set(8);
      }
      if (struct.isSetPreCacheCols()) {
        optionals.set(9);
      }
      if (struct.isSetTableProperties()) {
        optionals.set(10);
      }
      if (struct.isSetStrictTypes()) {
        optionals.set(11);
      }
      if (struct.isSetDefaultMissingFieldType()) {
        optionals.set(12);
      }
      if (struct.isSetDefaultMissingFieldLessIndexing()) {
        optionals.set(13);
      }
      if (struct.isSetDefaultMissingFieldProps()) {
        optionals.set(14);
      }
      oprot.writeBitSet(optionals, 15);
      if (struct.isSetEnabled()) {
        oprot.writeBool(struct.enabled);
      }
      if (struct.isSetShardCount()) {
        oprot.writeI32(struct.shardCount);
      }
      if (struct.isSetTableUri()) {
        oprot.writeString(struct.tableUri);
      }
      if (struct.isSetCluster()) {
        oprot.writeString(struct.cluster);
      }
      if (struct.isSetName()) {
        oprot.writeString(struct.name);
      }
      if (struct.isSetSimilarityClass()) {
        oprot.writeString(struct.similarityClass);
      }
      if (struct.isSetBlockCaching()) {
        oprot.writeBool(struct.blockCaching);
      }
      if (struct.isSetBlockCachingFileTypes()) {
        {
          oprot.writeI32(struct.blockCachingFileTypes.size());
          for (String _iter184 : struct.blockCachingFileTypes)
          {
            oprot.writeString(_iter184);
          }
        }
      }
      if (struct.isSetReadOnly()) {
        oprot.writeBool(struct.readOnly);
      }
      if (struct.isSetPreCacheCols()) {
        {
          oprot.writeI32(struct.preCacheCols.size());
          for (String _iter185 : struct.preCacheCols)
          {
            oprot.writeString(_iter185);
          }
        }
      }
      if (struct.isSetTableProperties()) {
        {
          oprot.writeI32(struct.tableProperties.size());
          for (Map.Entry<String, String> _iter186 : struct.tableProperties.entrySet())
          {
            oprot.writeString(_iter186.getKey());
            oprot.writeString(_iter186.getValue());
          }
        }
      }
      if (struct.isSetStrictTypes()) {
        oprot.writeBool(struct.strictTypes);
      }
      if (struct.isSetDefaultMissingFieldType()) {
        oprot.writeString(struct.defaultMissingFieldType);
      }
      if (struct.isSetDefaultMissingFieldLessIndexing()) {
        oprot.writeBool(struct.defaultMissingFieldLessIndexing);
      }
      if (struct.isSetDefaultMissingFieldProps()) {
        {
          oprot.writeI32(struct.defaultMissingFieldProps.size());
          for (Map.Entry<String, String> _iter187 : struct.defaultMissingFieldProps.entrySet())
          {
            oprot.writeString(_iter187.getKey());
            oprot.writeString(_iter187.getValue());
          }
        }
      }
    }
View Full Code Here

      }
    }

    @Override
    public void read(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, TableDescriptor struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol iprot = (TTupleProtocol) prot;
      BitSet incoming = iprot.readBitSet(15);
      if (incoming.get(0)) {
        struct.enabled = iprot.readBool();
        struct.setEnabledIsSet(true);
      }
      if (incoming.get(1)) {
        struct.shardCount = iprot.readI32();
        struct.setShardCountIsSet(true);
      }
      if (incoming.get(2)) {
        struct.tableUri = iprot.readString();
        struct.setTableUriIsSet(true);
      }
      if (incoming.get(3)) {
        struct.cluster = iprot.readString();
        struct.setClusterIsSet(true);
      }
      if (incoming.get(4)) {
        struct.name = iprot.readString();
        struct.setNameIsSet(true);
      }
      if (incoming.get(5)) {
        struct.similarityClass = iprot.readString();
        struct.setSimilarityClassIsSet(true);
      }
      if (incoming.get(6)) {
        struct.blockCaching = iprot.readBool();
        struct.setBlockCachingIsSet(true);
      }
      if (incoming.get(7)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TSet _set188 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TSet(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, iprot.readI32());
          struct.blockCachingFileTypes = new HashSet<String>(2*_set188.size);
          for (int _i189 = 0; _i189 < _set188.size; ++_i189)
          {
            String _elem190; // required
            _elem190 = iprot.readString();
            struct.blockCachingFileTypes.add(_elem190);
          }
        }
        struct.setBlockCachingFileTypesIsSet(true);
      }
      if (incoming.get(8)) {
        struct.readOnly = iprot.readBool();
        struct.setReadOnlyIsSet(true);
      }
      if (incoming.get(9)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TList _list191 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TList(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, iprot.readI32());
          struct.preCacheCols = new ArrayList<String>(_list191.size);
          for (int _i192 = 0; _i192 < _list191.size; ++_i192)
          {
            String _elem193; // required
            _elem193 = iprot.readString();
            struct.preCacheCols.add(_elem193);
          }
        }
        struct.setPreCacheColsIsSet(true);
      }
      if (incoming.get(10)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map194 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, iprot.readI32());
          struct.tableProperties = new HashMap<String,String>(2*_map194.size);
          for (int _i195 = 0; _i195 < _map194.size; ++_i195)
          {
            String _key196; // optional
            String _val197; // required
            _key196 = iprot.readString();
            _val197 = iprot.readString();
            struct.tableProperties.put(_key196, _val197);
          }
        }
        struct.setTablePropertiesIsSet(true);
      }
      if (incoming.get(11)) {
        struct.strictTypes = iprot.readBool();
        struct.setStrictTypesIsSet(true);
      }
      if (incoming.get(12)) {
        struct.defaultMissingFieldType = iprot.readString();
        struct.setDefaultMissingFieldTypeIsSet(true);
      }
      if (incoming.get(13)) {
        struct.defaultMissingFieldLessIndexing = iprot.readBool();
        struct.setDefaultMissingFieldLessIndexingIsSet(true);
      }
      if (incoming.get(14)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map198 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, iprot.readI32());
          struct.defaultMissingFieldProps = new HashMap<String,String>(2*_map198.size);
          for (int _i199 = 0; _i199 < _map198.size; ++_i199)
          {
            String _key200; // optional
            String _val201; // required
            _key200 = iprot.readString();
            _val201 = iprot.readString();
            struct.defaultMissingFieldProps.put(_key200, _val201);
          }
        }
        struct.setDefaultMissingFieldPropsIsSet(true);
      }
View Full Code Here

  private static class SchemaTupleScheme extends TupleScheme<Schema> {

    @Override
    public void write(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, Schema struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol oprot = (TTupleProtocol) prot;
      BitSet optionals = new BitSet();
      if (struct.isSetTable()) {
        optionals.set(0);
      }
      if (struct.isSetFamilies()) {
        optionals.set(1);
      }
      oprot.writeBitSet(optionals, 2);
      if (struct.isSetTable()) {
        oprot.writeString(struct.table);
      }
      if (struct.isSetFamilies()) {
        {
          oprot.writeI32(struct.families.size());
          for (Map.Entry<String, Map<String,ColumnDefinition>> _iter156 : struct.families.entrySet())
          {
            oprot.writeString(_iter156.getKey());
            {
              oprot.writeI32(_iter156.getValue().size());
              for (Map.Entry<String, ColumnDefinition> _iter157 : _iter156.getValue().entrySet())
              {
                oprot.writeString(_iter157.getKey());
                _iter157.getValue().write(oprot);
              }
            }
          }
        }
View Full Code Here

      }
    }

    @Override
    public void read(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, Schema struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol iprot = (TTupleProtocol) prot;
      BitSet incoming = iprot.readBitSet(2);
      if (incoming.get(0)) {
        struct.table = iprot.readString();
        struct.setTableIsSet(true);
      }
      if (incoming.get(1)) {
        {
          org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map158 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.MAP, iprot.readI32());
          struct.families = new HashMap<String,Map<String,ColumnDefinition>>(2*_map158.size);
          for (int _i159 = 0; _i159 < _map158.size; ++_i159)
          {
            String _key160; // optional
            Map<String,ColumnDefinition> _val161; // required
            _key160 = iprot.readString();
            {
              org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap _map162 = new org.apache.blur.thirdparty.thrift_0_9_0.protocol.TMap(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRING, org.apache.blur.thirdparty.thrift_0_9_0.protocol.TType.STRUCT, iprot.readI32());
              _val161 = new HashMap<String,ColumnDefinition>(2*_map162.size);
              for (int _i163 = 0; _i163 < _map162.size; ++_i163)
              {
                String _key164; // optional
                ColumnDefinition _val165; // required
                _key164 = iprot.readString();
                _val165 = new ColumnDefinition();
                _val165.read(iprot);
                _val161.put(_key164, _val165);
              }
            }
View Full Code Here

  private static class FetchRowResultTupleScheme extends TupleScheme<FetchRowResult> {

    @Override
    public void write(org.apache.blur.thirdparty.thrift_0_9_0.protocol.TProtocol prot, FetchRowResult struct) throws org.apache.blur.thirdparty.thrift_0_9_0.TException {
      TTupleProtocol oprot = (TTupleProtocol) prot;
      BitSet optionals = new BitSet();
      if (struct.isSetRow()) {
        optionals.set(0);
      }
      if (struct.isSetStartRecord()) {
        optionals.set(1);
      }
      if (struct.isSetMaxRecordsToFetch()) {
        optionals.set(2);
      }
      if (struct.isSetMoreRecordsToFetch()) {
        optionals.set(3);
      }
      if (struct.isSetTotalRecords()) {
        optionals.set(4);
      }
      oprot.writeBitSet(optionals, 5);
      if (struct.isSetRow()) {
        struct.row.write(oprot);
      }
      if (struct.isSetStartRecord()) {
        oprot.writeI32(struct.startRecord);
      }
      if (struct.isSetMaxRecordsToFetch()) {
        oprot.writeI32(struct.maxRecordsToFetch);
      }
      if (struct.isSetMoreRecordsToFetch()) {
        oprot.writeBool(struct.moreRecordsToFetch);
      }
      if (struct.isSetTotalRecords()) {
        oprot.writeI32(struct.totalRecords);
      }
    }
View Full Code Here

TOP

Related Classes of org.apache.blur.thirdparty.thrift_0_9_0.protocol.TTupleProtocol

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.