Documentation
¶
Overview ¶
Package dynconf implements dynamic configuration.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrKeyNotFound = errors.New("dynconf: key not found")
ErrKeyNotFound is returned when a key has not been found.
Functions ¶
This section is empty.
Types ¶
type Value ¶
type Value interface {
// Unmarshal unmarshals the value from the given data.
Unmarshal(data []byte) (err error)
// String returns a string representing the value.
String() string
}
Value represents a structured value of a key.
type ValueFactory ¶
type ValueFactory func() Value
ValueFactory is the type of the function returning a new value.
type ValueOutdatedCallback ¶
type ValueOutdatedCallback interface {
// OnOutdated is called once after the value, as the latest value,
// has been replaced with another value.
OnOutdated()
}
ValueOutdatedCallback represents an optional callback to Value.
type ValueWatchRemovedCallback ¶
type ValueWatchRemovedCallback interface {
// OnWatchRemoved is called once after the watch has been removed,
// which is set on the key for the value.
OnWatchRemoved()
}
ValueWatchRemovedCallback represents an optional callback to Value.
type Watch ¶
type Watch struct {
// contains filtered or unexported fields
}
Watch presents a watch on a key.
type Watcher ¶
type Watcher struct {
// contains filtered or unexported fields
}
Watcher presents a watcher for dynamic configuration.
Click to show internal directories.
Click to hide internal directories.