るりまサーチ

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

別のキーワード

  1. fcntl o_excl
  2. fcntl o_rdwr
  3. fcntl o_trunc
  4. fcntl o_creat
  5. fcntl o_rdonly

ライブラリ

クラス

モジュール

キーワード

検索結果

Fcntl::O_NONBLOCK -> Integer (15201.0)

ファイルを non-blocking モードで開きます。

...ファイルを non-blocking モードで開きます。...

IO#fcntl(cmd, arg = 0) -> Integer (3106.0)

IOに対してシステムコール fcntl を実行します。 機能の詳細は fcntl(2) を参照してください。 fcntl(2) が返した整数を返します。

...
I
Oに対してシステムコール fcntl を実行します。
機能の詳細は fcntl(2) を参照してください。
fcntl(2) が返した整数を返します。

@param cmd IO に対するコマンドを、添付ライブラリ fcntl が提供している定数で指定します。

@param...
...arg が nil か false の場合には 0を、true の場合には 1 を渡します。

@raise Errno::EXXX fcntl の実行に失敗した場合に発生します。

@raise IOError 既に close されている場合に発生します。

//emlist[例][ruby]{
require "fcntl"

I
O.write("testfile", "ab...
...cde")
# ファイル状態フラグを読み出す
File.open("testfile") do |f|
f.fcntl(Fcntl::F_GETFL, 0) # => 0
f.fcntl(Fcntl::F_SETFL, Fcntl::O_NONBLOCK) # => 0
f.fcntl(Fcntl::F_GETFL, 0) # => 4
end
//}...

Fcntl::O_NDELAY -> Integer (101.0)

ファイルを non-blocking モードで開きます。

...ファイルを non-blocking モードで開きます。...