るりまサーチ

最速Rubyリファレンスマニュアル検索!
12件ヒット [1-12件を表示] (0.205秒)
トップページ > クエリ:instruction[x] > クエリ:rexml/parsers/ultralightparser[x]

別のキーワード

  1. rexml/document new
  2. rexml/document write
  3. rexml/document to_s
  4. rexml/document node_type
  5. rexml/document clone

検索結果

rexml/parsers/ultralightparser (38018.0)

パース結果を配列で作られた木構造により返すパーサ。

...ode[4..-1] で得られる。
: [:text, 正規化文字列]
テキストノード
: [:processing_instruction, ターゲット文字列, 内容文字列 | nil]
XML処理命令(Processing Instruction, PI)
: [:comment ,コメント文字列]
コメント
: [:start_doctype, 親ノード, ルート...
...。[...]の部分は親
ノードを指しているので、pp の表示では省略されています。

//emlist[][ruby]{
require 'rexml/parsers/ultralightparser'
require 'pp'
parser = REXML::Parsers::UltraLightParser.new(<<XML)
<?xml version="1.0" encoding="UTF-8" ?>
<root>
<a n="1">xyz</a>...