Documentation
¶
Index ¶
- Constants
- Variables
- func AnyRuleMatches(rules []catalog.WorkflowRule, evalContext map[string]interface{}) bool
- func EvaluateRule(rule catalog.WorkflowRule, evalContext map[string]interface{}) bool
- func EvaluateRules(rules []catalog.WorkflowRule, evalContext map[string]interface{}) int
- func EvaluateRulesAsText(rules []catalog.WorkflowRule, evalContext map[string]interface{}) string
- func GetModuleRuleContext(env map[string]string, module *analyzerapi.ProjectModule) map[string]interface{}
- func GetProjectRuleContext(env map[string]string, modules []*analyzerapi.ProjectModule) map[string]interface{}
- func GetRuleContext(env map[string]string) map[string]interface{}
Constants ¶
View Source
const ( ModuleName = "MODULE_NAME" ModuleSlug = "MODULE_SLUG" ModuleType = "MODULE_TYPE" ModuleBuildSystem = "MODULE_BUILD_SYSTEM" ModuleBuildSystemSyntax = "MODULE_BUILD_SYSTEM_SYNTAX" ModuleConfigType = "MODULE_CONFIG_TYPE" ModuleSpecificationType = "MODULE_SPECIFICATION_TYPE" ModuleDeploymentSpec = "MODULE_DEPLOYMENT_SPEC" ModuleDeploymentType = "MODULE_DEPLOYMENT_TYPE" ModuleFiles = "MODULE_FILES" )
Variables ¶
View Source
var ReservedVariables = []string{ ModuleName, ModuleSlug, ModuleType, ModuleBuildSystem, ModuleBuildSystemSyntax, ModuleConfigType, ModuleSpecificationType, ModuleDeploymentSpec, ModuleDeploymentType, ModuleFiles, }
Functions ¶
func AnyRuleMatches ¶
func AnyRuleMatches(rules []catalog.WorkflowRule, evalContext map[string]interface{}) bool
AnyRuleMatches will return true if at least one rule matches, if no rules are provided this always returns true
func EvaluateRule ¶
func EvaluateRule(rule catalog.WorkflowRule, evalContext map[string]interface{}) bool
EvaluateRule will evaluate a WorkflowRule and return the result
func EvaluateRules ¶
func EvaluateRules(rules []catalog.WorkflowRule, evalContext map[string]interface{}) int
EvaluateRules will check all rules and returns the count of matching rules
func EvaluateRulesAsText ¶
func EvaluateRulesAsText(rules []catalog.WorkflowRule, evalContext map[string]interface{}) string
EvaluateRulesAsText will check all rules and returns the count of matching rules in the following format: 2/5
func GetModuleRuleContext ¶
func GetModuleRuleContext(env map[string]string, module *analyzerapi.ProjectModule) map[string]interface{}
func GetProjectRuleContext ¶ added in v0.4.1
func GetProjectRuleContext(env map[string]string, modules []*analyzerapi.ProjectModule) map[string]interface{}
func GetRuleContext ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.