config

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2019 License: GPL-3.0 Imports: 12 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 GetConfigInstance

func GetConfigInstance() *Config

singleton pattern for Config

func (*Config) Register

func (c *Config) Register(name string, config Iconfig) error

module register a config

func (*Config) SetPath

func (c *Config) SetPath(path string)

func (*Config) UnRegister

func (c *Config) UnRegister(name string) error

type Iconfig

type Iconfig interface {
	toml.UnmarshalerRec
	toml.MarshalerRec
	SetDefaultConfig() error
	SetSpecialConfig() error
}

interface for module config

Jump to

Keyboard shortcuts

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