org.ocap.resource
Interface ResourceAction


public interface ResourceAction

A computation to be performed within a specific resource context. The computation is performed by invoking ResourceContext.doResourceAction on the ResourceAction object. This interface is used only for computations that do not throw checked exceptions; computations that throw checked exceptions must use ResourceExceptionAction instead.

Author:
Aaron Kamienski
See Also:
ResourceContext, ResourceContext.doResourceAction(ResourceAction), ResourceExceptionAction

Method Summary
 Object executeAction()
          Performs the computation.
 

Method Detail

executeAction

Object executeAction()
Performs the computation. This method will be called by ResourceContext.doResourceAction. All resource reservation operations performed as part of this computation will implicitly have access to the ResourceContext and its attributes.

Returns:
A class-dependent value that may represent the results of the computation.
Throws:
RuntimeException - unchecked exceptions may be thrown
Error - unchecked exceptions may be thrown
See Also:
ResourceContext.doResourceAction(ResourceAction)