Module: When::TM::TemporalPosition::Conversion

Included in:
Date, Numeric, When::TM::TemporalPosition
Defined in:
lib/when_exe/tmposition.rb

Overview

When::TM::JulianDate, When::TM::CalDate or DateAndTime への変換メソッドを提供

Instance Method Summary collapse

Instance Method Details

#julian_date(options = {}) ⇒ When::TM::JulianDate Also known as: to_julian_date

対応する When::TM::JulianDate を生成

Parameters:

  • options (Hash) (defaults to: {})

    以下の通り

Options Hash (options):

Returns:



181
182
183
# File 'lib/when_exe/tmposition.rb', line 181

def julian_date(options={})
  When::TM::JulianDate.new(self, options)
end

#tm_pos(options = {}) ⇒ When::TM::CalDate, When::TM::DateAndTime Also known as: to_tm_pos

対応する When::TM::CalDate or DateAndTime を生成

Parameters:

Returns:



194
195
196
# File 'lib/when_exe/tmposition.rb', line 194

def tm_pos(options={})
  When.Calendar(options[:frame] || 'Gregorian').jul_trans(self, options)
end