Method: TZInfo::TimeOrDateTime#hour
- Defined in:
- lib/tzinfo/time_or_datetime.rb
#hour ⇒ Object
Returns the hour of the day (0..23).
158 159 160 161 162 163 164 165 166 |
# File 'lib/tzinfo/time_or_datetime.rb', line 158 def hour if @time @time.hour elsif @datetime @datetime.hour else to_time.hour end end |