Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConfigCreator ¶
type ConfigCreator func() interface{}
type ConfigCreatorCache ¶
type ConfigCreatorCache map[string]ConfigCreator
func (ConfigCreatorCache) CreateConfig ¶
func (v ConfigCreatorCache) CreateConfig(id string) (interface{}, error)
func (ConfigCreatorCache) RegisterCreator ¶
func (v ConfigCreatorCache) RegisterCreator(id string, creator ConfigCreator) error
type JSONConfigLoader ¶
type JSONConfigLoader struct {
// contains filtered or unexported fields
}
func NewJSONConfigLoader ¶
func NewJSONConfigLoader(cache ConfigCreatorCache, idKey string, configKey string) *JSONConfigLoader
func (*JSONConfigLoader) Load ¶
func (v *JSONConfigLoader) Load(raw []byte) (interface{}, string, error)
func (*JSONConfigLoader) LoadWithID ¶
func (v *JSONConfigLoader) LoadWithID(raw []byte, id string) (interface{}, error)
Click to show internal directories.
Click to hide internal directories.