Class ByteArrayOutputStreamEx

  • All Implemented Interfaces:
    java.io.Closeable, java.io.Flushable, java.lang.AutoCloseable

    final class ByteArrayOutputStreamEx
    extends java.io.ByteArrayOutputStream
    ByteArrayOutputStream with access to its raw buffer.
    • Field Summary

      • Fields inherited from class java.io.ByteArrayOutputStream

        buf, count
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      byte[] getBuffer()  
      void readFrom​(java.io.InputStream is)
      Reads the given InputStream completely into the buffer.
      void set​(Base64Data dt, java.lang.String mimeType)  
      • Methods inherited from class java.io.ByteArrayOutputStream

        close, reset, size, toByteArray, toString, toString, toString, toString, write, write, writeBytes, writeTo
      • Methods inherited from class java.io.OutputStream

        flush, nullOutputStream, write
      • Methods inherited from class java.lang.Object

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

      • ByteArrayOutputStreamEx

        public ByteArrayOutputStreamEx()
      • ByteArrayOutputStreamEx

        public ByteArrayOutputStreamEx​(int size)
    • Method Detail

      • set

        public void set​(Base64Data dt,
                        java.lang.String mimeType)
      • getBuffer

        public byte[] getBuffer()
      • readFrom

        public void readFrom​(java.io.InputStream is)
                      throws java.io.IOException
        Reads the given InputStream completely into the buffer.
        Throws:
        java.io.IOException