Class FloatLexicoder

java.lang.Object
org.apache.accumulo.core.client.lexicoder.AbstractEncoder<T>
org.apache.accumulo.core.client.lexicoder.impl.AbstractLexicoder<Float>
org.apache.accumulo.core.client.lexicoder.FloatLexicoder
All Implemented Interfaces:
Encoder<Float>, Lexicoder<Float>, org.apache.accumulo.core.iterators.TypedValueCombiner.Encoder<Float>

public class FloatLexicoder extends org.apache.accumulo.core.client.lexicoder.impl.AbstractLexicoder<Float>
A lexicoder for preserving the native Java sort order of Float values.
Since:
1.8.0
  • Constructor Details

    • FloatLexicoder

      public FloatLexicoder()
  • Method Details

    • encode

      public byte[] encode(Float f)
    • decode

      public Float decode(byte[] b)
      Specified by:
      decode in interface org.apache.accumulo.core.iterators.TypedValueCombiner.Encoder<Float>
      Overrides:
      decode in class AbstractEncoder<Float>
    • decodeUnchecked

      protected Float decodeUnchecked(byte[] b, int offset, int len) throws org.apache.accumulo.core.iterators.ValueFormatException
      Description copied from class: AbstractEncoder
      Decodes a byte array without checking if the offset and len exceed the bounds of the actual array.
      Specified by:
      decodeUnchecked in class AbstractEncoder<Float>
      Throws:
      org.apache.accumulo.core.iterators.ValueFormatException