55件ヒット
[1-55件を表示]
(0.044秒)
種類
- ライブラリ (33)
- インスタンスメソッド (11)
- クラス (11)
ライブラリ
-
rexml
/ document (22)
クラス
-
REXML
:: Entity (11)
キーワード
- external (11)
-
rexml
/ parsers / pullparser (11) -
rexml
/ parsers / sax2parser (11) -
rexml
/ parsers / streamparser (11)
検索結果
先頭5件
-
REXML
:: Entity (18118.0) -
XML における実体(エンティティ、entity)の宣言(declaration)を表わすクラス。
...、entity)の宣言(declaration)を表わすクラス。
DTD(REXML::DocType)内の実体宣言に対応するものです。
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<EOS)
<!DOCTYPE document [
<!ENTITY f "foo bar baz">
<!ENTITY x SYSTEM "x.txt">
<!ENTITY y SYSTEM "y.p......PNG>
<!ENTITY % z "zzz">
<!ENTITY zz "%z;%z;&f;">
]>
EOS
entities = doc.doctype.entities
# f は 内部実体名なので、external や ref は nil である
p entities["f"].name # => "f"
p entities["f"].value # => "foo bar baz"
p entities["f"].external # => nil
p entities["f"].ref # => nil
# x......実体名なので value が nil で、
# external や ref が文字列を返してくる。
# しかし解析対象実体(parsed entity)なので ndata は nil を返す
p entities["x"].name # => "x"
p entities["x"].value # => nil
p entities["x"].external # => "SYSTEM"
p entities["x"].ref # => "x.t... -
REXML
:: Entity # external -> String | nil (3145.0) -
実体が外部実体(external entity)宣言である場合は "SYSTEM" もしくは "PUBLIC" という文字列を返します。
...実体が外部実体(external entity)宣言である場合は
"SYSTEM" もしくは "PUBLIC" という文字列を返します。
内部実体(internal entity)宣言である場合には nil を返します。... -
rexml
/ parsers / pullparser (132.0) -
プル方式の XML パーサ。
...ターゲット文字列, 内容文字列 | nil)
XML処理命令(Processing Instruction, PI)
: comment (コメント文字列)
コメント
: start_doctype (ルート要素名, "SYSTEM" | "PUBLIC" | nil, システム識別子 | nil, 公開識別子 | nil)
DTD 開始。判定は REXML::Parsers:......フォルト値文字列(なければnil) } という Hash
: elementdecl (宣言文字列)
DTDの要素宣言
: entitydecl
DTDの実体宣言
: notationdecl (記法名文字列, "PUBLIC" | "SYSTEM" | nil, 公開識別子文字列 | nil, URI文字列 | nil)
DTDの記法宣言
: cdata (テキス......ト文字列)
cdata セクション
: xmldecl (バージョン文字列, エンコーディング文字列 | nil, standalone ("yes" | "no" | nil))
XML宣言
: externalentity (エンティティ文字列)
doctype内のパラメータ実体参照。
//emlist[][ruby]{
require 'rexml/parsers/pull... -
rexml
/ parsers / sax2parser (72.0) -
SAX2 と同等の API を持つストリーム式の XML パーサ。
...e="text/css" href="style.css"?>
<!DOCTYPE root SYSTEM "foo" [
<!ELEMENT root (a+)>
<!ELEMENT a>
<!ENTITY bar "barbarbarbar">
<!ATTLIST a att CDATA #REQUIRED xyz CDATA "foobar">
<!NOTATION foobar SYSTEM "http://example.org/foobar.dtd">
<!ENTITY % HTMLsymbol PUBLIC
"-//W3C//ENTITIES.......0", "UTF-8", nil]
# >> [:progress, 39]
# >> [:characters, "\n"]
# >> [:progress, 91]
# >> [:processing_instruction, "xml-stylesheet", " type=\"text/css\" href=\"style.css\""]
# >> [:progress, 91]
# >> [:characters, "\n"]
# >> [:progress, 144]
# >> [:doctype, "root", "SYSTEM", "foo", nil]
# >> [:pro......# >> [:progress, 159]
# >> [:entitydecl, "bar", "barbarbarbar"]
# >> [:progress, 190]
# >> [:attlistdecl, "a", {"att"=>nil, "xyz"=>"foobar"}, " \n <!ATTLIST a att CDATA #REQUIRED xyz CDATA \"foobar\">"]
# >> [:progress, 245]
# >> [:notationdecl, "foobar", "SYSTEM", nil, "http://example.org/foobar.... -
rexml
/ parsers / streamparser (60.0) -
ストリーム式の XML パーサ。
...e="text/css" href="style.css"?>
<!DOCTYPE root SYSTEM "foo" [
<!ELEMENT root (a+)>
<!ELEMENT a>
<!ENTITY bar "barbarbarbar">
<!ATTLIST a att CDATA #REQUIRED xyz CDATA "foobar">
<!NOTATION foobar SYSTEM "http://example.org/foobar.dtd">
<!ENTITY % HTMLsymbol PUBLIC
"-//W3C//ENTITIES......ecl, "1.0", "UTF-8", nil]
# >> [:text, "\n"]
# >> [:instruction, "xml-stylesheet", " type=\"text/css\" href=\"style.css\""]
# >> [:text, "\n"]
# >> [:doctype, "root", "SYSTEM", "foo", nil]
# >> [:elementdecl, "<!ELEMENT root (a+)"]
# >> [:elementdecl, "<!ELEMENT a"]
# >> [:entitydecl, ["bar", "barba......rbarbar"]]
# >> [:attlistdecl, "a", {"att"=>nil, "xyz"=>"foobar"}, " \n <!ATTLIST a att CDATA #REQUIRED xyz CDATA \"foobar\">"]
# >> [:notationdecl, ["foobar", "SYSTEM", nil, "http://example.org/foobar.dtd"]]
# >> [:entitydecl, ["HTMLsymbol", "PUBLIC", "-//W3C//ENTITIES Symbols for XHTML//EN", "xht...