Class IntegerType

  • All Implemented Interfaces:
    java.io.Serializable, ColumnType<java.lang.Integer>

    public class IntegerType
    extends java.lang.Object
    implements ColumnType<java.lang.Integer>
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int TYPE_SIZE  
    • Constructor Summary

      Constructors 
      Constructor Description
      IntegerType()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Integer parseColumn​(java.nio.ByteBuffer buffer, int length)
      Parses a value of this type from buffer.
      java.nio.ByteBuffer serialize​(java.lang.Integer value)
      Serialize into ByteBuffer and keeps the position at beginning of ByteBuffer
      • Methods inherited from class java.lang.Object

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

      • IntegerType

        public IntegerType()
    • Method Detail

      • parseColumn

        public java.lang.Integer parseColumn​(java.nio.ByteBuffer buffer,
                                             int length)
        Description copied from interface: ColumnType
        Parses a value of this type from buffer. Value will be parsed from current position of the buffer. After completion of the function, position will be moved by "length" bytes.
        Specified by:
        parseColumn in interface ColumnType<java.lang.Integer>
        Parameters:
        buffer - Buffer to parse column from
        length - Serialized value size in buffer is as big as length
        Returns:
        value as Java type
      • serialize

        public java.nio.ByteBuffer serialize​(java.lang.Integer value)
        Description copied from interface: ColumnType
        Serialize into ByteBuffer and keeps the position at beginning of ByteBuffer
        Specified by:
        serialize in interface ColumnType<java.lang.Integer>
        Parameters:
        value - the value to serialize
        Returns:
        A ByteBuffer containing the serialized value