[SAGA-RG] saga-ogf SVN commit 1282: /trunk/documents/saga-core-binding-java/implementation/VU/src/org/ogf/saga/task/

ceriel at cs.vu.nl ceriel at cs.vu.nl
Wed Jul 14 04:15:12 CDT 2010


User: svn_ceriel
Date: 2010/07/14 04:15 AM

Modified:
 /trunk/documents/saga-core-binding-java/implementation/VU/src/org/ogf/saga/task/
  Task.java, TaskContainer.java

Log:
 Updated task.getResult() spec according to current saga specs.

File Changes:

Directory: /trunk/documents/saga-core-binding-java/implementation/VU/src/org/ogf/saga/task/
===========================================================================================

File [modified]: Task.java
Delta lines: +37 -14
===================================================================
--- trunk/documents/saga-core-binding-java/implementation/VU/src/org/ogf/saga/task/Task.java	2010-06-24 10:49:26 UTC (rev 1281)
+++ trunk/documents/saga-core-binding-java/implementation/VU/src/org/ogf/saga/task/Task.java	2010-07-14 09:15:03 UTC (rev 1282)
@@ -163,25 +163,45 @@
             NoSuccessException;
 
     /**
-     * Obtains the result of the asynchronous method call.
+     * Obtains the result of the asynchronous method call. Implies a 
+     * {@link #waitFor()}.
+     * If the task is in {@link State#FAILED} state after a
+     * {@link #waitFor()}, a {@link #rethrow()} is called.
      * 
      * @return
      *      the result.
+     * @exception IncorrectURLException
+     *      is thrown when the failed task threw it.
+     * @exception NoSuccessException
+     *      is thrown when the failed task threw it.
+     * @exception BadParameterException
+     *      is thrown when the failed task threw it.
+     * @exception IncorrectStateException
+     *      is thrown when the failed task threw it, or when the task is in
+     *      {@link State#NEW} or {@link State#CANCELED} state.
+     * @exception PermissionDeniedException
+     *      is thrown when the failed task threw it.
+     * @exception AuthorizationFailedException
+     *      is thrown when the failed task threw it.
+     * @exception AuthenticationFailedException
+     *      is thrown when the failed task threw it.
      * @exception NotImplementedException
-     *      is thrown if the implementation does not provide an
-     *      implementation of this method.
+     *      is thrown when the failed task threw it, or when 
+     *      {@link #getResult()} is not implemented.
+     * @exception AlreadyExistsException
+     *      is thrown when the failed task threw it.
+     * @exception DoesNotExistException
+     *      is thrown when the failed task threw it.
      * @exception TimeoutException
-     *      is thrown when a remote operation did not complete successfully
-     *      because the network communication or the remote service timed
-     *      out.
-     * @exception IncorrectStateException
-     *      is thrown when task is in state NEW, FAILED, or CANCELED state.
-     * @exception NoSuccessException
-     *      is thrown when the operation was not successfully performed,
-     *      and none of the other exceptions apply.
+     *      is thrown when the failed task threw it.
+     * @exception SagaIOException
+     *      is thrown when the failed task threw it.
      */
-    public E getResult() throws NotImplementedException,
-            IncorrectStateException, TimeoutException, NoSuccessException;
+    public E getResult() throws NotImplementedException, IncorrectURLException,
+            BadParameterException, AlreadyExistsException, DoesNotExistException,
+            IncorrectStateException, PermissionDeniedException,
+            AuthorizationFailedException, AuthenticationFailedException,
+            TimeoutException, SagaIOException, NoSuccessException;
 
     /**
      * Gets the object from which the task was created.
@@ -203,7 +223,10 @@
             NoSuccessException;
 
     /**
-     * Throws any exception a failed task caught.
+     * Throws any exception a failed task caught. It does nothing unless the
+     * task is in state {@link State#FAILED}. Rethrow can be called multiple times,
+     * always throwing the same exception.
+     * 
      * @exception IncorrectURLException
      *      is thrown when the failed task threw it.
      * @exception NoSuccessException

File [modified]: TaskContainer.java
Delta lines: +1 -2
===================================================================
--- trunk/documents/saga-core-binding-java/implementation/VU/src/org/ogf/saga/task/TaskContainer.java	2010-06-24 10:49:26 UTC (rev 1281)
+++ trunk/documents/saga-core-binding-java/implementation/VU/src/org/ogf/saga/task/TaskContainer.java	2010-07-14 09:15:03 UTC (rev 1282)
@@ -63,8 +63,7 @@
      *      because the network communication or the remote service timed
      *      out.
      * @exception DoesNotExistException
-     *      is thrown when the container does not contain a task for the
-     *      specified cookie.
+     *      is thrown when the container does not contain the specified task.
      * @exception NoSuccessException
      *      is thrown when the operation was not successfully performed,
      *      and none of the other exceptions apply.



More information about the saga-rg mailing list