Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'actor-yield' of github.com:Takishipp/simgrid into actor-yield
[simgrid.git] / src / bindings / java / jmsg_as.hpp
1 /* Functions related to the java As instances.                              */
2
3 /* Copyright (c) 2007-2017. The SimGrid Team. All rights reserved.          */
4
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. */
7
8 #ifndef JMSG_AS_HPP
9 #define JMSG_AS_HPP
10 #include "simgrid/msg.h"
11 #include <jni.h>
12
13 extern "C" {
14
15 /* Shut up some errors in eclipse online compiler. I wish such a pimple wouldn't be needed */
16 #ifndef JNIEXPORT
17 #define JNIEXPORT
18 #endif
19 #ifndef JNICALL
20 #define JNICALL
21 #endif
22 /* end of eclipse-mandated pimple */
23
24 jobject jnetzone_new_instance(JNIEnv* env);
25 jobject jnetzone_ref(JNIEnv* env, jobject jnetzone);
26 void jnetzone_unref(JNIEnv* env, jobject jnetzone);
27 void jnetzone_bind(jobject jas, msg_netzone_t as, JNIEnv* env);
28 simgrid::s4u::NetZone* jnetzone_get_native(JNIEnv* env, jobject jnetzone);
29
30 JNIEXPORT void JNICALL Java_org_simgrid_msg_As_nativeInit(JNIEnv* env, jclass cls);
31 JNIEXPORT jobject JNICALL Java_org_simgrid_msg_As_getName(JNIEnv* env, jobject jas);
32 JNIEXPORT jobjectArray JNICALL Java_org_simgrid_msg_As_getSons(JNIEnv* env, jobject jnetzone);
33 JNIEXPORT jobject JNICALL Java_org_simgrid_msg_As_getProperty(JNIEnv* env, jobject jhost, jobject jname);
34 JNIEXPORT jobjectArray JNICALL Java_org_simgrid_msg_As_getHosts(JNIEnv* env, jobject jnetzone);
35 }
36 #endif