16 references to UnionCases
System.Text.Json (16)
System\Text\Json\Schema\JsonSchemaExporter.cs (1)
361
if (typeInfo.
UnionCases
is { Count: > 0 } unionCases)
System\Text\Json\Serialization\Attributes\JsonUnionAttribute.cs (1)
28
/// contract customization to populate <see cref="Metadata.JsonTypeInfo.
UnionCases
"/>
System\Text\Json\Serialization\JsonTypeClassifierContext.cs (1)
71
/// list mirrors <see cref="JsonTypeInfo.
UnionCases
"/> on the resolved
System\Text\Json\Serialization\Metadata\DefaultJsonTypeInfoResolver.Union.cs (3)
88
/// <see cref="JsonTypeInfo.
UnionCases
"/> in declaration order. Each ctor overload
100
Debug.Assert(typeInfo.
UnionCases
.Count == 0,
105
IList<JsonUnionCaseInfo> unionCases = typeInfo.
UnionCases
;
System\Text\Json\Serialization\Metadata\JsonMetadataServices.cs (1)
91
typeInfo.
UnionCases
.Add(caseInfo);
System\Text\Json\Serialization\Metadata\JsonTypeInfo.cs (9)
417
/// The returned type must match a <see cref="JsonUnionCaseInfo.CaseType"/> in <see cref="
UnionCases
"/>;
547
/// serializes as that value shape. Populated at configuration time from <see cref="
UnionCases
"/>.
565
/// First nullable union case type, if any. Populated at configuration time from <see cref="
UnionCases
"/>.
1036
BuildUnionValueTypeMap(
UnionCases
, Options, this);
1041
foreach (JsonUnionCaseInfo unionCase in
UnionCases
)
1060
if (
UnionCases
.Count == 0)
1080
foreach (JsonUnionCaseInfo unionCase in
UnionCases
)
1109
Debug.Assert(
UnionCases
.Count > 0);
1113
new List<JsonUnionCaseInfo>(
UnionCases
),