Version: 5.3.3-ice35-b63

OmeroBlitz API
Home Previous Up Next Index

omero::grid::ScriptProcess

Overview

interface ScriptProcess extends Process

Extension of the Process interface which is returned by IScript when an model::ScriptJob is launched. It is critical that instances of (@link ScriptProcess} are closed on completetion. See the close method for more information.

Operation Index

getJob
Returns the job which started this process.
getResults
Returns the results immediately if present.
setMessage
Sets the message on the model::ScriptJob object.
close
Closes this process and frees server resources attached to it.

Operations

model::ScriptJob getJob() throws ServerError

Returns the job which started this process. Several scheduling fields (submitted, scheduledFor, started, finished) may be of interest.

RTypeDict getResults(int waitSecs) throws ServerError

Returns the results immediately if present. If the process is not yet finished, waits "waitSecs" before throwing an ApiUsageException. If poll has returned a non-null value, then this method will always return a non-null value.

string setMessage(string message) throws ServerError

Sets the message on the model::ScriptJob object. This value MAY be overwritten by the server if the script fails.

void close(bool detach) throws ServerError

Closes this process and frees server resources attached to it. If the detach argument is True, then the background process will continue executing. The user can reconnect to the process via the IScript service. If the detach argument is False, then the background process will be shutdown immediately, and all intermediate results (stdout, stderr, ...) will be uploaded.


Home Previous Up Next Index