diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/CHANGELOG.md b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/CHANGELOG.md index 3653304633b1..ce3f1a661413 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/CHANGELOG.md +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/CHANGELOG.md @@ -5,6 +5,7 @@ ### Features Added - Enable the new model serialization by using the System.ClientModel, refer this [document](https://aka.ms/azsdk/net/mrw) for more details. +- Exposed `JsonModelWriteCore` for model serialization procedure. ### Breaking Changes diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/api/Azure.ResourceManager.NetworkCloud.netstandard2.0.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/api/Azure.ResourceManager.NetworkCloud.netstandard2.0.cs index 529bbcc6f57c..8dfb4ac2f73f 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/api/Azure.ResourceManager.NetworkCloud.netstandard2.0.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/api/Azure.ResourceManager.NetworkCloud.netstandard2.0.cs @@ -35,6 +35,7 @@ public NetworkCloudAgentPoolData(Azure.Core.AzureLocation location, long count, public System.Collections.Generic.IList Taints { get { throw null; } } public string UpgradeMaxSurge { get { throw null; } set { } } public string VmSkuName { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudAgentPoolData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudAgentPoolData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -113,6 +114,7 @@ public NetworkCloudBareMetalMachineData(Azure.Core.AzureLocation location, Azure public string SerialNumber { get { throw null; } set { } } public string ServiceTag { get { throw null; } } public System.Collections.Generic.IReadOnlyList VirtualMachinesAssociatedIds { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudBareMetalMachineData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudBareMetalMachineData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -151,6 +153,7 @@ public NetworkCloudBareMetalMachineKeySetData(Azure.Core.AzureLocation location, public Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineKeySetProvisioningState? ProvisioningState { get { throw null; } } public System.Collections.Generic.IList UserList { get { throw null; } } public System.Collections.Generic.IReadOnlyList UserListStatus { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudBareMetalMachineKeySetData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudBareMetalMachineKeySetData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -255,6 +258,7 @@ public NetworkCloudBmcKeySetData(Azure.Core.AzureLocation location, Azure.Resour public Azure.ResourceManager.NetworkCloud.Models.BmcKeySetProvisioningState? ProvisioningState { get { throw null; } } public System.Collections.Generic.IList UserList { get { throw null; } } public System.Collections.Generic.IReadOnlyList UserListStatus { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudBmcKeySetData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudBmcKeySetData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -318,6 +322,7 @@ public NetworkCloudCloudServicesNetworkData(Azure.Core.AzureLocation location, A public string InterfaceName { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.CloudServicesNetworkProvisioningState? ProvisioningState { get { throw null; } } public System.Collections.Generic.IReadOnlyList VirtualMachinesAssociatedIds { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudCloudServicesNetworkData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudCloudServicesNetworkData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -393,6 +398,7 @@ public NetworkCloudClusterData(Azure.Core.AzureLocation location, Azure.Resource public Azure.ResourceManager.NetworkCloud.Models.ClusterProvisioningState? ProvisioningState { get { throw null; } } public System.DateTimeOffset? SupportExpireOn { get { throw null; } } public System.Collections.Generic.IReadOnlyList WorkloadResourceIds { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudClusterData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudClusterData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -429,6 +435,7 @@ public NetworkCloudClusterManagerData(Azure.Core.AzureLocation location, Azure.C public Azure.ResourceManager.NetworkCloud.Models.ExtendedLocation ManagerExtendedLocation { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.ClusterManagerProvisioningState? ProvisioningState { get { throw null; } } public string VmSize { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudClusterManagerData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudClusterManagerData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -487,6 +494,7 @@ public NetworkCloudClusterMetricsConfigurationData(Azure.Core.AzureLocation loca public System.Collections.Generic.IList EnabledMetrics { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.ExtendedLocation ExtendedLocation { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.ClusterMetricsConfigurationProvisioningState? ProvisioningState { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudClusterMetricsConfigurationData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudClusterMetricsConfigurationData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -678,6 +686,7 @@ public NetworkCloudKubernetesClusterData(Azure.Core.AzureLocation location, Azur public Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterNetworkConfiguration NetworkConfiguration { get { throw null; } set { } } public System.Collections.Generic.IReadOnlyList Nodes { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterProvisioningState? ProvisioningState { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudKubernetesClusterData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudKubernetesClusterData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -745,6 +754,7 @@ public NetworkCloudL2NetworkData(Azure.Core.AzureLocation location, Azure.Resour public Azure.Core.ResourceIdentifier L2IsolationDomainId { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.L2NetworkProvisioningState? ProvisioningState { get { throw null; } } public System.Collections.Generic.IReadOnlyList VirtualMachinesAssociatedIds { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudL2NetworkData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudL2NetworkData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -812,6 +822,7 @@ public NetworkCloudL3NetworkData(Azure.Core.AzureLocation location, Azure.Resour public Azure.ResourceManager.NetworkCloud.Models.L3NetworkProvisioningState? ProvisioningState { get { throw null; } } public System.Collections.Generic.IReadOnlyList VirtualMachinesAssociatedIds { get { throw null; } } public long Vlan { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudL3NetworkData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudL3NetworkData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -870,6 +881,7 @@ public NetworkCloudRackData(Azure.Core.AzureLocation location, Azure.ResourceMan public string RackLocation { get { throw null; } set { } } public string RackSerialNumber { get { throw null; } set { } } public Azure.Core.ResourceIdentifier RackSkuId { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudRackData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudRackData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -925,6 +937,7 @@ public NetworkCloudRackSkuData() { } public Azure.ResourceManager.NetworkCloud.Models.RackSkuType? RackType { get { throw null; } } public System.Collections.Generic.IReadOnlyList StorageAppliances { get { throw null; } } public System.Collections.Generic.IReadOnlyList SupportedRackSkuIds { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudRackSkuData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudRackSkuData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -979,6 +992,7 @@ public NetworkCloudStorageApplianceData(Azure.Core.AzureLocation location, Azure public Azure.ResourceManager.NetworkCloud.Models.RemoteVendorManagementStatus? RemoteVendorManagementStatus { get { throw null; } } public string SerialNumber { get { throw null; } set { } } public string StorageApplianceSkuId { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudStorageApplianceData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudStorageApplianceData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1044,6 +1058,7 @@ public NetworkCloudTrunkedNetworkData(Azure.Core.AzureLocation location, Azure.R public Azure.ResourceManager.NetworkCloud.Models.TrunkedNetworkProvisioningState? ProvisioningState { get { throw null; } } public System.Collections.Generic.IReadOnlyList VirtualMachinesAssociatedIds { get { throw null; } } public System.Collections.Generic.IList Vlans { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudTrunkedNetworkData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudTrunkedNetworkData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1121,6 +1136,7 @@ public NetworkCloudVirtualMachineConsoleData(Azure.Core.AzureLocation location, public Azure.Core.ResourceIdentifier PrivateLinkServiceId { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.ConsoleProvisioningState? ProvisioningState { get { throw null; } } public System.Guid? VirtualMachineAccessId { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudVirtualMachineConsoleData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudVirtualMachineConsoleData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1180,6 +1196,7 @@ public NetworkCloudVirtualMachineData(Azure.Core.AzureLocation location, Azure.R public string VmImage { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.ImageRepositoryCredentials VmImageRepositoryCredentials { get { throw null; } set { } } public System.Collections.Generic.IReadOnlyList Volumes { get { throw null; } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudVirtualMachineData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudVirtualMachineData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1249,6 +1266,7 @@ public NetworkCloudVolumeData(Azure.Core.AzureLocation location, Azure.ResourceM public Azure.ResourceManager.NetworkCloud.Models.VolumeProvisioningState? ProvisioningState { get { throw null; } } public string SerialNumber { get { throw null; } } public long SizeInMiB { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudVolumeData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.NetworkCloudVolumeData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1384,6 +1402,7 @@ public partial class AdministrativeCredentials : System.ClientModel.Primitives.I public AdministrativeCredentials(string username) { } public string Password { get { throw null; } set { } } public string Username { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AdministrativeCredentials System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AdministrativeCredentials System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1395,6 +1414,7 @@ public partial class AdministratorConfiguration : System.ClientModel.Primitives. public AdministratorConfiguration() { } public string AdminUsername { get { throw null; } set { } } public System.Collections.Generic.IList SshPublicKeys { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AdministratorConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AdministratorConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1509,6 +1529,7 @@ public AttachedNetworkConfiguration() { } public System.Collections.Generic.IList L2Networks { get { throw null; } } public System.Collections.Generic.IList L3Networks { get { throw null; } } public System.Collections.Generic.IList TrunkedNetworks { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AttachedNetworkConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AttachedNetworkConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1538,6 +1559,7 @@ public partial class AvailableUpgrade : System.ClientModel.Primitives.IJsonModel internal AvailableUpgrade() { } public Azure.ResourceManager.NetworkCloud.Models.AvailabilityLifecycle? AvailabilityLifecycle { get { throw null; } } public string Version { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AvailableUpgrade System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.AvailableUpgrade System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1549,6 +1571,7 @@ public partial class BareMetalMachineCommandSpecification : System.ClientModel.P public BareMetalMachineCommandSpecification(string command) { } public System.Collections.Generic.IList Arguments { get { throw null; } } public string Command { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineCommandSpecification System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineCommandSpecification System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1566,6 +1589,7 @@ public BareMetalMachineConfiguration(Azure.ResourceManager.NetworkCloud.Models.A public string MachineName { get { throw null; } set { } } public long RackSlot { get { throw null; } set { } } public string SerialNumber { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1576,6 +1600,7 @@ public partial class BareMetalMachineCordonContent : System.ClientModel.Primitiv { public BareMetalMachineCordonContent() { } public Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineEvacuate? Evacuate { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineCordonContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineCordonContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1739,6 +1764,7 @@ public partial class BareMetalMachinePowerOffContent : System.ClientModel.Primit { public BareMetalMachinePowerOffContent() { } public Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineSkipShutdown? SkipShutdown { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachinePowerOffContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachinePowerOffContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1810,6 +1836,7 @@ public BareMetalMachineReplaceContent() { } public string BootMacAddress { get { throw null; } set { } } public string MachineName { get { throw null; } set { } } public string SerialNumber { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineReplaceContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineReplaceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1822,6 +1849,7 @@ public BareMetalMachineRunCommandContent(long limitTimeSeconds, string script) { public System.Collections.Generic.IList Arguments { get { throw null; } } public long LimitTimeSeconds { get { throw null; } } public string Script { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineRunCommandContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineRunCommandContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1833,6 +1861,7 @@ public partial class BareMetalMachineRunDataExtractsContent : System.ClientModel public BareMetalMachineRunDataExtractsContent(System.Collections.Generic.IEnumerable commands, long limitTimeSeconds) { } public System.Collections.Generic.IList Commands { get { throw null; } } public long LimitTimeSeconds { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineRunDataExtractsContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineRunDataExtractsContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1844,6 +1873,7 @@ public partial class BareMetalMachineRunReadCommandsContent : System.ClientModel public BareMetalMachineRunReadCommandsContent(System.Collections.Generic.IEnumerable commands, long limitTimeSeconds) { } public System.Collections.Generic.IList Commands { get { throw null; } } public long LimitTimeSeconds { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineRunReadCommandsContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineRunReadCommandsContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1893,6 +1923,7 @@ public BgpAdvertisement(System.Collections.Generic.IEnumerable ipAddress public System.Collections.Generic.IList Communities { get { throw null; } } public System.Collections.Generic.IList IPAddressPools { get { throw null; } } public System.Collections.Generic.IList Peers { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BgpAdvertisement System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BgpAdvertisement System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -1924,6 +1955,7 @@ public BgpServiceLoadBalancerConfiguration() { } public System.Collections.Generic.IList BgpPeers { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.FabricPeeringEnabled? FabricPeeringEnabled { get { throw null; } set { } } public System.Collections.Generic.IList IPAddressPools { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BgpServiceLoadBalancerConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.BgpServiceLoadBalancerConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2073,6 +2105,7 @@ internal ClusterAvailableUpgradeVersion() { } public System.DateTimeOffset? SupportExpireOn { get { throw null; } } public string TargetClusterVersion { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.WorkloadImpact? WorkloadImpact { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterAvailableUpgradeVersion System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterAvailableUpgradeVersion System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2084,6 +2117,7 @@ public partial class ClusterAvailableVersion : System.ClientModel.Primitives.IJs internal ClusterAvailableVersion() { } public string SupportExpiryDate { get { throw null; } } public string TargetClusterVersion { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterAvailableVersion System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterAvailableVersion System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2101,6 +2135,7 @@ internal ClusterCapacity() { } public long? TotalCoreCount { get { throw null; } } public long? TotalHostStorageGB { get { throw null; } } public long? TotalMemoryGB { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterCapacity System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterCapacity System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2130,6 +2165,7 @@ public partial class ClusterDeployContent : System.ClientModel.Primitives.IJsonM { public ClusterDeployContent() { } public System.Collections.Generic.IList SkipValidationsForMachines { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterDeployContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterDeployContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2306,6 +2342,7 @@ public partial class ClusterUpdateVersionContent : System.ClientModel.Primitives { public ClusterUpdateVersionContent(string targetClusterVersion) { } public string TargetClusterVersion { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterUpdateVersionContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ClusterUpdateVersionContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2394,6 +2431,7 @@ public ControlPlaneNodeConfiguration(long count, string vmSkuName) { } public System.Collections.Generic.IList AvailabilityZones { get { throw null; } } public long Count { get { throw null; } set { } } public string VmSkuName { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ControlPlaneNodeConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ControlPlaneNodeConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2458,6 +2496,7 @@ public partial class EgressEndpoint : System.ClientModel.Primitives.IJsonModel endpoints) { } public string Category { get { throw null; } set { } } public System.Collections.Generic.IList Endpoints { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.EgressEndpoint System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.EgressEndpoint System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2469,6 +2508,7 @@ public partial class EndpointDependency : System.ClientModel.Primitives.IJsonMod public EndpointDependency(string domainName) { } public string DomainName { get { throw null; } set { } } public long? Port { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.EndpointDependency System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.EndpointDependency System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2480,6 +2520,7 @@ public partial class ExtendedLocation : System.ClientModel.Primitives.IJsonModel public ExtendedLocation(string name, string extendedLocationType) { } public string ExtendedLocationType { get { throw null; } set { } } public string Name { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ExtendedLocation System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ExtendedLocation System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2530,6 +2571,7 @@ internal FeatureStatus() { } public string DetailedStatusMessage { get { throw null; } } public string Name { get { throw null; } } public string Version { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.FeatureStatus System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.FeatureStatus System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2542,6 +2584,7 @@ internal HardwareInventory() { } public string AdditionalHostInformation { get { throw null; } } public System.Collections.Generic.IReadOnlyList Interfaces { get { throw null; } } public System.Collections.Generic.IReadOnlyList Nics { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.HardwareInventory System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.HardwareInventory System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2555,6 +2598,7 @@ internal HardwareInventoryNetworkInterface() { } public string MacAddress { get { throw null; } } public string Name { get { throw null; } } public string NetworkInterfaceId { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.HardwareInventoryNetworkInterface System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.HardwareInventoryNetworkInterface System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2566,6 +2610,7 @@ public partial class HardwareValidationStatus : System.ClientModel.Primitives.IJ internal HardwareValidationStatus() { } public System.DateTimeOffset? LastValidationOn { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineHardwareValidationResult? Result { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.HardwareValidationStatus System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.HardwareValidationStatus System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2633,6 +2678,7 @@ public ImageRepositoryCredentials(string registryUriString, string username) { } public string Password { get { throw null; } set { } } public string RegistryUriString { get { throw null; } set { } } public string Username { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ImageRepositoryCredentials System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ImageRepositoryCredentials System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2653,6 +2699,7 @@ public InitialAgentPoolConfiguration(long count, Azure.ResourceManager.NetworkCl public System.Collections.Generic.IList Taints { get { throw null; } } public string UpgradeMaxSurge { get { throw null; } set { } } public string VmSkuName { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.InitialAgentPoolConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.InitialAgentPoolConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2666,6 +2713,7 @@ public IPAddressPool(System.Collections.Generic.IEnumerable addresses, s public Azure.ResourceManager.NetworkCloud.Models.BfdEnabled? AutoAssign { get { throw null; } set { } } public string Name { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.BfdEnabled? OnlyUseHostIPs { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.IPAddressPool System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.IPAddressPool System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2697,6 +2745,7 @@ public KeySetUser(string azureUserName, Azure.ResourceManager.NetworkCloud.Model public string AzureUserName { get { throw null; } set { } } public string Description { get { throw null; } set { } } public string KeyData { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KeySetUser System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KeySetUser System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2709,6 +2758,7 @@ internal KeySetUserStatus() { } public string AzureUserName { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.BareMetalMachineKeySetUserSetupStatus? Status { get { throw null; } } public string StatusMessage { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KeySetUserStatus System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KeySetUserStatus System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2744,6 +2794,7 @@ public KubernetesClusterNetworkConfiguration(Azure.Core.ResourceIdentifier cloud public System.Net.IPAddress DnsServiceIP { get { throw null; } set { } } public System.Collections.Generic.IList PodCidrs { get { throw null; } } public System.Collections.Generic.IList ServiceCidrs { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterNetworkConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterNetworkConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2771,6 +2822,7 @@ internal KubernetesClusterNode() { } public Azure.ResourceManager.NetworkCloud.Models.KubernetesNodeRole? Role { get { throw null; } } public System.Collections.Generic.IReadOnlyList Taints { get { throw null; } } public string VmSkuName { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterNode System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterNode System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2829,6 +2881,7 @@ public partial class KubernetesClusterRestartNodeContent : System.ClientModel.Pr { public KubernetesClusterRestartNodeContent(string nodeName) { } public string NodeName { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterRestartNodeContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesClusterRestartNodeContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2840,6 +2893,7 @@ public partial class KubernetesLabel : System.ClientModel.Primitives.IJsonModel< public KubernetesLabel(string key, string value) { } public string Key { get { throw null; } set { } } public string Value { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesLabel System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.KubernetesLabel System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2909,6 +2963,7 @@ public partial class L2NetworkAttachmentConfiguration : System.ClientModel.Primi public L2NetworkAttachmentConfiguration(Azure.Core.ResourceIdentifier networkId) { } public Azure.Core.ResourceIdentifier NetworkId { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.KubernetesPluginType? PluginType { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.L2NetworkAttachmentConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.L2NetworkAttachmentConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -2961,6 +3016,7 @@ public L3NetworkAttachmentConfiguration(Azure.Core.ResourceIdentifier networkId) public Azure.ResourceManager.NetworkCloud.Models.L3NetworkConfigurationIpamEnabled? IpamEnabled { get { throw null; } set { } } public Azure.Core.ResourceIdentifier NetworkId { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.KubernetesPluginType? PluginType { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.L3NetworkAttachmentConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.L3NetworkAttachmentConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3032,6 +3088,7 @@ internal LldpNeighbor() { } public string PortName { get { throw null; } } public string SystemDescription { get { throw null; } } public string SystemName { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.LldpNeighbor System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.LldpNeighbor System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3044,6 +3101,7 @@ internal MachineDisk() { } public long? CapacityGB { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.MachineSkuDiskConnectionType? Connection { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.DiskType? DiskType { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.MachineDisk System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.MachineDisk System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3085,6 +3143,7 @@ internal MachineSkuSlot() { } public long? RackSlot { get { throw null; } } public long? TotalThreads { get { throw null; } } public string Vendor { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.MachineSkuSlot System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.MachineSkuSlot System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3096,6 +3155,7 @@ public partial class ManagedResourceGroupConfiguration : System.ClientModel.Prim public ManagedResourceGroupConfiguration() { } public Azure.Core.AzureLocation? Location { get { throw null; } set { } } public string Name { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ManagedResourceGroupConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ManagedResourceGroupConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3112,6 +3172,7 @@ public NetworkAttachment(string attachedNetworkId, Azure.ResourceManager.Network public string IPv6Address { get { throw null; } set { } } public string MacAddress { get { throw null; } } public string NetworkAttachmentName { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkAttachment System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkAttachment System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3123,6 +3184,7 @@ public partial class NetworkCloudAgentConfiguration : System.ClientModel.Primiti public NetworkCloudAgentConfiguration(long hugepagesCount) { } public long HugepagesCount { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.HugepagesSize? HugepagesSize { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudAgentConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudAgentConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3154,6 +3216,7 @@ public NetworkCloudAgentPoolPatch() { } public long? Count { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } public string UpgradeMaxSurge { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudAgentPoolPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudAgentPoolPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3167,6 +3230,7 @@ public NetworkCloudBareMetalMachineKeySetPatch() { } public System.Collections.Generic.IList JumpHostsAllowed { get { throw null; } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } public System.Collections.Generic.IList UserList { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudBareMetalMachineKeySetPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudBareMetalMachineKeySetPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3178,6 +3242,7 @@ public partial class NetworkCloudBareMetalMachinePatch : System.ClientModel.Prim public NetworkCloudBareMetalMachinePatch() { } public string MachineDetails { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudBareMetalMachinePatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudBareMetalMachinePatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3190,6 +3255,7 @@ public NetworkCloudBmcKeySetPatch() { } public System.DateTimeOffset? ExpireOn { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } public System.Collections.Generic.IList UserList { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudBmcKeySetPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudBmcKeySetPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3202,6 +3268,7 @@ public NetworkCloudCloudServicesNetworkPatch() { } public System.Collections.Generic.IList AdditionalEgressEndpoints { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.CloudServicesNetworkEnableDefaultEgressEndpoint? EnableDefaultEgressEndpoints { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudCloudServicesNetworkPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudCloudServicesNetworkPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3212,6 +3279,7 @@ public partial class NetworkCloudClusterManagerPatch : System.ClientModel.Primit { public NetworkCloudClusterManagerPatch() { } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudClusterManagerPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudClusterManagerPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3224,6 +3292,7 @@ public NetworkCloudClusterMetricsConfigurationPatch() { } public long? CollectionInterval { get { throw null; } set { } } public System.Collections.Generic.IList EnabledMetrics { get { throw null; } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudClusterMetricsConfigurationPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudClusterMetricsConfigurationPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3239,6 +3308,7 @@ public NetworkCloudClusterPatch() { } public Azure.ResourceManager.NetworkCloud.Models.ValidationThreshold ComputeDeploymentThreshold { get { throw null; } set { } } public System.Collections.Generic.IList ComputeRackDefinitions { get { throw null; } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudClusterPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudClusterPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3251,6 +3321,7 @@ public NetworkCloudKubernetesClusterPatch() { } public long? ControlPlaneNodeCount { get { throw null; } set { } } public string KubernetesVersion { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudKubernetesClusterPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudKubernetesClusterPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3261,6 +3332,7 @@ public partial class NetworkCloudL2NetworkPatch : System.ClientModel.Primitives. { public NetworkCloudL2NetworkPatch() { } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudL2NetworkPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudL2NetworkPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3271,6 +3343,7 @@ public partial class NetworkCloudL3NetworkPatch : System.ClientModel.Primitives. { public NetworkCloudL3NetworkPatch() { } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudL3NetworkPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudL3NetworkPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3287,6 +3360,7 @@ internal NetworkCloudNetworkInterface() { } public long? PortCount { get { throw null; } } public long? PortSpeed { get { throw null; } } public string Vendor { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudNetworkInterface System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudNetworkInterface System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3299,6 +3373,7 @@ internal NetworkCloudNic() { } public Azure.ResourceManager.NetworkCloud.Models.LldpNeighbor LldpNeighbor { get { throw null; } } public string MacAddress { get { throw null; } } public string Name { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudNic System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudNic System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3317,6 +3392,7 @@ internal NetworkCloudOperationStatusResult() { } public Azure.Core.ResourceIdentifier ResourceId { get { throw null; } } public System.DateTimeOffset? StartOn { get { throw null; } } public string Status { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudOperationStatusResult System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudOperationStatusResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3329,6 +3405,7 @@ public NetworkCloudOSDisk(long diskSizeInGB) { } public Azure.ResourceManager.NetworkCloud.Models.OSDiskCreateOption? CreateOption { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.OSDiskDeleteOption? DeleteOption { get { throw null; } set { } } public long DiskSizeInGB { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudOSDisk System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudOSDisk System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3345,6 +3422,7 @@ public NetworkCloudRackDefinition(Azure.Core.ResourceIdentifier networkRackId, s public string RackSerialNumber { get { throw null; } set { } } public Azure.Core.ResourceIdentifier RackSkuId { get { throw null; } set { } } public System.Collections.Generic.IList StorageApplianceConfigurationData { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudRackDefinition System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudRackDefinition System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3357,6 +3435,7 @@ public NetworkCloudRackPatch() { } public string RackLocation { get { throw null; } set { } } public string RackSerialNumber { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudRackPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudRackPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3367,6 +3446,7 @@ public partial class NetworkCloudSshPublicKey : System.ClientModel.Primitives.IJ { public NetworkCloudSshPublicKey(string keyData) { } public string KeyData { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudSshPublicKey System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudSshPublicKey System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3378,6 +3458,7 @@ public partial class NetworkCloudStorageAppliancePatch : System.ClientModel.Prim public NetworkCloudStorageAppliancePatch() { } public string SerialNumber { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudStorageAppliancePatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudStorageAppliancePatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3389,6 +3470,7 @@ public partial class NetworkCloudStorageProfile : System.ClientModel.Primitives. public NetworkCloudStorageProfile(Azure.ResourceManager.NetworkCloud.Models.NetworkCloudOSDisk osDisk) { } public Azure.ResourceManager.NetworkCloud.Models.NetworkCloudOSDisk OSDisk { get { throw null; } set { } } public System.Collections.Generic.IList VolumeAttachments { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudStorageProfile System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudStorageProfile System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3399,6 +3481,7 @@ public partial class NetworkCloudTrunkedNetworkPatch : System.ClientModel.Primit { public NetworkCloudTrunkedNetworkPatch() { } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudTrunkedNetworkPatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudTrunkedNetworkPatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3412,6 +3495,7 @@ public NetworkCloudVirtualMachineConsolePatch() { } public System.DateTimeOffset? ExpireOn { get { throw null; } set { } } public string KeyData { get { throw null; } set { } } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudVirtualMachineConsolePatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudVirtualMachineConsolePatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3423,6 +3507,7 @@ public partial class NetworkCloudVirtualMachinePatch : System.ClientModel.Primit public NetworkCloudVirtualMachinePatch() { } public System.Collections.Generic.IDictionary Tags { get { throw null; } } public Azure.ResourceManager.NetworkCloud.Models.ImageRepositoryCredentials VmImageRepositoryCredentials { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudVirtualMachinePatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudVirtualMachinePatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3433,6 +3518,7 @@ public partial class NetworkCloudVolumePatch : System.ClientModel.Primitives.IJs { public NetworkCloudVolumePatch() { } public System.Collections.Generic.IDictionary Tags { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudVolumePatch System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.NetworkCloudVolumePatch System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3599,6 +3685,7 @@ public ServiceLoadBalancerBgpPeer(string name, string peerAddress, long peerAsn) public string PeerAddress { get { throw null; } set { } } public long PeerAsn { get { throw null; } set { } } public long? PeerPort { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ServiceLoadBalancerBgpPeer System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ServiceLoadBalancerBgpPeer System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3612,6 +3699,7 @@ public ServicePrincipalInformation(string applicationId, string principalId, str public string Password { get { throw null; } set { } } public string PrincipalId { get { throw null; } set { } } public string TenantId { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ServicePrincipalInformation System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ServicePrincipalInformation System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3643,6 +3731,7 @@ public StorageApplianceConfiguration(Azure.ResourceManager.NetworkCloud.Models.A public long RackSlot { get { throw null; } set { } } public string SerialNumber { get { throw null; } set { } } public string StorageApplianceName { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.StorageApplianceConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.StorageApplianceConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3672,6 +3761,7 @@ public partial class StorageApplianceEnableRemoteVendorManagementContent : Syste { public StorageApplianceEnableRemoteVendorManagementContent() { } public System.Collections.Generic.IList SupportEndpoints { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.StorageApplianceEnableRemoteVendorManagementContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.StorageApplianceEnableRemoteVendorManagementContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3705,6 +3795,7 @@ internal StorageApplianceSkuSlot() { } public long? CapacityGB { get { throw null; } } public string Model { get { throw null; } } public long? RackSlot { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.StorageApplianceSkuSlot System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.StorageApplianceSkuSlot System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3716,6 +3807,7 @@ public partial class TrunkedNetworkAttachmentConfiguration : System.ClientModel. public TrunkedNetworkAttachmentConfiguration(Azure.Core.ResourceIdentifier networkId) { } public Azure.Core.ResourceIdentifier NetworkId { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.KubernetesPluginType? PluginType { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.TrunkedNetworkAttachmentConfiguration System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.TrunkedNetworkAttachmentConfiguration System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3768,6 +3860,7 @@ public ValidationThreshold(Azure.ResourceManager.NetworkCloud.Models.ValidationT public Azure.ResourceManager.NetworkCloud.Models.ValidationThresholdGrouping Grouping { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.ValidationThresholdType ThresholdType { get { throw null; } set { } } public long Value { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ValidationThreshold System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.ValidationThreshold System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3914,6 +4007,7 @@ public VirtualMachinePlacementHint(Azure.ResourceManager.NetworkCloud.Models.Vir public Azure.Core.ResourceIdentifier ResourceId { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.VirtualMachineSchedulingExecution SchedulingExecution { get { throw null; } set { } } public Azure.ResourceManager.NetworkCloud.Models.VirtualMachinePlacementHintPodAffinityScope Scope { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.VirtualMachinePlacementHint System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.VirtualMachinePlacementHint System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -3960,6 +4054,7 @@ public partial class VirtualMachinePowerOffContent : System.ClientModel.Primitiv { public VirtualMachinePowerOffContent() { } public Azure.ResourceManager.NetworkCloud.Models.SkipShutdown? SkipShutdown { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.VirtualMachinePowerOffContent System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } void System.ClientModel.Primitives.IJsonModel.Write(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.NetworkCloud.Models.VirtualMachinePowerOffContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/assets.json b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/assets.json index 86dba40a8ed8..e700abb41164 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/assets.json +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/assets.json @@ -2,5 +2,5 @@ "AssetsRepo": "Azure/azure-sdk-assets", "AssetsRepoPrefixPath": "net", "TagPrefix": "net/networkcloud/Azure.ResourceManager.NetworkCloud", - "Tag": "net/networkcloud/Azure.ResourceManager.NetworkCloud_3e1c6bc439" + "Tag": "net/networkcloud/Azure.ResourceManager.NetworkCloud_0a7b4cd7f0" } diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministrativeCredentials.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministrativeCredentials.Serialization.cs index 3ab88be7777e..4c97d856f2e2 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministrativeCredentials.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministrativeCredentials.Serialization.cs @@ -18,6 +18,15 @@ public partial class AdministrativeCredentials : IUtf8JsonSerializable, IJsonMod void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea throw new FormatException($"The model {nameof(AdministrativeCredentials)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(Password)) { writer.WritePropertyName("password"u8); @@ -48,7 +56,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea #endif } } - writer.WriteEndObject(); } AdministrativeCredentials IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministratorConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministratorConfiguration.Serialization.cs index 6db60f8aa9a9..20dbb2a3cfd6 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministratorConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AdministratorConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class AdministratorConfiguration : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(AdministratorConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(AdminUsername)) { writer.WritePropertyName("adminUsername"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } AdministratorConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolList.Serialization.cs index 9206a87f97fe..7f3ce3f75248 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class AgentPoolList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt throw new FormatException($"The model {nameof(AgentPoolList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt #endif } } - writer.WriteEndObject(); } AgentPoolList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolUpgradeSettings.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolUpgradeSettings.Serialization.cs index 85966932b25e..457acd4b8ee8 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolUpgradeSettings.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AgentPoolUpgradeSettings.Serialization.cs @@ -18,6 +18,15 @@ internal partial class AgentPoolUpgradeSettings : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead throw new FormatException($"The model {nameof(AgentPoolUpgradeSettings)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(MaxSurge)) { writer.WritePropertyName("maxSurge"u8); @@ -46,7 +54,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead #endif } } - writer.WriteEndObject(); } AgentPoolUpgradeSettings IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AttachedNetworkConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AttachedNetworkConfiguration.Serialization.cs index 94f9796cc63d..ac24903e112f 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AttachedNetworkConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AttachedNetworkConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class AttachedNetworkConfiguration : IUtf8JsonSerializable, IJson void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Model throw new FormatException($"The model {nameof(AttachedNetworkConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(L2Networks)) { writer.WritePropertyName("l2Networks"u8); @@ -71,7 +79,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Model #endif } } - writer.WriteEndObject(); } AttachedNetworkConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AvailableUpgrade.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AvailableUpgrade.Serialization.cs index d277391e93a1..07c302a45cd4 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AvailableUpgrade.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/AvailableUpgrade.Serialization.cs @@ -18,6 +18,15 @@ public partial class AvailableUpgrade : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter throw new FormatException($"The model {nameof(AvailableUpgrade)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(AvailabilityLifecycle)) { writer.WritePropertyName("availabilityLifecycle"u8); @@ -51,7 +59,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter #endif } } - writer.WriteEndObject(); } AvailableUpgrade IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCommandSpecification.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCommandSpecification.Serialization.cs index 90630aa38281..56832e300a23 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCommandSpecification.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCommandSpecification.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachineCommandSpecification : IUtf8JsonSerializabl void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter write throw new FormatException($"The model {nameof(BareMetalMachineCommandSpecification)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Arguments)) { writer.WritePropertyName("arguments"u8); @@ -53,7 +61,6 @@ void IJsonModel.Write(Utf8JsonWriter write #endif } } - writer.WriteEndObject(); } BareMetalMachineCommandSpecification IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineConfiguration.Serialization.cs index bfd9a4a7f946..f2cb18aedb56 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachineConfiguration : IUtf8JsonSerializable, IJso void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode throw new FormatException($"The model {nameof(BareMetalMachineConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(BmcConnectionString)) { writer.WritePropertyName("bmcConnectionString"u8); @@ -66,7 +74,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode #endif } } - writer.WriteEndObject(); } BareMetalMachineConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCordonContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCordonContent.Serialization.cs index 1e2c37057f2a..033c11ab8ff1 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCordonContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineCordonContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachineCordonContent : IUtf8JsonSerializable, IJso void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode throw new FormatException($"The model {nameof(BareMetalMachineCordonContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(Evacuate)) { writer.WritePropertyName("evacuate"u8); @@ -46,7 +54,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode #endif } } - writer.WriteEndObject(); } BareMetalMachineCordonContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineKeySetList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineKeySetList.Serialization.cs index 9c50c77175a7..e5fdd75ae74e 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineKeySetList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineKeySetList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class BareMetalMachineKeySetList : IUtf8JsonSerializable, IJson void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(BareMetalMachineKeySetList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } BareMetalMachineKeySetList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineList.Serialization.cs index 1f7b45c4c56d..3215cf68d24e 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class BareMetalMachineList : IUtf8JsonSerializable, IJsonModel< void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr throw new FormatException($"The model {nameof(BareMetalMachineList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr #endif } } - writer.WriteEndObject(); } BareMetalMachineList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachinePowerOffContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachinePowerOffContent.Serialization.cs index a50c15d90434..7fcedce434b4 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachinePowerOffContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachinePowerOffContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachinePowerOffContent : IUtf8JsonSerializable, IJ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo throw new FormatException($"The model {nameof(BareMetalMachinePowerOffContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(SkipShutdown)) { writer.WritePropertyName("skipShutdown"u8); @@ -46,7 +54,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo #endif } } - writer.WriteEndObject(); } BareMetalMachinePowerOffContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineReplaceContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineReplaceContent.Serialization.cs index e243dcfc2295..1f6a384072e1 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineReplaceContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineReplaceContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachineReplaceContent : IUtf8JsonSerializable, IJs void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod throw new FormatException($"The model {nameof(BareMetalMachineReplaceContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(BmcCredentials)) { writer.WritePropertyName("bmcCredentials"u8); @@ -66,7 +74,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod #endif } } - writer.WriteEndObject(); } BareMetalMachineReplaceContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunCommandContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunCommandContent.Serialization.cs index 91dd009aacb3..fb362c702c51 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunCommandContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunCommandContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachineRunCommandContent : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(BareMetalMachineRunCommandContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Arguments)) { writer.WritePropertyName("arguments"u8); @@ -55,7 +63,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } BareMetalMachineRunCommandContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunDataExtractsContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunDataExtractsContent.Serialization.cs index 43bbe5a88c6a..a1f6df0f5e1a 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunDataExtractsContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunDataExtractsContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachineRunDataExtractsContent : IUtf8JsonSerializa void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter wri throw new FormatException($"The model {nameof(BareMetalMachineRunDataExtractsContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("commands"u8); writer.WriteStartArray(); foreach (var item in Commands) @@ -50,7 +58,6 @@ void IJsonModel.Write(Utf8JsonWriter wri #endif } } - writer.WriteEndObject(); } BareMetalMachineRunDataExtractsContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunReadCommandsContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunReadCommandsContent.Serialization.cs index c5a37aeabcb6..199ed7f0d397 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunReadCommandsContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BareMetalMachineRunReadCommandsContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class BareMetalMachineRunReadCommandsContent : IUtf8JsonSerializa void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter wri throw new FormatException($"The model {nameof(BareMetalMachineRunReadCommandsContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("commands"u8); writer.WriteStartArray(); foreach (var item in Commands) @@ -50,7 +58,6 @@ void IJsonModel.Write(Utf8JsonWriter wri #endif } } - writer.WriteEndObject(); } BareMetalMachineRunReadCommandsContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpAdvertisement.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpAdvertisement.Serialization.cs index c12f631cd61b..77769150084a 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpAdvertisement.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpAdvertisement.Serialization.cs @@ -18,6 +18,15 @@ public partial class BgpAdvertisement : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter throw new FormatException($"The model {nameof(BgpAdvertisement)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(AdvertiseToFabric)) { writer.WritePropertyName("advertiseToFabric"u8); @@ -73,7 +81,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter #endif } } - writer.WriteEndObject(); } BgpAdvertisement IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpServiceLoadBalancerConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpServiceLoadBalancerConfiguration.Serialization.cs index f96c76075fd3..6cf039c676c8 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpServiceLoadBalancerConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BgpServiceLoadBalancerConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class BgpServiceLoadBalancerConfiguration : IUtf8JsonSerializable void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer throw new FormatException($"The model {nameof(BgpServiceLoadBalancerConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(BgpAdvertisements)) { writer.WritePropertyName("bgpAdvertisements"u8); @@ -76,7 +84,6 @@ void IJsonModel.Write(Utf8JsonWriter writer #endif } } - writer.WriteEndObject(); } BgpServiceLoadBalancerConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BmcKeySetList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BmcKeySetList.Serialization.cs index ba65a10b2abb..9a8770e3b66b 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BmcKeySetList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/BmcKeySetList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class BmcKeySetList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt throw new FormatException($"The model {nameof(BmcKeySetList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt #endif } } - writer.WriteEndObject(); } BmcKeySetList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/CloudServicesNetworkList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/CloudServicesNetworkList.Serialization.cs index 7ba100202f22..d579c650ec64 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/CloudServicesNetworkList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/CloudServicesNetworkList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class CloudServicesNetworkList : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead throw new FormatException($"The model {nameof(CloudServicesNetworkList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead #endif } } - writer.WriteEndObject(); } CloudServicesNetworkList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableUpgradeVersion.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableUpgradeVersion.Serialization.cs index 6a8047378a2f..7eb2bc5caf8c 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableUpgradeVersion.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableUpgradeVersion.Serialization.cs @@ -18,6 +18,15 @@ public partial class ClusterAvailableUpgradeVersion : IUtf8JsonSerializable, IJs void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod throw new FormatException($"The model {nameof(ClusterAvailableUpgradeVersion)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(ControlImpact)) { writer.WritePropertyName("controlImpact"u8); @@ -71,7 +79,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod #endif } } - writer.WriteEndObject(); } ClusterAvailableUpgradeVersion IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableVersion.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableVersion.Serialization.cs index c260309758dd..e58f49b29b9e 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableVersion.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterAvailableVersion.Serialization.cs @@ -18,6 +18,15 @@ public partial class ClusterAvailableVersion : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade throw new FormatException($"The model {nameof(ClusterAvailableVersion)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(SupportExpiryDate)) { writer.WritePropertyName("supportExpiryDate"u8); @@ -51,7 +59,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade #endif } } - writer.WriteEndObject(); } ClusterAvailableVersion IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterCapacity.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterCapacity.Serialization.cs index 9b80c6b20f47..d199a4210a7f 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterCapacity.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterCapacity.Serialization.cs @@ -18,6 +18,15 @@ public partial class ClusterCapacity : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterO throw new FormatException($"The model {nameof(ClusterCapacity)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(AvailableApplianceStorageGB)) { writer.WritePropertyName("availableApplianceStorageGB"u8); @@ -81,7 +89,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterO #endif } } - writer.WriteEndObject(); } ClusterCapacity IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterDeployContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterDeployContent.Serialization.cs index 2ab5a9ecfb5e..a2cd4bb30f41 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterDeployContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterDeployContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class ClusterDeployContent : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr throw new FormatException($"The model {nameof(ClusterDeployContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(SkipValidationsForMachines)) { writer.WritePropertyName("skipValidationsForMachines"u8); @@ -51,7 +59,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr #endif } } - writer.WriteEndObject(); } ClusterDeployContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterList.Serialization.cs index 67b53ccece24..aa1c718c4f59 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class ClusterList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio throw new FormatException($"The model {nameof(ClusterList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio #endif } } - writer.WriteEndObject(); } ClusterList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterManagerList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterManagerList.Serialization.cs index 7e90e43ef331..807137547ccf 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterManagerList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterManagerList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class ClusterManagerList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(ClusterManagerList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit #endif } } - writer.WriteEndObject(); } ClusterManagerList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterMetricsConfigurationList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterMetricsConfigurationList.Serialization.cs index 2bc161af83dd..a3035f78c659 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterMetricsConfigurationList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterMetricsConfigurationList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class ClusterMetricsConfigurationList : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo throw new FormatException($"The model {nameof(ClusterMetricsConfigurationList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo #endif } } - writer.WriteEndObject(); } ClusterMetricsConfigurationList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterUpdateVersionContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterUpdateVersionContent.Serialization.cs index bad2cf8e8536..41f536e74f70 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterUpdateVersionContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ClusterUpdateVersionContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class ClusterUpdateVersionContent : IUtf8JsonSerializable, IJsonM void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelR throw new FormatException($"The model {nameof(ClusterUpdateVersionContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("targetClusterVersion"u8); writer.WriteStringValue(TargetClusterVersion); if (options.Format != "W" && _serializedAdditionalRawData != null) @@ -43,7 +51,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelR #endif } } - writer.WriteEndObject(); } ClusterUpdateVersionContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ConsoleList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ConsoleList.Serialization.cs index 887f4c232afd..2eb8e99a27e6 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ConsoleList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ConsoleList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class ConsoleList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio throw new FormatException($"The model {nameof(ConsoleList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio #endif } } - writer.WriteEndObject(); } ConsoleList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodeConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodeConfiguration.Serialization.cs index aef570b92282..39d1e42715e0 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodeConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodeConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class ControlPlaneNodeConfiguration : IUtf8JsonSerializable, IJso void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode throw new FormatException($"The model {nameof(ControlPlaneNodeConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(AdministratorConfiguration)) { writer.WritePropertyName("administratorConfiguration"u8); @@ -60,7 +68,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode #endif } } - writer.WriteEndObject(); } ControlPlaneNodeConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodePatchConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodePatchConfiguration.Serialization.cs index 7d7aebabd860..99f70b794d4c 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodePatchConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ControlPlaneNodePatchConfiguration.Serialization.cs @@ -18,6 +18,15 @@ internal partial class ControlPlaneNodePatchConfiguration : IUtf8JsonSerializabl void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(ControlPlaneNodePatchConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(Count)) { writer.WritePropertyName("count"u8); @@ -46,7 +54,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } ControlPlaneNodePatchConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EgressEndpoint.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EgressEndpoint.Serialization.cs index f296aff5d35f..612593916f80 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EgressEndpoint.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EgressEndpoint.Serialization.cs @@ -18,6 +18,15 @@ public partial class EgressEndpoint : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOp throw new FormatException($"The model {nameof(EgressEndpoint)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("category"u8); writer.WriteStringValue(Category); writer.WritePropertyName("endpoints"u8); @@ -50,7 +58,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOp #endif } } - writer.WriteEndObject(); } EgressEndpoint IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EndpointDependency.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EndpointDependency.Serialization.cs index b1d81655b5f1..8e0605d0b55e 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EndpointDependency.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/EndpointDependency.Serialization.cs @@ -18,6 +18,15 @@ public partial class EndpointDependency : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(EndpointDependency)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("domainName"u8); writer.WriteStringValue(DomainName); if (Optional.IsDefined(Port)) @@ -48,7 +56,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit #endif } } - writer.WriteEndObject(); } EndpointDependency IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ExtendedLocation.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ExtendedLocation.Serialization.cs index 9826b11287ab..83a1d2e4791f 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ExtendedLocation.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ExtendedLocation.Serialization.cs @@ -18,6 +18,15 @@ public partial class ExtendedLocation : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter throw new FormatException($"The model {nameof(ExtendedLocation)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("name"u8); writer.WriteStringValue(Name); writer.WritePropertyName("type"u8); @@ -45,7 +53,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter #endif } } - writer.WriteEndObject(); } ExtendedLocation IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/FeatureStatus.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/FeatureStatus.Serialization.cs index 003a0be0ce79..3553eb7deb17 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/FeatureStatus.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/FeatureStatus.Serialization.cs @@ -18,6 +18,15 @@ public partial class FeatureStatus : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt throw new FormatException($"The model {nameof(FeatureStatus)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(DetailedStatus)) { writer.WritePropertyName("detailedStatus"u8); @@ -61,7 +69,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt #endif } } - writer.WriteEndObject(); } FeatureStatus IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventory.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventory.Serialization.cs index d56def870eb3..e810ad813169 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventory.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventory.Serialization.cs @@ -18,6 +18,15 @@ public partial class HardwareInventory : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrite throw new FormatException($"The model {nameof(HardwareInventory)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(AdditionalHostInformation)) { writer.WritePropertyName("additionalHostInformation"u8); @@ -66,7 +74,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrite #endif } } - writer.WriteEndObject(); } HardwareInventory IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventoryNetworkInterface.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventoryNetworkInterface.Serialization.cs index 648f16b8d6fe..9adb2b725bfc 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventoryNetworkInterface.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareInventoryNetworkInterface.Serialization.cs @@ -18,6 +18,15 @@ public partial class HardwareInventoryNetworkInterface : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(HardwareInventoryNetworkInterface)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(LinkStatus)) { writer.WritePropertyName("linkStatus"u8); @@ -61,7 +69,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } HardwareInventoryNetworkInterface IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareValidationStatus.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareValidationStatus.Serialization.cs index b54d50ac5b6e..fd48c0436d21 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareValidationStatus.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/HardwareValidationStatus.Serialization.cs @@ -18,6 +18,15 @@ public partial class HardwareValidationStatus : IUtf8JsonSerializable, IJsonMode void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead throw new FormatException($"The model {nameof(HardwareValidationStatus)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(LastValidationOn)) { writer.WritePropertyName("lastValidationTime"u8); @@ -51,7 +59,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead #endif } } - writer.WriteEndObject(); } HardwareValidationStatus IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/IPAddressPool.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/IPAddressPool.Serialization.cs index 489e0807ad6b..f02ce10063da 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/IPAddressPool.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/IPAddressPool.Serialization.cs @@ -18,6 +18,15 @@ public partial class IPAddressPool : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt throw new FormatException($"The model {nameof(IPAddressPool)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("addresses"u8); writer.WriteStartArray(); foreach (var item in Addresses) @@ -60,7 +68,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt #endif } } - writer.WriteEndObject(); } IPAddressPool IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ImageRepositoryCredentials.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ImageRepositoryCredentials.Serialization.cs index a62a6ac35a98..27522908669d 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ImageRepositoryCredentials.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ImageRepositoryCredentials.Serialization.cs @@ -18,6 +18,15 @@ public partial class ImageRepositoryCredentials : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(ImageRepositoryCredentials)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(Password)) { writer.WritePropertyName("password"u8); @@ -50,7 +58,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } ImageRepositoryCredentials IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/InitialAgentPoolConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/InitialAgentPoolConfiguration.Serialization.cs index 615b56bc5f84..dbba8073e9dd 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/InitialAgentPoolConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/InitialAgentPoolConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class InitialAgentPoolConfiguration : IUtf8JsonSerializable, IJso void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode throw new FormatException($"The model {nameof(InitialAgentPoolConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(AdministratorConfiguration)) { writer.WritePropertyName("administratorConfiguration"u8); @@ -99,7 +107,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode #endif } } - writer.WriteEndObject(); } InitialAgentPoolConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUser.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUser.Serialization.cs index 559277e1f4da..a2e07e3667b6 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUser.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUser.Serialization.cs @@ -18,6 +18,15 @@ public partial class KeySetUser : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOption throw new FormatException($"The model {nameof(KeySetUser)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("azureUserName"u8); writer.WriteStringValue(AzureUserName); if (Optional.IsDefined(Description)) @@ -50,7 +58,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOption #endif } } - writer.WriteEndObject(); } KeySetUser IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUserStatus.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUserStatus.Serialization.cs index 5d520d6ad6ca..2a3cf026af60 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUserStatus.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KeySetUserStatus.Serialization.cs @@ -18,6 +18,15 @@ public partial class KeySetUserStatus : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter throw new FormatException($"The model {nameof(KeySetUserStatus)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(AzureUserName)) { writer.WritePropertyName("azureUserName"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter #endif } } - writer.WriteEndObject(); } KeySetUserStatus IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterList.Serialization.cs index f5666459a489..9f376a2706a3 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class KubernetesClusterList : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderW throw new FormatException($"The model {nameof(KubernetesClusterList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderW #endif } } - writer.WriteEndObject(); } KubernetesClusterList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNetworkConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNetworkConfiguration.Serialization.cs index c735371a3166..5311e6fa18fd 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNetworkConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNetworkConfiguration.Serialization.cs @@ -19,6 +19,15 @@ public partial class KubernetesClusterNetworkConfiguration : IUtf8JsonSerializab void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -26,7 +35,6 @@ void IJsonModel.Write(Utf8JsonWriter writ throw new FormatException($"The model {nameof(KubernetesClusterNetworkConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(AttachedNetworkConfiguration)) { writer.WritePropertyName("attachedNetworkConfiguration"u8); @@ -81,7 +89,6 @@ void IJsonModel.Write(Utf8JsonWriter writ #endif } } - writer.WriteEndObject(); } KubernetesClusterNetworkConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNode.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNode.Serialization.cs index 343fa36dd3d1..73dd50e7e3cf 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNode.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterNode.Serialization.cs @@ -18,6 +18,15 @@ public partial class KubernetesClusterNode : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderW throw new FormatException($"The model {nameof(KubernetesClusterNode)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(AgentPoolId)) { writer.WritePropertyName("agentPoolId"u8); @@ -146,7 +154,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderW #endif } } - writer.WriteEndObject(); } KubernetesClusterNode IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterRestartNodeContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterRestartNodeContent.Serialization.cs index 6a6b390d10f7..d81e8307bafc 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterRestartNodeContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesClusterRestartNodeContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class KubernetesClusterRestartNodeContent : IUtf8JsonSerializable void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer throw new FormatException($"The model {nameof(KubernetesClusterRestartNodeContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("nodeName"u8); writer.WriteStringValue(NodeName); if (options.Format != "W" && _serializedAdditionalRawData != null) @@ -43,7 +51,6 @@ void IJsonModel.Write(Utf8JsonWriter writer #endif } } - writer.WriteEndObject(); } KubernetesClusterRestartNodeContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesLabel.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesLabel.Serialization.cs index e16639be5b25..4dde87f9f80e 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesLabel.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/KubernetesLabel.Serialization.cs @@ -18,6 +18,15 @@ public partial class KubernetesLabel : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterO throw new FormatException($"The model {nameof(KubernetesLabel)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("key"u8); writer.WriteStringValue(Key); writer.WritePropertyName("value"u8); @@ -45,7 +53,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterO #endif } } - writer.WriteEndObject(); } KubernetesLabel IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkAttachmentConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkAttachmentConfiguration.Serialization.cs index 6d14fa7f052d..5f3c468abdaf 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkAttachmentConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkAttachmentConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class L2NetworkAttachmentConfiguration : IUtf8JsonSerializable, I void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, M throw new FormatException($"The model {nameof(L2NetworkAttachmentConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("networkId"u8); writer.WriteStringValue(NetworkId); if (Optional.IsDefined(PluginType)) @@ -48,7 +56,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, M #endif } } - writer.WriteEndObject(); } L2NetworkAttachmentConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkList.Serialization.cs index 361b7a0339e8..5d2cafee53f3 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L2NetworkList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class L2NetworkList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt throw new FormatException($"The model {nameof(L2NetworkList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt #endif } } - writer.WriteEndObject(); } L2NetworkList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkAttachmentConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkAttachmentConfiguration.Serialization.cs index 7d85a9fed708..3f5afd3c0568 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkAttachmentConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkAttachmentConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class L3NetworkAttachmentConfiguration : IUtf8JsonSerializable, I void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, M throw new FormatException($"The model {nameof(L3NetworkAttachmentConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(IpamEnabled)) { writer.WritePropertyName("ipamEnabled"u8); @@ -53,7 +61,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, M #endif } } - writer.WriteEndObject(); } L3NetworkAttachmentConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkList.Serialization.cs index 643251924751..0ee50ff3c724 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/L3NetworkList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class L3NetworkList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt throw new FormatException($"The model {nameof(L3NetworkList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt #endif } } - writer.WriteEndObject(); } L3NetworkList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/LldpNeighbor.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/LldpNeighbor.Serialization.cs index cb2bc99c3b2e..28b0fb4efef4 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/LldpNeighbor.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/LldpNeighbor.Serialization.cs @@ -18,6 +18,15 @@ public partial class LldpNeighbor : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpti throw new FormatException($"The model {nameof(LldpNeighbor)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(PortDescription)) { writer.WritePropertyName("portDescription"u8); @@ -61,7 +69,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpti #endif } } - writer.WriteEndObject(); } LldpNeighbor IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineDisk.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineDisk.Serialization.cs index df80bd8ac706..caf3bfbb3325 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineDisk.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineDisk.Serialization.cs @@ -18,6 +18,15 @@ public partial class MachineDisk : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio throw new FormatException($"The model {nameof(MachineDisk)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(CapacityGB)) { writer.WritePropertyName("capacityGB"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio #endif } } - writer.WriteEndObject(); } MachineDisk IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineSkuSlot.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineSkuSlot.Serialization.cs index 6b30b2d6f90c..b477d211d0fc 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineSkuSlot.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/MachineSkuSlot.Serialization.cs @@ -18,6 +18,15 @@ public partial class MachineSkuSlot : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOp throw new FormatException($"The model {nameof(MachineSkuSlot)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(RackSlot)) { writer.WritePropertyName("rackSlot"u8); @@ -114,7 +122,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOp #endif } } - writer.WriteEndObject(); } MachineSkuSlot IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ManagedResourceGroupConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ManagedResourceGroupConfiguration.Serialization.cs index 608a08e7161e..1c7e47b1eacf 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ManagedResourceGroupConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ManagedResourceGroupConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class ManagedResourceGroupConfiguration : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(ManagedResourceGroupConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(Location)) { writer.WritePropertyName("location"u8); @@ -51,7 +59,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } ManagedResourceGroupConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkAttachment.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkAttachment.Serialization.cs index 5e559075c7fe..3f3d1523dc44 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkAttachment.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkAttachment.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkAttachment : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrite throw new FormatException($"The model {nameof(NetworkAttachment)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("attachedNetworkId"u8); writer.WriteStringValue(AttachedNetworkId); if (Optional.IsDefined(DefaultGateway)) @@ -70,7 +78,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrite #endif } } - writer.WriteEndObject(); } NetworkAttachment IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAadConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAadConfiguration.Serialization.cs index 593e8e268bf5..ab5b8c72b1af 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAadConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAadConfiguration.Serialization.cs @@ -18,6 +18,15 @@ internal partial class NetworkCloudAadConfiguration : IUtf8JsonSerializable, IJs void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Model throw new FormatException($"The model {nameof(NetworkCloudAadConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("adminGroupObjectIds"u8); writer.WriteStartArray(); foreach (var item in AdminGroupObjectIds) @@ -48,7 +56,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Model #endif } } - writer.WriteEndObject(); } NetworkCloudAadConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentConfiguration.Serialization.cs index e4a3ffe03610..9e6e6d1a23e8 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudAgentConfiguration : IUtf8JsonSerializable, IJs void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod throw new FormatException($"The model {nameof(NetworkCloudAgentConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("hugepagesCount"u8); writer.WriteNumberValue(HugepagesCount); if (Optional.IsDefined(HugepagesSize)) @@ -48,7 +56,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod #endif } } - writer.WriteEndObject(); } NetworkCloudAgentConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentPoolPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentPoolPatch.Serialization.cs index 83faf0579e08..791fb521cccf 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentPoolPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudAgentPoolPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudAgentPoolPatch : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(NetworkCloudAgentPoolPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -65,7 +73,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } NetworkCloudAgentPoolPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachineKeySetPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachineKeySetPatch.Serialization.cs index b43874039e11..e33f77859ba8 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachineKeySetPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachineKeySetPatch.Serialization.cs @@ -19,6 +19,15 @@ public partial class NetworkCloudBareMetalMachineKeySetPatch : IUtf8JsonSerializ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -26,7 +35,6 @@ void IJsonModel.Write(Utf8JsonWriter wr throw new FormatException($"The model {nameof(NetworkCloudBareMetalMachineKeySetPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -86,7 +94,6 @@ void IJsonModel.Write(Utf8JsonWriter wr #endif } } - writer.WriteEndObject(); } NetworkCloudBareMetalMachineKeySetPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachinePatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachinePatch.Serialization.cs index 441b3744284b..ea4de1a9f2d7 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachinePatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBareMetalMachinePatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudBareMetalMachinePatch : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(NetworkCloudBareMetalMachinePatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -60,7 +68,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } NetworkCloudBareMetalMachinePatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBmcKeySetPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBmcKeySetPatch.Serialization.cs index 4bb4696e66d0..de03c6f18790 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBmcKeySetPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudBmcKeySetPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudBmcKeySetPatch : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(NetworkCloudBmcKeySetPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -70,7 +78,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } NetworkCloudBmcKeySetPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudCloudServicesNetworkPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudCloudServicesNetworkPatch.Serialization.cs index d5b86c7be875..1531c703d7e5 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudCloudServicesNetworkPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudCloudServicesNetworkPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudCloudServicesNetworkPatch : IUtf8JsonSerializab void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writ throw new FormatException($"The model {nameof(NetworkCloudCloudServicesNetworkPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -70,7 +78,6 @@ void IJsonModel.Write(Utf8JsonWriter writ #endif } } - writer.WriteEndObject(); } NetworkCloudCloudServicesNetworkPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterManagerPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterManagerPatch.Serialization.cs index e57f789a31b1..0c57595a0815 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterManagerPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterManagerPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudClusterManagerPatch : IUtf8JsonSerializable, IJ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo throw new FormatException($"The model {nameof(NetworkCloudClusterManagerPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -52,7 +60,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo #endif } } - writer.WriteEndObject(); } NetworkCloudClusterManagerPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterMetricsConfigurationPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterMetricsConfigurationPatch.Serialization.cs index 7d4c2cf650c4..dedf46dba957 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterMetricsConfigurationPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterMetricsConfigurationPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudClusterMetricsConfigurationPatch : IUtf8JsonSer void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWrit throw new FormatException($"The model {nameof(NetworkCloudClusterMetricsConfigurationPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -70,7 +78,6 @@ void IJsonModel.Write(Utf8JsonWrit #endif } } - writer.WriteEndObject(); } NetworkCloudClusterMetricsConfigurationPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterPatch.Serialization.cs index 4d42542720c9..c5f32e0907e5 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudClusterPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudClusterPatch : IUtf8JsonSerializable, IJsonMode void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead throw new FormatException($"The model {nameof(NetworkCloudClusterPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -85,7 +93,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead #endif } } - writer.WriteEndObject(); } NetworkCloudClusterPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudKubernetesClusterPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudKubernetesClusterPatch.Serialization.cs index 05bfe187b601..28728ce1d60c 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudKubernetesClusterPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudKubernetesClusterPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudKubernetesClusterPatch : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(NetworkCloudKubernetesClusterPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -65,7 +73,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } NetworkCloudKubernetesClusterPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL2NetworkPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL2NetworkPatch.Serialization.cs index de21f1025b26..36e6ffc8606c 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL2NetworkPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL2NetworkPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudL2NetworkPatch : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(NetworkCloudL2NetworkPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -52,7 +60,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } NetworkCloudL2NetworkPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL3NetworkPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL3NetworkPatch.Serialization.cs index 8e652a3a85c2..a855d9e8b714 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL3NetworkPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudL3NetworkPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudL3NetworkPatch : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(NetworkCloudL3NetworkPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -52,7 +60,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } NetworkCloudL3NetworkPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNetworkInterface.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNetworkInterface.Serialization.cs index 7f7942c61fa4..55e52383774b 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNetworkInterface.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNetworkInterface.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudNetworkInterface : IUtf8JsonSerializable, IJson void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Model throw new FormatException($"The model {nameof(NetworkCloudNetworkInterface)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(Address)) { writer.WritePropertyName("address"u8); @@ -76,7 +84,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Model #endif } } - writer.WriteEndObject(); } NetworkCloudNetworkInterface IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNic.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNic.Serialization.cs index e08faee3377e..ac0674894a9a 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNic.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudNic.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudNic : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterO throw new FormatException($"The model {nameof(NetworkCloudNic)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(LldpNeighbor)) { writer.WritePropertyName("lldpNeighbor"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterO #endif } } - writer.WriteEndObject(); } NetworkCloudNic IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOSDisk.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOSDisk.Serialization.cs index 38fbaa852eeb..8587aef3793c 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOSDisk.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOSDisk.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudOSDisk : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(NetworkCloudOSDisk)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(CreateOption)) { writer.WritePropertyName("createOption"u8); @@ -53,7 +61,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit #endif } } - writer.WriteEndObject(); } NetworkCloudOSDisk IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOperationStatusResult.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOperationStatusResult.Serialization.cs index b13cdba13c87..b5466583d8f6 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOperationStatusResult.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudOperationStatusResult.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudOperationStatusResult : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(NetworkCloudOperationStatusResult)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(Id)) { writer.WritePropertyName("id"u8); @@ -88,7 +96,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } NetworkCloudOperationStatusResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackDefinition.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackDefinition.Serialization.cs index 0acb725c3b05..577d67ad9797 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackDefinition.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackDefinition.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudRackDefinition : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(NetworkCloudRackDefinition)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(AvailabilityZone)) { writer.WritePropertyName("availabilityZone"u8); @@ -77,7 +85,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } NetworkCloudRackDefinition IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackPatch.Serialization.cs index 585b28e7b98a..1ffec87abfe4 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudRackPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudRackPatch : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderW throw new FormatException($"The model {nameof(NetworkCloudRackPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -65,7 +73,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderW #endif } } - writer.WriteEndObject(); } NetworkCloudRackPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudSshPublicKey.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudSshPublicKey.Serialization.cs index b29e456659e5..ebe4188f4635 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudSshPublicKey.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudSshPublicKey.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudSshPublicKey : IUtf8JsonSerializable, IJsonMode void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead throw new FormatException($"The model {nameof(NetworkCloudSshPublicKey)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("keyData"u8); writer.WriteStringValue(KeyData); if (options.Format != "W" && _serializedAdditionalRawData != null) @@ -43,7 +51,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead #endif } } - writer.WriteEndObject(); } NetworkCloudSshPublicKey IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageAppliancePatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageAppliancePatch.Serialization.cs index 7bf8347b84c1..31b2995f2c87 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageAppliancePatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageAppliancePatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudStorageAppliancePatch : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(NetworkCloudStorageAppliancePatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -60,7 +68,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, #endif } } - writer.WriteEndObject(); } NetworkCloudStorageAppliancePatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageProfile.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageProfile.Serialization.cs index ee6264f2b653..a63cca16304e 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageProfile.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudStorageProfile.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudStorageProfile : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(NetworkCloudStorageProfile)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("osDisk"u8); writer.WriteObjectValue(OSDisk, options); if (Optional.IsCollectionDefined(VolumeAttachments)) @@ -58,7 +66,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } NetworkCloudStorageProfile IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudTrunkedNetworkPatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudTrunkedNetworkPatch.Serialization.cs index bf4a60f9de93..e8d54b6a99fb 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudTrunkedNetworkPatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudTrunkedNetworkPatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudTrunkedNetworkPatch : IUtf8JsonSerializable, IJ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo throw new FormatException($"The model {nameof(NetworkCloudTrunkedNetworkPatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -52,7 +60,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo #endif } } - writer.WriteEndObject(); } NetworkCloudTrunkedNetworkPatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachineConsolePatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachineConsolePatch.Serialization.cs index b63d231095ac..3a9d884ad9b9 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachineConsolePatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachineConsolePatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudVirtualMachineConsolePatch : IUtf8JsonSerializa void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter wri throw new FormatException($"The model {nameof(NetworkCloudVirtualMachineConsolePatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -70,7 +78,6 @@ void IJsonModel.Write(Utf8JsonWriter wri #endif } } - writer.WriteEndObject(); } NetworkCloudVirtualMachineConsolePatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachinePatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachinePatch.Serialization.cs index 340b7856427f..1db07ff5c207 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachinePatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVirtualMachinePatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudVirtualMachinePatch : IUtf8JsonSerializable, IJ void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo throw new FormatException($"The model {nameof(NetworkCloudVirtualMachinePatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -60,7 +68,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo #endif } } - writer.WriteEndObject(); } NetworkCloudVirtualMachinePatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVolumePatch.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVolumePatch.Serialization.cs index 37bc66c367e4..be8f926cb864 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVolumePatch.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/NetworkCloudVolumePatch.Serialization.cs @@ -18,6 +18,15 @@ public partial class NetworkCloudVolumePatch : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade throw new FormatException($"The model {nameof(NetworkCloudVolumePatch)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(Tags)) { writer.WritePropertyName("tags"u8); @@ -52,7 +60,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade #endif } } - writer.WriteEndObject(); } NetworkCloudVolumePatch IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackList.Serialization.cs index ed4ed00297af..1b140fd4b6ae 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class RackList : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions throw new FormatException($"The model {nameof(RackList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions #endif } } - writer.WriteEndObject(); } RackList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackSkuList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackSkuList.Serialization.cs index 11ffff72cb1e..21bb382d1c05 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackSkuList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/RackSkuList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class RackSkuList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio throw new FormatException($"The model {nameof(RackSkuList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptio #endif } } - writer.WriteEndObject(); } RackSkuList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServiceLoadBalancerBgpPeer.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServiceLoadBalancerBgpPeer.Serialization.cs index 4a141ac3a9cb..483b3e81bfe3 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServiceLoadBalancerBgpPeer.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServiceLoadBalancerBgpPeer.Serialization.cs @@ -18,6 +18,15 @@ public partial class ServiceLoadBalancerBgpPeer : IUtf8JsonSerializable, IJsonMo void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe throw new FormatException($"The model {nameof(ServiceLoadBalancerBgpPeer)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(BfdEnabled)) { writer.WritePropertyName("bfdEnabled"u8); @@ -82,7 +90,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe #endif } } - writer.WriteEndObject(); } ServiceLoadBalancerBgpPeer IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServicePrincipalInformation.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServicePrincipalInformation.Serialization.cs index a536d309404d..35cad3b20cc5 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServicePrincipalInformation.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ServicePrincipalInformation.Serialization.cs @@ -18,6 +18,15 @@ public partial class ServicePrincipalInformation : IUtf8JsonSerializable, IJsonM void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelR throw new FormatException($"The model {nameof(ServicePrincipalInformation)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("applicationId"u8); writer.WriteStringValue(ApplicationId); if (Optional.IsDefined(Password)) @@ -52,7 +60,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelR #endif } } - writer.WriteEndObject(); } ServicePrincipalInformation IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceConfiguration.Serialization.cs index 6efb2caf5321..2314403db64f 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class StorageApplianceConfiguration : IUtf8JsonSerializable, IJso void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode throw new FormatException($"The model {nameof(StorageApplianceConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("adminCredentials"u8); writer.WriteObjectValue(AdminCredentials, options); writer.WritePropertyName("rackSlot"u8); @@ -52,7 +60,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode #endif } } - writer.WriteEndObject(); } StorageApplianceConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceEnableRemoteVendorManagementContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceEnableRemoteVendorManagementContent.Serialization.cs index d0aa5e9fcb33..de89929d8646 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceEnableRemoteVendorManagementContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceEnableRemoteVendorManagementContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class StorageApplianceEnableRemoteVendorManagementContent : IUtf8 void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8J throw new FormatException($"The model {nameof(StorageApplianceEnableRemoteVendorManagementContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsCollectionDefined(SupportEndpoints)) { writer.WritePropertyName("supportEndpoints"u8); @@ -51,7 +59,6 @@ void IJsonModel.Write(Utf8J #endif } } - writer.WriteEndObject(); } StorageApplianceEnableRemoteVendorManagementContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceList.Serialization.cs index c463ef907eb5..bffc0984fbe3 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class StorageApplianceList : IUtf8JsonSerializable, IJsonModel< void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr throw new FormatException($"The model {nameof(StorageApplianceList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr #endif } } - writer.WriteEndObject(); } StorageApplianceList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceSkuSlot.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceSkuSlot.Serialization.cs index 89d7e6bf6f9c..2ba2742dd993 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceSkuSlot.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/StorageApplianceSkuSlot.Serialization.cs @@ -18,6 +18,15 @@ public partial class StorageApplianceSkuSlot : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade throw new FormatException($"The model {nameof(StorageApplianceSkuSlot)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(RackSlot)) { writer.WritePropertyName("rackSlot"u8); @@ -59,7 +67,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade #endif } } - writer.WriteEndObject(); } StorageApplianceSkuSlot IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkAttachmentConfiguration.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkAttachmentConfiguration.Serialization.cs index 39c64f523118..46dadcfca87b 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkAttachmentConfiguration.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkAttachmentConfiguration.Serialization.cs @@ -18,6 +18,15 @@ public partial class TrunkedNetworkAttachmentConfiguration : IUtf8JsonSerializab void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writ throw new FormatException($"The model {nameof(TrunkedNetworkAttachmentConfiguration)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("networkId"u8); writer.WriteStringValue(NetworkId); if (Optional.IsDefined(PluginType)) @@ -48,7 +56,6 @@ void IJsonModel.Write(Utf8JsonWriter writ #endif } } - writer.WriteEndObject(); } TrunkedNetworkAttachmentConfiguration IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkList.Serialization.cs index 8af1f124bdc5..ae61c91b92bb 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/TrunkedNetworkList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class TrunkedNetworkList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(TrunkedNetworkList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit #endif } } - writer.WriteEndObject(); } TrunkedNetworkList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ValidationThreshold.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ValidationThreshold.Serialization.cs index e3a81095adb4..07a300aafd76 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ValidationThreshold.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/ValidationThreshold.Serialization.cs @@ -18,6 +18,15 @@ public partial class ValidationThreshold : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWri throw new FormatException($"The model {nameof(ValidationThreshold)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("grouping"u8); writer.WriteStringValue(Grouping.ToString()); writer.WritePropertyName("type"u8); @@ -47,7 +55,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWri #endif } } - writer.WriteEndObject(); } ValidationThreshold IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachineList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachineList.Serialization.cs index 311a45e5e1ad..cb359d87d6f7 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachineList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachineList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class VirtualMachineList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(VirtualMachineList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWrit #endif } } - writer.WriteEndObject(); } VirtualMachineList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePlacementHint.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePlacementHint.Serialization.cs index 0f966ac88175..7dc9ce8cf3e0 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePlacementHint.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePlacementHint.Serialization.cs @@ -18,6 +18,15 @@ public partial class VirtualMachinePlacementHint : IUtf8JsonSerializable, IJsonM void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelR throw new FormatException($"The model {nameof(VirtualMachinePlacementHint)} does not support writing '{format}' format."); } - writer.WriteStartObject(); writer.WritePropertyName("hintType"u8); writer.WriteStringValue(HintType.ToString()); writer.WritePropertyName("resourceId"u8); @@ -49,7 +57,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelR #endif } } - writer.WriteEndObject(); } VirtualMachinePlacementHint IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePowerOffContent.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePowerOffContent.Serialization.cs index 8db8276cb677..946aa66f52cf 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePowerOffContent.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VirtualMachinePowerOffContent.Serialization.cs @@ -18,6 +18,15 @@ public partial class VirtualMachinePowerOffContent : IUtf8JsonSerializable, IJso void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode throw new FormatException($"The model {nameof(VirtualMachinePowerOffContent)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(SkipShutdown)) { writer.WritePropertyName("skipShutdown"u8); @@ -46,7 +54,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode #endif } } - writer.WriteEndObject(); } VirtualMachinePowerOffContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VolumeList.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VolumeList.Serialization.cs index 83fe919cdc80..1915a762692c 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VolumeList.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/Models/VolumeList.Serialization.cs @@ -18,6 +18,15 @@ internal partial class VolumeList : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -25,7 +34,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOption throw new FormatException($"The model {nameof(VolumeList)} does not support writing '{format}' format."); } - writer.WriteStartObject(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); @@ -56,7 +64,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOption #endif } } - writer.WriteEndObject(); } VolumeList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudAgentPoolData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudAgentPoolData.Serialization.cs index 56459ddb998a..b84b900d61ce 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudAgentPoolData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudAgentPoolData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudAgentPoolData : IUtf8JsonSerializable, IJsonMod void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,45 +36,12 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea throw new FormatException($"The model {nameof(NetworkCloudAgentPoolData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); if (Optional.IsDefined(ExtendedLocation)) { writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); } - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (Optional.IsDefined(AdministratorConfiguration)) @@ -145,22 +121,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea writer.WritePropertyName("vmSkuName"u8); writer.WriteStringValue(VmSkuName); writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudAgentPoolData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineData.Serialization.cs index f22273fe52c1..024f5efe09db 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineData.Serialization.cs @@ -21,6 +21,15 @@ public partial class NetworkCloudBareMetalMachineData : IUtf8JsonSerializable, I void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -28,42 +37,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, M throw new FormatException($"The model {nameof(NetworkCloudBareMetalMachineData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (options.Format != "W" && Optional.IsCollectionDefined(AssociatedResourceIds)) @@ -197,22 +173,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, M writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudBareMetalMachineData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineKeySetData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineKeySetData.Serialization.cs index 250da77c6680..4729b4c504aa 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineKeySetData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBareMetalMachineKeySetData.Serialization.cs @@ -21,6 +21,15 @@ public partial class NetworkCloudBareMetalMachineKeySetData : IUtf8JsonSerializa void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -28,42 +37,9 @@ void IJsonModel.Write(Utf8JsonWriter wri throw new FormatException($"The model {nameof(NetworkCloudBareMetalMachineKeySetData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); writer.WritePropertyName("azureGroupId"u8); @@ -127,22 +103,6 @@ void IJsonModel.Write(Utf8JsonWriter wri writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudBareMetalMachineKeySetData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBmcKeySetData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBmcKeySetData.Serialization.cs index 056a3b77c6c8..b180da710da9 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBmcKeySetData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudBmcKeySetData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudBmcKeySetData : IUtf8JsonSerializable, IJsonMod void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea throw new FormatException($"The model {nameof(NetworkCloudBmcKeySetData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); writer.WritePropertyName("azureGroupId"u8); @@ -109,22 +85,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudBmcKeySetData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudCloudServicesNetworkData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudCloudServicesNetworkData.Serialization.cs index 591d6c3d0945..8dc0565bff78 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudCloudServicesNetworkData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudCloudServicesNetworkData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudCloudServicesNetworkData : IUtf8JsonSerializabl void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter write throw new FormatException($"The model {nameof(NetworkCloudCloudServicesNetworkData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (Optional.IsCollectionDefined(AdditionalEgressEndpoints)) @@ -161,22 +137,6 @@ void IJsonModel.Write(Utf8JsonWriter write writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudCloudServicesNetworkData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterData.Serialization.cs index f5fdd0fe778f..b2dcfbc3be64 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudClusterData : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade throw new FormatException($"The model {nameof(NetworkCloudClusterData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); writer.WritePropertyName("aggregatorOrSingleRackDefinition"u8); @@ -189,22 +165,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudClusterData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterManagerData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterManagerData.Serialization.cs index 06e36581d250..ecfcd28db6c1 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterManagerData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterManagerData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudClusterManagerData : IUtf8JsonSerializable, IJs void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,40 +36,7 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod throw new FormatException($"The model {nameof(NetworkCloudClusterManagerData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (Optional.IsDefined(AnalyticsWorkspaceId)) @@ -121,22 +97,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod writer.WriteStringValue(VmSize); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudClusterManagerData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterMetricsConfigurationData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterMetricsConfigurationData.Serialization.cs index 58742100a4bb..d8f5562b38c6 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterMetricsConfigurationData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudClusterMetricsConfigurationData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudClusterMetricsConfigurationData : IUtf8JsonSeri void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWrite throw new FormatException($"The model {nameof(NetworkCloudClusterMetricsConfigurationData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); writer.WritePropertyName("collectionInterval"u8); @@ -103,22 +79,6 @@ void IJsonModel.Write(Utf8JsonWrite writer.WriteStringValue(ProvisioningState.Value.ToString()); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudClusterMetricsConfigurationData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudKubernetesClusterData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudKubernetesClusterData.Serialization.cs index 814c02b824c9..3a3af907d40b 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudKubernetesClusterData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudKubernetesClusterData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudKubernetesClusterData : IUtf8JsonSerializable, void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, throw new FormatException($"The model {nameof(NetworkCloudKubernetesClusterData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (Optional.IsDefined(AadConfiguration)) @@ -169,22 +145,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, writer.WriteStringValue(ProvisioningState.Value.ToString()); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudKubernetesClusterData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL2NetworkData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL2NetworkData.Serialization.cs index 15ec7ce01940..f706e5f37eb1 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL2NetworkData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL2NetworkData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudL2NetworkData : IUtf8JsonSerializable, IJsonMod void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea throw new FormatException($"The model {nameof(NetworkCloudL2NetworkData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (options.Format != "W" && Optional.IsCollectionDefined(AssociatedResourceIds)) @@ -143,22 +119,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudL2NetworkData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL3NetworkData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL3NetworkData.Serialization.cs index bd4057161c70..b40c3aeddd2d 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL3NetworkData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudL3NetworkData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudL3NetworkData : IUtf8JsonSerializable, IJsonMod void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea throw new FormatException($"The model {nameof(NetworkCloudL3NetworkData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (options.Format != "W" && Optional.IsCollectionDefined(AssociatedResourceIds)) @@ -165,22 +141,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea writer.WritePropertyName("vlan"u8); writer.WriteNumberValue(Vlan); writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudL3NetworkData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackData.Serialization.cs index 6848200e3dff..e71ad92d1782 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudRackData : IUtf8JsonSerializable, IJsonModel ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr throw new FormatException($"The model {nameof(NetworkCloudRackData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); writer.WritePropertyName("availabilityZone"u8); @@ -94,22 +70,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr writer.WritePropertyName("rackSkuId"u8); writer.WriteStringValue(RackSkuId); writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudRackData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackSkuData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackSkuData.Serialization.cs index dd820de1335a..8ee031c26f3f 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackSkuData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudRackSkuData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudRackSkuData : IUtf8JsonSerializable, IJsonModel void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,27 +36,7 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade throw new FormatException($"The model {nameof(NetworkCloudRackSkuData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (options.Format != "W" && Optional.IsCollectionDefined(ComputeMachines)) @@ -111,22 +100,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudRackSkuData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudStorageApplianceData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudStorageApplianceData.Serialization.cs index 71d59133b843..4c1445010b8b 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudStorageApplianceData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudStorageApplianceData.Serialization.cs @@ -21,6 +21,15 @@ public partial class NetworkCloudStorageApplianceData : IUtf8JsonSerializable, I void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -28,42 +37,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, M throw new FormatException($"The model {nameof(NetworkCloudStorageApplianceData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); writer.WritePropertyName("administratorCredentials"u8); @@ -122,22 +98,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, M writer.WritePropertyName("storageApplianceSkuId"u8); writer.WriteStringValue(StorageApplianceSkuId); writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudStorageApplianceData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudTrunkedNetworkData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudTrunkedNetworkData.Serialization.cs index 9dd763eed45a..f0f888f4a951 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudTrunkedNetworkData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudTrunkedNetworkData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudTrunkedNetworkData : IUtf8JsonSerializable, IJs void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod throw new FormatException($"The model {nameof(NetworkCloudTrunkedNetworkData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (options.Format != "W" && Optional.IsCollectionDefined(AssociatedResourceIds)) @@ -155,22 +131,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod } writer.WriteEndArray(); writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudTrunkedNetworkData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineConsoleData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineConsoleData.Serialization.cs index 6a717407beda..055512674a72 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineConsoleData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineConsoleData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudVirtualMachineConsoleData : IUtf8JsonSerializab void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writ throw new FormatException($"The model {nameof(NetworkCloudVirtualMachineConsoleData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (options.Format != "W" && Optional.IsDefined(DetailedStatus)) @@ -100,22 +76,6 @@ void IJsonModel.Write(Utf8JsonWriter writ writer.WriteStringValue(VirtualMachineAccessId.Value); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudVirtualMachineConsoleData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineData.Serialization.cs index 832eb1f927cf..75d50251cf16 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVirtualMachineData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudVirtualMachineData : IUtf8JsonSerializable, IJs void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod throw new FormatException($"The model {nameof(NetworkCloudVirtualMachineData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); writer.WritePropertyName("adminUsername"u8); @@ -193,22 +169,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod writer.WriteEndArray(); } writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudVirtualMachineData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVolumeData.Serialization.cs b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVolumeData.Serialization.cs index 9cd2c1668d15..294f93b7f72c 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVolumeData.Serialization.cs +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/Generated/NetworkCloudVolumeData.Serialization.cs @@ -20,6 +20,15 @@ public partial class NetworkCloudVolumeData : IUtf8JsonSerializable, IJsonModel< void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + { + writer.WriteStartObject(); + JsonModelWriteCore(writer, options); + writer.WriteEndObject(); + } + + /// The JSON writer. + /// The client options for reading and writing models. + protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options) { var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") @@ -27,42 +36,9 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReader throw new FormatException($"The model {nameof(NetworkCloudVolumeData)} does not support writing '{format}' format."); } - writer.WriteStartObject(); + base.JsonModelWriteCore(writer, options); writer.WritePropertyName("extendedLocation"u8); writer.WriteObjectValue(ExtendedLocation, options); - if (Optional.IsCollectionDefined(Tags)) - { - writer.WritePropertyName("tags"u8); - writer.WriteStartObject(); - foreach (var item in Tags) - { - writer.WritePropertyName(item.Key); - writer.WriteStringValue(item.Value); - } - writer.WriteEndObject(); - } - writer.WritePropertyName("location"u8); - writer.WriteStringValue(Location); - if (options.Format != "W") - { - writer.WritePropertyName("id"u8); - writer.WriteStringValue(Id); - } - if (options.Format != "W") - { - writer.WritePropertyName("name"u8); - writer.WriteStringValue(Name); - } - if (options.Format != "W") - { - writer.WritePropertyName("type"u8); - writer.WriteStringValue(ResourceType); - } - if (options.Format != "W" && Optional.IsDefined(SystemData)) - { - writer.WritePropertyName("systemData"u8); - JsonSerializer.Serialize(writer, SystemData); - } writer.WritePropertyName("properties"u8); writer.WriteStartObject(); if (options.Format != "W" && Optional.IsCollectionDefined(AttachedTo)) @@ -98,22 +74,6 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReader writer.WritePropertyName("sizeMiB"u8); writer.WriteNumberValue(SizeInMiB); writer.WriteEndObject(); - if (options.Format != "W" && _serializedAdditionalRawData != null) - { - foreach (var item in _serializedAdditionalRawData) - { - writer.WritePropertyName(item.Key); -#if NET6_0_OR_GREATER - writer.WriteRawValue(item.Value); -#else - using (JsonDocument document = JsonDocument.Parse(item.Value)) - { - JsonSerializer.Serialize(writer, document.RootElement); - } -#endif - } - } - writer.WriteEndObject(); } NetworkCloudVolumeData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) diff --git a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/autorest.md b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/autorest.md index 16356e8ea51f..018973dbbb22 100644 --- a/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/autorest.md +++ b/sdk/networkcloud/Azure.ResourceManager.NetworkCloud/src/autorest.md @@ -18,6 +18,7 @@ skip-csproj: true modelerfour: flatten-payloads: false use-model-reader-writer: true +use-write-core: true # mgmt-debug: # show-serialized-names: true