Browse Source

[DOCUMENTATION] Japanese sync 19571, 19554, 19568

git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@19572 44c647ce-9c0f-0410-b52a-842ac1e357ba
yoshida@zend.co.jp 16 years ago
parent
commit
279c91a527

+ 45 - 1
documentation/manual/ja/module_specs/Zend_Application-CoreFunctionality-Bootstrap_Bootstrap.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 15718 -->
+<!-- EN-Revision: 19751 -->
 <sect2 id="zend.application.core-functionality.bootstrap-bootstrap">
     <title>Zend_Application_Bootstrap_Bootstrap</title>
 
@@ -19,4 +19,48 @@
         多くの場合、ブートストラップする必要性に応じて拡張するか、
         このクラスを単純に使って、利用するリソースプラグインのリストを与えたいことでしょう。
     </para>
+
+    <!-- TODO : to be translated -->
+    <sect3 id="zend.application.core-functionality.bootstrap-bootstrap.autoloading">
+        <title>Enabling Application Autoloading</title>
+
+        <para>
+            Additionally, this bootstrap implementation provides the ability to specify the
+            "namespace" or class prefix for resources located in its tree, which will enable
+            autoloading of various application resources; essentially, it instantiates a <link
+                linkend="zend.loader.autoloader-resource.module">Zend_Application_Module_Autoloader</link>
+            object, providing the requested namespace and the bootstrap's directory as arguments.
+            You may enable this functionality by providing a namespace to the "appnamespace"
+            configuration option. As an INI example:
+        </para>
+
+        <programlisting language="ini"><![CDATA[
+appnamespace = "Application"
+]]></programlisting>
+
+        <para>
+            Or in XML:
+        </para>
+
+        <programlisting language="xml"><![CDATA[
+<appnamespace>Application</appnamespace>
+]]></programlisting>
+
+        <para>
+            By default, <classname>Zend_Tool</classname> will enable this option with the value
+            "Application".
+        </para>
+
+        <para>
+            Alternately, you can simply define the <varname>$_appNamespace</varname> property of your
+            bootstrap class with the appropriate value:
+        </para>
+
+        <programlisting language="php"><![CDATA[
+class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
+{
+    protected $_appNamespace = 'Application';
+}
+]]></programlisting>
+    </sect3>
 </sect2>

+ 28 - 8
documentation/manual/ja/module_specs/Zend_Form-Elements.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 17618 -->
+<!-- EN-Revision: 19554 -->
 <sect1 id="zend.form.elements">
     <title>Zend_Form_Element を用いたフォーム要素の作成</title>
 
@@ -51,7 +51,7 @@
         <para>
             <classname>Zend_Form_Element</classname> は、<link
                 linkend="zend.loader.pluginloader">Zend_Loader_PluginLoader</link>
-            を使用しており、バリデータやフィルタ、デコレータの場所を指定することができます。
+            を使用しており、バリデータやフィルタ、デコレータの場所を指定できます。
             それぞれに独自のプラグインローダーが関連付けられており、
             アクセサを使用して個別に取得したり変更したりできます。
         </para>
@@ -204,7 +204,7 @@ $form->addElementPrefixPath('My_Decorator', 'My/Decorator/', 'decorator');
             これらの操作は
             <classname>Zend_Filter</classname> が行います。
             <classname>Zend_Form_Element</classname> はフィルタチェインをサポートしているので、
-            複数のフィルタを順に適用することができます。
+            複数のフィルタを順に適用できます。
             フィルタリングは、バリデーションの際や要素の値を <code>getValue()</code>
             で取得する際に行われます。
         </para>
@@ -577,7 +577,7 @@ class My_Validate_PasswordConfirmation extends Zend_Validate_Abstract
 
         <para>
             検証に失敗したときは、バリデータチェインから
-            エラーコードとメッセージを取得することができます。
+            エラーコードとメッセージを取得できます。
         </para>
 
         <programlisting language="php"><![CDATA[
@@ -592,7 +592,7 @@ $messages = $element->getMessages();
 
         <para>
             バリデータに加えて、ある要素が必須である場合は
-            <code>setRequired(true)</code> を使用することができます。
+            <code>setRequired(true)</code> を使用できます。
             デフォルトではこのフラグは false です。
             この場合は、<code>isValid()</code>
             に何も値が渡されなかった場合はバリデーションチェインをスキップします。
@@ -626,7 +626,7 @@ $messages = $element->getMessages();
                 <para>
                     この振る舞いが気に入らない場合は、
                     <code>setAutoInsertNotEmptyValidator($flag)</code>
-                    に false を渡せばこの機能を無効にすることができます。
+                    に false を渡せばこの機能を無効にできます。
                     この場合、 <code>isValid()</code>
                     がバリデータチェインに勝手に
                     'NotEmpty' バリデータを追加することはなくなります。
@@ -651,6 +651,26 @@ $messages = $element->getMessages();
             </para>
         </note>
 
+        <!-- TODO : to be translated -->
+        <note>
+            <title>When is an element detected as empty?</title>
+
+            <para>
+                As mentioned the 'NotEmpty' validator is used to detect if an element is empty
+                or not. But <classname>Zend_Validate_NotEmpty</classname> does, per default, not
+                work like <acronym>PHP</acronym>'s method <methodname>empty()</methodname>.
+            </para>
+
+            <para>
+                This means when an element contains an integer <emphasis>0</emphasis> or an string
+                <emphasis>'0'</emphasis> then the element will be seen as not empty. If you want to
+                have a different behaviour you must create your own instance of
+                <classname>Zend_Validate_NotEmpty</classname>. There you can define the behaviour of
+                this validator. See <ulink
+                    url="zend.validate.set.notempty">Zend_Validate_NotEmpty</ulink> for details.
+            </para>
+        </note>
+
         <para>
             検証関係のメソッドを以下にまとめます。
         </para>
@@ -1032,7 +1052,7 @@ echo $element->renderHtmlTag("This is the html tag content");
 
         <para>
             <classname>Zend_Form_Element</classname> は、
-            要素の属性やメタデータを処理することができます。
+            要素の属性やメタデータを処理できます。
             基本的な属性には次のようなものがあります。
         </para>
 
@@ -1265,7 +1285,7 @@ $element->class = 'text;
 
         <para>
             <classname>Zend_Form_Element</classname> のコンストラクタには、配列あるいは
-            <classname>Zend_Config</classname> オブジェクトでオプションを指定することができます。
+            <classname>Zend_Config</classname> オブジェクトでオプションを指定できます。
             また、<code>setOptions()</code> や
             <code>setConfig()</code> で設定を変更することもできます。
             一般に、キーの名前は次のようになります。

+ 4 - 4
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: 18840 -->
+<!-- EN-Revision: 19568 -->
 <sect2 id="zend.test.phpunit.bootstrapping">
     <title>テストケースの起動</title>
 
@@ -10,7 +10,7 @@
         テストケースは
         <classname>Zend_Test_PHPUnit_ControllerTestCase</classname>
         を継承しなければなりません。このクラスは
-        <code>PHPUnit_Framework_TestCase</code> を継承しており、
+        <classname>PHPUnit_Framework_TestCase</classname> を継承しており、
         PHPUnit が提供する仕組みやアサーションをすべて使用できます。
         またそれに加えて、Zend Framework の
         <acronym>MVC</acronym> 実装に特化した scaffold 機能やアサーションもあります。
@@ -111,8 +111,8 @@ class UserControllerTest extends Zend_Test_PHPUnit_ControllerTestCase
         プラグインやヘルパーをすべてリセットし、
         フロントコントローラをリセットして
         リクエストオブジェクトとレスポンスオブジェクトを新しく作成します。
-        それが終わったら、<code>$bootstrap</code>
-        で指定したファイルを読み込むか、
+        それが終わったら、<varname>$bootstrap</varname>
+        で指定したファイルを <methodname>include()</methodname> するか、
         あるいは指定したコールバックを呼び出します。
     </para>
 

+ 2 - 2
documentation/manual/ja/module_specs/Zend_Test-PHPUnit.xml

@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!-- Reviewed: no -->
-<!-- EN-Revision: 17175 -->
+<!-- EN-Revision: 19568 -->
 <sect1 id="zend.test.phpunit" xmlns:xi="http://www.w3.org/2001/XInclude">
     <title>Zend_Test_PHPUnit</title>
 
@@ -17,7 +17,7 @@
 
         <para>
             以下に示すのは
-            <code>UserController</code>
+            <classname>UserController</classname>
             用のシンプルなテストケースで、以下のような内容を検証します。
         </para>