config

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Initialize

func Initialize()

Initialize 初始化

Types

type Config

type Config struct {
	Server ServerConfig `mapstructure:"server"`
}

Config config

var (
	C Config
)

C 全局配置

func (Config) Show

func (c Config) Show()

Show 以 yaml 格式输出配置信息

func (Config) String

func (c Config) String() string

type ServerConfig

type ServerConfig struct {
	Listen         string `mapstructure:"listen" yaml:"listen"`
	ClientReadBuf  int    `mapstructure:"client_read_buf" yaml:"client_read_buf"`
	ClientWriteBuf int    `mapstructure:"client_Write_buf" yaml:"client_Write_buf"`
}

ServerConfig 服务配置

Jump to

Keyboard shortcuts

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