Module: Book::Features
- Defined in:
- lib/epub/maker.rb
Instance Method Summary collapse
Instance Method Details
#make_ocf ⇒ Object
67 68 69 70 71 72 73 |
# File 'lib/epub/maker.rb', line 67 def make_ocf self.ocf = OCF.new ocf.make do |ocf| yield ocf if block_given? end ocf end |
#make_package ⇒ Object
75 76 77 78 79 80 81 82 83 84 |
# File 'lib/epub/maker.rb', line 75 def make_package package = Publication::Package.new package.book = self package.make do |package| yield package if block_given? end no_package_rootfile = rootfiles.find {|rf| rf.package.nil?} no_package_rootfile.package = package if no_package_rootfile package end |
#save ⇒ Object
87 88 89 90 91 92 93 |
# File 'lib/epub/maker.rb', line 87 def save ocf.save package.save resources.each do |item| item.save end end |