るりまサーチ

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

別のキーワード

  1. prettyprint nest
  2. etc sc_expr_nest_max
  3. nest prettyprint
  4. sc_expr_nest_max etc

ライブラリ

クラス

モジュール

キーワード

検索結果

<< 1 2 3 ... > >>

PrettyPrint#nest(indent) {...} -> () (18101.0)

自身の現在のインデントを indent だけ増加させてから、ブロックを実行し、元に戻します。

自身の現在のインデントを indent だけ増加させてから、ブロックを実行し、元に戻します。

@param indent インデントの増加分を整数で指定します。

JSON::State#max_nesting -> Integer (6100.0)

生成される JSON 形式の文字列のネストの深さの最大値を返します。

...ax_nesting: 2)
json_state.max_nesting # => 2
JSON.generate([[]], json_state)
JSON.generate([[[]]], json_state) # => JSON::NestingError
//}

//emlist[例 ネストの深さチェックを行わない][ruby]{
require "json"

json_state = JSON::State.new(max_nesting: 0)
json_state.max_nestin...

JSON::State#max_nesting=(depth) (6100.0)

生成される JSON 形式の文字列のネストの深さの最大値をセットします。

...せん。

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

json_state = JSON::State.new(max_nesting: 2)
json_state.max_nesting # => 2
JSON.generate([[]], json_state)
json_state.max_nesting = 3
json_state.max_nesting # => 3
JSON.generate([[[[]]]], json_state) # => JSON::NestingError
//}...

Module.nesting -> [Class, Module] (6100.0)

このメソッドを呼び出した時点でのクラス/モジュールのネスト情 報を配列に入れて返します。

...このメソッドを呼び出した時点でのクラス/モジュールのネスト情
報を配列に入れて返します。

//emlist[例][ruby]{
module Foo
module Bar
module Baz
p Module.nesting # => [Foo::Bar::Baz, Foo::Bar, Foo]
end
end
end
//}...

static VALUE rb_mod_nesting(void) (6100.0)

絞り込み条件を変える

JSON::NestingError (6000.0)

パースしようとしているデータ構造のネストが深すぎる場合に発生する例外です。

パースしようとしているデータ構造のネストが深すぎる場合に発生する例外です。

Etc::SC_EXPR_NEST_MAX -> Integer (3101.0)

Etc.#sysconf の引数に指定します。

Etc.#sysconf の引数に指定します。

詳細は sysconf(3) を参照してください。

クラス/メソッドの定義 (22.0)

クラス/メソッドの定義 * クラス/メソッドの定義: * class * singleton_class * module * method * operator * nest_method * eval_method * singleton_method * class_method * limit * 定義に関する操作: * alias * undef * defined

...ス/メソッドの定義
* クラス/メソッドの定義:
* class
* singleton_class
* module
* method
* operator
* nest_method
* eval_method
* singleton_method
* class_method
* limit
* 定義に関する操作:
* alias
* undef
* defined...
...ではありませんが、まれにOS(シェル)のコ
マンド実行の挙動に不具合がある場合などに利用できます。

====[a:nest_method] メソッド定義のネスト

ネスト可能です。ネストされた定義式は、
それを定義したメソッドが実行された...

pp (12.0)

オブジェクトなどを見やすく出力するためのライブラリです。

...ちらが読みやすいでしょうか?

p による pretty-print されてない出力:
#<PP:0x81a0d10 @stack=[], @genspace=#<Proc:0x81a0cc0>, @nest=[0], @newline="\n",
@buf=#<PrettyPrint::Group:0x81a0c98 @group=0, @tail=0, @buf=[#<PrettyPrint::Gro
up:0x81a0ba8 @group=1, @tail=0, @buf=[#<Pr...
...roup=1,
@singleline_width=6,
@tail=0>],
@group=0,
@singleline_width=6,
@tail=0>,
@genspace=#<Proc:0x40d0656>,
@nest=[0],
@newline="\n",
@sharing_detection=false,
@stack=[]>


=== 出力のカスタマイズ

あるクラスの pp の出力をカスタマ...
<< 1 2 3 ... > >>