るりまサーチ

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

別のキーワード

  1. string oct
  2. _builtin oct
  3. oct string
  4. oct _builtin
  5. oct

ライブラリ

クラス

検索結果

REXML::DocType#attribute_of(element, attribute) -> String | nil (21227.0)

DTD 内の属性リスト宣言で、 element という名前の要素の attribute という 名前の属性のデフォルト値を返します。

...l/document'

doctype = REXML::Document.new(<<EOS).doctype
<!DOCTYPE books [
<!ELEMENT book (comment)>
<!ELEMENT comment (#PCDATA)>
<!ATTLIST book
author CDATA #REQUIRED
title CDATA #REQUIRED
publisher CDATA "foobar publisher">
]>
EOS

p doctype.attribute_of("book", "pub...
...lisher") # => "foobar publisher"
p doctype.attribute_of("bar", "foo") # => nil
p doctype.attribute_of("book", "baz") # => nil
p doctype.attribute_of("book", "title") # => nil
//}...