tcp

package
v0.0.0-...-36ee774 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Action = &action{}
View Source
var Middleware = &middleware{}

Functions

func Router

func Router(s *router.Router[*socket.Stream[server.Conn], any])

func Start

func Start(host string, fn func())

Types

type Controller

type Controller struct{}

func (*Controller) Error

func (c *Controller) Error(sender socket.Emitter[server.Conn], event string, msg any) error

func (*Controller) Failed

func (c *Controller) Failed(sender socket.Emitter[server.Conn], event string, msg any) error

func (*Controller) Forbidden

func (c *Controller) Forbidden(sender socket.Emitter[server.Conn], event string, msg any) error

func (*Controller) Success

func (c *Controller) Success(sender socket.Emitter[server.Conn], event string, msg any) error

func (*Controller) WithCode

func (c *Controller) WithCode(sender socket.Emitter[server.Conn], event string, code uint32, msg any) error

Jump to

Keyboard shortcuts

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