Package util

Class StreamReader

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable
    Direct Known Subclasses:
    SlimStreamReader

    public class StreamReader
    extends java.lang.Object
    implements java.io.Closeable
    • Constructor Detail

      • StreamReader

        public StreamReader​(java.io.InputStream input)
    • Method Detail

      • close

        public void close()
                   throws java.io.IOException
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable
        Throws:
        java.io.IOException
      • setTimeoutLimit

        public void setTimeoutLimit​(int timeout)
      • timeoutLimit

        public int timeoutLimit()
      • isTimeout

        public boolean isTimeout()
      • readLine

        public java.lang.String readLine()
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • readLineBytes

        public byte[] readLineBytes()
                             throws java.io.IOException
        Throws:
        java.io.IOException
      • read

        public java.lang.String read​(int count)
                              throws java.io.IOException
        Throws:
        java.io.IOException
      • readBytes

        public byte[] readBytes​(int count)
                         throws java.io.IOException
        Throws:
        java.io.IOException
      • copyBytes

        public void copyBytes​(int count,
                              java.io.OutputStream output)
                       throws java.io.IOException
        Throws:
        java.io.IOException
      • readUpTo

        public java.lang.String readUpTo​(java.lang.String boundary)
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • readBytesUpTo

        public byte[] readBytesUpTo​(java.lang.String boundary)
                             throws java.io.IOException
        Throws:
        java.io.IOException
      • copyBytesUpTo

        public void copyBytesUpTo​(java.lang.String boundary,
                                  java.io.OutputStream outputStream)
                           throws java.io.IOException
        Throws:
        java.io.IOException
      • byteCount

        public int byteCount()
      • getBufferedBytes

        public byte[] getBufferedBytes()
      • isEof

        public boolean isEof()
      • numberOfBytesConsumed

        public long numberOfBytesConsumed()
      • resetNumberOfBytesConsumed

        public void resetNumberOfBytesConsumed()