JsonSchemaExporter.GetJsonSchemaAsNode Metodo
Definizione
Importante
Alcune informazioni sono relative alla release non definitiva del prodotto, che potrebbe subire modifiche significative prima della release definitiva. Microsoft non riconosce alcuna garanzia, espressa o implicita, in merito alle informazioni qui fornite.
Overload
| Nome | Descrizione |
|---|---|
| GetJsonSchemaAsNode(JsonTypeInfo, JsonSchemaExporterOptions) |
Genera uno schema JSON corrispondente ai metadati del contratto specificati. |
| GetJsonSchemaAsNode(JsonSerializerOptions, Type, JsonSchemaExporterOptions) |
Genera uno schema JSON corrispondente ai metadati del contratto del tipo specificato. |
GetJsonSchemaAsNode(JsonTypeInfo, JsonSchemaExporterOptions)
- Origine:
- JsonSchemaExporter.cs
- Origine:
- JsonSchemaExporter.cs
- Origine:
- JsonSchemaExporter.cs
- Origine:
- JsonSchemaExporter.cs
Genera uno schema JSON corrispondente ai metadati del contratto specificati.
public static System.Text.Json.Nodes.JsonNode GetJsonSchemaAsNode(this System.Text.Json.Serialization.Metadata.JsonTypeInfo typeInfo, System.Text.Json.Schema.JsonSchemaExporterOptions? exporterOptions = default);
static member GetJsonSchemaAsNode : System.Text.Json.Serialization.Metadata.JsonTypeInfo * System.Text.Json.Schema.JsonSchemaExporterOptions -> System.Text.Json.Nodes.JsonNode
<Extension()>
Public Function GetJsonSchemaAsNode (typeInfo As JsonTypeInfo, Optional exporterOptions As JsonSchemaExporterOptions = Nothing) As JsonNode
Parametri
- typeInfo
- JsonTypeInfo
Metadati del contratto per i quali generare lo schema.
- exporterOptions
- JsonSchemaExporterOptions
Oggetto exporterOptions che controlla la generazione dello schema.
Valori restituiti
JsonNode Nuova istanza che definisce lo schema JSON per typeInfo.
Eccezioni
Uno dei parametri specificati è null.
Il typeInfo parametro contiene unsupported exporterOptions.
Si applica a
GetJsonSchemaAsNode(JsonSerializerOptions, Type, JsonSchemaExporterOptions)
- Origine:
- JsonSchemaExporter.cs
- Origine:
- JsonSchemaExporter.cs
- Origine:
- JsonSchemaExporter.cs
- Origine:
- JsonSchemaExporter.cs
Genera uno schema JSON corrispondente ai metadati del contratto del tipo specificato.
public static System.Text.Json.Nodes.JsonNode GetJsonSchemaAsNode(this System.Text.Json.JsonSerializerOptions options, Type type, System.Text.Json.Schema.JsonSchemaExporterOptions? exporterOptions = default);
static member GetJsonSchemaAsNode : System.Text.Json.JsonSerializerOptions * Type * System.Text.Json.Schema.JsonSchemaExporterOptions -> System.Text.Json.Nodes.JsonNode
<Extension()>
Public Function GetJsonSchemaAsNode (options As JsonSerializerOptions, type As Type, Optional exporterOptions As JsonSchemaExporterOptions = Nothing) As JsonNode
Parametri
- options
- JsonSerializerOptions
Istanza delle opzioni da cui risolvere i metadati del contratto.
- type
- Type
Tipo radice per il quale generare lo schema JSON.
- exporterOptions
- JsonSchemaExporterOptions
Oggetto exporterOptions che controlla la generazione dello schema.
Valori restituiti
JsonNode Nuova istanza che definisce lo schema JSON per type.
Eccezioni
Uno dei parametri specificati è null.
Il options parametro contiene unsupported exporterOptions.