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.
336 337 338 339 |
# File 'lib/prefab/criteria_evaluator.rb', line 336 def initialize(matched:, error: false) @matched = matched @error = error end |
Instance Attribute Details
#error ⇒ Object (readonly)
Returns the value of attribute error.
322 323 324 |
# File 'lib/prefab/criteria_evaluator.rb', line 322 def error @error end |
#matched ⇒ Object (readonly)
Returns the value of attribute matched.
322 323 324 |
# File 'lib/prefab/criteria_evaluator.rb', line 322 def matched @matched end |
Class Method Details
.error ⇒ Object
332 333 334 |
# File 'lib/prefab/criteria_evaluator.rb', line 332 def self.error new(matched: false, error: true) end |
.matched ⇒ Object
324 325 326 |
# File 'lib/prefab/criteria_evaluator.rb', line 324 def self.matched new(matched: true) end |
.not_matched ⇒ Object
328 329 330 |
# File 'lib/prefab/criteria_evaluator.rb', line 328 def self.not_matched new(matched: false) end |