com.cosylab.jcosyne.server
Interface RemoteTaskScript


public interface RemoteTaskScript

This interface must be implemented by all BeanScripts supplied to remote tasks for execution, be it either the post-initialization or post-execution scripts or the custom scripts submitted with execute. See BeanScript documentation fow how to write scripts implementing a given interface.

Author:
Gasper Tkacik (gasper.tkacik@cosylab.com)
See Also:
RemoteTaskMBean.executeScript(java.lang.String)

Method Summary
 java.lang.Object execute(RemoteTask task)
          Execute the custom portion of the script.
 

Method Detail

execute

public java.lang.Object execute(RemoteTask task)
Execute the custom portion of the script.

Parameters:
task - the task that is executing the script; use this reference in BeanScript to access task's fields and methods; can access private members if setAccessible(true) is called from within the script
Returns:
the result of script execution, can be null; this value must be stored in the remote task in LastScriptResult attribute