るりまサーチ

最速Rubyリファレンスマニュアル検索!
120件ヒット [1-100件を表示] (0.155秒)

別のキーワード

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

ライブラリ

モジュール

キーワード

検索結果

<< 1 2 > >>

REXML::Entity#ref -> String | nil (26101.0)

外部実体(external entity)宣言の URI を返します。

外部実体(external entity)宣言の URI を返します。

内部実体宣言の場合は nil を返します。

REXML::Attribute#prefix -> String (14106.0)

属性の名前空間を返します。

...require 'rexml/document'
e = REXML::Element.new( "elns:myelement" )
e.add_attribute( "nsa:a", "aval" )
e.add_attribute( "b", "bval" )
p e.attributes.get_attribute( "a" ).prefix # -> "nsa"
p e.attributes.get_attribute( "b" ).prefix # -> "elns"
a = REXML::Attribute.new( "x", "y" )
p a.prefix...

REXML::Attributes#prefixes -> [String] (14106.0)

self の中で宣言されている prefix の集合を 文字列の配列で返します。

...self の中で宣言されている prefix の集合を
文字列の配列で返します。

self が属する要素より上位の要素で定義されているものは含みません。

//emlist[][ruby]{
require 'rexml/document'

doc = REXML::Document.new(<<EOS)
<root xmlns:foo="http://example....
...org/foo"
xmlns:bar="http://example.org/bar">
<a foo:att='1' bar:att='2' att='&lt;'/>
</root>
EOS
a = doc.get_elements("/root/a").first

p doc.root.attributes.prefixes # => ["foo", "bar"]
p a.attributes.prefixes # => []
//}...

REXML::Element#prefixes -> [String] (14106.0)

self の文脈で定義されている prefix を文字列の配列を返します。

...る prefix を文字列の配列を返します。

対象の要素とその外側の要素で定義されている prefix を返します。

//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new("<a xmlns:x='1' xmlns:y='2'><b/><c xmlns:z='3'/></a>")
doc.elements['//b'].prefixes # =>...

REXML::Namespace#prefix -> String (14100.0)

prefix (前置修飾子) を返します。

...prefix (前置修飾子) を返します。

@see REXML::Namespace#prefix=...

絞り込み条件を変える

REXML::Namespace#prefix=(value) (14100.0)

prefix (前置修飾子) を設定します。

...prefix (前置修飾子) を設定します。

@param value prefix文字列
@see REXML::Namespace#prefix...

REXML::Element#add_namespace(prefix, uri) -> self (8106.0)

名前空間を要素に追加します。

...

引数が2個の場合は prefix と uri を指定します。
引数が1個の場合はデフォルトの namespace の uri を指定します。

既に同じ prefix が存在する場合はそれが上書きされます。

@param prefix 名前空間の prefix
@param uri 名前空間の uri...

REXML::Element#namespace(prefix=nil) -> String (8106.0)

self の文脈で prefix が指している名前空間の URI を返します。

...で prefix が指している名前空間の URI を返します。

prefix を省略すると、デフォルトの名前空間の URI を返します。

prefix で指示される名前空間の宣言が存在しない場合は nil を返します。

//emlist[][ruby]{
require 'rexml/document'
doc...

REXML::Entity.new(name, value, parent=nil, reference=false) -> REXML::Entity (8100.0)

新たな Entity オブジェクトを生成して返します。

...name, value で実体の名前とその値を定義します。
parent はその entity オブジェクトが属するノードを渡します。
ref
erence でその実体宣言がパラメータ実体(parameter entity)かどうかを指定します。

このコンストラクタでは単純な...
...に利用するため通常は利用しません。

@param name 実体参照の名前
@param value 参照の値
@param parent 親ノード
@param reference パラメータ実体であるかどうかの真偽値
@param array 初期化のための配列

=== 例
「&gt;」「>」 の対応は以下...
<< 1 2 > >>