8件ヒット
[1-8件を表示]
(0.092秒)
ライブラリ
- json (8)
キーワード
- depth (1)
- depth= (1)
- indent (1)
- indent= (1)
-
max
_ nesting= (1) -
quirks
_ mode (1) -
quirks
_ mode= (1) -
quirks
_ mode? (1)
検索結果
先頭5件
-
JSON
:: State # depth=(depth) (18607.0) -
This sets the maximum level of data structure nesting in the generated JSON to the integer depth, max_nesting = 0 if no maximum should be checked.
This sets the maximum level of data structure nesting in the generated
JSON to the integer depth, max_nesting = 0 if no maximum should be
checked. -
JSON
:: State # depth -> Integer (18307.0) -
This integer returns the current depth of data structure nesting.
This integer returns the current depth of data structure nesting. -
JSON
:: State # indent -> String (18307.0) -
インデントに使用する文字列を返します。
...インデントに使用する文字列を返します。
//emlist[例][ruby]{
require "json"
json_state = JSON::State.new(indent: "\t")
json_state.indent # => "\t"
JSON.generate({key1: "value1", key2: "value2"}, json_state)
# => "{\t\"key1\":\"value1\",\t\"key2\":\"value2\"}"
//}... -
JSON
:: State # indent=(string) (18307.0) -
インデントに使用する文字列をセットします。
...トします。
@param string インデントに使用する文字列を指定します。
//emlist[例][ruby]{
require "json"
json_state = JSON::State.new(indent: "\t")
json_state.indent # => "\t"
JSON.generate({key1: "value1", key2: "value2"}, json_state)
# => "{\t\"key1\":\"value1\",\t\"key2\"... -
JSON
:: State # quirks _ mode -> bool (18307.0) -
Returns true, if quirks mode is enabled. Otherwise returns false.
Returns true, if quirks mode is enabled. Otherwise returns false. -
JSON
:: State # quirks _ mode=(enable) (18307.0) -
If set to true, enables the quirks_mode mode.
If set to true, enables the quirks_mode mode. -
JSON
:: State # quirks _ mode? -> bool (18307.0) -
Returns true, if quirks mode is enabled. Otherwise returns false.
Returns true, if quirks mode is enabled. Otherwise returns false. -
JSON
:: State # max _ nesting=(depth) (307.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...