Class: JmesPathEvaluator
- Inherits:
-
Object
- Object
- JmesPathEvaluator
- Defined in:
- lib/cfn-nag/jmes_path_evaluator.rb
Instance Method Summary collapse
- #failure(id:, jmespath:, message:) ⇒ Object
-
#initialize(cfn_model) ⇒ JmesPathEvaluator
constructor
A new instance of JmesPathEvaluator.
- #violations ⇒ Object
- #warning(id:, jmespath:, message:) ⇒ Object
Constructor Details
#initialize(cfn_model) ⇒ JmesPathEvaluator
Returns a new instance of JmesPathEvaluator.
5 6 7 8 9 |
# File 'lib/cfn-nag/jmes_path_evaluator.rb', line 5 def initialize(cfn_model) @cfn_model = cfn_model @warnings = [] @failures = [] end |
Instance Method Details
#failure(id:, jmespath:, message:) ⇒ Object
18 19 20 21 22 23 |
# File 'lib/cfn-nag/jmes_path_evaluator.rb', line 18 def failure(id:, jmespath:, message:) violation id: id, jmespath: jmespath, message: , violation_type: Violation::FAILING_VIOLATION end |
#violations ⇒ Object
25 26 27 |
# File 'lib/cfn-nag/jmes_path_evaluator.rb', line 25 def violations @warnings + @failures end |