类 MemoryInputStream
- java.lang.Object
-
- java.io.InputStream
-
- cn.mcres.gyhhy.MXLib.io.MemoryInputStream
-
- 所有已实现的接口:
Closeable,AutoCloseable,Channel,ReadableByteChannel,WritableByteChannel
public class MemoryInputStream extends InputStream implements ReadableByteChannel, WritableByteChannel, Closeable, AutoCloseable
-
-
构造器概要
构造器 构造器 说明 MemoryInputStream()MemoryInputStream(boolean block)MemoryInputStream(byte[] warp)MemoryInputStream(byte[] warp, boolean block)MemoryInputStream(byte[] warp, int form, int length)MemoryInputStream(byte[] warp, int off, int length, boolean block)MemoryInputStream(int size)MemoryInputStream(int size, boolean block)
-
方法概要
修饰符和类型 方法 说明 OutputStreamasOutputStream()intavailable()voidclose()voidcloseAll()voidcloseOutputStream()voidflush()byte[]getByteArray()byte[]getContainer()已过时。ObjectgetLock()已过时。ObjectgetReadingLock()已过时。booleanisOpen()intlimit()已过时。static voidmain(String[] args)intposition()已过时。intread()intread(byte[] buf)intread(byte[] buf, int off, int leng)intread(ByteBuffer dst)voidreinit()longskip(long sk)voidwrite(byte[] data)voidwrite(byte[] buf, int off, int leng)voidwrite(int i)intwrite(ByteBuffer src)-
从类继承的方法 java.io.InputStream
mark, markSupported, nullInputStream, readAllBytes, readNBytes, readNBytes, reset, skipNBytes, transferTo
-
-
-
-
构造器详细资料
-
MemoryInputStream
public MemoryInputStream()
-
MemoryInputStream
public MemoryInputStream(int size)
-
MemoryInputStream
public MemoryInputStream(byte[] warp)
-
MemoryInputStream
public MemoryInputStream(byte[] warp, boolean block)
-
MemoryInputStream
public MemoryInputStream(byte[] warp, int form, int length)
-
MemoryInputStream
public MemoryInputStream(byte[] warp, int off, int length, boolean block)
-
MemoryInputStream
public MemoryInputStream(int size, boolean block)
-
MemoryInputStream
public MemoryInputStream(boolean block)
-
-
方法详细资料
-
flush
public void flush()
-
close
public void close()
- 指定者:
close在接口中AutoCloseable- 指定者:
close在接口中Channel- 指定者:
close在接口中Closeable- 覆盖:
close在类中InputStream
-
reinit
public void reinit() throws IOException- 抛出:
IOException
-
closeAll
public void closeAll()
-
closeOutputStream
public void closeOutputStream()
-
read
public int read(byte[] buf)
- 覆盖:
read在类中InputStream
-
getByteArray
public byte[] getByteArray()
-
write
public void write(byte[] buf, int off, int leng) throws IOException- 抛出:
IOException
-
write
public void write(int i) throws IOException- 抛出:
IOException
-
read
public int read(byte[] buf, int off, int leng)- 覆盖:
read在类中InputStream
-
read
public int read()
- 指定者:
read在类中InputStream
-
write
public void write(byte[] data) throws IOException- 抛出:
IOException
-
available
public int available()
- 覆盖:
available在类中InputStream
-
asOutputStream
public OutputStream asOutputStream()
-
read
public int read(ByteBuffer dst)
- 指定者:
read在接口中ReadableByteChannel
-
limit
@Deprecated public int limit()
已过时。
-
position
@Deprecated public int position()
已过时。
-
getContainer
@Deprecated public byte[] getContainer()
已过时。
-
getReadingLock
@Deprecated public Object getReadingLock()
已过时。
-
getLock
@Deprecated public Object getLock()
已过时。
-
skip
public long skip(long sk)
- 覆盖:
skip在类中InputStream
-
write
public int write(ByteBuffer src) throws IOException
- 指定者:
write在接口中WritableByteChannel- 抛出:
IOException
-
-