Class: Datadog::AIGuard::Evaluation::NoOpResult
- Inherits:
-
Object
- Object
- Datadog::AIGuard::Evaluation::NoOpResult
- Defined in:
- lib/datadog/ai_guard/evaluation/no_op_result.rb
Overview
Class for emulating AI Guard evaluation result when AI Guard is disabled.
Instance Attribute Summary collapse
-
#action ⇒ Object
readonly
Returns the value of attribute action.
-
#reason ⇒ Object
readonly
Returns the value of attribute reason.
-
#sds_findings ⇒ Object
readonly
Returns the value of attribute sds_findings.
-
#tag_probabilities ⇒ Object
readonly
Returns the value of attribute tag_probabilities.
-
#tags ⇒ Object
readonly
Returns the value of attribute tags.
Instance Method Summary collapse
- #abort? ⇒ Boolean
- #allow? ⇒ Boolean
- #blocking_enabled? ⇒ Boolean
- #deny? ⇒ Boolean
-
#initialize ⇒ NoOpResult
constructor
A new instance of NoOpResult.
Constructor Details
#initialize ⇒ NoOpResult
Returns a new instance of NoOpResult.
10 11 12 13 14 15 16 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 10 def initialize @action = Result::ALLOW_ACTION @reason = "AI Guard is disabled" @tags = [] @sds_findings = [] @tag_probabilities = {} end |
Instance Attribute Details
#action ⇒ Object (readonly)
Returns the value of attribute action.
8 9 10 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 8 def action @action end |
#reason ⇒ Object (readonly)
Returns the value of attribute reason.
8 9 10 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 8 def reason @reason end |
#sds_findings ⇒ Object (readonly)
Returns the value of attribute sds_findings.
8 9 10 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 8 def sds_findings @sds_findings end |
#tag_probabilities ⇒ Object (readonly)
Returns the value of attribute tag_probabilities.
8 9 10 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 8 def tag_probabilities @tag_probabilities end |
#tags ⇒ Object (readonly)
Returns the value of attribute tags.
8 9 10 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 8 def @tags end |
Instance Method Details
#abort? ⇒ Boolean
26 27 28 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 26 def abort? false end |
#allow? ⇒ Boolean
18 19 20 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 18 def allow? true end |
#blocking_enabled? ⇒ Boolean
30 31 32 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 30 def blocking_enabled? false end |
#deny? ⇒ Boolean
22 23 24 |
# File 'lib/datadog/ai_guard/evaluation/no_op_result.rb', line 22 def deny? false end |