public void open2(final CommandContext<P> consumer) { invocationContext = new InvocationContextImpl<P>(consumer); command.pushContext(invocationContext); command.unmatched = invoker.getMatch().getRest(); }
public void open2(final CommandContext<P> consumer) throws CommandException { // invocationContext = new InvocationContextImpl<P>(consumer); // Push context command.pushContext(invocationContext); // Set the unmatched part command.unmatched = invoker.getMatch().getRest(); // PC ret; try { ret = invoker.invoke(this); } catch (org.crsh.cli.impl.SyntaxException e) { throw new CommandException(ErrorKind.SYNTAX, "Syntax exception when executing command " + name, e); } catch (InvocationException e) { throw new CommandException(ErrorKind.EVALUATION, "Command " + name + " failed", e.getCause()); } // It's a pipe command if (ret != null) { real = ret; try { real.open(invocationContext); } catch (Exception e) { throw new CommandException(ErrorKind.EVALUATION, "Command " + name + " failed", e); } } }
public void open2(final CommandContext<P> consumer) { invocationContext = new InvocationContextImpl<P>(consumer); command.pushContext(invocationContext); command.unmatched = invoker.getMatch().getRest(); }
public void open2(final CommandContext<P> consumer) { invocationContext = new InvocationContextImpl<P>(consumer); command.pushContext(invocationContext); command.unmatched = invoker.getMatch().getRest(); }
public void open2(final CommandContext<P> consumer) throws CommandException { // invocationContext = new InvocationContextImpl<P>(consumer); // Push context command.pushContext(invocationContext); // Set the unmatched part command.unmatched = invoker.getMatch().getRest(); // PC ret; try { ret = invoker.invoke(this); } catch (org.crsh.cli.impl.SyntaxException e) { throw new CommandException(ErrorKind.SYNTAX, "Syntax exception when executing command " + name, e); } catch (InvocationException e) { throw new CommandException(ErrorKind.EVALUATION, "Command " + name + " failed", e.getCause()); } // It's a pipe command if (ret != null) { real = ret; try { real.open(invocationContext); } catch (Exception e) { throw new CommandException(ErrorKind.EVALUATION, "Command " + name + " failed", e); } } }
public void open2(final CommandContext<P> consumer) throws CommandException { // invocationContext = new InvocationContextImpl<P>(consumer); // Push context command.pushContext(invocationContext); // Set the unmatched part command.unmatched = invoker.getMatch().getRest(); // PC ret; try { ret = invoker.invoke(this); } catch (org.crsh.cli.impl.SyntaxException e) { throw new CommandException(ErrorKind.SYNTAX, "Syntax exception when executing command " + name, e); } catch (InvocationException e) { throw new CommandException(ErrorKind.EVALUATION, "Command " + name + " failed", e.getCause()); } // It's a pipe command if (ret != null) { real = ret; try { real.open(invocationContext); } catch (Exception e) { throw new CommandException(ErrorKind.EVALUATION, "Command " + name + " failed", e); } } }