Class Serializers.UnsignedLongSerializer

  • Enclosing class:
    Serializers

    public static final class Serializers.UnsignedLongSerializer
    extends java.lang.Object
    Serialize longs in an "Unsigned" form. In reality, this encoding guarantees that the natural sort matches unsigned lexicographic sort (i.e. -1 before 0, etc).
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      long deserialize​(byte[] bytes)  
      long deserialize​(byte[] bytes, int offset)  
      byte[] serialize​(long value)  
      void serialize​(long value, byte[] bytes, int offset)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • UnsignedLongSerializer

        public UnsignedLongSerializer()
    • Method Detail

      • serialize

        public byte[] serialize​(long value)
      • serialize

        public void serialize​(long value,
                              byte[] bytes,
                              int offset)
      • deserialize

        public long deserialize​(byte[] bytes)
      • deserialize

        public long deserialize​(byte[] bytes,
                                int offset)