Documentation ¶
Index ¶
- func CheckDuplicateKeys(json string) error
- func FormatJSONSyntaxError(data io.Reader, offset int64) (highlight string)
- func GetVersion(filename string, clnt etcd.Client) (version string, err error)
- func SaveConfig(data interface{}, filename string, clnt etcd.Client) (err error)
- type Config
- type ConfigEncoding
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckDuplicateKeys ¶
CheckDuplicateKeys - checks for duplicate entries in a JSON file
func FormatJSONSyntaxError ¶
FormatJSONSyntaxError generates a pretty printed json syntax error since golang doesn't provide an easy way to report the location of the error
func GetVersion ¶
GetVersion - extracts the version information.
Types ¶
type Config ¶
type Config interface { String() string Version() string Save(string) error Load(string) error Data() interface{} Diff(Config) ([]structs.Field, error) DeepDiff(Config) ([]structs.Field, error) }
Config - generic config interface functions
func LoadConfig ¶
LoadConfig - loads json config from filename for the a given struct data
Click to show internal directories.
Click to hide internal directories.