Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of git://scm.gforge.inria.fr/simgrid/simgrid-java
[simgrid.git] / org / simgrid / msg / Process.java
index dcfd43f..714a7a3 100644 (file)
@@ -230,16 +230,31 @@ public abstract class Process implements Runnable {
        /**
         * Suspends the process by suspending the task on which it was
         * waiting for the completion.
-        *
         */
-       public native void pause();
+       public native void suspend();
+       /**
+        * Suspends the process by suspending the task on which it was
+        * waiting for the completion.
+        * DEPRECATED: use suspend instead.
+        */
+       @Deprecated
+       public void pause() {
+               suspend();
+       }
        /**
         * Resumes a suspended process by resuming the task on which it was
         * waiting for the completion.
-        *
-        *
+        * DEPRECATED: use resume instead.
         */ 
-       public native void restart();
+       @Deprecated
+       public void restart() {
+               resume();
+       }
+       /**
+        * Resumes a suspended process by resuming the task on which it was
+        * waiting for the completion.
+        */
+       public native void resume();    
        /**
         * Tests if a process is suspended.
         *
@@ -377,6 +392,7 @@ public abstract class Process implements Runnable {
                 catch(ProcessKilledError pk) {
                         
                 }      
+               exit();
        }
 
        /**
@@ -387,7 +403,7 @@ public abstract class Process implements Runnable {
      */
        public abstract void main(String[]args) throws MsgException;
 
-    
+       public native void exit();    
        /**
         * Class initializer, to initialize various JNI stuff
         */