1
0
mirror of https://github.com/php/doc-ja.git synced 2026-03-28 09:02:14 +01:00
Files
archived-doc-ja/reference/phar/PharFileInfo/getCompressedSize.xml
2022-12-13 19:58:20 +09:00

103 lines
3.0 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<!-- EN-Revision: f03806fcd8fe03a0501bd40b6e3939ff6589a1d2 Maintainer: takagi Status: ready -->
<refentry xml:id="pharfileinfo.getcompressedsize" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>PharFileInfo::getCompressedSize</refname>
<refpurpose>Phar アーカイブ内での実際のファイルの大きさ (圧縮された状態) を返す</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis role="PharFileInfo">
<modifier>public</modifier> <type>int</type><methodname>PharFileInfo::getCompressedSize</methodname>
<void/>
</methodsynopsis>
<para>
この関数は、Phar アーカイブ内でのファイルの大きさを返します。
圧縮されていないファイルの場合は、getCompressedSize
<function>filesize</function> と同じ値を返します。
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
&no.function.parameters;
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
ディスク上の Phar アーカイブ内のファイルのバイト数を返します。
</para>
</refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
<example>
<title><function>PharFileInfo::getCompressedSize</function> の例</title>
<programlisting role="php">
<![CDATA[
<?php
try {
$p = new Phar('/path/to/my.phar', 0, 'my.phar');
$p['myfile.txt'] = 'hi';
$file = $p['myfile.txt'];
echo $file->getCompressedSize();
} catch (Exception $e) {
echo 'my.phar での書き込み操作に失敗しました: ', $e;
}
?>
]]>
</programlisting>
&example.outputs;
<screen>
<![CDATA[
2
]]>
</screen>
</example>
</para>
</refsect1>
<refsect1 role="seealso">
&reftitle.seealso;
<para>
<simplelist>
<member><function>PharFileInfo::isCompressed</function></member>
<member><function>PharFileInfo::decompress</function></member>
<member><function>PharFileInfo::compress</function></member>
<member><function>Phar::canCompress</function></member>
<member><function>Phar::isCompressed</function></member>
<member><function>Phar::compress</function></member>
<member><function>Phar::decompress</function></member>
<member><function>Phar::getSupportedCompression</function></member>
<member><function>Phar::decompressFiles</function></member>
<member><function>Phar::compressFiles</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
-->