Explorar el Código

[DOCUMENTATION] Japanese sync: 18429, 18536, 18556, 18604, 18618, 18621, 18622

git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@18649 44c647ce-9c0f-0410-b52a-842ac1e357ba
yoshida@zend.co.jp hace 16 años
padre
commit
41d505ada6

+ 28 - 0
documentation/manual/ja/module_specs/Zend_Application-AvailableResources-Layout.xml

@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Reviewed: no -->
+<!-- EN-Revision: 18621 -->
+<sect2 id="zend.application.available-resources.layout">
+    <title>Zend_Application_Resource_Layout</title>
+
+    <para>
+        <classname>Zend_Application_Resource_Layout</classname>は、
+        <classname>Zend_Layout</classname>を構成するために使用できます。
+        構成オプションは、<link
+            linkend="zend.layout.options"><classname>Zend_Layout</classname>
+            オプション</link>毎にあります。
+    </para>
+
+    <example id="zend.application.available-resources.layout.configExample">
+        <title>レイアウト構成サンプル</title>
+
+        <para>
+            下記は、ナビゲーション・リソースを設定する方法を示す、
+            <acronym>INI</acronym>スニペット・サンプルです。
+        </para>
+
+        <programlisting language="ini"><![CDATA[
+resources.layout.layout = "NameOfDefaultLayout"
+resources.layout.Path = "/path/to/layouts"
+]]></programlisting>
+    </example>
+</sect2>

+ 2 - 2
documentation/manual/ja/module_specs/Zend_Application-AvailableResources-Navigation.xml

@@ -1,12 +1,12 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 17436 -->
+<!-- EN-Revision: 18621 -->
 <sect2 id="zend.application.available-resources.navigation">
     <title>Zend_Application_Resource_Navigation</title>
 
     <para>
         <classname>Zend_Application_Resource_Navigation</classname>は、
-        <classname>Zend_Navigation</classname>インスタンスを構成するために使うことができます。
+        <classname>Zend_Navigation</classname>インスタンスを構成するために使できます。
         構成オプションは、<link
             linkend="zend.navigation.pages.common.options"><classname>Zend_Navigation</classname>
             オプション</link>毎にあります。

+ 2 - 1
documentation/manual/ja/module_specs/Zend_Application-AvailableResources.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 18419 -->
+<!-- EN-Revision: 18622 -->
 <sect1 id="zend.application.available-resources" xmlns:xi="http://www.w3.org/2001/XInclude">
     <title>利用できるリソースプラグイン</title>
 
@@ -11,6 +11,7 @@
 
     <xi:include href="Zend_Application-AvailableResources-Db.xml" />
     <xi:include href="Zend_Application-AvailableResources-Frontcontroller.xml" />
+    <xi:include href="Zend_Application-AvailableResources-Layout.xml" />
     <xi:include href="Zend_Application-AvailableResources-Modules.xml" />
     <xi:include href="Zend_Application-AvailableResources-Navigation.xml" />
     <xi:include href="Zend_Application-AvailableResources-Router.xml" />

+ 35 - 1
documentation/manual/ja/module_specs/Zend_Controller-ActionController.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 16649 -->
+<!-- EN-Revision: 18556 -->
 <sect1 id="zend.controller.action">
     <title>アクションコントローラ</title>
 
@@ -183,6 +183,40 @@ class FooController extends Zend_Controller_Action
             作成したコンテンツを (<methodname>postDispatch()</methodname> で)
             全サイト共通のテンプレートに配置したりといったことが考えられます。
         </para>
+        
+        <!-- TODO : to be translated -->
+        <note>
+            <title>Usage of init() vs. preDispatch()</title>
+
+            <para>
+                In the <link linkend="zend.controller.action.initialization">previous
+                    section</link>, we introduced the <methodname>init()</methodname> method, and
+                in this section, the <methodname>preDispatch()</methodname> method. What is the
+                difference between them, and what actions would you take in each?
+            </para>
+
+            <para>
+                The <methodname>init()</methodname> method is primarily intended for extending the
+                constructor. Typically, your constructor should simply set object state, and not
+                perform much logic. This might include initializing resources used in the controller
+                (such as models, configuration objects, etc.), or assigning values retrieved from
+                the front controller, bootstrap, or a registry.
+            </para>
+
+            <para>
+                The <methodname>preDispatch()</methodname> method can also be used to set object
+                or environmental (e.g., view, action helper, etc.) state, but its primary purpose
+                is to make decisions about whether or not the requested action should be dispatched.
+                If not, you should then <methodname>_forward()</methodname> to another action, or
+                throw an exception.
+            </para>
+
+            <para>
+                Note: <methodname>_forward()</methodname> actually will not work correctly when
+                executed from <methodname>init()</methodname>, which is a formalization of the
+                intentions of the two methods.
+            </para>
+        </note>
     </sect2>
 
     <sect2 id="zend.controller.action.accessors">

+ 1 - 1
documentation/manual/ja/module_specs/Zend_Date-Overview.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 18428 -->
+<!-- EN-Revision: 18429 -->
 <sect1 id="zend.date.overview">
 
     <title>Zend_Date API の概要</title>

+ 23 - 1
documentation/manual/ja/module_specs/Zend_Filter_Input.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 17871 -->
+<!-- EN-Revision: 18618 -->
 <sect1 id="zend.filter.input">
     <title>Zend_Filter_Input</title>
 
@@ -398,6 +398,28 @@ $input = new Zend_Filter_Input($filters, $validators, $data);
 $input->setOptions($options);
 ]]></programlisting>
 
+            <!-- TODO : to be translated -->
+            <para>
+                And you can also add a translator which gives you the ability to provide multiple
+                languages for the messages which are returned by
+                <classname>Zend_Filter_Input</classname>.
+            </para>
+
+            <programlisting language="php"><![CDATA[
+$translate = new Zend_Translate_Adapter_Array(array(
+    Zend_Filter_Input::MISSING_MESSAGE => "Where is the field?"
+);
+
+$input = new Zend_Filter_Input($filters, $validators, $data);
+$input->setTranslator($translate);
+]]></programlisting>
+
+            <para>
+                When you are using an application wide translator, then it will also be used by
+                <classname>Zend_Filter_Input</classname>. In this case you will not have to set the
+                translator manually.
+            </para>
+
             <para>
                 <methodname>getUnknown()</methodname> メソッドの結果は、
                 フィールド名とフィールドの値を対応させた連想配列となります。

+ 3 - 3
documentation/manual/ja/module_specs/Zend_Search_Lucene-IndexCreation.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 17409 -->
+<!-- EN-Revision: 18536 -->
 <sect1 id="zend.search.lucene.index-creation">
     <title>インデックスの構築</title>
 
@@ -143,7 +143,7 @@ for ($count = 0; $count < $index->maxDoc(); $count++) {
             Lucene インデックスセグメントのファイルは、その性質上更新することはできません。
             セグメントを更新するには、セグメント全体を再構成する必要があります
             (Lucene インデックスファイルのフォーマットについての詳細は、
-            <ulink url="http://lucene.apache.org/java/docs/fileformats.html">http://lucene.apache.org/java/docs/fileformats.html</ulink>
+            <ulink url="http://lucene.apache.org/java/2_3_0/fileformats.html">http://lucene.apache.org/java/2_3_0/fileformats.html</ulink>
             を参照ください)
             <footnote><para>現在サポートしている Lucene インデックスファイルフォーマットのバージョンは v2.3 (Zend Framework 1.6 以降) です</para></footnote>。
             このことより、新しいドキュメントをインデックスに追加する際には、
@@ -151,7 +151,7 @@ for ($count = 0; $count < $index->maxDoc(); $count++) {
         </para>
         <para>
             セグメントの数が増えるとインデックスの効率が下がります。
-            しかし、インデックスの最適化によってこれを修復することができます。
+            しかし、インデックスの最適化によってこれを修復できます。
             最適化により、複数のセグメントに分かれているデータがひとつにまとめられます。
             この処理も、セグメントを更新することはありません。まず大きなセグメントを新しく作成し、
             これまでいくつものセグメントに分かれていたデータをひとまとめにしてそこに格納し、

+ 2 - 2
documentation/manual/ja/module_specs/Zend_Search_Lucene-JavaLucene.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 17174 -->
+<!-- EN-Revision: 18536 -->
 <sect1 id="zend.search.lucene.java-lucene">
     <title>Java Lucene との相互運用</title>
 
@@ -13,7 +13,7 @@
 
         <para>
           このファイルフォーマットについての詳細な説明は
-          <ulink url="http://lucene.apache.org/java/docs/fileformats.html"/>
+          <ulink url="http://lucene.apache.org/java/2_3_0/fileformats.html"/>
           にあります。
           <footnote><para>現在 (Zend Framework 1.6 以降) サポートしている Lucene
           インデックスファイルフォーマットのバージョンは 2.1 です</para></footnote>。

+ 6 - 6
documentation/manual/ja/module_specs/Zend_Search_Lucene-QueryLanguage.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 15743 -->
+<!-- EN-Revision: 18536 -->
 <sect1 id="zend.search.lucene.query-language">
     <title>クエリ言語</title>
 
@@ -15,7 +15,7 @@
 
     <para>
         Java Lucene のクエリ言語の文法についての完全な文書は
-        <ulink url="http://lucene.apache.org/java/docs/queryparsersyntax.html">ここ</ulink>
+        <ulink url="http://lucene.apache.org/java/2_3_0/queryparsersyntax.html">ここ</ulink>
         にあります。
     </para>
 
@@ -58,7 +58,7 @@
         </para>
         <para>
             <classname>Zend_Search_Lucene</classname> クラスにはふたつの静的メソッドがあり、
-            この設定を操作することができます。
+            この設定を操作できます。
         </para>
         <programlisting language="php"><![CDATA[
 $defaultSearchField = Zend_Search_Lucene::getDefaultSearchField();
@@ -160,7 +160,7 @@ test*
         <para>
             これは、<code>Zend_Search_Lucene_Search_Query_Wildcard::getMinPrefixLength()</code> および
             <code>Zend_Search_Lucene_Search_Query_Wildcard::setMinPrefixLength()</code>
-            メソッドで変更することができます。
+            メソッドで変更できます。
         </para>
     </sect2>
 
@@ -224,7 +224,7 @@ roam~
             この検索は、foam あるいは roams といった単語にマッチします。
 
             (オプションの) 追加のパラメータによって、
-            あいまい検索の程度を指定することができます。
+            あいまい検索の程度を指定できます。
             このパラメータの値は 0 から 1 までの間となり、
             1 に近づくほど、類似点が多い単語にのみマッチするようになります。
             たとえば次のように使用します。
@@ -457,7 +457,7 @@ PHP^4 framework
         <title>フィールドのグループ化</title>
 
         <para>
-            Lucene では、括弧を使用して複数の条件をひとつのフィールドに適用することができます。
+            Lucene では、括弧を使用して複数の条件をひとつのフィールドに適用できます。
         </para>
         <para>
             タイトルに単語 "return" とフレーズ "pink panther" の両方を含むドキュメントを検索するには

+ 29 - 5
documentation/manual/ja/module_specs/Zend_Test-PHPUnit-Bootstrapping.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 18222 -->
+<!-- EN-Revision: 18604 -->
 <sect2 id="zend.test.phpunit.bootstrapping">
     <title>テストケースの起動</title>
 
@@ -22,8 +22,32 @@
         <code>$bootstrap</code> で決まります。
     </para>
 
+    <!-- TODO : to be translated -->
     <para>
-        まず、このプロパティでファイルを指定することができます。
+        First, and probably most straight-forward, simply create a
+        <classname>Zend_Application</classname> instance as you would in your
+        <filename>index.php</filename>, and assign it to the <varname>$bootstrap</varname> property.
+        Typically, you will do this in your <methodname>setUp()</methodname> method; you will need
+        to call <methodname>parent::setUp()</methodname> when done:
+    </para>
+
+    <programlisting language="php"><![CDATA[
+class UserControllerTest extends Zend_Test_PHPUnit_ControllerTestCase
+{
+    public function setUp()
+    {
+        // Assign and instantiate in one step:
+        $this->bootstrap = new Zend_Application(
+            'testing', 
+            APPLICATION_PATH . '/configs/application.ini'
+        );
+        parent::setUp();
+    }
+}
+]]></programlisting>
+
+    <para>
+        次に、このプロパティでファイルを指定できます。
         そうすると、そのファイルはフロントコントローラをディスパッチせず、
         単にフロントコントローラ (とアプリケーション固有の設定)
         を準備するだけの役割となります。
@@ -39,12 +63,12 @@ class UserControllerTest extends Zend_Test_PHPUnit_ControllerTestCase
 ]]></programlisting>
 
     <para>
-        2 番目の方法として、アプリケーションを起動するための
-        <acronym>PHP</acronym> コールバックを指定することができます。
+        番目の方法として、アプリケーションを起動するための
+        <acronym>PHP</acronym> コールバックを指定できます。
         この方法は <link
             linkend="zend.test.phpunit.loginexample">Login サンプル</link>
         で使用しています。使用するコールバックが関数や static
-        メソッドである場合は、クラスレベルで設定することができます。
+        メソッドである場合は、クラスレベルで設定できます。
     </para>
 
     <programlisting language="php"><![CDATA[