sconf

package
v1.4.13 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2021 License: BSD-3-Clause Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FileAutoCheck

type FileAutoCheck struct {
	// contains filtered or unexported fields
}

func NewFileAutoCheck

func NewFileAutoCheck(file string) *FileAutoCheck

func (*FileAutoCheck) Check

func (m *FileAutoCheck) Check() (bool, []byte, error)

type TierConf

type TierConf struct {
	// contains filtered or unexported fields
}

func NewTierConf

func NewTierConf() *TierConf

func (*TierConf) GetConf

func (m *TierConf) GetConf() map[string]map[string]string

func (*TierConf) Load

func (m *TierConf) Load(cfg []byte) error

func (*TierConf) LoadFromConf

func (m *TierConf) LoadFromConf(cfg map[string]map[string]string)

func (*TierConf) LoadFromFile

func (m *TierConf) LoadFromFile(conf string) error

func (*TierConf) LoadFromOneFile

func (m *TierConf) LoadFromOneFile(conf string) error

func (*TierConf) StringCheck

func (m *TierConf) StringCheck() (string, error)

func (*TierConf) ToBool

func (m *TierConf) ToBool(section string, property string) (bool, error)

func (*TierConf) ToBoolWithDefault

func (m *TierConf) ToBoolWithDefault(section string, property string, deft bool) bool

func (*TierConf) ToFloat32

func (m *TierConf) ToFloat32(section string, property string) (float32, error)

func (*TierConf) ToFloat64

func (m *TierConf) ToFloat64(section string, property string) (float64, error)

func (*TierConf) ToInt

func (m *TierConf) ToInt(section string, property string) (int, error)

func (*TierConf) ToInt32

func (m *TierConf) ToInt32(section string, property string) (int32, error)

func (*TierConf) ToInt64

func (m *TierConf) ToInt64(section string, property string) (int64, error)

func (*TierConf) ToIntWithDefault

func (m *TierConf) ToIntWithDefault(section string, property string, deft int) int

func (*TierConf) ToSection

func (m *TierConf) ToSection(section string) (map[string]string, error)

func (*TierConf) ToSliceInt

func (m *TierConf) ToSliceInt(section string, property string, sep string) ([]int, error)

func (*TierConf) ToSliceString

func (m *TierConf) ToSliceString(section string, property string, sep string) ([]string, error)

func (*TierConf) ToSliceStringWithDefault

func (m *TierConf) ToSliceStringWithDefault(section string, property string, sep string, deft []string) []string

func (*TierConf) ToString

func (m *TierConf) ToString(section string, property string) (string, error)

func (*TierConf) ToStringWithDefault

func (m *TierConf) ToStringWithDefault(section string, property string, deft string) string

func (*TierConf) ToUint32

func (m *TierConf) ToUint32(section string, property string) (uint32, error)

func (*TierConf) ToUint64

func (m *TierConf) ToUint64(section string, property string) (uint64, error)

func (*TierConf) Unmarshal

func (m *TierConf) Unmarshal(v interface{}) error

内层struct: struct {Type,map[string]Type} 1. struct {struct {}, *struct{}, map[string]struct{}, map[string]*struct{} } 2. map[string] struct {} 3. map[string] *struct {}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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