るりまサーチ

最速Rubyリファレンスマニュアル検索!
11件ヒット [1-11件を表示] (0.108秒)
トップページ > クエリ:I[x] > クエリ:<[x] > クエリ:delete_all[x]

別のキーワード

  1. _builtin <
  2. bigdecimal <
  3. module <
  4. integer <
  5. complex <

ライブラリ

クラス

検索結果

REXML::Attributes#delete_all(name) -> [REXML::Attribute] (21225.0)

name という名前を持つ属性をすべて削除します。

...名前

//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

a.attributes.delete_all("att") # => [a...
...tt='&lt;']
a # => <a foo:att='1' bar:att='2'/>
//}...