class
ZipTricks::FileReader::ZipEntry
- ZipTricks::FileReader::ZipEntry
- Reference
- Object
Overview
Represents a file within the ZIP archive being read.
Defined in:
file_reader.crInstance Method Summary
- #comment : String
- #comment=(comment : String)
-
#compressed_data_offset : UInt64
Returns the offset at which compressed data starts in the IO
-
#compressed_data_offset=(offset)
Sets the offset at which the compressed data for this file starts in the ZIP
- #compressed_size : UInt64
- #compressed_size=(compressed_size : UInt64)
- #crc32 : UInt32
- #crc32=(crc32 : UInt32)
- #disk_number_start : UInt16
- #disk_number_start=(disk_number_start : UInt16)
- #dos_date : UInt16
- #dos_date=(dos_date : UInt16)
- #dos_time : UInt16
- #dos_time=(dos_time : UInt16)
- #external_attrs : UInt32
- #external_attrs=(external_attrs : UInt32)
-
#extractor_from(from_io)
Returns a reader for the actual compressed data of the entry.
- #filename : String
- #filename=(filename : String)
- #gp_flags : UInt16
- #gp_flags=(gp_flags : UInt16)
- #internal_attrs : UInt16
- #internal_attrs=(internal_attrs : UInt16)
-
#known_offset? : Bool
Tells whether the compressed data offset is already known for this entry
- #local_file_header_offset : UInt64
- #local_file_header_offset=(local_file_header_offset : UInt64)
- #made_by : UInt16
- #made_by=(made_by : UInt16)
- #storage_mode : UInt16
- #storage_mode=(storage_mode : UInt16)
- #uncompressed_size : UInt64
- #uncompressed_size=(uncompressed_size : UInt64)
-
#uses_data_descriptor? : Bool
Tells whether the entry uses a data descriptor (bit 3 in GP flags)
- #version_needed_to_extract : UInt16
- #version_needed_to_extract=(version_needed_to_extract : UInt16)
Instance Method Detail
def compressed_data_offset=(offset)
#
Sets the offset at which the compressed data for this file starts in the ZIP
def extractor_from(from_io)
#
Returns a reader for the actual compressed data of the entry.
reader = entry.extractor_from(source_file) outfile.write(reader.extract(512 * 1024).not_nil!) until reader.eof?
def uses_data_descriptor? : Bool
#
Tells whether the entry uses a data descriptor (bit 3 in GP flags)