482件ヒット
[101-200件を表示]
(0.103秒)
ライブラリ
- ビルトイン (231)
- erb (8)
-
minitest
/ spec (3) - mkmf (72)
- pathname (36)
- prime (72)
-
rexml
/ document (36) -
rubygems
/ dependency _ installer (12) -
rubygems
/ source _ info _ cache (12)
クラス
- Data (3)
- ERB (8)
- Enumerator (24)
-
Gem
:: DependencyInstaller (12) -
Gem
:: SourceInfoCache (12) - Hash (34)
- Module (13)
- Object (2)
- Pathname (36)
-
Prime
:: PseudoPrimeGenerator (72) - Proc (6)
-
REXML
:: Child (12) -
REXML
:: Element (24) - Refinement (4)
- String (24)
- Symbol (6)
- Thread (18)
- Time (12)
モジュール
- Enumerable (88)
- Kernel (72)
キーワード
- < (12)
-
check
_ signedness (24) - children (12)
- chunk (12)
- compact (4)
-
convertible
_ int (24) -
delete
_ prefix (8) -
delete
_ prefix! (8) -
each
_ child (24) -
each
_ element _ with _ attribute (12) -
each
_ element _ with _ text (12) -
each
_ with _ index (48) -
find
_ gems _ with _ sources (12) -
import
_ methods (4) -
infect
_ with _ assertions (1) -
keep
_ if (24) -
max
_ by (48) -
must
_ be _ within _ delta (1) -
must
_ be _ within _ epsilon (1) -
replace
_ with (12) -
report
_ on _ exception (9) -
report
_ on _ exception= (9) - result (8)
-
ruby2
_ keywords (6) -
search
_ with _ source (12) - select! (10)
-
start
_ with? (14) - strftime (12)
-
with
_ index (48) -
with
_ object (24) -
with
_ werror (24)
検索結果
先頭5件
-
Kernel
# with _ werror(opt , opts = nil) {|opt , opts| . . . } -> object (6503.0) -
@todo 内部用?
...@todo 内部用?
???
@param opt ????
@param opts ????
@return ブロックを評価した結果を返します。... -
Kernel
# with _ werror(opt , opts = nil) {|opt| . . . } -> object (6403.0) -
@todo 内部用?
...@todo 内部用?
???
@param opt ????
@param opts ????
@return ブロックを評価した結果を返します。... -
Symbol
# start _ with?(*prefixes) -> bool (6244.0) -
self の先頭が prefixes のいずれかであるとき true を返します。
...の先頭が prefixes のいずれかであるとき true を返します。
(self.to_s.start_with?と同じです。)
@param prefixes パターンを表す文字列または正規表現 (のリスト)
@see Symbol#end_with?
@see String#start_with?
//emlist[][ruby]{
:hello.start_with?("hell")......#=> true
:hello.start_with?(/H/i) #=> true
# returns true if one of the prefixes matches.
:hello.start_with?("heaven", "hell") #=> true
:hello.start_with?("heaven", "paradise") #=> false
//}... -
String
# start _ with?(*prefixes) -> bool (6238.0) -
self の先頭が prefixes のいずれかであるとき true を返します。
...頭が prefixes のいずれかであるとき true を返します。
@param prefixes パターンを表す文字列または正規表現 (のリスト)
//emlist[例][ruby]{
"string".start_with?("str") # => true
"string".start_with?("ing") # => false
"string".start_with?("ing",......"str") # => true
"string".start_with?(/\w/) # => true
"string".start_with?(/\d/) # => false
//}
@see String#end_with?
@see String#delete_prefix, String#delete_prefix!... -
String
# delete _ prefix!(prefix) -> self | nil (6207.0) -
self の先頭から破壊的に prefix を削除します。
... prefix を削除します。
@param prefix 先頭から削除する文字列を指定します。
@return 削除した場合は self、変化しなかった場合は nil
//emlist[][ruby]{
"hello".delete_prefix!("hel") # => "lo"
"hello".delete_prefix!("llo") # => nil
//}
@see String#delete_prefi......x
@see String#delete_suffix!
@see String#start_with?... -
String
# delete _ prefix(prefix) -> String (6207.0) -
文字列の先頭から prefix を削除した文字列のコピーを返します。
...から prefix を削除した文字列のコピーを返します。
@param prefix 先頭から削除する文字列を指定します。
@return 文字列の先頭から prefix を削除した文字列のコピー
//emlist[][ruby]{
"hello".delete_prefix("hel") # => "lo"
"hello".delete_prefix("ll......o") # => "hello"
//}
@see String#delete_prefix!
@see String#delete_suffix
@see String#start_with?... -
Gem
:: SourceInfoCache # search _ with _ source(pattern , only _ platform = false , all = false) -> Array (6202.0) -
与えられた条件を満たす Gem::Specification と URL のリストを返します。
...与えられた条件を満たす Gem::Specification と URL のリストを返します。
@param pattern 検索したい Gem を表す Gem::Dependency のインスタンスを指定します。
@param only_platform 真を指定するとプラットフォームが一致するもののみを返......します。デフォルトは偽です。
@param all 真を指定するとキャッシュを更新してから検索を実行します。
@return 第一要素を Gem::Specification、第二要素を取得元の URL とする配列を要素とする配列を返します。... -
Module
# infect _ with _ assertions(positive _ prefix , negative _ prefix , skip _ regexp , map = {}) -> () (6202.0) -
BDD 風にテストを書くために使用するメソッド群を定義します。
...す。
@param positive_prefix assert の代わりのプレフィックスを指定します。
@param negative_prefix refute の代わりのプレフィックスを指定します。
@param skip_regexp この正規表現にマッチしたメソッドは定義しません。
@param map メソッ... -
REXML
:: Element # each _ element _ with _ attribute(key , value = nil , max = 0 , name = nil) {|element| . . . } -> () (6150.0) -
特定の属性を持つすべての子要素を引数としてブロックを呼び出します。
...と、それは xpath 文字列と見なされ、
それにマッチするもののみが対象となります。
max に 0 を指定すると、max の指定は無視されます(0個ではありません)。
@param key 属性名(文字列)
@param value 属性値(文字列)
@param max ブロッ......大個数
@param name xpath文字列
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new("<a><b id='1'/><c id='2'/><d id='1'/><e/></a>")
doc.root.each_element_with_attribute('id'){|e| p e }
# >> <b id='1'/>
# >> <c id='2'/>
# >> <d id='1'/>
doc.root.each_element_with_attribute('id'......, '1'){|e| p e }
# >> <b id='1'/>
# >> <d id='1'/>
doc.root.each_element_with_attribute('id', '1', 1){|e| p e }
# >> <b id='1'/>
doc.root.each_element_with_attribute('id', '1', 0, 'd'){|e| p e }
# >> <d id='1'/>
//}... -
REXML
:: Element # each _ element _ with _ text(text = nil , max = 0 , name = nil) {|element| . . . } -> () (6150.0) -
テキストを子ノードとして 持つすべての子要素を引数としてブロックを呼び出します。
...指定すると、それは xpath 文字列と見なされ、
それにマッチするもののみが対象となります。
max に 0 を指定すると、max の指定は無視されます(0個ではありません)。
@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> ... </>
//}... -
Enumerable
# each _ with _ index(*args) -> Enumerator (6145.0) -
要素とそのインデックスをブロックに渡して繰り返します。
...繰り返すような
Enumerator を返します。
Enumerator#with_index は offset 引数を受け取りますが、
each_with_index は受け取りません (引数はイテレータメソッドにそのまま渡されます)。
@param args イテレータメソッド (each など) にそのま......each_with_index do |n, idx|
p [n, idx]
end
# => [5, 0]
# [10, 1]
# [15, 2]
//}
//emlist[引数ありの例][ruby]{
require 'stringio'
StringIO.new("foo|bar|baz").each_with_index("|") do |s, i|
p [s, i]
end
# => ["foo|", 0]
# ["bar|", 1]
# ["baz", 2]
//}
@see Enumerator#with_index...