Class: Dalli::Compressor

Inherits:
Object
  • Object
show all
Defined in:
lib/dalli/compressor.rb

Class Method Summary collapse

Class Method Details

.compress(data) ⇒ Object


7
8
9
# File 'lib/dalli/compressor.rb', line 7

def self.compress(data)
  Zlib::Deflate.deflate(data)
end

.decompress(data) ⇒ Object


11
12
13
# File 'lib/dalli/compressor.rb', line 11

def self.decompress(data)
  Zlib::Inflate.inflate(data)
end