svn: /phpdoc/ja/trunk/reference/apcu/ book.xml functions/apcu-entry.xml setup.xml

[email protected] (Yoshinari Takaoka)
Newsgroups php.doc.ja
Message-ID <[email protected]>
mumumu                                   Mon, 09 Mar 2020 00:42:27 +0000

Revision: http://svn.php.net/viewvc?view=revision&revision=349356

Log:
added apcu missing doc translations

Changed paths:
    A   phpdoc/ja/trunk/reference/apcu/book.xml
    A   phpdoc/ja/trunk/reference/apcu/functions/apcu-entry.xml
    A   phpdoc/ja/trunk/reference/apcu/setup.xml
svn-diffs-349356.txt (text/x-diff, 11.2 KB)
Added: phpdoc/ja/trunk/reference/apcu/book.xml
===================================================================
--- phpdoc/ja/trunk/reference/apcu/book.xml	                        (rev 0)
+++ phpdoc/ja/trunk/reference/apcu/book.xml	2020-03-09 00:42:27 UTC (rev 349356)
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- $Revision$ -->
+<!-- EN-Revision: 349154 Maintainer: mumumu Status: ready -->
+
+<book xml:id="book.apcu" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
+ <title>APC User Cache</title>
+ <titleabbrev>APCu</titleabbrev>
+
+ <preface xml:id="intro.apcu">
+  &reftitle.intro;
+  <para>
+   APCu は <link linkend="book.apc">APC</link> から opcode のキャッシュ機能を除いたものです。
+  </para>
+  <para>
+   一番はじめの APCu のコードベースには 4.0.0 というバージョンが付けられました。
+   これは当時の APC の master ブランチの最新版からフォークした時点のものです。
+  </para>
+  <para>
+   APCu 5.0.0 で PHP 7 がサポートされました。
+  </para>
+  <para>
+   APCu は、APC の代替となるように互換モードが提供しています。
+  </para>
+ </preface>
+
+ &reference.apcu.setup;
+ &reference.apcu.constants;
+ &reference.apcu.reference;
+ &reference.apcu.apcuiterator;
+
+</book>
+
+<!-- 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
+-->
+


Property changes on: phpdoc/ja/trunk/reference/apcu/book.xml
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Id Rev Revision Date LastChangedDate LastChangedRevision Author LastChangedBy HeadURL URL
\ No newline at end of property
Added: phpdoc/ja/trunk/reference/apcu/functions/apcu-entry.xml
===================================================================
--- phpdoc/ja/trunk/reference/apcu/functions/apcu-entry.xml	                        (rev 0)
+++ phpdoc/ja/trunk/reference/apcu/functions/apcu-entry.xml	2020-03-09 00:42:27 UTC (rev 349356)
@@ -0,0 +1,178 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- $Revision$ -->
+<!-- EN-Revision: 342988 Maintainer: mumumu Status: ready -->
+<refentry xml:id="function.apcu-entry" xmlns="http://docbook.org/ns/docbook">
+ <refnamediv>
+  <refname>apcu_entry</refname>
+  <refpurpose>
+   アトミックに値を取得するか、キャッシュエントリを生成する
+  </refpurpose>
+ </refnamediv>
+ <refsect1 role="description">
+  &reftitle.description;
+  <methodsynopsis>
+   <type>mixed</type><methodname>apcu_entry</methodname>
+   <methodparam><type>string</type><parameter>key</parameter></methodparam>
+   <methodparam><type>callable</type><parameter>generator</parameter></methodparam>
+   <methodparam choice="opt"><type>int</type><parameter>ttl</parameter><initializer>0</initializer></methodparam>
+  </methodsynopsis>
+  <para>
+   キャッシュに <parameter>key</parameter> が存在するかをアトミックに検索します。
+   存在しなければ <parameter>generator</parameter> が呼び出され、
+   <parameter>key</parameter> が唯一の引数として渡されます。
+   <parameter>generator</parameter> ではオプションで指定する <parameter>ttl</parameter> の間だけ値をキャッシュし、
+   キャッシュした値が返されます。
+  </para>
+  <note>
+   <simpara>
+    <function>apcu_entry</function> 関数に制御が移ると、
+    キャッシュのロックを排他的に取得します。
+    このロックは <function>apcu_entry</function> の実行が終わったときに開放されます:
+    この結果、<parameter>generator</parameter> はクリティカルセクションに入るため、
+    ふたつのプロセスが同時に同じコードパスを実行することができなくなります。
+    さらに、他のAPCuのあらゆる関数も同時に並列に実行できなくなります。
+    なぜなら、同じロックを共有しているからです。
+   </simpara>
+  </note>
+  <warning>
+   <simpara>
+    <parameter>generator</parameter> から安全に呼び出せるAPCuの関数は <function>apcu_entry</function> だけです。
+   </simpara>
+  </warning>
+ </refsect1>
+ <refsect1 role="parameters">
+  &reftitle.parameters;
+  <para>
+   <variablelist>
+    <varlistentry>
+     <term><parameter>key</parameter></term>
+     <listitem>
+      <para>
+       キャッシュエントリのキー。
+      </para>
+     </listitem>
+    </varlistentry>
+    <varlistentry>
+     <term><parameter>generator</parameter></term>
+     <listitem>
+      <para>
+       <parameter>key</parameter> を唯一の引数として取り、
+       キャッシュする値を返す関数
+      </para>
+     </listitem>
+    </varlistentry>
+    <varlistentry>
+     <term><parameter>ttl</parameter></term>
+     <listitem>
+      <para>
+       有効期間。<parameter>var</parameter> は、キャッシュに
+       <parameter>ttl</parameter> 秒間だけ格納されます。
+       <parameter>ttl</parameter> が経過すると、格納されている変数は
+       (次のリクエスト時に)キャッシュから削除されます。
+       <parameter>ttl</parameter> が指定されていない(あるいは
+       <parameter>ttl</parameter> が <literal>0</literal> の場合)は、
+       キャッシュから手動で削除される・あるいはキャッシュに存在できなくなる
+       (clear, restart など)まで値が持続します。
+      </para>
+     </listitem>
+    </varlistentry>
+   </variablelist>
+  </para>
+ </refsect1>
+ <refsect1 role="returnvalues">
+  &reftitle.returnvalues;
+  <para>
+   キャッシュされた値を返します。
+  </para>
+ </refsect1>
+
+ <refsect1 role="examples">
+  &reftitle.examples;
+  <para>
+   <example>
+    <title><function>apcu_entry</function> の例</title>
+    <programlisting role="php">
+<![CDATA[
+<?php
+$config = apcu_entry("config", function($key) {
+ return [
+   "fruit" => apcu_entry("config.fruit", function($key){
+     return [
+       "apples",
+       "pears"
+     ];
+   }),
+   "people" => apcu_entry("config.people", function($key){
+     return [
+      "bob",
+      "joe",
+      "niki"
+     ];
+   })
+ ];
+});
+
+var_dump($config);
+?>
+]]>
+    </programlisting>
+    &example.outputs;
+    <screen>
+<![CDATA[
+array(2) {
+  ["fruit"]=>
+  array(2) {
+    [0]=>
+    string(6) "apples"
+    [1]=>
+    string(5) "pears"
+  }
+  ["people"]=>
+  array(3) {
+    [0]=>
+    string(3) "bob"
+    [1]=>
+    string(3) "joe"
+    [2]=>
+    string(4) "niki"
+  }
+}
+]]>
+    </screen>
+   </example>
+  </para>
+ </refsect1>
+
+ <refsect1 role="seealso">
+  &reftitle.seealso;
+  <para>
+   <simplelist>
+    <member><function>apcu_store</function></member>
+    <member><function>apcu_fetch</function></member>
+    <member><function>apcu_delete</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
+-->


Property changes on: phpdoc/ja/trunk/reference/apcu/functions/apcu-entry.xml
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Id Rev Revision Date LastChangedDate LastChangedRevision Author LastChangedBy HeadURL URL
\ No newline at end of property
Added: phpdoc/ja/trunk/reference/apcu/setup.xml
===================================================================
--- phpdoc/ja/trunk/reference/apcu/setup.xml	                        (rev 0)
+++ phpdoc/ja/trunk/reference/apcu/setup.xml	2020-03-09 00:42:27 UTC (rev 349356)
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- $Revision$ -->
+<!-- EN-Revision: 342988 Maintainer: mumumu Status: ready -->
+
+<chapter xml:id="apcu.setup" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
+ &reftitle.setup;
+
+ <section xml:id="apcu.requirements">
+  &reftitle.required;
+  &no.requirement;
+ </section>
+
+ <section xml:id="apcu.installation">
+  &reftitle.install;
+  <para>
+   APC の機能と後方互換を取ることが必須な場合、APCu は --enable-apcu-bc を付けてコンパイルしなければなりません。
+  </para>
+  <warning>
+   <simpara>
+    PHP 7 では、APC と後方互換を取るために別のモジュール
+    (<link xlink:href="&url.apc.bc;">apc.so</link>) を提供しています。
+   </simpara>
+  </warning>
+  <para>
+   後方互換モードでは、APCu はAPCの関数を後方互換が取れたプロトタイプで登録します。
+  </para>
+  <para>
+   <parameter>cache_type</parameter> を引数として取るAPC関数は、
+   後方互換モードが有効なバージョンでは単に無視され、
+   APCu のバージョンではプロトタイプで省略されます。
+  </para>
+  <note>
+   <simpara>
+    Windows では、既に存在しており、
+    かつ Webサーバから書き込み可能な temp path が必要です。
+    APCu は TMP, TEMP, USERPROFILE 環境変数をこの順でチェックし、
+    これらに値がセットされていない場合は WINDOWS ディレクトリを最後に調べます。
+   </simpara>
+  </note>
+  <note>
+   <simpara>
+    さらに細かい、技術的に高度な実装の詳細については、
+    <link xlink:href="&url.apc.technotes;">
+     開発者が提供している TECHNOTES ファイル
+    </link> を参照して下さい。
+   </simpara>
+  </note>
+  <para>
+   APCu のソースコードは、<link xlink:href="&url.git.hub;krakjoe/apcu">ここ</link> で見ることが出来ます。
+  </para>
+ </section>
+
+ &reference.apcu.ini;
+
+ <section xml:id="apcu.resources">
+  &reftitle.resources;
+  &no.resource;
+ </section>
+
+</chapter>
+
+<!-- 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
+-->
+


Property changes on: phpdoc/ja/trunk/reference/apcu/setup.xml
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Id Rev Revision Date LastChangedDate LastChangedRevision Author LastChangedBy HeadURL URL
\ No newline at end of property
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.