public class ParseConfig extends Object implements Serializable
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_MAXIMUM_NESTING_DEPTH
默认最大嵌套深度
|
| Constructor and Description |
|---|
ParseConfig() |
| Modifier and Type | Method and Description |
|---|---|
int |
getMaxNestingDepth()
获取最大嵌套深度,用于解析时限制解析层级,当大于这个层级时抛出异常,-1表示无限制
|
boolean |
isKeepStrings()
是否保持值为String类型,如果为
false,则尝试转换为对应类型(numeric, boolean, string) |
static ParseConfig |
of()
创建ParseConfig
|
ParseConfig |
setKeepStrings(boolean keepStrings)
设置是否保持值为String类型,如果为
false,则尝试转换为对应类型(numeric, boolean, string) |
ParseConfig |
setMaxNestingDepth(int maxNestingDepth)
设置最大嵌套深度,用于解析时限制解析层级,当大于这个层级时抛出异常,-1表示无限制
|
public static final int DEFAULT_MAXIMUM_NESTING_DEPTH
public static ParseConfig of()
public boolean isKeepStrings()
false,则尝试转换为对应类型(numeric, boolean, string)public ParseConfig setKeepStrings(boolean keepStrings)
false,则尝试转换为对应类型(numeric, boolean, string)keepStrings - 是否保持值为String类型public int getMaxNestingDepth()
public ParseConfig setMaxNestingDepth(int maxNestingDepth)
maxNestingDepth - 最大嵌套深度Copyright © 2025. All rights reserved.