instance method
JSON::Ext::Generator::State#max_nesting=
max_nesting=(depth)
ext/json/generator/generator.c
View on GitHub ↗
static VALUE cState_max_nesting_set(VALUE self, VALUE depth)
{
rb_check_frozen(self);
GET_STATE(self);
state->max_nesting = long_config(depth);
return Qnil;
}
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.