Phar::delete

(PHP >= 5.3.0, PECL phar >= 2.0.0) Delete a file within a phar archive public bool Phar::delete ( string $entry ) Note: This method requires the php.ini setting phar.readonly to be set to 0 in order to work for Phar objects. Otherwise, a PharException will be thrown. Delete a file within an archive. This is the functional equivalent of calling unlink() on the stream wrapper equivalent, as shown in the example below.

Phar::extractTo

(Unknown) Extract the contents of a phar archive to a directory public bool Phar::extractTo ( string $pathto [, string|array $files [, bool $overwrite = false ]] ) Note: This method requires the php.ini setting phar.readonly to be set to 0 in order to work for Phar objects. Otherwise, a PharException will be thrown. Extract all files within a phar archive to disk. Extracted files and directories preserve permissions as

Phar::getMetadata

(PHP >= 5.3.0, PECL phar >= 1.0.0) Returns phar archive meta-data public mixed Phar::getMetadata ( void ) Retrieve archive meta-data. Meta-data can be any PHP variable that can be serialized. Returns: any PHP variable that can be serialized and is stored as meta-data for the Phar archive, or NULL if no meta-data is stored. Examples:

Phar::getModified

(PHP >= 5.3.0, PECL phar >= 1.0.0) Return whether phar was modified public bool Phar::getModified ( void ) This method can be used to determine whether a phar has either had an internal file deleted, or contents of a file changed in some way. Returns: TRUE if the phar has been modified since opened, FALSE if not.

Phar::getSignature

(PHP >= 5.3.0, PECL phar >= 1.0.0) Return MD5/SHA1/SHA256/SHA512/OpenSSL signature of a Phar archive public array Phar::getSignature ( void ) Returns the verification signature of a phar archive in a hexadecimal string. Returns: Array with the opened archive's signature in hash key and MD5, SHA-1, SHA-256, SHA-512, or OpenSSL in hash_type. This signature is a hash calculated on the entire ph

Phar::getStub

(PHP >= 5.3.0, PECL phar >= 1.0.0) Return the PHP loader or bootstrap stub of a Phar archive public string Phar::getStub ( void ) Phar archives contain a bootstrap loader, or stub written in PHP that is executed when the archive is executed in PHP either via include: <?php include 'myphar.phar'; ?> php myphar.phar Returns: Returns a string containing the contents of the bo

Phar::getSupportedCompression

(PHP >= 5.3.0, PECL phar >= 1.2.0) Return array of supported compression algorithms final public static array Phar::getSupportedCompression ( void ) Returns: Returns an array containing any of Phar::GZ or Phar::BZ2, depending on the availability of the zlib extension or the bz2 extension. See also: PharFileI

Phar::getSupportedSignatures

(PHP >= 5.3.0, PECL phar >= 1.1.0) Return array of supported signature types final public static array Phar::getSupportedSignatures ( void ) Return array of supported signature types Returns: Returns an array containing any of MD5, SHA-1, SHA-256, SHA-512, or OpenSSL. See also: Phar::getSignature() -

Phar::getVersion

(PHP >= 5.3.0, PECL phar >= 1.0.0) Return version info of Phar archive public string Phar::getVersion ( void ) Returns the API version of an opened Phar archive. Returns: The opened archive's API version. This is not to be confused with the API version that the loaded phar extension will use to create new phars. Each Phar archive has the API version hard-coded into its manifest. See Phar fil

Phar::hasMetadata

(PHP >= 5.3.0, PECL phar >= 1.2.0) Returns whether phar has global meta-data public bool Phar::hasMetadata ( void ) Returns whether phar has global meta-data set. Returns: Returns TRUE if meta-data has been set, and FALSE if not. Examples: A Phar::hasMetadata() example <?php try {     $phar = new Phar('myphar.pha