GetData()
|
Previous Top Next |
:GetData(<cEntry> | <nEntry> | <oEntry>) --> cData
|
The single Parameter can be either a Character String, a Number, or a Central Directory Record Object:
|
|
<cEntry>
|
<cEntry> specifies the File Name of the Central Directory Record Entry that contains the information for the (File) Entry, which holds the Data of the Zip File.
|
<nEntry>
|
<nEntry> specifies the Index Number of the Central Directory Record Entry that contains the information for the (File) Entry, which holds the Data of the Zip File.
|
<oEntry>
|
<oEntry> specifies the ZipCentralDirectoryRecord object of the (File) Entry, which holds the Data of the Zip File.
|
This method returns the compressed or stored Data of the specified (File) Entry, or "" (an empty string) if the (File) Entry could not be found.
|
This method simply extracts and returns a copy of the compressed or stored Data of the specified (File) Entry.
|
Open the Zip File "MyArchive.zip" in Read-Only mode and retrieve the (possibly compressed) raw Data of the (File) Entry named "MyFile.xxx", and store that data in the variable cData. Then close the Zip File:
|
LOCAL oZip := XbZLibZip():New('MyArchive.zip', XBZ_OPEN_READ)
|
LOCAL cData := oZip:GetData('MyFile.xxx')
|
oZip:Close()
|