Documentation ¶
Index ¶
- Variables
- type AttrValueRule
- type PartialContentEvaluationRule
- type SetRule
- func (r *SetRule[T]) Check(runner tflint.Runner) error
- func (b SetRule) EnableFailOnEvaluationError()
- func (b SetRule) Enabled() bool
- func (b SetRule) GetAttributeName() string
- func (b SetRule) GetNestedBlockType() *string
- func (b SetRule) GetResourceType() string
- func (r *SetRule[T]) Name() string
- func (b SetRule) Severity() tflint.Severity
- type SimpleRule
- func (r *SimpleRule[T]) Check(runner tflint.Runner) error
- func (b SimpleRule) EnableFailOnEvaluationError()
- func (b SimpleRule) Enabled() bool
- func (b SimpleRule) GetAttributeName() string
- func (b SimpleRule) GetNestedBlockType() *string
- func (b SimpleRule) GetResourceType() string
- func (r *SimpleRule[T]) Link() string
- func (r *SimpleRule[T]) Name() string
- func (b SimpleRule) Severity() tflint.Severity
- type UnknownValueRule
- func (r *UnknownValueRule) Check(runner tflint.Runner) error
- func (b UnknownValueRule) EnableFailOnEvaluationError()
- func (b UnknownValueRule) Enabled() bool
- func (b UnknownValueRule) GetAttributeName() string
- func (r *UnknownValueRule) GetNestedBlockType() *string
- func (b UnknownValueRule) GetResourceType() string
- func (r *UnknownValueRule) Link() string
- func (r *UnknownValueRule) Name() string
- func (b UnknownValueRule) Severity() tflint.Severity
Constants ¶
This section is empty.
Variables ¶
var AppFs = afero.Afero{ Fs: afero.NewOsFs(), }
Functions ¶
This section is empty.
Types ¶
type AttrValueRule ¶
type PartialContentEvaluationRule ¶ added in v0.12.0
type PartialContentEvaluationRule interface {
EnableFailOnEvaluationError()
}
type SetRule ¶
type SetRule[T cmp.Ordered] struct { tflint.DefaultRule // Embed the default rule to reuse its implementation // contains filtered or unexported fields }
SetRule checks whether a list of numbers attribute value is one of the expected values. It is not concerned with the order of the numbers in the list.
func NewSetRule ¶
func NewSetRule[T cmp.Ordered](resourceType string, attributeName string, expectedValues [][]T, link string, ruleName string) *SetRule[T]
NewSetRule returns a new rule with the given resource type, attribute name, and expected values.
func (SetRule) EnableFailOnEvaluationError ¶ added in v0.12.0
func (b SetRule) EnableFailOnEvaluationError()
func (SetRule) GetAttributeName ¶
func (b SetRule) GetAttributeName() string
func (SetRule) GetNestedBlockType ¶
func (b SetRule) GetNestedBlockType() *string
func (SetRule) GetResourceType ¶
func (b SetRule) GetResourceType() string
type SimpleRule ¶
type SimpleRule[T any] struct { tflint.DefaultRule // Embed the default rule to reuse its implementation // contains filtered or unexported fields }
SimpleRule checks whether a string attribute value is one of the expected values. It can be used to check string, number, and bool attributes.
func NewSimpleNestedBlockRule ¶
func NewSimpleNestedBlockRule[T any](resourceType, nestedBlockType, attributeName string, expectedValues []T, link string, mustExist bool, ruleName string) *SimpleRule[T]
NewSimpleNestedBlockRule returns a new rule with the given resource type, attribute name, and expected values.
func NewSimpleRule ¶
func NewSimpleRule[T any](resourceType, attributeName string, expectedValues []T, link string, mustExist bool, ruleName string) *SimpleRule[T]
NewSimpleRule returns a new rule with the given resource type, attribute name, and expected values.
func (SimpleRule) EnableFailOnEvaluationError ¶ added in v0.12.0
func (b SimpleRule) EnableFailOnEvaluationError()
func (SimpleRule) GetAttributeName ¶
func (b SimpleRule) GetAttributeName() string
func (SimpleRule) GetNestedBlockType ¶
func (b SimpleRule) GetNestedBlockType() *string
func (SimpleRule) GetResourceType ¶
func (b SimpleRule) GetResourceType() string
func (*SimpleRule[T]) Link ¶
func (r *SimpleRule[T]) Link() string
func (*SimpleRule[T]) Name ¶
func (r *SimpleRule[T]) Name() string
type UnknownValueRule ¶
type UnknownValueRule struct { tflint.DefaultRule // Embed the default rule to reuse its implementation // contains filtered or unexported fields }
UnknownValueRule checks whether an attribute value is null or part of a variable with no default value.
func NewUnknownValueNestedBlockRule ¶
func NewUnknownValueNestedBlockRule(resourceType, nestedBlockType, attributeName, link string, ruleName string) *UnknownValueRule
NewUnknownValueNestedBlockRule returns a new rule with the given resource type, nested block type, and attribute name
func NewUnknownValueRule ¶
func NewUnknownValueRule(resourceType, attributeName, link string, ruleName string) *UnknownValueRule
NewUnknownValueRule returns a new rule with the given resource type, and attribute name
func (UnknownValueRule) EnableFailOnEvaluationError ¶ added in v0.12.0
func (b UnknownValueRule) EnableFailOnEvaluationError()
func (UnknownValueRule) GetAttributeName ¶
func (b UnknownValueRule) GetAttributeName() string
func (*UnknownValueRule) GetNestedBlockType ¶
func (r *UnknownValueRule) GetNestedBlockType() *string
func (UnknownValueRule) GetResourceType ¶
func (b UnknownValueRule) GetResourceType() string
func (*UnknownValueRule) Link ¶
func (r *UnknownValueRule) Link() string
func (*UnknownValueRule) Name ¶
func (r *UnknownValueRule) Name() string