|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.crsh.shell.impl.command.spi.CommandInvoker<Object,Object>
org.crsh.lang.impl.groovy.closure.ClosureInvoker
public class ClosureInvoker
| Constructor Summary | |
|---|---|
ClosureInvoker(groovy.lang.Closure closure)
|
|
| Method Summary | |
|---|---|
void |
close()
Close the producer. |
void |
flush()
Flush the stream. |
Class<Object> |
getConsumedType()
Returns the class of the element generic type. |
Class<Object> |
getProducedType()
Returns the class of the produced type. |
void |
open(CommandContext<? super Object> consumer)
Open the producer with the specified consumer. |
void |
provide(Object element)
Provide an element. |
| Methods inherited from class org.crsh.shell.impl.command.spi.CommandInvoker |
|---|
getKeyHandler, getScreenContext, invoke |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ClosureInvoker(groovy.lang.Closure closure)
| Method Detail |
|---|
public Class<Object> getProducedType()
Producer
public Class<Object> getConsumedType()
Consumer
public void provide(Object element)
throws IOException,
CommandException
Consumer
provide in interface Consumer<Object>provide in class CommandInvoker<Object,Object>element - the provided element
IOException
CommandExceptionpublic void open(CommandContext<? super Object> consumer)
Producer
open in interface Producer<Object,CommandContext<? super Object>>open in class CommandInvoker<Object,Object>consumer - the consumer
public void flush()
throws IOException
Consumer
flush in interface Consumer<Object>flush in class CommandInvoker<Object,Object>IOException - any io exceptionpublic void close()
Producer
close in interface Producer<Object,CommandContext<? super Object>>close in class CommandInvoker<Object,Object>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||