Class: Axlsx::WorkbookViews

Inherits:
SimpleTypedList
  • Object
show all
Defined in:
lib/axlsx/workbook/workbook_views.rb

Overview

a simple types list of BookView objects

Instance Method Summary collapse

Constructor Details

#initializeWorkbookViews

creates the book views object



7
8
9
# File 'lib/axlsx/workbook/workbook_views.rb', line 7

def initialize
  super(WorkbookView)
end

Instance Method Details

#to_xml_string(str = +'')) ⇒ String

Serialize to xml

Parameters:

  • str (String) (defaults to: +''))

Returns:

  • (String)


14
15
16
17
18
19
20
# File 'lib/axlsx/workbook/workbook_views.rb', line 14

def to_xml_string(str = +'')
  return if empty?

  str << "<bookViews>"
  each { |view| view.to_xml_string(str) }
  str << '</bookViews>'
end