Rational Developer for System z
Enterprise PL/I for z/OS, Version 3.9, プログラミング・ガイド

SAX イベント構造体

start_of_document
version_information
encoding_declaration
standalone_declaration
document_type_declaration
end_of_document
start_of_element
attribute_name
attribute_characters
attribute_predefined_reference
attribute_character_reference
end_of_element
start_of_CDATA_section
end_of_CDATA_section
content_characters
content_predefined_reference
content_character_reference
processing_instruction
comment
unknown_attribute_reference
unknown_content_reference
start_of_prefix_mapping
end_of_prefix_mapping
exception
イベント関数に渡されるパラメーター

イベント構造体は、24 個の LIMITED ENTRY 変数で構成される構造体です。 これらの変数は、さまざまな「イベント」に対してパーサーが起動する機能を 指しています。

これらすべての ENTRY は、OPTLINK リンケージを使用する必要があります。

次に示す各イベントの説明は、図 89 の XML 文書 の例に対応しています。 この説明にある「XML テキスト」という用語は、イベントに渡される ポインターと長さに基づくストリングを意味しています。

図 89. サンプル XML 文書
   xmlDocument =
      '<?xml version="1.0" standalone="yes"?>'
   || '<!--This document is just an example-->'
   || '<sandwich>'
   || '<bread type="baker&quot;s best"/>'
   || '<?spread please use real mayonnaise ?>'
   || '<meat>Ham &amp; turkey</meat>'
   || '<filling>Cheese, lettuce, tomato, etc.</filling>'
   || '<![CDATA[We should add a <relish> element in future!]]>'
   || '</sandwich>'
   || 'junk';

この構造体での出現順に、パーサーは次のイベントを認識することができます。


Terms of use | Feedback

This information center is powered by Eclipse technology. (http://www.eclipse.org)