Class: FormulaCell

Inherits:
Cell
  • Object
show all
Defined in:
lib/surpass/cell.rb

Instance Attribute Summary

Attributes inherited from Cell

#index

Instance Method Summary collapse

Methods inherited from Cell

#col, #row, #set_style

Constructor Details

#initialize(parent, index, format_index, formula, calc_flags = 0) ⇒ FormulaCell

Returns a new instance of FormulaCell.



122
123
124
125
126
127
128
# File 'lib/surpass/cell.rb', line 122

def initialize(parent, index, format_index, formula, calc_flags = 0)
  @parent = parent
  @index = index
  @format_index = format_index
  @formula = formula
  @calc_flags = calc_flags
end

Instance Method Details

#to_biffObject



130
131
132
133
# File 'lib/surpass/cell.rb', line 130

def to_biff
  args = [@parent.index, @index, @format_index, @formula.to_biff, @calc_flags]
  FormulaRecord.new(*args).to_biff
end