语言

JsonWriterOptions.MaxDepth 属性

定义

获取或设置写入 JSON 时允许的最大深度,默认值(即 0)表示最大深度为 1000。

public:
 property int MaxDepth { int get(); void set(int value); };
public int MaxDepth { get; set; }
member this.MaxDepth : int with get, set
Public Property MaxDepth As Integer

属性值

例外

最大深度设置为负值。

注解

写入过去此深度将引发一个 JsonException。

适用于