Files
php-doc-ru/reference/phar/PharData/addEmptyDir.xml
Alexey Pyltsyn 8f8d4016fe Upd
git-svn-id: https://svn.php.net/repository/phpdoc/ru/trunk@343999 c90b9560-bf6c-de11-be94-00142212c4b1
2018-01-28 09:37:16 +00:00

105 lines
2.7 KiB
XML
Raw 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"?>
<!-- $Revision$ -->
<!-- EN-Revision: fa994a739c769e155f6b6848f66f1f9a24ec9eb0 Maintainer: rjhdby Status: ready -->
<!-- Reviewed: no -->
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="phardata.addemptydir">
<refnamediv>
<refname>PharData::addEmptyDir</refname>
<refpurpose>Добавить пустую директорию в tar/zip-архив</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<type>void</type><methodname>PharData::addEmptyDir</methodname>
<methodparam><type>string</type><parameter>dirname</parameter></methodparam>
</methodsynopsis>
<para>
С помощью этого места можно создать директорию по пути <literal>dirname</literal>.
Этот метод аналогичен <function>ZipArchive::addEmptyDir</function>.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<para>
<variablelist>
<varlistentry>
<term><parameter>dirname</parameter></term>
<listitem>
<para>
Путь создаваемой директории
</para>
</listitem>
</varlistentry>
</variablelist>
</para>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Ничего не возвращает. В случае ошибок бросает исключениее.
</para>
</refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
<example>
<title>Пример использования <function>PharData::addEmptyDir</function></title>
<programlisting role="php">
<![CDATA[
<?php
try {
$a = new PharData('/path/to/my.tar');
$a->addEmptyDir('/full/path/to/file');
// demonstrates how this file is stored
$b = $a['full/path/to/file']->isDir();
} catch (Exception $e) {
// обрабатываем ошибки
}
?>
]]>
</programlisting>
</example>
</para>
</refsect1>
<refsect1 role="seealso">
&reftitle.seealso;
<para>
<simplelist>
<member><function>Phar::addEmptyDir</function></member>
<member><function>PharData::addFile</function></member>
<member><function>PharData::addFromString</function></member>
</simplelist>
</para>
</refsect1>
</refentry>
<!-- 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
-->