Class: YDIM::Reconciler::Result
- Inherits:
-
Object
- Object
- YDIM::Reconciler::Result
- Defined in:
- lib/ydim/reconciler.rb
Overview
What a reconciliation run found, including the entries that never made it as far as matching -- silently dropping those would make the report look like it had seen everything.
Instance Attribute Summary collapse
-
#matches ⇒ Object
readonly
Returns the value of attribute matches.
-
#skipped ⇒ Object
readonly
Returns the value of attribute skipped.
Instance Method Summary collapse
- #applicable ⇒ Object
- #applied ⇒ Object
-
#initialize ⇒ Result
constructor
A new instance of Result.
- #review ⇒ Object
- #unmatched ⇒ Object
Constructor Details
#initialize ⇒ Result
Returns a new instance of Result.
75 76 77 78 |
# File 'lib/ydim/reconciler.rb', line 75 def initialize @matches = [] @skipped = Hash.new(0) end |
Instance Attribute Details
#matches ⇒ Object (readonly)
Returns the value of attribute matches.
74 75 76 |
# File 'lib/ydim/reconciler.rb', line 74 def matches @matches end |
#skipped ⇒ Object (readonly)
Returns the value of attribute skipped.
74 75 76 |
# File 'lib/ydim/reconciler.rb', line 74 def skipped @skipped end |
Instance Method Details
#applicable ⇒ Object
79 80 81 |
# File 'lib/ydim/reconciler.rb', line 79 def applicable @matches.select { |match| match.applicable? } end |
#applied ⇒ Object
88 89 90 |
# File 'lib/ydim/reconciler.rb', line 88 def applied @matches.select { |match| match.applied? } end |
#review ⇒ Object
82 83 84 |
# File 'lib/ydim/reconciler.rb', line 82 def review @matches.select { |match| match.review? } end |
#unmatched ⇒ Object
85 86 87 |
# File 'lib/ydim/reconciler.rb', line 85 def unmatched @matches.select { |match| match.state == :unmatched } end |