class TimeScales::Parts::AbstractPart
Public Instance Methods
&(time)
click to toggle source
# File lib/time_scales/parts.rb, line 68 def &(time) raise NotImplementedError, "Subclass responsibility" end
===(other)
click to toggle source
# File lib/time_scales/parts.rb, line 24 def ===(other) self == other || symbol == other end
component_mixin()
click to toggle source
# File lib/time_scales/parts.rb, line 52 def component_mixin raise NotImplementedError, "Subclass responsibility" end
default_for_unit?()
click to toggle source
# File lib/time_scales/parts.rb, line 44 def default_for_unit? raise NotImplementedError, "Subclass responsibility" end
name()
click to toggle source
# File lib/time_scales/parts.rb, line 60 def name @name ||= /::([^:]+)Class$/.match( self.class.name )[1] end
scale()
click to toggle source
# File lib/time_scales/parts.rb, line 40 def scale subdivision.scale end
scheme_scoped_precision_mixin()
click to toggle source
# File lib/time_scales/parts.rb, line 56 def scheme_scoped_precision_mixin raise NotImplementedError, "Subclass responsibility" end
scope()
click to toggle source
# File lib/time_scales/parts.rb, line 36 def scope raise NotImplementedError, "Subclass responsibility" end
subdivision()
click to toggle source
# File lib/time_scales/parts.rb, line 32 def subdivision raise NotImplementedError, "Subclass responsibility" end
subdivision_name()
click to toggle source
# File lib/time_scales/parts.rb, line 64 def subdivision_name subdivision.name end
symbol()
click to toggle source
# File lib/time_scales/parts.rb, line 28 def symbol raise NotImplementedError, "Subclass responsibility" end
to_s()
click to toggle source
# File lib/time_scales/parts.rb, line 48 def to_s @to_s ||= self.class.name.sub(/Class$/, '').freeze end
to_time_scales_part()
click to toggle source
# File lib/time_scales/parts.rb, line 20 def to_time_scales_part self end