22件ヒット
[1-22件を表示]
(0.057秒)
ライブラリ
- ビルトイン (22)
検索結果
-
Thread
# join(limit) -> self | nil (18340.0) -
スレッド self の実行が終了するまで、カレントスレッドを停止し ます。self が例外により終了していれば、その例外がカレントス レッドに対して発生します。
...ドに対して発生します。
limit を指定して、limit 秒過ぎても自身が終了しない場合、nil を返します。
@param limit タイムアウトする時間を整数か小数で指定します。単位は秒です。
@raise ThreadError join を実行することによって......レッドを join したときにも発生します。
以下は、生成したすべてのスレッドの終了を待つ例です。
threads = []
threads.push(Thread.new { n = rand(5); sleep n; n })
threads.push(Thread.new { n = rand(5); sleep n; n })
threads.push(Thread.new { n = ran......d(5); sleep n; n })
threads.each {|t| t.join}... -
Thread
# join -> self (18240.0) -
スレッド self の実行が終了するまで、カレントスレッドを停止し ます。self が例外により終了していれば、その例外がカレントス レッドに対して発生します。
...ドに対して発生します。
limit を指定して、limit 秒過ぎても自身が終了しない場合、nil を返します。
@param limit タイムアウトする時間を整数か小数で指定します。単位は秒です。
@raise ThreadError join を実行することによって......レッドを join したときにも発生します。
以下は、生成したすべてのスレッドの終了を待つ例です。
threads = []
threads.push(Thread.new { n = rand(5); sleep n; n })
threads.push(Thread.new { n = rand(5); sleep n; n })
threads.push(Thread.new { n = ran......d(5); sleep n; n })
threads.each {|t| t.join}...