class Roo::Excelx::Cell::Date

Attributes

cell_type[R]
cell_value[R]
coordinate[R]
format[R]
formula[R]
value[R]

Public Class Methods

new(value, formula, excelx_type, style, link, base_date, coordinate) click to toggle source
Calls superclass method Roo::Excelx::Cell::DateTime::new
# File lib/roo/excelx/cell/date.rb, line 11
def initialize(value, formula, excelx_type, style, link, base_date, coordinate)
  # NOTE: Pass all arguments to the parent class, DateTime.
  super
  @format = excelx_type.last
  @value = link ? Roo::Link.new(link, value) : create_date(base_date, value)
end

Private Instance Methods

create_date(base_date, value) click to toggle source
# File lib/roo/excelx/cell/date.rb, line 22
def create_date(base_date, value)
  base_date + value.to_i
end
create_datetime(_,_) click to toggle source
# File lib/roo/excelx/cell/date.rb, line 20
def create_datetime(_,_);  end