Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR Microsoft.Azure.Management.ApiManagement] [DO NOT MERGE] Compute 2019-07-01 version #197

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,10 @@ public AuthenticationSettingsContract()
/// </summary>
/// <param name="oAuth2">OAuth2 Authentication settings</param>
/// <param name="openid">OpenID Connect Authentication Settings</param>
/// <param name="subscriptionKeyRequired">Specifies whether
/// subscription key is required during call to this API, true - API is
/// included into closed products only, false - API is included into
/// open products alone, null - there is a mix of products.</param>
public AuthenticationSettingsContract(OAuth2AuthenticationSettingsContract oAuth2 = default(OAuth2AuthenticationSettingsContract), OpenIdAuthenticationSettingsContract openid = default(OpenIdAuthenticationSettingsContract), bool? subscriptionKeyRequired = default(bool?))
public AuthenticationSettingsContract(OAuth2AuthenticationSettingsContract oAuth2 = default(OAuth2AuthenticationSettingsContract), OpenIdAuthenticationSettingsContract openid = default(OpenIdAuthenticationSettingsContract))
{
OAuth2 = oAuth2;
Openid = openid;
SubscriptionKeyRequired = subscriptionKeyRequired;
CustomInit();
}

Expand All @@ -62,14 +57,5 @@ public AuthenticationSettingsContract()
[JsonProperty(PropertyName = "openid")]
public OpenIdAuthenticationSettingsContract Openid { get; set; }

/// <summary>
/// Gets or sets specifies whether subscription key is required during
/// call to this API, true - API is included into closed products only,
/// false - API is included into open products alone, null - there is a
/// mix of products.
/// </summary>
[JsonProperty(PropertyName = "subscriptionKeyRequired")]
public bool? SubscriptionKeyRequired { get; set; }

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -454,6 +454,31 @@ public partial interface INamespacesOperations
/// </exception>
Task<AzureOperationResponse<NetworkRuleSet>> GetNetworkRuleSetWithHttpMessagesAsync(string resourceGroupName, string namespaceName, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Gets list of NetworkRuleSet for a Namespace.
/// </summary>
/// <param name='resourceGroupName'>
/// Name of the Resource group within the Azure subscription.
/// </param>
/// <param name='namespaceName'>
/// The namespace name
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<IPage<NetworkRuleSet>>> ListNetworkRuleSetsWithHttpMessagesAsync(string resourceGroupName, string namespaceName, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Creates or updates a service namespace. Once created, this
/// namespace's resource manifest is immutable. This operation is
/// idempotent.
Expand Down Expand Up @@ -578,5 +603,27 @@ public partial interface INamespacesOperations
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<IPage<SBAuthorizationRule>>> ListAuthorizationRulesNextWithHttpMessagesAsync(string nextPageLink, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Gets list of NetworkRuleSet for a Namespace.
/// </summary>
/// <param name='nextPageLink'>
/// The NextLink from the previous successful call to List operation.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<IPage<NetworkRuleSet>>> ListNetworkRuleSetsNextWithHttpMessagesAsync(string nextPageLink, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,18 @@ public Rule()
[JsonProperty(PropertyName = "properties.correlationFilter")]
public CorrelationFilter CorrelationFilter { get; set; }

/// <summary>
/// Validate the object.
/// </summary>
/// <exception cref="ValidationException">
/// Thrown if validation fails
/// </exception>
public virtual void Validate()
{
if (SqlFilter != null)
{
SqlFilter.Validate();
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

namespace Microsoft.Azure.Management.ServiceBus.Models
{
using Microsoft.Rest;
using Newtonsoft.Json;
using System.Linq;

Expand Down Expand Up @@ -57,11 +58,11 @@ public SqlFilter()
public string SqlExpression { get; set; }

/// <summary>
/// Gets this property is reserved for future use. An integer value
/// showing the compatibility level, currently hard-coded to 20.
/// Gets or sets this property is reserved for future use. An integer
/// value showing the compatibility level, currently hard-coded to 20.
/// </summary>
[JsonProperty(PropertyName = "compatibilityLevel")]
public int? CompatibilityLevel { get; private set; }
public int? CompatibilityLevel { get; set; }

/// <summary>
/// Gets or sets value that indicates whether the rule action requires
Expand All @@ -70,5 +71,22 @@ public SqlFilter()
[JsonProperty(PropertyName = "requiresPreprocessing")]
public bool? RequiresPreprocessing { get; set; }

/// <summary>
/// Validate the object.
/// </summary>
/// <exception cref="ValidationException">
/// Thrown if validation fails
/// </exception>
public virtual void Validate()
{
if (CompatibilityLevel > 20)
{
throw new ValidationException(ValidationRules.InclusiveMaximum, "CompatibilityLevel", 20);
}
if (CompatibilityLevel < 20)
{
throw new ValidationException(ValidationRules.InclusiveMinimum, "CompatibilityLevel", 20);
}
}
}
}
Loading