gatewayservicelogic

package
v0.0.0-...-68aaea9 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrTimeout = errors.New("timeout")
View Source
var WsManager *wsManager

Functions

func InitWsManager

func InitWsManager(svcCtx *svc.ServiceContext)

Types

type GetSessionDescriptionLogic

type GetSessionDescriptionLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewGetSessionDescriptionLogic

func NewGetSessionDescriptionLogic(ctx context.Context, svcCtx *svc.ServiceContext) *GetSessionDescriptionLogic

func (*GetSessionDescriptionLogic) GetSessionDescription

type NodeLogic

type NodeLogic struct {
	logx.Logger
	// contains filtered or unexported fields
}

func NewNodeLogic

func NewNodeLogic(ctx context.Context, svcCtx *svc.ServiceContext) *NodeLogic

func (*NodeLogic) Node

func (l *NodeLogic) Node(in *pb.NodeReq) (*pb.NodeResp, error)

type WsConnection

type WsConnection struct {
	Id         int64
	Connection *websocket.Conn
	AppId      string
	Ctx        context.Context
}

type WsConnectionMap

type WsConnectionMap struct {
	// contains filtered or unexported fields
}

func (*WsConnectionMap) Delete

func (w *WsConnectionMap) Delete(userId string, connectionId int64)

func (*WsConnectionMap) GetAliveTime

func (w *WsConnectionMap) GetAliveTime(connectionId int64) (time.Time, bool)

func (*WsConnectionMap) GetAll

func (w *WsConnectionMap) GetAll() []*WsConnection

func (*WsConnectionMap) GetByAppId

func (w *WsConnectionMap) GetByAppId(appId string) ([]*WsConnection, bool)

func (*WsConnectionMap) GetByConnectionId

func (w *WsConnectionMap) GetByConnectionId(connectionId int64) (*WsConnection, bool)

func (*WsConnectionMap) Set

func (w *WsConnectionMap) Set(connectionId int64, value *WsConnection)

func (*WsConnectionMap) SetAliveTime

func (w *WsConnectionMap) SetAliveTime(ctx context.Context, connectionId int64, aliveTime time.Time)

Jump to

Keyboard shortcuts

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