Class FileSerializedIO

  • All Implemented Interfaces:
    SerializedIO

    public class FileSerializedIO
    extends java.lang.Object
    implements SerializedIO
    • Constructor Summary

      Constructors 
      Constructor Description
      FileSerializedIO​(java.lang.String filepath, boolean compressed)  
    • Method Summary

      Modifier and Type Method Description
      java.util.Optional<java.nio.ByteBuffer> read()
      Read the object
      void write​(java.nio.ByteBuffer buffer)
      Write content to an object
      • Methods inherited from class java.lang.Object

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

      • FileSerializedIO

        public FileSerializedIO​(java.lang.String filepath,
                                boolean compressed)
    • Method Detail

      • write

        public void write​(java.nio.ByteBuffer buffer)
        Description copied from interface: SerializedIO
        Write content to an object
        Specified by:
        write in interface SerializedIO
        Parameters:
        buffer - the content to be written to the object111
      • read

        public java.util.Optional<java.nio.ByteBuffer> read()
        Description copied from interface: SerializedIO
        Read the object
        Specified by:
        read in interface SerializedIO
        Returns:
        An optional ByteBuffer that contains the content of the object (or Empty if any error occurred)