13. Library Reference

Program BPELWait
Wait for time (ms).

Input Parameters:Output Parameters:
timeString
Commands:
BPEL
system.CT_BPEL
bpelXML
statusString
errormsgString

Program BPELEmpty
This program does nothing.

Input Parameters:Output Parameters:
Commands:
BPEL
system.CT_BPEL
bpelXML
statusString
errormsgString

Program BPELThrow
This program always fails. You can use it to throw an exception..

Input Parameters:Output Parameters:
faultNameString
faultCodeString
Commands:
BPEL
system.CT_BPEL
bpelXML
statusString
errormsgString

Program Multiply
Snippet to multiply two floating point numbers.

Input Parameters:Output Parameters:
afloat
bfloat
cfloat
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
c = a * b;
ScriptCode:Java
ExceptionText

Program Sum
Adds two floating point numbers.

Input Parameters:Output Parameters:
afloat
bfloat
cfloat
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
c = a + b;
ScriptCode:Java
ExceptionText

Program Subtract
Returns the difference between a and b.

Input Parameters:Output Parameters:
afloat
bfloat
cfloat
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
c = a - b;
ScriptCode:Java
ExceptionText

Program Divide
Snippet to divide two floating point numbers.

Input Parameters:Output Parameters:
afloat
bfloat
cfloat
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
c = a / b;
ScriptCode:Java
ExceptionText

Program Operation
Abstract interface representing math operations that take two floating point numbers and return one.

Input Parameters:Output Parameters:
afloat
bfloat
cfloat
Commands:

Program Power
Raises a to the b-th power.

Input Parameters:Output Parameters:
adouble
bdouble
cdouble
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
c = Math.pow(a,b);
ScriptCode:Java
ExceptionText

Program Null
Snippet that will always return 0 no matter what input is given.

Input Parameters:Output Parameters:
afloat
bfloat
cfloat
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
c = 0;
ScriptCode:Java
ExceptionText

Program getProgramsByInterface
Returns the list of the names of currently deployed programs that match the interface signature contained in the filter parameter. The list is sorted..

Input Parameters:Output Parameters:
FilterString
ProgramsString
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
Programs = Opera.getInstance().listProgramInterfaces(Filter);
ScriptCode:Java
ExceptionText

Program getProgramsByName
Returns programs whose name matches the regular expression passed as filter.

Input Parameters:Output Parameters:
FilterString
ProgramsString
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
Programs = Opera.getInstance().listProgramNames(Filter);
ScriptCode:Java
ExceptionText

Program Cancel
This library task should be called to cancel the execution of another one identified by its TID..

Input Parameters:Output Parameters:
t_idString
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
Opera.getInstance().signal(new TID(t_id), ch.ethz.jopera.kernel.api.APIConsts.SIGNAL_KILL);
ScriptCode:Java
ExceptionText

Program Resume
This library task should be called to resume the execution of a task identified by its ID system parameter..

Input Parameters:Output Parameters:
t_idString
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
Opera.getInstance().signal(new TID(t_id), ch.ethz.jopera.kernel.api.APIConsts.SIGNAL_CONTINUE);
ScriptCode:Java
ExceptionText

Program Suspend
This library task should be called to suspend the execution of a task identified by its ID system parameter. It can also suspend the entire process..

Input Parameters:Output Parameters:
t_idString
Commands:
NewAccessMethod
system.CT_JAVASCRIPT
Opera.getInstance().signal(new TID(t_id), ch.ethz.jopera.kernel.api.APIConsts.SIGNAL_PAUSE);
ScriptCode:Java
ExceptionText