/// <summary> /// Gets the list of all possible traffic between resources for the /// subscription /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <IPage <AllowedConnectionsResource> > ListAsync(this IAllowedConnectionsOperations operations, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListWithHttpMessagesAsync(null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Gets the list of all possible traffic between resources for the /// subscription and location, based on connection type. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group within the user's subscription. The name is /// case insensitive. /// </param> /// <param name='connectionType'> /// The type of allowed connections (Internal, External). Possible values /// include: 'Internal', 'External' /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <AllowedConnectionsResource> GetAsync(this IAllowedConnectionsOperations operations, string resourceGroupName, string connectionType, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.GetWithHttpMessagesAsync(resourceGroupName, connectionType, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Initializes client properties. /// </summary> private void Initialize() { Pricings = new PricingsOperations(this); SecurityContacts = new SecurityContactsOperations(this); WorkspaceSettings = new WorkspaceSettingsOperations(this); AutoProvisioningSettings = new AutoProvisioningSettingsOperations(this); Compliances = new CompliancesOperations(this); AdvancedThreatProtection = new AdvancedThreatProtectionOperations(this); Settings = new SettingsOperations(this); InformationProtectionPolicies = new InformationProtectionPoliciesOperations(this); Operations = new Operations(this); Locations = new LocationsOperations(this); Tasks = new TasksOperations(this); Alerts = new AlertsOperations(this); DiscoveredSecuritySolutions = new DiscoveredSecuritySolutionsOperations(this); JitNetworkAccessPolicies = new JitNetworkAccessPoliciesOperations(this); ExternalSecuritySolutions = new ExternalSecuritySolutionsOperations(this); Topology = new TopologyOperations(this); AllowedConnections = new AllowedConnectionsOperations(this); BaseUri = new System.Uri("https://management.azure.com"); AcceptLanguage = "en-US"; LongRunningOperationRetryTimeout = 30; GenerateClientRequestId = true; SerializationSettings = new JsonSerializerSettings { Formatting = Newtonsoft.Json.Formatting.Indented, DateFormatHandling = Newtonsoft.Json.DateFormatHandling.IsoDateFormat, DateTimeZoneHandling = Newtonsoft.Json.DateTimeZoneHandling.Utc, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore, ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize, ContractResolver = new ReadOnlyJsonContractResolver(), Converters = new List <JsonConverter> { new Iso8601TimeSpanConverter() } }; SerializationSettings.Converters.Add(new TransformationJsonConverter()); DeserializationSettings = new JsonSerializerSettings { DateFormatHandling = Newtonsoft.Json.DateFormatHandling.IsoDateFormat, DateTimeZoneHandling = Newtonsoft.Json.DateTimeZoneHandling.Utc, NullValueHandling = Newtonsoft.Json.NullValueHandling.Ignore, ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize, ContractResolver = new ReadOnlyJsonContractResolver(), Converters = new List <JsonConverter> { new Iso8601TimeSpanConverter() } }; SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <Setting>("kind")); DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <Setting>("kind")); SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <ExternalSecuritySolution>("kind")); DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <ExternalSecuritySolution>("kind")); CustomInitialize(); DeserializationSettings.Converters.Add(new TransformationJsonConverter()); DeserializationSettings.Converters.Add(new CloudErrorJsonConverter()); }
/// <summary> /// Gets the list of all possible traffic between resources for the /// subscription and location, based on connection type. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group within the user's subscription. The name is /// case insensitive. /// </param> /// <param name='connectionType'> /// The type of allowed connections (Internal, External). Possible values /// include: 'Internal', 'External' /// </param> public static AllowedConnectionsResource Get(this IAllowedConnectionsOperations operations, string resourceGroupName, string connectionType) { return(operations.GetAsync(resourceGroupName, connectionType).GetAwaiter().GetResult()); }
/// <summary> /// Gets the list of all possible traffic between resources for the /// subscription and location. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> public static IPage <AllowedConnectionsResource> ListByHomeRegion(this IAllowedConnectionsOperations operations) { return(operations.ListByHomeRegionAsync().GetAwaiter().GetResult()); }
/// <summary> /// Gets the list of all possible traffic between resources for the /// subscription and location. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='nextPageLink'> /// The NextLink from the previous successful call to List operation. /// </param> public static IPage <AllowedConnectionsResource> ListByHomeRegionNext(this IAllowedConnectionsOperations operations, string nextPageLink) { return(operations.ListByHomeRegionNextAsync(nextPageLink).GetAwaiter().GetResult()); }