org.ogf.saga.rpc
Interface RPC

All Superinterfaces:
Async, Cloneable, Permissions<RPC>, SagaObject

public interface RPC
extends SagaObject, Async, Permissions<RPC>

The RPC class represents a remote function handle that can be called repeatedly.


Field Summary
 
Fields inherited from interface org.ogf.saga.SagaObject
NO_WAIT, WAIT_FOREVER
 
Method Summary
 void call(Parameter... parameters)
          Calls the remote procedure.
 Task<RPC,Void> call(TaskMode mode, Parameter... parameters)
          Creates a task for calling the remote procedure.
 void close()
          Non-blocking close of the RPC handle instance.
 void close(float timeoutInSeconds)
          Closes the RPC handle instance.
 Task<RPC,Void> close(TaskMode mode)
          Creates a task for closing the RPC handle instance.
 Task<RPC,Void> close(TaskMode mode, float timeoutInSeconds)
          Creates a task for closing the RPC handle instance.
 
Methods inherited from interface org.ogf.saga.SagaObject
clone, getId, getSession
 
Methods inherited from interface org.ogf.saga.permissions.Permissions
getGroup, getGroup, getOwner, getOwner, permissionsAllow, permissionsAllow, permissionsCheck, permissionsCheck, permissionsDeny, permissionsDeny
 

Method Detail

call

void call(Parameter... parameters)
          throws NotImplementedException,
                 IncorrectURLException,
                 AuthenticationFailedException,
                 AuthorizationFailedException,
                 PermissionDeniedException,
                 BadParameterException,
                 IncorrectStateException,
                 DoesNotExistException,
                 TimeoutException,
                 NoSuccessException
Calls the remote procedure.

Parameters:
parameters - arguments and results for the call.
Throws:
IncorrectURLException - may be thrown here because the RPC server that was specified to the factory may not have been contacted before invoking the call.
NoSuccessException - is thrown for arbitrary backend failures, with a descriptive error message.
NotImplementedException - is thrown if the implementation does not provide an implementation of this method.
BadParameterException - is thrown when at least one of the parameters of the method call is ill-formed, invalid, out of bounds or otherwise not usable, or if the RPC server cannot be found.
DoesNotExistException - is thrown when an operation cannot succeed because the RPC server does not recognize the specified method.
IncorrectStateException - is thrown when the object is already closed.
PermissionDeniedException - is thrown when the method failed because the identity used did not have sufficient permissions to perform the operation successfully.
AuthorizationFailedException - is thrown when none of the available contexts of the used session could be used for successful authorization. This error indicates that the resource could not be accessed at all, and not that an operation was not available due to restricted permissions.
AuthenticationFailedException - is thrown when operation failed because none of the available session contexts could successfully be used for authentication.
TimeoutException - is thrown when a remote operation did not complete successfully because the network communication or the remote service timed out.

close

void close()
           throws NotImplementedException,
                  IncorrectStateException,
                  NoSuccessException
Non-blocking close of the RPC handle instance. Note for Java implementations: A finalizer could be used in case the application forgets to close.

Throws:
NoSuccessException - is thrown for arbitrary backend failures, with a descriptive error message.
NotImplementedException - is thrown if the implementation does not provide an implementation of this method.
IncorrectStateException - is in the SAGA specifications, but is not thrown when the object is already closed.

close

void close(float timeoutInSeconds)
           throws NotImplementedException,
                  IncorrectStateException,
                  NoSuccessException
Closes the RPC handle instance. Note for Java implementations: A finalizer could be used in case the application forgets to close.

Parameters:
timeoutInSeconds - seconds to wait.
Throws:
NoSuccessException - is thrown for arbitrary backend failures, with a descriptive error message.
NotImplementedException - is thrown if the implementation does not provide an implementation of this method.
IncorrectStateException - is in the SAGA specifications, but is not thrown when the object is already closed.

call

Task<RPC,Void> call(TaskMode mode,
                    Parameter... parameters)
                    throws NotImplementedException
Creates a task for calling the remote procedure.

Parameters:
mode - the task mode.
parameters - arguments and results for the call.
Returns:
the task.
Throws:
NotImplementedException - is thrown when the task version of this method is not implemented.

close

Task<RPC,Void> close(TaskMode mode)
                     throws NotImplementedException
Creates a task for closing the RPC handle instance.

Parameters:
mode - the task mode.
Returns:
the task.
Throws:
NotImplementedException - is thrown when the task version of this method is not implemented.

close

Task<RPC,Void> close(TaskMode mode,
                     float timeoutInSeconds)
                     throws NotImplementedException
Creates a task for closing the RPC handle instance.

Parameters:
mode - the task mode.
timeoutInSeconds - seconds to wait.
Returns:
the task.
Throws:
NotImplementedException - is thrown when the task version of this method is not implemented.


Copyright © 2014 Open Grid Forum. All rights reserved.