Sha256: 1125b5ec1f3563e42591759ad8057c4f6d370887d32d23667395bbe647188543
Contents?: true
Size: 439 Bytes
Versions: 2
Compression:
Stored size: 439 Bytes
Contents
module IOStreams module Bzip2 class Writer < IOStreams::Writer # Write to a stream, compressing with Bzip2 def self.stream(input_stream, original_file_name: nil, **_args) Utils.load_dependency('rbzip2', 'Bzip2') unless defined?(RBzip2) begin io = RBzip2.default_adapter::Compressor.new(input_stream) yield io ensure io&.close end end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
iostreams-1.0.0.beta2 | lib/io_streams/bzip2/writer.rb |
iostreams-1.0.0.beta | lib/io_streams/bzip2/writer.rb |