Class: FormulaCell

Inherits:
SurpassCell show all
Defined in:
lib/surpass/surpass_cell.rb

Instance Attribute Summary

Attributes inherited from SurpassCell

#index

Instance Method Summary collapse

Methods inherited from SurpassCell

#col, #row, #set_style

Constructor Details

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

Returns a new instance of FormulaCell.



126
127
128
129
130
131
132
# File 'lib/surpass/surpass_cell.rb', line 126

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



134
135
136
137
# File 'lib/surpass/surpass_cell.rb', line 134

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