るりまサーチ

最速Rubyリファレンスマニュアル検索!
601件ヒット [1-100件を表示] (0.017秒)
トップページ > クエリ:age[x] > ライブラリ:ビルトイン[x]

別のキーワード

  1. etc age
  2. etc age=
  3. passwd age
  4. passwd age=
  5. cookie max_age

クラス

モジュール

キーワード

検索結果

<< 1 2 3 ... > >>

Enumerator::Lazy#eager -> Enumerator (6102.0)

自身を遅延評価しない Enumerator に変換して返します。

...延評価されるので終了する
p lazy_enum.class # => Enumerator::Lazy
p lazy_enum.select { |n| n.even? }.first(5)
# => [2, 4, 6, 8, 10]

# select が遅延評価されないので終了しない
enum = lazy_enum.eager
p enum.class # => Enumerator
p enum.select { |n| n.even? }.first(5)
//}...

Exception#full_message(highlight: true, order: :bottom) -> String (6102.0)

例外の整形された文字列を返します。

...=> e
p e.full_message # => "\e[1mTraceback \e[m(most recent call last):\ntest.rb:2:in `<main>': \e[1mtest (\e[4;1mRuntimeError\e[m\e[1m)\n\e[m"
$stderr = $stdout
p e.full_message # => "test.rb:2:in `<main>': test (RuntimeError)\n"
$stderr = STDERR
p e.full_message # => "\e[1mTraceba...

Exception#message -> String (6102.0)

エラーメッセージをあらわす文字列を返します。

...エラーメッセージをあらわす文字列を返します。

//emlist[例][ruby]{
begin
1 + nil
rescue => e
p e.message #=> "nil can't be coerced into Fixnum"
end
//}...

GC#garbage_collect(full_mark: true, immediate_sweep: true) -> nil (6102.0)

ガーベージコレクトを開始します。

...ガーベージコレクトを開始します。

GC.start や ObjectSpace.#garbage_collect と同じ働きをします。
GC.disable により GC が禁止されている場合は何もしません。

nil を返します。

@param full_mark マイナー GC を動作させる場合は false を...
...将来のバージョンとの互換性も保証されません。また、Ruby の実装がサポー
トしていない場合はキーワード引数を指定しても無視される可能性があります。

//emlist[例][ruby]{
include GC
GC.count # => 3
garbage_collect
GC.count # => 4
//}...
...ガーベージコレクトを開始します。

GC.start や ObjectSpace.#garbage_collect と同じ働きをします。
GC.disable により GC が禁止されている場合でもガベージコレクトを開始します。

nil を返します。

@param full_mark マイナー GC を動作さ...

ObjectSpace.#garbage_collect(full_mark: true, immediate_sweep: true) -> nil (6102.0)

どこからも参照されなくなったオブジェクトを回収します。 GC.start と同じです。

どこからも参照されなくなったオブジェクトを回収します。
GC.start と同じです。

@param full_mark マイナー GC を動作させる場合は false を、そうでない場
合は true を指定します。

@param immediate_sweep sweep を遅らせる(Lazy Sweep を行う)場合は false
を、そうでない場合は true を指定します。

注意: これらのキーワード引数は Ruby の実装やバージョンによって異なりま
す。将来のバージョンとの互換性も保証されませ...

絞り込み条件を変える

Exception#to_s -> String (3002.0)

エラーメッセージをあらわす文字列を返します。

...エラーメッセージをあらわす文字列を返します。

//emlist[例][ruby]{
begin
1 + nil
rescue => e
p e.message #=> "nil can't be coerced into Fixnum"
end
//}...

Errno::EXXX.new(error_message) -> Errno::EXXX (102.0)

Errno::EXXX オブジェクトを生成して返します。

...no::EXXX オブジェクトを生成して返します。

@param error_message エラーメッセージを表す文字列

p Errno::ENOENT.new
# => #<Errno::ENOENT: No such file or directory>
p Errno::ENOENT.new('message')
# => #<Errno::ENOENT: No such file or directory - message>...

Exception#exception(error_message) -> Exception (102.0)

引数を指定しない場合は self を返します。引数を指定した場合 自身のコピー を生成し Exception#message 属性を error_message にして返します。

...た場合 自身のコピー
を生成し Exception#message 属性を error_message にして返します。

Kernel.#raise は、実質的に、例外オブジェクトの exception
メソッドの呼び出しです。

@param error_message エラーメッセージを表す文字列を指定しま...

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

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

...aram 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"
//}...

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

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

...aram 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"
//}...

絞り込み条件を変える

<< 1 2 3 ... > >>