411件ヒット
[1-100件を表示]
(0.091秒)
ライブラリ
- ビルトイン (92)
-
cgi
/ core (11) -
irb
/ context (33) -
net
/ http (33) - open-uri (44)
- pp (33)
-
rexml
/ document (121) -
rexml
/ streamlistener (11) - uri (22)
-
webrick
/ httprequest (11)
クラス
- CGI (11)
-
Enumerator
:: Yielder (5) -
IRB
:: Context (33) - Method (12)
- Object (22)
- PP (11)
- Proc (12)
-
REXML
:: CData (22) -
REXML
:: Element (55) -
REXML
:: Instruction (22) -
REXML
:: Text (22) - String (63)
-
URI
:: MailTo (22) -
WEBrick
:: HTTPRequest (11)
モジュール
-
Net
:: HTTPHeader (33) -
OpenURI
:: Meta (44) -
REXML
:: StreamListener (11)
キーワード
- +@ (9)
- -@ (9)
- << (12)
- >> (12)
- charset (22)
-
comma
_ breakable (11) - content (11)
-
content
_ type (22) - dedup (2)
-
each
_ element _ with _ text (11) - encode (33)
- entitydecl (11)
-
get
_ text (11) -
has
_ elements? (11) - header (11)
-
main
_ type (11) -
next
_ element (11) -
pretty
_ print (11) -
pretty
_ print _ cycle (11) -
prompt
_ mode (11) - query (11)
-
sub
_ type (11) - target (11)
-
to
_ mailtext (11) -
to
_ proc (5) -
to
_ rfc822text (11) -
to
_ s (22) -
unicode
_ normalize! (10) -
use
_ readline (11) -
use
_ readline? (11) - value (22)
検索結果
先頭5件
-
REXML
:: Element # text(path = nil) -> String | nil (18256.0) -
先頭のテキスト子ノードの文字列を返します。
...EXML::Text#value も参照してください。
path を渡した場合は、その XPath 文字列で指定される
テキストノードの文字列を返します。
テキストノードがない場合には nil を返します。
@param path XPath文字列
@see REXML::Element#get_text
//em......list[][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 text " と " more text"
# を持っているが、前者を返す
doc.root.text # => "some text "
//}... -
REXML
:: Element # get _ text(path = nil) -> REXML :: Text | nil (6357.0) -
先頭のテキスト子ノードを返します。
...REXML::Text#value も参照してください。
path を渡した場合は、その XPath 文字列で指定される
テキストノードの文字列を返します。
テキストノードがない場合には nil を返します。
@param path XPath文字列
@see REXML::Element#text
//emli......st[][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 text " と " more text"
# を持っているが、前者を返す
doc.root.get_text.value # => "some text "
//}... -
REXML
:: Element # each _ element _ with _ text(text = nil , max = 0 , name = nil) {|element| . . . } -> () (6351.0) -
テキストを子ノードとして 持つすべての子要素を引数としてブロックを呼び出します。
...テキストを子ノードとして
持つすべての子要素を引数としてブロックを呼び出します。
text を指定すると、テキストの内容が text であるもののみを対象とします。
maxを指定すると、対象となる子要素の先頭 max 個のみが対......)。
@param text テキストの中身(文字列)
@param max ブロック呼出の対象とする子要素の最大個数
@param name xpath文字列
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new '<a><b>b</b><c>b</c><d>d</d><e/></a>'
doc.root.each_element_with_text {|e|p e}
#......>> <b> ... </>
# >> <c> ... </>
# >> <d> ... </>
doc.root.each_element_with_text('b'){|e|p e}
# >> <b> ... </>
# >> <c> ... </>
doc.root.each_element_with_text('b', 1){|e|p e}
# >> <b> ... </>
doc.root.each_element_with_text(nil, 0, 'd'){|e|p e}
# >> <d> ... </>
//}... -
URI
:: MailTo # to _ mailtext -> String (6274.0) -
URI オブジェクトからメールテキスト文字列を生成します。
...:
require 'uri'
p mailto = URI.parse("mailto:ruby-list@ruby-lang.org?subject=subscribe&cc=myaddr")
print mailto.to_mailtext
=> #<URI::MailTo:0x20104a0e URL:mailto:ruby-list@ruby-lang.org?subject=subscribe&cc=myaddr>
To: ruby-list@ruby-lang.org
Subject: subscribe
Cc: myaddr... -
URI
:: MailTo # to _ rfc822text -> String (6274.0) -
URI オブジェクトからメールテキスト文字列を生成します。
...:
require 'uri'
p mailto = URI.parse("mailto:ruby-list@ruby-lang.org?subject=subscribe&cc=myaddr")
print mailto.to_mailtext
=> #<URI::MailTo:0x20104a0e URL:mailto:ruby-list@ruby-lang.org?subject=subscribe&cc=myaddr>
To: ruby-list@ruby-lang.org
Subject: subscribe
Cc: myaddr... -
String
# -@ -> String | self (6227.0) -
self が freeze されている文字列の場合、self を返します。 freeze されていない場合は元の文字列の freeze された (できる限り既存の) 複製を返します。
...[例][ruby]{
# frozen_string_literal: false
original_text = "text"
frozen_text = -original_text
frozen_text.frozen? # => true
original_text == frozen_text # => true
original_text.equal?(frozen_text) # => false
original_text = "text".freeze
frozen_text = -original_text
froz......en_text.frozen? # => true
original_text == frozen_text # => true
original_text.equal?(frozen_text) # => true
//}
@see String#+@... -
String
# dedup -> String | self (3227.0) -
self が freeze されている文字列の場合、self を返します。 freeze されていない場合は元の文字列の freeze された (できる限り既存の) 複製を返します。
...[例][ruby]{
# frozen_string_literal: false
original_text = "text"
frozen_text = -original_text
frozen_text.frozen? # => true
original_text == frozen_text # => true
original_text.equal?(frozen_text) # => false
original_text = "text".freeze
frozen_text = -original_text
froz......en_text.frozen? # => true
original_text == frozen_text # => true
original_text.equal?(frozen_text) # => true
//}
@see String#+@... -
REXML
:: Text # to _ s -> String (3125.0) -
テキストの内容を正規化(すべての実体をエスケープ)された状態で返します。
...返り値は XML のテキストとして妥当です。
結果は REXML::Text.new で指定した entity_filter を反映しています。
@see REXML::Text#value
//emlist[][ruby]{
require 'rexml/document'
t = REXML::Text.new("< & foobar", false, nil, false)
t.to_s # => "< & foobar"
t.val... -
REXML
:: Text # value -> String (3125.0) -
テキストの内容を非正規化(すべての実体をアンエスケープ)された状態で返します。
...。
このメソッドの返り値では raw モードや entity_filter は無視されます。
@see REXML::Text#raw, REXML::Text#to_s
//emlist[][ruby]{
require 'rexml/document'
t = REXML::Text.new("< & foobar", false, nil, false)
t.to_s # => "< & foobar"
t.value # => "< & foobar"
//}... -
IRB
:: Context # use _ readline -> bool | nil (3119.0) -
readline を使うかどうかを返します。
...を使わない
: nil
inf-ruby-mode 以外で readline ライブラリを利用しようとする (デフォルト)
動作を変更するためには .irbrc ファイル中で IRB.conf[:USE_READLINE] の設
定や irb 起動時に --readline オプション、--noreadline オプションの指... -
IRB
:: Context # use _ readline? -> bool | nil (3119.0) -
readline を使うかどうかを返します。
...を使わない
: nil
inf-ruby-mode 以外で readline ライブラリを利用しようとする (デフォルト)
動作を変更するためには .irbrc ファイル中で IRB.conf[:USE_READLINE] の設
定や irb 起動時に --readline オプション、--noreadline オプションの指...