diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/IPublicIpAddressesOperations.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/IPublicIPAddressesOperations.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/IPublicIpAddressesOperations.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/IPublicIPAddressesOperations.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/IVirtualWANsOperations.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/IVirtualWansOperations.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/IVirtualWANsOperations.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/IVirtualWansOperations.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayAutoscaleConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayAutoscaleConfiguration.cs index 310e30ea48b3..feca79d52be4 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayAutoscaleConfiguration.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayAutoscaleConfiguration.cs @@ -72,12 +72,9 @@ public virtual void Validate() { throw new ValidationException(ValidationRules.InclusiveMinimum, "MinCapacity", 0); } - if (MaxCapacity != null) + if (MaxCapacity < 2) { - if (MaxCapacity < 2) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxCapacity", 2); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxCapacity", 2); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayFrontendIpConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayFrontendIPConfiguration.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayFrontendIpConfiguration.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayFrontendIPConfiguration.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayIpConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayIPConfiguration.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayIpConfiguration.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayIPConfiguration.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayLoadDistributionTarget.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayLoadDistributionTarget.cs index 8ddb867b2931..fba64610be6e 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayLoadDistributionTarget.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayLoadDistributionTarget.cs @@ -101,16 +101,13 @@ public ApplicationGatewayLoadDistributionTarget() /// public virtual void Validate() { - if (WeightPerServer != null) + if (WeightPerServer > 100) { - if (WeightPerServer > 100) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "WeightPerServer", 100); - } - if (WeightPerServer < 1) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "WeightPerServer", 1); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "WeightPerServer", 100); + } + if (WeightPerServer < 1) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "WeightPerServer", 1); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayProbe.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayProbe.cs index de4d79857277..1444f590718f 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayProbe.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayProbe.cs @@ -202,16 +202,13 @@ public ApplicationGatewayProbe() /// public virtual void Validate() { - if (Port != null) + if (Port > 65535) { - if (Port > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); - } - if (Port < 1) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 1); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); + } + if (Port < 1) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 1); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayRequestRoutingRule.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayRequestRoutingRule.cs index 3d12aaebb9d9..3f073eb3bdab 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayRequestRoutingRule.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayRequestRoutingRule.cs @@ -181,16 +181,13 @@ public ApplicationGatewayRequestRoutingRule() /// public virtual void Validate() { - if (Priority != null) + if (Priority > 20000) { - if (Priority > 20000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 20000); - } - if (Priority < 1) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 1); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 20000); + } + if (Priority < 1) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 1); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayWebApplicationFirewallConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayWebApplicationFirewallConfiguration.cs index dad33866910e..bd4966fd77a9 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayWebApplicationFirewallConfiguration.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationGatewayWebApplicationFirewallConfiguration.cs @@ -165,34 +165,25 @@ public virtual void Validate() } } } - if (MaxRequestBodySize != null) + if (MaxRequestBodySize > 128) { - if (MaxRequestBodySize > 128) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "MaxRequestBodySize", 128); - } - if (MaxRequestBodySize < 8) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxRequestBodySize", 8); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "MaxRequestBodySize", 128); } - if (MaxRequestBodySizeInKb != null) + if (MaxRequestBodySize < 8) { - if (MaxRequestBodySizeInKb > 128) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "MaxRequestBodySizeInKb", 128); - } - if (MaxRequestBodySizeInKb < 8) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxRequestBodySizeInKb", 8); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxRequestBodySize", 8); } - if (FileUploadLimitInMb != null) + if (MaxRequestBodySizeInKb > 128) { - if (FileUploadLimitInMb < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "FileUploadLimitInMb", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "MaxRequestBodySizeInKb", 128); + } + if (MaxRequestBodySizeInKb < 8) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxRequestBodySizeInKb", 8); + } + if (FileUploadLimitInMb < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "FileUploadLimitInMb", 0); } if (Exclusions != null) { diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationRule.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationRule.cs index 3bfb4fabf638..caa6a0d598e6 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationRule.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ApplicationRule.cs @@ -18,7 +18,6 @@ namespace Microsoft.Azure.Management.Network.Models /// /// Rule of type application. /// - [Newtonsoft.Json.JsonObject("ApplicationRule")] public partial class ApplicationRule : FirewallPolicyRule { /// diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleCollection.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleCollection.cs index 30fea8c7ada4..6528bdb761cf 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleCollection.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleCollection.cs @@ -116,16 +116,13 @@ public AzureFirewallApplicationRuleCollection() /// public virtual void Validate() { - if (Priority != null) + if (Priority > 65000) { - if (Priority > 65000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); - } - if (Priority < 100) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); + } + if (Priority < 100) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleProtocol.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleProtocol.cs index 278a39b679cb..f2c9c74fdc19 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleProtocol.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallApplicationRuleProtocol.cs @@ -70,16 +70,13 @@ public AzureFirewallApplicationRuleProtocol() /// public virtual void Validate() { - if (Port != null) + if (Port > 64000) { - if (Port > 64000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 64000); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 64000); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNatRuleCollection.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNatRuleCollection.cs index 01ffee90b3fd..d18672edde1b 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNatRuleCollection.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNatRuleCollection.cs @@ -116,16 +116,13 @@ public AzureFirewallNatRuleCollection() /// public virtual void Validate() { - if (Priority != null) + if (Priority > 65000) { - if (Priority > 65000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); - } - if (Priority < 100) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); + } + if (Priority < 100) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNetworkRuleCollection.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNetworkRuleCollection.cs index cb720dc5c385..00531f0237b2 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNetworkRuleCollection.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureFirewallNetworkRuleCollection.cs @@ -115,16 +115,13 @@ public AzureFirewallNetworkRuleCollection() /// public virtual void Validate() { - if (Priority != null) + if (Priority > 65000) { - if (Priority > 65000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); - } - if (Priority < 100) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); + } + if (Priority < 100) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureReachabilityReportLatencyInfo.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureReachabilityReportLatencyInfo.cs index da00b97ff30c..a204272b613f 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureReachabilityReportLatencyInfo.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/AzureReachabilityReportLatencyInfo.cs @@ -68,16 +68,13 @@ public AzureReachabilityReportLatencyInfo() /// public virtual void Validate() { - if (Score != null) + if (Score > 100) { - if (Score > 100) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Score", 100); - } - if (Score < 1) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Score", 1); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Score", 100); + } + if (Score < 1) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Score", 1); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BastionHost.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BastionHost.cs index abb537163021..fdb1f396faeb 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BastionHost.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BastionHost.cs @@ -175,16 +175,13 @@ public virtual void Validate() } } } - if (ScaleUnits != null) + if (ScaleUnits > 50) { - if (ScaleUnits > 50) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "ScaleUnits", 50); - } - if (ScaleUnits < 2) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "ScaleUnits", 2); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "ScaleUnits", 50); + } + if (ScaleUnits < 2) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "ScaleUnits", 2); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpConnection.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpConnection.cs index 35fd140862ac..fbcc04667aeb 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpConnection.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpConnection.cs @@ -126,16 +126,13 @@ public BgpConnection() /// public virtual void Validate() { - if (PeerAsn != null) + if (PeerAsn > 4294967295) { - if (PeerAsn > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerAsn", 4294967295); - } - if (PeerAsn < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerAsn", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerAsn", 4294967295); + } + if (PeerAsn < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerAsn", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpPeerStatus.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpPeerStatus.cs index 843529d85907..4add761aab2f 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpPeerStatus.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpPeerStatus.cs @@ -119,16 +119,13 @@ public BgpPeerStatus() /// public virtual void Validate() { - if (Asn != null) + if (Asn > 4294967295) { - if (Asn > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Asn", 4294967295); - } - if (Asn < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Asn", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Asn", 4294967295); + } + if (Asn < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Asn", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpSettings.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpSettings.cs index 7ae62bc4e6bb..5e5788fc6e23 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpSettings.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/BgpSettings.cs @@ -88,16 +88,13 @@ public BgpSettings() /// public virtual void Validate() { - if (Asn != null) + if (Asn > 4294967295) { - if (Asn > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Asn", 4294967295); - } - if (Asn < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Asn", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Asn", 4294967295); + } + if (Asn < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Asn", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitor.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitor.cs index 89593c0c4910..0caac861305b 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitor.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitor.cs @@ -158,16 +158,13 @@ public virtual void Validate() { Destination.Validate(); } - if (MonitoringIntervalInSeconds != null) + if (MonitoringIntervalInSeconds > 1800) { - if (MonitoringIntervalInSeconds > 1800) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "MonitoringIntervalInSeconds", 1800); - } - if (MonitoringIntervalInSeconds < 30) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MonitoringIntervalInSeconds", 30); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "MonitoringIntervalInSeconds", 1800); + } + if (MonitoringIntervalInSeconds < 30) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "MonitoringIntervalInSeconds", 30); } if (Endpoints != null) { diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorDestination.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorDestination.cs index a2c4c891be63..eb4b187b8726 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorDestination.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorDestination.cs @@ -79,16 +79,13 @@ public ConnectionMonitorDestination() /// public virtual void Validate() { - if (Port != null) + if (Port > 65535) { - if (Port > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorHttpConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorHttpConfiguration.cs index 9f52940d25c4..7d6e8ebc03e8 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorHttpConfiguration.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorHttpConfiguration.cs @@ -110,16 +110,13 @@ public ConnectionMonitorHttpConfiguration() /// public virtual void Validate() { - if (Port != null) + if (Port > 65535) { - if (Port > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorParameters.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorParameters.cs index 403ef9585674..b4ad6eaafdb1 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorParameters.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorParameters.cs @@ -142,16 +142,13 @@ public virtual void Validate() { Destination.Validate(); } - if (MonitoringIntervalInSeconds != null) + if (MonitoringIntervalInSeconds > 1800) { - if (MonitoringIntervalInSeconds > 1800) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "MonitoringIntervalInSeconds", 1800); - } - if (MonitoringIntervalInSeconds < 30) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MonitoringIntervalInSeconds", 30); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "MonitoringIntervalInSeconds", 1800); + } + if (MonitoringIntervalInSeconds < 30) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "MonitoringIntervalInSeconds", 30); } if (Endpoints != null) { diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorResult.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorResult.cs index afe0533ea4c7..2a49a2fa6b6a 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorResult.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorResult.cs @@ -233,16 +233,13 @@ public virtual void Validate() { Destination.Validate(); } - if (MonitoringIntervalInSeconds != null) + if (MonitoringIntervalInSeconds > 1800) { - if (MonitoringIntervalInSeconds > 1800) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "MonitoringIntervalInSeconds", 1800); - } - if (MonitoringIntervalInSeconds < 30) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MonitoringIntervalInSeconds", 30); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "MonitoringIntervalInSeconds", 1800); + } + if (MonitoringIntervalInSeconds < 30) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "MonitoringIntervalInSeconds", 30); } if (Endpoints != null) { diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorSource.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorSource.cs index 83bd49a53e0d..b0627a3e13db 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorSource.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorSource.cs @@ -71,16 +71,13 @@ public virtual void Validate() { throw new ValidationException(ValidationRules.CannotBeNull, "ResourceId"); } - if (Port != null) + if (Port > 65535) { - if (Port > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorTcpConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorTcpConfiguration.cs index 2fe276a1ca7c..66c4afb87b25 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorTcpConfiguration.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionMonitorTcpConfiguration.cs @@ -78,16 +78,13 @@ public ConnectionMonitorTcpConfiguration() /// public virtual void Validate() { - if (Port != null) + if (Port > 65535) { - if (Port > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionStateSnapshot.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionStateSnapshot.cs index fb8bdc77ff24..30b563b24bd9 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionStateSnapshot.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectionStateSnapshot.cs @@ -138,60 +138,45 @@ public ConnectionStateSnapshot() /// public virtual void Validate() { - if (AvgLatencyInMs != null) + if (AvgLatencyInMs > 4294967295) { - if (AvgLatencyInMs > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "AvgLatencyInMs", 4294967295); - } - if (AvgLatencyInMs < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "AvgLatencyInMs", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "AvgLatencyInMs", 4294967295); } - if (MinLatencyInMs != null) + if (AvgLatencyInMs < 0) { - if (MinLatencyInMs > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "MinLatencyInMs", 4294967295); - } - if (MinLatencyInMs < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MinLatencyInMs", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "AvgLatencyInMs", 0); } - if (MaxLatencyInMs != null) + if (MinLatencyInMs > 4294967295) { - if (MaxLatencyInMs > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "MaxLatencyInMs", 4294967295); - } - if (MaxLatencyInMs < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxLatencyInMs", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "MinLatencyInMs", 4294967295); } - if (ProbesSent != null) + if (MinLatencyInMs < 0) { - if (ProbesSent > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "ProbesSent", 4294967295); - } - if (ProbesSent < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "ProbesSent", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "MinLatencyInMs", 0); } - if (ProbesFailed != null) + if (MaxLatencyInMs > 4294967295) { - if (ProbesFailed > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "ProbesFailed", 4294967295); - } - if (ProbesFailed < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "ProbesFailed", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "MaxLatencyInMs", 4294967295); + } + if (MaxLatencyInMs < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxLatencyInMs", 0); + } + if (ProbesSent > 4294967295) + { + throw new ValidationException(ValidationRules.InclusiveMaximum, "ProbesSent", 4294967295); + } + if (ProbesSent < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "ProbesSent", 0); + } + if (ProbesFailed > 4294967295) + { + throw new ValidationException(ValidationRules.InclusiveMaximum, "ProbesFailed", 4294967295); + } + if (ProbesFailed < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "ProbesFailed", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivityDestination.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivityDestination.cs index f6f519013db7..070ecc5f1ead 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivityDestination.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivityDestination.cs @@ -77,16 +77,13 @@ public ConnectivityDestination() /// public virtual void Validate() { - if (Port != null) + if (Port > 65535) { - if (Port > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivitySource.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivitySource.cs index 9115d726b250..00e6136a7079 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivitySource.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ConnectivitySource.cs @@ -72,16 +72,13 @@ public virtual void Validate() { throw new ValidationException(ValidationRules.CannotBeNull, "ResourceId"); } - if (Port != null) + if (Port > 65535) { - if (Port > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 65535); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExplicitProxySettings.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExplicitProxySettings.cs index 9435d58b46ce..e764328c3b6a 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExplicitProxySettings.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExplicitProxySettings.cs @@ -94,38 +94,29 @@ public ExplicitProxySettings() /// public virtual void Validate() { - if (HttpPort != null) + if (HttpPort > 64000) { - if (HttpPort > 64000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "HttpPort", 64000); - } - if (HttpPort < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "HttpPort", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "HttpPort", 64000); } - if (HttpsPort != null) + if (HttpPort < 0) { - if (HttpsPort > 64000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "HttpsPort", 64000); - } - if (HttpsPort < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "HttpsPort", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "HttpPort", 0); } - if (PacFilePort != null) + if (HttpsPort > 64000) { - if (PacFilePort > 64000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "PacFilePort", 64000); - } - if (PacFilePort < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "PacFilePort", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "HttpsPort", 64000); + } + if (HttpsPort < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "HttpsPort", 0); + } + if (PacFilePort > 64000) + { + throw new ValidationException(ValidationRules.InclusiveMaximum, "PacFilePort", 64000); + } + if (PacFilePort < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "PacFilePort", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCircuitPeering.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCircuitPeering.cs index 5a4692d55c50..207feb5c06e7 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCircuitPeering.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCircuitPeering.cs @@ -265,16 +265,13 @@ public ExpressRouteCircuitPeering() /// public virtual void Validate() { - if (PeerASN != null) + if (PeerASN > 4294967295) { - if (PeerASN > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerASN", 4294967295); - } - if (PeerASN < 1) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerASN", 1); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerASN", 4294967295); + } + if (PeerASN < 1) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerASN", 1); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCrossConnectionPeering.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCrossConnectionPeering.cs index 2246452167f1..7f0342d94b6b 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCrossConnectionPeering.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/ExpressRouteCrossConnectionPeering.cs @@ -209,16 +209,13 @@ public ExpressRouteCrossConnectionPeering() /// public virtual void Validate() { - if (PeerASN != null) + if (PeerASN > 4294967295) { - if (PeerASN > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerASN", 4294967295); - } - if (PeerASN < 1) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerASN", 1); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerASN", 4294967295); + } + if (PeerASN < 1) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerASN", 1); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyFilterRuleCollection.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyFilterRuleCollection.cs index 2184add4699b..f0a93af05634 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyFilterRuleCollection.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyFilterRuleCollection.cs @@ -18,7 +18,6 @@ namespace Microsoft.Azure.Management.Network.Models /// /// Firewall Policy Filter Rule Collection. /// - [Newtonsoft.Json.JsonObject("FirewallPolicyFilterRuleCollection")] public partial class FirewallPolicyFilterRuleCollection : FirewallPolicyRuleCollection { /// diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyNatRuleCollection.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyNatRuleCollection.cs index 5466fda21bf3..45fc27690fbb 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyNatRuleCollection.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyNatRuleCollection.cs @@ -18,7 +18,6 @@ namespace Microsoft.Azure.Management.Network.Models /// /// Firewall Policy NAT Rule Collection. /// - [Newtonsoft.Json.JsonObject("FirewallPolicyNatRuleCollection")] public partial class FirewallPolicyNatRuleCollection : FirewallPolicyRuleCollection { /// diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRule.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRule.cs index ed4b7f977df1..f56257124f71 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRule.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRule.cs @@ -16,7 +16,6 @@ namespace Microsoft.Azure.Management.Network.Models /// /// Properties of a rule. /// - [Newtonsoft.Json.JsonObject("FirewallPolicyRule")] public partial class FirewallPolicyRule { /// diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleApplicationProtocol.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleApplicationProtocol.cs index 2bad4a0ff8cf..cf68f4aa6b54 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleApplicationProtocol.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleApplicationProtocol.cs @@ -70,16 +70,13 @@ public FirewallPolicyRuleApplicationProtocol() /// public virtual void Validate() { - if (Port != null) + if (Port > 64000) { - if (Port > 64000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 64000); - } - if (Port < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Port", 64000); + } + if (Port < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Port", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollection.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollection.cs index 824b73fb84a3..03123f19d0fa 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollection.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollection.cs @@ -17,7 +17,6 @@ namespace Microsoft.Azure.Management.Network.Models /// /// Properties of the rule collection. /// - [Newtonsoft.Json.JsonObject("FirewallPolicyRuleCollection")] public partial class FirewallPolicyRuleCollection { /// @@ -69,16 +68,13 @@ public FirewallPolicyRuleCollection() /// public virtual void Validate() { - if (Priority != null) + if (Priority > 65000) { - if (Priority > 65000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); - } - if (Priority < 100) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); + } + if (Priority < 100) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollectionGroup.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollectionGroup.cs index 3cd122ca0f1d..b417d38a1e8c 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollectionGroup.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FirewallPolicyRuleCollectionGroup.cs @@ -116,16 +116,13 @@ public FirewallPolicyRuleCollectionGroup() /// public virtual void Validate() { - if (Priority != null) + if (Priority > 65000) { - if (Priority > 65000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); - } - if (Priority < 100) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "Priority", 65000); + } + if (Priority < 100) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "Priority", 100); } if (RuleCollections != null) { diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FrontendIpConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FrontendIPConfiguration.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FrontendIpConfiguration.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/FrontendIPConfiguration.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/HopLink.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/HopLink.cs index cfec5a05915c..64218016af56 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/HopLink.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/HopLink.cs @@ -119,38 +119,29 @@ public HopLink() /// public virtual void Validate() { - if (RoundTripTimeMin != null) + if (RoundTripTimeMin > 4294967295) { - if (RoundTripTimeMin > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "RoundTripTimeMin", 4294967295); - } - if (RoundTripTimeMin < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "RoundTripTimeMin", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "RoundTripTimeMin", 4294967295); } - if (RoundTripTimeAvg != null) + if (RoundTripTimeMin < 0) { - if (RoundTripTimeAvg > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "RoundTripTimeAvg", 4294967295); - } - if (RoundTripTimeAvg < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "RoundTripTimeAvg", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "RoundTripTimeMin", 0); } - if (RoundTripTimeMax != null) + if (RoundTripTimeAvg > 4294967295) { - if (RoundTripTimeMax > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "RoundTripTimeMax", 4294967295); - } - if (RoundTripTimeMax < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "RoundTripTimeMax", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "RoundTripTimeAvg", 4294967295); + } + if (RoundTripTimeAvg < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "RoundTripTimeAvg", 0); + } + if (RoundTripTimeMax > 4294967295) + { + throw new ValidationException(ValidationRules.InclusiveMaximum, "RoundTripTimeMax", 4294967295); + } + if (RoundTripTimeMax < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "RoundTripTimeMax", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/IpAllocationMethod.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/IPAllocationMethod.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/IpAllocationMethod.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/IPAllocationMethod.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/InboundSecurityRules.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/InboundSecurityRules.cs index 133d8fe7975e..be9f44b217ff 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/InboundSecurityRules.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/InboundSecurityRules.cs @@ -78,16 +78,13 @@ public InboundSecurityRules() /// public virtual void Validate() { - if (DestinationPortRange != null) + if (DestinationPortRange > 65535) { - if (DestinationPortRange > 65535) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "DestinationPortRange", 65535); - } - if (DestinationPortRange < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "DestinationPortRange", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "DestinationPortRange", 65535); + } + if (DestinationPortRange < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "DestinationPortRange", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NatRule.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NatRule.cs index 8dbc9d3c938e..8fa86e0c9935 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NatRule.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NatRule.cs @@ -18,7 +18,6 @@ namespace Microsoft.Azure.Management.Network.Models /// /// Rule of type nat. /// - [Newtonsoft.Json.JsonObject("NatRule")] public partial class NatRule : FirewallPolicyRule { /// diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkInterfaceIpConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkInterfaceIPConfiguration.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkInterfaceIpConfiguration.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkInterfaceIPConfiguration.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkRule.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkRule.cs index feebc1b0ae05..7a0279f4f82e 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkRule.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkRule.cs @@ -18,7 +18,6 @@ namespace Microsoft.Azure.Management.Network.Models /// /// Rule of type network. /// - [Newtonsoft.Json.JsonObject("NetworkRule")] public partial class NetworkRule : FirewallPolicyRule { /// diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkVirtualAppliance.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkVirtualAppliance.cs index 35972f2b397d..bda261502f6c 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkVirtualAppliance.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/NetworkVirtualAppliance.cs @@ -187,16 +187,13 @@ public NetworkVirtualAppliance() /// public virtual void Validate() { - if (VirtualApplianceAsn != null) + if (VirtualApplianceAsn > 4294967295) { - if (VirtualApplianceAsn > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "VirtualApplianceAsn", 4294967295); - } - if (VirtualApplianceAsn < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "VirtualApplianceAsn", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "VirtualApplianceAsn", 4294967295); + } + if (VirtualApplianceAsn < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "VirtualApplianceAsn", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCapture.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCapture.cs index 0cb6d02efca3..270be9f057ac 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCapture.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCapture.cs @@ -115,38 +115,29 @@ public virtual void Validate() { throw new ValidationException(ValidationRules.CannotBeNull, "StorageLocation"); } - if (BytesToCapturePerPacket != null) + if (BytesToCapturePerPacket > 4294967295) { - if (BytesToCapturePerPacket > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "BytesToCapturePerPacket", 4294967295); - } - if (BytesToCapturePerPacket < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "BytesToCapturePerPacket", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "BytesToCapturePerPacket", 4294967295); } - if (TotalBytesPerSession != null) + if (BytesToCapturePerPacket < 0) { - if (TotalBytesPerSession > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "TotalBytesPerSession", 4294967295); - } - if (TotalBytesPerSession < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "TotalBytesPerSession", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "BytesToCapturePerPacket", 0); } - if (TimeLimitInSeconds != null) + if (TotalBytesPerSession > 4294967295) { - if (TimeLimitInSeconds > 18000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "TimeLimitInSeconds", 18000); - } - if (TimeLimitInSeconds < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "TimeLimitInSeconds", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "TotalBytesPerSession", 4294967295); + } + if (TotalBytesPerSession < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "TotalBytesPerSession", 0); + } + if (TimeLimitInSeconds > 18000) + { + throw new ValidationException(ValidationRules.InclusiveMaximum, "TimeLimitInSeconds", 18000); + } + if (TimeLimitInSeconds < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "TimeLimitInSeconds", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureParameters.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureParameters.cs index e791803e4fad..a8a225ae7b4b 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureParameters.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureParameters.cs @@ -113,38 +113,29 @@ public virtual void Validate() { throw new ValidationException(ValidationRules.CannotBeNull, "StorageLocation"); } - if (BytesToCapturePerPacket != null) + if (BytesToCapturePerPacket > 4294967295) { - if (BytesToCapturePerPacket > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "BytesToCapturePerPacket", 4294967295); - } - if (BytesToCapturePerPacket < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "BytesToCapturePerPacket", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "BytesToCapturePerPacket", 4294967295); } - if (TotalBytesPerSession != null) + if (BytesToCapturePerPacket < 0) { - if (TotalBytesPerSession > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "TotalBytesPerSession", 4294967295); - } - if (TotalBytesPerSession < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "TotalBytesPerSession", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "BytesToCapturePerPacket", 0); } - if (TimeLimitInSeconds != null) + if (TotalBytesPerSession > 4294967295) { - if (TimeLimitInSeconds > 18000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "TimeLimitInSeconds", 18000); - } - if (TimeLimitInSeconds < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "TimeLimitInSeconds", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "TotalBytesPerSession", 4294967295); + } + if (TotalBytesPerSession < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "TotalBytesPerSession", 0); + } + if (TimeLimitInSeconds > 18000) + { + throw new ValidationException(ValidationRules.InclusiveMaximum, "TimeLimitInSeconds", 18000); + } + if (TimeLimitInSeconds < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "TimeLimitInSeconds", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureResult.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureResult.cs index ed6a805dc78e..cdd1a0f896be 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureResult.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PacketCaptureResult.cs @@ -152,38 +152,29 @@ public virtual void Validate() { throw new ValidationException(ValidationRules.CannotBeNull, "StorageLocation"); } - if (BytesToCapturePerPacket != null) + if (BytesToCapturePerPacket > 4294967295) { - if (BytesToCapturePerPacket > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "BytesToCapturePerPacket", 4294967295); - } - if (BytesToCapturePerPacket < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "BytesToCapturePerPacket", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "BytesToCapturePerPacket", 4294967295); } - if (TotalBytesPerSession != null) + if (BytesToCapturePerPacket < 0) { - if (TotalBytesPerSession > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "TotalBytesPerSession", 4294967295); - } - if (TotalBytesPerSession < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "TotalBytesPerSession", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "BytesToCapturePerPacket", 0); } - if (TimeLimitInSeconds != null) + if (TotalBytesPerSession > 4294967295) { - if (TimeLimitInSeconds > 18000) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "TimeLimitInSeconds", 18000); - } - if (TimeLimitInSeconds < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "TimeLimitInSeconds", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "TotalBytesPerSession", 4294967295); + } + if (TotalBytesPerSession < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "TotalBytesPerSession", 0); + } + if (TimeLimitInSeconds > 18000) + { + throw new ValidationException(ValidationRules.InclusiveMaximum, "TimeLimitInSeconds", 18000); + } + if (TimeLimitInSeconds < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "TimeLimitInSeconds", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PolicySettings.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PolicySettings.cs index 1e003d19090e..15ebdf469c64 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PolicySettings.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PolicySettings.cs @@ -95,19 +95,13 @@ public PolicySettings() /// public virtual void Validate() { - if (MaxRequestBodySizeInKb != null) + if (MaxRequestBodySizeInKb < 8) { - if (MaxRequestBodySizeInKb < 8) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxRequestBodySizeInKb", 8); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "MaxRequestBodySizeInKb", 8); } - if (FileUploadLimitInMb != null) + if (FileUploadLimitInMb < 0) { - if (FileUploadLimitInMb < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "FileUploadLimitInMb", 0); - } + throw new ValidationException(ValidationRules.InclusiveMinimum, "FileUploadLimitInMb", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIpAddress.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIPAddress.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIpAddress.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIPAddress.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIpAddressDnsSettings.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIPAddressDnsSettings.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIpAddressDnsSettings.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/PublicIPAddressDnsSettings.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualHub.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualHub.cs index d1746404da5f..99c728642f4d 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualHub.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualHub.cs @@ -254,16 +254,13 @@ public VirtualHub() /// public virtual void Validate() { - if (VirtualRouterAsn != null) + if (VirtualRouterAsn > 4294967295) { - if (VirtualRouterAsn > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "VirtualRouterAsn", 4294967295); - } - if (VirtualRouterAsn < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "VirtualRouterAsn", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "VirtualRouterAsn", 4294967295); + } + if (VirtualRouterAsn < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "VirtualRouterAsn", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualNetworkGatewayIpConfiguration.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualNetworkGatewayIPConfiguration.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualNetworkGatewayIpConfiguration.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualNetworkGatewayIPConfiguration.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouter.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouter.cs index e6a1b590c68a..970f9a3fe686 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouter.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouter.cs @@ -122,16 +122,13 @@ public VirtualRouter() /// public virtual void Validate() { - if (VirtualRouterAsn != null) + if (VirtualRouterAsn > 4294967295) { - if (VirtualRouterAsn > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "VirtualRouterAsn", 4294967295); - } - if (VirtualRouterAsn < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "VirtualRouterAsn", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "VirtualRouterAsn", 4294967295); + } + if (VirtualRouterAsn < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "VirtualRouterAsn", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouterPeering.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouterPeering.cs index 35a8277064c2..356b2fda9334 100644 --- a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouterPeering.cs +++ b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/Models/VirtualRouterPeering.cs @@ -107,16 +107,13 @@ public VirtualRouterPeering() /// public virtual void Validate() { - if (PeerAsn != null) + if (PeerAsn > 4294967295) { - if (PeerAsn > 4294967295) - { - throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerAsn", 4294967295); - } - if (PeerAsn < 0) - { - throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerAsn", 0); - } + throw new ValidationException(ValidationRules.InclusiveMaximum, "PeerAsn", 4294967295); + } + if (PeerAsn < 0) + { + throw new ValidationException(ValidationRules.InclusiveMinimum, "PeerAsn", 0); } } } diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIpAddressesOperations.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIPAddressesOperations.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIpAddressesOperations.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIPAddressesOperations.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIpAddressesOperationsExtensions.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIPAddressesOperationsExtensions.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIpAddressesOperationsExtensions.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/PublicIPAddressesOperationsExtensions.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWANsOperations.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWansOperations.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWANsOperations.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWansOperations.cs diff --git a/sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWANsOperationsExtensions.cs b/sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWansOperationsExtensions.cs similarity index 100% rename from sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWANsOperationsExtensions.cs rename to sdk/network/Microsoft.Azure.Management.Network/src/Generated/VirtualWansOperationsExtensions.cs