类java.nio.channels.spi.AbstractInterruptibleChannel源码实例Demo

下面列出了怎么用java.nio.channels.spi.AbstractInterruptibleChannel的API类实例代码及写法,或者点击链接到github查看源代码。

源代码1 项目: pravega   文件: FileSystemMockTests.java
private static void fixChannelMock(AbstractInterruptibleChannel mockFileChannel) throws Exception {
    // Note : This is a workaround for NullPointerException.
    // This will break when jdk decides to change implementation.
    Field closeLockField = AbstractInterruptibleChannel.class.getDeclaredField("closeLock");
    closeLockField.setAccessible(true);
    closeLockField.set(mockFileChannel, new Object());
}
 
 类所在包
 类方法
 同包方法