Name | Return Type | Description |
---|---|---|
err | Workflow | Specifies the function to handle the error. |
exec | Workflow | Next, we run the function. |
getReport | { id: String, start: Number, end: Number, time: Number, success: Boolean }[] | Returns a report of the workflow execution result. |
send | Workflow | Next, execute Submission. |
name | type | description | |
---|---|---|---|
app | AppInstance | ||
debugoptional | Boolean | defaultfalse
|
var workflow = new cpr.foundation.Workflow(app);
workflow.exec(...).send(...).error(function(error) {
console.err(error);
});
name | type | description | |
---|---|---|---|
func | (error: Object)=>Object | Functions to handle errors |
return | Workflow |
---|
var workflow = new cpr.foundation.Workflow(app);
workflow.exec(function() {
... CODE ...
});
name | type | description | |
---|---|---|---|
func | (value: Object)=>Object | Next execute function | |
idoptional | String | Name of the job to be executed (used for logging) |
return | Workflow |
---|
var workflow = new cpr.foundation.Workflow(app);
workflow.exec(...).send(...).exec(...).error(...)
.exec(function() {
console.log(JSON.stringify(workflow.getReport()));
});
return | { id: String, start: Number, end: Number, time: Number, success: Boolean }[] |
---|
var workflow = new cpr.foundation.Workflow (app);
workflow.send ("submain", "subsub", ...);
code> pre>
name | type | description | |
---|---|---|---|
submissionIds | String | cpr.protocols.Submission[] | Submissions to be executed next |
return | Workflow |
---|