Class ByteArrayInputStream

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

    public class ByteArrayInputStream
    extends java.io.InputStream
    Author:
    Riyad Kalla ([email protected])
    • Method Detail

      • valueOf

        public static ByteArrayInputStream valueOf​(byte[] data)
                                            throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • valueOf

        public static ByteArrayInputStream valueOf​(byte[] data,
                                                   int offset,
                                                   int length)
                                            throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • available

        public int available()
                      throws java.io.IOException
        Overrides:
        available in class java.io.InputStream
        Throws:
        java.io.IOException
      • skip

        public long skip​(long number)
                  throws java.lang.IllegalArgumentException,
                         java.io.IOException
        Overrides:
        skip in class java.io.InputStream
        Throws:
        java.lang.IllegalArgumentException
        java.io.IOException
      • read

        public int read()
                 throws java.io.IOException
        Specified by:
        read in class java.io.InputStream
        Throws:
        java.io.IOException
      • read

        public int read​(byte[] buffer,
                        int offset,
                        int length)
                 throws java.lang.IllegalArgumentException,
                        java.io.IOException
        Overrides:
        read in class java.io.InputStream
        Throws:
        java.lang.IllegalArgumentException
        java.io.IOException
      • markSupported

        public boolean markSupported()
        Overrides:
        markSupported in class java.io.InputStream
      • mark

        public void mark​(int readlimit)
        Overrides:
        mark in class java.io.InputStream
      • reset

        public void reset()
                   throws java.io.IOException
        Overrides:
        reset in class java.io.InputStream
        Throws:
        java.io.IOException
      • reset

        public void reset​(int offset)
                   throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • reset

        public void reset​(byte[] data)
                   throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • reset

        public void reset​(byte[] data,
                          int offset,
                          int length)
                   throws java.lang.IllegalArgumentException
        Throws:
        java.lang.IllegalArgumentException
      • getArray

        public byte[] getArray()
      • getOffset

        public int getOffset()
      • getLength

        public int getLength()