Documentation
¶
Index ¶
- type Client
- func (c *Client) HandleMessageType(name string, handler func([]byte))
- func (c *Client) Kill() error
- func (c *Client) RespondRaw(t string, v any) error
- func (c *Client) RunCommand(name codes.MessageCode, v any) (codes.PluginExitReason, error)
- func (c *Client) SetCommand(command string)
- func (c *Client) StartLocal() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
Client is a standard plug host. It supports basic operations.
func (*Client) HandleMessageType ¶
HandleMessageType adds handler for incoming messages from the plug to the host.
func (*Client) RespondRaw ¶ added in v0.0.3
RespondRaw is a basic function for sending any message from host to a plug.
func (*Client) RunCommand ¶
func (c *Client) RunCommand(name codes.MessageCode, v any) (codes.PluginExitReason, error)
RunCommand sends arbitrary message to a plug. Plug must understand the message.
func (*Client) SetCommand ¶
SetCommand sets plug executable name
Click to show internal directories.
Click to hide internal directories.