/[suikacvs]/markup/html/html5/spec-ja/data/documents.dat
Suika

Diff of /markup/html/html5/spec-ja/data/documents.dat

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by apache, Sun Aug 10 08:20:29 2008 UTC revision 1.44 by apache, Wed Aug 20 16:19:16 2008 UTC
# Line 1  Line 1 
   
1  #pattern  #pattern
2  <span class=secno>* </span>Semantics and structure of HTML  <span class=secno>* </span>Semantics and structure of HTML
3     documents     documents
# Line 8  Line 7 
7  #pattern  #pattern
8  <span class=secno>* </span>Documents  <span class=secno>* </span>Documents
9  #ja  #ja
 <span class=secno>$1 </span>文書  
10    <span class=secno>$1 </span>文書
11    
12    #en
13    Every XML and HTML document in an HTML UA is represented by a
14       <code>Document</code> object. <a href="#refsDOM3CORE">[DOM3CORE]</a>
15    #ja
16    HTML 利用者エージェントにおけるすべての XML や HTML の文書は
17    <code>Document</code> オブジェクトにより表現されます。 <a href="#refsDOM3CORE">[DOM3CORE]</a>
18    
19    #pattern
20    <span class=secno>* </span>Documents in the DOM
21    #ja
22    <span class=secno>$1 </span>DOM 中の文書
23    
24    #en
25    <code>Document</code> objects are assumed to be <dfn
26       id=xml-documents>XML documents</dfn> unless they are flagged as being <dfn
27       id=html->HTML documents</dfn> when they are created. Whether a document is
28       an <a href="#html-" title="HTML documents">HTML document</a> or an <a
29       href="#xml-documents" title="XML documents">XML document</a> affects the
30       behavior of certain APIs, as well as a few CSS rendering rules. <a
31       href="#refsCSS21">[CSS21]</a>
32    #ja
33    <code>Document</code> オブジェクトは、作成された時に
34    <dfn
35       id=html->HTML 文書</dfn>であると旗付けされていなければ、 <dfn
36       id=xml-documents>XML 文書</dfn>であると見なします。
37    文書が <a href="#html-" title="HTML documents">HTML 文書</a>であるか <a
38       href="#xml-documents" title="XML documents">XML 文書</a>であるかは、
39    いくつかの API の動作や CSS のレンダリング規則の一部に影響します。 <a
40       href="#refsCSS21">[CSS21]</a>
41    
42    #en
43    A <code>Document</code> object created by the <code
44       title="">createDocument()</code> API on the <code>DOMImplementation</code>
45       object is initially an <a href="#xml-documents" title="XML documents">XML
46       document</a>, but can be made into an <a href="#html-" title="HTML
47       documents">HTML document</a> by calling <code title=dom-document-open><a
48       href="#open">document.open()</a></code> on it.
49    #ja
50    <code>DOMImplementation</code> 上の <code
51       title="">createDocument()</code> API により作成された <code>Document</code>
52    オブジェクトははじめ <a href="#xml-documents" title="XML documents">XML
53       文書</a>ですが、 <code title=dom-document-open><a
54       href="#open">document.open()</a></code>
55    を呼び出すことにより <a href="#html-" title="HTML
56       documents">HTML 文書</a>にすることができます。
57    
58    #en
59    All <code>Document</code> objects (in user agents implementing this
60       specification) must also implement the <code><a
61       href="#htmldocument">HTMLDocument</a></code> interface, available using
62       binding-specific methods. (This is the case whether or not the document in
63       question is an <a href="#html-" title="HTML documents">HTML document</a>
64       or indeed whether it contains any <a href="#html-elements">HTML
65       elements</a> at all.) <code>Document</code> objects must also implement
66       the document-level interface of any other namespaces found in the document
67       that the UA supports. For example, if an HTML implementation also supports
68       SVG, then the <code>Document</code> object must implement <code><a
69       href="#htmldocument">HTMLDocument</a></code> and <code>SVGDocument</code>.
70    #ja
71    (この仕様書を実装する利用書エージェントにおける) すべての
72    <code>Document</code>
73    オブジェクトは、 <code><a
74       href="#htmldocument">HTMLDocument</a></code> 界面をも実装し、
75    束縛規定の方式により利用可能としなければ[[MUST:なりません]]。
76    (これは当該文書が <a href="#html-" title="HTML documents">HTML 文書</a>であるか否かや、
77    そもそも <a href="#html-elements">HTML
78       要素</a>を含んでいるか否かによらずのことです。)
79    <code>Document</code> オブジェクトは、文書中に現れ、利用者エージェントが対応している、
80    他の名前空間の文書水準の界面をも実装しなければ[[MUST:なりません]]。
81    例えば、 HTML 実装が SVG にも対応している場合、 <code>Document</code>
82    オブジェクトは <code><a
83       href="#htmldocument">HTMLDocument</a></code> と
84    <code>SVGDocument</code> を実装しなければなりません<!-- 例示なので MUST でなく must -->。
85    
86    #en
87    Because the <code><a
88       href="#htmldocument">HTMLDocument</a></code> interface is now obtained
89       using binding-specific casting methods instead of simply being the primary
90       interface of the document object, it is no longer defined as inheriting
91       from <code>Document</code>.
92    #ja
93    <code><a
94       href="#htmldocument">HTMLDocument</a></code>
95    界面は現在では単純に文書オブジェクトの主たる界面であるとするのではなく、
96    束縛規定の型変換方式を使って得るものとしているので、
97    最早 <code>Document</code> から継承するとは定義していません。
98    
99    #en
100    Since the <code><a href="#htmldocument">HTMLDocument</a></code>
101       interface holds methods and attributes related to a number of disparate
102       features, the members of this interface are described in various different
103       sections.
104    #ja
105    <code><a href="#htmldocument">HTMLDocument</a></code>
106    界面は色々な機能に関係するメソッドや属性を持っていますので、
107    この界面の構成員はそれぞれの節で説明します。
108    
109    #en
110    User agents must raise a <a href="#security10">security exception</a>
111       whenever any of the members of an <code><a
112       href="#htmldocument">HTMLDocument</a></code> object are accessed by
113       scripts whose <a href="#effective3">effective script origin</a> is not the
114       <a href="#same-origin" title="same origin">same</a> as the
115       <code>Document</code>'s <a href="#effective3">effective script origin</a>.
116    #ja
117    利用者エージェントは、 <code><a
118       href="#htmldocument">HTMLDocument</a></code>
119    オブジェクトの構成員のいずれかが、
120    <a href="#effective3">実効スクリプト起源</a>が <code>Document</code>
121    の<a href="#effective3">実効スクリプト起源</a>と<a href="#same-origin" title="same origin">同じ</a>ではないスクリプトからアクセスされる場合に、
122    常に、
123    <a href="#security10">保安性例外</a>を発生させなければ[[MUST:なりません]]。
124    
125    #pattern
126    <span class=secno>* </span><dfn id=resource0>Resource
127       metadata management</dfn>
128    #ja
129    <span class=secno>$1 </span><dfn id=resource0>資源メタデータ管理</dfn>
130    
131    #en
132    The <dfn id=url0 title=dom-document-URL><code>URL</code></dfn> attribute
133       must return <span>the document's address</span><!--
134      XXXDOCURL xref -->.
135    #ja
136    <dfn id=url0 title=dom-document-URL><code>URL</code></dfn>
137    属性は<span>文書の番地</span><!--
138      XXXDOCURL xref -->を返さなければ[[MUST:なりません]]。
139    
140    #en
141    The <dfn id=referrer
142       title=dom-document-referrer><code>referrer</code></dfn> attribute must
143       return either the <span title="the document's
144       address">address</span><!-- XXXDOXURL xref --> of the <a
145       href="#active">active document</a> of the <a href="#source0">source
146       browsing context</a> at the time the navigation was started (that is, the
147       page which <a href="#navigate" title=navigate>navigated</a> the <a
148       href="#browsing1">browsing context</a> to the current document), or the
149       empty string if there is no such originating page, or if the UA has been
150       configured not to report referrers in this case, or if the navigation was
151       initiated for a <a href="#hyperlinks">hyperlink</a> with a <code
152       title=rel-noreferrer><a href="#noreferrer">noreferrer</a></code> keyword.
153    #ja
154    <dfn id=referrer
155       title=dom-document-referrer><code>referrer</code></dfn>
156    属性は、操縦が開始された時点での<a href="#source0">原始閲覧文脈</a>の<a
157       href="#active">活性文書</a>
158    (<a
159       href="#browsing1">閲覧文脈</a>を現在の文書に<a href="#navigate" title=navigate>操縦</a>した頁)
160    の<span title="the document's
161       address">番地</span><!-- XXXDOXURL xref -->か、
162    または、そのような元々の頁がない場合、利用者エージェントがこの場合に参照子を報告しないように設定されている場合、
163    操縦が <code
164       title=rel-noreferrer><a href="#noreferrer">noreferrer</a></code>
165    キーワードのある<a href="#hyperlinks">ハイパーリンク</a>について初期化された場合には空文字列、
166    このいずれかを返さなければ[[MUST:なりません]]。
167    
168    
169    #en
170    In the case of HTTP, the <code title=dom-document-referrer><a
171       href="#referrer">referrer</a></code> DOM attribute will match the <code
172       title="">Referer</code> (sic) header that was sent when <a href="#fetch"
173       title=fetch>fetching</a> the current page.
174    #ja
175    HTTP の場合、 <code title=dom-document-referrer><a
176       href="#referrer">referrer</a></code> DOM 属性は現在の頁を<a href="#fetch"
177       title=fetch>取ってくる</a>時に送られた <code
178       title="">Referer</code> (ママ) 頭部と一致します。
179    
180    #en
181    Typically user agents are configured to not report referrers
182       in the case where the referrer uses an encrypted protocol and the current
183       page does not (e.g. when navigating from an <code title="">https:</code>
184       page to an <code title="">http:</code> page).
185    #ja
186    通常、利用者エージェントは、参照子が暗号化プロトコルを使っており、
187    現在の頁がそうではない場合 (例えば <code title="">https:</code>
188    頁から <code title="">http:</code> 頁へと操縦した時)
189    には参照子を報告しないように設定されています。
190    
191    #en
192    The <dfn id=cookie0 title=dom-document-cookie><code>cookie</code></dfn>
193       attribute represents the cookies of the resource.
194    #ja
195    <dfn id=cookie0 title=dom-document-cookie><code>cookie</code></dfn>
196    属性は、資源のクッキーを表します。
197    
198    #en
199    On getting, if the <a href="#sandboxed2">sandboxed
200       origin browsing context flag</a> is set on the <a
201       href="#browsing1">browsing context</a> of the document, the user agent
202       must raise a <a href="#security10">security exception</a>. Otherwise, it
203       must return the same string as the value of the <code
204       title="">Cookie</code> HTTP header it would include if <a href="#fetch"
205       title=fetch>fetching</a> the resource indicated by <span>the document's
206       address</span><!-- XXXDOCURL --> over HTTP, as per RFC 2109 section 4.3.4
207       or later specifications. <a href="#refsRFC2109">[RFC2109]</a> <a
208       href="#refsRFC2965">[RFC2965]</a>
209    #ja
210    取得時、<a href="#sandboxed2">砂箱起源閲覧文脈旗</a>が文書の<a
211       href="#browsing1">閲覧文脈</a>に設定されている場合には、
212    利用者エージェントは<a href="#security10">保安性例外</a>を発生させなければ[[MUST:なりません]]。
213    そうでない場合、<span>文書の番地</span><!-- XXXDOCURL -->で示される資源を HTTP
214    によって<a href="#fetch"
215       title=fetch>取ってくる</a>場合に RFC 2109
216    4.3.4 節やより新しい仕様書に従って含まれるであろう <code
217       title="">Cookie</code> HTTP 頭部の値と同じ文字列を返さなければ[[MUST:なりません]]。 <a href="#refsRFC2109">[RFC2109]</a> <a
218       href="#refsRFC2965">[RFC2965]</a>
219    
220    #en
221    On setting, if the <a href="#sandboxed2">sandboxed origin browsing
222       context flag</a> is set on the <a href="#browsing1">browsing context</a>
223       of the document, the user agent must raise a <a
224       href="#security10">security exception</a>. Otherwise, the user agent must
225       act as it would when processing cookies if it had just attempted to <a
226       href="#fetch">fetch</a> <span>the document's address</span><!-- XXXDOCURL
227      -->
228       over HTTP, and had received a response with a <code>Set-Cookie</code>
229       header whose value was the specified value, as per RFC 2109 sections
230       4.3.1, 4.3.2, and 4.3.3 or later specifications. <a
231       href="#refsRFC2109">[RFC2109]</a> <a href="#refsRFC2965">[RFC2965]</a>
232    #ja
233    設定時、<a href="#sandboxed2">砂箱起源閲覧文脈旗</a>が文書の<a
234       href="#browsing1">閲覧文脈</a>に設定されている場合には、
235    利用者エージェントは<a href="#security10">保安性例外</a>を発生させなければ[[MUST:なりません]]。
236    そうでない場合、利用者エージェントは、
237    <span>文書の番地</span><!-- XXXDOCURL -->で示される資源を HTTP
238    によって<a href="#fetch"
239       title=fetch>取ってこよう</a>とし、
240    値が指定された値である <code>Set-Cookie</code>
241    頭部がある応答を受信した場合にクッキーを処理する時と同じように、
242    RFC 2109 4.3.1 節、4.3.2 節、4.3.3. 節やより新しい仕様書に従い作用しなければ[[MUST:なりません]]。 <a href="#refsRFC2109">[RFC2109]</a> <a
243       href="#refsRFC2965">[RFC2965]</a>
244    
245    #en
246    Since the <code title=dom-document-cookie><a
247       href="#cookie0">cookie</a></code> attribute is accessible across frames,
248       the path restrictions on cookies are only a tool to help manage which
249       cookies are sent to which parts of the site, and are not in any way a
250       security feature.
251    #ja
252    <code title=dom-document-cookie><a
253       href="#cookie0">cookie</a></code> 属性はフレームをまたいでアクセス可能ですので、
254    クッキーの経路制限はクッキーがサイト上のどの部分に送られるかを管理することを助けるための道具に過ぎず、
255    保安性のための機能では決してありません。
256    
257    #en
258    The <dfn id=lastmodified
259       title=dom-document-lastModified><code>lastModified</code></dfn> attribute,
260       on getting, must return the date and time of the <code>Document</code>'s
261       source file's last modification, in the user's local timezone, in the
262       following format:
263    #ja
264    <dfn id=lastmodified
265       title=dom-document-lastModified><code>lastModified</code></dfn>
266    属性は、取得時、 <code>Document</code> の原始ファイルの最終修正の日時を、
267    利用者の地方時において、次の書式で返さなければ[[MUST:なりません]]。
268    
269    #en
270    The month component of the date.
271    #ja
272    日付の月の部品。
273    
274    #en
275    A U+002F SOLIDUS character ('/').
276    #ja
277    U+002F SOLIDUS 文字 ('/')。
278    
279    #en
280    The day component of the date.
281    #ja
282    日付の日の部品。
283    
284    #en
285    The year component of the date.
286    #ja
287    日付の年の部品。
288    
289    #en
290    A U+0020 SPACE character.
291    #ja
292    U+0020 SPACE 文字。
293    
294    #en
295    The hours component of the time.
296    #ja
297    時刻の時の部品。
298    
299    #en
300    A U+003A COLON character (':').
301    #ja
302    U+003A COLON 文字 (':')。
303    
304    #en
305    The minutes component of the time.
306    #ja
307    時刻の分の部品。
308    
309    #en
310    The seconds component of the time.
311    #ja
312    時刻の秒の部品。
313    
314    #en
315    All the numeric components above, other than the year, must be given as
316       two digits in the range U+0030 DIGIT ZERO to U+0039 DIGIT NINE
317       representing the number in base ten, zero-padded if necessary.
318    #ja
319    前述の数値の部品のうち年以外のすべては、範囲 U+0030 DIGIT ZERO ~
320    U+0039 DIGIT NINE の2つの数字によって十進数を表す、
321    必要なら零埋めしたものとして与えなければ[[MUST:なりません]]。
322    
323    #en
324    The <code>Document</code>'s source file's last modification date and
325       time must be derived from relevant features of the networking protocols
326       used, e.g. from the value of the HTTP <code title="">Last-Modified</code>
327       header of the document, or from metadata in the file system for local
328       files. If the last modification date and time are not known, the attribute
329       must return the string <code title="">01/01/1970 00:00:00</code>.
330    #ja
331    <code>Document</code> の原始ファイルの最終修正日時は、
332    使用されているネットワークのプロトコルの関係する機能、例えば文書の HTTP <code title="">Last-Modified</code> 頭部から、または局所ファイルのファイル・システムのメタデータから得たものでなければ[[MUST:なりません]]。
333    最終修正日時がわからない場合は、この属性は文字列 <code title="">01/01/1970 00:00:00</code>
334    を返さなければ[[MUST:なりません]]。
335    
336    #en
337    The <code>Document</code>'s source file's last modification date and
338       time must be derived from relevant features of the networking protocols
339       used, e.g. from the value of the HTTP <code title="">Last-Modified</code>
340       header of the document, or from metadata in the file system for local
341       files. If the last modification date and time are not known, the attribute
342       must return the string <code title="">01/01/1970 00:00:00</code>.
343    #ja
344    <code>Document</code> の原始ファイルの最終修正日時は、
345    使用されているネットワークのプロトコルの関係する機能、例えば文書の HTTP <code title="">Last-Modified</code> 頭部から、または局所ファイルのファイル・システムのメタデータから得たものでなければ[[MUST:なりません]]。
346    最終修正日時がわからない場合は、この属性は文字列 <code title="">01/01/1970 00:00:00</code>
347    を返さなければ[[MUST:なりません]]。
348    
349    #en
350    A <code>Document</code> is always set to one of three modes: <dfn
351       id=no-quirks>no quirks mode</dfn>, the default; <dfn id=quirks>quirks
352       mode</dfn>, used typically for legacy documents; and <dfn
353       id=limited1>limited quirks mode</dfn>, also known as "almost standards"
354       mode. The mode is only ever changed from the default by the <a
355       href="#html-0">HTML parser</a>, based on the presence, absence, or value
356       of the DOCTYPE string.
357    #ja
358    <code>Document</code> は常に3つのモードのいずれかに設定されています。<dfn
359       id=no-quirks>無奇癖モード</dfn>は既定値です。<dfn id=quirks>奇癖モード</dfn>は、
360    普通、遺物文書に使われます。<dfn
361       id=limited1>制限奇癖モード</dfn>は、「ほぼ標準」モードとも呼ばれます。
362    このモードは
363    <a
364       href="#html-0">HTML 構文解析器</a>によってのみ、
365    DOCTYPE 文字列が存在するか存在しないかやその値に基づいて既定値から変更されます。
366    
367    #en
368    The <dfn id=compatmode
369       title=dom-document-compatMode><code>compatMode</code></dfn> DOM attribute
370       must return the literal string "<code title="">CSS1Compat</code>" unless
371       the document has been set to <a href="#quirks">quirks mode</a> by the <a
372       href="#html-0">HTML parser</a>, in which case it must instead return the
373       literal string "<code title="">BackCompat</code>".
374    #ja
375    <dfn id=compatmode
376       title=dom-document-compatMode><code>compatMode</code></dfn> DOM
377    属性は、生の文字列「<code title="">CSS1Compat</code>」を返さなければ[[MUST:なりません]]。
378    ただし、文書が <a
379       href="#html-0">HTML 構文解析器</a>により<a href="#quirks">奇癖モード</a>に設定されている場合には、
380    代わりに名前の文字列「<code title="">BackCompat</code>」を返さなければ[[MUST:なりません]]。
381    
382    #en
383    Documents have an associated <dfn id=character3 title="document's
384       character encoding">character encoding</dfn>. When a <code>Document</code>
385       object is created, the <a href="#character3">document's character
386       encoding</a> must be initialized to UTF-16. Various algorithms during page
387       loading affect this value, as does the <code title=dom-document-charset><a
388       href="#charset0">charset</a></code> setter. <a
389       href="#refsIANACHARSET">[IANACHARSET]</a> <!-- XXX
390      http://www.iana.org/assignments/character-sets -->
391    #ja
392    文書は<dfn id=character3 title="document's
393       character encoding">文字符号化</dfn>と関連付けられています。
394    <code>Document</code> オブジェクトが作成された時、<a href="#character3">文書の文字符号化</a>は
395    UTF-16 に初期化されなければ[[MUST:なりません]]。
396    頁の読み込みの間の色々な算法や <code title=dom-document-charset><a
397       href="#charset0">charset</a></code> 設定子がこの値を変化させます。 <a
398       href="#refsIANACHARSET">[IANACHARSET]</a> <!-- XXX
399      http://www.iana.org/assignments/character-sets -->
400    
401    #en
402    The <dfn id=charset0
403       title=dom-document-charset><code>charset</code></dfn> DOM attribute must,
404       on getting, return the preferred MIME name of the <a
405       href="#character3">document's character encoding</a>. On setting, if the
406       new value is an IANA-registered alias for a character encoding, the <a
407       href="#character3">document's character encoding</a> must be set to that
408       character encoding. (Otherwise, nothing happens.)
409    #ja
410    <dfn id=charset0
411       title=dom-document-charset><code>charset</code></dfn> DOM
412    属性は、取得時、<a
413       href="#character3">文書の文字符号化</a>の優先 MIME
414    名を返さなければ[[MUST:なりません]]。設定時、
415    新しい値がある文字符号化の IANA に登録された別名である場合、<a
416       href="#character3">文書の文字符号化</a>をその文字符号化に設定しなければ[[MUST:なりません]]。
417    (それ以外の場合、何も起きません。)
418    
419    #en
420    The <dfn id=characterset
421       title=dom-document-characterSet><code>characterSet</code></dfn> DOM
422       attribute must, on getting, return the preferred MIME name of the <a
423       href="#character3">document's character encoding</a>.
424    #ja
425    <dfn id=characterset
426       title=dom-document-characterSet><code>characterSet</code></dfn> DOM
427    属性は、取得時、<a
428       href="#character3">文書の文字符号化</a>の優先 MIME 名を返さなければ[[MUST:なりません]]。
429    
430    #en
431    The <dfn id=defaultcharset
432       title=dom-document-defaultCharset><code>defaultCharset</code></dfn> DOM
433       attribute must, on getting, return the preferred MIME name of a character
434       encoding, possibly the user's default encoding, or an encoding associated
435       with the user's current geographical location, or any arbitrary encoding
436       name.
437    #ja
438    <dfn id=defaultcharset
439       title=dom-document-defaultCharset><code>defaultCharset</code></dfn>
440    DOM 属性は、取得時、文字符号化の優先 MIME 名を返さなければ[[MUST:なりません]]。
441    この文字符号化は利用者の既定の符号化でもいいですし、
442    利用者の現在の地理的位置に関連付けられた符号化でもいいですし、
443    その他任意の符号化名でもあり得ます。
444    
445    #pattern
446    <span class=secno>* </span><dfn id=dom-tree0>DOM tree
447       accessors</dfn>
448    #ja
449    <span class=secno>$1 </span><dfn id=dom-tree0>DOM 木アクセス器</dfn>
450    
451    #en
452    <dfn id=the-html0>The <code>html</code> element</dfn> of a document is
453       the document's root element, if there is one and it's an <code><a
454       href="#html">html</a></code> element, or null otherwise.
455    #ja
456    文書の<dfn id=the-html0>文書 <code>html</code> 要素</dfn>は、
457    その文書の根要素があり、それが <code><a
458       href="#html">html</a></code> 要素である場合はその要素、それ以外の場合には
459    null です。
460    
461    #en
462    <dfn id=the-head0>The <code>head</code> element</dfn> of a document is
463       the first <code><a href="#head">head</a></code> element that is a child of
464       <a href="#the-html0">the <code>html</code> element</a>, if there is one,
465       or null otherwise.
466    #ja
467    文書の<dfn id=the-head0>文書 <code>head</code> 要素</dfn>は、
468    <a href="#the-html0">文書 <code>html</code> 要素</a>の子供である最初の
469    <code><a href="#head">head</a></code> 要素がある場合はその要素、
470    そうでない場合は null です。

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.44

[email protected]
ViewVC Help
Powered by ViewVC 1.1.24