Package io.deephaven.plugin
Class EchoObjectType
java.lang.Object
io.deephaven.plugin.PluginBase
io.deephaven.plugin.type.ObjectTypeBase
io.deephaven.plugin.EchoObjectType
- All Implemented Interfaces:
Plugin,Registration,ObjectType
An
object type plugin named "Echo" that echos back the received contents back to the
client. When compatibleClientConnection(Object, MessageStream) is called, an empty payload is sent to the
client.
The only object that is compatible with this plugin is INSTANCE.
-
Nested Class Summary
Nested classes/interfaces inherited from class io.deephaven.plugin.type.ObjectTypeBase
ObjectTypeBase.FetchOnlyNested classes/interfaces inherited from interface io.deephaven.plugin.type.ObjectType
ObjectType.AuthorizationExportBehavior, ObjectType.MessageStreamNested classes/interfaces inherited from interface io.deephaven.plugin.Plugin
Plugin.Visitor<T>Nested classes/interfaces inherited from interface io.deephaven.plugin.Registration
Registration.Callback -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncompatibleClientConnection(Object object, ObjectType.MessageStream connection) Signals creation of a client stream to the provided object.booleanReturns true if, and only if, theobjectis compatible withthisobject type.name()The name of the object type.Methods inherited from class io.deephaven.plugin.type.ObjectTypeBase
clientConnection, walkMethods inherited from class io.deephaven.plugin.PluginBase
registerIntoMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.deephaven.plugin.type.ObjectType
authorizationExportBehaviorMethods inherited from interface io.deephaven.plugin.Plugin
registerInto
-
Field Details
-
NAME
- See Also:
-
INSTANCE
-
-
Constructor Details
-
EchoObjectType
public EchoObjectType()
-
-
Method Details
-
name
Description copied from interface:ObjectTypeThe name of the object type.- Returns:
- the name
-
isType
Description copied from interface:ObjectTypeReturns true if, and only if, theobjectis compatible withthisobject type.- Parameters:
object- the object- Returns:
- true if the
objectis compatible
-
compatibleClientConnection
public ObjectType.MessageStream compatibleClientConnection(Object object, ObjectType.MessageStream connection) throws ObjectCommunicationException Description copied from class:ObjectTypeBaseSignals creation of a client stream to the provided object. The returned MessageStream implementation will be called with each received message from the client, and can call the provided connection instance to send messages as needed to the client.- Specified by:
compatibleClientConnectionin classObjectTypeBase- Parameters:
object- the object to create a connection forconnection- a stream to send objects to the client- Returns:
- a stream to receive objects from the client
- Throws:
ObjectCommunicationException- may throw an exception received fromObjectType.MessageStream.onData(ByteBuffer, Object...)calls
-