るりまサーチ

最速Rubyリファレンスマニュアル検索!
24件ヒット [1-24件を表示] (0.012秒)
トップページ > クエリ:lock[x] > モジュール:Kernel[x]

別のキーワード

  1. mutex_m lock
  2. net/http lock
  3. mutex_m mu_lock
  4. mutex_m try_lock
  5. mutex_m mu_try_lock

ライブラリ

キーワード

検索結果

Kernel.#block_given? -> bool (6101.0)

メソッドにブロックが与えられていれば真を返します。

...ートするとはいえないので)推奨されていないの
で block_given? を使ってください。

//emlist[例][ruby]{
def check
if block_given?
puts "Block is given."
else
puts "Block isn't given."
end
end
check{} #=> Block is given.
check #=> Block isn't given.
//}...

Kernel.#iterator? -> bool (3001.0)

メソッドにブロックが与えられていれば真を返します。

...ートするとはいえないので)推奨されていないの
で block_given? を使ってください。

//emlist[例][ruby]{
def check
if block_given?
puts "Block is given."
else
puts "Block isn't given."
end
end
check{} #=> Block is given.
check #=> Block isn't given.
//}...