Click or drag to resize
Json.NET

JsonSchemaGeneratorGenerate Method (Type, Boolean)

 
Generate a JsonSchema from the specified type.

Namespace:  Newtonsoft.Json.Schema
Assembly:  Newtonsoft.Json (in Newtonsoft.Json.dll) Version: 12.0.1+509643a8952ce731e0207710c429ad6e67dc43db
Syntax
C#
public JsonSchema Generate(
	Type type,
	bool rootSchemaNullable
)

Parameters

type
Type: SystemType
The type to generate a JsonSchema from.
rootSchemaNullable
Type: SystemBoolean
Specify whether the generated root JsonSchema will be nullable.

Return Value

Type: JsonSchema
A JsonSchema generated from the specified type.
See Also