<html xmlns="http://www.w3.org/1999/xhtml" a0:Name="SuikaWiki" xmlns:a0="urn:x-suika-fam-cx:markup:suikawiki:0:9:" a0:Version="0.9"><head></head><body><p><a0:anchor-end a0:anchor="1">[1]</a0:anchor-end> 【<a0:anchor>SGML</a0:anchor>】 <a0:anchor>公開識別子</a0:anchor>から<a0:anchor>システム識別子</a0:anchor>への変換を定義する文書, あるいはその文書形式。</p><ul><li><a0:anchor-end a0:anchor="2">[2]</a0:anchor-end> <em>カタログの作成と修正</em> <a0:anchor-external a0:resParameter="http://www.linux.or.jp/JF/JFdocs/LDP-Author-Guide/making-catalogues.html" a0:resScheme="URI">http://www.linux.or.jp/JF/JFdocs/LDP-Author-Guide/making-catalogues.html</a0:anchor-external></li><li><a0:anchor-end a0:anchor="3">[3]</a0:anchor-end> <em>TR 9401:1995 - Entity Management</em> <a0:anchor-external a0:resParameter="http://www.oasis-open.org/cover/tr9401.html" a0:resScheme="URI">http://www.oasis-open.org/cover/tr9401.html</a0:anchor-external></li><li><a0:anchor-end a0:anchor="4">[4]</a0:anchor-end> 日本語の情報はほとんどないです。 (自明だからかな?)</li><li><a0:anchor-end a0:anchor="5">[5]</a0:anchor-end> <a0:anchor>JIS-TR</a0:anchor> も変な標準情報ばっかり増やさないで、こういうのを翻訳したらいいのに。
<a0:form ref="comment"></a0:form></li></ul><section><h1>SGML 型録の形式</h1><p><a0:anchor-end a0:anchor="7">[7]</a0:anchor-end> <a0:anchor>ABNF</a0:anchor> です。厳密な定義は <a0:anchor-internal a0:anchor="2">&gt;&gt;2</a0:anchor-internal> の仕様書に載っている
<a0:anchor>SGML//生成規則//表記法</a0:anchor>によるものを参照して下さい。</p><ul><li>型録 = *<a0:anchor>ps</a0:anchor> *((拡張外部識別子 / その他の情報) 1*<a0:anchor>ps</a0:anchor>)</li><li>その他の情報 = <a0:anchor>見出し語</a0:anchor> *(1*ps <a0:anchor>引数</a0:anchor>)</li><li>見出し語 = システム文字列d</li><li>引数 = システム文字列d / (<a0:anchor>lit</a0:anchor> 1*システム文字b lit) / (<a0:anchor>lita</a0:anchor> 1*システム文字ba lita)</li><li>拡張外部識別子 = (公開識別子見出し語 1*ps 公開識別子 1*ps 保管物体識別子) / (名前見出し語 1*ps 実体名指定 1*ps 保管物体識別子) / (無名見出し語 1*ps 保管物体識別子)</li><li>公開識別子見出し語 = 'PUBLIC' / 'DTDDECL'</li><li>名前見出し語 = 'ENTITY' / 'DOCTYPE' / 'LINKTYPE'</li><li>無名見出し語 = 'SGMLDECL' / 'DOCUMENT'</li><li>実体名指定 = 1*拡張名前文字a / (lit 1*拡張名前文字b lit) / (lita 1*拡張名前文字ba lita)<ul><li>;; 「実体名」には、文書型名及び連結型名を含む。</li></ul></li><li>保管物体識別子 = 1*システム文字a / (lit 1*システム文字b lit) / (lita 1*システム文字ba lita)<ul><li>;; 現在のファイル・システムで利用可能なファイルの識別子であるべき。</li><li>;; 特に、 <code class="ABNF"><dfn><a0:anchor>POSIX</a0:anchor> 可搬ファイル名文字集合</dfn> = ALPHA / DIGIT / &quot;.&quot; / &quot;-&quot; / &quot;_&quot;</code> のみから構成されるなら、ファイル名とみなさなければならない。</li><li>;; <a0:anchor>相対経路</a0:anchor>名である場合は、型録ファイルからの経路を示す。</li></ul></li><li>ps = <a0:anchor>s</a0:anchor> / <a0:anchor>注釈</a0:anchor></li><li>注釈 = <a0:anchor>com</a0:anchor> システム文字列c com</li><li>lit  = &lt;&quot;&gt; ;; 二重引用符</li><li>lita = &quot;'&quot; ;; 一重引用符</li><li>com = &quot;--&quot;</li><li>公開識別子 = &lt;ISO 8879 公開識別子&gt;</li><li>s = &lt;ISO 8879 規格参照具象構文 s&gt;</li><li>拡張名前文字a = 拡張名前文字 − (<a0:anchor>NULL</a0:anchor> / lit / lita / s)</li><li>拡張名前文字b = 拡張名前文字 − (NULL / lit)</li><li>拡張名前文字ba = 拡張名前文字 − (NULL / lita)</li><li>拡張名前文字 = &lt;任意の<a0:anchor>文字</a0:anchor>&gt;</li><li>システム文字a = システム文字 − (NULL / lit / lita / s)</li><li>システム文字b = システム文字 − (NULL / lit)</li><li>システム文字ba = システム文字 − (NULL / lita)</li><li>システム文字列c = *システム文字 − (*システム文字 com *システム文字) − (NULL)</li><li>システム文字列d = 1*システム文字a − (公開識別子見出し語 / 名前見出し語 / 無名見出し語)</li><li>システム文字= &lt;任意の<a0:anchor>文字</a0:anchor>&gt;<ul><li>;; システム文字の列は、少なくても1024文字までは扱えることが保証されている。</li></ul></li></ul><dl><dt><code class="SGML"><a0:anchor>PUBLIC</a0:anchor></code></dt><dd>指定した<a0:anchor>公開識別子</a0:anchor>で識別される実体の<a0:anchor>実体文</a0:anchor>を、指定した保管物体識別子で識別される物体とする。</dd><dt><code class="SGML"><a0:anchor>ENTITY</a0:anchor></code></dt><dd>名前が実体名指定と一致する実体の実体文を、指定した保管物体識別子で識別される物体とする。</dd><dt><code class="SGML"><a0:anchor>DOCTYPE</a0:anchor></code></dt><dd><a0:anchor>文書型名</a0:anchor>が実体名指定と一致する<a0:anchor>文書実体</a0:anchor>の<a0:anchor>文書型定義</a0:anchor>の<a0:anchor>外部部分集合</a0:anchor>となる実体文を、指定した保管物体識別子で識別される物体とする。</dd><dt><code class="SGML"><a0:anchor>LINKTYPE</a0:anchor></code></dt><dd><a0:anchor>連結型名</a0:anchor>が実体名指定と一致する<a0:anchor>連結型宣言</a0:anchor>で指定される実体の実体文を、指定した保管物体識別子で識別される物体とする。</dd><dt><code class="SGML"><a0:anchor>SGMLDECL</a0:anchor></code></dt><dd>指定した保管物体識別子で識別される物体を<a0:anchor>SGML宣言</a0:anchor>の入った実体として使用する。</dd><dt><code class="SGML"><a0:anchor>DTDDECL</a0:anchor></code></dt><dd>公開識別子が文書型宣言のものと一致する文書実体について、指定した保管物体識別子で識別される物体を SGML 宣言の入った実体として使用する。</dd><dt><code class="SGML"><a0:anchor>DOCUMENT</a0:anchor></code></dt><dd>指定した保管物体識別子で識別される物体を構文解析を開始する実体として使用する。 (この見出し語を使った指定が複数あることは、禁止はしないが認めもしない。)</dd></dl><p><a0:anchor-end a0:anchor="8">[8]</a0:anchor-end> SGML 宣言は、<ol><li>文書に明示されているもの</li><li><code class="SGML">DTDDECL</code> で指定されたもの</li><li><code class="SGML">SGMLDECL</code> で指定されたもの</li></ol></p><p>という優先順を持ちます。</p><p>もちろん、文書型宣言は<a0:anchor>具象構文</a0:anchor>が事前にわかっていないと読めないのですが、
大体の SGML 文書はその辺りは規格参照具象構文と同じでしょうから、
ほとんど問題ないでしょう。</p><a0:form ref="comment"></a0:form></section><section><h1>XML 型録</h1><p><a0:anchor-end a0:anchor="13">[13]</a0:anchor-end></p><blockquote><p><dfn>型録 catalog</dfn> は、「対応付け」情報を含む論理構造です。
1つの型録は物理的に1つ以上の<dfn><a0:anchor>型録項目ファイル</a0:anchor>を含みます。
型録項目ファイルは<a0:anchor>型録項目</a0:anchor>の集合を含む文書です。
<a0:anchor-external a0:resParameter="http://www.oasis-open.org/committees/entity/spec.html#s.terminology" a0:resScheme="URI">http://www.oasis-open.org/committees/entity/spec.html#s.terminology</a0:anchor-external></dfn></p></blockquote><p><a0:anchor-end a0:anchor="9">[9]</a0:anchor-end> <a0:anchor>OASIS</a0:anchor> は、 TR 9401 (SGML Catalog)
を <a0:anchor>XML</a0:anchor> 化した仕様として
<em>XML Catalogs</em> <a0:anchor-external a0:resParameter="http://www.oasis-open.org/committees/entity/spec.html" a0:resScheme="URI">http://www.oasis-open.org/committees/entity/spec.html</a0:anchor-external>
を定義しました。 TR 9401 の SGML もどきとは異なり、
こちらは完全に XML 風の文書として記述できます。
<a0:weak>基本的には XML で意味がある機能だけですが、それ以外の TR 9401 の機能の写像も定義しています。</a0:weak></p><p><a0:anchor-end a0:anchor="15">[15]</a0:anchor-end> <a0:anchor-external a0:resParameter="http://www.oasis-open.org/committees/entity/spec.html#s.res.fail" a0:resScheme="URI">http://www.oasis-open.org/committees/entity/spec.html#s.res.fail</a0:anchor-external>
によれば、<a0:anchor>資源</a0:anchor>が XML 型録であるためには、
次の条件をすべて満たす必要があります。<ul><li><a0:anchor>名前空間整形式</a0:anchor>であること。</li><li><a0:anchor>根要素型</a0:anchor>が
<code class="XML"><var>{<code class="URI">urn:oasis:names:tc:entity:xmlns:xml:catalog</code>}</var>:<a0:anchor>catalog</a0:anchor></code>
であること。</li></ul></p><p>応用は、これ以外の形式の型録を扱うことができても別に構いません。</p><ul><li><a0:anchor-end a0:anchor="10">[10]</a0:anchor-end> <em>Catalog support</em> <a0:anchor-external a0:resParameter="http://xmlsoft.org/catalog.html" a0:resScheme="URI">http://xmlsoft.org/catalog.html</a0:anchor-external></li><li><a0:anchor-end a0:anchor="12">[12]</a0:anchor-end> <a0:anchor-external a0:resParameter="CPAN:&quot;XML::Catalog&quot;" a0:resScheme="IW">IW:CPAN:&quot;XML::Catalog&quot;</a0:anchor-external> (0.02) はこれの実装だけど、 draft 仕様に対応したものらしい。大丈夫かな? 怪しいなあ。 </li><li><a0:anchor-end a0:anchor="14">[14]</a0:anchor-end> 委譲や参照があるので、循環参照の対策をしておく必要があります。また、型録項目ファイル自体が<a0:anchor>文書型宣言</a0:anchor>を持っているかもしれないことにも注意が必要です。<a0:weak>一々 OASIS のサーバーに取りに行くのは無駄ですから、最初だけ hard‐coded な型録を使うか、型録で参照されている仕様と同じ識別子を持つ<a0:anchor>実体</a0:anchor>は無視することになるでしょう。きっと。</a0:weak>
<a0:form ref="comment"></a0:form></li></ul></section><section><h1>メモ</h1><ul><li><a0:anchor-end a0:anchor="11">[11]</a0:anchor-end> <em>XML Namespace Catalog Format</em> <a0:anchor-external a0:resParameter="http://www.openhealth.org/XMLCatalog/" a0:resScheme="URI">http://www.openhealth.org/XMLCatalog/</a0:anchor-external>: XML <a0:anchor>名前空間名</a0:anchor>から <a0:anchor>schema</a0:anchor> とかを取り出すための型録らしい。なぜか <a0:anchor>XHTMLBasic</a0:anchor> を土台に、 <a0:anchor>XLink</a0:anchor> を使って腐った <a0:anchor>RDF/XML</a0:anchor> 風に記述する。この仕様は、 schema に限らず一般化した <a0:anchor>RDDL</a0:anchor> に発展的消滅したみたい。<a0:weak>その仕様の意図よりも、 XLink の駄目さ加減と RDF がリンクであることがひしひしと伝わってくる(謎)のがなんとも。</a0:weak></li></ul></section></body></html>