socket

package
v0.0.0-...-e91a5b0 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitAuthenticationCache

func InitAuthenticationCache()

func NewClientSocket

func NewClientSocket(ctx context.Context, hub *Hub, ws *websocket.Conn)

Types

type AuthenticationCache

type AuthenticationCache struct {
	sync.Mutex
	// contains filtered or unexported fields
}

type Client

type Client struct {
	ID     uuid.UUID
	UserID int64
	// contains filtered or unexported fields
}

type Hub

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

func NewHub

func NewHub() *Hub

func (*Hub) Run

func (hub *Hub) Run()

type SocketController

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

func (*SocketController) HandleTokenAuthentication

func (sc *SocketController) HandleTokenAuthentication(c *gin.Context)

func (*SocketController) HandleWebSocket

func (sc *SocketController) HandleWebSocket(hub *Hub, c *gin.Context)

type Ticket

type Ticket struct {
	Token      string
	ExpireTime time.Time
}

Jump to

Keyboard shortcuts

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