X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/13fb4af932a02ea0bd4293d1e55ac071de326f80..67d66b0cf79b9fc02c0450f254584693dbf21d3b:/src/bindings/java/jmsg_host.h diff --git a/src/bindings/java/jmsg_host.h b/src/bindings/java/jmsg_host.h index 0b9ed50145..75df2d49aa 100644 --- a/src/bindings/java/jmsg_host.h +++ b/src/bindings/java/jmsg_host.h @@ -1,6 +1,6 @@ /* Functions related to the java host instances. */ -/* Copyright (c) 2007-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2007-2021. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -8,10 +8,11 @@ #ifndef MSG_JHOST_H #define MSG_JHOST_H +#include "simgrid/host.h" +#include "simgrid/plugins/file_system.h" #include -#include "simgrid/msg.h" -SG_BEGIN_DECL() +SG_BEGIN_DECL /* Shut up some errors in eclipse online compiler. I wish such a pimple wouldn't be needed */ #ifndef JNIEXPORT @@ -22,7 +23,7 @@ SG_BEGIN_DECL() #endif /* end of eclipse-mandated pimple */ -/** Returns a new java instance of an host. */ +/** Returns a new java instance of a host. */ jobject jhost_new_instance(JNIEnv * env); /** Take a ref onto the java instance (to prevent its collection) */ @@ -32,10 +33,10 @@ jobject jhost_ref(JNIEnv * env, jobject jhost); void jhost_unref(JNIEnv * env, jobject jhost); /** Binds a native instance to a java instance. */ -void jhost_bind(jobject jhost, msg_host_t host, JNIEnv * env); +void jhost_bind(jobject jhost, sg_host_t host, JNIEnv* env); /** Extracts the native instance associated to a java instance. */ -msg_host_t jhost_get_native(JNIEnv * env, jobject jhost); +sg_host_t jhost_get_native(JNIEnv* env, jobject jhost); /** Initialize the native world, called from the Java world at startup */ JNIEXPORT void JNICALL Java_org_simgrid_msg_Host_nativeInit(JNIEnv *env, jclass cls); @@ -53,9 +54,6 @@ JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getSpeed (JNIEnv *env, jobje JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getCoreNumber (JNIEnv *env, jobject jhost); JNIEXPORT jobject JNICALL Java_org_simgrid_msg_Host_getProperty(JNIEnv *env, jobject jhost, jobject jname); JNIEXPORT void JNICALL Java_org_simgrid_msg_Host_setProperty(JNIEnv *env, jobject jhost, jobject jname, jobject jvalue); -JNIEXPORT jobjectArray JNICALL Java_org_simgrid_msg_Host_getMountedStorage(JNIEnv * env, jobject jhost); -JNIEXPORT jobjectArray JNICALL Java_org_simgrid_msg_Host_getAttachedStorage(JNIEnv * env, jobject jhost); -JNIEXPORT jobjectArray JNICALL Java_org_simgrid_msg_Host_getStorageContent(JNIEnv * env, jobject jhost); JNIEXPORT jobjectArray JNICALL Java_org_simgrid_msg_Host_all(JNIEnv *env, jclass cls); JNIEXPORT void JNICALL Java_org_simgrid_msg_Host_setAsyncMailbox(JNIEnv * env, jclass cls_arg, jobject jname); @@ -67,6 +65,10 @@ JNIEXPORT jint JNICALL Java_org_simgrid_msg_Host_getPstate(JNIEnv* env, jobject JNIEXPORT jint JNICALL Java_org_simgrid_msg_Host_getPstatesCount(JNIEnv* env, jobject jhost); JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getCurrentPowerPeak(JNIEnv* env, jobject jhost); JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getPowerPeakAt(JNIEnv* env, jobject jhost, jint pstate); +JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getLoad(JNIEnv* env, jobject jhost); -SG_END_DECL() +JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getCurrentLoad(JNIEnv *env, jobject jhost); +JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getAvgLoad(JNIEnv *env, jobject jhost); +JNIEXPORT jdouble JNICALL Java_org_simgrid_msg_Host_getComputedFlops (JNIEnv *env, jobject jhost); +SG_END_DECL #endif