// <auto-generated/> #nullable enable annotations #nullable disable warnings // Suppress warnings about [Obsolete] member usage in generated code. #pragma warning disable CS0612, CS0618 namespace Microsoft.Extensions.AI.JsonSchemaExporter { public static partial class TestTypes { public partial class TestTypesContext { private global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::System.Xml.Linq.XDocumentType>? _XDocumentType; /// <summary> /// Defines the source generated JSON serialization contract metadata for a given type. /// </summary> #nullable disable annotations // Marking the property type as nullable-oblivious. public global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::System.Xml.Linq.XDocumentType> XDocumentType #nullable enable annotations { get => _XDocumentType ??= (global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::System.Xml.Linq.XDocumentType>)Options.GetTypeInfo(typeof(global::System.Xml.Linq.XDocumentType)); } private global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::System.Xml.Linq.XDocumentType> Create_XDocumentType(global::System.Text.Json.JsonSerializerOptions options) { if (!TryGetTypeInfoForRuntimeCustomConverter<global::System.Xml.Linq.XDocumentType>(options, out global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::System.Xml.Linq.XDocumentType> jsonTypeInfo)) { var objectInfo = new global::System.Text.Json.Serialization.Metadata.JsonObjectInfoValues<global::System.Xml.Linq.XDocumentType> { ObjectCreator = null, ObjectWithParameterizedConstructorCreator = null, PropertyMetadataInitializer = _ => XDocumentTypePropInit(options), ConstructorParameterMetadataInitializer = null, ConstructorAttributeProviderFactory = null, SerializeHandler = XDocumentTypeSerializeHandler, }; jsonTypeInfo = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreateObjectInfo<global::System.Xml.Linq.XDocumentType>(options, objectInfo); jsonTypeInfo.NumberHandling = null; } jsonTypeInfo.OriginatingResolver = this; return jsonTypeInfo; } private static global::System.Text.Json.Serialization.Metadata.JsonPropertyInfo[] XDocumentTypePropInit(global::System.Text.Json.JsonSerializerOptions options) { var properties = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfo[11]; var info0 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<string> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XDocumentType), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XDocumentType)obj).InternalSubset, Setter = static (obj, value) => ((global::System.Xml.Linq.XDocumentType)obj).InternalSubset = value!, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "InternalSubset", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XDocumentType).GetProperty("InternalSubset", InstanceMemberBindingFlags, null, typeof(string), global::System.Array.Empty<global::System.Type>(), null), }; properties[0] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<string>(options, info0); var info1 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<string> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XDocumentType), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XDocumentType)obj).Name, Setter = static (obj, value) => ((global::System.Xml.Linq.XDocumentType)obj).Name = value!, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "Name", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XDocumentType).GetProperty("Name", InstanceMemberBindingFlags, null, typeof(string), global::System.Array.Empty<global::System.Type>(), null), }; properties[1] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<string>(options, info1); properties[1].IsGetNullable = false; properties[1].IsSetNullable = false; var info2 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::System.Xml.XmlNodeType> { IsProperty = true, IsPublic = true, IsVirtual = true, DeclaringType = typeof(global::System.Xml.Linq.XDocumentType), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XDocumentType)obj).NodeType, Setter = null, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "NodeType", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XDocumentType).GetProperty("NodeType", InstanceMemberBindingFlags, null, typeof(global::System.Xml.XmlNodeType), global::System.Array.Empty<global::System.Type>(), null), }; properties[2] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::System.Xml.XmlNodeType>(options, info2); var info3 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<string> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XDocumentType), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XDocumentType)obj).PublicId, Setter = static (obj, value) => ((global::System.Xml.Linq.XDocumentType)obj).PublicId = value!, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "PublicId", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XDocumentType).GetProperty("PublicId", InstanceMemberBindingFlags, null, typeof(string), global::System.Array.Empty<global::System.Type>(), null), }; properties[3] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<string>(options, info3); var info4 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<string> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XDocumentType), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XDocumentType)obj).SystemId, Setter = static (obj, value) => ((global::System.Xml.Linq.XDocumentType)obj).SystemId = value!, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "SystemId", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XDocumentType).GetProperty("SystemId", InstanceMemberBindingFlags, null, typeof(string), global::System.Array.Empty<global::System.Type>(), null), }; properties[4] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<string>(options, info4); var info5 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::System.Xml.Linq.XNode> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XNode), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XNode)obj).NextNode, Setter = null, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "NextNode", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XNode).GetProperty("NextNode", InstanceMemberBindingFlags, null, typeof(global::System.Xml.Linq.XNode), global::System.Array.Empty<global::System.Type>(), null), }; properties[5] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::System.Xml.Linq.XNode>(options, info5); var info6 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::System.Xml.Linq.XNode> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XNode), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XNode)obj).PreviousNode, Setter = null, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "PreviousNode", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XNode).GetProperty("PreviousNode", InstanceMemberBindingFlags, null, typeof(global::System.Xml.Linq.XNode), global::System.Array.Empty<global::System.Type>(), null), }; properties[6] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::System.Xml.Linq.XNode>(options, info6); var info7 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<string> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XObject), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XObject)obj).BaseUri, Setter = null, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "BaseUri", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XObject).GetProperty("BaseUri", InstanceMemberBindingFlags, null, typeof(string), global::System.Array.Empty<global::System.Type>(), null), }; properties[7] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<string>(options, info7); properties[7].IsGetNullable = false; var info8 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::System.Xml.Linq.XDocument> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XObject), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XObject)obj).Document, Setter = null, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "Document", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XObject).GetProperty("Document", InstanceMemberBindingFlags, null, typeof(global::System.Xml.Linq.XDocument), global::System.Array.Empty<global::System.Type>(), null), }; properties[8] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::System.Xml.Linq.XDocument>(options, info8); var info9 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::System.Xml.XmlNodeType> { IsProperty = true, IsPublic = true, IsVirtual = true, DeclaringType = typeof(global::System.Xml.Linq.XObject), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XObject)obj).NodeType, Setter = null, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "NodeType", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XObject).GetProperty("NodeType", InstanceMemberBindingFlags, null, typeof(global::System.Xml.XmlNodeType), global::System.Array.Empty<global::System.Type>(), null), }; properties[9] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::System.Xml.XmlNodeType>(options, info9); var info10 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::System.Xml.Linq.XElement> { IsProperty = true, IsPublic = true, IsVirtual = false, DeclaringType = typeof(global::System.Xml.Linq.XObject), Converter = null, Getter = static obj => ((global::System.Xml.Linq.XObject)obj).Parent, Setter = null, IgnoreCondition = null, HasJsonInclude = false, IsExtensionData = false, NumberHandling = null, PropertyName = "Parent", JsonPropertyName = null, AttributeProviderFactory = static () => typeof(global::System.Xml.Linq.XObject).GetProperty("Parent", InstanceMemberBindingFlags, null, typeof(global::System.Xml.Linq.XElement), global::System.Array.Empty<global::System.Type>(), null), }; properties[10] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::System.Xml.Linq.XElement>(options, info10); return properties; } // Intentionally not a static method because we create a delegate to it. Invoking delegates to instance // methods is almost as fast as virtual calls. Static methods need to go through a shuffle thunk. private void XDocumentTypeSerializeHandler(global::System.Text.Json.Utf8JsonWriter writer, global::System.Xml.Linq.XDocumentType? value) { if (value is null) { writer.WriteNullValue(); return; } writer.WriteStartObject(); writer.WriteString(PropName_InternalSubset, ((global::System.Xml.Linq.XDocumentType)value).InternalSubset); writer.WriteString(PropName_Name, ((global::System.Xml.Linq.XDocumentType)value).Name); writer.WritePropertyName(PropName_NodeType); global::System.Text.Json.JsonSerializer.Serialize(writer, ((global::System.Xml.Linq.XDocumentType)value).NodeType, XmlNodeType); writer.WriteString(PropName_PublicId, ((global::System.Xml.Linq.XDocumentType)value).PublicId); writer.WriteString(PropName_SystemId, ((global::System.Xml.Linq.XDocumentType)value).SystemId); writer.WritePropertyName(PropName_NextNode); XNodeSerializeHandler(writer, ((global::System.Xml.Linq.XNode)value).NextNode); writer.WritePropertyName(PropName_PreviousNode); XNodeSerializeHandler(writer, ((global::System.Xml.Linq.XNode)value).PreviousNode); writer.WriteString(PropName_BaseUri, ((global::System.Xml.Linq.XObject)value).BaseUri); writer.WritePropertyName(PropName_Document); XDocumentSerializeHandler(writer, ((global::System.Xml.Linq.XObject)value).Document); writer.WritePropertyName(PropName_Parent); XElementSerializeHandler(writer, ((global::System.Xml.Linq.XObject)value).Parent); writer.WriteEndObject(); } } } }