Create  Edit  FrontPage  Index  Search  Changes  History  RSS  Login

GLib::ZlibCompressor

class GLib::ZlibCompressor

GLib::ZlibCompressor is an implementation of GLib::Converter that compresses data using zlib.

Class Methods

GLib::ZlibCompressor.new(format = GLib::ZlibCompressor::FORMAT_ZLIB, level = -1)
Creates a new GLib::ZlibCompressor

Instance Methods

convert(input, flags = GLib::Converter::NO_FLAGS)
See GLib::Converter#convert.
file_info

Gets the GLib::FileInfo used for retrieving file name and modification time for the GZIP header.

Since 2.26

file_info=(file_info)
Same as GLib::ZlibCompressor#set_file_info
format

Gets the format of the compressed data.

Default Value: GLib:ZlibCompressor::FORMAT_ZLIB

  • Returns: The format of the compressed data
level
Gets the level of compression from 0 (no compression) to 9 (most compression), -1 for the default level.
  • Returns: The level of compression from 0 (no compression) to 9 (most compression), -1 for the default level
reset
See GLib::Converter#reset.
set_file_info(file_info)

Sets the GLib::FileInfo used for retrieving file name and modification time for the GZIP header, if format is set to GLib::ZlibCompressor::FORMAT_GZIP, or nil to not output such information.

Since 2.26

  • file_info: File info
  • Returns: self

Properties

file-info: GLib::FileInfo (Read/Write)

The GLib::FileInvfo? used for retrieving file name and modification time for the GZIP header, if format is set to GLib::ZlibCompressor::FORMAT_GZIP.

Default value: nil

format: GLib::ZlibCompressor::Format (Read/Write)

The format of the compressed data

Default value: GLib::ZlibCompressor::FORMAT_ZLIB

level: Integer (Read/Write)

The level of compression from 0 (no compression) to 9 (most compression), -1 for the default level

Default value: -1

Last modified:2010/12/27 21:59:23
Keyword(s):
References:[GLib::ZlibCompressor] [Ruby/GIO] [GLib::ZlibDecompressor] [index-ruby-gio2] [index-ruby-glib2] [GLib::Converter]