class ISO8601::Hours
The Hours
atom in a {ISO8601::Duration}
Constants
- AVERAGE_FACTOR
Public Class Methods
new(atom)
click to toggle source
@param [Numeric] atom The atom value
# File lib/iso8601/hours.rb, line 13 def initialize(atom) valid_atom?(atom) @atom = atom end
Public Instance Methods
factor()
click to toggle source
The Week factor
@return [Numeric]
# File lib/iso8601/hours.rb, line 23 def factor AVERAGE_FACTOR end
symbol()
click to toggle source
The atom symbol.
@return [Symbol]
# File lib/iso8601/hours.rb, line 39 def symbol :H end
to_seconds()
click to toggle source
The amount of seconds
@return [Numeric]
# File lib/iso8601/hours.rb, line 31 def to_seconds AVERAGE_FACTOR * atom end