module TimeScales::Frame::PartComponents::HasDayOfYear

Attributes

day[R]
day_of_year[R]

Public Class Methods

included(other) click to toggle source
# File lib/time_scales/frame/part_components.rb, line 97
def self.included(other)
  other.extend HasDayOfYear::ClassMixin
end

Private Instance Methods

_initialize(args_array) click to toggle source
Calls superclass method
# File lib/time_scales/frame/part_components.rb, line 107
def _initialize(args_array)
  super
  @day_of_year = ensure_fixnum( args_array.shift )
end
prepare_time_struct(struct) click to toggle source
Calls superclass method
# File lib/time_scales/frame/part_components.rb, line 112
def prepare_time_struct(struct)
  struct.day = (struct.day || 1) + day_of_year - 1
  super
end