utils

package
v0.0.0-...-adac0c8 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Time allowed to write a message to the peer.
	WriteWait = 10 * time.Second

	// Time allowed to read the next pong message from the peer.
	PongWait = 10 * time.Second

	// Send pings to peer with this period. Must be less than pongWait.
	PingPeriod = (PongWait * 8) / 10

	// Maximum message size allowed from peer.
	MaxMessageSize = 512
)

Variables

View Source
var (
	Newline = []byte{'\n'}
	Space   = []byte{' '}
)

Functions

func GetCommandFromMap

func GetCommandFromMap(messageMap map[string]interface{}) (int, bool)

func GetLocalIP

func GetLocalIP() (string, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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