标签: java nio
如何将FilterInputStream应用于NIO通道,特别是从RandomAccessFile获取的FileChannel?
答案 0 :(得分:1)
import java.nio.channels.*; InputStream in = new MyFilterInputStream(Channels.newInputStream(channel));
但是为什么频道?
答案 1 :(得分:-1)
请按照以下工作示例:
Using FileChannel to random access to a File