proto

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2022 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package proto specifies websocket protocol helpers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Decode

func Decode(data []byte) (*message.Message, error)

Decode implements websocket message decoding.

func Encode

func Encode(message protoreflect.ProtoMessage) ([]byte, error)

Encode implements websocket message encoding.

func NewErrorResponse

func NewErrorResponse(request *message.Message, err error) (*message.Message, error)

NewErrorResponse creates new Error message.

func NewOkResponse

func NewOkResponse(request *message.Message) (*message.Message, error)

NewOkResponse creates new Ok message.

func NewRuntimeEvent

func NewRuntimeEvent(subscriptionUID string, event runtime.Event) (*message.Message, error)

NewRuntimeEvent creates new runtime event.

func NewSubscribedResponse

func NewSubscribedResponse(request *message.Message, id string) (*message.Message, error)

NewSubscribedResponse compose subscribed response.

Types

This section is empty.

Jump to

Keyboard shortcuts

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