Class: Zip::ZipStreamableDirectory

Inherits:
ZipEntry
  • Object
show all
Defined in:
lib/zip/zip_streamable_directory.rb

Constant Summary

Constants inherited from ZipEntry

Zip::ZipEntry::CDIR_ENTRY_STATIC_HEADER_LENGTH, Zip::ZipEntry::CENTRAL_DIRECTORY_ENTRY_SIGNATURE, Zip::ZipEntry::DEFLATED, Zip::ZipEntry::FSTYPES, Zip::ZipEntry::FSTYPE_ACORN, Zip::ZipEntry::FSTYPE_AMIGA, Zip::ZipEntry::FSTYPE_ATARI, Zip::ZipEntry::FSTYPE_ATHEOS, Zip::ZipEntry::FSTYPE_BEOS, Zip::ZipEntry::FSTYPE_CPM, Zip::ZipEntry::FSTYPE_FAT, Zip::ZipEntry::FSTYPE_HPFS, Zip::ZipEntry::FSTYPE_MAC, Zip::ZipEntry::FSTYPE_MAC_OSX, Zip::ZipEntry::FSTYPE_MVS, Zip::ZipEntry::FSTYPE_NTFS, Zip::ZipEntry::FSTYPE_QDOS, Zip::ZipEntry::FSTYPE_TANDEM, Zip::ZipEntry::FSTYPE_THEOS, Zip::ZipEntry::FSTYPE_TOPS20, Zip::ZipEntry::FSTYPE_UNIX, Zip::ZipEntry::FSTYPE_VFAT, Zip::ZipEntry::FSTYPE_VMS, Zip::ZipEntry::FSTYPE_VM_CMS, Zip::ZipEntry::FSTYPE_Z_SYSTEM, Zip::ZipEntry::LOCAL_ENTRY_SIGNATURE, Zip::ZipEntry::LOCAL_ENTRY_STATIC_HEADER_LENGTH, Zip::ZipEntry::LOCAL_ENTRY_TRAILING_DESCRIPTOR_LENGTH, Zip::ZipEntry::STORED, Zip::ZipEntry::VERSION_NEEDED_TO_EXTRACT

Instance Attribute Summary

Attributes inherited from ZipEntry

#comment, #compressed_size, #compression_method, #crc, #dirty, #externalFileAttributes, #extra, #filepath, #follow_symlinks, #fstype, #ftype, #gp_flags, #header_signature, #localHeaderOffset, #name, #restore_ownership, #restore_permissions, #restore_times, #size, #unix_gid, #unix_perms, #unix_uid, #zipfile

Instance Method Summary collapse

Methods inherited from ZipEntry

#<=>, #==, #calculate_local_header_size, #cdir_header_size, #directory?, #extract, #file?, #file_stat, #gather_fileinfo_from_srcpath, #get_extra_attributes_from_path, #get_input_stream, #get_raw_input_stream, #local_entry_offset, #name_is_directory?, #next_header_offset, #parent_as_string, read_c_dir_entry, #read_c_dir_entry, read_local_entry, #read_local_entry, read_zip_long, read_zip_short, #set_extra_attributes_on_path, #symlink?, #time, #time=, #to_s, #write_c_dir_entry, #write_local_entry, #write_to_zip_output_stream

Constructor Details

#initialize(zipfile, entry, srcPath = nil, permissionInt = nil) ⇒ ZipStreamableDirectory

Returns a new instance of ZipStreamableDirectory.



3
4
5
6
7
8
9
# File 'lib/zip/zip_streamable_directory.rb', line 3

def initialize(zipfile, entry, srcPath = nil, permissionInt = nil)
  super(zipfile, entry)

  @ftype = :directory
  entry.get_extra_attributes_from_path(srcPath) if (srcPath)
  @unix_perms = permissionInt if (permissionInt)
end