PharData::convertToTar

(No version information available, might be only in CVS)

PharData::convertToTar — Convert a zip archive to the tar file format

Описание

bool PharData::convertToTar ( string $extension )

This method is used to convert a phar archive in phar or zip format to the tar file format.

Список параметров

extension

By default, the extension is .tar for converting from zip archives.

Возвращаемые значения

The method returns a PharData object on success and throws an exception on failure.

Errors/Exceptions

This method throws BadMethodCallException when unable to compress, an unknown compression method has been specified, the requested archive is buffering with PharData::startBuffering() and has not concluded with PharData::stopBuffering(), and a PharException if any problems are encountered during the tar creation process.

Примеры

Пример #1 A PharData::convertToTar() example

Using PharData::convertToTar():

<?php
try {
    
$zip = new PharData('myphar.zip');
    
$tar $zip->convertToTar();
} catch (
Exception $e) {
    
// handle the error here
}
?>

Смотрите также

[an error occurred while processing the directive]

Коментарии

404 Not Found

404 Not Found


nginx

    Поддержать сайт на родительском проекте КГБ