Class JArchiveTar

Description

Tar format adapter for the JArchive class

This class is inspired from and draws heavily in code and concept from the Compress package of The Horde Project <http://www.horde.org>

  • since: 11.1

Located in /libraries/joomla/filesystem/archive/tar.php (line 25)

JObject
   |
   --JArchiveTar
Variable Summary
string $_data
array $_metadata
array $_types
Method Summary
static boolean isSupported ()
boolean extract (string $archive, string $destination, [array $options = array()])
array _getTarInfo (string &$data)
Variables
string $_data = null (line 50)

Tar file data buffer

  • since: 11.1
  • access: private
array $_metadata = null (line 58)

Tar file metadata array

  • since: 11.1
  • access: private
array $_types = array(
0x0 => 'Unix file',
0x30 => 'File',
0x31 => 'Link',
0x32 => 'Symbolic link',
0x33 => 'Character special file',
0x34 => 'Block special file',
0x35 => 'Directory',
0x36 => 'FIFO special file',
0x37 => 'Contiguous file')
(line 33)

Tar file types.

  • since: 11.1
  • access: private

Inherited Variables

Inherited from JObject

JObject::$_errors
Methods
static method isSupported (line 118)

Tests whether this adapter can unpack files on this computer.

  • return: True if supported
  • since: 11.3
  • access: public
static boolean isSupported ()
extract (line 71)

Extract a ZIP compressed file to a given path

  • return: True if successful
  • since: 11.1
  • access: public
boolean extract (string $archive, string $destination, [array $options = array()])
  • string $archive: Path to ZIP archive to extract
  • string $destination: Path to extract archive into
  • array $options: Extraction options [unused]
_getTarInfo (line 141)

Get the list of files/data from a Tar archive buffer.

  • return: Archive metadata array
     KEY: Position in the array
     VALUES: 'attr'  --  File attributes
     'data'  --  Raw file contents
     'date'  --  File modification time
     'name'  --  Filename
     'size'  --  Original file size
     'type'  --  File type
  • since: 11.1
  • access: protected
array _getTarInfo (string &$data)
  • string &$data: The Tar archive buffer.

Inherited Methods

Inherited From JObject

JObject::__construct()
JObject::def()
JObject::get()
JObject::getError()
JObject::getErrors()
JObject::getProperties()
JObject::set()
JObject::setError()
JObject::setProperties()
JObject::toString()
JObject::__toString()

Documentation generated on Mon, 25 Jun 2012 14:00:05 -0500 by phpDocumentor 1.4.4