Class PrimitiveCodec


  • public final class PrimitiveCodec
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int INT_LENGTH  
      static int LONG_LENGTH  
    • Constructor Summary

      Constructors 
      Constructor Description
      PrimitiveCodec()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static int readInt​(byte[] buffer, int offset)  
      static int readInt​(java.io.ByteArrayInputStream in)  
      static long readLong​(byte[] buffer, int offset)  
      static long readLong​(java.io.ByteArrayInputStream in)  
      static void writeInt​(byte[] buffer, int offset, int val)  
      static void writeInt​(java.io.ByteArrayOutputStream out, int val)  
      static void writeLong​(byte[] buffer, int offset, long val)  
      static void writeLong​(byte[] buffer, long val)  
      static void writeLong​(java.io.ByteArrayOutputStream out, long val)  
      • Methods inherited from class java.lang.Object

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

      • PrimitiveCodec

        public PrimitiveCodec()
    • Method Detail

      • readInt

        public static final int readInt​(byte[] buffer,
                                        int offset)
      • readInt

        public static final int readInt​(java.io.ByteArrayInputStream in)
      • writeInt

        public static final void writeInt​(byte[] buffer,
                                          int offset,
                                          int val)
      • writeInt

        public static final void writeInt​(java.io.ByteArrayOutputStream out,
                                          int val)
      • writeLong

        public static final void writeLong​(byte[] buffer,
                                           long val)
      • writeLong

        public static final void writeLong​(byte[] buffer,
                                           int offset,
                                           long val)
      • writeLong

        public static final void writeLong​(java.io.ByteArrayOutputStream out,
                                           long val)
      • readLong

        public static final long readLong​(byte[] buffer,
                                          int offset)
      • readLong

        public static final long readLong​(java.io.ByteArrayInputStream in)