conf

package
v0.0.20 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2022 License: MIT Imports: 16 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get(key string) interface{}

func GetBool

func GetBool(key string) bool

func GetBoold

func GetBoold(key string, d bool) bool

func GetBoold_c

func GetBoold_c(key string, d bool) (bool, chan int)

func GetInt

func GetInt(key string) int

func GetIntd

func GetIntd(key string, d int) int

func GetIntd_c

func GetIntd_c(key string, d int) (int, chan int)

func GetString

func GetString(key string) string

func GetStringd

func GetStringd(key string, d string) string

func GetStringd_c

func GetStringd_c(key string, d string) (string, chan int)

func Getd

func Getd(key string, d interface{}) interface{}

func Getd_c

func Getd_c(key string, d interface{}) (interface{}, chan int)

func Set

func Set(key string, v interface{})

Types

type Config

type Config struct {
	SysSetting sysSetting
	Setting    Settings
}

总配置

func GetConf

func GetConf() *Config

func InitConfg

func InitConfg() *Config

func (*Config) AnalysisSetting

func (c *Config) AnalysisSetting(s map[string]interface{})

解析配置

type Setting

type Setting struct {
	Key   string
	Value interface{}
	// contains filtered or unexported fields
}

type Settings

type Settings map[string]Setting

其他设置

func GetChild

func GetChild(key string) *Settings

func GetChildd

func GetChildd(key string) *Settings

func GetChildd_c

func GetChildd_c(key string) (*Settings, chan int)

func (*Settings) Get

func (s *Settings) Get(key string) interface{}

func (*Settings) GetBool

func (s *Settings) GetBool(key string) bool

func (*Settings) GetBoold

func (s *Settings) GetBoold(key string, d bool) bool

func (*Settings) GetBoold_c

func (s *Settings) GetBoold_c(key string, d bool) (bool, chan int)

func (*Settings) GetChild

func (s *Settings) GetChild(key string) *Settings

func (*Settings) GetChildd

func (s *Settings) GetChildd(key string) *Settings

func (*Settings) GetChildd_c

func (s *Settings) GetChildd_c(key string) (*Settings, chan int)

func (*Settings) GetInt

func (s *Settings) GetInt(key string) int

func (*Settings) GetIntd

func (s *Settings) GetIntd(key string, d int) int

func (*Settings) GetIntd_c

func (s *Settings) GetIntd_c(key string, d int) (int, chan int)

func (*Settings) GetString

func (s *Settings) GetString(key string) string

func (*Settings) GetStringd

func (s *Settings) GetStringd(key string, d string) string

func (*Settings) GetStringd_c

func (s *Settings) GetStringd_c(key string, d string) (string, chan int)

func (*Settings) Getd

func (s *Settings) Getd(key string, d interface{}) interface{}

func (*Settings) Getd_c

func (s *Settings) Getd_c(key string, d interface{}) (interface{}, chan int)

func (*Settings) Set

func (s *Settings) Set(key string, v interface{})

Jump to

Keyboard shortcuts

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