server

package
v0.0.0-...-82c6a1a Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HttpServer

type HttpServer struct {
	*Server
}

HttpServer - custom http server structure.

func NewHttpServer

func NewHttpServer(port string, router *router.HttpRouter) *HttpServer

NewHttpServer - initiate new http server.

type Server

type Server struct {
	http.Server
}

Server Server - custom server structure.

func NewServer

func NewServer(port string, h http.Handler) *Server

NewServer - instantiate new server.

func (*Server) Serve

func (s *Server) Serve()

Serve - start listen and serve for incoming requests.

func (*Server) Shutdown

func (s *Server) Shutdown()

Shutdown - stop listen and serve for incoming requests.

type WsServer

type WsServer struct {
	*Server
	// contains filtered or unexported fields
}

WsServer - custom ws server structure.

func NewWsServer

func NewWsServer(pt string, ro *router.WsRouter) *WsServer

NewWsServer - Instantiate new ws server.

func (*WsServer) CountConnections

func (s *WsServer) CountConnections() int

Jump to

Keyboard shortcuts

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