Expand description
Functionality and types shared between the plugin and the engine, other than protocol types.
If you are writing a plugin, you probably don’t need this crate. We will make fewer guarantees
for the stability of the interface of this crate than for nu_plugin
.
Modules§
Structs§
- Json
Serializer - A
PluginEncoder
that enables the plugin to communicate with Nushell with JSON serialized data. - MsgPack
Serializer - A
PluginEncoder
that enables the plugin to communicate with Nushell with MsgPack serialized data. - Stream
Manager - Stream
Manager Handle - A
StreamManagerHandle
supports operations for interacting with theStreamManager
. - Stream
Reader - Receives messages from a stream read from input by a
StreamManager
. - Stream
Writer - Writes messages to a stream, with flow control.
Enums§
- Client
Communication Io - The required streams for communication from the plugin side, i.e. the client in socket terms.
- Communication
Mode - The type of communication used between the plugin and the engine.
- Encoding
Type - Enum that supports all of the plugin serialization formats.
- Pipeline
Data Writer - Completes the write operation for a
PipelineData
. You must callPipelineDataWriter::write()
to write all of the data contained within the streams. - Prepared
Server Communication - The result of
CommunicationMode::serve()
, which acts as an intermediate stage for communication modes that require some kind of socket binding to occur before the client process can be started. Call.connect()
once the client process has been started. - Server
Communication Io - The required streams for communication from the engine side, i.e. the server in socket terms.
Traits§
- Encoder
- Encoder for a specific message type. Usually implemented on
PluginInput
andPluginOutput
. - From
Shell Error - Values that can contain a
ShellError
to signal an error has occurred. - Interface
- An interface provides an API for communicating with a plugin or the engine and facilitates
stream I/O. See
PluginInterface
innu-plugin-engine
for the API from the engine side to a plugin, orEngineInterface
innu-plugin
for the API from the plugin side to the engine. - Interface
Manager - An interface manager handles I/O and state management for communication between a plugin and
the engine. See
PluginInterfaceManager
innu-plugin-engine
for communication from the engine side to a plugin, orEngineInterfaceManager
innu-plugin
for communication from the plugin side to the engine. - Plugin
Encoder - Encoding scheme that defines a plugin’s communication protocol with Nu
- Plugin
Read - Read input/output from the stream.
- Plugin
Write - Write input/output to the stream.