X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/8199067e1f2a6ea4d3d8a38df1a4fb3f25d364da..7b138f8b1ed3e8816eda5cb26deb71fe81b4087a:/src/bindings/java/jmsg_storage.h diff --git a/src/bindings/java/jmsg_storage.h b/src/bindings/java/jmsg_storage.h index eeda61e123..21a855da84 100644 --- a/src/bindings/java/jmsg_storage.h +++ b/src/bindings/java/jmsg_storage.h @@ -1,6 +1,6 @@ /* Functions related to the java storage API. */ -/* Copyright (c) 2012-2014. The SimGrid Team. +/* Copyright (c) 2012-2015. The SimGrid Team. * All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it @@ -9,117 +9,107 @@ #ifndef MSG_JSTORAGE_H #define MSG_JSTORAGE_H #include -#include "msg/msg.h" +#include "simgrid/msg.h" + +SG_BEGIN_DECL() /** * This function returns a new java storage instance. * - * @param env The environment of the current thread + * @param env The environment of the current thread * - * @return A new java storage object. + * @return A new java storage object. * - * @exception If the class Storage is not found the function throws - * the ClassNotFoundException. If the constructor of - * this class is not found the function throws the exception - * NotSuchMethodException. + * @exception If the class Storage is not found the function throws the ClassNotFoundException. If the constructor of + * this class is not found the function throws the exception NotSuchMethodException. */ jobject jstorage_new_instance(JNIEnv * env); /** * This function associated a native storage to a java storage instance. * - * @param jstorage The java storage instance. - * @param storage The native storage to bind. - * @param env The environment of the current thread + * @param jstorage The java storage instance. + * @param storage The native storage to bind. + * @param env The environment of the current thread * - * @exception If the class Storage is not found the function throws - * the ClassNotFoundException. If the field bind of - * this class is not found the function throws the exception - * NotSuchFieldException. + * @exception If the class Storage is not found the function throws the ClassNotFoundException. If the field bind + * of this class is not found the function throws the exception NotSuchFieldException. */ void jstorage_bind(jobject jstorage, msg_storage_t storage, JNIEnv * env); - /** * This function returns a native storage from a java storage instance. * - * @param jstorage The java storage object from which get the native storage. - * @param env The environment of the current thread + * @param jstorage The java storage object from which get the native storage. + * @param env The environment of the current thread * - * @return The function returns the native storage associated to the - * java storage object. + * @return The function returns the native storage associated to the java storage object. * - * @exception If the class Storage is not found the function throws - * the ClassNotFoundException. If the field bind of - * this class is not found the function throws the exception - * NotSuchFieldException. + * @exception If the class Storage is not found the function throws the ClassNotFoundException. If the field bind + * of this class is not found the function throws the exception NotSuchFieldException. */ msg_storage_t jstorage_get_native(JNIEnv * env, jobject jstorage); - /** - * Class org_simgrid_msg_Storage - * Method nativeInit - * Signature ()V + * Class org_simgrid_msg_Storage + * Method nativeInit + * Signature ()V */ -JNIEXPORT void JNICALL -Java_org_simgrid_msg_Storage_nativeInit(JNIEnv*, jclass); - +JNIEXPORT void JNICALL Java_org_simgrid_msg_Storage_nativeInit(JNIEnv*, jclass); /** - * This function returns a global reference to the java storage instance - * specified by the parameter jstorage. + * This function returns a global reference to the java storage instance specified by the parameter jstorage. * - * @param jstorage The original java storage instance. - * @param env The environment of the current thread + * @param jstorage The original java storage instance. + * @param env The environment of the current thread * - * @return The global reference to the original java storage - * instance. + * @return The global reference to the original java storage instance. */ jobject jstorage_ref(JNIEnv * env, jobject jstorage); + /** * This function delete a global reference to a java storage instance. * - * @param The global reference to delete. - * @param env The environment of the current thread + * @param The global reference to delete. + * @param env The environment of the current thread */ void jstorage_unref(JNIEnv * env, jobject jstorage); /** * This function returns the name of a MSG storage. * - * @param jstorage A java storage object. - * @param env The environment of the current thread + * @param jstorage A java storage object. + * @param env The environment of the current thread * - * @return The name of the storage. + * @return The name of the storage. */ const char *jstorage_get_name(jobject jstorage, JNIEnv * env); /* - * Class org_simgrid_msg_Storage - * Method getByName - * Signature (Ljava/lang/String;)Lsimgrid/msg/Storage; + * Class org_simgrid_msg_Storage + * Method getByName + * Signature (Ljava/lang/String;)Lsimgrid/msg/Storage; */ JNIEXPORT jobject JNICALL Java_org_simgrid_msg_Storage_getByName(JNIEnv *, jclass, jstring); /* - * Class org_simgrid_msg_Storage - * Method getSize - * Signature ()D + * Class org_simgrid_msg_Storage + * Method getSize + * Signature ()D */ JNIEXPORT jlong JNICALL Java_org_simgrid_msg_Storage_getSize(JNIEnv *, jobject); /* - * Class org_simgrid_msg_Storage - * Method getFreeSize - * Signature ()D + * Class org_simgrid_msg_Storage + * Method getFreeSize + * Signature ()D */ JNIEXPORT jlong JNICALL Java_org_simgrid_msg_Storage_getFreeSize(JNIEnv *, jobject); /* - * Class org_simgrid_msg_Storage - * Method getUsedSize - * Signature ()D + * Class org_simgrid_msg_Storage + * Method getUsedSize + * Signature ()D */ JNIEXPORT jlong JNICALL Java_org_simgrid_msg_Storage_getUsedSize(JNIEnv *, jobject); @@ -128,8 +118,8 @@ JNIEXPORT jlong JNICALL Java_org_simgrid_msg_Storage_getUsedSize(JNIEnv *, jobje * Method getProperty * Signature (Ljava/lang/String;)Ljava/lang/String; */ -JNIEXPORT jobject JNICALL -Java_org_simgrid_msg_Storage_getProperty(JNIEnv *env, jobject jstorage, jobject jname); +JNIEXPORT jobject JNICALL Java_org_simgrid_msg_Storage_getProperty(JNIEnv *env, jobject jstorage, jobject jname); + /* * Class org_simgrid_msg_Storage * Method setProperty @@ -143,15 +133,13 @@ Java_org_simgrid_msg_Storage_setProperty(JNIEnv *env, jobject jstorage, jobject * Method getHost * Signature (Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String; */ -JNIEXPORT jobject JNICALL -Java_org_simgrid_msg_Storage_getHost(JNIEnv * env,jobject jstorage); +JNIEXPORT jobject JNICALL Java_org_simgrid_msg_Storage_getHost(JNIEnv * env,jobject jstorage); /** * Class org_simgrid_msg_Storage * Method all */ -JNIEXPORT jobjectArray JNICALL -Java_org_simgrid_msg_Storage_all(JNIEnv *, jclass); - +JNIEXPORT jobjectArray JNICALL Java_org_simgrid_msg_Storage_all(JNIEnv *, jclass); +SG_END_DECL() #endif /*!MSG_JSTORAGE_H */