Class: Lt::Lcms::Lesson::Downloader::PDF
- Defined in:
- lib/lt/lcms/lesson/downloader/pdf.rb
Constant Summary collapse
- MIME_TYPE =
'application/pdf'
Constants inherited from Base
Base::MAX_RETRY_COUNT, Base::MIME_TYPE_EXPORT, Base::RETRY_DELAYES
Instance Attribute Summary
Attributes inherited from Base
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Base
#download, #file, #file_id, file_id_for, #initialize
Constructor Details
This class inherits a constructor from Lt::Lcms::Lesson::Downloader::Base
Class Method Details
.gdoc_file_url(id) ⇒ Object
10 11 12 |
# File 'lib/lt/lcms/lesson/downloader/pdf.rb', line 10 def self.gdoc_file_url(id) "https://docs.google.com/file/d/#{id}" end |
Instance Method Details
#pdf_content ⇒ Object
14 15 16 |
# File 'lib/lt/lcms/lesson/downloader/pdf.rb', line 14 def pdf_content service.get_file(file_id, download_dest: StringIO.new, supports_all_drives: true).string end |