Class: EpubForge::Builder::Html

Inherits:
EpubForge::Builder show all
Defined in:
lib/epubforge/builder/html.rb

Constant Summary

Constants included from EpubForge::Builder

FONT_FILE_EXTENSION, IMAGE_FILE_EXTENSIONS, MEDIA_TYPES, PAGE_FILE_EXTENSIONS

Instance Method Summary collapse

Instance Method Details

#buildObject



4
5
6
7
8
9
10
11
# File 'lib/epubforge/builder/html.rb', line 4

def build
  @html_content = ""
  
  @sections.each do |section|
    @html_content << section.html
    @html_content << "\n\n"         # couldn't hurt?
  end
end

#cleanObject



17
18
19
# File 'lib/epubforge/builder/html.rb', line 17

def clean
  # do nothing
end

#package(html_filename) ⇒ Object



13
14
15
# File 'lib/epubforge/builder/html.rb', line 13

def package( html_filename )
  html_filename.write( wrap_page( @html_content ) )
end