Class: CalendariumRomanum::Season
- Inherits:
-
Object
- Object
- CalendariumRomanum::Season
- Defined in:
- lib/calendarium-romanum/enums.rb
Instance Attribute Summary collapse
-
#colour ⇒ Object
readonly
Returns the value of attribute colour.
-
#symbol ⇒ Object
(also: #to_sym)
readonly
Returns the value of attribute symbol.
Instance Method Summary collapse
-
#initialize(symbol, colour) ⇒ Season
constructor
A new instance of Season.
- #name ⇒ Object
Constructor Details
#initialize(symbol, colour) ⇒ Season
Returns a new instance of Season.
31 32 33 34 35 |
# File 'lib/calendarium-romanum/enums.rb', line 31 def initialize(symbol, colour) @symbol = symbol @colour = colour @i18n_key = "temporale.season.#{@symbol}" end |
Instance Attribute Details
#colour ⇒ Object (readonly)
Returns the value of attribute colour.
37 38 39 |
# File 'lib/calendarium-romanum/enums.rb', line 37 def colour @colour end |
#symbol ⇒ Object (readonly) Also known as: to_sym
Returns the value of attribute symbol.
37 38 39 |
# File 'lib/calendarium-romanum/enums.rb', line 37 def symbol @symbol end |
Instance Method Details
#name ⇒ Object
40 41 42 |
# File 'lib/calendarium-romanum/enums.rb', line 40 def name I18n.t @i18n_key end |