Difference between revisions of "JArchiveZip"
From Joomla! Documentation
(Layout updates) |
(Updated to r1448:247ba8d88526) |
||
Line 1: | Line 1: | ||
__NOTOC__ | __NOTOC__ | ||
+ | =={{JVer|11.1}} JArchiveZip== | ||
+ | ===Description=== | ||
+ | {{Description:JArchiveZip}} | ||
<span class="editsection" style="font-size:76%;"> | <span class="editsection" style="font-size:76%;"> | ||
<nowiki>[</nowiki>[[Description:JArchiveZip|Edit Descripton]]<nowiki>]</nowiki> | <nowiki>[</nowiki>[[Description:JArchiveZip|Edit Descripton]]<nowiki>]</nowiki> | ||
</span> | </span> | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
===Methods=== | ===Methods=== | ||
{| class="wikitable sortable" | {| class="wikitable sortable" | ||
|- | |- | ||
+ | !Visibility | ||
!Method name | !Method name | ||
!Description | !Description | ||
|- | |- | ||
+ | |public | ||
|[[JArchiveZip::checkZipData/11.1|checkZipData]] | |[[JArchiveZip::checkZipData/11.1|checkZipData]] | ||
|Checks to see if the data is a valid ZIP file. | |Checks to see if the data is a valid ZIP file. | ||
|- | |- | ||
+ | |public | ||
|[[JArchiveZip::create/11.1|create]] | |[[JArchiveZip::create/11.1|create]] | ||
|Create a ZIP compressed file from an array of file data. | |Create a ZIP compressed file from an array of file data. | ||
|- | |- | ||
+ | |public | ||
|[[JArchiveZip::extract/11.1|extract]] | |[[JArchiveZip::extract/11.1|extract]] | ||
|Extract a ZIP compressed file to a given path. | |Extract a ZIP compressed file to a given path. | ||
|- | |- | ||
+ | |public | ||
|[[JArchiveZip::hasNativeSupport/11.1|hasNativeSupport]] | |[[JArchiveZip::hasNativeSupport/11.1|hasNativeSupport]] | ||
|Method to determine if the server has native zip support for faster handling. | |Method to determine if the server has native zip support for faster handling. | ||
|- | |- | ||
+ | |protected | ||
|[[JArchiveZip::_addToZIPFile/11.1|_addToZIPFile]] | |[[JArchiveZip::_addToZIPFile/11.1|_addToZIPFile]] | ||
|Adds a "file" to the ZIP archive. | |Adds a "file" to the ZIP archive. | ||
|- | |- | ||
+ | |protected | ||
|[[JArchiveZip::_createZIPFile/11.1|_createZIPFile]] | |[[JArchiveZip::_createZIPFile/11.1|_createZIPFile]] | ||
|Creates the ZIP file. | |Creates the ZIP file. | ||
|- | |- | ||
+ | |protected | ||
|[[JArchiveZip::_extract/11.1|_extract]] | |[[JArchiveZip::_extract/11.1|_extract]] | ||
|Extract a ZIP compressed file to a given path using a php based algorithm that only requires zlib support. | |Extract a ZIP compressed file to a given path using a php based algorithm that only requires zlib support. | ||
|- | |- | ||
+ | |protected | ||
|[[JArchiveZip::_extractNative/11.1|_extractNative]] | |[[JArchiveZip::_extractNative/11.1|_extractNative]] | ||
|Extract a ZIP compressed file to a given path using native php api calls for speed. | |Extract a ZIP compressed file to a given path using native php api calls for speed. | ||
|- | |- | ||
+ | |protected | ||
|[[JArchiveZip::_getFileData/11.1|_getFileData]] | |[[JArchiveZip::_getFileData/11.1|_getFileData]] | ||
|Returns the file data for a file by offsest in the ZIP archive. | |Returns the file data for a file by offsest in the ZIP archive. | ||
|- | |- | ||
+ | |protected | ||
|[[JArchiveZip::_getZipInfo/11.1|_getZipInfo]] | |[[JArchiveZip::_getZipInfo/11.1|_getZipInfo]] | ||
|Get the list of files/data from a ZIP archive buffer. | |Get the list of files/data from a ZIP archive buffer. | ||
|- | |- | ||
+ | |protected | ||
|[[JArchiveZip::_unix2DOSTime/11.1|_unix2DOSTime]] | |[[JArchiveZip::_unix2DOSTime/11.1|_unix2DOSTime]] | ||
|Converts a UNIX timestamp to a 4-byte DOS date and time format (date in high 2-bytes, time in low 2-bytes allowing magnitude comparison). | |Converts a UNIX timestamp to a 4-byte DOS date and time format (date in high 2-bytes, time in low 2-bytes allowing magnitude comparison). | ||
|- | |- | ||
|} | |} | ||
+ | * '''Defined in''' libraries/joomla/filesystem/archive/zip.php | ||
+ | * '''Extends''' [[JObject/11.1|JObject]] | ||
===Importing=== | ===Importing=== | ||
<source lang="php">jimport( 'joomla.filesystem.archive.zip' );</source> | <source lang="php">jimport( 'joomla.filesystem.archive.zip' );</source> | ||
===See also=== | ===See also=== | ||
− | * JArchiveZip source code | + | * {{JVer|11.1}} '''JArchiveZip source code''' on [[jplatform:filesystem/archive/zip.php|BitBucket]] |
− | * [[JArchiveZip|Other versions of | + | * {{JVer|11.1}} Subpackage [[Subpackage Filesystem/11.1|Filesystem]] |
+ | * [[JArchiveZip|Other versions of JArchiveZip]] | ||
{{SeeAlso:JArchiveZip}} | {{SeeAlso:JArchiveZip}} | ||
<span class="editsection" style="font-size:76%;"> | <span class="editsection" style="font-size:76%;"> | ||
<nowiki>[</nowiki>[[SeeAlso:JArchiveZip|Edit See Also]]<nowiki>]</nowiki> | <nowiki>[</nowiki>[[SeeAlso:JArchiveZip|Edit See Also]]<nowiki>]</nowiki> | ||
</span> | </span> | ||
− | === | + | ===User contributed notes=== |
<CodeExamplesForm /> | <CodeExamplesForm /> | ||
<dpl> | <dpl> | ||
Line 69: | Line 78: | ||
category=ClassExample | category=ClassExample | ||
include=* | include=* | ||
+ | namespace=CodeExample | ||
format= ,,, | format= ,,, | ||
</dpl> | </dpl> | ||
<noinclude>[[Category:Platform]][[Category:Platform 11.1]][[Category:JArchiveZip]]</noinclude> | <noinclude>[[Category:Platform]][[Category:Platform 11.1]][[Category:JArchiveZip]]</noinclude> |
Revision as of 17:55, 27 April 2011
The "API17" namespace is an archived namespace. This page contains information for a Joomla! version which is no longer supported. It exists only as a historical reference, it will not be improved and its content may be incomplete and/or contain broken links.
JArchiveZip[edit]
Description[edit]
Template:Description:JArchiveZip [Edit Descripton]
Methods[edit]
Visibility | Method name | Description |
---|---|---|
public | checkZipData | Checks to see if the data is a valid ZIP file. |
public | create | Create a ZIP compressed file from an array of file data. |
public | extract | Extract a ZIP compressed file to a given path. |
public | hasNativeSupport | Method to determine if the server has native zip support for faster handling. |
protected | _addToZIPFile | Adds a "file" to the ZIP archive. |
protected | _createZIPFile | Creates the ZIP file. |
protected | _extract | Extract a ZIP compressed file to a given path using a php based algorithm that only requires zlib support. |
protected | _extractNative | Extract a ZIP compressed file to a given path using native php api calls for speed. |
protected | _getFileData | Returns the file data for a file by offsest in the ZIP archive. |
protected | _getZipInfo | Get the list of files/data from a ZIP archive buffer. |
protected | _unix2DOSTime | Converts a UNIX timestamp to a 4-byte DOS date and time format (date in high 2-bytes, time in low 2-bytes allowing magnitude comparison). |
- Defined in libraries/joomla/filesystem/archive/zip.php
- Extends JObject
Importing[edit]
jimport( 'joomla.filesystem.archive.zip' );
See also[edit]
- JArchiveZip source code on BitBucket
- Subpackage Filesystem
- Other versions of JArchiveZip
Template:SeeAlso:JArchiveZip [Edit See Also]
User contributed notes[edit]
<CodeExamplesForm />