Package i2p.susi.util

Interface Buffer

All Known Implementing Classes:
FileBuffer, GzipFileBuffer, MemoryBuffer, OutputStreamBuffer, ReadBuffer

public interface Buffer
Base interface for all Buffers. Data may only be read or written via streams, unless implemented via additional methods in subclasses.
Since:
0.9.34
  • Method Details

    • getInputStream

      InputStream getInputStream() throws IOException
      Throws:
      IOException
    • getOutputStream

      OutputStream getOutputStream() throws IOException
      Throws:
      IOException
    • readComplete

      void readComplete(boolean success)
      Top-level reader MUST call this to close the input stream.
    • writeComplete

      void writeComplete(boolean success)
      Writer MUST call this when done.
      Parameters:
      success - if false, deletes any resources
    • getLength

      int getLength()
    • getOffset

      int getOffset()