るりまサーチ

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

別のキーワード

  1. net/imap param
  2. win32ole win32ole_param
  3. bodytypetext param
  4. win32ole_param new
  5. win32ole_param retval?

ライブラリ

キーワード

検索結果

REXML::Element#get_text(path = nil) -> REXML::Text | nil (326.0)

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

...ください。

path
を渡した場合は、その XPath 文字列で指定される
テキストノードの文字列を返します。

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

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

//emlist[][ruby]{
require 'rexml/documen...
...t'
doc = REXML::Document.new "<p>some text <b>this is bold!</b> more text</p>"
# doc.root (<p> ... </p>) は2つのテキストノード("some text " と " more text"
# を持っているが、前者を返す
doc.root.get_text.value # => "some text "
//}...

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

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

...ださい。

path
を渡した場合は、その XPath 文字列で指定される
テキストノードの文字列を返します。

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

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

//emlist[][ruby]{
require 'rexml/docume...
...nt'
doc = REXML::Document.new "<p>some text <b>this is bold!</b> more text</p>"
# doc.root (<p> ... </p>) は2つのテキストノード("some text " と " more text"
# を持っているが、前者を返す
doc.root.text # => "some text "
//}...