1512件ヒット
[1501-1512件を表示]
(0.018秒)
ライブラリ
- ビルトイン (928)
- fiber (8)
- fiddle (24)
-
json
/ add / bigdecimal (12) -
json
/ add / complex (12) -
json
/ add / date (12) -
json
/ add / date _ time (12) -
json
/ add / exception (12) -
json
/ add / range (12) -
json
/ add / rational (12) -
json
/ add / regexp (12) -
json
/ add / struct (12) -
json
/ add / time (12) - optparse (96)
- pathname (72)
- rake (48)
- ripper (24)
- set (18)
- un (12)
- win32ole (36)
クラス
- BasicObject (48)
- BigDecimal (12)
- Class (24)
- Complex (12)
- Data (21)
- Date (12)
- DateTime (12)
- Enumerator (122)
-
Enumerator
:: Lazy (72) - Exception (12)
- Fiber (12)
-
Fiddle
:: Closure :: BlockCaller (12) -
Fiddle
:: Function (12) - Hash (6)
- Method (66)
- Module (36)
- Object (120)
- OptionParser (96)
- Pathname (72)
- Proc (6)
-
Rake
:: FileList (12) - Range (12)
- Rational (12)
- Regexp (12)
- Ripper (24)
-
RubyVM
:: InstructionSequence (12) - String (12)
- Struct (60)
- Time (12)
- UnboundMethod (12)
- WIN32OLE (24)
-
WIN32OLE
_ EVENT (12)
モジュール
- Enumerable (115)
- FileUtils (12)
- Kernel (192)
-
Rake
:: TaskManager (24) -
RubyVM
:: AbstractSyntaxTree (30)
キーワード
- % (12)
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (12) - === (8)
- BasicObject (12)
-
NEWS for Ruby 2
. 7 . 0 (6) - Ruby プログラムの実行 (12)
- [] (42)
-
_ _ send _ _ (24) - allocate (12)
-
bind
_ call (12) - binread (12)
- call (36)
- caller (36)
-
class
_ exec (12) -
create
_ rule (12) - curry (22)
- define (6)
-
define
_ task (12) - each (48)
-
each
_ line (24) -
each
_ with _ index (24) -
each
_ with _ object (24) - entries (12)
-
enum
_ for (48) - exec (48)
- fnmatch (12)
- force (12)
- handler= (12)
- initialize (12)
-
instance
_ exec (12) - join (12)
-
method
_ missing (12) - mkmf (12)
-
module
_ exec (12) - new (80)
-
next
_ values (12) - of (10)
- order (48)
- parse (34)
-
parse
_ file (10) - permute (24)
-
public
_ send (24) -
rb
_ define _ method (12) -
rb
_ scan _ args (12) -
respond
_ to _ missing? (12) -
rexml
/ parsers / sax2parser (12) -
rexml
/ parsers / streamparser (12) -
ruby 1
. 9 feature (12) -
ruby2
_ keywords (18) -
ruby2
_ keywords _ hash? (6) -
rubygems
/ commands / pristine _ command (12) -
rubygems
/ commands / rdoc _ command (12) - send (24)
- setproperty (24)
- spawn (48)
- system (48)
-
to
_ a (24) -
to
_ enum (48) -
to
_ h (19) -
to
_ json (120) -
to
_ set (24) - transfer (12)
- warn (12)
- warning (12)
- with (3)
-
with
_ index (36) -
with
_ object (24) - クラス/メソッドの定義 (12)
検索結果
先頭2件
-
Enumerator
# with _ object(obj) -> Enumerator (7.0) -
繰り返しの各要素に obj を添えてブロックを繰り返し、obj を返り値として返します。
...渡されなかった場合は、上で説明した繰り返しを実行し、
最後に obj を返す Enumerator を返します。
//emlist[例][ruby]{
# 0,1,2 と呼びだす enumeratorを作る
to_three = Enumerator.new do |y|
3.times do |x|
y << x
end
end
to_three_with_string = to_thr... -
Enumerator
:: Lazy # with _ index(offset = 0) -> Enumerator :: Lazy (7.0) -
生成時のパラメータに従って、要素にインデックスを添えて繰り返します。 インデックスは offset から始まります。
...クスは offset から始まります。
ブロックを指定した場合の戻り値は生成時に指定したレシーバ自身です。
//emlist[][ruby]{
("a"..).lazy.with_index(1) { |it, index| puts "#{index}:#{it}" }.take(3).force
# => 1:a
# 2:b
# 3:c
//}
@see Enumerator#with_index...