Class: PrEntry
- Inherits:
-
Object
- Object
- PrEntry
- Defined in:
- lib/jirametrics/github_pr_scatterplot.rb
Instance Attribute Summary collapse
-
#closed_at ⇒ Object
readonly
Returns the value of attribute closed_at.
-
#created_at ⇒ Object
readonly
Returns the value of attribute created_at.
-
#days ⇒ Object
readonly
Returns the value of attribute days.
-
#hours_to_first_review ⇒ Object
readonly
Returns the value of attribute hours_to_first_review.
-
#pr_number ⇒ Object
readonly
Returns the value of attribute pr_number.
-
#repo ⇒ Object
readonly
Returns the value of attribute repo.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
Instance Method Summary collapse
-
#initialize(row) ⇒ PrEntry
constructor
A new instance of PrEntry.
Constructor Details
#initialize(row) ⇒ PrEntry
Returns a new instance of PrEntry.
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 8 def initialize row @created_at = Time.parse(row['Created At (UTC)']).getlocal('-05:00') @closed_at = Time.parse(row['Closed At (UTC)']).getlocal('-05:00') @hours_to_first_review = row['Time to First Review (hrs)'] @pr_number = row['PR Number'] @days = ((closed_at - created_at) / 3600.0 / 24).ceil @repo = row['Repo'] @title = row['Title'] end |
Instance Attribute Details
#closed_at ⇒ Object (readonly)
Returns the value of attribute closed_at.
6 7 8 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 6 def closed_at @closed_at end |
#created_at ⇒ Object (readonly)
Returns the value of attribute created_at.
6 7 8 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 6 def created_at @created_at end |
#days ⇒ Object (readonly)
Returns the value of attribute days.
6 7 8 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 6 def days @days end |
#hours_to_first_review ⇒ Object (readonly)
Returns the value of attribute hours_to_first_review.
6 7 8 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 6 def hours_to_first_review @hours_to_first_review end |
#pr_number ⇒ Object (readonly)
Returns the value of attribute pr_number.
6 7 8 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 6 def pr_number @pr_number end |
#repo ⇒ Object (readonly)
Returns the value of attribute repo.
6 7 8 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 6 def repo @repo end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
6 7 8 |
# File 'lib/jirametrics/github_pr_scatterplot.rb', line 6 def title @title end |