るりまサーチ

最速Rubyリファレンスマニュアル検索!
11件ヒット [1-11件を表示] (0.161秒)
トップページ > クエリ:i[x] > クエリ:-[x] > クエリ:bool[x] > クエリ:test[x] > クラス:IO[x]

別のキーワード

  1. _builtin -
  2. open-uri open
  3. irb/input-method new
  4. irb/input-method gets
  5. matrix -

ライブラリ

検索結果

IO#closed? -> bool (3208.0)

self が完全に(読み込み用と書き込み用の両方が)クローズされている場合に true を返します。 そうでない場合は false を返します。

...ist[例][ruby]{
IO
.write("testfile", "test")
f = File.new("testfile")
f.close # => nil
f.closed? # => true
f = IO.popen("/bin/sh","r+")
f.close_write # => nil
f.closed? # => false
f.close_read # => nil
f.closed? # => true
//}

@see IO#close, IO#close_read, IO#close_wri...