Method: Axlsx::NumData#to_xml_string

Defined in:
lib/axlsx/drawing/num_data.rb

#to_xml_string(str = "") ⇒ Object

serialize the object



40
41
42
43
44
45
46
47
48
# File 'lib/axlsx/drawing/num_data.rb', line 40

def to_xml_string(str = "")
  str << '<c:' << @tag_name.to_s << '>'
  str << '<c:formatCode>' << format_code.to_s << '</c:formatCode>'
  str << '<c:ptCount val="' << @pt.size.to_s << '"/>'
  @pt.each_with_index do |num_val, index|
    num_val.to_xml_string index, str
  end
  str << '</c:' << @tag_name.to_s << '>'
end