Class: RiCal::FloatingTimezone
- Defined in:
- lib/ri_cal/floating_timezone.rb
Overview
FloatingTimezone represents the ‘time zone’ for a time or date time with no timezone Times with floating timezones are always interpreted in the timezone of the observer
Class Method Summary collapse
-
.identifier ⇒ Object
:nodoc:.
-
.local_to_utc(time) ⇒ Object
Return the time unchanged.
-
.rational_utc_offset(local) ⇒ Object
:nodoc:.
-
.tzinfo_timezone ⇒ Object
:nodoc:.
-
.utc_to_local(time) ⇒ Object
Return the time unchanged.
Class Method Details
.identifier ⇒ Object
:nodoc:
6 7 8 |
# File 'lib/ri_cal/floating_timezone.rb', line 6 def self.identifier #:nodoc: nil end |
.local_to_utc(time) ⇒ Object
Return the time unchanged
24 25 26 |
# File 'lib/ri_cal/floating_timezone.rb', line 24 def self.local_to_utc(time) time.with_floating_timezone.to_ri_cal_date_time_value end |
.rational_utc_offset(local) ⇒ Object
:nodoc:
14 15 16 |
# File 'lib/ri_cal/floating_timezone.rb', line 14 def self.rational_utc_offset(local) #:nodoc: @offset = RiCal.RationalOffset[0] end |
.tzinfo_timezone ⇒ Object
:nodoc:
10 11 12 |
# File 'lib/ri_cal/floating_timezone.rb', line 10 def self.tzinfo_timezone #:nodoc: nil end |
.utc_to_local(time) ⇒ Object
Return the time unchanged
19 20 21 |
# File 'lib/ri_cal/floating_timezone.rb', line 19 def self.utc_to_local(time) time.with_floating_timezone.to_ri_cal_date_time_value end |