るりまサーチ

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

別のキーワード

  1. _builtin new
  2. _builtin inspect
  3. _builtin []
  4. _builtin to_s
  5. _builtin each

クラス

モジュール

オブジェクト

キーワード

検索結果

<< 1 2 3 ... > >>

GC.verify_compaction_references(toward: nil, double_heap: nil) -> Hash (20203.0)

コンパクションの参照の一貫性を検証します。

...系依存 (CRuby 特有) です。
コンパクション中に移動されたオブジェクトは T_MOVED オブジェクトに置き換えられます。
コンパクション後には T_MOVED を参照するオブジェクトは存在するべきではありません。

この関数は全ての...
...MOVED への参照をもつオブジェクトがあれば、マークスタックにプッシュされて、
SEGV が起きるでしょう。

@param toward nil か :empty を指定します。
@param double_heap ヒープサイズを2倍にするかどうかを真偽値で指定します。

@retur...
...n GC.compact の返り値と同じです。

@see GC.compact...

Encoding::Converter.asciicompat_encoding(encoding) -> Encoding | nil (17303.0)

同じ文字集合を持つ ASCII 互換エンコーディングを返します。

...集合を持つ ASCII 互換エンコーディングを返します。

@param string エンコーディング名
@param encoding エンコーディングオブジェクト
@return ASCII 互換エンコーディングのオブジェクトか nil

引数とエンコーディングと同じ文字集...
...ングでない場合は nil を返します。

//emlist[][ruby]{
E
ncoding::Converter.asciicompat_encoding("ISO-2022-JP") #=> #<Encoding:stateless-ISO-2022-JP>
E
ncoding::Converter.asciicompat_encoding("UTF-16BE") #=> #<Encoding:UTF-8>
E
ncoding::Converter.asciicompat_encoding("UTF-8") #=> nil
//}...

Exception.exception(error_message = nil) -> Exception (17239.0)

例外オブジェクトを生成して返します。

...@param error_message エラーメッセージを表す文字列を指定します。このメッセージは
属性 Exception#message の値になり、デフォルトの例外ハンドラで表示されます。

//emlist[例][ruby]{
e
= Exception.new("some message")
p e...
...# => #<Exception: some message>
p e.message # => "some message"
//}

//emlist[例][ruby]{
e
= Exception.exception("some message")
p e # => #<Exception: some message>
p e.message # => "some message"
//}...

Thread.report_on_exception -> bool (17215.0)

真の時は、いずれかのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

...を $stderr に報告します。

デフォルトは false です。

Thread.new { 1.times { raise } }

は $stderr に以下のように出力します:

#<Thread:...> terminated with exception (report_on_exception is true):
Traceback (most recent call last):
2: from -e:1:in `block...
...in <main>'
1: from -e:1:in `times'

これによってスレッドのエラーを早期に捕捉できるようになります。
いくつかのケースでは、この出力を望まないかもしれません。
出力を抑制するには複数の方法があります:

* 例外が...
...で rescue して、
その例外でスレッドが終了しないようにするのがより良い方法です。
* Thread#join や Thread#value でそのスレッドの終了を待つことが保証できるなら、
スレッド開始時に Thread.current.report_on_exception = false でレ...
...容を $stderr に報告します。

デフォルトは true です。

Thread.new { 1.times { raise } }

は $stderr に以下のように出力します:

#<Thread:...> terminated with exception (report_on_exception is true):
Traceback (most recent call last):
2: from -e:1:in `blo...
...ck in <main>'
1: from -e:1:in `times'

これによってスレッドのエラーを早期に捕捉できるようになります。
いくつかのケースでは、この出力を望まないかもしれません。
出力を抑制するには複数の方法があります:

* 例外が...

Thread.report_on_exception=(newstate) (17215.0)

真の時は、いずれかのスレッドが例外によって終了した時に、その内容を $stderr に報告します。

...を $stderr に報告します。

デフォルトは false です。

Thread.new { 1.times { raise } }

は $stderr に以下のように出力します:

#<Thread:...> terminated with exception (report_on_exception is true):
Traceback (most recent call last):
2: from -e:1:in `block...
...in <main>'
1: from -e:1:in `times'

これによってスレッドのエラーを早期に捕捉できるようになります。
いくつかのケースでは、この出力を望まないかもしれません。
出力を抑制するには複数の方法があります:

* 例外が...
...で rescue して、
その例外でスレッドが終了しないようにするのがより良い方法です。
* Thread#join や Thread#value でそのスレッドの終了を待つことが保証できるなら、
スレッド開始時に Thread.current.report_on_exception = false でレ...
...容を $stderr に報告します。

デフォルトは true です。

Thread.new { 1.times { raise } }

は $stderr に以下のように出力します:

#<Thread:...> terminated with exception (report_on_exception is true):
Traceback (most recent call last):
2: from -e:1:in `blo...
...ck in <main>'
1: from -e:1:in `times'

これによってスレッドのエラーを早期に捕捉できるようになります。
いくつかのケースでは、この出力を望まないかもしれません。
出力を抑制するには複数の方法があります:

* 例外が...

絞り込み条件を変える

Encoding::Converter.asciicompat_encoding(string) -> Encoding | nil (17203.0)

同じ文字集合を持つ ASCII 互換エンコーディングを返します。

...集合を持つ ASCII 互換エンコーディングを返します。

@param string エンコーディング名
@param encoding エンコーディングオブジェクト
@return ASCII 互換エンコーディングのオブジェクトか nil

引数とエンコーディングと同じ文字集...
...ングでない場合は nil を返します。

//emlist[][ruby]{
E
ncoding::Converter.asciicompat_encoding("ISO-2022-JP") #=> #<Encoding:stateless-ISO-2022-JP>
E
ncoding::Converter.asciicompat_encoding("UTF-16BE") #=> #<Encoding:UTF-8>
E
ncoding::Converter.asciicompat_encoding("UTF-8") #=> nil
//}...

File.readable_real?(path) -> bool (17203.0)

FileTest.#readable_real? と同じです。

...FileTest.#readable_real? と同じです。

@param path パスを表す文字列か IO オブジェクトを指定します。...

Exception.new(error_message = nil) -> Exception (17139.0)

例外オブジェクトを生成して返します。

...@param error_message エラーメッセージを表す文字列を指定します。このメッセージは
属性 Exception#message の値になり、デフォルトの例外ハンドラで表示されます。

//emlist[例][ruby]{
e
= Exception.new("some message")
p e...
...# => #<Exception: some message>
p e.message # => "some message"
//}

//emlist[例][ruby]{
e
= Exception.exception("some message")
p e # => #<Exception: some message>
p e.message # => "some message"
//}...

ENV.length -> Integer (17103.0)

環境変数の数を返します。

環境変数の数を返します。

ENV.size -> Integer (17103.0)

環境変数の数を返します。

環境変数の数を返します。

絞り込み条件を変える

Dir.children(path, encoding: enc) -> [String] (14303.0)

ディレクトリ path に含まれるファイルエントリ名のうち、 "." と ".." をのぞいた配列を返します。

...す。

@param encoding ディレクトリのエンコーディングを文字列か
E
ncoding オブジェクトで指定します。省略した場合は
ファイルシステムのエンコーディングと同じになります。

@raise Errno::EXXX 失敗した...
...場合に発生します。

//emlist[例][ruby]{
Dir.children('.') #=> ["bar", "foo"]
//}

@see Dir#children
@see Dir.each_child
@see Dir.entries...
<< 1 2 3 ... > >>