Class: EarthTools::Timezone
- Inherits:
-
Object
- Object
- EarthTools::Timezone
- Defined in:
- lib/earth_tools/timezone.rb
Instance Attribute Summary collapse
-
#dst ⇒ Object
Returns the value of attribute dst.
-
#isotime ⇒ Object
Returns the value of attribute isotime.
-
#localtime ⇒ Object
Returns the value of attribute localtime.
-
#location ⇒ Object
Returns the value of attribute location.
-
#offset ⇒ Object
Returns the value of attribute offset.
-
#suffix ⇒ Object
Returns the value of attribute suffix.
-
#utctime ⇒ Object
Returns the value of attribute utctime.
-
#version ⇒ Object
Returns the value of attribute version.
Instance Method Summary collapse
-
#initialize(attrs = {}) ⇒ Timezone
constructor
A new instance of Timezone.
Constructor Details
#initialize(attrs = {}) ⇒ Timezone
Returns a new instance of Timezone.
5 6 7 8 9 10 11 12 13 14 15 |
# File 'lib/earth_tools/timezone.rb', line 5 def initialize(attrs = {}) attrs ||= {} @version = attrs['version'] @location = EarthTools::Location.new(attrs['location']) @offset = attrs['offset'] @suffix = attrs['suffix'] @localtime = attrs['localtime'] @isotime = attrs['isotime'] @utctime = attrs['utctime'] @dst = attrs['dst'] end |
Instance Attribute Details
#dst ⇒ Object
Returns the value of attribute dst.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def dst @dst end |
#isotime ⇒ Object
Returns the value of attribute isotime.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def isotime @isotime end |
#localtime ⇒ Object
Returns the value of attribute localtime.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def localtime @localtime end |
#location ⇒ Object
Returns the value of attribute location.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def location @location end |
#offset ⇒ Object
Returns the value of attribute offset.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def offset @offset end |
#suffix ⇒ Object
Returns the value of attribute suffix.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def suffix @suffix end |
#utctime ⇒ Object
Returns the value of attribute utctime.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def utctime @utctime end |
#version ⇒ Object
Returns the value of attribute version.
3 4 5 |
# File 'lib/earth_tools/timezone.rb', line 3 def version @version end |