Module: Bindery::Extensions::ZipFileExtensions
- Defined in:
- lib/bindery/extensions/zip_file.rb
Instance Method Summary collapse
Instance Method Details
#write_file(entry, contents) ⇒ Object
6 7 8 |
# File 'lib/bindery/extensions/zip_file.rb', line 6 def write_file(entry, contents) get_output_stream(entry){|os| os.write(contents) } end |
#write_uncompressed_file(entry_name, contents) ⇒ Object
10 11 12 13 14 |
# File 'lib/bindery/extensions/zip_file.rb', line 10 def write_uncompressed_file(entry_name, contents) entry = Zip::ZipEntry.new(@name, entry_name.to_s) entry.compression_method = Zip::ZipEntry::STORED write_file(entry, contents) end |