Class: RiCal::Component::Calendar::TimezoneID

Inherits:
Object
  • Object
show all
Defined in:
lib/ri_cal/component/calendar.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(identifier, calendar) ⇒ TimezoneID

Returns a new instance of TimezoneID.



82
83
84
# File 'lib/ri_cal/component/calendar.rb', line 82

def initialize(identifier, calendar)
  self.identifier, self.calendar = identifier, calendar
end

Instance Attribute Details

#calendarObject (readonly)

Returns the value of attribute calendar.



81
82
83
# File 'lib/ri_cal/component/calendar.rb', line 81

def calendar
  @calendar
end

#identifierObject (readonly)

Returns the value of attribute identifier.



81
82
83
# File 'lib/ri_cal/component/calendar.rb', line 81

def identifier
  @identifier
end

Instance Method Details

#local_to_utc(local) ⇒ Object



94
95
96
# File 'lib/ri_cal/component/calendar.rb', line 94

def local_to_utc(local)
  resolved.local_to_utc(date_time_prop)
end

#resolvedObject



90
91
92
# File 'lib/ri_cal/component/calendar.rb', line 90

def resolved
  calendar.find_timezone(identifier)
end

#tzinfo_timezoneObject



86
87
88
# File 'lib/ri_cal/component/calendar.rb', line 86

def tzinfo_timezone
  nil
end