1
0
mirror of https://github.com/php/doc-ru.git synced 2026-03-23 23:32:16 +01:00
Files
archived-doc-ru/reference/phar/Phar.xml
2026-02-06 09:55:33 +03:00

224 lines
7.9 KiB
XML
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?xml version="1.0" encoding="utf-8"?>
<!-- EN-Revision: 2b232242b1c4a99e689f79bd47735008c5009840 Maintainer: rjhdby Status: ready -->
<!-- Reviewed: no -->
<reference xml:id="class.phar" role="class" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xi="http://www.w3.org/2001/XInclude">
<title>Класс Phar</title>
<titleabbrev>Phar</titleabbrev>
<partintro>
<!-- {{{ Phar intro -->
<section xml:id="phar.intro">
&reftitle.intro;
<para>
Класс Phar предоставляет высокоуровневый интерфейс создания phar-архивов и доступа к ним.
</para>
</section>
<!-- }}} -->
<section xml:id="phar.synopsis">
&reftitle.classsynopsis;
<!-- {{{ Synopsis -->
<classsynopsis class="class">
<ooclass>
<classname>Phar</classname>
</ooclass>
<ooclass>
<modifier>extends</modifier>
<classname>RecursiveDirectoryIterator</classname>
</ooclass>
<oointerface>
<modifier>implements</modifier>
<interfacename>Countable</interfacename>
</oointerface>
<oointerface>
<interfacename>ArrayAccess</interfacename>
</oointerface>
<classsynopsisinfo role="comment">&InheritedConstants;</classsynopsisinfo>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.filesystemiterator')/db:partintro/db:section/db:classsynopsis/db:fieldsynopsis[preceding-sibling::db:classsynopsisinfo[1][@role='comment' and text()='&Constants;']]))">
<xi:fallback/>
</xi:include>
<classsynopsisinfo role="comment">&Constants;</classsynopsisinfo>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.bz2">Phar::BZ2</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.gz">Phar::GZ</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.none">Phar::NONE</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.phar">Phar::PHAR</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.tar">Phar::TAR</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.zip">Phar::ZIP</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.compressed">Phar::COMPRESSED</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.php">Phar::PHP</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.phps">Phar::PHPS</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.md5">Phar::MD5</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.openssl">Phar::OPENSSL</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.openssl-sha256">Phar::OPENSSL_SHA256</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.openssl-sha512">Phar::OPENSSL_SHA512</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.sha1">Phar::SHA1</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.sha256">Phar::SHA256</varname>
</fieldsynopsis>
<fieldsynopsis>
<modifier>const</modifier>
<type>int</type>
<varname linkend="phar.constants.sha512">Phar::SHA512</varname>
</fieldsynopsis>
<classsynopsisinfo role="comment">&Methods;</classsynopsisinfo>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.phar')/db:refentry/db:refsect1[@role='description']/descendant::db:constructorsynopsis[@role='Phar'])">
<xi:fallback/>
</xi:include>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.phar')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[@role='Phar'])">
<xi:fallback/>
</xi:include>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.phar')/db:refentry/db:refsect1[@role='description']/descendant::db:destructorsynopsis[@role='Phar'])">
<xi:fallback/>
</xi:include>
<classsynopsisinfo role="comment">&InheritedMethods;</classsynopsisinfo>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.recursivedirectoryiterator')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[@role='RecursiveDirectoryIterator'])">
<xi:fallback/>
</xi:include>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.filesystemiterator')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[@role='FilesystemIterator'])">
<xi:fallback/>
</xi:include>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.directoryiterator')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[@role='DirectoryIterator'])">
<xi:fallback/>
</xi:include>
<xi:include xpointer="xmlns(db=http://docbook.org/ns/docbook) xpointer(id('class.splfileinfo')/db:refentry/db:refsect1[@role='description']/descendant::db:methodsynopsis[@role='SplFileInfo'])">
<xi:fallback/>
</xi:include>
</classsynopsis>
<!-- }}} -->
</section>
<section role="changelog">
&reftitle.changelog;
<informaltable>
<tgroup cols="2">
<thead>
<row>
<entry>&Version;</entry>
<entry>&Description;</entry>
</row>
</thead>
<tbody>
<row>
<entry>8.4.0</entry>
<entry>
Добавлена поддержка модуля меток времени эпохи Unix для архивов на основе Zip.
</entry>
</row>
<row>
<entry>8.0.0</entry>
<entry>
Метаданные больше не десериализуются при открытии архива,
а откладываются до вызова метода <methodname>Phar::getMetadata</methodname>.
</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</section>
<section role="notes">
&reftitle.notes;
<caution>
<simpara>
До PHP 8.0.0 метаданные десериализовались при открытии архива,
что могло привести к уязвимостям в безопасности.
Начиная с PHP 8.0.0, метаданные десериализуются только при вызове
метода <methodname>Phar::getMetadata</methodname>, у которого есть
опции для ограничения десериализации из соображений безопасности.
</simpara>
</caution>
</section>
</partintro>
&reference.phar.entities.Phar;
</reference>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->