Class: Doc2Text::Pptx::Document
Class Method Summary
collapse
Instance Method Summary
collapse
#clean, #extract_path, #initialize, #open, #unpack
Class Method Details
.parse_and_save(input, output_filename) ⇒ Object
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
# File 'lib/doc2text/pptx/pptx.rb', line 5
def self.parse_and_save(input, output_filename)
docx = new input
begin
docx.unpack
output = File.open output_filename, 'w'
markdown = Markdown::DocxParser.new output, nil
begin
docx.parse markdown
ensure
markdown.close
end
ensure
docx.clean
end
end
|
Instance Method Details
21
22
23
|
# File 'lib/doc2text/pptx/pptx.rb', line 21
def
File.exist? File.join(, '[Content_Types].xml')
end
|
25
26
27
|
# File 'lib/doc2text/pptx/pptx.rb', line 25
def
'unpacked_pptx'
end
|