Package com.yahoo.io

Class BufferChain


  • public final class BufferChain
    extends java.lang.Object
    Data store for AbstractByteWriter. Tested in unit tests for ByteWriter.
    Author:
    Steinar Knutsen
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void append​(byte b)  
      void append​(byte[] alreadyEncoded)  
      void append​(byte[] alreadyEncoded, int offset, int length)  
      void append​(AbstractUtf8Array v)  
      void append​(java.nio.ByteBuffer alreadyEncoded)  
      void append​(java.nio.CharBuffer toEncode, java.nio.charset.CharsetEncoder encoder)  
      long appended()  
      void flush()  
      • Methods inherited from class java.lang.Object

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

      • append

        public void append​(byte b)
                    throws java.io.IOException
        Throws:
        java.io.IOException
      • append

        public void append​(AbstractUtf8Array v)
                    throws java.io.IOException
        Throws:
        java.io.IOException
      • append

        public void append​(byte[] alreadyEncoded)
                    throws java.io.IOException
        Throws:
        java.io.IOException
      • append

        public void append​(byte[] alreadyEncoded,
                           int offset,
                           int length)
                    throws java.io.IOException
        Throws:
        java.io.IOException
      • append

        public void append​(java.nio.ByteBuffer alreadyEncoded)
                    throws java.io.IOException
        Throws:
        java.io.IOException
      • append

        public void append​(java.nio.CharBuffer toEncode,
                           java.nio.charset.CharsetEncoder encoder)
                    throws java.io.IOException
        Throws:
        java.io.IOException
      • flush

        public void flush()
                   throws java.io.IOException
        Throws:
        java.io.IOException
      • appended

        public long appended()
        Returns:
        number of bytes written to this buffer