Class NativeIOJni
- java.lang.Object
-
- org.apache.bookkeeper.common.util.nativeio.NativeIOJni
-
class NativeIOJni extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description NativeIOJni()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description (package private) static intclose(int fd)(package private) static intfallocate(int fd, int mode, long offset, long len)fallocate is a linux-only syscall, so callers must handle the possibility that it does not exist.(package private) static voidfree(long pointer)(package private) static intfsync(int fd)(package private) static longlseek(int fd, long offset, int whence)(package private) static intopen(java.lang.String pathname, int flags, int mode)(package private) static intposix_fadvise(int fd, long offset, long len, int flag)(package private) static longposix_memalign(int alignment, int size)(package private) static longpread(int fd, long pointer, long size, long offset)(package private) static intpwrite(int fd, long pointer, int count, long offset)
-
-
-
Method Detail
-
open
static int open(java.lang.String pathname, int flags, int mode) throws NativeIOException- Throws:
NativeIOException
-
fsync
static int fsync(int fd) throws NativeIOException- Throws:
NativeIOException
-
fallocate
static int fallocate(int fd, int mode, long offset, long len) throws NativeIOExceptionfallocate is a linux-only syscall, so callers must handle the possibility that it does not exist.- Throws:
NativeIOException
-
posix_fadvise
static int posix_fadvise(int fd, long offset, long len, int flag) throws NativeIOException- Throws:
NativeIOException
-
pwrite
static int pwrite(int fd, long pointer, int count, long offset) throws NativeIOException- Throws:
NativeIOException
-
posix_memalign
static long posix_memalign(int alignment, int size) throws NativeIOException- Throws:
NativeIOException
-
free
static void free(long pointer) throws NativeIOException- Throws:
NativeIOException
-
lseek
static long lseek(int fd, long offset, int whence) throws NativeIOException- Throws:
NativeIOException
-
pread
static long pread(int fd, long pointer, long size, long offset) throws NativeIOException- Throws:
NativeIOException
-
close
static int close(int fd) throws NativeIOException- Throws:
NativeIOException
-
-