serverconf

package
v0.0.0-...-d8243a5 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2021 License: Unlicense Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

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

func New

func New(cfgMap map[string]string) *Config

Create a new Config using cfgMap as the intial internal config map. If cfgMap is nil, ConfigWithMap will create a new config map.

func (*Config) BoolValue

func (cfg *Config) BoolValue(key string) (boolval bool)

BoolValue gets the value fo a sepcific config key as a bool

func (*Config) GetAll

func (cfg *Config) GetAll() (all map[string]string)

GetAll gets a copy of the Config's internal config map

func (*Config) IntValue

func (cfg *Config) IntValue(key string) (intval int)

IntValue gets the value of a speific config key as an int

func (*Config) Reset

func (cfg *Config) Reset(key string)

Reset the value of a config key

func (*Config) Set

func (cfg *Config) Set(key string, value string)

Set a new value for a config key

func (*Config) StringValue

func (cfg *Config) StringValue(key string) (value string)

StringValue gets the value of a specific config key encoded as a string

func (*Config) Uint32Value

func (cfg *Config) Uint32Value(key string) (uint32val uint32)

Uint32Value gets the value of a specific config key as a uint32

Jump to

Keyboard shortcuts

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