Documentation ¶
Index ¶
Constants ¶
View Source
const ( MsgNewSale = "new_event" MsgGasPrice = "gas_price" MsgCommand = "cmd" )
Variables ¶
View Source
var (
ErrEventNotSupported = errors.New("this event type is not supported")
)
* wsUpgrader is used to upgrade incomming HTTP requests into a persitent websocket connection.
Functions ¶
func StartWebUI ¶ added in v0.4.0
Types ¶
type GasPriceMessage ¶ added in v0.5.0
payloads for message types.
type Message ¶ added in v0.5.0
type Message struct { // Type is the message type sent Type string `json:"type"` // Payload is the data Based on the Type Payload any `json:"payload"` }
Message is the Messages sent over the websocket Used to differ between different actions.
type MessageHandler ¶ added in v0.5.0
MessageHandler is a function signature that is used to affect messages on the socket and triggered depending on the type.
type MessagePayload ¶ added in v0.5.0
type MessagePayload json.RawMessage
type NewEventMessage ¶ added in v0.5.0
payloads for message types.
type SendMessageMessage ¶ added in v0.5.0
SendMessageMessage is the payload sent in the send_message message.
Click to show internal directories.
Click to hide internal directories.