るりまサーチ (Ruby 2.3.0)

最速Rubyリファレンスマニュアル検索!
9件ヒット [1-9件を表示] (0.050秒)

別のキーワード

  1. json state
  2. random state
  3. _builtin state
  4. state []
  5. state []=

クラス

キーワード

検索結果

Random#state -> Integer (54313.0)

C言語レベルで定義されている構造体MTの状態を参照します。詳しくはrandom.c を参照してください。

C言語レベルで定義されている構造体MTの状態を参照します。詳しくはrandom.c を参照してください。

Enumerator::Lazy#chunk(initial_state) {|elt, state| ... } -> Enumerator::Lazy (616.0)

Enumerable#chunk と同じですが、配列ではなく Enumerator::Lazy を返します。

Enumerable#chunk と同じですが、配列ではなく Enumerator::Lazy を返します。

//emlist[例][ruby]{
1.step.lazy.chunk{ |n| n % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x007f8bf18118f0>:each>>

1.step.lazy.chunk{ |n| n % 3 == 0 }.take(5).force
# => [[false, [1, 2]], [true, [3]], [false, [4, 5...

Enumerator::Lazy#slice_before(initial_state) {|elt, state| bool } -> Enumerator::Lazy (616.0)

Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。

Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。

//emlist[例][ruby]{
1.step.lazy.slice_before { |e| e.even? }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x00007f9f31844ce8>:each>>

1.step.lazy.slice_before { |e| e % 3 == 0 }.take(5).force
# => [[1, 2], [3, 4, 5], [6...

IO#sync=(newstate) (310.0)

自身を同期モードに設定すると、出力関数の呼出毎にバッファがフラッシュされます。

自身を同期モードに設定すると、出力関数の呼出毎にバッファがフラッシュされます。

@param newstate 自身を同期モードに設定するかを boolean で指定します。

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

@see IO#sync

Thread#abort_on_exception=(newstate) (310.0)

真の場合、そのスレッドが例外によって終了した時に、インタプリタ 全体を中断させます。false の場合、あるスレッドで起こった例 外は、Thread#join などで検出されない限りそのスレッ ドだけをなにも警告を出さずに終了させます。

真の場合、そのスレッドが例外によって終了した時に、インタプリタ
全体を中断させます。false の場合、あるスレッドで起こった例
外は、Thread#join などで検出されない限りそのスレッ
ドだけをなにも警告を出さずに終了させます。

デフォルトは偽です。c:Thread#exceptionを参照してください。

@param newstate 自身を実行中に例外発生した場合、インタプリタ全体を終了させるかどうかを true か false で指定します。

//emlist[例][ruby]{
thread = Thread.new { sleep 1 }
thread.abort_o...

絞り込み条件を変える

Encoding::Converter#insert_output(string) -> nil (28.0)

変換器内のバッファに文字列を挿入します。 バッファに保持された文字列は、次の変換時の変換結果と一緒に返されます。

変換器内のバッファに文字列を挿入します。
バッファに保持された文字列は、次の変換時の変換結果と一緒に返されます。

変換先がステートフルなエンコーディングであった場合、
挿入された文字列は状態に基づいて変換され、状態を更新します。

このメソッドは変換に際してエラーが発生した際にのみ利用されるべきです。

@param string 挿入する文字列

//emlist[][ruby]{
ec = Encoding::Converter.new("utf-8", "iso-8859-1")
src = "HIRAGANA LETTER A is \u{3042}."
dst = ""
p ec....

Enumerator::Lazy#chunk {|elt| ... } -> Enumerator::Lazy (16.0)

Enumerable#chunk と同じですが、配列ではなく Enumerator::Lazy を返します。

Enumerable#chunk と同じですが、配列ではなく Enumerator::Lazy を返します。

//emlist[例][ruby]{
1.step.lazy.chunk{ |n| n % 3 == 0 }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x007f8bf18118f0>:each>>

1.step.lazy.chunk{ |n| n % 3 == 0 }.take(5).force
# => [[false, [1, 2]], [true, [3]], [false, [4, 5...

Enumerator::Lazy#slice_before {|elt| bool } -> Enumerator::Lazy (16.0)

Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。

Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。

//emlist[例][ruby]{
1.step.lazy.slice_before { |e| e.even? }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x00007f9f31844ce8>:each>>

1.step.lazy.slice_before { |e| e % 3 == 0 }.take(5).force
# => [[1, 2], [3, 4, 5], [6...

Enumerator::Lazy#slice_before(pattern) -> Enumerator::Lazy (16.0)

Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。

Enumerable#slice_before と同じですが、配列ではなく Enumerator::Lazy を返します。

//emlist[例][ruby]{
1.step.lazy.slice_before { |e| e.even? }
# => #<Enumerator::Lazy: #<Enumerator: #<Enumerator::Generator:0x00007f9f31844ce8>:each>>

1.step.lazy.slice_before { |e| e % 3 == 0 }.take(5).force
# => [[1, 2], [3, 4, 5], [6...