Skip to content

Commit 9dded7a

Browse files
doc-en と同期し 11 モジュールを完訳(既訳更新 15 件・新規翻訳 2 件) (php#382)
## 翻訳内容 ### sscanf/fscanf 系(3件)— 負の戻り値 -1 の明確化 - reference/strings/functions/sscanf.xml 1. php/doc-en@9947012 - reference/spl/splfileobject/fscanf.xml 1. php/doc-en@9947012 - reference/filesystem/functions/fscanf.xml 1. php/doc-en@9947012 ### IMAGETYPE_HEIF 定数追加(4件・PHP 8.5) - appendices/migration85/constants.xml 1. php/doc-en@f8bab1d - reference/image/constants.xml 1. php/doc-en@f8bab1d - reference/image/functions/image-type-to-mime-type.xml 1. php/doc-en@f8bab1d - reference/exif/functions/exif-imagetype.xml 1. php/doc-en@f8bab1d ### exit 終了コード挙動(2件・PHP 8.4.0) - reference/misc/functions/exit.xml 1. php/doc-en@2312f82 - reference/funchand/functions/register-shutdown-function.xml 1. php/doc-en@2312f82 ### reference/soap(2件・新規翻訳)— PHP 8.4 resource→Object 変換 - reference/soap/soap.sdl.xml 1. php/doc-en@89205c8 - reference/soap/soap.url.xml 1. php/doc-en@89205c8 ### 独立ファイル(6件) - reference/image/functions/imagecopyresampled.xml — 戻り値型の 8.5.0 changelog を追加 1. php/doc-en@16b6c34 - reference/url/functions/http-build-query.xml — オブジェクトと __toString() の挙動を明確化 1. php/doc-en@f72c603 - reference/exec/functions/proc-close.xml — proc_get_status との終了ステータスの関係を明確化 1. php/doc-en@ef623cc - reference/hash/functions/hash.xml — changelog に E_WARNING を追記 1. php/doc-en@df2a77a - reference/stream/streamwrapper/stream-lock.xml — LOCK_NB を単独モードとして記述 1. php/doc-en@38231ac - reference/memcached/memcached/construct.xml — __construct() のパラメータ説明を補完 1. php/doc-en@c49d175 ### 完訳になったモジュール(11) filesystem / image / exif / soap / url / exec / hash / stream / memcached / misc / funchand
1 parent 3b33599 commit 9dded7a

17 files changed

Lines changed: 444 additions & 189 deletions

File tree

appendices/migration85/constants.xml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: ec45af749649dc0d6a23eaedeed1b601f7460813 Maintainer: mumumu Status: ready -->
3+
<!-- EN-Revision: f8bab1dfb5246788f144103de56208dd133e9461 Maintainer: mumumu Status: ready -->
44
<sect1 xml:id="migration85.constants">
55
<title>新しいグローバル定数</title>
66

@@ -162,6 +162,9 @@
162162
<title>Standard</title>
163163

164164
<simplelist>
165+
<member>
166+
<constant>IMAGETYPE_HEIF</constant>
167+
</member>
165168
<member>
166169
<constant>IMAGETYPE_SVG</constant>
167170
when libxml is loaded.

reference/exec/functions/proc-close.xml

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 350d95443aeb0ea8751d71f262aac56d3ad48f83 Maintainer: hirokawa Status: ready -->
3+
<!-- EN-Revision: ef623ccf442df416da4e5bc254b4c5d4f6df9475 Maintainer: hirokawa Status: ready -->
44
<!-- CREDITS: shimooka,mumumu -->
55
<!-- splitted from ./en/functions/exec.xml, last change in rev 1.28 -->
66
<refentry xml:id='function.proc-close' xmlns="http://docbook.org/ns/docbook">
@@ -51,7 +51,29 @@
5151
</para>
5252
&note.sigchild;
5353
</refsect1>
54-
54+
<refsect1 role="changelog">
55+
&reftitle.changelog;
56+
<informaltable>
57+
<tgroup cols="2">
58+
<thead>
59+
<row>
60+
<entry>&Version;</entry>
61+
<entry>&Description;</entry>
62+
</row>
63+
</thead>
64+
<tbody>
65+
<row>
66+
<entry>8.3.0</entry>
67+
<entry>
68+
先に <function>proc_get_status</function> が呼び出された後でも、
69+
<function>proc_close</function> は正しい終了コードを返すようになりました。
70+
これより前のバージョンでは、<literal>-1</literal> を返していました。
71+
</entry>
72+
</row>
73+
</tbody>
74+
</tgroup>
75+
</informaltable>
76+
</refsect1>
5577
</refentry>
5678

5779
<!-- Keep this comment at the end of the file

reference/exif/functions/exif-imagetype.xml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 6a08181be1706dfebdb3ad6e45620bceb08019ba Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: f8bab1dfb5246788f144103de56208dd133e9461 Maintainer: takagi Status: ready -->
44
<!-- Credits: mumumu -->
55
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.exif-imagetype">
66
<refnamediv>
@@ -137,6 +137,10 @@
137137
<entry>19</entry>
138138
<entry><constant>IMAGETYPE_AVIF</constant></entry>
139139
</row>
140+
<row>
141+
<entry>20</entry>
142+
<entry><constant>IMAGETYPE_HEIF</constant></entry>
143+
</row>
140144
</tbody>
141145
</tgroup>
142146
</table>
@@ -175,6 +179,12 @@
175179
AVIF をサポートしました。
176180
</entry>
177181
</row>
182+
<row>
183+
<entry>8.5.0</entry>
184+
<entry>
185+
HEIF をサポートしました。
186+
</entry>
187+
</row>
178188
</tbody>
179189
</tgroup>
180190
</informaltable>

reference/filesystem/functions/fscanf.xml

Lines changed: 52 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 4225e50bc391ddba99e367c231463da0dc04357d Maintainer: hirokawa Status: ready -->
3+
<!-- EN-Revision: 9947012f745f0fb6e083bce5a8c920213ff468b7 Maintainer: hirokawa Status: ready -->
44
<!-- CREDITS: shimooka,mumumu -->
55
<refentry xml:id="function.fscanf" xmlns="http://docbook.org/ns/docbook">
66
<refnamediv>
@@ -16,66 +16,69 @@
1616
<methodparam><type>string</type><parameter>format</parameter></methodparam>
1717
<methodparam rep="repeat"><type>mixed</type><parameter role="reference">vars</parameter></methodparam>
1818
</methodsynopsis>
19-
<para>
19+
<simpara>
2020
関数<function>fscanf</function> は <function>sscanf</function>
2121
に似ていますが、<parameter>stream</parameter> が指すファイルから入力を取得し、
2222
指定したフォーマット <parameter>format</parameter> に基づき解釈を行います。
23-
</para>
24-
<para>
23+
</simpara>
24+
<simpara>
2525
フォーマット文字列におけるあらゆる空白は
2626
入力ストリームのあらゆる空白にマッチします。
2727
これはつまりフォーマット文字列のタブ (<literal>\t</literal>) すらも
2828
入力ストリームの空白1個にマッチしてしまうことを意味します。
29-
</para>
30-
<para>
29+
</simpara>
30+
<simpara>
3131
<function>fscanf</function> をコールするたびに、ファイルから 1 行ずつ読み込みます。
32-
</para>
32+
</simpara>
3333
</refsect1>
3434

3535
<refsect1 role="parameters">
3636
&reftitle.parameters;
37-
<para>
38-
<variablelist>
39-
<varlistentry>
40-
<term><parameter>stream</parameter></term>
41-
<listitem>
42-
&fs.file.pointer;
43-
</listitem>
44-
</varlistentry>
45-
&strings.scanf.parameter.format;
46-
<varlistentry>
47-
<term><parameter>vars</parameter></term>
48-
<listitem>
49-
<para>
50-
オプションで代入する値。
51-
</para>
52-
</listitem>
53-
</varlistentry>
54-
</variablelist>
55-
</para>
37+
<variablelist>
38+
<varlistentry>
39+
<term><parameter>stream</parameter></term>
40+
<listitem>
41+
&fs.file.pointer;
42+
</listitem>
43+
</varlistentry>
44+
&strings.scanf.parameter.format;
45+
<varlistentry>
46+
<term><parameter>vars</parameter></term>
47+
<listitem>
48+
<simpara>
49+
オプションで代入する値。
50+
</simpara>
51+
</listitem>
52+
</varlistentry>
53+
</variablelist>
5654
</refsect1>
5755

5856
<refsect1 role="returnvalues">
5957
&reftitle.returnvalues;
60-
<para>
58+
<simpara>
6159
この関数のパラメータが二つだけの場合、処理された値は配列として返されます。
6260
他方、オプションのパラメータが指定された場合、
6361
この関数は、代入された値の数を返します。
6462
オプション引数は参照渡しとする必要があります。
65-
</para>
66-
<para>
63+
</simpara>
64+
<simpara>
6765
<parameter>string</parameter> で利用可能な部分文字列よりも、
6866
<parameter>format</parameter> で期待された部分文字列の数が多い場合は、&null; が返されます。
6967
その他のエラーが発生した場合は、&false; が返されます。
70-
</para>
68+
</simpara>
69+
<simpara>
70+
オプションのパラメータを使用していて、
71+
いずれかの値がパースされる前に
72+
<parameter>stream</parameter> から読み込んだ入力の終端に達した場合は、
73+
<literal>-1</literal> が返されます。
74+
</simpara>
7175
</refsect1>
7276

7377
<refsect1 role="examples">
7478
&reftitle.examples;
75-
<para>
76-
<example>
77-
<title><function>fscanf</function> の例</title>
78-
<programlisting role="php">
79+
<example>
80+
<title><function>fscanf</function> の例</title>
81+
<programlisting role="php">
7982
<![CDATA[
8083
<?php
8184
$handle = fopen("users.txt", "r");
@@ -86,36 +89,31 @@ while ($userinfo = fscanf($handle, "%s\t%s\t%s\n")) {
8689
fclose($handle);
8790
?>
8891
]]>
89-
</programlisting>
90-
</example>
91-
</para>
92-
<para>
93-
<example>
94-
<title>users.txt の内容</title>
95-
<programlisting role="txt">
92+
</programlisting>
93+
</example>
94+
<example>
95+
<title>users.txt の内容</title>
96+
<programlisting role="txt">
9697
<![CDATA[
9798
javier argonaut pe
9899
hiroshi sculptor jp
99100
robert slacker us
100101
luigi florist it
101102
]]>
102-
</programlisting>
103-
</example>
104-
</para>
103+
</programlisting>
104+
</example>
105105
</refsect1>
106106

107107
<refsect1 role="seealso">
108108
&reftitle.seealso;
109-
<para>
110-
<simplelist>
111-
<member><function>fread</function></member>
112-
<member><function>fgets</function></member>
113-
<member><function>fgetss</function></member>
114-
<member><function>sscanf</function></member>
115-
<member><function>printf</function></member>
116-
<member><function>sprintf</function></member>
117-
</simplelist>
118-
</para>
109+
<simplelist>
110+
<member><function>fread</function></member>
111+
<member><function>fgets</function></member>
112+
<member><function>fgetss</function></member>
113+
<member><function>sscanf</function></member>
114+
<member><function>printf</function></member>
115+
<member><function>sprintf</function></member>
116+
</simplelist>
119117
</refsect1>
120118

121119
</refentry>

reference/funchand/functions/register-shutdown-function.xml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: b412bbd26214f7281ac7dd858710e09952a275f2 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: 2312f826e5fdedbef87c6288c2c20f9f904b4d0b Maintainer: takagi Status: ready -->
44
<!-- CREDITS: hirokawa -->
55
<refentry xml:id="function.register-shutdown-function" xmlns="http://docbook.org/ns/docbook">
66
<refnamediv>
@@ -25,6 +25,15 @@
2525
登録した関数内で <function>exit</function> をコールした場合、
2626
処理はそこで終了してその他のシャットダウン関数はコールされません。
2727
</para>
28+
<caution>
29+
<simpara>
30+
PHP 8.4.0 以降は、登録したシャットダウン関数内で引数なしの
31+
<function>exit</function> をコールすると、終了コードが
32+
<literal>0</literal> にリセットされます。
33+
明示的にステータスを指定して <function>exit</function> をコールした場合は、
34+
すべてのバージョンで、それ以前の終了コードが上書きされます。
35+
</simpara>
36+
</caution>
2837
<para>
2938
シャットダウン関数は、
3039
別のシャットダウン関数をキューの最後に追加するために、

reference/hash/functions/hash.xml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 539a9823a805ac29cab7fa4baf3ae3a28116a2f5 Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: df2a77acbbb9d381426b863fcfa4d66ac7f5ab6d Maintainer: takagi Status: ready -->
44
<!-- Credits: mumumu -->
55
<refentry xml:id="function.hash" xmlns="http://docbook.org/ns/docbook">
66
<refnamediv>
@@ -71,7 +71,15 @@
7171
そのままのバイナリ形式で返されます。
7272
</para>
7373
</refsect1>
74-
74+
75+
<refsect1 role="errors">
76+
&reftitle.errors;
77+
<simpara>
78+
<parameter>algo</parameter> が不明な場合、
79+
<exceptionname>ValueError</exceptionname> がスローされます。
80+
</simpara>
81+
</refsect1>
82+
7583
<refsect1 role="changelog">
7684
&reftitle.changelog;
7785
<para>
@@ -90,10 +98,10 @@
9098
<row>
9199
<entry>8.0.0</entry>
92100
<entry>
93-
<function>hash</function> は、
94101
<parameter>algo</parameter> が未知の場合に、
95-
<classname>ValueError</classname> をスローするようになりました。
96-
これより前のバージョンでは、&false; を返していました。
102+
<exceptionname>ValueError</exceptionname> をスローするようになりました。
103+
これより前のバージョンでは、&false; を返し、
104+
<constant>E_WARNING</constant> メッセージを発行していました。
97105
</entry>
98106
</row>
99107
</tbody>

reference/image/constants.xml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 7f5d646f3ee39231150e767fb876b56610f56c2b Maintainer: takagi Status: ready -->
3+
<!-- EN-Revision: f8bab1dfb5246788f144103de56208dd133e9461 Maintainer: takagi Status: ready -->
44
<!-- Credits: mumumu -->
55
<appendix xml:id="image.constants" xmlns="http://docbook.org/ns/docbook">
66
&reftitle.constants;
@@ -703,6 +703,18 @@
703703
</simpara>
704704
</listitem>
705705
</varlistentry>
706+
<varlistentry xml:id="constant.imagetype-heif">
707+
<term>
708+
<constant>IMAGETYPE_HEIF</constant>
709+
(<type>int</type>)
710+
</term>
711+
<listitem>
712+
&gd.constants.type;
713+
<simpara>
714+
(PHP 8.5.0 以降で利用可能です)
715+
</simpara>
716+
</listitem>
717+
</varlistentry>
706718
<varlistentry xml:id="constant.imagetype-unknown">
707719
<term>
708720
<constant>IMAGETYPE_UNKNOWN</constant>

reference/image/functions/image-type-to-mime-type.xml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: 89ae180a851621c308f0ea4604ff2e919aa57a7f Maintainer: hirokawa Status: ready -->
3+
<!-- EN-Revision: f8bab1dfb5246788f144103de56208dd133e9461 Maintainer: hirokawa Status: ready -->
44
<!-- CREDITS: shimooka,mumumu -->
55
<refentry xml:id="function.image-type-to-mime-type" xmlns="http://docbook.org/ns/docbook">
66
<refnamediv>
@@ -130,6 +130,10 @@
130130
<entry><constant>IMAGETYPE_AVIF</constant></entry>
131131
<entry><literal>image/avif</literal></entry>
132132
</row>
133+
<row>
134+
<entry><constant>IMAGETYPE_HEIF</constant></entry>
135+
<entry><literal>image/heif</literal></entry>
136+
</row>
133137
</tbody>
134138
</tgroup>
135139
</table>

reference/image/functions/imagecopyresampled.xml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: fcd9214294f88b05862a538c6dd94c7872420139 Maintainer: hirokawa Status: ready -->
3+
<!-- EN-Revision: 16b6c3466bb70f2300b236273003f509638ebb90 Maintainer: hirokawa Status: ready -->
44
<!-- CREDITS: shimooka,mumumu -->
55
<refentry xml:id="function.imagecopyresampled" xmlns="http://docbook.org/ns/docbook">
66
<refnamediv>
@@ -143,6 +143,12 @@
143143
</row>
144144
</thead>
145145
<tbody>
146+
<row>
147+
<entry>8.5.0</entry>
148+
<entry>
149+
戻り値の型が、&true; になりました。これより前のバージョンでは、<type>bool</type> でした。
150+
</entry>
151+
</row>
146152
<row>
147153
<entry>8.0.0</entry>
148154
<entry>

0 commit comments

Comments
 (0)