Class: StudFinder::Churn::Result
- Inherits:
-
Object
- Object
- StudFinder::Churn::Result
- Defined in:
- lib/stud_finder/churn.rb
Instance Attribute Summary collapse
-
#churn_commits ⇒ Object
readonly
Returns the value of attribute churn_commits.
-
#churn_lines ⇒ Object
readonly
Returns the value of attribute churn_lines.
-
#zero_inflated ⇒ Object
readonly
Returns the value of attribute zero_inflated.
-
#zero_percentage ⇒ Object
readonly
Returns the value of attribute zero_percentage.
Instance Method Summary collapse
- #counts ⇒ Object
-
#initialize(zero_inflated:, zero_percentage:, **values) ⇒ Result
constructor
A new instance of Result.
- #line_counts ⇒ Object
Constructor Details
#initialize(zero_inflated:, zero_percentage:, **values) ⇒ Result
Returns a new instance of Result.
10 11 12 13 14 15 |
# File 'lib/stud_finder/churn.rb', line 10 def initialize(zero_inflated:, zero_percentage:, **values) @churn_commits = values[:churn_commits] || values[:counts] || {} @churn_lines = values[:churn_lines] || values[:line_counts] || {} @zero_inflated = zero_inflated @zero_percentage = zero_percentage end |
Instance Attribute Details
#churn_commits ⇒ Object (readonly)
Returns the value of attribute churn_commits.
8 9 10 |
# File 'lib/stud_finder/churn.rb', line 8 def churn_commits @churn_commits end |
#churn_lines ⇒ Object (readonly)
Returns the value of attribute churn_lines.
8 9 10 |
# File 'lib/stud_finder/churn.rb', line 8 def churn_lines @churn_lines end |
#zero_inflated ⇒ Object (readonly)
Returns the value of attribute zero_inflated.
8 9 10 |
# File 'lib/stud_finder/churn.rb', line 8 def zero_inflated @zero_inflated end |
#zero_percentage ⇒ Object (readonly)
Returns the value of attribute zero_percentage.
8 9 10 |
# File 'lib/stud_finder/churn.rb', line 8 def zero_percentage @zero_percentage end |
Instance Method Details
#counts ⇒ Object
17 18 19 |
# File 'lib/stud_finder/churn.rb', line 17 def counts churn_commits end |
#line_counts ⇒ Object
21 22 23 |
# File 'lib/stud_finder/churn.rb', line 21 def line_counts churn_lines end |