Class: Time
- Inherits:
-
Object
- Object
- Time
- Defined in:
- lib/merry_go_round/core_ext/time.rb
Instance Method Summary collapse
- #all_hour ⇒ Object
- #all_minute ⇒ Object
- #beginning_of_hour ⇒ Object
- #beginning_of_minute ⇒ Object
- #end_of_hour ⇒ Object
- #end_of_minute ⇒ Object
Instance Method Details
#all_hour ⇒ Object
29 30 31 |
# File 'lib/merry_go_round/core_ext/time.rb', line 29 def all_hour beginning_of_hour..end_of_hour end |
#all_minute ⇒ Object
25 26 27 |
# File 'lib/merry_go_round/core_ext/time.rb', line 25 def all_minute beginning_of_minute..end_of_minute end |
#beginning_of_hour ⇒ Object
13 14 15 |
# File 'lib/merry_go_round/core_ext/time.rb', line 13 def beginning_of_hour change(min: 0) end |
#beginning_of_minute ⇒ Object
2 3 4 |
# File 'lib/merry_go_round/core_ext/time.rb', line 2 def beginning_of_minute change(sec: 0) end |
#end_of_hour ⇒ Object
17 18 19 20 21 22 23 |
# File 'lib/merry_go_round/core_ext/time.rb', line 17 def end_of_hour change( :min => 59, :sec => 59, :usec => Rational(999999999, 1000) ) end |
#end_of_minute ⇒ Object
6 7 8 9 10 11 |
# File 'lib/merry_go_round/core_ext/time.rb', line 6 def end_of_minute change( sec: 59, usec: Rational(999999999, 1000) ) end |