Documentation ¶
Index ¶
- Constants
- Variables
- func GetConfigMap() map[string]string
- func GetMappedConfigValue(config string) string
- func GetMappedRuleType(ruleType string) *registryinstanceclient.RuleType
- func GetRuleTypeMap() map[string]registryinstanceclient.RuleType
- func NewFlagSet(cmd *cobra.Command, f *factory.Factory) *flagSet
- type RuleErrHandler
- type Validator
Constants ¶
View Source
const ( ValidityRule = "validity" CompatibilityRule = "compatibility" )
View Source
const ( ConfigFULL = "full" ConfigSYNTAX_ONLY = "syntax-only" ConfigFULL_TRANSITIVE = "full-transitive" ConfigBACKWARD = "backward" ConfigBACKWARD_TRANSITIVE = "backward-transitive" ConfigFORWARD = "forward" ConfigFORWARD_TRANSITIVE = "forward-transitive" ConfigNONE = "none" )
Variables ¶
View Source
var ValidRuleConfigs = map[string][]string{ CompatibilityRule: {ConfigBACKWARD, ConfigBACKWARD_TRANSITIVE, ConfigFORWARD, ConfigFORWARD_TRANSITIVE, ConfigFULL, ConfigFULL_TRANSITIVE, ConfigNONE}, ValidityRule: {ConfigFULL, ConfigSYNTAX_ONLY, ConfigNONE}, }
View Source
var ValidRuleTypes = []string{ValidityRule, CompatibilityRule}
View Source
var ValidRules []string = []string{ValidityRule, CompatibilityRule}
Functions ¶
func GetConfigMap ¶
GetConfigMap returns the mappings for rule configurations
func GetMappedConfigValue ¶
GetConfigMap gets the mapped configuration value
func GetMappedRuleType ¶
func GetMappedRuleType(ruleType string) *registryinstanceclient.RuleType
GetMappedRuleType gets the mapped rule type value
func GetRuleTypeMap ¶
func GetRuleTypeMap() map[string]registryinstanceclient.RuleType
GetRuleTypeMap returns the mappings for rule types
Types ¶
type RuleErrHandler ¶
func (*RuleErrHandler) ArtifactNotFoundError ¶
func (r *RuleErrHandler) ArtifactNotFoundError(artifactID string) error
func (*RuleErrHandler) ConflictError ¶
func (r *RuleErrHandler) ConflictError(ruleType string) error
func (*RuleErrHandler) RuleNotEnabled ¶
func (r *RuleErrHandler) RuleNotEnabled(ruleType string) error
type Validator ¶
Validator is a struct to validate inputs for service registry rule operations
func (*Validator) IsValidRuleConfig ¶
func (*Validator) ValidateRuleType ¶
ValidateRuleType checks if value v is a valid value for --offset
Click to show internal directories.
Click to hide internal directories.