Java 类org.apache.hadoop.hbase.codec.prefixtree.encode.other.LongEncoder 实例源码

项目:ditb    文件:TestTimestampEncoder.java   
public TestTimestampEncoder(TestTimestampData testTimestamps) throws IOException {
  this.timestamps = testTimestamps;
  this.blockMeta = new PrefixTreeBlockMeta();
  this.blockMeta.setNumMetaBytes(0);
  this.blockMeta.setNumRowBytes(0);
  this.blockMeta.setNumQualifierBytes(0);
  this.encoder = new LongEncoder();
  for (Long ts : testTimestamps.getInputs()) {
    encoder.add(ts);
  }
  encoder.compile();
  blockMeta.setTimestampFields(encoder);
  bytes = encoder.getByteArray();
  decoder = new TimestampDecoder();
  decoder.initOnBlock(blockMeta, bytes);
}
项目:pbase    文件:TestTimestampEncoder.java   
public TestTimestampEncoder(TestTimestampData testTimestamps) throws IOException {
  this.timestamps = testTimestamps;
  this.blockMeta = new PrefixTreeBlockMeta();
  this.blockMeta.setNumMetaBytes(0);
  this.blockMeta.setNumRowBytes(0);
  this.blockMeta.setNumQualifierBytes(0);
  this.encoder = new LongEncoder();
  for (Long ts : testTimestamps.getInputs()) {
    encoder.add(ts);
  }
  encoder.compile();
  blockMeta.setTimestampFields(encoder);
  bytes = encoder.getByteArray();
  decoder = new TimestampDecoder();
  decoder.initOnBlock(blockMeta, bytes);
}
项目:HIndex    文件:TestTimestampEncoder.java   
public TestTimestampEncoder(TestTimestampData testTimestamps) throws IOException {
  this.timestamps = testTimestamps;
  this.blockMeta = new PrefixTreeBlockMeta();
  this.blockMeta.setNumMetaBytes(0);
  this.blockMeta.setNumRowBytes(0);
  this.blockMeta.setNumQualifierBytes(0);
  this.encoder = new LongEncoder();
  for (Long ts : testTimestamps.getInputs()) {
    encoder.add(ts);
  }
  encoder.compile();
  blockMeta.setTimestampFields(encoder);
  bytes = encoder.getByteArray();
  decoder = new TimestampDecoder();
  decoder.initOnBlock(blockMeta, bytes);
}
项目:PyroDB    文件:TestTimestampEncoder.java   
public TestTimestampEncoder(TestTimestampData testTimestamps) throws IOException {
  this.timestamps = testTimestamps;
  this.blockMeta = new PrefixTreeBlockMeta();
  this.blockMeta.setNumMetaBytes(0);
  this.blockMeta.setNumRowBytes(0);
  this.blockMeta.setNumQualifierBytes(0);
  this.encoder = new LongEncoder();
  for (Long ts : testTimestamps.getInputs()) {
    encoder.add(ts);
  }
  encoder.compile();
  blockMeta.setTimestampFields(encoder);
  bytes = encoder.getByteArray();
  decoder = new TimestampDecoder();
  decoder.initOnBlock(blockMeta, bytes);
}
项目:c5    文件:TestTimestampEncoder.java   
public TestTimestampEncoder(TestTimestampData testTimestamps) throws IOException {
  this.timestamps = testTimestamps;
  this.blockMeta = new PrefixTreeBlockMeta();
  this.blockMeta.setNumMetaBytes(0);
  this.blockMeta.setNumRowBytes(0);
  this.blockMeta.setNumQualifierBytes(0);
  this.encoder = new LongEncoder();
  for (Long ts : testTimestamps.getInputs()) {
    encoder.add(ts);
  }
  encoder.compile();
  blockMeta.setTimestampFields(encoder);
  bytes = encoder.getByteArray();
  decoder = new TimestampDecoder();
  decoder.initOnBlock(blockMeta, bytes);
}
项目:ditb    文件:PrefixTreeEncoder.java   
/***************** construct ***********************/

  public PrefixTreeEncoder(OutputStream outputStream, boolean includeMvccVersion) {
    // used during cell accumulation
    this.blockMeta = new PrefixTreeBlockMeta();
    this.rowRange = new SimpleMutableByteRange();
    this.familyRange = new SimpleMutableByteRange();
    this.qualifierRange = new SimpleMutableByteRange();
    this.timestamps = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.mvccVersions = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.typeBytes = new byte[INITIAL_PER_CELL_ARRAY_SIZES];
    this.valueOffsets = new int[INITIAL_PER_CELL_ARRAY_SIZES];
    this.values = new byte[VALUE_BUFFER_INIT_SIZE];

    // used during compilation
    this.familyDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.qualifierDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.timestampEncoder = new LongEncoder();
    this.mvccVersionEncoder = new LongEncoder();
    this.cellTypeEncoder = new CellTypeEncoder();
    this.rowTokenizer = new Tokenizer();
    this.familyTokenizer = new Tokenizer();
    this.qualifierTokenizer = new Tokenizer();
    this.rowWriter = new RowSectionWriter();
    this.familyWriter = new ColumnSectionWriter();
    this.qualifierWriter = new ColumnSectionWriter();
    initializeTagHelpers();

    reset(outputStream, includeMvccVersion);
  }
项目:pbase    文件:PrefixTreeEncoder.java   
/***************** construct ***********************/

  public PrefixTreeEncoder(OutputStream outputStream, boolean includeMvccVersion) {
    // used during cell accumulation
    this.blockMeta = new PrefixTreeBlockMeta();
    this.rowRange = new SimpleMutableByteRange();
    this.familyRange = new SimpleMutableByteRange();
    this.qualifierRange = new SimpleMutableByteRange();
    this.timestamps = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.mvccVersions = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.typeBytes = new byte[INITIAL_PER_CELL_ARRAY_SIZES];
    this.valueOffsets = new int[INITIAL_PER_CELL_ARRAY_SIZES];
    this.values = new byte[VALUE_BUFFER_INIT_SIZE];

    // used during compilation
    this.familyDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.qualifierDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.timestampEncoder = new LongEncoder();
    this.mvccVersionEncoder = new LongEncoder();
    this.cellTypeEncoder = new CellTypeEncoder();
    this.rowTokenizer = new Tokenizer();
    this.familyTokenizer = new Tokenizer();
    this.qualifierTokenizer = new Tokenizer();
    this.rowWriter = new RowSectionWriter();
    this.familyWriter = new ColumnSectionWriter();
    this.qualifierWriter = new ColumnSectionWriter();
    initializeTagHelpers();

    reset(outputStream, includeMvccVersion);
  }
项目:HIndex    文件:PrefixTreeEncoder.java   
/***************** construct ***********************/

  public PrefixTreeEncoder(OutputStream outputStream, boolean includeMvccVersion) {
    // used during cell accumulation
    this.blockMeta = new PrefixTreeBlockMeta();
    this.rowRange = new SimpleByteRange();
    this.familyRange = new SimpleByteRange();
    this.qualifierRange = new SimpleByteRange();
    this.timestamps = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.mvccVersions = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.typeBytes = new byte[INITIAL_PER_CELL_ARRAY_SIZES];
    this.valueOffsets = new int[INITIAL_PER_CELL_ARRAY_SIZES];
    this.values = new byte[VALUE_BUFFER_INIT_SIZE];

    // used during compilation
    this.familyDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.qualifierDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.timestampEncoder = new LongEncoder();
    this.mvccVersionEncoder = new LongEncoder();
    this.cellTypeEncoder = new CellTypeEncoder();
    this.rowTokenizer = new Tokenizer();
    this.familyTokenizer = new Tokenizer();
    this.qualifierTokenizer = new Tokenizer();
    this.rowWriter = new RowSectionWriter();
    this.familyWriter = new ColumnSectionWriter();
    this.qualifierWriter = new ColumnSectionWriter();
    initializeTagHelpers();

    reset(outputStream, includeMvccVersion);
  }
项目:PyroDB    文件:PrefixTreeEncoder.java   
/***************** construct ***********************/

  public PrefixTreeEncoder(OutputStream outputStream, boolean includeMvccVersion) {
    // used during cell accumulation
    this.blockMeta = new PrefixTreeBlockMeta();
    this.rowRange = new SimpleByteRange();
    this.familyRange = new SimpleByteRange();
    this.qualifierRange = new SimpleByteRange();
    this.timestamps = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.mvccVersions = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.typeBytes = new byte[INITIAL_PER_CELL_ARRAY_SIZES];
    this.valueOffsets = new int[INITIAL_PER_CELL_ARRAY_SIZES];
    this.values = new byte[VALUE_BUFFER_INIT_SIZE];

    // used during compilation
    this.familyDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.qualifierDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.timestampEncoder = new LongEncoder();
    this.mvccVersionEncoder = new LongEncoder();
    this.cellTypeEncoder = new CellTypeEncoder();
    this.rowTokenizer = new Tokenizer();
    this.familyTokenizer = new Tokenizer();
    this.qualifierTokenizer = new Tokenizer();
    this.rowWriter = new RowSectionWriter();
    this.familyWriter = new ColumnSectionWriter();
    this.qualifierWriter = new ColumnSectionWriter();
    initializeTagHelpers();

    reset(outputStream, includeMvccVersion);
  }
项目:c5    文件:PrefixTreeEncoder.java   
/***************** construct ***********************/

  public PrefixTreeEncoder(OutputStream outputStream, boolean includeMvccVersion) {
    // used during cell accumulation
    this.blockMeta = new PrefixTreeBlockMeta();
    this.rowRange = new SimpleByteRange();
    this.familyRange = new SimpleByteRange();
    this.qualifierRange = new SimpleByteRange();
    this.timestamps = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.mvccVersions = new long[INITIAL_PER_CELL_ARRAY_SIZES];
    this.typeBytes = new byte[INITIAL_PER_CELL_ARRAY_SIZES];
    this.valueOffsets = new int[INITIAL_PER_CELL_ARRAY_SIZES];
    this.values = new byte[VALUE_BUFFER_INIT_SIZE];

    // used during compilation
    this.familyDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.qualifierDeduplicator = USE_HASH_COLUMN_SORTER ? new ByteRangeHashSet()
        : new ByteRangeTreeSet();
    this.timestampEncoder = new LongEncoder();
    this.mvccVersionEncoder = new LongEncoder();
    this.cellTypeEncoder = new CellTypeEncoder();
    this.rowTokenizer = new Tokenizer();
    this.familyTokenizer = new Tokenizer();
    this.qualifierTokenizer = new Tokenizer();
    this.rowWriter = new RowSectionWriter();
    this.familyWriter = new ColumnSectionWriter();
    this.qualifierWriter = new ColumnSectionWriter();

    reset(outputStream, includeMvccVersion);
  }
项目:ditb    文件:PrefixTreeBlockMeta.java   
public void setTimestampFields(LongEncoder encoder){
  this.minTimestamp = encoder.getMin();
  this.timestampIndexWidth = encoder.getBytesPerIndex();
  this.timestampDeltaWidth = encoder.getBytesPerDelta();
  this.numTimestampBytes = encoder.getTotalCompressedBytes();
}
项目:ditb    文件:PrefixTreeBlockMeta.java   
public void setMvccVersionFields(LongEncoder encoder){
  this.minMvccVersion = encoder.getMin();
  this.mvccVersionIndexWidth = encoder.getBytesPerIndex();
  this.mvccVersionDeltaWidth = encoder.getBytesPerDelta();
  this.numMvccVersionBytes = encoder.getTotalCompressedBytes();
}
项目:ditb    文件:PrefixTreeEncoder.java   
public LongEncoder getTimestampEncoder() {
  return timestampEncoder;
}
项目:ditb    文件:PrefixTreeEncoder.java   
public LongEncoder getMvccVersionEncoder() {
  return mvccVersionEncoder;
}
项目:pbase    文件:PrefixTreeBlockMeta.java   
public void setTimestampFields(LongEncoder encoder){
  this.minTimestamp = encoder.getMin();
  this.timestampIndexWidth = encoder.getBytesPerIndex();
  this.timestampDeltaWidth = encoder.getBytesPerDelta();
  this.numTimestampBytes = encoder.getTotalCompressedBytes();
}
项目:pbase    文件:PrefixTreeBlockMeta.java   
public void setMvccVersionFields(LongEncoder encoder){
  this.minMvccVersion = encoder.getMin();
  this.mvccVersionIndexWidth = encoder.getBytesPerIndex();
  this.mvccVersionDeltaWidth = encoder.getBytesPerDelta();
  this.numMvccVersionBytes = encoder.getTotalCompressedBytes();
}
项目:pbase    文件:PrefixTreeEncoder.java   
public LongEncoder getTimestampEncoder() {
  return timestampEncoder;
}
项目:pbase    文件:PrefixTreeEncoder.java   
public LongEncoder getMvccVersionEncoder() {
  return mvccVersionEncoder;
}
项目:HIndex    文件:PrefixTreeBlockMeta.java   
public void setTimestampFields(LongEncoder encoder){
  this.minTimestamp = encoder.getMin();
  this.timestampIndexWidth = encoder.getBytesPerIndex();
  this.timestampDeltaWidth = encoder.getBytesPerDelta();
  this.numTimestampBytes = encoder.getTotalCompressedBytes();
}
项目:HIndex    文件:PrefixTreeBlockMeta.java   
public void setMvccVersionFields(LongEncoder encoder){
  this.minMvccVersion = encoder.getMin();
  this.mvccVersionIndexWidth = encoder.getBytesPerIndex();
  this.mvccVersionDeltaWidth = encoder.getBytesPerDelta();
  this.numMvccVersionBytes = encoder.getTotalCompressedBytes();
}
项目:HIndex    文件:PrefixTreeEncoder.java   
public LongEncoder getTimestampEncoder() {
  return timestampEncoder;
}
项目:HIndex    文件:PrefixTreeEncoder.java   
public LongEncoder getMvccVersionEncoder() {
  return mvccVersionEncoder;
}
项目:PyroDB    文件:PrefixTreeBlockMeta.java   
public void setTimestampFields(LongEncoder encoder){
  this.minTimestamp = encoder.getMin();
  this.timestampIndexWidth = encoder.getBytesPerIndex();
  this.timestampDeltaWidth = encoder.getBytesPerDelta();
  this.numTimestampBytes = encoder.getTotalCompressedBytes();
}
项目:PyroDB    文件:PrefixTreeBlockMeta.java   
public void setMvccVersionFields(LongEncoder encoder){
  this.minMvccVersion = encoder.getMin();
  this.mvccVersionIndexWidth = encoder.getBytesPerIndex();
  this.mvccVersionDeltaWidth = encoder.getBytesPerDelta();
  this.numMvccVersionBytes = encoder.getTotalCompressedBytes();
}
项目:PyroDB    文件:PrefixTreeEncoder.java   
public LongEncoder getTimestampEncoder() {
  return timestampEncoder;
}
项目:PyroDB    文件:PrefixTreeEncoder.java   
public LongEncoder getMvccVersionEncoder() {
  return mvccVersionEncoder;
}
项目:c5    文件:PrefixTreeBlockMeta.java   
public void setTimestampFields(LongEncoder encoder){
  this.minTimestamp = encoder.getMin();
  this.timestampIndexWidth = encoder.getBytesPerIndex();
  this.timestampDeltaWidth = encoder.getBytesPerDelta();
  this.numTimestampBytes = encoder.getTotalCompressedBytes();
}
项目:c5    文件:PrefixTreeBlockMeta.java   
public void setMvccVersionFields(LongEncoder encoder){
  this.minMvccVersion = encoder.getMin();
  this.mvccVersionIndexWidth = encoder.getBytesPerIndex();
  this.mvccVersionDeltaWidth = encoder.getBytesPerDelta();
  this.numMvccVersionBytes = encoder.getTotalCompressedBytes();
}
项目:c5    文件:PrefixTreeEncoder.java   
public LongEncoder getTimestampEncoder() {
  return timestampEncoder;
}
项目:c5    文件:PrefixTreeEncoder.java   
public LongEncoder getMvccVersionEncoder() {
  return mvccVersionEncoder;
}