< prev index next >
src/java.base/share/native/libjava/io_util.h
Print this page
@@ -27,10 +27,11 @@
#include "jni_util.h"
extern jfieldID IO_fd_fdID;
extern jfieldID IO_handle_fdID;
extern jfieldID IO_append_fdID;
+extern jfieldID IO_pgsz_fdID;
#ifdef _ALLBSD_SOURCE
#include <fcntl.h>
#ifndef O_SYNC
#define O_SYNC O_FSYNC
@@ -48,13 +49,17 @@
*/
jint readSingle(JNIEnv *env, jobject this, jfieldID fid);
jint readBytes(JNIEnv *env, jobject this, jbyteArray bytes, jint off,
jint len, jfieldID fid);
+jint readBytesD(JNIEnv *env, jobject this, jbyteArray bytes, jint off,
+ jint len, jfieldID fid, jfieldID pgsz_id);
void writeSingle(JNIEnv *env, jobject this, jint byte, jboolean append, jfieldID fid);
void writeBytes(JNIEnv *env, jobject this, jbyteArray bytes, jint off,
jint len, jboolean append, jfieldID fid);
+void writeBytesD(JNIEnv *env, jobject this, jbyteArray bytes, jint off,
+ jint len, jboolean append, jfieldID fid, jfieldID pgsz_id);
void fileOpen(JNIEnv *env, jobject this, jstring path, jfieldID fid, int flags);
void throwFileNotFoundException(JNIEnv *env, jstring path);
/*
* Macros for managing platform strings. The typical usage pattern is:
@@ -125,5 +130,8 @@
#define END_UNICODE_STRING(env, var) \
(*(env))->ReleaseStringChars(env, _##var##str, var); \
_##var##end: ; \
} else ((void)NULL)
+
+#define GET_PG_SIZE(this, IO_pgsz_fdID) \
+ (*env)->GetIntField(env, (this), (IO_pgsz_fdID))
< prev index next >