るりまサーチ (Ruby 2.3.0)

最速Rubyリファレンスマニュアル検索!
1件ヒット [1-1件を表示] (0.023秒)
トップページ > クエリ:String[x] > バージョン:2.3.0[x] > クエリ:path=[x] > ライブラリ:rexml/document[x]

別のキーワード

  1. string []=
  2. string slice
  3. string []
  4. string slice!
  5. string gsub

クラス

検索結果

REXML::Element#text(path = nil) -> String | nil (313.0)

先頭のテキスト子ノードの文字列を返します。

...トノードがない場合には nil を返します。

@param path XPath文字列
@see REXML::Element#get_text

//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new "<p>some text <b>this is bold!</b> more text</p>"
# doc.root (<p> ... </p>) は2つのテキストノード("some te...