类 InputSubstream

  • 所有已实现的接口:
    Releasable, java.io.Closeable, java.lang.AutoCloseable

    public final class InputSubstream
    extends SdkFilterInputStream
    Filtered input stream implementation that exposes a range of an input stream as a new input stream.
    • 字段概要

      • 从类继承的字段 java.io.FilterInputStream

        in
    • 构造器概要

      构造器 
      构造器 说明
      InputSubstream​(java.io.InputStream in, long offset, long length, boolean closeSourceStream)
      Constructs a new InputSubstream so that when callers start reading from this stream they'll start at the specified offset in the real stream and after they've read the specified length, this stream will look empty.
    • 方法概要

      所有方法 实例方法 具体方法 
      修饰符和类型 方法 说明
      int available()  
      void close()  
      void mark​(int readlimit)  
      int read()  
      int read​(byte[] b, int off, int len)  
      void reset()  
      • 从类继承的方法 java.io.FilterInputStream

        read
      • 从类继承的方法 java.io.InputStream

        nullInputStream, readAllBytes, readNBytes, readNBytes, transferTo
      • 从类继承的方法 java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • 构造器详细资料

      • InputSubstream

        public InputSubstream​(java.io.InputStream in,
                              long offset,
                              long length,
                              boolean closeSourceStream)
        Constructs a new InputSubstream so that when callers start reading from this stream they'll start at the specified offset in the real stream and after they've read the specified length, this stream will look empty.
        参数:
        in - The input stream to wrap.
        offset - The offset, in bytes, into the specified input stream at which to start reading data.
        length - The length, in bytes, of the specified input stream to return through this stream.
        closeSourceStream - True if the wrapped InputStream should be closed when this InputSubstream is closed.
    • 方法详细资料

      • read

        public int read()
                 throws java.io.IOException
        覆盖:
        read 在类中 SdkFilterInputStream
        抛出:
        java.io.IOException
      • read

        public int read​(byte[] b,
                        int off,
                        int len)
                 throws java.io.IOException
        覆盖:
        read 在类中 SdkFilterInputStream
        抛出:
        java.io.IOException
      • reset

        public void reset()
                   throws java.io.IOException
        覆盖:
        reset 在类中 SdkFilterInputStream
        抛出:
        java.io.IOException
      • close

        public void close()
                   throws java.io.IOException
        指定者:
        close 在接口中 java.lang.AutoCloseable
        指定者:
        close 在接口中 java.io.Closeable
        覆盖:
        close 在类中 SdkFilterInputStream
        抛出:
        java.io.IOException