るりまサーチ

最速Rubyリファレンスマニュアル検索!
22件ヒット [1-22件を表示] (0.032秒)
トップページ > クエリ:Integer[x] > ライブラリ:ビルトイン[x] > クエリ:NONBLOCK[x] > 種類:インスタンスメソッド[x]

別のキーワード

  1. openssl integer
  2. asn1 integer
  3. _builtin integer
  4. integer upto
  5. integer downto

クラス

キーワード

検索結果

IO#write_nonblock(string, exception: true) -> Integer | :wait_writable (6211.0)

IO をノンブロッキングモードに設定し、string を write(2) システムコールで書き出します。

...CK である場合は、
その例外オブジェクトに IO::WaitWritable が Object#extend
されます。よって IO::WaitWritable を write_nonblock のリトライが必要
かの判定に用いることができます。

@param string 自身に書き込みたい文字列を指定します...

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

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

...に発生します。

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

IO.write("testfile", "abcde")
# ファイル状態フラグを読み出す
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
//}...