JArchiveBzip2

Implements \JArchiveExtractable

Bzip2 format adapter for the JArchive class

deprecated
since

11.1

deprecated

4.0 use the Joomla\Archive\Bzip2 class instead

package

Joomla.Platform

Methods

extract

Extract a Bzip2 compressed file to a given path

extract(string $archive, string $destination, array $options = array()) : boolean
since

11.1

throws

\RuntimeException

Arguments

$archive

stringPath to Bzip2 archive to extract

$destination

stringPath to extract archive to

$options

arrayExtraction options [unused]

Response

booleanTrue if successful

extractStream

Method to extract archive using stream objects

extractStream(string $archive, string $destination, array $options = array()) : boolean

Arguments

$archive

stringPath to Bzip2 archive to extract

$destination

stringPath to extract archive to

$options

arrayExtraction options [unused]

Response

booleanTrue if successful

isSupported

Tests whether this adapter can unpack files on this computer.

isSupported() : boolean
static
since

11.3

Response

booleanTrue if supported

raiseWarning

Temporary private method to isolate JError from the extract method This code should be removed when JError is removed.

raiseWarning(integer $code, string $msg) : \JException
throws

\RuntimeExceptionif JError class does not exist

Arguments

$code

integerThe application-internal error code for this error

$msg

stringThe error message, which may also be shown the user if need be.

Response

\JExceptionJException instance if JError class exists

Properties

_data

Bzip2 file data buffer

Type(s)

string