// <auto-generated/>
#nullable enable annotations
#nullable disable warnings
// Suppress warnings about [Obsolete] member usage in generated code.
#pragma warning disable CS0612, CS0618
namespace Microsoft.DotNet.Cli.Telemetry.Implementation
{
internal sealed partial class TelemetryJsonContext
{
private global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>>? _DependencyEnvelope;
/// <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::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>> DependencyEnvelope
#nullable enable annotations
{
get => _DependencyEnvelope ??= (global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>>)Options.GetTypeInfo(typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>));
}
private global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>> Create_DependencyEnvelope(global::System.Text.Json.JsonSerializerOptions options)
{
if (!TryGetTypeInfoForRuntimeCustomConverter<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>>(options, out global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>> jsonTypeInfo))
{
var objectInfo = new global::System.Text.Json.Serialization.Metadata.JsonObjectInfoValues<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>>
{
ObjectCreator = () => new global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>(),
ObjectWithParameterizedConstructorCreator = null,
PropertyMetadataInitializer = _ => DependencyEnvelopePropInit(options),
ConstructorParameterMetadataInitializer = null,
ConstructorAttributeProviderFactory = static () => typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>).GetConstructor(InstanceMemberBindingFlags, binder: null, global::System.Array.Empty<global::System.Type>(), modifiers: null),
SerializeHandler = DependencyEnvelopeSerializeHandler,
PolymorphismOptions = new global::System.Text.Json.Serialization.Metadata.JsonPolymorphismOptions(),
TypeClassifierFactory = null,
};
jsonTypeInfo = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreateObjectInfo<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>>(options, objectInfo);
jsonTypeInfo.NumberHandling = null;
}
jsonTypeInfo.OriginatingResolver = this;
return jsonTypeInfo;
}
private static global::System.Text.Json.Serialization.Metadata.JsonPropertyInfo[] DependencyEnvelopePropInit(global::System.Text.Json.JsonSerializerOptions options)
{
var properties = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfo[5];
var info0 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<string>
{
IsProperty = true,
IsPublic = true,
IsVirtual = false,
DeclaringType = typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>),
Converter = null,
Getter = static obj => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Name,
Setter = static (obj, value) => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Name = value!,
IgnoreCondition = null,
HasJsonInclude = false,
IsExtensionData = false,
NumberHandling = null,
PropertyName = "Name",
JsonPropertyName = "name",
AttributeProviderFactory = static () => typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>).GetProperty("Name", 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);
properties[0].IsGetNullable = false;
properties[0].IsSetNullable = false;
var info1 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<string>
{
IsProperty = true,
IsPublic = true,
IsVirtual = false,
DeclaringType = typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>),
Converter = null,
Getter = static obj => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Time,
Setter = static (obj, value) => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Time = value!,
IgnoreCondition = null,
HasJsonInclude = false,
IsExtensionData = false,
NumberHandling = null,
PropertyName = "Time",
JsonPropertyName = "time",
AttributeProviderFactory = static () => typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>).GetProperty("Time", 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<string>
{
IsProperty = true,
IsPublic = true,
IsVirtual = false,
DeclaringType = typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>),
Converter = null,
Getter = static obj => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).InstrumentationKey,
Setter = static (obj, value) => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).InstrumentationKey = value!,
IgnoreCondition = null,
HasJsonInclude = false,
IsExtensionData = false,
NumberHandling = null,
PropertyName = "InstrumentationKey",
JsonPropertyName = "iKey",
AttributeProviderFactory = static () => typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>).GetProperty("InstrumentationKey", InstanceMemberBindingFlags, null, typeof(string), global::System.Array.Empty<global::System.Type>(), null),
};
properties[2] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<string>(options, info2);
properties[2].IsGetNullable = false;
properties[2].IsSetNullable = false;
var info3 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::System.Collections.Generic.Dictionary<string, string>>
{
IsProperty = true,
IsPublic = true,
IsVirtual = false,
DeclaringType = typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>),
Converter = null,
Getter = static obj => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Tags,
Setter = static (obj, value) => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Tags = value!,
IgnoreCondition = null,
HasJsonInclude = false,
IsExtensionData = false,
NumberHandling = null,
PropertyName = "Tags",
JsonPropertyName = "tags",
AttributeProviderFactory = static () => typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>).GetProperty("Tags", InstanceMemberBindingFlags, null, typeof(global::System.Collections.Generic.Dictionary<string, string>), global::System.Array.Empty<global::System.Type>(), null),
};
properties[3] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::System.Collections.Generic.Dictionary<string, string>>(options, info3);
properties[3].IsGetNullable = false;
properties[3].IsSetNullable = false;
var info4 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryData<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>>
{
IsProperty = true,
IsPublic = true,
IsVirtual = false,
DeclaringType = typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>),
Converter = null,
Getter = static obj => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Data,
Setter = static (obj, value) => ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)obj).Data = value!,
IgnoreCondition = null,
HasJsonInclude = false,
IsExtensionData = false,
NumberHandling = null,
PropertyName = "Data",
JsonPropertyName = "data",
AttributeProviderFactory = static () => typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>).GetProperty("Data", InstanceMemberBindingFlags, null, typeof(global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryData<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>), global::System.Array.Empty<global::System.Type>(), null),
};
properties[4] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryData<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>>(options, info4);
properties[4].IsGetNullable = false;
properties[4].IsSetNullable = false;
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 DependencyEnvelopeSerializeHandler(global::System.Text.Json.Utf8JsonWriter writer, global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>? value)
{
if (value is null)
{
writer.WriteNullValue();
return;
}
writer.WriteStartObject();
writer.WriteString(PropName_name, ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)value).Name);
writer.WriteString(PropName_time, ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)value).Time);
writer.WriteString(PropName_iKey, ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)value).InstrumentationKey);
writer.WritePropertyName(PropName_tags);
DictionaryStringStringSerializeHandler(writer, ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)value).Tags);
writer.WritePropertyName(PropName_data);
TelemetryDataRemoteDependencyDataSerializeHandler(writer, ((global::Microsoft.DotNet.Cli.Telemetry.Implementation.TelemetryEnvelope<global::Microsoft.DotNet.Cli.Telemetry.Implementation.RemoteDependencyData>)value).Data);
writer.WriteEndObject();
}
}
}