utils

package
v0.0.0-...-ee6b5e2 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GlobalObj

type GlobalObj struct {
	// server
	//当前zinx全局的server对象
	TcpServer ziface.IServer
	//当前服务器主机监听的IP
	Host string
	//当前服务器主机监听的端口号
	TcpPort int
	//当前服务器的名称
	Name string
	//
	// ZInx
	//当前zinx的版本号
	Version string
	//当前服务器主机允许的最大连接数
	MaxConn int
	//当前zinx框架数据包的最大值
	MaxPackageSize uint32
}

存储一切有关zinx的全局参数, 供其他模块调用。

var GlobalObject *GlobalObj

定义一个全局的对外GlobalObj

func (*GlobalObj) Reload

func (g *GlobalObj) Reload()

从zinx.json去加载用户自定义的参数。

Jump to

Keyboard shortcuts

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