Package org.yamcs
Class StreamTcCommandReleaser
java.lang.Object
com.google.common.util.concurrent.AbstractService
org.yamcs.AbstractProcessorService
org.yamcs.StreamTcCommandReleaser
- All Implemented Interfaces:
com.google.common.util.concurrent.Service
,CommandReleaser
,ProcessorService
Sends commands to yamcs streams
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
A matcher is associated to a stream and used to match commands that are sent to that streamclass
Matches commands using a list of regular expressionsNested classes/interfaces inherited from interface com.google.common.util.concurrent.Service
com.google.common.util.concurrent.Service.Listener, com.google.common.util.concurrent.Service.State
-
Field Summary
Fields inherited from class org.yamcs.AbstractProcessorService
config, log, processor
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
doStart()
protected void
doStop()
void
init
(Processor proc, YConfiguration config, Object spec) void
registerOutStream
(int index, Stream stream, StreamTcCommandReleaser.CommandMatcher matcher) Add a new stream together with a matcher that will select the commands going to this streamvoid
release a command.void
setCommandHistory
(CommandHistoryPublisher commandHistoryPublisher) the command releaser has to add the command to the history when it is released.Methods inherited from class org.yamcs.AbstractProcessorService
getConfig, getYamcsInstance
Methods inherited from class com.google.common.util.concurrent.AbstractService
addListener, awaitRunning, awaitRunning, awaitRunning, awaitTerminated, awaitTerminated, awaitTerminated, doCancelStart, failureCause, isRunning, notifyFailed, notifyStarted, notifyStopped, startAsync, state, stopAsync, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.yamcs.ProcessorService
getSpec
Methods inherited from interface com.google.common.util.concurrent.Service
addListener, awaitRunning, awaitRunning, awaitRunning, awaitTerminated, awaitTerminated, awaitTerminated, failureCause, isRunning, startAsync, state, stopAsync
-
Constructor Details
-
StreamTcCommandReleaser
public StreamTcCommandReleaser()
-
-
Method Details
-
init
- Specified by:
init
in interfaceProcessorService
- Overrides:
init
in classAbstractProcessorService
config
- service configuration as specified in processor.yamlspec
- passed by the user when creating the processor (for instance via the REST API)
-
registerOutStream
public void registerOutStream(int index, Stream stream, StreamTcCommandReleaser.CommandMatcher matcher) Add a new stream together with a matcher that will select the commands going to this stream -
releaseCommand
Description copied from interface:CommandReleaser
release a command.- Specified by:
releaseCommand
in interfaceCommandReleaser
-
doStart
protected void doStart()- Specified by:
doStart
in classcom.google.common.util.concurrent.AbstractService
-
setCommandHistory
Description copied from interface:CommandReleaser
the command releaser has to add the command to the history when it is released.- Specified by:
setCommandHistory
in interfaceCommandReleaser
-
doStop
protected void doStop()- Specified by:
doStop
in classcom.google.common.util.concurrent.AbstractService
-