A SERVICE OF

logo

MediaScript Objects and Methods 161
Unzip Object
The Unzip object is used to extract files from an existing zip archive.
Unzip Profile Object Methods
The Unzip Object implements the following methods:
Unzip() constructor
open()
extractAll()
firstFile()
nextFile()
getFileName()
extractFile()
close()
NOTE: For all paths in the UnZip Object that do not specify a file system the default is the read
file system. See “File Systems” on page 14 for more information.
Unzip()
Constructor for Unzip object.
Parameters
This function takes no parameters.
open()
Opens an existing archive. The archive will remain open until one of the following occurs:
another archive is opened, the archive is explicitly closed with the close() method, or the
Unzip object is garbage collected.
Parameters
archiveName - specifies the path to the existing archive file.
extractAll()
Extracts all files in the zip archive to the specified directory. The full paths stored in the
archive will be preserved in the destination directory.
Parameters
dir - specifies the VFS path of the directory to extract files.