500件ヒット
[1-100件を表示]
(0.131秒)
種類
- インスタンスメソッド (385)
- 文書 (49)
- ライブラリ (44)
- 特異メソッド (11)
- クラス (11)
ライブラリ
- ビルトイン (110)
- csv (33)
- matrix (22)
-
net
/ http (154) - prime (44)
-
rubygems
/ commands / dependency _ command (11) -
rubygems
/ dependency _ list (11) - strscan (22)
クラス
- Array (55)
- CSV (22)
-
CSV
:: FieldInfo (11) -
Gem
:: Commands :: DependencyCommand (11) -
Gem
:: DependencyList (11) - MatchData (22)
- Matrix (22)
-
Net
:: HTTP (77) -
Net
:: HTTPGenericRequest (22) -
Net
:: HTTPResponse (22) -
Prime
:: PseudoPrimeGenerator (44) - StringScanner (22)
モジュール
- Enumerable (22)
-
Net
:: HTTPHeader (33)
キーワード
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (11) -
NEWS for Ruby 2
. 7 . 0 (5) - String (11)
- begin (11)
-
body
_ stream (11) -
body
_ stream= (11) -
cgi
/ session (11) - convert (22)
- each (22)
-
each
_ index (22) -
each
_ with _ index (66) - fetch (44)
-
find
_ gems (11) -
from
_ source _ index (11) - get (22)
- get2 (22)
-
net
/ pop (11) - pointer= (11)
- pos= (11)
- rdoc (11)
-
rdoc
/ generator / json _ index (11) -
read
_ body (11) -
request
_ get (22) -
ruby 1
. 6 feature (11) -
ruby 1
. 8 . 4 feature (11) -
ruby 1
. 9 feature (11) -
send
_ request (11) - value (11)
-
with
_ index (22)
検索結果
先頭5件
-
CSV
:: FieldInfo # index -> Integer (24313.0) -
行内で何番目のフィールドかわかるゼロベースのインデックスを返します。
...ロベースのインデックスを返します。
//emlist[例][ruby]{
require 'csv'
csv = CSV.new("date1,date2\n2018-07-09,2018-07-10", headers: true)
csv.convert do |field,field_info|
p field_info.index
Date.parse(field)
end
p csv.first
# => 0
# => 1
# => #<CSV::Row "date1":#<Date: 2018-0... -
MatchData
# end(n) -> Integer | nil (18243.0) -
n 番目の部分文字列終端のオフセットを返します。
...nil を返します。
@param n 部分文字列を指定する数値。
@raise IndexError 範囲外の n を指定した場合に発生します。
//emlist[例][ruby]{
/(foo)(bar)(BAZ)?/ =~ "foobarbaz"
p $~.end(0) # => 6
p $~.end(1) # => 3
p $~.end(2) # => 6
p $~.end(3) # => nil
p $~.end......(4) # => `end': index 4 out of matches (IndexError)
//}
@see MatchData#begin... -
Gem
:: DependencyList . from _ source _ index(src _ index) -> Gem :: DependencyList (15508.0) -
与えられた Gem::SourceIndex のインスタンスから自身を作成します。
...与えられた Gem::SourceIndex のインスタンスから自身を作成します。
@param src_index Gem::SourceIndex を指定します。
@see Gem::SourceIndex... -
Prime
:: PseudoPrimeGenerator # each _ with _ index {|prime , index| . . . } -> self (15336.0) -
与えられたブロックに対して、素数を0起点の連番を渡して評価します。
...を返します。 ブロックを与えられなかった場合は Enumerator を返します。
//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}
@see Enumerator#with_index... -
Prime
:: PseudoPrimeGenerator # with _ index {|prime , index| . . . } -> self (15336.0) -
与えられたブロックに対して、素数を0起点の連番を渡して評価します。
...を返します。 ブロックを与えられなかった場合は Enumerator を返します。
//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}
@see Enumerator#with_index... -
Prime
:: PseudoPrimeGenerator # each _ with _ index -> Enumerator (15236.0) -
与えられたブロックに対して、素数を0起点の連番を渡して評価します。
...を返します。 ブロックを与えられなかった場合は Enumerator を返します。
//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}
@see Enumerator#with_index... -
Prime
:: PseudoPrimeGenerator # with _ index -> Enumerator (15236.0) -
与えられたブロックに対して、素数を0起点の連番を渡して評価します。
...を返します。 ブロックを与えられなかった場合は Enumerator を返します。
//emlist[例][ruby]{
require 'prime'
Prime::EratosthenesGenerator.new(10).each_with_index do |prime, index|
p [prime, index]
end
# [2, 0]
# [3, 1]
# [5, 2]
# [7, 3]
//}
@see Enumerator#with_index... -
Enumerable
# each _ with _ index(*args) {|item , index| . . . } -> self (12457.0) -
要素とそのインデックスをブロックに渡して繰り返します。
...with_index は offset 引数を受け取りますが、
each_with_index は受け取りません (引数はイテレータメソッドにそのまま渡されます)。
@param args イテレータメソッド (each など) にそのまま渡されます。
//emlist[例][ruby]{
[5, 10, 15].each_wit......h_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... -
Array
# each _ index {|index| . . . . } -> self (12421.0) -
各要素のインデックスに対してブロックを評価します。
...スに対してブロックを評価します。
以下と同じです。
//emlist[例][ruby]{
(0 ... ary.size).each do |index|
# ....
end
//}
ブロックが与えられなかった場合は、自身と each_index から生成した
Enumerator オブジェクトを返します。
@see Array#e... -
Enumerable
# each _ with _ index(*args) -> Enumerator (12257.0) -
要素とそのインデックスをブロックに渡して繰り返します。
...with_index は offset 引数を受け取りますが、
each_with_index は受け取りません (引数はイテレータメソッドにそのまま渡されます)。
@param args イテレータメソッド (each など) にそのまま渡されます。
//emlist[例][ruby]{
[5, 10, 15].each_wit......h_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...