1 /* Java bindings of the file API. */
3 /* Copyright (c) 2012-2019. The SimGrid Team. All rights reserved. */
5 /* This program is free software; you can redistribute it and/or modify it
6 * under the terms of the license (GNU LGPL) which comes with this package. */
11 #include "simgrid/msg.h"
12 #include "simgrid/plugins/file_system.h"
17 /* Shut up some errors in eclipse online compiler. I wish such a pimple wouldn't be needed */
24 /* end of eclipse-mandated pimple */
26 jfieldID jfile_field_bind;
28 void jfile_bind(JNIEnv *env, jobject jfile, msg_file_t fd);
29 msg_file_t jfile_get_native(JNIEnv *env, jobject jfile);
31 JNIEXPORT void JNICALL Java_org_simgrid_msg_File_nativeInit(JNIEnv *env, jclass cls);
32 JNIEXPORT void JNICALL Java_org_simgrid_msg_File_open(JNIEnv *env, jobject jfile, jobject jpath);
33 JNIEXPORT jlong JNICALL Java_org_simgrid_msg_File_read(JNIEnv *env, jobject jfile, jlong jsize);
34 JNIEXPORT jlong JNICALL Java_org_simgrid_msg_File_write(JNIEnv *env, jobject jfile, jlong jsize);
35 JNIEXPORT void JNICALL Java_org_simgrid_msg_File_seek(JNIEnv *env, jobject jfile, jlong joffset, jlong jorigin);
36 JNIEXPORT void JNICALL Java_org_simgrid_msg_File_close(JNIEnv *env, jobject jfile);