Exception: LunarBlessing::OutOfRange
- Inherits:
-
StandardError
- Object
- StandardError
- LunarBlessing::OutOfRange
- Defined in:
- lib/lunar_blessing.rb
Instance Attribute Summary collapse
-
#year ⇒ Object
readonly
Returns the value of attribute year.
Instance Method Summary collapse
-
#initialize(year) ⇒ OutOfRange
constructor
A new instance of OutOfRange.
- #message ⇒ Object
Constructor Details
#initialize(year) ⇒ OutOfRange
Returns a new instance of OutOfRange.
98 99 100 |
# File 'lib/lunar_blessing.rb', line 98 def initialize(year) @year = year end |
Instance Attribute Details
#year ⇒ Object (readonly)
Returns the value of attribute year.
97 98 99 |
# File 'lib/lunar_blessing.rb', line 97 def year @year end |
Instance Method Details
#message ⇒ Object
102 103 104 |
# File 'lib/lunar_blessing.rb', line 102 def "The #{year} year you provided is out of range. This gem only support 1900 - 2099." end |