Documentation
¶
Index ¶
- Constants
- Variables
- func Encrypt(publicKey *rsa.PublicKey, plainText []byte) ([]byte, error)
- type Connection
- type Context
- type HandlerFunc
- type Key
- type Options
- type Packet
- func (*Packet) Descriptor() ([]byte, []int)deprecated
- func (x *Packet) GetAction() string
- func (x *Packet) GetBody() []byte
- func (x *Packet) GetCompleted() bool
- func (x *Packet) GetCreated() int64
- func (x *Packet) GetHeaders() []string
- func (x *Packet) GetListener() int32
- func (x *Packet) GetSender() string
- func (*Packet) ProtoMessage()
- func (x *Packet) ProtoReflect() protoreflect.Message
- func (x *Packet) Reset()
- func (x *Packet) String() string
Constants ¶
View Source
const ( TouchAction = "Touch" RejectAction = "Rejected" )
View Source
const ( TouchAction = "Touch" RejectAction = "Rejected" )
Variables ¶
View Source
var File_packet_proto protoreflect.FileDescriptor
Functions ¶
Types ¶
type Connection ¶
type Connection struct {
// contains filtered or unexported fields
}
func (*Connection) AddHandler ¶
func (c *Connection) AddHandler(action string, handler HandlerFunc)
func (*Connection) AddReplayHandler ¶
func (c *Connection) AddReplayHandler(action string, handler HandlerFunc)
func (*Connection) Start ¶
func (c *Connection) Start()
type HandlerFunc ¶
type Key ¶
type Key struct {
// contains filtered or unexported fields
}
func GenerateKey ¶
func (Key) PrivateKeyToPemString ¶
func (Key) PublicKeyToPemString ¶
type Packet ¶
type Packet struct {
Action string `protobuf:"bytes,1,opt,name=Action,proto3" json:"Action,omitempty"`
Listener int32 `protobuf:"varint,2,opt,name=Listener,proto3" json:"Listener,omitempty"`
Headers []string `protobuf:"bytes,5,rep,name=Headers,proto3" json:"Headers,omitempty"`
Sender string `protobuf:"bytes,6,opt,name=sender,proto3" json:"sender,omitempty"`
Completed bool `protobuf:"varint,7,opt,name=completed,proto3" json:"completed,omitempty"`
Body []byte `protobuf:"bytes,8,opt,name=Body,proto3" json:"Body,omitempty"`
Created int64 `protobuf:"varint,9,opt,name=created,proto3" json:"created,omitempty"`
// contains filtered or unexported fields
}
func (*Packet) Descriptor
deprecated
func (*Packet) GetCompleted ¶
func (*Packet) GetCreated ¶
func (*Packet) GetHeaders ¶
func (*Packet) GetListener ¶
func (*Packet) ProtoMessage ¶
func (*Packet) ProtoMessage()
func (*Packet) ProtoReflect ¶
func (x *Packet) ProtoReflect() protoreflect.Message
Click to show internal directories.
Click to hide internal directories.