Class: Zakuro::Operation::Diffs
- Inherits:
-
Object
- Object
- Zakuro::Operation::Diffs
- Defined in:
- lib/zakuro/operation/month/type.rb
Overview
Diffs 総差分
Instance Attribute Summary collapse
-
#days ⇒ Integer
readonly
日差分.
-
#month ⇒ Month
readonly
月差分.
-
#solar_term ⇒ SolarTerm::Direction
readonly
二十四節気差分.
Instance Method Summary collapse
-
#initialize(month: Month.new, solar_term: SolarTerm::Direction.new, days: INVALID_DAY_VALUE) ⇒ Diffs
constructor
初期化.
-
#invalid_days? ⇒ True, False
日差分が無効か.
Constructor Details
#initialize(month: Month.new, solar_term: SolarTerm::Direction.new, days: INVALID_DAY_VALUE) ⇒ Diffs
初期化
162 163 164 165 166 167 |
# File 'lib/zakuro/operation/month/type.rb', line 162 def initialize(month: Month.new, solar_term: SolarTerm::Direction.new, days: INVALID_DAY_VALUE) @month = month @solar_term = solar_term @days = days end |
Instance Attribute Details
#days ⇒ Integer (readonly)
Returns 日差分.
153 154 155 |
# File 'lib/zakuro/operation/month/type.rb', line 153 def days @days end |
#month ⇒ Month (readonly)
Returns 月差分.
149 150 151 |
# File 'lib/zakuro/operation/month/type.rb', line 149 def month @month end |
#solar_term ⇒ SolarTerm::Direction (readonly)
Returns 二十四節気差分.
151 152 153 |
# File 'lib/zakuro/operation/month/type.rb', line 151 def solar_term @solar_term end |
Instance Method Details
#invalid_days? ⇒ True, False
日差分が無効か
175 176 177 |
# File 'lib/zakuro/operation/month/type.rb', line 175 def invalid_days? @days == INVALID_DAY_VALUE end |