jx/internal/data/config.go

30 lines
587 B
Go
Raw Permalink Normal View History

2024-08-15 15:12:42 +00:00
// Copyright 2024 Matthew Rich <matthewrich.conf@gmail.com>. All rights reserved.
package data
import (
"errors"
)
var (
ErrUnknownConfigurationType = errors.New("Unknown configuration type")
ErrUnknownConfigurationKey = errors.New("Unknown configuration key")
2024-08-15 15:12:42 +00:00
)
type ConfigurationValueGetter interface {
GetValue(key string) (any, error)
}
type ConfigurationValueChecker interface {
Has(key string) bool
}
type Configuration interface {
Identifier
Type() string
Reader
ConfigurationValueGetter
ConfigurationValueChecker
Clone() Configuration
}