Class: DaruLite::Offsets::Tick
Abstract
Overview
Private superclass for Offsets with equal inter-frequencies.
Instance Method Summary
collapse
#freq_string, #initialize
Methods inherited from DateOffset
#-@, #initialize
Instance Method Details
105
106
107
|
# File 'lib/daru_lite/date_time/offsets.rb', line 105
def +(other)
other + (@n * multiplier)
end
|
109
110
111
|
# File 'lib/daru_lite/date_time/offsets.rb', line 109
def -(other)
other - (@n * multiplier)
end
|
#==(other) ⇒ Object
113
114
115
|
# File 'lib/daru_lite/date_time/offsets.rb', line 113
def ==(other)
other.is_a?(Tick) && period == other.period
end
|
117
118
119
|
# File 'lib/daru_lite/date_time/offsets.rb', line 117
def period
@n * multiplier
end
|