dstservice

package
v1.1.7 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2022 License: Apache-2.0 Imports: 11 Imported by: 1

Documentation

Index

Constants

View Source
const (
	RequestHeader = "__request_header__"
)

Variables

Functions

This section is empty.

Types

type Method

type Method interface {
	gnetws.Serialize

	Args() (x interface{})
	DoProc(ctx *eventserve.GnetContext, conn *websocket.Conn, x interface{})
}

type Packet

type Packet interface {
	io.Reader
	Head() string
}

type WebSocketHandler

type WebSocketHandler struct {
	Path    string
	Plugins *plugins
	// contains filtered or unexported fields
}

func (*WebSocketHandler) Blueprint

func (self *WebSocketHandler) Blueprint(path string, args Packet, codec gnetws.Serialize) *blueprint

func (*WebSocketHandler) Proc

func (self *WebSocketHandler) Proc(ctx *eventserve.GnetContext, conn gnet.Conn) error

func (*WebSocketHandler) Route

func (self *WebSocketHandler) Route(path string, codec gnetws.Serialize, proc websocket.Handler) (err error)

type WebSocketUP

type WebSocketUP struct {
	ws.Upgrader
	WebSocketHandler
}

func NewWebSocketHandler

func NewWebSocketHandler() *WebSocketUP

func (*WebSocketUP) Proc

func (self *WebSocketUP) Proc(ctx *eventserve.GnetContext, conn gnet.Conn) error

Jump to

Keyboard shortcuts

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