Class: Prefab::CriteriaEvaluator::MatchResult
- Inherits:
-
Object
- Object
- Prefab::CriteriaEvaluator::MatchResult
- Defined in:
- lib/prefab/criteria_evaluator.rb
Instance Attribute Summary collapse
-
#error ⇒ Object
readonly
Returns the value of attribute error.
-
#matched ⇒ Object
readonly
Returns the value of attribute matched.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(matched:, error: false) ⇒ MatchResult
constructor
A new instance of MatchResult.
Constructor Details
#initialize(matched:, error: false) ⇒ MatchResult
Returns a new instance of MatchResult.
338 339 340 341 |
# File 'lib/prefab/criteria_evaluator.rb', line 338 def initialize(matched:, error: false) @matched = matched @error = error end |
Instance Attribute Details
#error ⇒ Object (readonly)
Returns the value of attribute error.
324 325 326 |
# File 'lib/prefab/criteria_evaluator.rb', line 324 def error @error end |
#matched ⇒ Object (readonly)
Returns the value of attribute matched.
324 325 326 |
# File 'lib/prefab/criteria_evaluator.rb', line 324 def matched @matched end |
Class Method Details
.error ⇒ Object
334 335 336 |
# File 'lib/prefab/criteria_evaluator.rb', line 334 def self.error new(matched: false, error: true) end |
.matched ⇒ Object
326 327 328 |
# File 'lib/prefab/criteria_evaluator.rb', line 326 def self.matched new(matched: true) end |
.not_matched ⇒ Object
330 331 332 |
# File 'lib/prefab/criteria_evaluator.rb', line 330 def self.not_matched new(matched: false) end |