Documentation
¶
Index ¶
- Variables
- func FromPtr[T any](v *T) T
- func ToPtr[T any](v T) *T
- type Client
- func (c *Client) Close()
- func (c *Client) Execute(ctx context.Context, execute string, arguments, result any) error
- func (c *Client) Greeting() Greeting
- func (c *Client) Listen(ctx context.Context, filter func(Event) bool) <-chan Event
- func (c *Client) RegisterEvent(name string, factory func() api.EventType)
- type Dialer
- type Error
- type Event
- type Greeting
- type Message
- type Option
- type Options
- type QMPCapability
- type VersionInfo
- type VersionTriple
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrConnectionClosed = errors.New("connection closed")
View Source
var ErrListenerClosed = errors.New("listener closed")
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
type Greeting ¶
type Greeting struct {
QMP struct {
Version VersionInfo `json:"version"`
Capabilities []QMPCapability
} `json:"qmp"`
}
type Message ¶
type Message struct {
Return json.RawMessage `json:"return"`
Error *Error `json:"error"`
}
type QMPCapability ¶
type QMPCapability string
type VersionInfo ¶
type VersionInfo struct {
QEMU VersionTriple `json:"qemu"`
Package string `json:"package"`
}
type VersionTriple ¶
Click to show internal directories.
Click to hide internal directories.