Class MemSeekableFile

java.lang.Object
com.zakgof.velvetvideo.MemSeekableFile
All Implemented Interfaces:
ISeekableOutput, java.lang.AutoCloseable

public class MemSeekableFile
extends java.lang.Object
implements ISeekableOutput
  • Constructor Summary

    Constructors 
    Constructor Description
    MemSeekableFile()  
  • Method Summary

    Modifier and Type Method Description
    void close()
    Closes the output stream and frees the resources.
    void seek​(long position)
    Seeks the write pointer to a specified position.
    byte[] toBytes()  
    void write​(byte[] bytes)
    Writes bytes from bytes array into the output stream.

    Methods inherited from class java.lang.Object

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

  • Method Details

    • write

      public void write​(byte[] bytes)
      Description copied from interface: ISeekableOutput
      Writes bytes from bytes array into the output stream.
      Specified by:
      write in interface ISeekableOutput
      Parameters:
      bytes - buffer to write data from
    • seek

      public void seek​(long position)
      Description copied from interface: ISeekableOutput
      Seeks the write pointer to a specified position.
      Specified by:
      seek in interface ISeekableOutput
      Parameters:
      position - position to seek in bytes from the stream beginning
    • close

      public void close()
      Description copied from interface: ISeekableOutput
      Closes the output stream and frees the resources.
      Specified by:
      close in interface java.lang.AutoCloseable
      Specified by:
      close in interface ISeekableOutput
    • toBytes

      public byte[] toBytes()