Package jnr.enxio.channels
Class Native
- java.lang.Object
-
- jnr.enxio.channels.Native
-
public final class Native extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
Native.LibC
private static class
Native.SingletonHolder
static class
Native.Timespec
-
Constructor Summary
Constructors Constructor Description Native()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
close(int fd)
static jnr.constants.platform.Errno
getLastError()
static java.lang.String
getLastErrorString()
(package private) static jnr.ffi.Runtime
getRuntime()
(package private) static Native.LibC
libc()
static int
read(int fd, java.nio.ByteBuffer dst)
static void
setBlocking(int fd, boolean block)
static int
shutdown(int fd, int how)
static int
write(int fd, java.nio.ByteBuffer src)
-
-
-
Method Detail
-
libc
static Native.LibC libc()
-
getRuntime
static jnr.ffi.Runtime getRuntime()
-
close
public static int close(int fd) throws java.io.IOException
- Throws:
java.io.IOException
-
read
public static int read(int fd, java.nio.ByteBuffer dst) throws java.io.IOException
- Throws:
java.io.IOException
-
write
public static int write(int fd, java.nio.ByteBuffer src) throws java.io.IOException
- Throws:
java.io.IOException
-
setBlocking
public static void setBlocking(int fd, boolean block)
-
shutdown
public static int shutdown(int fd, int how)
-
getLastErrorString
public static java.lang.String getLastErrorString()
-
getLastError
public static jnr.constants.platform.Errno getLastError()
-
-