use of org.scijava.command.CommandInfo in project imagej-ops by imagej.
the class CachedOpEnvironment method otherArgs.
/**
* Gets the given {@link Op} instance's argument value, starting at the
* specified offset.
*/
private Object[] otherArgs(final Op op, final int offset) {
final CommandInfo cInfo = info(op).cInfo();
final Module module = cInfo.createModule(op);
final ArrayList<Object> args = new ArrayList<>();
int i = 0;
for (final ModuleItem<?> input : cInfo.inputs()) {
if (i++ >= offset)
args.add(input.getValue(module));
}
return args.toArray();
}
Aggregations