種類
- インスタンスメソッド (840)
- 特異メソッド (108)
- クラス (48)
- モジュール (12)
- 文書 (12)
ライブラリ
-
cgi
/ html (480) - openssl (60)
-
rdoc
/ context (12) -
rexml
/ document (300) -
rexml
/ sax2listener (12) -
rexml
/ streamlistener (12) -
rubygems
/ specification (60) - uri (48)
-
webrick
/ accesslog (12) -
webrick
/ httprequest (12)
クラス
-
Gem
:: Specification (60) -
OpenSSL
:: ASN1 :: ObjectId (12) -
OpenSSL
:: X509 :: Request (24) -
RDoc
:: Context (12) -
REXML
:: Attribute (36) -
REXML
:: Attributes (192) -
REXML
:: DocType (12) -
REXML
:: Element (36) -
URI
:: LDAP (48) -
WEBrick
:: HTTPRequest (12)
モジュール
-
CGI
:: HtmlExtension (480) -
REXML
:: SAX2Listener (12) -
REXML
:: StreamListener (12)
キーワード
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (12) - << (12)
- AccessLog (12)
- Attribute (12)
- Attributes (12)
- Config (12)
- Element (12)
- [] (12)
- []= (12)
- add (12)
-
add
_ attributes (12) -
array
_ attributes (12) - attlistdecl (12)
- attribute (12)
-
attribute
_ defaults (12) - attributes= (24)
-
attributes
_ of (12) - build (24)
- checkbox (24)
-
checkbox
_ group (24) - delete (12)
-
delete
_ all (12) - each (12)
-
each
_ attribute (12) -
file
_ field (24) - form (48)
-
get
_ attribute (12) -
get
_ attribute _ ns (12) -
has
_ attributes? (12) - hidden (24)
- html (24)
- img (24)
- length (12)
-
multipart
_ form (48) - namespace (12)
- namespaces (12)
- new (12)
-
password
_ field (24) - prefix (12)
- prefixes (12)
-
radio
_ group (24) - register (12)
-
required
_ attributes (12) - reset (24)
-
scrolling
_ list (24) - size (12)
-
start
_ element (12) - submit (24)
-
text
_ field (24) - textarea (24)
-
to
_ a (12) -
to
_ string (12)
検索結果
先頭5件
-
REXML
:: Attributes # get _ attribute _ ns(namespace , name) -> REXML :: Attribute | nil (3024.0) -
namespace と name で特定される属性を返します。
...a = doc.get_elements("/root/a").first
a.attributes.get_attribute_ns("", "att") # => att='<'
a.attributes.get_attribute_ns("http://example.org/foo", "att") # => foo:att='1'
a.attributes.get_attribute_ns("http://example.org/baz", "att") # => nil
a.attributes.get_attribute_ns("http://example.org/fo... -
REXML
:: Attributes # [](name) -> String | nil (3018.0) -
属性名nameの属性値を返します。
...属性名nameの属性値を返します。
属性値ではなく REXML::Attribute オブジェクトが必要な場合は
REXML::Attributes#get_attribute を使ってください。
nameという属性名の属性がない場合は nil を返します。
@param name 属性名(文字列)
//emlis......'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='<'/>
</root>
EOS
a = doc.get_elements("/root/a").first
p a.attributes["att"] # => "<"
p a.attributes["bar:att"] # => "2"
//}... -
REXML
:: Attributes # []=(name , value) (3018.0) -
指定した属性を更新します。
.../example.org/foo"
xmlns:bar="http://example.org/bar">
<a foo:att='1' bar:att='2' att='<'/>
</root>
EOS
a = doc.get_elements("/root/a").first
a.attributes["att"] = "9"
a.attributes["foo:attt"] = "8"
a # => <a foo:att='1' bar:att='2' att='9' foo:attt='8'/>
//}
@see REXML::Attributes#add... -
REXML
:: Attributes # get _ attribute(name) -> Attribute | nil (3018.0) -
name という名前の属性を取得します。
...e REXML::Attributes#[]
//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='<'/>
</root>
EOS
a = doc.get_elements("/root/a").first
a.attributes.get_attr......ibute("att") # => att='<'
a.attributes.get_attribute("foo:att") # => foo:att='1'
//}... -
REXML
:: Attributes # namespaces -> { String => String } (3012.0) -
self の中で宣言されている名前空間の集合を返します。
...p://example.org/foo"
xmlns:bar="http://example.org/bar">
<a foo:att='1' bar:att='2' att='<'/>
</root>
EOS
a = doc.get_elements("/root/a").first
p doc.root.attributes.namespaces
# => {"foo"=>"http://example.org/foo", "bar"=>"http://example.org/bar"}
p a.attributes.namespaces
# => {}
//}... -
REXML
:: Attributes # prefixes -> [String] (3012.0) -
self の中で宣言されている prefix の集合を 文字列の配列で返します。
...'
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='<'/>
</root>
EOS
a = doc.get_elements("/root/a").first
p doc.root.attributes.prefixes # => ["foo", "bar"]
p a.attributes.prefixes # => []
//}... -
REXML
:: Attributes # <<(attribute) -> () (3006.0) -
属性を追加/更新します。
...ブジェクト)を
指定します。既に同じ名前(REXML::Attribute#name)のオブジェクトが
存在する場合は属性が上書きされ、ない場合は追加されます。
@param attribute 追加(更新)する属性(REXML::Attribute オブジェクト)
@see REXML::Attributes#[]=... -
REXML
:: Attributes # add(attribute) -> () (3006.0) -
属性を追加/更新します。
...ブジェクト)を
指定します。既に同じ名前(REXML::Attribute#name)のオブジェクトが
存在する場合は属性が上書きされ、ない場合は追加されます。
@param attribute 追加(更新)する属性(REXML::Attribute オブジェクト)
@see REXML::Attributes#[]=... -
REXML
:: Attributes # delete _ all(name) -> [REXML :: Attribute] (3006.0) -
name という名前を持つ属性をすべて削除します。
...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='<'/>
</root>
EOS
a = doc.get_elements("/root/a").first
a.attributes.delete_all("att") # => [att='<']
a # => <a foo:att='1' bar:att='2'/>
//}...