public void provide(Object element) throws Exception { outter.provide(element); }
public void provide(Object element) throws Exception { if (current == null) { throw new IllegalStateException("Not under context"); } else { current.provide(element); } } public Class<Object> getConsumedType() {
@Override public void provide(Object element) throws Exception { context.provide(element); } };
@Override public void provide(String element) throws Exception { context.provide(element); } };
@Override public void close() throws Exception { context.provide(count); } };
@Command public void main(org.crsh.command.InvocationContext<String> context) throws Exception { count.incrementAndGet(); context.provide("foo"); } }
@Command public void main(org.crsh.command.InvocationContext<Integer> context) throws Exception { context.provide(3); } }
@Command public void sub(org.crsh.command.InvocationContext<Integer> context) throws Exception { context.provide(3); } }
@Override public void flush() throws IOException { for (String s : buffer) { try { context.provide(s); } catch (Exception e) { throw new UndeclaredThrowableException(e); } } buffer.clear(); super.flush(); } };
@Command public void main(org.crsh.command.InvocationContext<Value> context) throws Exception { context.provide(new Value("abc")); } }
context.provide(ret);
P produced = producedType.cast(ret); try { invocationContext.provide(produced);
if (name != null) { if (name.equals(current.getLanguage().getName())) { context.provide("Using repl " + name); } else { Repl found = null; context.provide("Using repl " + name); } else { throw new ScriptException("Repl " + name + " not found"); context.provide(new LabelElement("Current repl is " + current.getLanguage().getName() + "available repl are:\n")); context.provide(table);
public void provide(Object element) throws Exception { if (current == null) { throw new IllegalStateException("Not under context"); } else { current.provide(element); } } public Class<Object> getConsumedType() {
public void provide(Object element) throws Exception { if (current == null) { throw new IllegalStateException("Not under context"); } else { current.provide(element); } } public Class<Object> getConsumedType() {
@Command @Usage("list flows that user can start") public void list(InvocationContext<String> context) throws Exception { logger.info("Executing command \"flow list\"."); for (String name : ops().registeredFlows()) { context.provide(name + System.lineSeparator()); } } }
@Command @Usage("list flows that user can start") public void list(InvocationContext<String> context) throws Exception { for (String name : ops().registeredFlows()) { context.provide(name + System.lineSeparator()); } } }