new ArrayOutputReturn(output)
Creates a wrapper for the results produced by ArrayOutput.
This object allows convenient inspection of values, errors and status.
Example
Basic inspection
var { ArrayOutput } = require("sigma/arrayOutput");
var out = new ArrayOutput();
out.add(deviceA, "OK");
out.add(deviceB, null, "Timeout");
var ret = out.getReturn();
print(ret.values()); // ["OK", null]
print(ret.errors()); // [null, "Timeout"]
Parameters:
|
Array.<Object>
|
output |
Internal array with {name, object, value, error} fields. |
Return index of the object in the output list.