message

package
v2.0.0-beta.40.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 25, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Parse

func Parse(message string) (*parsedMessage, error)

Parse will attempt to parse the given message

Types

type CallMessage

type CallMessage struct {
	Name       string            `json:"name"`
	Args       []json.RawMessage `json:"args"`
	CallbackID string            `json:"callbackID,omitempty"`
}

type ContextMenusOnMessage

type ContextMenusOnMessage struct {
	// MenuID is the id of the menu item we are interested in
	MenuID string
	// Callback is called when the menu is clicked
	Callback func(*menu.MenuItem, string)
}

ContextMenusOnMessage is used to emit listener registration requests on the service bus

type EventMessage

type EventMessage struct {
	Name string        `json:"name"`
	Data []interface{} `json:"data"`
}
type MenuOnMessage struct {
	// MenuID is the id of the menu item we are interested in
	MenuID string
	// Callback is called when the menu is clicked
	Callback func(*menu.MenuItem)
}

MenuOnMessage is used to emit listener registration requests on the service bus

type OnEventMessage

type OnEventMessage struct {
	Name     string
	Callback func(optionalData ...interface{})
	Counter  int
}

type TrayOnMessage

type TrayOnMessage struct {
	// MenuID is the id of the menu item we are interested in
	MenuID string
	// Callback is called when the menu is clicked
	Callback func(*menu.MenuItem)
}

TrayOnMessage is used to emit listener registration requests on the service bus

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL