JsonMetadataServices.GetEnumConverter<T>(JsonSerializerOptions) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a JsonConverter<T> instance that converts T
values.
public:
generic <typename T>
where T : value class static System::Text::Json::Serialization::JsonConverter<T> ^ GetEnumConverter(System::Text::Json::JsonSerializerOptions ^ options);
public static System.Text.Json.Serialization.JsonConverter<T> GetEnumConverter<T> (System.Text.Json.JsonSerializerOptions options) where T : struct;
static member GetEnumConverter : System.Text.Json.JsonSerializerOptions -> System.Text.Json.Serialization.JsonConverter<'T (requires 'T : struct)> (requires 'T : struct)
Public Shared Function GetEnumConverter(Of T As Structure) (options As JsonSerializerOptions) As JsonConverter(Of T)
Type Parameters
- T
The generic definition for the enum type.
Parameters
- options
- JsonSerializerOptions
The JsonSerializerOptions to use for serialization and deserialization.
Returns
A JsonConverter<T> instance that converts T
values.
Remarks
This API is for use by the output of the System.Text.Json source generator and should not be called directly.
Applies to
Sodelujte z nami v storitvi GitHub
Vir za to vsebino najdete v storitvi GitHub, kjer lahko tudi ustvarite in pregledate težave in zahtevke za uveljavitev sprememb. Če želite več informacij, glejte naš vodnik za sodelavce.