C - the consumed element generic typeP - the produced element generic typepublic abstract class CommandInvoker<C,P> extends Object implements Filter<C,P,CommandContext<? super P>>
CommandContext kind of consumer.| Constructor and Description |
|---|
CommandInvoker() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
close()
Close the producer.
|
abstract void |
flush()
Flush the stream.
|
KeyHandler |
getKeyHandler()
Return the key handler or null if the invoker cannot handler key events.
|
ScreenContext |
getScreenContext()
Provide an opportunity for the command to implement screen context.
|
void |
invoke(CommandContext<? super P> consumer)
Invoke the command.
|
abstract void |
open(CommandContext<? super P> consumer)
Open the producer with the specified consumer.
|
abstract void |
provide(C element)
Provide an element.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetConsumedTypegetProducedTypepublic CommandInvoker()
public final void invoke(CommandContext<? super P> consumer) throws IOException, CommandException
consumer - the consumer for this invocationIOException - any io exceptionCommandException - anything command exceptionpublic abstract void flush() throws IOException
Consumerflush in interface Consumer<C>IOException - any io exceptionpublic abstract void provide(C element) throws IOException, CommandException
Consumerprovide in interface Consumer<C>element - the provided elementIOExceptionCommandExceptionpublic abstract void open(CommandContext<? super P> consumer) throws IOException, CommandException
Produceropen in interface Producer<P,CommandContext<? super P>>consumer - the consumerIOExceptionCommandExceptionpublic abstract void close() throws IOException, CommandException
Producerclose in interface Producer<P,CommandContext<? super P>>IOExceptionCommandExceptionpublic ScreenContext getScreenContext()
public KeyHandler getKeyHandler()
Copyright © 2015 eXo Platform SAS. All Rights Reserved.