Declaration¶
Source position: zipper.pp line 363
type
TZipFileEntry = class(TCollectionItem)
public
constructor Create;
function IsDirectory : Boolean;
function IsLink : Boolean;
procedure Assign;
property Stream: TStream; {rw}
published
property ArchiveFileName: AnsiString; {rw}
property UTF8ArchiveFileName: UTF8String; {rw}
property DiskFileName: AnsiString; {rw}
property UTF8DiskFileName: UTF8String; {rw}
property Size: Int64; {rw}
property DateTime: TDateTime; {rw}
property OS: Byte; {rw}
property Attributes: LongWord; {rw}
property CompressionLevel: Tcompressionlevel; {rw}
end;
Inheritance¶
Description¶
TZipFileEntry is a TCollectionItem descendant which represents a file or directory added to a .ZIP file archive. TZipFileEntry is the type used for items in the Entries property in the TZipFileEntries collection.
TZipFileEntry provides properties with metadata for the file or directory, including:
- ArchiveFileName
- Name of the file or directory in the .ZIP archive.
- UTF8ArchiveFileName
- Name of the file or directory in the .ZIP archive using UTF-8 encoding.
- DiskFileName
- Name of the file or directory on the local file system.
- UTF8DiskFileName
- Name of the file or directory using UTF-8 encoding.
- Size
- Size of the compressed file or directory in the .ZIP archive.
- DateTime
- The timestamp for file or directory in the .ZIP archive.
- OS
- Indicates the operating system device type / file system where the file or directory originated.
- Attributes
- File attributes for the entry.
- CompressionLevel
- Compression level applied to the content in the .ZIP archive.
- Stream
- TStream instance with the content for the entry.
Use IsDirectory to determine if the entry represents a directory.
Use IsLink to determine if the entry is a symbolic link on the local file system.
Properties¶
| Member | Visibility | Description |
|---|---|---|
| ArchiveFileName | published | Name of the file or directory in the .ZIP archive. |
| Attributes | published | File attributes for the file or directory. |
| CompressionLevel | published | Compression level applied to the content stored in the .ZIP archive. |
| DateTime | published | Timestamp for the file or directory in the .ZIP archive. |
| DiskFileName | published | Name of the file or directory on the local file system. |
| OS | published | Indication of operating system/file system. |
| Size | published | Size of the compressed content for the file or directory. |
| Stream | public | Stream with the content for the entry. |
| UTF8ArchiveFileName | published | Archive filename as UTF8 string. |
| UTF8DiskFileName | published | Name of the file or directory on the local file system using UTF-8 encoding. |
Methods¶
| Member | Visibility | Description |
|---|---|---|
| Assign | public | Copies property values from the specified persistent object. |
| Create | public | Constructor for the class instance. |
| IsDirectory | public | True if the entry is a directory on the local file system. |
| IsLink | public | True if the directory is a symbolic link on the local file system. |