るりまサーチ

最速Rubyリファレンスマニュアル検索!
12件ヒット [1-12件を表示] (0.034秒)
トップページ > クエリ:http[x] > クラス:REXML::Element[x]

別のキーワード

  1. net/http get
  2. http get
  3. http start
  4. net/http start
  5. net/http post

ライブラリ

検索結果

REXML::Element#attribute(name, namespace = nil) -> REXML::Attribute | nil (19.0)

name で指定される属性を返します。

...ML::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
a.attribute("att") # => att='&lt;'
a.attribute("att", "http://example.org/bar") # => bar:att='2'
a.a...