Class: Numeric
- Inherits:
-
Object
- Object
- Numeric
- Includes:
- When::TM::TemporalPosition::Conversion
- Defined in:
- lib/when_exe/core/duration.rb,
lib/when_exe/core/extension.rb
Overview
Extensions to Numeric class
Direct Known Subclasses
Instance Method Summary collapse
-
#clock ⇒ When::Parts::Timezone::Base
(also: #to_clock)
self を秒数とみなして When::Parts::Timezone::Base を取得.
-
#to_day_of_week ⇒ When::Coordinates::Residue
(also: #day_of_week)
曜日(剰余類).
-
#to_month_name ⇒ When::BasicTypes::M17n
(also: #month_name)
月名.
-
#to_pair(branch = nil) ⇒ When::Coordinates::Pair
(also: #pair)
self を幹の要素と解釈してWhen::Coordinates::Pair を生成.
-
#unit_duration ⇒ When::TM::Duration
メソッド名に相当する単位で表した When::TM::Duration.
-
#unit_interval_length ⇒ When::TM::IntervalLength
メソッド名に相当する単位で表した When::TM::IntervalLength.
-
#unit_period_duration ⇒ When::TM::PeriodDuration
メソッド名に相当する単位で表した When::TM::PeriodDuration.
Methods included from When::TM::TemporalPosition::Conversion
Instance Method Details
#clock ⇒ When::Parts::Timezone::Base Also known as: to_clock
core/extension
self を秒数とみなして When::Parts::Timezone::Base を取得
155 156 157 |
# File 'lib/when_exe/core/extension.rb', line 155 def clock When.Clock(self) end |
#to_day_of_week ⇒ When::Coordinates::Residue Also known as: day_of_week
core/extension
曜日(剰余類)
118 119 120 |
# File 'lib/when_exe/core/extension.rb', line 118 def to_day_of_week When::Coordinates::Residue.day_of_week(self) end |
#to_month_name ⇒ When::BasicTypes::M17n Also known as: month_name
core/extension
月名
self が 月番号の月名を返します
132 133 134 |
# File 'lib/when_exe/core/extension.rb', line 132 def to_month_name When::BasicTypes::M17n.month_name(self) end |
#to_pair(branch = nil) ⇒ When::Coordinates::Pair Also known as: pair
self を幹の要素と解釈してWhen::Coordinates::Pair を生成
143 144 145 |
# File 'lib/when_exe/core/extension.rb', line 143 def to_pair(branch=nil) Coordinates::Pair._force_pair(self, branch) end |
#unit_duration ⇒ When::TM::Duration
unit は second, minute, hour, day, week または seconds, minutes, hours, days, weeks に読み替える
core/duration
メソッド名に相当する単位で表した When::TM::Duration
|
# File 'lib/when_exe/core/duration.rb', line 110
|
#unit_interval_length ⇒ When::TM::IntervalLength
unit は second, minute, hour, day, week または seconds, minutes, hours, days, weeks に読み替える
core/extension
メソッド名に相当する単位で表した When::TM::IntervalLength
|
# File 'lib/when_exe/core/extension.rb', line 160
|
#unit_period_duration ⇒ When::TM::PeriodDuration
unit は second, minute, hour, day, week, month, year または seconds, minutes, hours, days, weeks, months, years に読み替える
core/extension
メソッド名に相当する単位で表した When::TM::PeriodDuration
|
# File 'lib/when_exe/core/extension.rb', line 169
|