- return exec(SLC_WITH_REFRESH, ci);
- }
-
- public Object _slcnr(CommandInterpreter ci) {
- return exec(SLC_NO_REFRESH, ci);
- }
-
- protected Object exec(String slcCommand, CommandInterpreter ci) {
- // TODO: check version
- String firstArg = ci.nextArgument();
- if (firstArg == null) {
- if (lastLaunch != null) {
- String cmd = slcCommand + " " + lastLaunch.getModuleName()
- + " " + lastLaunch.getFlowDescriptor().getName();
- if (log.isDebugEnabled())
- log.debug("Execute again last command: " + cmd);
- return ci.execute(cmd);
- } else {
- ci.execute("help");
- throw new SlcException("Command not properly formatted");
- }
+ List<String> args = new ArrayList<String>();
+ String arg = null;
+ while ((arg = ci.nextArgument()) != null)
+ args.add(arg);
+ if (args.size() == 0) {
+ // TODO relaunch last process
+ ci.execute("help");
+ throw new SlcException("Command not properly formatted");