/** ReflectionFactory identifier for command (compiler) */
protected String commandName;
+ protected ICommand command;
+
/** client-set message sink */
private IMessageHolder clientHolder;
this.controller = controller;
}
+ public void setCommand(ICommand command) {
+ this.command = command;
+ }
+
/**
* Run without throwing exceptions but optionally using System.exit(..). This sets up a message handler which emits messages
* immediately, so report(boolean, IMessageHandler) only reports total number of errors or warnings.
if (0 < holder.numMessages(IMessage.ERROR, true)) {
return;
}
- ICommand command = ReflectionFactory.makeCommand(commandName, holder);
+ if (command == null) {
+ command = ReflectionFactory.makeCommand(commandName, holder);
+ }
if (0 < holder.numMessages(IMessage.ERROR, true)) {
return;
}