lib/zakuro/calculation/range/operated_range.rb in zakuro-0.6.0 vs lib/zakuro/calculation/range/operated_range.rb in zakuro-0.6.1
- old
+ new
@@ -27,18 +27,18 @@
#
# 初期化
#
# @param [Context] context 暦コンテキスト
# @param [Western::Calendar] start_date 開始日
- # @param [Western::Calendar] end_date 終了日
+ # @param [Western::Calendar] last_date 終了日
# @param [Array<Year>] years 年データ(完全範囲)
#
- def initialize(context:, start_date: Western::Calendar.new, end_date: Western::Calendar.new,
+ def initialize(context:, start_date: Western::Calendar.new, last_date: Western::Calendar.new,
years: [])
@context = context
@years = years
- @scroll = Gengou::Scroll.new(start_date: start_date, end_date: end_date)
+ @scroll = Gengou::Scroll.new(start_date: start_date, last_date: last_date)
@operated_solar_terms = OperatedSolarTerms.new(context: context, years: @years)
@operated_solar_terms.create
end
#
@@ -81,10 +81,9 @@
# 運用情報で年を跨ぐ月をその年に寄せる
#
# @param [Array<OperatedYear>] operated_years 運用結果範囲
#
def self.move(operated_years:)
- # FIXME: この方式は完全ではない。範囲の1年前/1年後が必要
move_into_next_year(operated_years: operated_years)
move_into_last_year(operated_years: operated_years)
end
#