public class NativeDeviceChannel extends java.nio.channels.spi.AbstractSelectableChannel implements java.nio.channels.ByteChannel, NativeSelectableChannel
| Modifier and Type | Field and Description |
|---|---|
private int |
fd |
private boolean |
isFile |
private int |
validOps |
| Constructor and Description |
|---|
NativeDeviceChannel(int fd) |
NativeDeviceChannel(int fd,
boolean isFile) |
NativeDeviceChannel(java.nio.channels.spi.SelectorProvider provider,
int fd,
int ops,
boolean isFile) |
| Modifier and Type | Method and Description |
|---|---|
int |
getFD() |
protected void |
implCloseSelectableChannel() |
protected void |
implConfigureBlocking(boolean block) |
int |
read(java.nio.ByteBuffer dst) |
private static java.nio.channels.spi.SelectorProvider |
selectorProvider(boolean isFile) |
int |
validOps() |
int |
write(java.nio.ByteBuffer src) |
blockingLock, configureBlocking, implCloseChannel, isBlocking, isRegistered, keyFor, provider, registerbegin, close, end, isOpenprivate final int fd
private final int validOps
private final boolean isFile
public NativeDeviceChannel(int fd)
public NativeDeviceChannel(int fd,
boolean isFile)
public NativeDeviceChannel(java.nio.channels.spi.SelectorProvider provider,
int fd,
int ops,
boolean isFile)
private static java.nio.channels.spi.SelectorProvider selectorProvider(boolean isFile)
protected void implCloseSelectableChannel()
throws java.io.IOException
implCloseSelectableChannel in class java.nio.channels.spi.AbstractSelectableChanneljava.io.IOExceptionprotected void implConfigureBlocking(boolean block)
throws java.io.IOException
implConfigureBlocking in class java.nio.channels.spi.AbstractSelectableChanneljava.io.IOExceptionpublic final int validOps()
validOps in class java.nio.channels.SelectableChannelpublic final int getFD()
getFD in interface NativeSelectableChannelpublic int read(java.nio.ByteBuffer dst)
throws java.io.IOException
read in interface java.nio.channels.ReadableByteChanneljava.io.IOExceptionpublic int write(java.nio.ByteBuffer src)
throws java.io.IOException
write in interface java.nio.channels.WritableByteChanneljava.io.IOException