Documentation
¶
Index ¶
- func AddWatch(event func(e fsnotify.Event))
- func All() map[string]any
- func GenerateConfig() []byte
- func Get(path string, defaultValue ...any) string
- func GetBool(path string, defaultValue ...any) bool
- func GetFloat64(path string, defaultValue ...any) float64
- func GetInt(path string, defaultValue ...any) int
- func GetInt64(path string, defaultValue ...any) int64
- func GetIntSlice(path string) []int
- func GetString(path string, defaultValue ...any) string
- func GetStringMapString(path string) map[string]string
- func GetStringSlice(path string) []string
- func GetUint(path string, defaultValue ...any) uint
- func IsSet(path string) bool
- func OpenConfigChangeEvent()
- type ExclusivePreferences
- func (itself *ExclusivePreferences) Get(path string, defaultValue ...any) string
- func (itself *ExclusivePreferences) GetBool(path string, defaultValue ...any) bool
- func (itself *ExclusivePreferences) GetFloat64(path string, defaultValue ...any) float64
- func (itself *ExclusivePreferences) GetInt(path string, defaultValue ...any) int
- func (itself *ExclusivePreferences) GetInt64(path string, defaultValue ...any) int64
- func (itself *ExclusivePreferences) GetString(path string, defaultValue ...any) string
- func (itself *ExclusivePreferences) GetStringMapString(path string) map[string]string
- func (itself *ExclusivePreferences) GetUint(path string, defaultValue ...any) uint
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateConfig ¶ added in v0.0.4
func GenerateConfig() []byte
func GetFloat64 ¶
GetFloat64 获取 float64 类型的配置信息
func GetIntSlice ¶
func GetStringMapString ¶
GetStringMapString 获取结构数据
func GetStringSlice ¶
Types ¶
type ExclusivePreferences ¶
type ExclusivePreferences struct {
// contains filtered or unexported fields
}
func GetExclusivePreferences ¶
func GetExclusivePreferences(prefix string) ExclusivePreferences
func (*ExclusivePreferences) Get ¶
func (itself *ExclusivePreferences) Get(path string, defaultValue ...any) string
func (*ExclusivePreferences) GetBool ¶
func (itself *ExclusivePreferences) GetBool(path string, defaultValue ...any) bool
func (*ExclusivePreferences) GetFloat64 ¶
func (itself *ExclusivePreferences) GetFloat64(path string, defaultValue ...any) float64
func (*ExclusivePreferences) GetInt ¶
func (itself *ExclusivePreferences) GetInt(path string, defaultValue ...any) int
func (*ExclusivePreferences) GetInt64 ¶
func (itself *ExclusivePreferences) GetInt64(path string, defaultValue ...any) int64
func (*ExclusivePreferences) GetString ¶
func (itself *ExclusivePreferences) GetString(path string, defaultValue ...any) string
func (*ExclusivePreferences) GetStringMapString ¶
func (itself *ExclusivePreferences) GetStringMapString(path string) map[string]string
Click to show internal directories.
Click to hide internal directories.