Java Code Examples for org.apache.hadoop.hbase.util.Bytes.SIZEOF_DOUBLE

The following are Jave code examples for showing how to use SIZEOF_DOUBLE of the org.apache.hadoop.hbase.util.Bytes class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
+ Save this method
Example 1
Project: ditb   File: DoubleColumnInterpreter.java   View Source Code Vote up 5 votes
@Override
public Double getValue(byte[] colFamily, byte[] colQualifier, Cell c)
    throws IOException {
  if (c == null || c.getValueLength() != Bytes.SIZEOF_DOUBLE)
    return null;
  return Bytes.toDouble(c.getValueArray(), c.getValueOffset());
}
 
Example 2
Project: ditb   File: RawDouble.java   View Source Code Vote up 4 votes
@Override
public int encodedLength(Double val) { return Bytes.SIZEOF_DOUBLE; }
 
Example 3
Project: ditb   File: RawDouble.java   View Source Code Vote up 4 votes
@Override
public int skip(PositionedByteRange src) {
  src.setPosition(src.getPosition() + Bytes.SIZEOF_DOUBLE);
  return Bytes.SIZEOF_DOUBLE;
}