Class: HtmlFromPdf::Converter
- Inherits:
-
Object
- Object
- HtmlFromPdf::Converter
- Includes:
- Helpers
- Defined in:
- lib/html_from_pdf/converter.rb
Instance Method Summary collapse
- #convert ⇒ Object
-
#initialize(pdf_path, html_path, options = {}) ⇒ Converter
constructor
A new instance of Converter.
Methods included from Helpers
#create_dir, #default_file_path
Constructor Details
#initialize(pdf_path, html_path, options = {}) ⇒ Converter
Returns a new instance of Converter.
5 6 7 8 9 |
# File 'lib/html_from_pdf/converter.rb', line 5 def initialize(pdf_path, html_path, = {}) @pdf_path = pdf_path @html_path = html_path @options = end |
Instance Method Details
#convert ⇒ Object
11 12 13 14 15 |
# File 'lib/html_from_pdf/converter.rb', line 11 def convert file_name = process_html_path command = "pdf2htmlEX #{} #{@pdf_path} #{file_name}" raise HtmlFromPdf::ConvertingError unless system command end |