Documentation
¶
Index ¶
- Constants
- func CueValidate(cueTpl string) error
- func LoadConfigObjectFromContent(cfgType parametersv1alpha1.CfgFileFormat, rawData string) (map[string]interface{}, error)
- func ValidateConfigWithCue(cueString string, cfgType parametersv1alpha1.CfgFileFormat, rawData string) error
- type ConfigValidator
- type CueType
- type CueWalkVisitor
- type ValidatorOptions
Constants ¶
View Source
const ( StoreUnit = 1024 KByte = 1 * StoreUnit MByte = KByte * StoreUnit GByte = MByte * StoreUnit TByte = GByte * StoreUnit PByte = TByte * StoreUnit EByte = PByte * StoreUnit ZByte = EByte * StoreUnit YByte = ZByte * StoreUnit )
View Source
const ( Millisecond = time.Duration(1) Second = 1000 * Millisecond Minute = 60 * Second Hour = 60 * Minute Day = 24 * Hour )
Variables ¶
This section is empty.
Functions ¶
func LoadConfigObjectFromContent ¶
func LoadConfigObjectFromContent(cfgType parametersv1alpha1.CfgFileFormat, rawData string) (map[string]interface{}, error)
func ValidateConfigWithCue ¶ added in v1.0.0
func ValidateConfigWithCue(cueString string, cfgType parametersv1alpha1.CfgFileFormat, rawData string) error
Types ¶
type ConfigValidator ¶
func NewConfigValidator ¶
func NewConfigValidator(paramsSchema *parametersv1alpha1.ParametersSchema, fileFormat *parametersv1alpha1.FileFormatConfig) ConfigValidator
type CueType ¶
type CueType string
CueType defines cue type +enum
const ( NullableType CueType = "nullable" FloatType CueType = "float" IntType CueType = "integer" BoolType CueType = "boolean" StringType CueType = "string" StructType CueType = "object" ListType CueType = "array" K8SQuantityType CueType = "quantity" ClassicStorageType CueType = "storage" ClassicTimeDurationType CueType = "timeDuration" )
type CueWalkVisitor ¶
type ValidatorOptions ¶
Click to show internal directories.
Click to hide internal directories.