Class: Hubtime::Activity::Month
- Inherits:
-
Period
- Object
- Period
- Hubtime::Activity::Month
show all
- Defined in:
- lib/hubtime/activity.rb
Instance Attribute Summary
Attributes inherited from Period
#children, #compiled, #example, #label, #repo_stats, #total_stats
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Period
#_first_child_key, #_last_child_key, #add, #additions, #child_keys, #commits, #compile!, #compiled?, #count, #default_stats, #deletions, #first!, #first?, #impact, #import, #initialize, #key_value, #last!, #last?, #repositories
Class Method Details
.child_class ⇒ Object
251
252
253
|
# File 'lib/hubtime/activity.rb', line 251
def self.child_class
Day
end
|
.display(time) ⇒ Object
247
248
249
|
# File 'lib/hubtime/activity.rb', line 247
def self.display(time)
time.strftime("%m")
end
|
Instance Method Details
#first_child_key ⇒ Object
255
256
257
|
# File 'lib/hubtime/activity.rb', line 255
def first_child_key
"01"
end
|
#last_child_key ⇒ Object
259
260
261
262
263
264
265
266
267
|
# File 'lib/hubtime/activity.rb', line 259
def last_child_key
if self.example
self.class.child_class.display(self.example.end_of_month)
else
"30"
end
end
|