View source code
Display the source code in std/zip.d from which this page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page. Requires a signed-in GitHub account. This works well for small changes. If you'd like to make larger changes you may want to consider using local clone.

Class std.zip.ArchiveMember

A single file or directory inside the archive.

class ArchiveMember ;

Fields

NameTypeDescription
comment stringComment associated with this member.
extra ubyte[]The content of the extra data field for this member. See original documentation for a description of the general format of this data. May contain undocumented 3rd-party data.
flags ushortContains some information on how to extract this archive. See original documentation for details.
internalAttributes ushortInternal attributes. Bit 1 is set, if the member is apparently in binary format and bit 2 is set, if each record is preceded by the length of the record.
name stringThe name of the archive member; it is used to index the archive directory for the member. Each member must have a unique name. Do not change without removing member from the directory first.

Properties

NameTypeDescription
compressedData[get] ubyte[]Data of member in compressed form.
compressedSize[get] uintSize of data of member in compressed form.
compressionMethod[get, set] CompressionMethodGet or set compression method used for this member.
crc32[get] uintCyclic redundancy check (CRC) value.
expandedData[get, set] ubyte[]Get or set data of member in uncompressed form. When an existing archive is read ZipArchive.expand needs to be called before this can be accessed.
expandedSize[get] uintSize of data of member in uncompressed form.
extractVersion[get] ushortThe zip file format version needed to extract this member.
fileAttributes[get, set] uintGet or set the OS specific file attributes for this archive member.
index[get, set] uintThe index of this archive member within the archive. Set this to a different value for reordering the members of an archive.
time[get, set] uintGet or set the last modification time for this member.

Methods

NameDescription
factory (classname) Create instance of class specified by the fully qualified name classname. The class must either have no constructors or have a default constructor.
opCmp (o) Compare with another Object obj.
opEquals (o) Test whether this is equal to o. The default implementation only compares by identity (using the is operator). Generally, overrides and overloads for opEquals should attempt to compare objects by their contents. A class will most likely want to add an overload that takes your specific type as the argument and does the content comparison. Then you can override this and forward it to your specific typed overload with a cast. Remember to check for null on the typed overload.
toHash () Compute hash function for Object.
toString () Convert Object to a human readable string.

Authors

Walter Bright

License

Boost License 1.0.