From 8a2e05012ed29062f701817e62867f003648b55a Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Tue, 16 Sep 2025 16:07:50 +0800 Subject: [PATCH 1/7] Generate SDK code from Swagger --- .../Azure.ResourceManager.Datadog.net8.0.cs | 241 +++++- ....ResourceManager.Datadog.netstandard2.0.cs | 241 +++++- .../src/Generated/ArmDatadogModelFactory.cs | 235 ++++-- .../src/Generated/DatadogMonitorResource.cs | 444 ++++++---- .../DatadogMonitorResourceCollection.cs | 20 +- ...atadogMonitorResourceData.Serialization.cs | 22 +- .../Generated/DatadogMonitorResourceData.cs | 19 +- .../Generated/DatadogSingleSignOnResource.cs | 8 +- .../DatadogSingleSignOnResourceCollection.cs | 20 +- .../DatadogSingleSignOnResourceData.cs | 5 +- .../Generated/Extensions/DatadogExtensions.cs | 181 +++- .../Extensions/MockableDatadogArmClient.cs | 24 +- .../MockableDatadogResourceGroupResource.cs | 4 +- .../MockableDatadogSubscriptionResource.cs | 156 +++- ...oredSubscriptionPropertyOperationSource.cs | 36 + .../AzureResourceManagerDatadogContext.cs | 14 +- ...sourceSupportedProperties.Serialization.cs | 144 ++++ .../CreateResourceSupportedProperties.cs | 69 ++ ...urceSupportedResponseList.Serialization.cs | 151 ++++ .../CreateResourceSupportedResponseList.cs | 80 ++ ...ementResourceListResponse.Serialization.cs | 29 +- .../DatadogAgreementResourceListResponse.cs | 26 +- ...DatadogApiKeyListResponse.Serialization.cs | 29 +- .../Models/DatadogApiKeyListResponse.cs | 26 +- ...BillingInfoResponseResult.Serialization.cs | 148 ++++ .../DatadogBillingInfoResponseResult.cs | 69 ++ ...ceSupportedResponseResult.Serialization.cs | 133 +++ ...ogCreateResourceSupportedResponseResult.cs | 65 ++ .../src/Generated/Models/DatadogHost.cs | 4 +- .../DatadogHostListResponse.Serialization.cs | 29 +- .../Models/DatadogHostListResponse.cs | 26 +- ...nitorResourceListResponse.Serialization.cs | 29 +- .../DatadogMonitorResourceListResponse.cs | 26 +- .../Models/DatadogMonitorResourcePatch.cs | 20 +- ...dogOrganizationProperties.Serialization.cs | 20 +- .../Models/DatadogOrganizationProperties.cs | 20 +- ...ignOnResourceListResponse.Serialization.cs | 29 +- ...DatadogSingleSignOnResourceListResponse.cs | 26 +- .../Models/LinkedInfo.Serialization.cs | 144 ++++ .../src/Generated/Models/LinkedInfo.cs | 70 ++ ...inkedResourceListResponse.Serialization.cs | 37 +- .../Models/LinkedResourceListResponse.cs | 29 +- .../MarketplaceSaaSInfo.Serialization.cs | 183 ++++ .../Generated/Models/MarketplaceSaaSInfo.cs | 81 ++ .../src/Generated/Models/MonitorProperties.cs | 8 +- .../MonitorUpdateProperties.Serialization.cs | 19 +- .../Models/MonitorUpdateProperties.cs | 8 +- ...toredResourceListResponse.Serialization.cs | 29 +- .../Models/MonitoredResourceListResponse.cs | 26 +- .../MonitoredSubscription.Serialization.cs | 170 ++++ .../Generated/Models/MonitoredSubscription.cs | 77 ++ ...ubscriptionPropertiesList.Serialization.cs | 151 ++++ .../MonitoredSubscriptionPropertiesList.cs | 80 ++ ...oringTagRulesListResponse.Serialization.cs | 29 +- .../Models/MonitoringTagRulesListResponse.cs | 26 +- ...itoringTagRulesProperties.Serialization.cs | 38 +- .../Models/MonitoringTagRulesProperties.cs | 11 +- .../src/Generated/Models/Operation.cs | 60 ++ .../PartnerBillingEntity.Serialization.cs | 155 ++++ .../Generated/Models/PartnerBillingEntity.cs | 73 ++ .../src/Generated/Models/ResourceSku.cs | 8 +- .../src/Generated/Models/Status.cs | 57 ++ .../Models/SubscriptionList.Serialization.cs | 158 ++++ .../src/Generated/Models/SubscriptionList.cs | 70 ++ .../src/Generated/Models/UserInfo.cs | 2 +- ...MonitoredSubscriptionPropertyCollection.cs | 493 +++++++++++ ...dSubscriptionPropertyData.Serialization.cs | 156 ++++ .../MonitoredSubscriptionPropertyData.cs | 75 ++ ...scriptionPropertyResource.Serialization.cs | 29 + .../MonitoredSubscriptionPropertyResource.cs | 347 ++++++++ .../Generated/MonitoringTagRuleCollection.cs | 20 +- .../Generated/MonitoringTagRuleResource.cs | 8 +- .../BillingInfoRestOperations.cs | 133 +++ .../CreationSupportedRestOperations.cs | 287 +++++++ .../MarketplaceAgreementsRestOperations.cs | 6 +- .../MonitoredSubscriptionsRestOperations.cs | 617 ++++++++++++++ .../RestOperations/MonitorsRestOperations.cs | 792 +++++++++--------- ...ingleSignOnConfigurationsRestOperations.cs | 102 +-- .../RestOperations/TagRulesRestOperations.cs | 70 +- .../src/autorest.md | 6 +- .../Samples/Sample_DatadogMonitorResource.cs | 120 ++- ...Sample_DatadogMonitorResourceCollection.cs | 39 +- .../Sample_DatadogSingleSignOnResource.cs | 14 +- ...e_DatadogSingleSignOnResourceCollection.cs | 20 +- ...MonitoredSubscriptionPropertyCollection.cs | 256 ++++++ ...e_MonitoredSubscriptionPropertyResource.cs | 169 ++++ .../Sample_MonitoringTagRuleCollection.cs | 37 +- .../Sample_MonitoringTagRuleResource.cs | 31 +- .../Sample_SubscriptionResourceExtensions.cs | 68 +- 89 files changed, 7418 insertions(+), 1144 deletions(-) create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/LongRunningOperation/MonitoredSubscriptionPropertyOperationSource.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Operation.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Status.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs index e99d54eb3c19..5687f4dcd7a4 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs @@ -10,6 +10,10 @@ public static partial class DatadogExtensions { public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Response GetDatadogMonitorResource(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetDatadogMonitorResourceAsync(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -19,6 +23,7 @@ public static partial class DatadogExtensions public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } public partial class DatadogMonitorResource : Azure.ResourceManager.ArmResource, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel @@ -36,6 +41,8 @@ protected DatadogMonitorResource() { } public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetDatadogSingleSignOnResource(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetDatadogSingleSignOnResourceAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResources() { throw null; } @@ -43,10 +50,13 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetHosts(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionProperties() { throw null; } + public virtual Azure.Response GetMonitoredSubscriptionProperty(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetMonitoredSubscriptionPropertyAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetMonitoringTagRule(string ruleSetName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetMonitoringTagRuleAsync(string ruleSetName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoringTagRuleCollection GetMonitoringTagRules() { throw null; } @@ -141,6 +151,53 @@ protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter write string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MonitoredSubscriptionPropertyCollection : Azure.ResourceManager.ArmCollection, System.Collections.Generic.IAsyncEnumerable, System.Collections.Generic.IEnumerable, System.Collections.IEnumerable + { + protected MonitoredSubscriptionPropertyCollection() { } + public virtual Azure.ResourceManager.ArmOperation CreateOrUpdate(Azure.WaitUntil waitUntil, string configurationName, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateAsync(Azure.WaitUntil waitUntil, string configurationName, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response Exists(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> ExistsAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response Get(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetAll(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetAllAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.NullableResponse GetIfExists(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetIfExistsAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + System.Collections.Generic.IAsyncEnumerator System.Collections.Generic.IAsyncEnumerable.GetAsyncEnumerator(System.Threading.CancellationToken cancellationToken) { throw null; } + System.Collections.Generic.IEnumerator System.Collections.Generic.IEnumerable.GetEnumerator() { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + } + public partial class MonitoredSubscriptionPropertyData : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public MonitoredSubscriptionPropertyData() { } + public Azure.ResourceManager.Datadog.Models.SubscriptionList Properties { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData 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.Datadog.MonitoredSubscriptionPropertyData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class MonitoredSubscriptionPropertyResource : Azure.ResourceManager.ArmResource, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public static readonly Azure.Core.ResourceType ResourceType; + protected MonitoredSubscriptionPropertyResource() { } + public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData Data { get { throw null; } } + public virtual bool HasData { get { throw null; } } + public static Azure.Core.ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) { throw null; } + public virtual Azure.ResourceManager.ArmOperation Delete(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task DeleteAsync(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData 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.Datadog.MonitoredSubscriptionPropertyData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + public virtual Azure.ResourceManager.ArmOperation Update(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> UpdateAsync(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } public partial class MonitoringTagRuleCollection : Azure.ResourceManager.ArmCollection, System.Collections.Generic.IAsyncEnumerable, System.Collections.Generic.IEnumerable, System.Collections.IEnumerable { protected MonitoringTagRuleCollection() { } @@ -194,6 +251,7 @@ public partial class MockableDatadogArmClient : Azure.ResourceManager.ArmResourc protected MockableDatadogArmClient() { } public virtual Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(Azure.Core.ResourceIdentifier id) { throw null; } + public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(Azure.Core.ResourceIdentifier id) { throw null; } } public partial class MockableDatadogResourceGroupResource : Azure.ResourceManager.ArmResource @@ -208,6 +266,10 @@ public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager protected MockableDatadogSubscriptionResource() { } public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -218,19 +280,37 @@ namespace Azure.ResourceManager.Datadog.Models { public static partial class ArmDatadogModelFactory { + public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? creationSupported = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties DatadogAgreementResourceProperties(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult DatadogBillingInfoResponseResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult DatadogCreateResourceSupportedResponseResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } - public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), string skuName = null, Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties DatadogOrganizationProperties(string name = null, string id = null, string linkingAuthCode = null, string linkingClientId = null, System.Uri redirectUri = null, string apiKey = null, string applicationKey = null, string enterpriseAppId = null) { throw null; } + public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, string skuName = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSetPasswordLink DatadogSetPasswordLink(string setPasswordLink = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.LinkedInfo LinkedInfo(string id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? subscribed = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? sendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? sendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } + public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? automuting = default(bool?), bool? customMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity(string id = null, string name = null, System.Uri partnerEntityUri = null) { throw null; } + } + public partial class CreateResourceSupportedProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal CreateResourceSupportedProperties() { } + public bool? CreationSupported { 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.Datadog.Models.CreateResourceSupportedProperties 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.Datadog.Models.CreateResourceSupportedProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { @@ -275,6 +355,29 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DatadogBillingInfoResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DatadogBillingInfoResponseResult() { } + public Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaasInfo { get { throw null; } } + public Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult 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.Datadog.Models.DatadogBillingInfoResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class DatadogCreateResourceSupportedResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DatadogCreateResourceSupportedResponseResult() { } + public Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties Properties { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult 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.Datadog.Models.DatadogCreateResourceSupportedResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogHost : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal DatadogHost() { } @@ -318,7 +421,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class DatadogMonitorResourcePatch : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogMonitorResourcePatch() { } - public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitorUpdateMonitoringStatus { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties Properties { get { throw null; } set { } } public string SkuName { 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) { } @@ -333,11 +436,12 @@ public partial class DatadogOrganizationProperties : System.ClientModel.Primitiv public DatadogOrganizationProperties() { } public string ApiKey { get { throw null; } set { } } public string ApplicationKey { get { throw null; } set { } } + public bool? Cspm { get { throw null; } set { } } public string EnterpriseAppId { get { throw null; } set { } } - public string Id { get { throw null; } } + public string Id { get { throw null; } set { } } public string LinkingAuthCode { get { throw null; } set { } } public string LinkingClientId { get { throw null; } set { } } - public string Name { get { throw null; } } + public string Name { get { throw null; } set { } } public System.Uri RedirectUri { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -402,6 +506,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory left, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory right) { throw null; } public override string ToString() { throw null; } } + public partial class LinkedInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal LinkedInfo() { } + public string Id { get { throw null; } } + public Azure.Core.AzureLocation? Location { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.LinkedInfo 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.Datadog.Models.LinkedInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class LogRules : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public LogRules() { } @@ -416,6 +532,21 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MarketplaceSaaSInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal MarketplaceSaaSInfo() { } + public string BilledAzureSubscriptionId { get { throw null; } } + public string MarketplaceName { get { throw null; } } + public string MarketplaceStatus { get { throw null; } } + public string MarketplaceSubscriptionId { get { throw null; } } + public bool? Subscribed { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo 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.Datadog.Models.MarketplaceSaaSInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct MarketplaceSubscriptionStatus : System.IEquatable { @@ -451,6 +582,20 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MonitoredSubscription : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public MonitoredSubscription() { } + public string Error { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.Status? Status { get { throw null; } set { } } + public string SubscriptionId { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.MonitoredSubscription 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.Datadog.Models.MonitoredSubscription System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct MonitoringStatus : System.IEquatable { @@ -472,6 +617,8 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoringTagRulesProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoringTagRulesProperties() { } + public bool? Automuting { get { throw null; } set { } } + public bool? CustomMetrics { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.LogRules LogRules { get { throw null; } set { } } public System.Collections.Generic.IList MetricRulesFilteringTags { get { throw null; } } public Azure.ResourceManager.Datadog.Models.ProvisioningState? ProvisioningState { get { throw null; } } @@ -499,6 +646,52 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MonitorUpdateProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public MonitorUpdateProperties() { } + public bool? Cspm { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitoringStatus { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties 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.Datadog.Models.MonitorUpdateProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct Operation : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public Operation(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.Operation Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation AddBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation AddComplete { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation DeleteBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation DeleteComplete { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.Operation other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.Operation (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } + public override string ToString() { throw null; } + } + public partial class PartnerBillingEntity : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal PartnerBillingEntity() { } + public string Id { get { throw null; } } + public string Name { get { throw null; } } + public System.Uri PartnerEntityUri { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.PartnerBillingEntity 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.Datadog.Models.PartnerBillingEntity System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct ProvisioningState : System.IEquatable { @@ -545,6 +738,38 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public override string ToString() { throw null; } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct Status : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public Status(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.Status Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Status Deleting { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Status Failed { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Status InProgress { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.Status other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.Status (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } + public override string ToString() { throw null; } + } + public partial class SubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public SubscriptionList() { } + public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } + public Azure.ResourceManager.Datadog.Models.Operation? Operation { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.SubscriptionList 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.Datadog.Models.SubscriptionList System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct TagAction : System.IEquatable { private readonly object _dummy; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs index e99d54eb3c19..5687f4dcd7a4 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs @@ -10,6 +10,10 @@ public static partial class DatadogExtensions { public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Response GetDatadogMonitorResource(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetDatadogMonitorResourceAsync(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -19,6 +23,7 @@ public static partial class DatadogExtensions public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } public partial class DatadogMonitorResource : Azure.ResourceManager.ArmResource, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel @@ -36,6 +41,8 @@ protected DatadogMonitorResource() { } public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetDatadogSingleSignOnResource(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetDatadogSingleSignOnResourceAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResources() { throw null; } @@ -43,10 +50,13 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetHosts(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionProperties() { throw null; } + public virtual Azure.Response GetMonitoredSubscriptionProperty(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetMonitoredSubscriptionPropertyAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetMonitoringTagRule(string ruleSetName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetMonitoringTagRuleAsync(string ruleSetName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoringTagRuleCollection GetMonitoringTagRules() { throw null; } @@ -141,6 +151,53 @@ protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter write string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MonitoredSubscriptionPropertyCollection : Azure.ResourceManager.ArmCollection, System.Collections.Generic.IAsyncEnumerable, System.Collections.Generic.IEnumerable, System.Collections.IEnumerable + { + protected MonitoredSubscriptionPropertyCollection() { } + public virtual Azure.ResourceManager.ArmOperation CreateOrUpdate(Azure.WaitUntil waitUntil, string configurationName, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateAsync(Azure.WaitUntil waitUntil, string configurationName, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response Exists(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> ExistsAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response Get(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetAll(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetAllAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.NullableResponse GetIfExists(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetIfExistsAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + System.Collections.Generic.IAsyncEnumerator System.Collections.Generic.IAsyncEnumerable.GetAsyncEnumerator(System.Threading.CancellationToken cancellationToken) { throw null; } + System.Collections.Generic.IEnumerator System.Collections.Generic.IEnumerable.GetEnumerator() { throw null; } + System.Collections.IEnumerator System.Collections.IEnumerable.GetEnumerator() { throw null; } + } + public partial class MonitoredSubscriptionPropertyData : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public MonitoredSubscriptionPropertyData() { } + public Azure.ResourceManager.Datadog.Models.SubscriptionList Properties { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData 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.Datadog.MonitoredSubscriptionPropertyData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class MonitoredSubscriptionPropertyResource : Azure.ResourceManager.ArmResource, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public static readonly Azure.Core.ResourceType ResourceType; + protected MonitoredSubscriptionPropertyResource() { } + public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData Data { get { throw null; } } + public virtual bool HasData { get { throw null; } } + public static Azure.Core.ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) { throw null; } + public virtual Azure.ResourceManager.ArmOperation Delete(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task DeleteAsync(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData 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.Datadog.MonitoredSubscriptionPropertyData System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + public virtual Azure.ResourceManager.ArmOperation Update(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> UpdateAsync(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData data, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + } public partial class MonitoringTagRuleCollection : Azure.ResourceManager.ArmCollection, System.Collections.Generic.IAsyncEnumerable, System.Collections.Generic.IEnumerable, System.Collections.IEnumerable { protected MonitoringTagRuleCollection() { } @@ -194,6 +251,7 @@ public partial class MockableDatadogArmClient : Azure.ResourceManager.ArmResourc protected MockableDatadogArmClient() { } public virtual Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(Azure.Core.ResourceIdentifier id) { throw null; } + public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(Azure.Core.ResourceIdentifier id) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(Azure.Core.ResourceIdentifier id) { throw null; } } public partial class MockableDatadogResourceGroupResource : Azure.ResourceManager.ArmResource @@ -208,6 +266,10 @@ public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager protected MockableDatadogSubscriptionResource() { } public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -218,19 +280,37 @@ namespace Azure.ResourceManager.Datadog.Models { public static partial class ArmDatadogModelFactory { + public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? creationSupported = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties DatadogAgreementResourceProperties(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult DatadogBillingInfoResponseResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult DatadogCreateResourceSupportedResponseResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } - public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), string skuName = null, Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties DatadogOrganizationProperties(string name = null, string id = null, string linkingAuthCode = null, string linkingClientId = null, System.Uri redirectUri = null, string apiKey = null, string applicationKey = null, string enterpriseAppId = null) { throw null; } + public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, string skuName = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSetPasswordLink DatadogSetPasswordLink(string setPasswordLink = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.LinkedInfo LinkedInfo(string id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? subscribed = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? sendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? sendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } + public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? automuting = default(bool?), bool? customMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity(string id = null, string name = null, System.Uri partnerEntityUri = null) { throw null; } + } + public partial class CreateResourceSupportedProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal CreateResourceSupportedProperties() { } + public bool? CreationSupported { 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.Datadog.Models.CreateResourceSupportedProperties 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.Datadog.Models.CreateResourceSupportedProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { @@ -275,6 +355,29 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DatadogBillingInfoResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DatadogBillingInfoResponseResult() { } + public Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaasInfo { get { throw null; } } + public Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult 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.Datadog.Models.DatadogBillingInfoResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + public partial class DatadogCreateResourceSupportedResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DatadogCreateResourceSupportedResponseResult() { } + public Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties Properties { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult 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.Datadog.Models.DatadogCreateResourceSupportedResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogHost : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal DatadogHost() { } @@ -318,7 +421,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class DatadogMonitorResourcePatch : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogMonitorResourcePatch() { } - public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitorUpdateMonitoringStatus { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties Properties { get { throw null; } set { } } public string SkuName { 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) { } @@ -333,11 +436,12 @@ public partial class DatadogOrganizationProperties : System.ClientModel.Primitiv public DatadogOrganizationProperties() { } public string ApiKey { get { throw null; } set { } } public string ApplicationKey { get { throw null; } set { } } + public bool? Cspm { get { throw null; } set { } } public string EnterpriseAppId { get { throw null; } set { } } - public string Id { get { throw null; } } + public string Id { get { throw null; } set { } } public string LinkingAuthCode { get { throw null; } set { } } public string LinkingClientId { get { throw null; } set { } } - public string Name { get { throw null; } } + public string Name { get { throw null; } set { } } public System.Uri RedirectUri { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -402,6 +506,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory left, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory right) { throw null; } public override string ToString() { throw null; } } + public partial class LinkedInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal LinkedInfo() { } + public string Id { get { throw null; } } + public Azure.Core.AzureLocation? Location { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.LinkedInfo 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.Datadog.Models.LinkedInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class LogRules : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public LogRules() { } @@ -416,6 +532,21 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MarketplaceSaaSInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal MarketplaceSaaSInfo() { } + public string BilledAzureSubscriptionId { get { throw null; } } + public string MarketplaceName { get { throw null; } } + public string MarketplaceStatus { get { throw null; } } + public string MarketplaceSubscriptionId { get { throw null; } } + public bool? Subscribed { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo 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.Datadog.Models.MarketplaceSaaSInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct MarketplaceSubscriptionStatus : System.IEquatable { @@ -451,6 +582,20 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MonitoredSubscription : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public MonitoredSubscription() { } + public string Error { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.Status? Status { get { throw null; } set { } } + public string SubscriptionId { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.MonitoredSubscription 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.Datadog.Models.MonitoredSubscription System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct MonitoringStatus : System.IEquatable { @@ -472,6 +617,8 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoringTagRulesProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoringTagRulesProperties() { } + public bool? Automuting { get { throw null; } set { } } + public bool? CustomMetrics { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.LogRules LogRules { get { throw null; } set { } } public System.Collections.Generic.IList MetricRulesFilteringTags { get { throw null; } } public Azure.ResourceManager.Datadog.Models.ProvisioningState? ProvisioningState { get { throw null; } } @@ -499,6 +646,52 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class MonitorUpdateProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public MonitorUpdateProperties() { } + public bool? Cspm { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitoringStatus { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties 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.Datadog.Models.MonitorUpdateProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct Operation : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public Operation(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.Operation Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation AddBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation AddComplete { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation DeleteBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Operation DeleteComplete { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.Operation other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.Operation (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } + public override string ToString() { throw null; } + } + public partial class PartnerBillingEntity : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal PartnerBillingEntity() { } + public string Id { get { throw null; } } + public string Name { get { throw null; } } + public System.Uri PartnerEntityUri { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.PartnerBillingEntity 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.Datadog.Models.PartnerBillingEntity System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct ProvisioningState : System.IEquatable { @@ -545,6 +738,38 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public override string ToString() { throw null; } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct Status : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public Status(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.Status Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Status Deleting { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Status Failed { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.Status InProgress { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.Status other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.Status (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } + public override string ToString() { throw null; } + } + public partial class SubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public SubscriptionList() { } + public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } + public Azure.ResourceManager.Datadog.Models.Operation? Operation { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.SubscriptionList 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.Datadog.Models.SubscriptionList System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct TagAction : System.IEquatable { private readonly object _dummy; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs index ec461eb700bc..8500767ffb59 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs @@ -34,9 +34,113 @@ public static DatadogAgreementResourceProperties DatadogAgreementResourcePropert serializedAdditionalRawData: null); } + /// Initializes a new instance of . + /// The id. + /// The name. + /// The resourceType. + /// The systemData. + /// The tags. + /// The location. + /// Properties specific to the monitor resource. + /// Represents the SKU of a resource. + /// Gets or sets the identity. Current supported identity types: SystemAssigned, UserAssigned. + /// A new instance for mocking. + public static DatadogMonitorResourceData DatadogMonitorResourceData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, IDictionary tags = null, AzureLocation location = default, MonitorProperties properties = null, string skuName = null, ManagedServiceIdentity identity = null) + { + tags ??= new Dictionary(); + + return new DatadogMonitorResourceData( + id, + name, + resourceType, + systemData, + tags, + location, + properties, + skuName != null ? new ResourceSku(skuName, serializedAdditionalRawData: null) : null, + identity, + serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// + /// Flag specifying if the resource monitoring is enabled or disabled. + /// Flag specifying the Marketplace Subscription Status of the resource. If payment is not made in time, the resource will go in Suspended state. + /// Specify the Datadog organization name. In the case of linking to existing organizations, Id, ApiKey, and Applicationkey is required as well. + /// Includes name, email and optionally, phone number. User Information can't be null. + /// + /// The priority of the resource. + /// A new instance for mocking. + public static MonitorProperties MonitorProperties(ProvisioningState? provisioningState = null, MonitoringStatus? monitoringStatus = null, MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = null, DatadogOrganizationProperties datadogOrganizationProperties = null, UserInfo userInfo = null, LiftrResourceCategory? liftrResourceCategory = null, int? liftrResourcePreference = null) + { + return new MonitorProperties( + provisioningState, + monitoringStatus, + marketplaceSubscriptionStatus, + datadogOrganizationProperties, + userInfo, + liftrResourceCategory, + liftrResourcePreference, + serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// Represents the properties of the resource. + /// A new instance for mocking. + public static DatadogCreateResourceSupportedResponseResult DatadogCreateResourceSupportedResponseResult(CreateResourceSupportedProperties properties = null) + { + return new DatadogCreateResourceSupportedResponseResult(properties, serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// The ARM id of the subscription. + /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. + /// A new instance for mocking. + public static CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? creationSupported = null) + { + return new CreateResourceSupportedProperties(name, creationSupported, serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// Marketplace Subscription details. + /// Partner Billing Entity details: Organization Info. + /// A new instance for mocking. + public static DatadogBillingInfoResponseResult DatadogBillingInfoResponseResult(MarketplaceSaaSInfo marketplaceSaasInfo = null, PartnerBillingEntity partnerBillingEntity = null) + { + return new DatadogBillingInfoResponseResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// Marketplace Subscription Id. This is a GUID-formatted string. + /// Marketplace Subscription Details: SAAS Name. + /// Marketplace Subscription Details: SaaS Subscription Status. + /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. + /// Flag specifying if the Marketplace status is subscribed or not. + /// A new instance for mocking. + public static MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? subscribed = null) + { + return new MarketplaceSaaSInfo( + marketplaceSubscriptionId, + marketplaceName, + marketplaceStatus, + billedAzureSubscriptionId, + subscribed, + serializedAdditionalRawData: null); + } + + /// Initializes a new instance of . + /// The Datadog Organization Id. + /// The Datadog Organization Name. + /// Link to the datadog organization page. + /// A new instance for mocking. + public static PartnerBillingEntity PartnerBillingEntity(string id = null, string name = null, Uri partnerEntityUri = null) + { + return new PartnerBillingEntity(id, name, partnerEntityUri, serializedAdditionalRawData: null); + } + /// Initializes a new instance of . /// The name of the host. - /// The aliases for the host. + /// The aliases for the host installed via the Datadog agent. /// The Datadog integrations reporting metrics for the host. /// /// A new instance for mocking. @@ -68,6 +172,15 @@ public static DatadogInstallMethod DatadogInstallMethod(string tool = null, stri return new DatadogInstallMethod(tool, toolVersion, installerVersion, serializedAdditionalRawData: null); } + /// Initializes a new instance of . + /// The ARM id of the linked resource. + /// The location of the linked resource. + /// A new instance for mocking. + public static LinkedInfo LinkedInfo(string id = null, AzureLocation? location = null) + { + return new LinkedInfo(id, location, serializedAdditionalRawData: null); + } + /// Initializes a new instance of . /// The ARM id of the resource. /// Flag indicating if resource is sending metrics to Datadog. @@ -86,77 +199,41 @@ public static MonitoredResourceContent MonitoredResourceContent(string id = null serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. - /// The tags. - /// The location. - /// - /// Properties specific to the monitor resource. - /// Gets or sets the identity. Current supported identity types: SystemAssigned, UserAssigned. - /// A new instance for mocking. - public static DatadogMonitorResourceData DatadogMonitorResourceData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, IDictionary tags = null, AzureLocation location = default, string skuName = null, MonitorProperties properties = null, ManagedServiceIdentity identity = null) + /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. + /// A new instance for mocking. + public static MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, SubscriptionList properties = null) { - tags ??= new Dictionary(); - - return new DatadogMonitorResourceData( + return new MonitoredSubscriptionPropertyData( id, name, resourceType, systemData, - tags, - location, - skuName != null ? new ResourceSku(skuName, serializedAdditionalRawData: null) : null, properties, - identity, serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// - /// Flag specifying if the resource monitoring is enabled or disabled. - /// Flag specifying the Marketplace Subscription Status of the resource. If payment is not made in time, the resource will go in Suspended state. - /// Datadog organization properties. - /// User info. - /// - /// The priority of the resource. - /// A new instance for mocking. - public static MonitorProperties MonitorProperties(ProvisioningState? provisioningState = null, MonitoringStatus? monitoringStatus = null, MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = null, DatadogOrganizationProperties datadogOrganizationProperties = null, UserInfo userInfo = null, LiftrResourceCategory? liftrResourceCategory = null, int? liftrResourcePreference = null) + /// Set of rules for sending logs for the Monitor resource. + /// Set of rules for sending metrics for the Monitor resource. + /// Configuration to enable/disable auto-muting flag. + /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. + /// A new instance for mocking. + public static MonitoringTagRulesProperties MonitoringTagRulesProperties(ProvisioningState? provisioningState = null, LogRules logRules = null, IEnumerable metricRulesFilteringTags = null, bool? automuting = null, bool? customMetrics = null) { - return new MonitorProperties( - provisioningState, - monitoringStatus, - marketplaceSubscriptionStatus, - datadogOrganizationProperties, - userInfo, - liftrResourceCategory, - liftrResourcePreference, - serializedAdditionalRawData: null); - } + metricRulesFilteringTags ??= new List(); - /// Initializes a new instance of . - /// Name of the Datadog organization. - /// Id of the Datadog organization. - /// The auth code used to linking to an existing datadog organization. - /// The client_id from an existing in exchange for an auth token to link organization. - /// The redirect uri for linking. - /// Api key associated to the Datadog organization. - /// Application key associated to the Datadog organization. - /// The Id of the Enterprise App used for Single sign on. - /// A new instance for mocking. - public static DatadogOrganizationProperties DatadogOrganizationProperties(string name = null, string id = null, string linkingAuthCode = null, string linkingClientId = null, Uri redirectUri = null, string apiKey = null, string applicationKey = null, string enterpriseAppId = null) - { - return new DatadogOrganizationProperties( - name, - id, - linkingAuthCode, - linkingClientId, - redirectUri, - apiKey, - applicationKey, - enterpriseAppId, + return new MonitoringTagRulesProperties( + provisioningState, + logRules, + metricRulesFilteringTags != null ? new MetricRules(metricRulesFilteringTags?.ToList(), serializedAdditionalRawData: null) : null, + automuting, + customMetrics, serializedAdditionalRawData: null); } @@ -168,16 +245,16 @@ public static DatadogSetPasswordLink DatadogSetPasswordLink(string setPasswordLi return new DatadogSetPasswordLink(setPasswordLink, serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. - /// Definition of the properties for a TagRules resource. - /// A new instance for mocking. - public static MonitoringTagRuleData MonitoringTagRuleData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, MonitoringTagRulesProperties properties = null) + /// + /// A new instance for mocking. + public static DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogSingleSignOnProperties properties = null) { - return new MonitoringTagRuleData( + return new DatadogSingleSignOnResourceData( id, name, resourceType, @@ -186,28 +263,27 @@ public static MonitoringTagRuleData MonitoringTagRuleData(ResourceIdentifier id serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// - /// Set of rules for sending logs for the Monitor resource. - /// Set of rules for sending metrics for the Monitor resource. - /// A new instance for mocking. - public static MonitoringTagRulesProperties MonitoringTagRulesProperties(ProvisioningState? provisioningState = null, LogRules logRules = null, IEnumerable metricRulesFilteringTags = null) + /// Various states of the SSO resource. + /// The Id of the Enterprise App used for Single sign-on. + /// The login URL specific to this Datadog Organization. + /// A new instance for mocking. + public static DatadogSingleSignOnProperties DatadogSingleSignOnProperties(ProvisioningState? provisioningState = null, SingleSignOnState? singleSignOnState = null, string enterpriseAppId = null, Uri singleSignOnUri = null) { - metricRulesFilteringTags ??= new List(); - - return new MonitoringTagRulesProperties(provisioningState, logRules, metricRulesFilteringTags != null ? new MetricRules(metricRulesFilteringTags?.ToList(), serializedAdditionalRawData: null) : null, serializedAdditionalRawData: null); + return new DatadogSingleSignOnProperties(provisioningState, singleSignOnState, enterpriseAppId, singleSignOnUri, serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. - /// - /// A new instance for mocking. - public static DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogSingleSignOnProperties properties = null) + /// Definition of the properties for a TagRules resource. + /// A new instance for mocking. + public static MonitoringTagRuleData MonitoringTagRuleData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, MonitoringTagRulesProperties properties = null) { - return new DatadogSingleSignOnResourceData( + return new MonitoringTagRuleData( id, name, resourceType, @@ -215,16 +291,5 @@ public static DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Re properties, serializedAdditionalRawData: null); } - - /// Initializes a new instance of . - /// - /// Various states of the SSO resource. - /// The Id of the Enterprise App used for Single sign-on. - /// The login URL specific to this Datadog Organization. - /// A new instance for mocking. - public static DatadogSingleSignOnProperties DatadogSingleSignOnProperties(ProvisioningState? provisioningState = null, SingleSignOnState? singleSignOnState = null, string enterpriseAppId = null, Uri singleSignOnUri = null) - { - return new DatadogSingleSignOnProperties(provisioningState, singleSignOnState, enterpriseAppId, singleSignOnUri, serializedAdditionalRawData: null); - } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs index fd5c00868355..45cf0677f887 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs @@ -6,10 +6,8 @@ #nullable disable using System; -using System.ClientModel.Primitives; using System.Collections.Generic; using System.Globalization; -using System.Text; using System.Threading; using System.Threading.Tasks; using Autorest.CSharp.Core; @@ -17,7 +15,6 @@ using Azure.Core.Pipeline; using Azure.ResourceManager.Datadog.Models; using Azure.ResourceManager.Resources; -using Azure.ResourceManager.Resources.Models; namespace Azure.ResourceManager.Datadog { @@ -41,6 +38,8 @@ public static ResourceIdentifier CreateResourceIdentifier(string subscriptionId, private readonly ClientDiagnostics _datadogMonitorResourceMonitorsClientDiagnostics; private readonly MonitorsRestOperations _datadogMonitorResourceMonitorsRestClient; + private readonly ClientDiagnostics _billingInfoClientDiagnostics; + private readonly BillingInfoRestOperations _billingInfoRestClient; private readonly DatadogMonitorResourceData _data; /// Gets the resource type for the operations. @@ -68,6 +67,8 @@ internal DatadogMonitorResource(ArmClient client, ResourceIdentifier id) : base( _datadogMonitorResourceMonitorsClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.Datadog", ResourceType.Namespace, Diagnostics); TryGetApiVersion(ResourceType, out string datadogMonitorResourceMonitorsApiVersion); _datadogMonitorResourceMonitorsRestClient = new MonitorsRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint, datadogMonitorResourceMonitorsApiVersion); + _billingInfoClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.Datadog", ProviderConstants.DefaultProviderNamespace, Diagnostics); + _billingInfoRestClient = new BillingInfoRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint); #if DEBUG ValidateResourceId(Id); #endif @@ -94,73 +95,73 @@ internal static void ValidateResourceId(ResourceIdentifier id) throw new ArgumentException(string.Format(CultureInfo.CurrentCulture, "Invalid resource type {0} expected {1}", id.ResourceType, ResourceType), nameof(id)); } - /// Gets a collection of MonitoringTagRuleResources in the DatadogMonitorResource. - /// An object representing collection of MonitoringTagRuleResources and their operations over a MonitoringTagRuleResource. - public virtual MonitoringTagRuleCollection GetMonitoringTagRules() + /// Gets a collection of MonitoredSubscriptionPropertyResources in the DatadogMonitorResource. + /// An object representing collection of MonitoredSubscriptionPropertyResources and their operations over a MonitoredSubscriptionPropertyResource. + public virtual MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionProperties() { - return GetCachedClient(client => new MonitoringTagRuleCollection(client, Id)); + return GetCachedClient(client => new MonitoredSubscriptionPropertyCollection(client, Id)); } /// - /// Get a tag rule set for a given monitor resource. + /// List the subscriptions currently being monitored by the Datadog monitor resource. /// /// /// Request Path - /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/tagRules/{ruleSetName} + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} /// /// /// Operation Id - /// TagRules_Get + /// MonitoredSubscriptions_Get /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource - /// + /// /// /// /// - /// Rule set name. + /// The configuration name. Only 'default' value is supported. /// The cancellation token to use. - /// is null. - /// is an empty string, and was expected to be non-empty. + /// is null. + /// is an empty string, and was expected to be non-empty. [ForwardsClientCalls] - public virtual async Task> GetMonitoringTagRuleAsync(string ruleSetName, CancellationToken cancellationToken = default) + public virtual async Task> GetMonitoredSubscriptionPropertyAsync(string configurationName, CancellationToken cancellationToken = default) { - return await GetMonitoringTagRules().GetAsync(ruleSetName, cancellationToken).ConfigureAwait(false); + return await GetMonitoredSubscriptionProperties().GetAsync(configurationName, cancellationToken).ConfigureAwait(false); } /// - /// Get a tag rule set for a given monitor resource. + /// List the subscriptions currently being monitored by the Datadog monitor resource. /// /// /// Request Path - /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/tagRules/{ruleSetName} + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} /// /// /// Operation Id - /// TagRules_Get + /// MonitoredSubscriptions_Get /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource - /// + /// /// /// /// - /// Rule set name. + /// The configuration name. Only 'default' value is supported. /// The cancellation token to use. - /// is null. - /// is an empty string, and was expected to be non-empty. + /// is null. + /// is an empty string, and was expected to be non-empty. [ForwardsClientCalls] - public virtual Response GetMonitoringTagRule(string ruleSetName, CancellationToken cancellationToken = default) + public virtual Response GetMonitoredSubscriptionProperty(string configurationName, CancellationToken cancellationToken = default) { - return GetMonitoringTagRules().Get(ruleSetName, cancellationToken); + return GetMonitoredSubscriptionProperties().Get(configurationName, cancellationToken); } /// Gets a collection of DatadogSingleSignOnResources in the DatadogMonitorResource. @@ -183,7 +184,7 @@ public virtual DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResou /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -214,7 +215,7 @@ public virtual async Task> GetDatadogSingl /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -232,6 +233,75 @@ public virtual Response GetDatadogSingleSignOnResou return GetDatadogSingleSignOnResources().Get(configurationName, cancellationToken); } + /// Gets a collection of MonitoringTagRuleResources in the DatadogMonitorResource. + /// An object representing collection of MonitoringTagRuleResources and their operations over a MonitoringTagRuleResource. + public virtual MonitoringTagRuleCollection GetMonitoringTagRules() + { + return GetCachedClient(client => new MonitoringTagRuleCollection(client, Id)); + } + + /// + /// Get a tag rule set for a given monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/tagRules/{ruleSetName} + /// + /// + /// Operation Id + /// TagRules_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// Rule set name. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + [ForwardsClientCalls] + public virtual async Task> GetMonitoringTagRuleAsync(string ruleSetName, CancellationToken cancellationToken = default) + { + return await GetMonitoringTagRules().GetAsync(ruleSetName, cancellationToken).ConfigureAwait(false); + } + + /// + /// Get a tag rule set for a given monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/tagRules/{ruleSetName} + /// + /// + /// Operation Id + /// TagRules_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// Rule set name. + /// The cancellation token to use. + /// is null. + /// is an empty string, and was expected to be non-empty. + [ForwardsClientCalls] + public virtual Response GetMonitoringTagRule(string ruleSetName, CancellationToken cancellationToken = default) + { + return GetMonitoringTagRules().Get(ruleSetName, cancellationToken); + } + /// /// Get the properties of a specific monitor resource. /// @@ -245,7 +315,7 @@ public virtual Response GetDatadogSingleSignOnResou /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -285,7 +355,7 @@ public virtual async Task> GetAsync(Cancellatio /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -325,7 +395,7 @@ public virtual Response Get(CancellationToken cancellati /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -367,7 +437,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -409,7 +479,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -455,7 +525,7 @@ public virtual async Task> UpdateAsync(Wait /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -488,66 +558,6 @@ public virtual ArmOperation Update(WaitUntil waitUntil, } } - /// - /// List the api keys for a given monitor resource. - /// - /// - /// Request Path - /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/listApiKeys - /// - /// - /// Operation Id - /// Monitors_ListApiKeys - /// - /// - /// Default Api Version - /// 2021-03-01 - /// - /// - /// Resource - /// - /// - /// - /// - /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetApiKeysAsync(CancellationToken cancellationToken = default) - { - HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogApiKey.DeserializeDatadogApiKey(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); - } - - /// - /// List the api keys for a given monitor resource. - /// - /// - /// Request Path - /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/listApiKeys - /// - /// - /// Operation Id - /// Monitors_ListApiKeys - /// - /// - /// Default Api Version - /// 2021-03-01 - /// - /// - /// Resource - /// - /// - /// - /// - /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetApiKeys(CancellationToken cancellationToken = default) - { - HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogApiKey.DeserializeDatadogApiKey(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); - } - /// /// Get the default api key. /// @@ -561,7 +571,7 @@ public virtual Pageable GetApiKeys(CancellationToken cancellation /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -599,7 +609,7 @@ public virtual async Task> GetDefaultKeyAsync(Cancellati /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -625,19 +635,19 @@ public virtual Response GetDefaultKey(CancellationToken cancellat } /// - /// Set the default api key. + /// List the api keys for a given monitor resource. /// /// /// Request Path - /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/setDefaultKey + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/listApiKeys /// /// /// Operation Id - /// Monitors_SetDefaultKey + /// Monitors_ListApiKeys /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -645,38 +655,29 @@ public virtual Response GetDefaultKey(CancellationToken cancellat /// /// /// - /// The to use. /// The cancellation token to use. - public virtual async Task SetDefaultKeyAsync(DatadogApiKey body = null, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetApiKeysAsync(CancellationToken cancellationToken = default) { - using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); - scope.Start(); - try - { - var response = await _datadogMonitorResourceMonitorsRestClient.SetDefaultKeyAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken).ConfigureAwait(false); - return response; - } - catch (Exception e) - { - scope.Failed(e); - throw; - } + HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogApiKey.DeserializeDatadogApiKey(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); } /// - /// Set the default api key. + /// List the api keys for a given monitor resource. /// /// /// Request Path - /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/setDefaultKey + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/listApiKeys /// /// /// Operation Id - /// Monitors_SetDefaultKey + /// Monitors_ListApiKeys /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -684,22 +685,13 @@ public virtual async Task SetDefaultKeyAsync(DatadogApiKey body = null /// /// /// - /// The to use. /// The cancellation token to use. - public virtual Response SetDefaultKey(DatadogApiKey body = null, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetApiKeys(CancellationToken cancellationToken = default) { - using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); - scope.Start(); - try - { - var response = _datadogMonitorResourceMonitorsRestClient.SetDefaultKey(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken); - return response; - } - catch (Exception e) - { - scope.Failed(e); - throw; - } + HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogApiKey.DeserializeDatadogApiKey(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); } /// @@ -715,7 +707,7 @@ public virtual Response SetDefaultKey(DatadogApiKey body = null, CancellationTok /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -745,7 +737,7 @@ public virtual AsyncPageable GetHostsAsync(CancellationToken cancel /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -775,7 +767,7 @@ public virtual Pageable GetHosts(CancellationToken cancellationToke /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -784,12 +776,12 @@ public virtual Pageable GetHosts(CancellationToken cancellationToke /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetLinkedResourcesAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetLinkedResourcesAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => ModelReaderWriter.Read(new BinaryData(Encoding.UTF8.GetBytes(e.GetRawText())), ModelSerializationExtensions.WireOptions, AzureResourceManagerDatadogContext.Default), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => LinkedInfo.DeserializeLinkedInfo(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); } /// @@ -805,7 +797,7 @@ public virtual AsyncPageable GetLinkedResourcesAsync(CancellationTo /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -814,12 +806,12 @@ public virtual AsyncPageable GetLinkedResourcesAsync(CancellationTo /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetLinkedResources(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetLinkedResources(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => ModelReaderWriter.Read(new BinaryData(Encoding.UTF8.GetBytes(e.GetRawText())), ModelSerializationExtensions.WireOptions, AzureResourceManagerDatadogContext.Default), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => LinkedInfo.DeserializeLinkedInfo(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); } /// @@ -835,7 +827,7 @@ public virtual Pageable GetLinkedResources(CancellationToken cancel /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -865,7 +857,7 @@ public virtual AsyncPageable GetMonitoredResourcesAsyn /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -895,7 +887,7 @@ public virtual Pageable GetMonitoredResources(Cancella /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -933,7 +925,7 @@ public virtual async Task> RefreshSetPasswordLi /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -958,6 +950,152 @@ public virtual Response RefreshSetPasswordLink(Cancellat } } + /// + /// Set the default api key. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/setDefaultKey + /// + /// + /// Operation Id + /// Monitors_SetDefaultKey + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The to use. + /// The cancellation token to use. + public virtual async Task SetDefaultKeyAsync(DatadogApiKey body = null, CancellationToken cancellationToken = default) + { + using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); + scope.Start(); + try + { + var response = await _datadogMonitorResourceMonitorsRestClient.SetDefaultKeyAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken).ConfigureAwait(false); + return response; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Set the default api key. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/setDefaultKey + /// + /// + /// Operation Id + /// Monitors_SetDefaultKey + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The to use. + /// The cancellation token to use. + public virtual Response SetDefaultKey(DatadogApiKey body = null, CancellationToken cancellationToken = default) + { + using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); + scope.Start(); + try + { + var response = _datadogMonitorResourceMonitorsRestClient.SetDefaultKey(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken); + return response; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get marketplace and organization info mapped to the given monitor. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/getBillingInfo + /// + /// + /// Operation Id + /// BillingInfo_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// The cancellation token to use. + public virtual async Task> GetBillingInfoAsync(CancellationToken cancellationToken = default) + { + using var scope = _billingInfoClientDiagnostics.CreateScope("DatadogMonitorResource.GetBillingInfo"); + scope.Start(); + try + { + var response = await _billingInfoRestClient.GetAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, cancellationToken).ConfigureAwait(false); + return response; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Get marketplace and organization info mapped to the given monitor. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/getBillingInfo + /// + /// + /// Operation Id + /// BillingInfo_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// The cancellation token to use. + public virtual Response GetBillingInfo(CancellationToken cancellationToken = default) + { + using var scope = _billingInfoClientDiagnostics.CreateScope("DatadogMonitorResource.GetBillingInfo"); + scope.Start(); + try + { + var response = _billingInfoRestClient.Get(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, cancellationToken); + return response; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + /// /// Add a tag to the current resource. /// @@ -971,7 +1109,7 @@ public virtual Response RefreshSetPasswordLink(Cancellat /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -1033,7 +1171,7 @@ public virtual async Task> AddTagAsync(string k /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -1095,7 +1233,7 @@ public virtual Response AddTag(string key, string value, /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -1152,7 +1290,7 @@ public virtual async Task> SetTagsAsync(IDictio /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -1209,7 +1347,7 @@ public virtual Response SetTags(IDictionary /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -1269,7 +1407,7 @@ public virtual async Task> RemoveTagAsync(strin /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs index 2e00fa6231c7..b6120a4bf2f2 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs @@ -65,7 +65,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -114,7 +114,7 @@ public virtual async Task> CreateOrUpdateAs /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -163,7 +163,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil wai /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -208,7 +208,7 @@ public virtual async Task> GetAsync(string moni /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -253,7 +253,7 @@ public virtual Response Get(string monitorName, Cancella /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -283,7 +283,7 @@ public virtual AsyncPageable GetAllAsync(CancellationTok /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -313,7 +313,7 @@ public virtual Pageable GetAll(CancellationToken cancell /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -356,7 +356,7 @@ public virtual async Task> ExistsAsync(string monitorName, Cancel /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -399,7 +399,7 @@ public virtual Response Exists(string monitorName, CancellationToken cance /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -444,7 +444,7 @@ public virtual async Task> GetIfExistsA /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.Serialization.cs index 3a21ef029fde..36887b5d4564 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.Serialization.cs @@ -38,16 +38,16 @@ protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWri } base.JsonModelWriteCore(writer, options); - if (Optional.IsDefined(Sku)) - { - writer.WritePropertyName("sku"u8); - writer.WriteObjectValue(Sku, options); - } if (Optional.IsDefined(Properties)) { writer.WritePropertyName("properties"u8); writer.WriteObjectValue(Properties, options); } + if (Optional.IsDefined(Sku)) + { + writer.WritePropertyName("sku"u8); + writer.WriteObjectValue(Sku, options); + } if (Optional.IsDefined(Identity)) { writer.WritePropertyName("identity"u8); @@ -75,8 +75,8 @@ internal static DatadogMonitorResourceData DeserializeDatadogMonitorResourceData { return null; } - ResourceSku sku = default; MonitorProperties properties = default; + ResourceSku sku = default; ManagedServiceIdentity identity = default; IDictionary tags = default; AzureLocation location = default; @@ -88,22 +88,22 @@ internal static DatadogMonitorResourceData DeserializeDatadogMonitorResourceData Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { - if (property.NameEquals("sku"u8)) + if (property.NameEquals("properties"u8)) { if (property.Value.ValueKind == JsonValueKind.Null) { continue; } - sku = ResourceSku.DeserializeResourceSku(property.Value, options); + properties = MonitorProperties.DeserializeMonitorProperties(property.Value, options); continue; } - if (property.NameEquals("properties"u8)) + if (property.NameEquals("sku"u8)) { if (property.Value.ValueKind == JsonValueKind.Null) { continue; } - properties = MonitorProperties.DeserializeMonitorProperties(property.Value, options); + sku = ResourceSku.DeserializeResourceSku(property.Value, options); continue; } if (property.NameEquals("identity"u8)) @@ -171,8 +171,8 @@ internal static DatadogMonitorResourceData DeserializeDatadogMonitorResourceData systemData, tags ?? new ChangeTrackingDictionary(), location, - sku, properties, + sku, identity, serializedAdditionalRawData); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs index 1cb677445207..91bfaf4a23e1 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs @@ -13,7 +13,10 @@ namespace Azure.ResourceManager.Datadog { - /// A class representing the DatadogMonitorResource data model. + /// + /// A class representing the DatadogMonitorResource data model. + /// Concrete tracked resource types can be created by aliasing this type using a specific property type. + /// public partial class DatadogMonitorResourceData : TrackedResourceData { /// @@ -61,14 +64,14 @@ public DatadogMonitorResourceData(AzureLocation location) : base(location) /// The systemData. /// The tags. /// The location. - /// /// Properties specific to the monitor resource. + /// Represents the SKU of a resource. /// Gets or sets the identity. Current supported identity types: SystemAssigned, UserAssigned. /// Keeps track of any properties unknown to the library. - internal DatadogMonitorResourceData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, IDictionary tags, AzureLocation location, ResourceSku sku, MonitorProperties properties, ManagedServiceIdentity identity, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData, tags, location) + internal DatadogMonitorResourceData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, IDictionary tags, AzureLocation location, MonitorProperties properties, ResourceSku sku, ManagedServiceIdentity identity, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData, tags, location) { - Sku = sku; Properties = properties; + Sku = sku; Identity = identity; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -78,17 +81,17 @@ internal DatadogMonitorResourceData() { } - /// Gets or sets the sku. + /// Properties specific to the monitor resource. + public MonitorProperties Properties { get; set; } + /// Represents the SKU of a resource. internal ResourceSku Sku { get; set; } - /// Name of the SKU. + /// The name of the SKU. public string SkuName { get => Sku is null ? default : Sku.Name; set => Sku = new ResourceSku(value); } - /// Properties specific to the monitor resource. - public MonitorProperties Properties { get; set; } /// Gets or sets the identity. Current supported identity types: SystemAssigned, UserAssigned. public ManagedServiceIdentity Identity { get; set; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs index 249f4195b7a9..03f698358feb 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(Cancel /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken cance /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -227,7 +227,7 @@ public virtual async Task> UpdateAsync /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs index b070cf293b74..e20111693211 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -113,7 +113,7 @@ public virtual async Task> CreateOrUpd /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -162,7 +162,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUnti /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -207,7 +207,7 @@ public virtual async Task> GetAsync(string /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -252,7 +252,7 @@ public virtual Response Get(string configurationNam /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -282,7 +282,7 @@ public virtual AsyncPageable GetAllAsync(Cancellati /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -312,7 +312,7 @@ public virtual Pageable GetAll(CancellationToken ca /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -355,7 +355,7 @@ public virtual async Task> ExistsAsync(string configurationName, /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -398,7 +398,7 @@ public virtual Response Exists(string configurationName, CancellationToken /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -443,7 +443,7 @@ public virtual async Task> GetIfEx /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceData.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceData.cs index a3e010664292..c388490d7af5 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceData.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceData.cs @@ -13,7 +13,10 @@ namespace Azure.ResourceManager.Datadog { - /// A class representing the DatadogSingleSignOnResource data model. + /// + /// A class representing the DatadogSingleSignOnResource data model. + /// Concrete proxy resource types can be created by aliasing this type using a specific property type. + /// public partial class DatadogSingleSignOnResourceData : ResourceData { /// diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs index 3ccd2696b82a..a46ff4e67607 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs @@ -53,22 +53,22 @@ public static DatadogMonitorResource GetDatadogMonitorResource(this ArmClient cl } /// - /// Gets an object representing a along with the instance operations that can be performed on it but with no data. - /// You can use to create a from its components. + /// Gets an object representing a along with the instance operations that can be performed on it but with no data. + /// You can use to create a from its components. /// /// Mocking - /// To mock this method, please mock instead. + /// To mock this method, please mock instead. /// /// /// The instance the method will execute against. /// The resource ID of the resource to get. /// is null. - /// Returns a object. - public static MonitoringTagRuleResource GetMonitoringTagRuleResource(this ArmClient client, ResourceIdentifier id) + /// Returns a object. + public static MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this ArmClient client, ResourceIdentifier id) { Argument.AssertNotNull(client, nameof(client)); - return GetMockableDatadogArmClient(client).GetMonitoringTagRuleResource(id); + return GetMockableDatadogArmClient(client).GetMonitoredSubscriptionPropertyResource(id); } /// @@ -90,6 +90,25 @@ public static DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Ar return GetMockableDatadogArmClient(client).GetDatadogSingleSignOnResource(id); } + /// + /// Gets an object representing a along with the instance operations that can be performed on it but with no data. + /// You can use to create a from its components. + /// + /// Mocking + /// To mock this method, please mock instead. + /// + /// + /// The instance the method will execute against. + /// The resource ID of the resource to get. + /// is null. + /// Returns a object. + public static MonitoringTagRuleResource GetMonitoringTagRuleResource(this ArmClient client, ResourceIdentifier id) + { + Argument.AssertNotNull(client, nameof(client)); + + return GetMockableDatadogArmClient(client).GetMonitoringTagRuleResource(id); + } + /// /// Gets a collection of DatadogMonitorResources in the ResourceGroupResource. /// @@ -120,7 +139,7 @@ public static DatadogMonitorResourceCollection GetDatadogMonitorResources(this R /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -158,7 +177,7 @@ public static async Task> GetDatadogMonitorReso /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -196,7 +215,7 @@ public static Response GetDatadogMonitorResource(this Re /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// @@ -228,7 +247,7 @@ public static AsyncPageable GetMarketplaceAg /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// @@ -260,7 +279,7 @@ public static Pageable GetMarketplaceAgreeme /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// @@ -269,7 +288,7 @@ public static Pageable GetMarketplaceAgreeme /// /// /// The instance the method will execute against. - /// The to use. + /// The request body. /// The cancellation token to use. /// is null. public static async Task> CreateOrUpdateMarketplaceAgreementAsync(this SubscriptionResource subscriptionResource, DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) @@ -292,7 +311,7 @@ public static async Task> CreateOrU /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// @@ -301,7 +320,7 @@ public static async Task> CreateOrU /// /// /// The instance the method will execute against. - /// The to use. + /// The request body. /// The cancellation token to use. /// is null. public static Response CreateOrUpdateMarketplaceAgreement(this SubscriptionResource subscriptionResource, DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) @@ -324,7 +343,7 @@ public static Response CreateOrUpdateMarketp /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -360,7 +379,7 @@ public static AsyncPageable GetDatadogMonitorResourcesAs /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -382,5 +401,135 @@ public static Pageable GetDatadogMonitorResources(this S return GetMockableDatadogSubscriptionResource(subscriptionResource).GetDatadogMonitorResources(cancellationToken); } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses + /// + /// + /// Operation Id + /// CreationSupported_List + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Mocking + /// To mock this method, please mock instead. + /// + /// + /// The instance the method will execute against. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + /// An async collection of that may take multiple service requests to iterate over. + public static AsyncPageable GetCreationSupportedsAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); + + return GetMockableDatadogSubscriptionResource(subscriptionResource).GetCreationSupportedsAsync(datadogOrganizationId, cancellationToken); + } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses + /// + /// + /// Operation Id + /// CreationSupported_List + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Mocking + /// To mock this method, please mock instead. + /// + /// + /// The instance the method will execute against. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + /// A collection of that may take multiple service requests to iterate over. + public static Pageable GetCreationSupporteds(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); + + return GetMockableDatadogSubscriptionResource(subscriptionResource).GetCreationSupporteds(datadogOrganizationId, cancellationToken); + } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses/default + /// + /// + /// Operation Id + /// CreationSupported_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Mocking + /// To mock this method, please mock instead. + /// + /// + /// The instance the method will execute against. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + public static async Task> GetCreationSupportedAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); + + return await GetMockableDatadogSubscriptionResource(subscriptionResource).GetCreationSupportedAsync(datadogOrganizationId, cancellationToken).ConfigureAwait(false); + } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses/default + /// + /// + /// Operation Id + /// CreationSupported_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Mocking + /// To mock this method, please mock instead. + /// + /// + /// The instance the method will execute against. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + public static Response GetCreationSupported(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); + + return GetMockableDatadogSubscriptionResource(subscriptionResource).GetCreationSupported(datadogOrganizationId, cancellationToken); + } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogArmClient.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogArmClient.cs index 7246ba834fff..4f8f66508564 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogArmClient.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogArmClient.cs @@ -47,15 +47,15 @@ public virtual DatadogMonitorResource GetDatadogMonitorResource(ResourceIdentifi } /// - /// Gets an object representing a along with the instance operations that can be performed on it but with no data. - /// You can use to create a from its components. + /// Gets an object representing a along with the instance operations that can be performed on it but with no data. + /// You can use to create a from its components. /// /// The resource ID of the resource to get. - /// Returns a object. - public virtual MonitoringTagRuleResource GetMonitoringTagRuleResource(ResourceIdentifier id) + /// Returns a object. + public virtual MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(ResourceIdentifier id) { - MonitoringTagRuleResource.ValidateResourceId(id); - return new MonitoringTagRuleResource(Client, id); + MonitoredSubscriptionPropertyResource.ValidateResourceId(id); + return new MonitoredSubscriptionPropertyResource(Client, id); } /// @@ -69,5 +69,17 @@ public virtual DatadogSingleSignOnResource GetDatadogSingleSignOnResource(Resour DatadogSingleSignOnResource.ValidateResourceId(id); return new DatadogSingleSignOnResource(Client, id); } + + /// + /// Gets an object representing a along with the instance operations that can be performed on it but with no data. + /// You can use to create a from its components. + /// + /// The resource ID of the resource to get. + /// Returns a object. + public virtual MonitoringTagRuleResource GetMonitoringTagRuleResource(ResourceIdentifier id) + { + MonitoringTagRuleResource.ValidateResourceId(id); + return new MonitoringTagRuleResource(Client, id); + } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs index d7f7a5ce5c05..cf8023142f7e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs @@ -53,7 +53,7 @@ public virtual DatadogMonitorResourceCollection GetDatadogMonitorResources() /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -84,7 +84,7 @@ public virtual async Task> GetDatadogMonitorRes /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs index e083c6e15891..d8658f57ec61 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs @@ -22,6 +22,8 @@ public partial class MockableDatadogSubscriptionResource : ArmResource private MarketplaceAgreementsRestOperations _marketplaceAgreementsRestClient; private ClientDiagnostics _datadogMonitorResourceMonitorsClientDiagnostics; private MonitorsRestOperations _datadogMonitorResourceMonitorsRestClient; + private ClientDiagnostics _creationSupportedClientDiagnostics; + private CreationSupportedRestOperations _creationSupportedRestClient; /// Initializes a new instance of the class for mocking. protected MockableDatadogSubscriptionResource() @@ -39,6 +41,8 @@ internal MockableDatadogSubscriptionResource(ArmClient client, ResourceIdentifie private MarketplaceAgreementsRestOperations MarketplaceAgreementsRestClient => _marketplaceAgreementsRestClient ??= new MarketplaceAgreementsRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint); private ClientDiagnostics DatadogMonitorResourceMonitorsClientDiagnostics => _datadogMonitorResourceMonitorsClientDiagnostics ??= new ClientDiagnostics("Azure.ResourceManager.Datadog", DatadogMonitorResource.ResourceType.Namespace, Diagnostics); private MonitorsRestOperations DatadogMonitorResourceMonitorsRestClient => _datadogMonitorResourceMonitorsRestClient ??= new MonitorsRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint, GetApiVersionOrNull(DatadogMonitorResource.ResourceType)); + private ClientDiagnostics CreationSupportedClientDiagnostics => _creationSupportedClientDiagnostics ??= new ClientDiagnostics("Azure.ResourceManager.Datadog", ProviderConstants.DefaultProviderNamespace, Diagnostics); + private CreationSupportedRestOperations CreationSupportedRestClient => _creationSupportedRestClient ??= new CreationSupportedRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint); private string GetApiVersionOrNull(ResourceType resourceType) { @@ -59,7 +63,7 @@ private string GetApiVersionOrNull(ResourceType resourceType) /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// @@ -85,7 +89,7 @@ public virtual AsyncPageable GetMarketplaceA /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// @@ -111,11 +115,11 @@ public virtual Pageable GetMarketplaceAgreem /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// - /// The to use. + /// The request body. /// The cancellation token to use. public virtual async Task> CreateOrUpdateMarketplaceAgreementAsync(DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) { @@ -146,11 +150,11 @@ public virtual async Task> CreateOr /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// - /// The to use. + /// The request body. /// The cancellation token to use. public virtual Response CreateOrUpdateMarketplaceAgreement(DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) { @@ -181,7 +185,7 @@ public virtual Response CreateOrUpdateMarket /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -211,7 +215,7 @@ public virtual AsyncPageable GetDatadogMonitorResourcesA /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -227,5 +231,141 @@ public virtual Pageable GetDatadogMonitorResources(Cance HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => DatadogMonitorResourceMonitorsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId); return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => new DatadogMonitorResource(Client, DatadogMonitorResourceData.DeserializeDatadogMonitorResourceData(e)), DatadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetDatadogMonitorResources", "value", "nextLink", cancellationToken); } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses + /// + /// + /// Operation Id + /// CreationSupported_List + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Datadog Organization Id. + /// The cancellation token to use. + /// is null. + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + HttpMessage FirstPageRequest(int? pageSizeHint) => CreationSupportedRestClient.CreateListRequest(Id.SubscriptionId, datadogOrganizationId); + HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreationSupportedRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, datadogOrganizationId); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); + } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses + /// + /// + /// Operation Id + /// CreationSupported_List + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Datadog Organization Id. + /// The cancellation token to use. + /// is null. + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetCreationSupporteds(string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + HttpMessage FirstPageRequest(int? pageSizeHint) => CreationSupportedRestClient.CreateListRequest(Id.SubscriptionId, datadogOrganizationId); + HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreationSupportedRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, datadogOrganizationId); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); + } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses/default + /// + /// + /// Operation Id + /// CreationSupported_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Datadog Organization Id. + /// The cancellation token to use. + /// is null. + public virtual async Task> GetCreationSupportedAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var scope = CreationSupportedClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.GetCreationSupported"); + scope.Start(); + try + { + var response = await CreationSupportedRestClient.GetAsync(Id.SubscriptionId, datadogOrganizationId, cancellationToken).ConfigureAwait(false); + return response; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/providers/Microsoft.Datadog/subscriptionStatuses/default + /// + /// + /// Operation Id + /// CreationSupported_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// + /// Datadog Organization Id. + /// The cancellation token to use. + /// is null. + public virtual Response GetCreationSupported(string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var scope = CreationSupportedClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.GetCreationSupported"); + scope.Start(); + try + { + var response = CreationSupportedRestClient.Get(Id.SubscriptionId, datadogOrganizationId, cancellationToken); + return response; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/LongRunningOperation/MonitoredSubscriptionPropertyOperationSource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/LongRunningOperation/MonitoredSubscriptionPropertyOperationSource.cs new file mode 100644 index 000000000000..9df122cd6126 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/LongRunningOperation/MonitoredSubscriptionPropertyOperationSource.cs @@ -0,0 +1,36 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System.ClientModel.Primitives; +using System.Threading; +using System.Threading.Tasks; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog +{ + internal class MonitoredSubscriptionPropertyOperationSource : IOperationSource + { + private readonly ArmClient _client; + + internal MonitoredSubscriptionPropertyOperationSource(ArmClient client) + { + _client = client; + } + + MonitoredSubscriptionPropertyResource IOperationSource.CreateResult(Response response, CancellationToken cancellationToken) + { + var data = ModelReaderWriter.Read(response.Content, ModelReaderWriterOptions.Json, AzureResourceManagerDatadogContext.Default); + return new MonitoredSubscriptionPropertyResource(_client, data); + } + + async ValueTask IOperationSource.CreateResultAsync(Response response, CancellationToken cancellationToken) + { + var data = ModelReaderWriter.Read(response.Content, ModelReaderWriterOptions.Json, AzureResourceManagerDatadogContext.Default); + return await Task.FromResult(new MonitoredSubscriptionPropertyResource(_client, data)).ConfigureAwait(false); + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs index 88ca5dbcf00b..d59ed830f6ae 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs @@ -8,7 +8,6 @@ using System.ClientModel.Primitives; using Azure.ResourceManager.Datadog.Models; using Azure.ResourceManager.Models; -using Azure.ResourceManager.Resources.Models; namespace Azure.ResourceManager.Datadog { @@ -16,11 +15,15 @@ namespace Azure.ResourceManager.Datadog /// Context class which will be filled in by the System.ClientModel.SourceGeneration. /// For more information see 'https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/System.ClientModel/src/docs/ModelReaderWriterContext.md' /// + [ModelReaderWriterBuildable(typeof(CreateResourceSupportedProperties))] + [ModelReaderWriterBuildable(typeof(CreateResourceSupportedResponseList))] [ModelReaderWriterBuildable(typeof(DatadogAgreementProperties))] [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceListResponse))] [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceProperties))] [ModelReaderWriterBuildable(typeof(DatadogApiKey))] [ModelReaderWriterBuildable(typeof(DatadogApiKeyListResponse))] + [ModelReaderWriterBuildable(typeof(DatadogBillingInfoResponseResult))] + [ModelReaderWriterBuildable(typeof(DatadogCreateResourceSupportedResponseResult))] [ModelReaderWriterBuildable(typeof(DatadogHost))] [ModelReaderWriterBuildable(typeof(DatadogHostListResponse))] [ModelReaderWriterBuildable(typeof(DatadogHostMetadata))] @@ -37,21 +40,28 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResourceData))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResourceListResponse))] [ModelReaderWriterBuildable(typeof(FilteringTag))] + [ModelReaderWriterBuildable(typeof(LinkedInfo))] [ModelReaderWriterBuildable(typeof(LinkedResourceListResponse))] [ModelReaderWriterBuildable(typeof(LogRules))] [ModelReaderWriterBuildable(typeof(ManagedServiceIdentity))] + [ModelReaderWriterBuildable(typeof(MarketplaceSaaSInfo))] [ModelReaderWriterBuildable(typeof(MetricRules))] [ModelReaderWriterBuildable(typeof(MonitoredResourceContent))] [ModelReaderWriterBuildable(typeof(MonitoredResourceListResponse))] + [ModelReaderWriterBuildable(typeof(MonitoredSubscription))] + [ModelReaderWriterBuildable(typeof(MonitoredSubscriptionPropertiesList))] + [ModelReaderWriterBuildable(typeof(MonitoredSubscriptionPropertyData))] + [ModelReaderWriterBuildable(typeof(MonitoredSubscriptionPropertyResource))] [ModelReaderWriterBuildable(typeof(MonitoringTagRuleData))] [ModelReaderWriterBuildable(typeof(MonitoringTagRuleResource))] [ModelReaderWriterBuildable(typeof(MonitoringTagRulesListResponse))] [ModelReaderWriterBuildable(typeof(MonitoringTagRulesProperties))] [ModelReaderWriterBuildable(typeof(MonitorProperties))] [ModelReaderWriterBuildable(typeof(MonitorUpdateProperties))] + [ModelReaderWriterBuildable(typeof(PartnerBillingEntity))] [ModelReaderWriterBuildable(typeof(ResourceSku))] [ModelReaderWriterBuildable(typeof(ResponseError))] - [ModelReaderWriterBuildable(typeof(SubResource))] + [ModelReaderWriterBuildable(typeof(SubscriptionList))] [ModelReaderWriterBuildable(typeof(SystemData))] [ModelReaderWriterBuildable(typeof(UserInfo))] public partial class AzureResourceManagerDatadogContext : ModelReaderWriterContext diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs new file mode 100644 index 000000000000..3624fd9665b5 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs @@ -0,0 +1,144 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class CreateResourceSupportedProperties : 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") + { + throw new FormatException($"The model {nameof(CreateResourceSupportedProperties)} does not support writing '{format}' format."); + } + + if (options.Format != "W" && Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (options.Format != "W" && Optional.IsDefined(CreationSupported)) + { + writer.WritePropertyName("creationSupported"u8); + writer.WriteBooleanValue(CreationSupported.Value); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + CreateResourceSupportedProperties IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(CreateResourceSupportedProperties)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeCreateResourceSupportedProperties(document.RootElement, options); + } + + internal static CreateResourceSupportedProperties DeserializeCreateResourceSupportedProperties(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + string name = default; + bool? creationSupported = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("creationSupported"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + creationSupported = property.Value.GetBoolean(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new CreateResourceSupportedProperties(name, creationSupported, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(CreateResourceSupportedProperties)} does not support writing '{options.Format}' format."); + } + } + + CreateResourceSupportedProperties IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeCreateResourceSupportedProperties(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(CreateResourceSupportedProperties)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs new file mode 100644 index 000000000000..5fa80014a575 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs @@ -0,0 +1,69 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Datadog resource can be created or not properties. + public partial class CreateResourceSupportedProperties + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal CreateResourceSupportedProperties() + { + } + + /// Initializes a new instance of . + /// The ARM id of the subscription. + /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. + /// Keeps track of any properties unknown to the library. + internal CreateResourceSupportedProperties(string name, bool? creationSupported, IDictionary serializedAdditionalRawData) + { + Name = name; + CreationSupported = creationSupported; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The ARM id of the subscription. + public string Name { get; } + /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. + public bool? CreationSupported { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.Serialization.cs new file mode 100644 index 000000000000..d6e2bd63ae5b --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.Serialization.cs @@ -0,0 +1,151 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + internal partial class CreateResourceSupportedResponseList : 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") + { + throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support writing '{format}' format."); + } + + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) + { + writer.WriteObjectValue(item, options); + } + writer.WriteEndArray(); + if (Optional.IsDefined(NextLink)) + { + writer.WritePropertyName("nextLink"u8); + writer.WriteStringValue(NextLink.AbsoluteUri); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + CreateResourceSupportedResponseList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeCreateResourceSupportedResponseList(document.RootElement, options); + } + + internal static CreateResourceSupportedResponseList DeserializeCreateResourceSupportedResponseList(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + IReadOnlyList value = default; + Uri nextLink = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("value"u8)) + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(item, options)); + } + value = array; + continue; + } + if (property.NameEquals("nextLink"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new CreateResourceSupportedResponseList(value, nextLink, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support writing '{options.Format}' format."); + } + } + + CreateResourceSupportedResponseList IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeCreateResourceSupportedResponseList(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.cs new file mode 100644 index 000000000000..b73c2107a43e --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.cs @@ -0,0 +1,80 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Linq; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Paged collection of CreateResourceSupportedResponse items. + internal partial class CreateResourceSupportedResponseList + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + /// The CreateResourceSupportedResponse items on this page. + /// is null. + internal CreateResourceSupportedResponseList(IEnumerable value) + { + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); + } + + /// Initializes a new instance of . + /// The CreateResourceSupportedResponse items on this page. + /// The link to the next page of items. + /// Keeps track of any properties unknown to the library. + internal CreateResourceSupportedResponseList(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + { + Value = value; + NextLink = nextLink; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Initializes a new instance of for deserialization. + internal CreateResourceSupportedResponseList() + { + } + + /// The CreateResourceSupportedResponse items on this page. + public IReadOnlyList Value { get; } + /// The link to the next page of items. + public Uri NextLink { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.Serialization.cs index 05cbc961adcb..0e274c855f6b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.Serialization.cs @@ -34,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(DatadogAgreementResourceListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - writer.WriteObjectValue(item, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -87,17 +84,13 @@ internal static DatadogAgreementResourceListResponse DeserializeDatadogAgreement return null; } IReadOnlyList value = default; - string nextLink = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -108,7 +101,11 @@ internal static DatadogAgreementResourceListResponse DeserializeDatadogAgreement } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -117,7 +114,7 @@ internal static DatadogAgreementResourceListResponse DeserializeDatadogAgreement } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogAgreementResourceListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new DatadogAgreementResourceListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.cs index 30f7fc575245..3d53e69d2a58 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -46,25 +47,34 @@ internal partial class DatadogAgreementResourceListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal DatadogAgreementResourceListResponse() + /// The DatadogAgreementResource items on this page. + /// is null. + internal DatadogAgreementResourceListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The DatadogAgreementResource items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogAgreementResourceListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal DatadogAgreementResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. + /// Initializes a new instance of for deserialization. + internal DatadogAgreementResourceListResponse() + { + } + + /// The DatadogAgreementResource items on this page. public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.Serialization.cs index 0367deb65681..ccd83e8c0a44 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.Serialization.cs @@ -34,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(DatadogApiKeyListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - writer.WriteObjectValue(item, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -87,17 +84,13 @@ internal static DatadogApiKeyListResponse DeserializeDatadogApiKeyListResponse(J return null; } IReadOnlyList value = default; - string nextLink = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -108,7 +101,11 @@ internal static DatadogApiKeyListResponse DeserializeDatadogApiKeyListResponse(J } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -117,7 +114,7 @@ internal static DatadogApiKeyListResponse DeserializeDatadogApiKeyListResponse(J } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogApiKeyListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new DatadogApiKeyListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.cs index f4e28af97451..a066ca0ba094 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -46,25 +47,34 @@ internal partial class DatadogApiKeyListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal DatadogApiKeyListResponse() + /// The DatadogApiKey items on this page. + /// is null. + internal DatadogApiKeyListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The DatadogApiKey items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogApiKeyListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal DatadogApiKeyListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. + /// Initializes a new instance of for deserialization. + internal DatadogApiKeyListResponse() + { + } + + /// The DatadogApiKey items on this page. public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.Serialization.cs new file mode 100644 index 000000000000..8295a783168c --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.Serialization.cs @@ -0,0 +1,148 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class DatadogBillingInfoResponseResult : 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") + { + throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(MarketplaceSaasInfo)) + { + writer.WritePropertyName("marketplaceSaasInfo"u8); + writer.WriteObjectValue(MarketplaceSaasInfo, options); + } + if (Optional.IsDefined(PartnerBillingEntity)) + { + writer.WritePropertyName("partnerBillingEntity"u8); + writer.WriteObjectValue(PartnerBillingEntity, options); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + DatadogBillingInfoResponseResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeDatadogBillingInfoResponseResult(document.RootElement, options); + } + + internal static DatadogBillingInfoResponseResult DeserializeDatadogBillingInfoResponseResult(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + MarketplaceSaaSInfo marketplaceSaasInfo = default; + PartnerBillingEntity partnerBillingEntity = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("marketplaceSaasInfo"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + marketplaceSaasInfo = MarketplaceSaaSInfo.DeserializeMarketplaceSaaSInfo(property.Value, options); + continue; + } + if (property.NameEquals("partnerBillingEntity"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + partnerBillingEntity = PartnerBillingEntity.DeserializePartnerBillingEntity(property.Value, options); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new DatadogBillingInfoResponseResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support writing '{options.Format}' format."); + } + } + + DatadogBillingInfoResponseResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeDatadogBillingInfoResponseResult(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.cs new file mode 100644 index 000000000000..1ab8053c7796 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.cs @@ -0,0 +1,69 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Marketplace Subscription and Organization details to which resource gets billed into. + public partial class DatadogBillingInfoResponseResult + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal DatadogBillingInfoResponseResult() + { + } + + /// Initializes a new instance of . + /// Marketplace Subscription details. + /// Partner Billing Entity details: Organization Info. + /// Keeps track of any properties unknown to the library. + internal DatadogBillingInfoResponseResult(MarketplaceSaaSInfo marketplaceSaasInfo, PartnerBillingEntity partnerBillingEntity, IDictionary serializedAdditionalRawData) + { + MarketplaceSaasInfo = marketplaceSaasInfo; + PartnerBillingEntity = partnerBillingEntity; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Marketplace Subscription details. + public MarketplaceSaaSInfo MarketplaceSaasInfo { get; } + /// Partner Billing Entity details: Organization Info. + public PartnerBillingEntity PartnerBillingEntity { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.Serialization.cs new file mode 100644 index 000000000000..9ba570b81a99 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.Serialization.cs @@ -0,0 +1,133 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class DatadogCreateResourceSupportedResponseResult : 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") + { + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(Properties)) + { + writer.WritePropertyName("properties"u8); + writer.WriteObjectValue(Properties, options); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + DatadogCreateResourceSupportedResponseResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement, options); + } + + internal static DatadogCreateResourceSupportedResponseResult DeserializeDatadogCreateResourceSupportedResponseResult(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + CreateResourceSupportedProperties properties = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("properties"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + properties = CreateResourceSupportedProperties.DeserializeCreateResourceSupportedProperties(property.Value, options); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new DatadogCreateResourceSupportedResponseResult(properties, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support writing '{options.Format}' format."); + } + } + + DatadogCreateResourceSupportedResponseResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.cs new file mode 100644 index 000000000000..16dd65443c66 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.cs @@ -0,0 +1,65 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Datadog resource can be created or not. + public partial class DatadogCreateResourceSupportedResponseResult + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal DatadogCreateResourceSupportedResponseResult() + { + } + + /// Initializes a new instance of . + /// Represents the properties of the resource. + /// Keeps track of any properties unknown to the library. + internal DatadogCreateResourceSupportedResponseResult(CreateResourceSupportedProperties properties, IDictionary serializedAdditionalRawData) + { + Properties = properties; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Represents the properties of the resource. + public CreateResourceSupportedProperties Properties { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHost.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHost.cs index 0cccb61c9801..54c08039d974 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHost.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHost.cs @@ -54,7 +54,7 @@ internal DatadogHost() /// Initializes a new instance of . /// The name of the host. - /// The aliases for the host. + /// The aliases for the host installed via the Datadog agent. /// The Datadog integrations reporting metrics for the host. /// /// Keeps track of any properties unknown to the library. @@ -69,7 +69,7 @@ internal DatadogHost(string name, IReadOnlyList aliases, IReadOnlyList The name of the host. public string Name { get; } - /// The aliases for the host. + /// The aliases for the host installed via the Datadog agent. public IReadOnlyList Aliases { get; } /// The Datadog integrations reporting metrics for the host. public IReadOnlyList Apps { get; } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.Serialization.cs index 2f74f398c31b..c25b978865d0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.Serialization.cs @@ -34,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(DatadogHostListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - writer.WriteObjectValue(item, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -87,17 +84,13 @@ internal static DatadogHostListResponse DeserializeDatadogHostListResponse(JsonE return null; } IReadOnlyList value = default; - string nextLink = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -108,7 +101,11 @@ internal static DatadogHostListResponse DeserializeDatadogHostListResponse(JsonE } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -117,7 +114,7 @@ internal static DatadogHostListResponse DeserializeDatadogHostListResponse(JsonE } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogHostListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new DatadogHostListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.cs index b068a79729a9..c4de4766bf59 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -46,25 +47,34 @@ internal partial class DatadogHostListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal DatadogHostListResponse() + /// The DatadogHost items on this page. + /// is null. + internal DatadogHostListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The DatadogHost items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogHostListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal DatadogHostListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. + /// Initializes a new instance of for deserialization. + internal DatadogHostListResponse() + { + } + + /// The DatadogHost items on this page. public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.Serialization.cs index d09a0aed512b..428baf825728 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.Serialization.cs @@ -34,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(DatadogMonitorResourceListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - writer.WriteObjectValue(item, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -87,17 +84,13 @@ internal static DatadogMonitorResourceListResponse DeserializeDatadogMonitorReso return null; } IReadOnlyList value = default; - string nextLink = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -108,7 +101,11 @@ internal static DatadogMonitorResourceListResponse DeserializeDatadogMonitorReso } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -117,7 +114,7 @@ internal static DatadogMonitorResourceListResponse DeserializeDatadogMonitorReso } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogMonitorResourceListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new DatadogMonitorResourceListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.cs index 853af5c64878..d25831fca794 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -46,25 +47,34 @@ internal partial class DatadogMonitorResourceListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal DatadogMonitorResourceListResponse() + /// The DatadogMonitorResource items on this page. + /// is null. + internal DatadogMonitorResourceListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The DatadogMonitorResource items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogMonitorResourceListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal DatadogMonitorResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. + /// Initializes a new instance of for deserialization. + internal DatadogMonitorResourceListResponse() + { + } + + /// The DatadogMonitorResource items on this page. public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs index 5a47319dd0b0..e942b976aa35 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs @@ -54,7 +54,7 @@ public DatadogMonitorResourcePatch() /// Initializes a new instance of . /// The set of properties that can be update in a PATCH request to a monitor resource. /// The new tags of the monitor resource. - /// + /// Represents the SKU of a resource. /// Keeps track of any properties unknown to the library. internal DatadogMonitorResourcePatch(MonitorUpdateProperties properties, IDictionary tags, ResourceSku sku, IDictionary serializedAdditionalRawData) { @@ -65,24 +65,12 @@ internal DatadogMonitorResourcePatch(MonitorUpdateProperties properties, IDictio } /// The set of properties that can be update in a PATCH request to a monitor resource. - internal MonitorUpdateProperties Properties { get; set; } - /// Flag specifying if the resource monitoring is enabled or disabled. - public MonitoringStatus? MonitorUpdateMonitoringStatus - { - get => Properties is null ? default : Properties.MonitoringStatus; - set - { - if (Properties is null) - Properties = new MonitorUpdateProperties(); - Properties.MonitoringStatus = value; - } - } - + public MonitorUpdateProperties Properties { get; set; } /// The new tags of the monitor resource. public IDictionary Tags { get; } - /// Gets or sets the sku. + /// Represents the SKU of a resource. internal ResourceSku Sku { get; set; } - /// Name of the SKU. + /// The name of the SKU. public string SkuName { get => Sku is null ? default : Sku.Name; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs index 233ae8e790cb..5bb76d078f56 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs @@ -34,12 +34,12 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(DatadogOrganizationProperties)} does not support writing '{format}' format."); } - if (options.Format != "W" && Optional.IsDefined(Name)) + if (Optional.IsDefined(Name)) { writer.WritePropertyName("name"u8); writer.WriteStringValue(Name); } - if (options.Format != "W" && Optional.IsDefined(Id)) + if (Optional.IsDefined(Id)) { writer.WritePropertyName("id"u8); writer.WriteStringValue(Id); @@ -74,6 +74,11 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("enterpriseAppId"u8); writer.WriteStringValue(EnterpriseAppId); } + if (Optional.IsDefined(Cspm)) + { + writer.WritePropertyName("cspm"u8); + writer.WriteBooleanValue(Cspm.Value); + } if (options.Format != "W" && _serializedAdditionalRawData != null) { foreach (var item in _serializedAdditionalRawData) @@ -119,6 +124,7 @@ internal static DatadogOrganizationProperties DeserializeDatadogOrganizationProp string apiKey = default; string applicationKey = default; string enterpriseAppId = default; + bool? cspm = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) @@ -167,6 +173,15 @@ internal static DatadogOrganizationProperties DeserializeDatadogOrganizationProp enterpriseAppId = property.Value.GetString(); continue; } + if (property.NameEquals("cspm"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + cspm = property.Value.GetBoolean(); + continue; + } if (options.Format != "W") { rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); @@ -182,6 +197,7 @@ internal static DatadogOrganizationProperties DeserializeDatadogOrganizationProp apiKey, applicationKey, enterpriseAppId, + cspm, serializedAdditionalRawData); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs index d40c9a0d7918..61285439da74 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs @@ -10,7 +10,7 @@ namespace Azure.ResourceManager.Datadog.Models { - /// Datadog organization properties. + /// Specify the Datadog organization name. In the case of linking to existing organizations, Id, ApiKey, and Applicationkey is required as well. public partial class DatadogOrganizationProperties { /// @@ -53,14 +53,15 @@ public DatadogOrganizationProperties() /// Initializes a new instance of . /// Name of the Datadog organization. /// Id of the Datadog organization. - /// The auth code used to linking to an existing datadog organization. + /// The auth code used to linking to an existing Datadog organization. /// The client_id from an existing in exchange for an auth token to link organization. - /// The redirect uri for linking. + /// The redirect URI for linking. /// Api key associated to the Datadog organization. /// Application key associated to the Datadog organization. /// The Id of the Enterprise App used for Single sign on. + /// The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. /// Keeps track of any properties unknown to the library. - internal DatadogOrganizationProperties(string name, string id, string linkingAuthCode, string linkingClientId, Uri redirectUri, string apiKey, string applicationKey, string enterpriseAppId, IDictionary serializedAdditionalRawData) + internal DatadogOrganizationProperties(string name, string id, string linkingAuthCode, string linkingClientId, Uri redirectUri, string apiKey, string applicationKey, string enterpriseAppId, bool? cspm, IDictionary serializedAdditionalRawData) { Name = name; Id = id; @@ -70,18 +71,19 @@ internal DatadogOrganizationProperties(string name, string id, string linkingAut ApiKey = apiKey; ApplicationKey = applicationKey; EnterpriseAppId = enterpriseAppId; + Cspm = cspm; _serializedAdditionalRawData = serializedAdditionalRawData; } /// Name of the Datadog organization. - public string Name { get; } + public string Name { get; set; } /// Id of the Datadog organization. - public string Id { get; } - /// The auth code used to linking to an existing datadog organization. + public string Id { get; set; } + /// The auth code used to linking to an existing Datadog organization. public string LinkingAuthCode { get; set; } /// The client_id from an existing in exchange for an auth token to link organization. public string LinkingClientId { get; set; } - /// The redirect uri for linking. + /// The redirect URI for linking. public Uri RedirectUri { get; set; } /// Api key associated to the Datadog organization. public string ApiKey { get; set; } @@ -89,5 +91,7 @@ internal DatadogOrganizationProperties(string name, string id, string linkingAut public string ApplicationKey { get; set; } /// The Id of the Enterprise App used for Single sign on. public string EnterpriseAppId { get; set; } + /// The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. + public bool? Cspm { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.Serialization.cs index 69bde882264a..30d862477b80 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.Serialization.cs @@ -34,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - writer.WriteObjectValue(item, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -87,17 +84,13 @@ internal static DatadogSingleSignOnResourceListResponse DeserializeDatadogSingle return null; } IReadOnlyList value = default; - string nextLink = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -108,7 +101,11 @@ internal static DatadogSingleSignOnResourceListResponse DeserializeDatadogSingle } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -117,7 +114,7 @@ internal static DatadogSingleSignOnResourceListResponse DeserializeDatadogSingle } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogSingleSignOnResourceListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new DatadogSingleSignOnResourceListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.cs index 8e3e182df560..4b3954454aa2 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -46,25 +47,34 @@ internal partial class DatadogSingleSignOnResourceListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal DatadogSingleSignOnResourceListResponse() + /// The DatadogSingleSignOnResource items on this page. + /// is null. + internal DatadogSingleSignOnResourceListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The DatadogSingleSignOnResource items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogSingleSignOnResourceListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal DatadogSingleSignOnResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. + /// Initializes a new instance of for deserialization. + internal DatadogSingleSignOnResourceListResponse() + { + } + + /// The DatadogSingleSignOnResource items on this page. public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.Serialization.cs new file mode 100644 index 000000000000..73547aa1249a --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.Serialization.cs @@ -0,0 +1,144 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class LinkedInfo : 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") + { + throw new FormatException($"The model {nameof(LinkedInfo)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(Id)) + { + writer.WritePropertyName("id"u8); + writer.WriteStringValue(Id); + } + if (Optional.IsDefined(Location)) + { + writer.WritePropertyName("location"u8); + writer.WriteStringValue(Location.Value); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + LinkedInfo IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(LinkedInfo)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeLinkedInfo(document.RootElement, options); + } + + internal static LinkedInfo DeserializeLinkedInfo(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + string id = default; + AzureLocation? location = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id"u8)) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("location"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + location = new AzureLocation(property.Value.GetString()); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new LinkedInfo(id, location, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(LinkedInfo)} does not support writing '{options.Format}' format."); + } + } + + LinkedInfo IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeLinkedInfo(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(LinkedInfo)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.cs new file mode 100644 index 000000000000..a4c3f046e0c7 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.cs @@ -0,0 +1,70 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// The definition of a linked resource. + public partial class LinkedInfo + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal LinkedInfo() + { + } + + /// Initializes a new instance of . + /// The ARM id of the linked resource. + /// The location of the linked resource. + /// Keeps track of any properties unknown to the library. + internal LinkedInfo(string id, AzureLocation? location, IDictionary serializedAdditionalRawData) + { + Id = id; + Location = location; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The ARM id of the linked resource. + public string Id { get; } + /// The location of the linked resource. + public AzureLocation? Location { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.Serialization.cs index a0b93b29c316..52e636abccce 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.Serialization.cs @@ -8,10 +8,8 @@ using System; using System.ClientModel.Primitives; using System.Collections.Generic; -using System.Text; using System.Text.Json; using Azure.Core; -using Azure.ResourceManager.Resources.Models; namespace Azure.ResourceManager.Datadog.Models { @@ -36,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(LinkedResourceListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - ((IJsonModel)item).Write(writer, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -88,29 +83,29 @@ internal static LinkedResourceListResponse DeserializeLinkedResourceListResponse { return null; } - IReadOnlyList value = default; - string nextLink = default; + IReadOnlyList value = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(ModelReaderWriter.Read(new BinaryData(Encoding.UTF8.GetBytes(item.GetRawText())), options, AzureResourceManagerDatadogContext.Default)); + array.Add(LinkedInfo.DeserializeLinkedInfo(item, options)); } value = array; continue; } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -119,7 +114,7 @@ internal static LinkedResourceListResponse DeserializeLinkedResourceListResponse } } serializedAdditionalRawData = rawDataDictionary; - return new LinkedResourceListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new LinkedResourceListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.cs index 4d407bebdd50..79122f3e1a17 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.cs @@ -7,7 +7,7 @@ using System; using System.Collections.Generic; -using Azure.ResourceManager.Resources.Models; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -47,25 +47,34 @@ internal partial class LinkedResourceListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal LinkedResourceListResponse() + /// The LinkedResource items on this page. + /// is null. + internal LinkedResourceListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The LinkedResource items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal LinkedResourceListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal LinkedResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. - public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// Initializes a new instance of for deserialization. + internal LinkedResourceListResponse() + { + } + + /// The LinkedResource items on this page. + public IReadOnlyList Value { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs new file mode 100644 index 000000000000..4f7ef417c6ed --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs @@ -0,0 +1,183 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class MarketplaceSaaSInfo : 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") + { + throw new FormatException($"The model {nameof(MarketplaceSaaSInfo)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(MarketplaceSubscriptionId)) + { + writer.WritePropertyName("marketplaceSubscriptionId"u8); + writer.WriteStringValue(MarketplaceSubscriptionId); + } + if (Optional.IsDefined(MarketplaceName)) + { + writer.WritePropertyName("marketplaceName"u8); + writer.WriteStringValue(MarketplaceName); + } + if (Optional.IsDefined(MarketplaceStatus)) + { + writer.WritePropertyName("marketplaceStatus"u8); + writer.WriteStringValue(MarketplaceStatus); + } + if (Optional.IsDefined(BilledAzureSubscriptionId)) + { + writer.WritePropertyName("billedAzureSubscriptionId"u8); + writer.WriteStringValue(BilledAzureSubscriptionId); + } + if (Optional.IsDefined(Subscribed)) + { + writer.WritePropertyName("subscribed"u8); + writer.WriteBooleanValue(Subscribed.Value); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + MarketplaceSaaSInfo IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(MarketplaceSaaSInfo)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeMarketplaceSaaSInfo(document.RootElement, options); + } + + internal static MarketplaceSaaSInfo DeserializeMarketplaceSaaSInfo(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + string marketplaceSubscriptionId = default; + string marketplaceName = default; + string marketplaceStatus = default; + string billedAzureSubscriptionId = default; + bool? subscribed = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("marketplaceSubscriptionId"u8)) + { + marketplaceSubscriptionId = property.Value.GetString(); + continue; + } + if (property.NameEquals("marketplaceName"u8)) + { + marketplaceName = property.Value.GetString(); + continue; + } + if (property.NameEquals("marketplaceStatus"u8)) + { + marketplaceStatus = property.Value.GetString(); + continue; + } + if (property.NameEquals("billedAzureSubscriptionId"u8)) + { + billedAzureSubscriptionId = property.Value.GetString(); + continue; + } + if (property.NameEquals("subscribed"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + subscribed = property.Value.GetBoolean(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new MarketplaceSaaSInfo( + marketplaceSubscriptionId, + marketplaceName, + marketplaceStatus, + billedAzureSubscriptionId, + subscribed, + serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(MarketplaceSaaSInfo)} does not support writing '{options.Format}' format."); + } + } + + MarketplaceSaaSInfo IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeMarketplaceSaaSInfo(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(MarketplaceSaaSInfo)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs new file mode 100644 index 000000000000..ad032f2cafd6 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Marketplace SAAS Info of the resource. + public partial class MarketplaceSaaSInfo + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal MarketplaceSaaSInfo() + { + } + + /// Initializes a new instance of . + /// Marketplace Subscription Id. This is a GUID-formatted string. + /// Marketplace Subscription Details: SAAS Name. + /// Marketplace Subscription Details: SaaS Subscription Status. + /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. + /// Flag specifying if the Marketplace status is subscribed or not. + /// Keeps track of any properties unknown to the library. + internal MarketplaceSaaSInfo(string marketplaceSubscriptionId, string marketplaceName, string marketplaceStatus, string billedAzureSubscriptionId, bool? subscribed, IDictionary serializedAdditionalRawData) + { + MarketplaceSubscriptionId = marketplaceSubscriptionId; + MarketplaceName = marketplaceName; + MarketplaceStatus = marketplaceStatus; + BilledAzureSubscriptionId = billedAzureSubscriptionId; + Subscribed = subscribed; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Marketplace Subscription Id. This is a GUID-formatted string. + public string MarketplaceSubscriptionId { get; } + /// Marketplace Subscription Details: SAAS Name. + public string MarketplaceName { get; } + /// Marketplace Subscription Details: SaaS Subscription Status. + public string MarketplaceStatus { get; } + /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. + public string BilledAzureSubscriptionId { get; } + /// Flag specifying if the Marketplace status is subscribed or not. + public bool? Subscribed { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorProperties.cs index b603c7d912fe..34de24ab8a7e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorProperties.cs @@ -54,8 +54,8 @@ public MonitorProperties() /// /// Flag specifying if the resource monitoring is enabled or disabled. /// Flag specifying the Marketplace Subscription Status of the resource. If payment is not made in time, the resource will go in Suspended state. - /// Datadog organization properties. - /// User info. + /// Specify the Datadog organization name. In the case of linking to existing organizations, Id, ApiKey, and Applicationkey is required as well. + /// Includes name, email and optionally, phone number. User Information can't be null. /// /// The priority of the resource. /// Keeps track of any properties unknown to the library. @@ -77,9 +77,9 @@ internal MonitorProperties(ProvisioningState? provisioningState, MonitoringStatu public MonitoringStatus? MonitoringStatus { get; set; } /// Flag specifying the Marketplace Subscription Status of the resource. If payment is not made in time, the resource will go in Suspended state. public MarketplaceSubscriptionStatus? MarketplaceSubscriptionStatus { get; } - /// Datadog organization properties. + /// Specify the Datadog organization name. In the case of linking to existing organizations, Id, ApiKey, and Applicationkey is required as well. public DatadogOrganizationProperties DatadogOrganizationProperties { get; set; } - /// User info. + /// Includes name, email and optionally, phone number. User Information can't be null. public UserInfo UserInfo { get; set; } /// Gets the liftr resource category. public LiftrResourceCategory? LiftrResourceCategory { get; } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs index 784d4b2790a5..93d2caae4f12 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs @@ -13,7 +13,7 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class MonitorUpdateProperties : IUtf8JsonSerializable, IJsonModel + public partial class MonitorUpdateProperties : IUtf8JsonSerializable, IJsonModel { void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); @@ -39,6 +39,11 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("monitoringStatus"u8); writer.WriteStringValue(MonitoringStatus.Value.ToString()); } + if (Optional.IsDefined(Cspm)) + { + writer.WritePropertyName("cspm"u8); + writer.WriteBooleanValue(Cspm.Value); + } if (options.Format != "W" && _serializedAdditionalRawData != null) { foreach (var item in _serializedAdditionalRawData) @@ -77,6 +82,7 @@ internal static MonitorUpdateProperties DeserializeMonitorUpdateProperties(JsonE return null; } MonitoringStatus? monitoringStatus = default; + bool? cspm = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) @@ -90,13 +96,22 @@ internal static MonitorUpdateProperties DeserializeMonitorUpdateProperties(JsonE monitoringStatus = new MonitoringStatus(property.Value.GetString()); continue; } + if (property.NameEquals("cspm"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + cspm = property.Value.GetBoolean(); + continue; + } if (options.Format != "W") { rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); } } serializedAdditionalRawData = rawDataDictionary; - return new MonitorUpdateProperties(monitoringStatus, serializedAdditionalRawData); + return new MonitorUpdateProperties(monitoringStatus, cspm, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs index 054c8335a0ba..3a1e4e1a0eee 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs @@ -11,7 +11,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// The set of properties that can be update in a PATCH request to a monitor resource. - internal partial class MonitorUpdateProperties + public partial class MonitorUpdateProperties { /// /// Keeps track of any properties unknown to the library. @@ -52,14 +52,18 @@ public MonitorUpdateProperties() /// Initializes a new instance of . /// Flag specifying if the resource monitoring is enabled or disabled. + /// The new cloud security posture management value of the monitor resource. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. /// Keeps track of any properties unknown to the library. - internal MonitorUpdateProperties(MonitoringStatus? monitoringStatus, IDictionary serializedAdditionalRawData) + internal MonitorUpdateProperties(MonitoringStatus? monitoringStatus, bool? cspm, IDictionary serializedAdditionalRawData) { MonitoringStatus = monitoringStatus; + Cspm = cspm; _serializedAdditionalRawData = serializedAdditionalRawData; } /// Flag specifying if the resource monitoring is enabled or disabled. public MonitoringStatus? MonitoringStatus { get; set; } + /// The new cloud security posture management value of the monitor resource. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. + public bool? Cspm { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.Serialization.cs index c5b057b7f369..8665948d0025 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.Serialization.cs @@ -34,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(MonitoredResourceListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - writer.WriteObjectValue(item, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -87,17 +84,13 @@ internal static MonitoredResourceListResponse DeserializeMonitoredResourceListRe return null; } IReadOnlyList value = default; - string nextLink = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -108,7 +101,11 @@ internal static MonitoredResourceListResponse DeserializeMonitoredResourceListRe } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -117,7 +114,7 @@ internal static MonitoredResourceListResponse DeserializeMonitoredResourceListRe } } serializedAdditionalRawData = rawDataDictionary; - return new MonitoredResourceListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new MonitoredResourceListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.cs index 0f5c53205a96..3234615a062a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -46,25 +47,34 @@ internal partial class MonitoredResourceListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal MonitoredResourceListResponse() + /// The MonitoredResource items on this page. + /// is null. + internal MonitoredResourceListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The MonitoredResource items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal MonitoredResourceListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal MonitoredResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. + /// Initializes a new instance of for deserialization. + internal MonitoredResourceListResponse() + { + } + + /// The MonitoredResource items on this page. public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs new file mode 100644 index 000000000000..86e4ed1b5c8d --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs @@ -0,0 +1,170 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class MonitoredSubscription : 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") + { + throw new FormatException($"The model {nameof(MonitoredSubscription)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(SubscriptionId)) + { + writer.WritePropertyName("subscriptionId"u8); + writer.WriteStringValue(SubscriptionId); + } + if (Optional.IsDefined(Status)) + { + writer.WritePropertyName("status"u8); + writer.WriteStringValue(Status.Value.ToString()); + } + if (Optional.IsDefined(Error)) + { + writer.WritePropertyName("error"u8); + writer.WriteStringValue(Error); + } + if (Optional.IsDefined(TagRules)) + { + writer.WritePropertyName("tagRules"u8); + writer.WriteObjectValue(TagRules, options); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + MonitoredSubscription IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(MonitoredSubscription)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeMonitoredSubscription(document.RootElement, options); + } + + internal static MonitoredSubscription DeserializeMonitoredSubscription(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + string subscriptionId = default; + Status? status = default; + string error = default; + MonitoringTagRulesProperties tagRules = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("subscriptionId"u8)) + { + subscriptionId = property.Value.GetString(); + continue; + } + if (property.NameEquals("status"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + status = new Status(property.Value.GetString()); + continue; + } + if (property.NameEquals("error"u8)) + { + error = property.Value.GetString(); + continue; + } + if (property.NameEquals("tagRules"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + tagRules = MonitoringTagRulesProperties.DeserializeMonitoringTagRulesProperties(property.Value, options); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new MonitoredSubscription(subscriptionId, status, error, tagRules, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(MonitoredSubscription)} does not support writing '{options.Format}' format."); + } + } + + MonitoredSubscription IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeMonitoredSubscription(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(MonitoredSubscription)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs new file mode 100644 index 000000000000..edb4deb92a0c --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs @@ -0,0 +1,77 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// The list of subscriptions and it's monitoring status by current Datadog monitor. + public partial class MonitoredSubscription + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public MonitoredSubscription() + { + } + + /// Initializes a new instance of . + /// The subscriptionId to be monitored. + /// The state of monitoring. + /// The reason of not monitoring the subscription. + /// Definition of the properties for a TagRules resource. + /// Keeps track of any properties unknown to the library. + internal MonitoredSubscription(string subscriptionId, Status? status, string error, MonitoringTagRulesProperties tagRules, IDictionary serializedAdditionalRawData) + { + SubscriptionId = subscriptionId; + Status = status; + Error = error; + TagRules = tagRules; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The subscriptionId to be monitored. + public string SubscriptionId { get; set; } + /// The state of monitoring. + public Status? Status { get; set; } + /// The reason of not monitoring the subscription. + public string Error { get; set; } + /// Definition of the properties for a TagRules resource. + public MonitoringTagRulesProperties TagRules { get; set; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.Serialization.cs new file mode 100644 index 000000000000..57e33575b93b --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.Serialization.cs @@ -0,0 +1,151 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + internal partial class MonitoredSubscriptionPropertiesList : 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") + { + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertiesList)} does not support writing '{format}' format."); + } + + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) + { + writer.WriteObjectValue(item, options); + } + writer.WriteEndArray(); + if (Optional.IsDefined(NextLink)) + { + writer.WritePropertyName("nextLink"u8); + writer.WriteStringValue(NextLink.AbsoluteUri); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + MonitoredSubscriptionPropertiesList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertiesList)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeMonitoredSubscriptionPropertiesList(document.RootElement, options); + } + + internal static MonitoredSubscriptionPropertiesList DeserializeMonitoredSubscriptionPropertiesList(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + IReadOnlyList value = default; + Uri nextLink = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("value"u8)) + { + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(MonitoredSubscriptionPropertyData.DeserializeMonitoredSubscriptionPropertyData(item, options)); + } + value = array; + continue; + } + if (property.NameEquals("nextLink"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new MonitoredSubscriptionPropertiesList(value, nextLink, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertiesList)} does not support writing '{options.Format}' format."); + } + } + + MonitoredSubscriptionPropertiesList IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeMonitoredSubscriptionPropertiesList(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertiesList)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.cs new file mode 100644 index 000000000000..2e8cffbbc5c9 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscriptionPropertiesList.cs @@ -0,0 +1,80 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using System.Linq; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Paged collection of MonitoredSubscriptionProperties items. + internal partial class MonitoredSubscriptionPropertiesList + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + /// The MonitoredSubscriptionProperties items on this page. + /// is null. + internal MonitoredSubscriptionPropertiesList(IEnumerable value) + { + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); + } + + /// Initializes a new instance of . + /// The MonitoredSubscriptionProperties items on this page. + /// The link to the next page of items. + /// Keeps track of any properties unknown to the library. + internal MonitoredSubscriptionPropertiesList(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + { + Value = value; + NextLink = nextLink; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Initializes a new instance of for deserialization. + internal MonitoredSubscriptionPropertiesList() + { + } + + /// The MonitoredSubscriptionProperties items on this page. + public IReadOnlyList Value { get; } + /// The link to the next page of items. + public Uri NextLink { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.Serialization.cs index e0ab8eb13872..976ac0b92145 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.Serialization.cs @@ -34,20 +34,17 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(MonitoringTagRulesListResponse)} does not support writing '{format}' format."); } - if (Optional.IsCollectionDefined(Value)) + writer.WritePropertyName("value"u8); + writer.WriteStartArray(); + foreach (var item in Value) { - writer.WritePropertyName("value"u8); - writer.WriteStartArray(); - foreach (var item in Value) - { - writer.WriteObjectValue(item, options); - } - writer.WriteEndArray(); + writer.WriteObjectValue(item, options); } + writer.WriteEndArray(); if (Optional.IsDefined(NextLink)) { writer.WritePropertyName("nextLink"u8); - writer.WriteStringValue(NextLink); + writer.WriteStringValue(NextLink.AbsoluteUri); } if (options.Format != "W" && _serializedAdditionalRawData != null) { @@ -87,17 +84,13 @@ internal static MonitoringTagRulesListResponse DeserializeMonitoringTagRulesList return null; } IReadOnlyList value = default; - string nextLink = default; + Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) { if (property.NameEquals("value"u8)) { - if (property.Value.ValueKind == JsonValueKind.Null) - { - continue; - } List array = new List(); foreach (var item in property.Value.EnumerateArray()) { @@ -108,7 +101,11 @@ internal static MonitoringTagRulesListResponse DeserializeMonitoringTagRulesList } if (property.NameEquals("nextLink"u8)) { - nextLink = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + nextLink = new Uri(property.Value.GetString()); continue; } if (options.Format != "W") @@ -117,7 +114,7 @@ internal static MonitoringTagRulesListResponse DeserializeMonitoringTagRulesList } } serializedAdditionalRawData = rawDataDictionary; - return new MonitoringTagRulesListResponse(value ?? new ChangeTrackingList(), nextLink, serializedAdditionalRawData); + return new MonitoringTagRulesListResponse(value, nextLink, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.cs index 993e4c3fb014..5f65a587b643 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using System.Linq; namespace Azure.ResourceManager.Datadog.Models { @@ -46,25 +47,34 @@ internal partial class MonitoringTagRulesListResponse private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - internal MonitoringTagRulesListResponse() + /// The MonitoringTagRules items on this page. + /// is null. + internal MonitoringTagRulesListResponse(IEnumerable value) { - Value = new ChangeTrackingList(); + Argument.AssertNotNull(value, nameof(value)); + + Value = value.ToList(); } /// Initializes a new instance of . - /// Results of a list operation. - /// Link to the next set of results, if any. + /// The MonitoringTagRules items on this page. + /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal MonitoringTagRulesListResponse(IReadOnlyList value, string nextLink, IDictionary serializedAdditionalRawData) + internal MonitoringTagRulesListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Results of a list operation. + /// Initializes a new instance of for deserialization. + internal MonitoringTagRulesListResponse() + { + } + + /// The MonitoringTagRules items on this page. public IReadOnlyList Value { get; } - /// Link to the next set of results, if any. - public string NextLink { get; } + /// The link to the next page of items. + public Uri NextLink { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs index a27605356936..8037a0303faf 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs @@ -49,6 +49,16 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("metricRules"u8); writer.WriteObjectValue(MetricRules, options); } + if (Optional.IsDefined(Automuting)) + { + writer.WritePropertyName("automuting"u8); + writer.WriteBooleanValue(Automuting.Value); + } + if (Optional.IsDefined(CustomMetrics)) + { + writer.WritePropertyName("customMetrics"u8); + writer.WriteBooleanValue(CustomMetrics.Value); + } if (options.Format != "W" && _serializedAdditionalRawData != null) { foreach (var item in _serializedAdditionalRawData) @@ -89,6 +99,8 @@ internal static MonitoringTagRulesProperties DeserializeMonitoringTagRulesProper ProvisioningState? provisioningState = default; LogRules logRules = default; MetricRules metricRules = default; + bool? automuting = default; + bool? customMetrics = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) @@ -120,13 +132,37 @@ internal static MonitoringTagRulesProperties DeserializeMonitoringTagRulesProper metricRules = MetricRules.DeserializeMetricRules(property.Value, options); continue; } + if (property.NameEquals("automuting"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + automuting = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("customMetrics"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + customMetrics = property.Value.GetBoolean(); + continue; + } if (options.Format != "W") { rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); } } serializedAdditionalRawData = rawDataDictionary; - return new MonitoringTagRulesProperties(provisioningState, logRules, metricRules, serializedAdditionalRawData); + return new MonitoringTagRulesProperties( + provisioningState, + logRules, + metricRules, + automuting, + customMetrics, + serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs index 81d7c5749048..48ab31f866fd 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs @@ -54,12 +54,16 @@ public MonitoringTagRulesProperties() /// /// Set of rules for sending logs for the Monitor resource. /// Set of rules for sending metrics for the Monitor resource. + /// Configuration to enable/disable auto-muting flag. + /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. /// Keeps track of any properties unknown to the library. - internal MonitoringTagRulesProperties(ProvisioningState? provisioningState, LogRules logRules, MetricRules metricRules, IDictionary serializedAdditionalRawData) + internal MonitoringTagRulesProperties(ProvisioningState? provisioningState, LogRules logRules, MetricRules metricRules, bool? automuting, bool? customMetrics, IDictionary serializedAdditionalRawData) { ProvisioningState = provisioningState; LogRules = logRules; MetricRules = metricRules; + Automuting = automuting; + CustomMetrics = customMetrics; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -79,5 +83,10 @@ public IList MetricRulesFilteringTags return MetricRules.FilteringTags; } } + + /// Configuration to enable/disable auto-muting flag. + public bool? Automuting { get; set; } + /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. + public bool? CustomMetrics { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Operation.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Operation.cs new file mode 100644 index 000000000000..641e3d78b9e7 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Operation.cs @@ -0,0 +1,60 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// The operation for the patch on the resource. + public readonly partial struct Operation : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public Operation(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string AddBeginValue = "AddBegin"; + private const string AddCompleteValue = "AddComplete"; + private const string DeleteBeginValue = "DeleteBegin"; + private const string DeleteCompleteValue = "DeleteComplete"; + private const string ActiveValue = "Active"; + + /// AddBegin. + public static Operation AddBegin { get; } = new Operation(AddBeginValue); + /// AddComplete. + public static Operation AddComplete { get; } = new Operation(AddCompleteValue); + /// DeleteBegin. + public static Operation DeleteBegin { get; } = new Operation(DeleteBeginValue); + /// DeleteComplete. + public static Operation DeleteComplete { get; } = new Operation(DeleteCompleteValue); + /// Active. + public static Operation Active { get; } = new Operation(ActiveValue); + /// Determines if two values are the same. + public static bool operator ==(Operation left, Operation right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(Operation left, Operation right) => !left.Equals(right); + /// Converts a to a . + public static implicit operator Operation(string value) => new Operation(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is Operation other && Equals(other); + /// + public bool Equals(Operation other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.Serialization.cs new file mode 100644 index 000000000000..a2c0a50ad0ce --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.Serialization.cs @@ -0,0 +1,155 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class PartnerBillingEntity : 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") + { + throw new FormatException($"The model {nameof(PartnerBillingEntity)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(Id)) + { + writer.WritePropertyName("id"u8); + writer.WriteStringValue(Id); + } + if (Optional.IsDefined(Name)) + { + writer.WritePropertyName("name"u8); + writer.WriteStringValue(Name); + } + if (Optional.IsDefined(PartnerEntityUri)) + { + writer.WritePropertyName("partnerEntityUri"u8); + writer.WriteStringValue(PartnerEntityUri.AbsoluteUri); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + PartnerBillingEntity IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(PartnerBillingEntity)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializePartnerBillingEntity(document.RootElement, options); + } + + internal static PartnerBillingEntity DeserializePartnerBillingEntity(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + string id = default; + string name = default; + Uri partnerEntityUri = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("id"u8)) + { + id = property.Value.GetString(); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("partnerEntityUri"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + partnerEntityUri = new Uri(property.Value.GetString()); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new PartnerBillingEntity(id, name, partnerEntityUri, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(PartnerBillingEntity)} does not support writing '{options.Format}' format."); + } + } + + PartnerBillingEntity IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializePartnerBillingEntity(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(PartnerBillingEntity)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.cs new file mode 100644 index 000000000000..9d217d91f1f2 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/PartnerBillingEntity.cs @@ -0,0 +1,73 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Partner Billing details associated with the resource. + public partial class PartnerBillingEntity + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + internal PartnerBillingEntity() + { + } + + /// Initializes a new instance of . + /// The Datadog Organization Id. + /// The Datadog Organization Name. + /// Link to the datadog organization page. + /// Keeps track of any properties unknown to the library. + internal PartnerBillingEntity(string id, string name, Uri partnerEntityUri, IDictionary serializedAdditionalRawData) + { + Id = id; + Name = name; + PartnerEntityUri = partnerEntityUri; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The Datadog Organization Id. + public string Id { get; } + /// The Datadog Organization Name. + public string Name { get; } + /// Link to the datadog organization page. + public Uri PartnerEntityUri { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs index 90e7a9f06b17..4b10f83ae5b2 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs @@ -10,7 +10,7 @@ namespace Azure.ResourceManager.Datadog.Models { - /// The ResourceSku. + /// Represents the SKU of a resource. internal partial class ResourceSku { /// @@ -46,7 +46,7 @@ internal partial class ResourceSku private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - /// Name of the SKU. + /// The name of the SKU. /// is null. public ResourceSku(string name) { @@ -56,7 +56,7 @@ public ResourceSku(string name) } /// Initializes a new instance of . - /// Name of the SKU. + /// The name of the SKU. /// Keeps track of any properties unknown to the library. internal ResourceSku(string name, IDictionary serializedAdditionalRawData) { @@ -69,7 +69,7 @@ internal ResourceSku() { } - /// Name of the SKU. + /// The name of the SKU. public string Name { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Status.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Status.cs new file mode 100644 index 000000000000..1c40c67ad38d --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Status.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// The state of monitoring. + public readonly partial struct Status : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public Status(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string InProgressValue = "InProgress"; + private const string ActiveValue = "Active"; + private const string FailedValue = "Failed"; + private const string DeletingValue = "Deleting"; + + /// InProgress. + public static Status InProgress { get; } = new Status(InProgressValue); + /// Active. + public static Status Active { get; } = new Status(ActiveValue); + /// Failed. + public static Status Failed { get; } = new Status(FailedValue); + /// Deleting. + public static Status Deleting { get; } = new Status(DeletingValue); + /// Determines if two values are the same. + public static bool operator ==(Status left, Status right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(Status left, Status right) => !left.Equals(right); + /// Converts a to a . + public static implicit operator Status(string value) => new Status(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is Status other && Equals(other); + /// + public bool Equals(Status other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs new file mode 100644 index 000000000000..ddf39f28327a --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs @@ -0,0 +1,158 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class SubscriptionList : 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") + { + throw new FormatException($"The model {nameof(SubscriptionList)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(Operation)) + { + writer.WritePropertyName("operation"u8); + writer.WriteStringValue(Operation.Value.ToString()); + } + if (Optional.IsCollectionDefined(MonitoredSubscriptionList)) + { + writer.WritePropertyName("monitoredSubscriptionList"u8); + writer.WriteStartArray(); + foreach (var item in MonitoredSubscriptionList) + { + writer.WriteObjectValue(item, options); + } + writer.WriteEndArray(); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + SubscriptionList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(SubscriptionList)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeSubscriptionList(document.RootElement, options); + } + + internal static SubscriptionList DeserializeSubscriptionList(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + Operation? operation = default; + IList monitoredSubscriptionList = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("operation"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + operation = new Operation(property.Value.GetString()); + continue; + } + if (property.NameEquals("monitoredSubscriptionList"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(MonitoredSubscription.DeserializeMonitoredSubscription(item, options)); + } + monitoredSubscriptionList = array; + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new SubscriptionList(operation, monitoredSubscriptionList ?? new ChangeTrackingList(), serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(SubscriptionList)} does not support writing '{options.Format}' format."); + } + } + + SubscriptionList IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeSubscriptionList(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(SubscriptionList)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs new file mode 100644 index 000000000000..ffb0687fac96 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs @@ -0,0 +1,70 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. + public partial class SubscriptionList + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public SubscriptionList() + { + MonitoredSubscriptionList = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// The operation for the patch on the resource. + /// List of subscriptions and the state of the monitoring. + /// Keeps track of any properties unknown to the library. + internal SubscriptionList(Operation? operation, IList monitoredSubscriptionList, IDictionary serializedAdditionalRawData) + { + Operation = operation; + MonitoredSubscriptionList = monitoredSubscriptionList; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The operation for the patch on the resource. + public Operation? Operation { get; set; } + /// List of subscriptions and the state of the monitoring. + public IList MonitoredSubscriptionList { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/UserInfo.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/UserInfo.cs index 7132b36b2fda..0df4c5a76aaa 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/UserInfo.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/UserInfo.cs @@ -10,7 +10,7 @@ namespace Azure.ResourceManager.Datadog.Models { - /// User info. + /// Includes name, email and optionally, phone number. User Information can't be null. public partial class UserInfo { /// diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs new file mode 100644 index 000000000000..e1ff2130fd92 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs @@ -0,0 +1,493 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Globalization; +using System.Threading; +using System.Threading.Tasks; +using Autorest.CSharp.Core; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.ResourceManager.Datadog +{ + /// + /// A class representing a collection of and their operations. + /// Each in the collection will belong to the same instance of . + /// To get a instance call the GetMonitoredSubscriptionProperties method from an instance of . + /// + public partial class MonitoredSubscriptionPropertyCollection : ArmCollection, IEnumerable, IAsyncEnumerable + { + private readonly ClientDiagnostics _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics; + private readonly MonitoredSubscriptionsRestOperations _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient; + + /// Initializes a new instance of the class for mocking. + protected MonitoredSubscriptionPropertyCollection() + { + } + + /// Initializes a new instance of the class. + /// The client parameters to use in these operations. + /// The identifier of the parent resource that is the target of operations. + internal MonitoredSubscriptionPropertyCollection(ArmClient client, ResourceIdentifier id) : base(client, id) + { + _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.Datadog", MonitoredSubscriptionPropertyResource.ResourceType.Namespace, Diagnostics); + TryGetApiVersion(MonitoredSubscriptionPropertyResource.ResourceType, out string monitoredSubscriptionPropertyMonitoredSubscriptionsApiVersion); + _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient = new MonitoredSubscriptionsRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint, monitoredSubscriptionPropertyMonitoredSubscriptionsApiVersion); +#if DEBUG + ValidateResourceId(Id); +#endif + } + + internal static void ValidateResourceId(ResourceIdentifier id) + { + if (id.ResourceType != DatadogMonitorResource.ResourceType) + throw new ArgumentException(string.Format(CultureInfo.CurrentCulture, "Invalid resource type {0} expected {1}", id.ResourceType, DatadogMonitorResource.ResourceType), nameof(id)); + } + + /// + /// Add the subscriptions that should be monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_CreateorUpdate + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// The configuration name. Only 'default' value is supported. + /// The to use. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// or is null. + public virtual async Task> CreateOrUpdateAsync(WaitUntil waitUntil, string configurationName, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.CreateOrUpdate"); + scope.Start(); + try + { + var response = await _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateorUpdateAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, data, cancellationToken).ConfigureAwait(false); + var operation = new DatadogArmOperation(new MonitoredSubscriptionPropertyOperationSource(Client), _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateCreateorUpdateRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, data).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + await operation.WaitForCompletionAsync(cancellationToken).ConfigureAwait(false); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Add the subscriptions that should be monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_CreateorUpdate + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// The configuration name. Only 'default' value is supported. + /// The to use. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// or is null. + public virtual ArmOperation CreateOrUpdate(WaitUntil waitUntil, string configurationName, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.CreateOrUpdate"); + scope.Start(); + try + { + var response = _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateorUpdate(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, data, cancellationToken); + var operation = new DatadogArmOperation(new MonitoredSubscriptionPropertyOperationSource(Client), _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateCreateorUpdateRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, data).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + operation.WaitForCompletion(cancellationToken); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// is null. + public virtual async Task> GetAsync(string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.Get"); + scope.Start(); + try + { + var response = await _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.GetAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, cancellationToken).ConfigureAwait(false); + if (response.Value == null) + throw new RequestFailedException(response.GetRawResponse()); + return Response.FromValue(new MonitoredSubscriptionPropertyResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// is null. + public virtual Response Get(string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.Get"); + scope.Start(); + try + { + var response = _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.Get(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, cancellationToken); + if (response.Value == null) + throw new RequestFailedException(response.GetRawResponse()); + return Response.FromValue(new MonitoredSubscriptionPropertyResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions + /// + /// + /// Operation Id + /// MonitoredSubscriptions_List + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The cancellation token to use. + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetAllAsync(CancellationToken cancellationToken = default) + { + HttpMessage FirstPageRequest(int? pageSizeHint) => _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateListRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => new MonitoredSubscriptionPropertyResource(Client, MonitoredSubscriptionPropertyData.DeserializeMonitoredSubscriptionPropertyData(e)), _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, "MonitoredSubscriptionPropertyCollection.GetAll", "value", "nextLink", cancellationToken); + } + + /// + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions + /// + /// + /// Operation Id + /// MonitoredSubscriptions_List + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The cancellation token to use. + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetAll(CancellationToken cancellationToken = default) + { + HttpMessage FirstPageRequest(int? pageSizeHint) => _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateListRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => new MonitoredSubscriptionPropertyResource(Client, MonitoredSubscriptionPropertyData.DeserializeMonitoredSubscriptionPropertyData(e)), _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, "MonitoredSubscriptionPropertyCollection.GetAll", "value", "nextLink", cancellationToken); + } + + /// + /// Checks to see if the resource exists in azure. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// is null. + public virtual async Task> ExistsAsync(string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.Exists"); + scope.Start(); + try + { + var response = await _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.GetAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, cancellationToken: cancellationToken).ConfigureAwait(false); + return Response.FromValue(response.Value != null, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Checks to see if the resource exists in azure. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// is null. + public virtual Response Exists(string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.Exists"); + scope.Start(); + try + { + var response = _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.Get(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, cancellationToken: cancellationToken); + return Response.FromValue(response.Value != null, response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Tries to get details for this resource from the service. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// is null. + public virtual async Task> GetIfExistsAsync(string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.GetIfExists"); + scope.Start(); + try + { + var response = await _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.GetAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, cancellationToken: cancellationToken).ConfigureAwait(false); + if (response.Value == null) + return new NoValueResponse(response.GetRawResponse()); + return Response.FromValue(new MonitoredSubscriptionPropertyResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Tries to get details for this resource from the service. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// is an empty string, and was expected to be non-empty. + /// is null. + public virtual NullableResponse GetIfExists(string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyCollection.GetIfExists"); + scope.Start(); + try + { + var response = _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.Get(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, configurationName, cancellationToken: cancellationToken); + if (response.Value == null) + return new NoValueResponse(response.GetRawResponse()); + return Response.FromValue(new MonitoredSubscriptionPropertyResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + IEnumerator IEnumerable.GetEnumerator() + { + return GetAll().GetEnumerator(); + } + + IEnumerator IEnumerable.GetEnumerator() + { + return GetAll().GetEnumerator(); + } + + IAsyncEnumerator IAsyncEnumerable.GetAsyncEnumerator(CancellationToken cancellationToken) + { + return GetAllAsync(cancellationToken: cancellationToken).GetAsyncEnumerator(cancellationToken); + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs new file mode 100644 index 000000000000..222d1a924ff8 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs @@ -0,0 +1,156 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text; +using System.Text.Json; +using Azure.Core; +using Azure.ResourceManager.Datadog.Models; +using Azure.ResourceManager.Models; + +namespace Azure.ResourceManager.Datadog +{ + public partial class MonitoredSubscriptionPropertyData : 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") + { + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertyData)} does not support writing '{format}' format."); + } + + base.JsonModelWriteCore(writer, options); + if (Optional.IsDefined(Properties)) + { + writer.WritePropertyName("properties"u8); + writer.WriteObjectValue(Properties, options); + } + } + + MonitoredSubscriptionPropertyData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertyData)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeMonitoredSubscriptionPropertyData(document.RootElement, options); + } + + internal static MonitoredSubscriptionPropertyData DeserializeMonitoredSubscriptionPropertyData(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + SubscriptionList properties = default; + ResourceIdentifier id = default; + string name = default; + ResourceType type = default; + SystemData systemData = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("properties"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + properties = SubscriptionList.DeserializeSubscriptionList(property.Value, options); + continue; + } + if (property.NameEquals("id"u8)) + { + id = new ResourceIdentifier(property.Value.GetString()); + continue; + } + if (property.NameEquals("name"u8)) + { + name = property.Value.GetString(); + continue; + } + if (property.NameEquals("type"u8)) + { + type = new ResourceType(property.Value.GetString()); + continue; + } + if (property.NameEquals("systemData"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + systemData = ModelReaderWriter.Read(new BinaryData(Encoding.UTF8.GetBytes(property.Value.GetRawText())), ModelSerializationExtensions.WireOptions, AzureResourceManagerDatadogContext.Default); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new MonitoredSubscriptionPropertyData( + id, + name, + type, + systemData, + properties, + serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertyData)} does not support writing '{options.Format}' format."); + } + } + + MonitoredSubscriptionPropertyData IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeMonitoredSubscriptionPropertyData(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(MonitoredSubscriptionPropertyData)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs new file mode 100644 index 000000000000..4adef9a407c3 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs @@ -0,0 +1,75 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; +using Azure.ResourceManager.Datadog.Models; +using Azure.ResourceManager.Models; + +namespace Azure.ResourceManager.Datadog +{ + /// + /// A class representing the MonitoredSubscriptionProperty data model. + /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. + /// + public partial class MonitoredSubscriptionPropertyData : ResourceData + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public MonitoredSubscriptionPropertyData() + { + } + + /// Initializes a new instance of . + /// The id. + /// The name. + /// The resourceType. + /// The systemData. + /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. + /// Keeps track of any properties unknown to the library. + internal MonitoredSubscriptionPropertyData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, SubscriptionList properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + { + Properties = properties; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. + public SubscriptionList Properties { get; set; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.Serialization.cs new file mode 100644 index 000000000000..4ba439200a01 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.Serialization.cs @@ -0,0 +1,29 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Text.Json; + +namespace Azure.ResourceManager.Datadog +{ + public partial class MonitoredSubscriptionPropertyResource : IJsonModel + { + private static MonitoredSubscriptionPropertyData s_dataDeserializationInstance; + private static MonitoredSubscriptionPropertyData DataDeserializationInstance => s_dataDeserializationInstance ??= new(); + + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) => ((IJsonModel)Data).Write(writer, options); + + MonitoredSubscriptionPropertyData IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) => ((IJsonModel)DataDeserializationInstance).Create(ref reader, options); + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) => ModelReaderWriter.Write(Data, options, AzureResourceManagerDatadogContext.Default); + + MonitoredSubscriptionPropertyData IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) => ModelReaderWriter.Read(data, options, AzureResourceManagerDatadogContext.Default); + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => ((IPersistableModel)DataDeserializationInstance).GetFormatFromOptions(options); + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs new file mode 100644 index 000000000000..65e9ca04179e --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs @@ -0,0 +1,347 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Globalization; +using System.Threading; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Core.Pipeline; + +namespace Azure.ResourceManager.Datadog +{ + /// + /// A Class representing a MonitoredSubscriptionProperty along with the instance operations that can be performed on it. + /// If you have a you can construct a + /// from an instance of using the GetMonitoredSubscriptionPropertyResource method. + /// Otherwise you can get one from its parent resource using the GetMonitoredSubscriptionProperty method. + /// + public partial class MonitoredSubscriptionPropertyResource : ArmResource + { + /// Generate the resource identifier of a instance. + /// The subscriptionId. + /// The resourceGroupName. + /// The monitorName. + /// The configurationName. + public static ResourceIdentifier CreateResourceIdentifier(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) + { + var resourceId = $"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName}"; + return new ResourceIdentifier(resourceId); + } + + private readonly ClientDiagnostics _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics; + private readonly MonitoredSubscriptionsRestOperations _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient; + private readonly MonitoredSubscriptionPropertyData _data; + + /// Gets the resource type for the operations. + public static readonly ResourceType ResourceType = "Microsoft.Datadog/monitors/monitoredSubscriptions"; + + /// Initializes a new instance of the class for mocking. + protected MonitoredSubscriptionPropertyResource() + { + } + + /// Initializes a new instance of the class. + /// The client parameters to use in these operations. + /// The resource that is the target of operations. + internal MonitoredSubscriptionPropertyResource(ArmClient client, MonitoredSubscriptionPropertyData data) : this(client, data.Id) + { + HasData = true; + _data = data; + } + + /// Initializes a new instance of the class. + /// The client parameters to use in these operations. + /// The identifier of the resource that is the target of operations. + internal MonitoredSubscriptionPropertyResource(ArmClient client, ResourceIdentifier id) : base(client, id) + { + _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.Datadog", ResourceType.Namespace, Diagnostics); + TryGetApiVersion(ResourceType, out string monitoredSubscriptionPropertyMonitoredSubscriptionsApiVersion); + _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient = new MonitoredSubscriptionsRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint, monitoredSubscriptionPropertyMonitoredSubscriptionsApiVersion); +#if DEBUG + ValidateResourceId(Id); +#endif + } + + /// Gets whether or not the current instance has data. + public virtual bool HasData { get; } + + /// Gets the data representing this Feature. + /// Throws if there is no data loaded in the current instance. + public virtual MonitoredSubscriptionPropertyData Data + { + get + { + if (!HasData) + throw new InvalidOperationException("The current instance does not have data, you must call Get first."); + return _data; + } + } + + internal static void ValidateResourceId(ResourceIdentifier id) + { + if (id.ResourceType != ResourceType) + throw new ArgumentException(string.Format(CultureInfo.CurrentCulture, "Invalid resource type {0} expected {1}", id.ResourceType, ResourceType), nameof(id)); + } + + /// + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The cancellation token to use. + public virtual async Task> GetAsync(CancellationToken cancellationToken = default) + { + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyResource.Get"); + scope.Start(); + try + { + var response = await _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.GetAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, cancellationToken).ConfigureAwait(false); + if (response.Value == null) + throw new RequestFailedException(response.GetRawResponse()); + return Response.FromValue(new MonitoredSubscriptionPropertyResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Get + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// The cancellation token to use. + public virtual Response Get(CancellationToken cancellationToken = default) + { + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyResource.Get"); + scope.Start(); + try + { + var response = _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.Get(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, cancellationToken); + if (response.Value == null) + throw new RequestFailedException(response.GetRawResponse()); + return Response.FromValue(new MonitoredSubscriptionPropertyResource(Client, response.Value), response.GetRawResponse()); + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Updates the subscriptions that are being monitored by the Datadog monitor resource + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Delete + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// The cancellation token to use. + public virtual async Task DeleteAsync(WaitUntil waitUntil, CancellationToken cancellationToken = default) + { + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyResource.Delete"); + scope.Start(); + try + { + var response = await _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.DeleteAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, cancellationToken).ConfigureAwait(false); + var operation = new DatadogArmOperation(_monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateDeleteRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + await operation.WaitForCompletionResponseAsync(cancellationToken).ConfigureAwait(false); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Updates the subscriptions that are being monitored by the Datadog monitor resource + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Delete + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// The cancellation token to use. + public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancellationToken = default) + { + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyResource.Delete"); + scope.Start(); + try + { + var response = _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.Delete(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, cancellationToken); + var operation = new DatadogArmOperation(_monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateDeleteRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + operation.WaitForCompletionResponse(cancellationToken); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Updates the subscriptions that are being monitored by the Datadog monitor resource + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Update + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// The to use. + /// The cancellation token to use. + /// is null. + public virtual async Task> UpdateAsync(WaitUntil waitUntil, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(data, nameof(data)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyResource.Update"); + scope.Start(); + try + { + var response = await _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.UpdateAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, data, cancellationToken).ConfigureAwait(false); + var operation = new DatadogArmOperation(new MonitoredSubscriptionPropertyOperationSource(Client), _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateUpdateRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, data).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + await operation.WaitForCompletionAsync(cancellationToken).ConfigureAwait(false); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Updates the subscriptions that are being monitored by the Datadog monitor resource + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/monitoredSubscriptions/{configurationName} + /// + /// + /// Operation Id + /// MonitoredSubscriptions_Update + /// + /// + /// Default Api Version + /// 2023-10-20 + /// + /// + /// Resource + /// + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// The to use. + /// The cancellation token to use. + /// is null. + public virtual ArmOperation Update(WaitUntil waitUntil, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(data, nameof(data)); + + using var scope = _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics.CreateScope("MonitoredSubscriptionPropertyResource.Update"); + scope.Start(); + try + { + var response = _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.Update(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, data, cancellationToken); + var operation = new DatadogArmOperation(new MonitoredSubscriptionPropertyOperationSource(Client), _monitoredSubscriptionPropertyMonitoredSubscriptionsClientDiagnostics, Pipeline, _monitoredSubscriptionPropertyMonitoredSubscriptionsRestClient.CreateUpdateRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Parent.Name, Id.Name, data).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + operation.WaitForCompletion(cancellationToken); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs index 8f7017c0cc50..42bbbf22a087 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -115,7 +115,7 @@ public virtual async Task> CreateOrUpdat /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -166,7 +166,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -211,7 +211,7 @@ public virtual async Task> GetAsync(string r /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -256,7 +256,7 @@ public virtual Response Get(string ruleSetName, Cance /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -286,7 +286,7 @@ public virtual AsyncPageable GetAllAsync(Cancellation /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -316,7 +316,7 @@ public virtual Pageable GetAll(CancellationToken canc /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -359,7 +359,7 @@ public virtual async Task> ExistsAsync(string ruleSetName, Cancel /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -402,7 +402,7 @@ public virtual Response Exists(string ruleSetName, CancellationToken cance /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -447,7 +447,7 @@ public virtual async Task> GetIfExis /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs index fc8b4759e2ef..4301e45b49a3 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(Cancella /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken cancell /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource @@ -229,7 +229,7 @@ public virtual async Task> UpdateAsync(W /// /// /// Default Api Version - /// 2021-03-01 + /// 2023-10-20 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs new file mode 100644 index 000000000000..0a40224d5fda --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs @@ -0,0 +1,133 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Core.Pipeline; +using Azure.ResourceManager.Datadog.Models; + +namespace Azure.ResourceManager.Datadog +{ + internal partial class BillingInfoRestOperations + { + private readonly TelemetryDetails _userAgent; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// Initializes a new instance of BillingInfoRestOperations. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The application id to use for user agent. + /// server parameter. + /// Api Version. + /// or is null. + public BillingInfoRestOperations(HttpPipeline pipeline, string applicationId, Uri endpoint = null, string apiVersion = default) + { + _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); + _endpoint = endpoint ?? new Uri("https://management.azure.com"); + _apiVersion = apiVersion ?? "2023-10-20"; + _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); + } + + internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/getBillingInfo", false); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/getBillingInfo", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Get marketplace and organization info mapped to the given monitor. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + DatadogBillingInfoResponseResult value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = DatadogBillingInfoResponseResult.DeserializeDatadogBillingInfoResponseResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// Get marketplace and organization info mapped to the given monitor. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response Get(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + DatadogBillingInfoResponseResult value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = DatadogBillingInfoResponseResult.DeserializeDatadogBillingInfoResponseResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs new file mode 100644 index 000000000000..209ff2da86e5 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs @@ -0,0 +1,287 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Core.Pipeline; +using Azure.ResourceManager.Datadog.Models; + +namespace Azure.ResourceManager.Datadog +{ + internal partial class CreationSupportedRestOperations + { + private readonly TelemetryDetails _userAgent; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// Initializes a new instance of CreationSupportedRestOperations. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The application id to use for user agent. + /// server parameter. + /// Api Version. + /// or is null. + public CreationSupportedRestOperations(HttpPipeline pipeline, string applicationId, Uri endpoint = null, string apiVersion = default) + { + _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); + _endpoint = endpoint ?? new Uri("https://management.azure.com"); + _apiVersion = apiVersion ?? "2023-10-20"; + _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); + } + + internal RequestUriBuilder CreateListRequestUri(string subscriptionId, string datadogOrganizationId) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/providers/Microsoft.Datadog/subscriptionStatuses", false); + uri.AppendQuery("api-version", _apiVersion, true); + uri.AppendQuery("datadogOrganizationId", datadogOrganizationId, true); + return uri; + } + + internal HttpMessage CreateListRequest(string subscriptionId, string datadogOrganizationId) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/providers/Microsoft.Datadog/subscriptionStatuses", false); + uri.AppendQuery("api-version", _apiVersion, true); + uri.AppendQuery("datadogOrganizationId", datadogOrganizationId, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// The ID of the target subscription. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + public async Task> ListAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var message = CreateListRequest(subscriptionId, datadogOrganizationId); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + CreateResourceSupportedResponseList value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// The ID of the target subscription. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + public Response List(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var message = CreateListRequest(subscriptionId, datadogOrganizationId); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + CreateResourceSupportedResponseList value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string datadogOrganizationId) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/providers/Microsoft.Datadog/subscriptionStatuses/default", false); + uri.AppendQuery("api-version", _apiVersion, true); + uri.AppendQuery("datadogOrganizationId", datadogOrganizationId, true); + return uri; + } + + internal HttpMessage CreateGetRequest(string subscriptionId, string datadogOrganizationId) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/providers/Microsoft.Datadog/subscriptionStatuses/default", false); + uri.AppendQuery("api-version", _apiVersion, true); + uri.AppendQuery("datadogOrganizationId", datadogOrganizationId, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// The ID of the target subscription. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + public async Task> GetAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var message = CreateGetRequest(subscriptionId, datadogOrganizationId); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + DatadogCreateResourceSupportedResponseResult value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// The ID of the target subscription. + /// Datadog Organization Id. + /// The cancellation token to use. + /// or is null. + /// is an empty string, and was expected to be non-empty. + public Response Get(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var message = CreateGetRequest(subscriptionId, datadogOrganizationId); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + DatadogCreateResourceSupportedResponseResult value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateListNextPageRequestUri(string nextLink, string subscriptionId, string datadogOrganizationId) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRawNextLink(nextLink, false); + return uri; + } + + internal HttpMessage CreateListNextPageRequest(string nextLink, string subscriptionId, string datadogOrganizationId) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRawNextLink(nextLink, false); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// The URL to the next page of results. + /// The ID of the target subscription. + /// Datadog Organization Id. + /// The cancellation token to use. + /// , or is null. + /// is an empty string, and was expected to be non-empty. + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(nextLink, nameof(nextLink)); + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var message = CreateListNextPageRequest(nextLink, subscriptionId, datadogOrganizationId); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + CreateResourceSupportedResponseList value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// Informs if the current subscription is being already monitored for selected Datadog organization. + /// The URL to the next page of results. + /// The ID of the target subscription. + /// Datadog Organization Id. + /// The cancellation token to use. + /// , or is null. + /// is an empty string, and was expected to be non-empty. + public Response ListNextPage(string nextLink, string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(nextLink, nameof(nextLink)); + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); + + using var message = CreateListNextPageRequest(nextLink, subscriptionId, datadogOrganizationId); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + CreateResourceSupportedResponseList value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs index 6cccd0d1de2f..9221aeaa12ca 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs @@ -32,7 +32,7 @@ public MarketplaceAgreementsRestOperations(HttpPipeline pipeline, string applica { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2021-03-01"; + _apiVersion = apiVersion ?? "2023-10-20"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } @@ -151,7 +151,7 @@ internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DatadogA /// Create Datadog marketplace agreement in the subscription. /// The ID of the target subscription. - /// The to use. + /// The request body. /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. @@ -177,7 +177,7 @@ public async Task> CreateOrUpdateAs /// Create Datadog marketplace agreement in the subscription. /// The ID of the target subscription. - /// The to use. + /// The request body. /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs new file mode 100644 index 000000000000..2f7ced44c7e7 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs @@ -0,0 +1,617 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Text.Json; +using System.Threading; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Core.Pipeline; +using Azure.ResourceManager.Datadog.Models; + +namespace Azure.ResourceManager.Datadog +{ + internal partial class MonitoredSubscriptionsRestOperations + { + private readonly TelemetryDetails _userAgent; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// Initializes a new instance of MonitoredSubscriptionsRestOperations. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The application id to use for user agent. + /// server parameter. + /// Api Version. + /// or is null. + public MonitoredSubscriptionsRestOperations(HttpPipeline pipeline, string applicationId, Uri endpoint = null, string apiVersion = default) + { + _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); + _endpoint = endpoint ?? new Uri("https://management.azure.com"); + _apiVersion = apiVersion ?? "2023-10-20"; + _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); + } + + internal RequestUriBuilder CreateListRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions", false); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateListRequest(string subscriptionId, string resourceGroupName, string monitorName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> ListAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateListRequest(subscriptionId, resourceGroupName, monitorName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + MonitoredSubscriptionPropertiesList value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = MonitoredSubscriptionPropertiesList.DeserializeMonitoredSubscriptionPropertiesList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response List(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateListRequest(subscriptionId, resourceGroupName, monitorName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + MonitoredSubscriptionPropertiesList value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = MonitoredSubscriptionPropertiesList.DeserializeMonitoredSubscriptionPropertiesList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, configurationName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + MonitoredSubscriptionPropertyData value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = MonitoredSubscriptionPropertyData.DeserializeMonitoredSubscriptionPropertyData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((MonitoredSubscriptionPropertyData)null, message.Response); + default: + throw new RequestFailedException(message.Response); + } + } + + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public Response Get(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, configurationName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + MonitoredSubscriptionPropertyData value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = MonitoredSubscriptionPropertyData.DeserializeMonitoredSubscriptionPropertyData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((MonitoredSubscriptionPropertyData)null, message.Response); + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateCreateorUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateCreateorUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Put; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); + request.Content = content; + _userAgent.Apply(message); + return message; + } + + /// Add the subscriptions that should be monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The to use. + /// The cancellation token to use. + /// , , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public async Task CreateorUpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); + + using var message = CreateCreateorUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + case 201: + case 202: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + + /// Add the subscriptions that should be monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The to use. + /// The cancellation token to use. + /// , , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public Response CreateorUpdate(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); + + using var message = CreateCreateorUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + case 201: + case 202: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Patch; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); + request.Content = content; + _userAgent.Apply(message); + return message; + } + + /// Updates the subscriptions that are being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The to use. + /// The cancellation token to use. + /// , , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public async Task UpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); + + using var message = CreateUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + case 202: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + + /// Updates the subscriptions that are being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The to use. + /// The cancellation token to use. + /// , , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public Response Update(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, MonitoredSubscriptionPropertyData data, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); + + using var message = CreateUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + case 202: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateDeleteRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateDeleteRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Delete; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/monitoredSubscriptions/", false); + uri.AppendPath(configurationName, true); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// Updates the subscriptions that are being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public async Task DeleteAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var message = CreateDeleteRequest(subscriptionId, resourceGroupName, monitorName, configurationName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + case 202: + case 204: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + + /// Updates the subscriptions that are being monitored by the Datadog monitor resource. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The configuration name. Only 'default' value is supported. + /// The cancellation token to use. + /// , , or is null. + /// , , or is an empty string, and was expected to be non-empty. + public Response Delete(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + + using var message = CreateDeleteRequest(subscriptionId, resourceGroupName, monitorName, configurationName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + case 202: + case 204: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + + internal RequestUriBuilder CreateListNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRawNextLink(nextLink, false); + return uri; + } + + internal HttpMessage CreateListNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Get; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendRawNextLink(nextLink, false); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + _userAgent.Apply(message); + return message; + } + + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// The URL to the next page of results. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The cancellation token to use. + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(nextLink, nameof(nextLink)); + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateListNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + { + MonitoredSubscriptionPropertiesList value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = MonitoredSubscriptionPropertiesList.DeserializeMonitoredSubscriptionPropertiesList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + + /// List the subscriptions currently being monitored by the Datadog monitor resource. + /// The URL to the next page of results. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// The cancellation token to use. + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response ListNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + { + Argument.AssertNotNull(nextLink, nameof(nextLink)); + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateListNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + { + MonitoredSubscriptionPropertiesList value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = MonitoredSubscriptionPropertiesList.DeserializeMonitoredSubscriptionPropertiesList(document.RootElement); + return Response.FromValue(value, message.Response); + } + default: + throw new RequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs index 4812d4549679..39e08538e15e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs @@ -32,39 +32,31 @@ public MonitorsRestOperations(HttpPipeline pipeline, string applicationId, Uri e { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2021-03-01"; + _apiVersion = apiVersion ?? "2023-10-20"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } - internal RequestUriBuilder CreateListApiKeysRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateListRequestUri(string subscriptionId) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); uri.AppendPath(subscriptionId, true); - uri.AppendPath("/resourceGroups/", false); - uri.AppendPath(resourceGroupName, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); - uri.AppendPath(monitorName, true); - uri.AppendPath("/listApiKeys", false); + uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateListApiKeysRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateListRequest(string subscriptionId) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Post; + request.Method = RequestMethod.Get; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); uri.AppendPath(subscriptionId, true); - uri.AppendPath("/resourceGroups/", false); - uri.AppendPath(resourceGroupName, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); - uri.AppendPath(monitorName, true); - uri.AppendPath("/listApiKeys", false); + uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); @@ -72,28 +64,24 @@ internal HttpMessage CreateListApiKeysRequest(string subscriptionId, string reso return message; } - /// List the api keys for a given monitor resource. + /// List all monitors under the specified subscription. /// The ID of the target subscription. - /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , or is null. - /// , or is an empty string, and was expected to be non-empty. - public async Task> ListApiKeysAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// is null. + /// is an empty string, and was expected to be non-empty. + public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); - Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListApiKeysRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateListRequest(subscriptionId); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogApiKeyListResponse value = default; + DatadogMonitorResourceListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -101,28 +89,24 @@ public async Task> ListApiKeysAsync(string s } } - /// List the api keys for a given monitor resource. + /// List all monitors under the specified subscription. /// The ID of the target subscription. - /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , or is null. - /// , or is an empty string, and was expected to be non-empty. - public Response ListApiKeys(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// is null. + /// is an empty string, and was expected to be non-empty. + public Response List(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); - Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListApiKeysRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateListRequest(subscriptionId); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogApiKeyListResponse value = default; + DatadogMonitorResourceListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -130,7 +114,7 @@ public Response ListApiKeys(string subscriptionId, st } } - internal RequestUriBuilder CreateGetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateListByResourceGroupRequestUri(string subscriptionId, string resourceGroupName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -138,27 +122,23 @@ internal RequestUriBuilder CreateGetDefaultKeyRequestUri(string subscriptionId, uri.AppendPath(subscriptionId, true); uri.AppendPath("/resourceGroups/", false); uri.AppendPath(resourceGroupName, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); - uri.AppendPath(monitorName, true); - uri.AppendPath("/getDefaultKey", false); + uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateGetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateListByResourceGroupRequest(string subscriptionId, string resourceGroupName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Post; + request.Method = RequestMethod.Get; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); uri.AppendPath(subscriptionId, true); uri.AppendPath("/resourceGroups/", false); uri.AppendPath(resourceGroupName, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); - uri.AppendPath(monitorName, true); - uri.AppendPath("/getDefaultKey", false); + uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); @@ -166,28 +146,26 @@ internal HttpMessage CreateGetDefaultKeyRequest(string subscriptionId, string re return message; } - /// Get the default api key. + /// List all monitors under the specified resource group. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , or is null. - /// , or is an empty string, and was expected to be non-empty. - public async Task> GetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// or is null. + /// or is an empty string, and was expected to be non-empty. + public async Task> ListByResourceGroupAsync(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateGetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateListByResourceGroupRequest(subscriptionId, resourceGroupName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogApiKey value = default; + DatadogMonitorResourceListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKey.DeserializeDatadogApiKey(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -195,28 +173,26 @@ public async Task> GetDefaultKeyAsync(string subscriptio } } - /// Get the default api key. + /// List all monitors under the specified resource group. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , or is null. - /// , or is an empty string, and was expected to be non-empty. - public Response GetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// or is null. + /// or is an empty string, and was expected to be non-empty. + public Response ListByResourceGroup(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateGetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateListByResourceGroupRequest(subscriptionId, resourceGroupName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogApiKey value = default; + DatadogMonitorResourceListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKey.DeserializeDatadogApiKey(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -224,7 +200,7 @@ public Response GetDefaultKey(string subscriptionId, string resou } } - internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body) + internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -234,16 +210,15 @@ internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/setDefaultKey", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body) + internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Post; + request.Method = RequestMethod.Get; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -252,72 +227,76 @@ internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string re uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/setDefaultKey", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); - if (body != null) - { - request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(body, ModelSerializationExtensions.WireOptions); - request.Content = content; - } _userAgent.Apply(message); return message; } - /// Set the default api key. + /// Get the properties of a specific monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task SetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body = null, CancellationToken cancellationToken = default) + public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, body); + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - return message.Response; + { + DatadogMonitorResourceData value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = DatadogMonitorResourceData.DeserializeDatadogMonitorResourceData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((DatadogMonitorResourceData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - /// Set the default api key. + /// Get the properties of a specific monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response SetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body = null, CancellationToken cancellationToken = default) + public Response Get(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, body); + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - return message.Response; + { + DatadogMonitorResourceData value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = DatadogMonitorResourceData.DeserializeDatadogMonitorResourceData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((DatadogMonitorResourceData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateListHostsRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateCreateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -327,16 +306,15 @@ internal RequestUriBuilder CreateListHostsRequestUri(string subscriptionId, stri uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/listHosts", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateListHostsRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateCreateRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Post; + request.Method = RequestMethod.Put; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -345,73 +323,72 @@ internal HttpMessage CreateListHostsRequest(string subscriptionId, string resour uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/listHosts", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); + request.Content = content; _userAgent.Apply(message); return message; } - /// List the hosts for a given monitor resource. + /// Create a monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. + /// The to use. /// The cancellation token to use. - /// , or is null. + /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListHostsAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task CreateAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNull(data, nameof(data)); - using var message = CreateListHostsRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateCreateRequest(subscriptionId, resourceGroupName, monitorName, data); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - { - DatadogHostListResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } + case 201: + return message.Response; default: throw new RequestFailedException(message.Response); } } - /// List the hosts for a given monitor resource. + /// Create a monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. + /// The to use. /// The cancellation token to use. - /// , or is null. + /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListHosts(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response Create(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNull(data, nameof(data)); - using var message = CreateListHostsRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateCreateRequest(subscriptionId, resourceGroupName, monitorName, data); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - { - DatadogHostListResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } + case 201: + return message.Response; default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateListLinkedResourcesRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -421,16 +398,15 @@ internal RequestUriBuilder CreateListLinkedResourcesRequestUri(string subscripti uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/listLinkedResources", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateListLinkedResourcesRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Post; + request.Method = RequestMethod.Patch; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -439,73 +415,72 @@ internal HttpMessage CreateListLinkedResourcesRequest(string subscriptionId, str uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/listLinkedResources", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(patch, ModelSerializationExtensions.WireOptions); + request.Content = content; _userAgent.Apply(message); return message; } - /// List all Azure resources associated to the same Datadog organization as the target resource. + /// Update a monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. + /// The to use. /// The cancellation token to use. - /// , or is null. + /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListLinkedResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task UpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNull(patch, nameof(patch)); - using var message = CreateListLinkedResourcesRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateUpdateRequest(subscriptionId, resourceGroupName, monitorName, patch); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - { - LinkedResourceListResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } + case 201: + return message.Response; default: throw new RequestFailedException(message.Response); } } - /// List all Azure resources associated to the same Datadog organization as the target resource. + /// Update a monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. + /// The to use. /// The cancellation token to use. - /// , or is null. + /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListLinkedResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response Update(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + Argument.AssertNotNull(patch, nameof(patch)); - using var message = CreateListLinkedResourcesRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateUpdateRequest(subscriptionId, resourceGroupName, monitorName, patch); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - { - LinkedResourceListResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } + case 201: + return message.Response; default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateListMonitoredResourcesRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateDeleteRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -515,16 +490,15 @@ internal RequestUriBuilder CreateListMonitoredResourcesRequestUri(string subscri uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/listMonitoredResources", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateListMonitoredResourcesRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateDeleteRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Post; + request.Method = RequestMethod.Delete; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -533,7 +507,6 @@ internal HttpMessage CreateListMonitoredResourcesRequest(string subscriptionId, uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/listMonitoredResources", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); @@ -541,85 +514,87 @@ internal HttpMessage CreateListMonitoredResourcesRequest(string subscriptionId, return message; } - /// List the resources currently being monitored by the Datadog monitor resource. + /// Delete a monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListMonitoredResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task DeleteAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListMonitoredResourcesRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateDeleteRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - { - MonitoredResourceListResponse value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } + case 202: + case 204: + return message.Response; default: throw new RequestFailedException(message.Response); } } - /// List the resources currently being monitored by the Datadog monitor resource. + /// Delete a monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListMonitoredResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response Delete(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListMonitoredResourcesRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateDeleteRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - { - MonitoredResourceListResponse value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); - return Response.FromValue(value, message.Response); - } + case 202: + case 204: + return message.Response; default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateListRequestUri(string subscriptionId) + internal RequestUriBuilder CreateGetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); uri.AppendPath(subscriptionId, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/getDefaultKey", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateListRequest(string subscriptionId) + internal HttpMessage CreateGetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Get; + request.Method = RequestMethod.Post; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); uri.AppendPath(subscriptionId, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/getDefaultKey", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); @@ -627,24 +602,28 @@ internal HttpMessage CreateListRequest(string subscriptionId) return message; } - /// List all monitors under the specified subscription. + /// Get the default api key. /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// is null. - /// is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> GetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListRequest(subscriptionId); + using var message = CreateGetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogApiKey value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogApiKey.DeserializeDatadogApiKey(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -652,24 +631,28 @@ public async Task> ListAsync(string } } - /// List all monitors under the specified subscription. + /// Get the default api key. /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// is null. - /// is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, CancellationToken cancellationToken = default) + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response GetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListRequest(subscriptionId); + using var message = CreateGetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogApiKey value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogApiKey.DeserializeDatadogApiKey(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -677,7 +660,7 @@ public Response List(string subscriptionId, } } - internal RequestUriBuilder CreateListByResourceGroupRequestUri(string subscriptionId, string resourceGroupName) + internal RequestUriBuilder CreateListApiKeysRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -685,23 +668,27 @@ internal RequestUriBuilder CreateListByResourceGroupRequestUri(string subscripti uri.AppendPath(subscriptionId, true); uri.AppendPath("/resourceGroups/", false); uri.AppendPath(resourceGroupName, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/listApiKeys", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateListByResourceGroupRequest(string subscriptionId, string resourceGroupName) + internal HttpMessage CreateListApiKeysRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Get; + request.Method = RequestMethod.Post; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); uri.AppendPath(subscriptionId, true); uri.AppendPath("/resourceGroups/", false); uri.AppendPath(resourceGroupName, true); - uri.AppendPath("/providers/Microsoft.Datadog/monitors", false); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/listApiKeys", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); @@ -709,26 +696,28 @@ internal HttpMessage CreateListByResourceGroupRequest(string subscriptionId, str return message; } - /// List all monitors under the specified resource group. + /// List the api keys for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// or is null. - /// or is an empty string, and was expected to be non-empty. - public async Task> ListByResourceGroupAsync(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> ListApiKeysAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListByResourceGroupRequest(subscriptionId, resourceGroupName); + using var message = CreateListApiKeysRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogApiKeyListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -736,26 +725,28 @@ public async Task> ListByResourceGr } } - /// List all monitors under the specified resource group. + /// List the api keys for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// or is null. - /// or is an empty string, and was expected to be non-empty. - public Response ListByResourceGroup(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response ListApiKeys(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListByResourceGroupRequest(subscriptionId, resourceGroupName); + using var message = CreateListApiKeysRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogApiKeyListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -763,7 +754,7 @@ public Response ListByResourceGroup(string s } } - internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateListHostsRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -773,15 +764,16 @@ internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string res uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/listHosts", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateListHostsRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Get; + request.Method = RequestMethod.Post; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -790,6 +782,7 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGrou uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/listHosts", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); @@ -797,69 +790,65 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGrou return message; } - /// Get the properties of a specific monitor resource. + /// List the hosts for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListHostsAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateListHostsRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceData value = default; + DatadogHostListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceData.DeserializeDatadogMonitorResourceData(document.RootElement); + value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); return Response.FromValue(value, message.Response); } - case 404: - return Response.FromValue((DatadogMonitorResourceData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - /// Get the properties of a specific monitor resource. + /// List the hosts for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response Get(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListHosts(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateListHostsRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceData value = default; + DatadogHostListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceData.DeserializeDatadogMonitorResourceData(document.RootElement); + value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); return Response.FromValue(value, message.Response); } - case 404: - return Response.FromValue((DatadogMonitorResourceData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateCreateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data) + internal RequestUriBuilder CreateListLinkedResourcesRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -869,15 +858,16 @@ internal RequestUriBuilder CreateCreateRequestUri(string subscriptionId, string uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/listLinkedResources", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateCreateRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data) + internal HttpMessage CreateListLinkedResourcesRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Put; + request.Method = RequestMethod.Post; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -886,72 +876,73 @@ internal HttpMessage CreateCreateRequest(string subscriptionId, string resourceG uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/listLinkedResources", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); - request.Content = content; _userAgent.Apply(message); return message; } - /// Create a monitor resource. + /// List all Azure resources associated to the same Datadog organization as the target resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task CreateAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data, CancellationToken cancellationToken = default) + public async Task> ListLinkedResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - Argument.AssertNotNull(data, nameof(data)); - using var message = CreateCreateRequest(subscriptionId, resourceGroupName, monitorName, data); + using var message = CreateListLinkedResourcesRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - case 201: - return message.Response; + { + LinkedResourceListResponse value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + return Response.FromValue(value, message.Response); + } default: throw new RequestFailedException(message.Response); } } - /// Create a monitor resource. + /// List all Azure resources associated to the same Datadog organization as the target resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response Create(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourceData data, CancellationToken cancellationToken = default) + public Response ListLinkedResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - Argument.AssertNotNull(data, nameof(data)); - using var message = CreateCreateRequest(subscriptionId, resourceGroupName, monitorName, data); + using var message = CreateListLinkedResourcesRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - case 201: - return message.Response; + { + LinkedResourceListResponse value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + return Response.FromValue(value, message.Response); + } default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch) + internal RequestUriBuilder CreateListMonitoredResourcesRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -961,15 +952,16 @@ internal RequestUriBuilder CreateUpdateRequestUri(string subscriptionId, string uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/listMonitoredResources", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch) + internal HttpMessage CreateListMonitoredResourcesRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Patch; + request.Method = RequestMethod.Post; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -978,72 +970,73 @@ internal HttpMessage CreateUpdateRequest(string subscriptionId, string resourceG uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/listMonitoredResources", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(patch, ModelSerializationExtensions.WireOptions); - request.Content = content; _userAgent.Apply(message); return message; } - /// Update a monitor resource. + /// List the resources currently being monitored by the Datadog monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task UpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch, CancellationToken cancellationToken = default) + public async Task> ListMonitoredResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - Argument.AssertNotNull(patch, nameof(patch)); - using var message = CreateUpdateRequest(subscriptionId, resourceGroupName, monitorName, patch); + using var message = CreateListMonitoredResourcesRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - case 201: - return message.Response; + { + MonitoredResourceListResponse value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + return Response.FromValue(value, message.Response); + } default: throw new RequestFailedException(message.Response); } } - /// Update a monitor resource. + /// List the resources currently being monitored by the Datadog monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response Update(string subscriptionId, string resourceGroupName, string monitorName, DatadogMonitorResourcePatch patch, CancellationToken cancellationToken = default) + public Response ListMonitoredResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - Argument.AssertNotNull(patch, nameof(patch)); - using var message = CreateUpdateRequest(subscriptionId, resourceGroupName, monitorName, patch); + using var message = CreateListMonitoredResourcesRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - case 201: - return message.Response; + { + MonitoredResourceListResponse value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + return Response.FromValue(value, message.Response); + } default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateDeleteRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateRefreshSetPasswordLinkRequestUri(string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1053,15 +1046,16 @@ internal RequestUriBuilder CreateDeleteRequestUri(string subscriptionId, string uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/refreshSetPasswordLink", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateDeleteRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateRefreshSetPasswordLinkRequest(string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Delete; + request.Method = RequestMethod.Post; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -1070,6 +1064,7 @@ internal HttpMessage CreateDeleteRequest(string subscriptionId, string resourceG uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); + uri.AppendPath("/refreshSetPasswordLink", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); @@ -1077,59 +1072,65 @@ internal HttpMessage CreateDeleteRequest(string subscriptionId, string resourceG return message; } - /// Delete a monitor resource. + /// Refresh the set password link and return a latest one. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task DeleteAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> RefreshSetPasswordLinkAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateDeleteRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateRefreshSetPasswordLinkRequest(subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - case 202: - case 204: - return message.Response; + { + DatadogSetPasswordLink value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = DatadogSetPasswordLink.DeserializeDatadogSetPasswordLink(document.RootElement); + return Response.FromValue(value, message.Response); + } default: throw new RequestFailedException(message.Response); } } - /// Delete a monitor resource. + /// Refresh the set password link and return a latest one. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response Delete(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response RefreshSetPasswordLink(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateDeleteRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateRefreshSetPasswordLinkRequest(subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - case 202: - case 204: - return message.Response; + { + DatadogSetPasswordLink value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = DatadogSetPasswordLink.DeserializeDatadogSetPasswordLink(document.RootElement); + return Response.FromValue(value, message.Response); + } default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateRefreshSetPasswordLinkRequestUri(string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1139,12 +1140,12 @@ internal RequestUriBuilder CreateRefreshSetPasswordLinkRequestUri(string subscri uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/refreshSetPasswordLink", false); + uri.AppendPath("/setDefaultKey", false); uri.AppendQuery("api-version", _apiVersion, true); return uri; } - internal HttpMessage CreateRefreshSetPasswordLinkRequest(string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1157,73 +1158,72 @@ internal HttpMessage CreateRefreshSetPasswordLinkRequest(string subscriptionId, uri.AppendPath(resourceGroupName, true); uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); uri.AppendPath(monitorName, true); - uri.AppendPath("/refreshSetPasswordLink", false); + uri.AppendPath("/setDefaultKey", false); uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); + if (body != null) + { + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(body, ModelSerializationExtensions.WireOptions); + request.Content = content; + } _userAgent.Apply(message); return message; } - /// Refresh the set password link and return a latest one. + /// Set the default api key. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. + /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> RefreshSetPasswordLinkAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task SetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateRefreshSetPasswordLinkRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, body); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - { - DatadogSetPasswordLink value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogSetPasswordLink.DeserializeDatadogSetPasswordLink(document.RootElement); - return Response.FromValue(value, message.Response); - } + return message.Response; default: throw new RequestFailedException(message.Response); } } - /// Refresh the set password link and return a latest one. + /// Set the default api key. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. + /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response RefreshSetPasswordLink(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response SetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateRefreshSetPasswordLinkRequest(subscriptionId, resourceGroupName, monitorName); + using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, body); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - { - DatadogSetPasswordLink value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogSetPasswordLink.DeserializeDatadogSetPasswordLink(document.RootElement); - return Response.FromValue(value, message.Response); - } + return message.Response; default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateListApiKeysNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateListNextPageRequestUri(string nextLink, string subscriptionId) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1231,7 +1231,7 @@ internal RequestUriBuilder CreateListApiKeysNextPageRequestUri(string nextLink, return uri; } - internal HttpMessage CreateListApiKeysNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateListNextPageRequest(string nextLink, string subscriptionId) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1245,30 +1245,26 @@ internal HttpMessage CreateListApiKeysNextPageRequest(string nextLink, string su return message; } - /// List the api keys for a given monitor resource. + /// List all monitors under the specified subscription. /// The URL to the next page of results. /// The ID of the target subscription. - /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , , or is null. - /// , or is an empty string, and was expected to be non-empty. - public async Task> ListApiKeysNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// or is null. + /// is an empty string, and was expected to be non-empty. + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); - Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListApiKeysNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListNextPageRequest(nextLink, subscriptionId); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogApiKeyListResponse value = default; + DatadogMonitorResourceListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1276,30 +1272,26 @@ public async Task> ListApiKeysNextPageAsync( } } - /// List the api keys for a given monitor resource. + /// List all monitors under the specified subscription. /// The URL to the next page of results. /// The ID of the target subscription. - /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , , or is null. - /// , or is an empty string, and was expected to be non-empty. - public Response ListApiKeysNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// or is null. + /// is an empty string, and was expected to be non-empty. + public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); - Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListApiKeysNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListNextPageRequest(nextLink, subscriptionId); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogApiKeyListResponse value = default; + DatadogMonitorResourceListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1307,7 +1299,7 @@ public Response ListApiKeysNextPage(string nextLink, } } - internal RequestUriBuilder CreateListHostsNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateListByResourceGroupNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1315,7 +1307,7 @@ internal RequestUriBuilder CreateListHostsNextPageRequestUri(string nextLink, st return uri; } - internal HttpMessage CreateListHostsNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateListByResourceGroupNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1329,30 +1321,28 @@ internal HttpMessage CreateListHostsNextPageRequest(string nextLink, string subs return message; } - /// List the hosts for a given monitor resource. + /// List all monitors under the specified resource group. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , , or is null. - /// , or is an empty string, and was expected to be non-empty. - public async Task> ListHostsNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + public async Task> ListByResourceGroupNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListHostsNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListByResourceGroupNextPageRequest(nextLink, subscriptionId, resourceGroupName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogHostListResponse value = default; + DatadogMonitorResourceListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1360,30 +1350,28 @@ public async Task> ListHostsNextPageAsync(stri } } - /// List the hosts for a given monitor resource. + /// List all monitors under the specified resource group. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. - /// Monitor resource name. /// The cancellation token to use. - /// , , or is null. - /// , or is an empty string, and was expected to be non-empty. - public Response ListHostsNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + /// , or is null. + /// or is an empty string, and was expected to be non-empty. + public Response ListByResourceGroupNextPage(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); - Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListHostsNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListByResourceGroupNextPageRequest(nextLink, subscriptionId, resourceGroupName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogHostListResponse value = default; + DatadogMonitorResourceListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); + value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1391,7 +1379,7 @@ public Response ListHostsNextPage(string nextLink, stri } } - internal RequestUriBuilder CreateListLinkedResourcesNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateListApiKeysNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1399,7 +1387,7 @@ internal RequestUriBuilder CreateListLinkedResourcesNextPageRequestUri(string ne return uri; } - internal HttpMessage CreateListLinkedResourcesNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateListApiKeysNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1413,7 +1401,7 @@ internal HttpMessage CreateListLinkedResourcesNextPageRequest(string nextLink, s return message; } - /// List all Azure resources associated to the same Datadog organization as the target resource. + /// List the api keys for a given monitor resource. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. @@ -1421,22 +1409,22 @@ internal HttpMessage CreateListLinkedResourcesNextPageRequest(string nextLink, s /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListLinkedResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListApiKeysNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListLinkedResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListApiKeysNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - LinkedResourceListResponse value = default; + DatadogApiKeyListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1444,7 +1432,7 @@ public async Task> ListLinkedResourcesNextP } } - /// List all Azure resources associated to the same Datadog organization as the target resource. + /// List the api keys for a given monitor resource. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. @@ -1452,22 +1440,22 @@ public async Task> ListLinkedResourcesNextP /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListLinkedResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListApiKeysNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListLinkedResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListApiKeysNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - LinkedResourceListResponse value = default; + DatadogApiKeyListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1475,7 +1463,7 @@ public Response ListLinkedResourcesNextPage(string n } } - internal RequestUriBuilder CreateListMonitoredResourcesNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal RequestUriBuilder CreateListHostsNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1483,7 +1471,7 @@ internal RequestUriBuilder CreateListMonitoredResourcesNextPageRequestUri(string return uri; } - internal HttpMessage CreateListMonitoredResourcesNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) + internal HttpMessage CreateListHostsNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1497,7 +1485,7 @@ internal HttpMessage CreateListMonitoredResourcesNextPageRequest(string nextLink return message; } - /// List the resources currently being monitored by the Datadog monitor resource. + /// List the hosts for a given monitor resource. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. @@ -1505,22 +1493,22 @@ internal HttpMessage CreateListMonitoredResourcesNextPageRequest(string nextLink /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListMonitoredResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListHostsNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListMonitoredResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListHostsNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - MonitoredResourceListResponse value = default; + DatadogHostListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1528,7 +1516,7 @@ public async Task> ListMonitoredResource } } - /// List the resources currently being monitored by the Datadog monitor resource. + /// List the hosts for a given monitor resource. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. @@ -1536,22 +1524,22 @@ public async Task> ListMonitoredResource /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListMonitoredResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListHostsNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListMonitoredResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); + using var message = CreateListHostsNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - MonitoredResourceListResponse value = default; + DatadogHostListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1559,7 +1547,7 @@ public Response ListMonitoredResourcesNextPage(st } } - internal RequestUriBuilder CreateListNextPageRequestUri(string nextLink, string subscriptionId) + internal RequestUriBuilder CreateListLinkedResourcesNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1567,7 +1555,7 @@ internal RequestUriBuilder CreateListNextPageRequestUri(string nextLink, string return uri; } - internal HttpMessage CreateListNextPageRequest(string nextLink, string subscriptionId) + internal HttpMessage CreateListLinkedResourcesNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1581,26 +1569,30 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript return message; } - /// List all monitors under the specified subscription. + /// List all Azure resources associated to the same Datadog organization as the target resource. /// The URL to the next page of results. /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// or is null. - /// is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> ListLinkedResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListNextPageRequest(nextLink, subscriptionId); + using var message = CreateListLinkedResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + LinkedResourceListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1608,26 +1600,30 @@ public async Task> ListNextPageAsyn } } - /// List all monitors under the specified subscription. + /// List all Azure resources associated to the same Datadog organization as the target resource. /// The URL to the next page of results. /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// or is null. - /// is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response ListLinkedResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListNextPageRequest(nextLink, subscriptionId); + using var message = CreateListLinkedResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + LinkedResourceListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1635,7 +1631,7 @@ public Response ListNextPage(string nextLink } } - internal RequestUriBuilder CreateListByResourceGroupNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName) + internal RequestUriBuilder CreateListMonitoredResourcesNextPageRequestUri(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1643,7 +1639,7 @@ internal RequestUriBuilder CreateListByResourceGroupNextPageRequestUri(string ne return uri; } - internal HttpMessage CreateListByResourceGroupNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName) + internal HttpMessage CreateListMonitoredResourcesNextPageRequest(string nextLink, string subscriptionId, string resourceGroupName, string monitorName) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1657,28 +1653,30 @@ internal HttpMessage CreateListByResourceGroupNextPageRequest(string nextLink, s return message; } - /// List all monitors under the specified resource group. + /// List the resources currently being monitored by the Datadog monitor resource. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// , or is null. - /// or is an empty string, and was expected to be non-empty. - public async Task> ListByResourceGroupNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task> ListMonitoredResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListByResourceGroupNextPageRequest(nextLink, subscriptionId, resourceGroupName); + using var message = CreateListMonitoredResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + MonitoredResourceListResponse value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1686,28 +1684,30 @@ public async Task> ListByResourceGr } } - /// List all monitors under the specified resource group. + /// List the resources currently being monitored by the Datadog monitor resource. /// The URL to the next page of results. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. /// The cancellation token to use. - /// , or is null. - /// or is an empty string, and was expected to be non-empty. - public Response ListByResourceGroupNextPage(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + /// , , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response ListMonitoredResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateListByResourceGroupNextPageRequest(nextLink, subscriptionId, resourceGroupName); + using var message = CreateListMonitoredResourcesNextPageRequest(nextLink, subscriptionId, resourceGroupName, monitorName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogMonitorResourceListResponse value = default; + MonitoredResourceListResponse value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs index 420fc2201a64..0941daae63e1 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs @@ -32,7 +32,7 @@ public SingleSignOnConfigurationsRestOperations(HttpPipeline pipeline, string ap { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2021-03-01"; + _apiVersion = apiVersion ?? "2023-10-20"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } @@ -130,7 +130,7 @@ public Response List(string subscriptio } } - internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data) + internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -146,11 +146,11 @@ internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, return uri; } - internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data) + internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Put; + request.Method = RequestMethod.Get; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -164,73 +164,77 @@ internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, string r uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); - request.Content = content; _userAgent.Apply(message); return message; } - /// Configures single-sign-on for this resource. + /// Gets the datadog single sign-on resource for the given Monitor. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Configuration name. - /// The to use. /// The cancellation token to use. - /// , , , or is null. + /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public async Task CreateOrUpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data, CancellationToken cancellationToken = default) + public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); - Argument.AssertNotNull(data, nameof(data)); - using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, configurationName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - case 201: - return message.Response; + { + DatadogSingleSignOnResourceData value = default; + using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); + value = DatadogSingleSignOnResourceData.DeserializeDatadogSingleSignOnResourceData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((DatadogSingleSignOnResourceData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - /// Configures single-sign-on for this resource. + /// Gets the datadog single sign-on resource for the given Monitor. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Configuration name. - /// The to use. /// The cancellation token to use. - /// , , , or is null. + /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public Response CreateOrUpdate(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data, CancellationToken cancellationToken = default) + public Response Get(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); - Argument.AssertNotNull(data, nameof(data)); - using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, configurationName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - case 201: - return message.Response; + { + DatadogSingleSignOnResourceData value = default; + using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); + value = DatadogSingleSignOnResourceData.DeserializeDatadogSingleSignOnResourceData(document.RootElement); + return Response.FromValue(value, message.Response); + } + case 404: + return Response.FromValue((DatadogSingleSignOnResourceData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) + internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -246,11 +250,11 @@ internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string res return uri; } - internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName) + internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Get; + request.Method = RequestMethod.Put; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -264,71 +268,67 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGrou uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); + request.Content = content; _userAgent.Apply(message); return message; } - /// Gets the datadog single sign-on resource for the given Monitor. + /// Configures single-sign-on for this resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Configuration name. + /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) + public async Task CreateOrUpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); - using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, configurationName); + using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: - { - DatadogSingleSignOnResourceData value = default; - using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogSingleSignOnResourceData.DeserializeDatadogSingleSignOnResourceData(document.RootElement); - return Response.FromValue(value, message.Response); - } - case 404: - return Response.FromValue((DatadogSingleSignOnResourceData)null, message.Response); + case 201: + return message.Response; default: throw new RequestFailedException(message.Response); } } - /// Gets the datadog single sign-on resource for the given Monitor. + /// Configures single-sign-on for this resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Configuration name. + /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public Response Get(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, CancellationToken cancellationToken = default) + public Response CreateOrUpdate(string subscriptionId, string resourceGroupName, string monitorName, string configurationName, DatadogSingleSignOnResourceData data, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(configurationName, nameof(configurationName)); + Argument.AssertNotNull(data, nameof(data)); - using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, configurationName); + using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, configurationName, data); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: - { - DatadogSingleSignOnResourceData value = default; - using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogSingleSignOnResourceData.DeserializeDatadogSingleSignOnResourceData(document.RootElement); - return Response.FromValue(value, message.Response); - } - case 404: - return Response.FromValue((DatadogSingleSignOnResourceData)null, message.Response); + case 201: + return message.Response; default: throw new RequestFailedException(message.Response); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs index 8b2da67f4990..44f40a6e029e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs @@ -32,7 +32,7 @@ public TagRulesRestOperations(HttpPipeline pipeline, string applicationId, Uri e { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2021-03-01"; + _apiVersion = apiVersion ?? "2023-10-20"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } @@ -130,7 +130,7 @@ public Response List(string subscriptionId, stri } } - internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data) + internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -146,11 +146,11 @@ internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, return uri; } - internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data) + internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Put; + request.Method = RequestMethod.Get; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -164,32 +164,26 @@ internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, string r uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); - request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); - request.Content = content; _userAgent.Apply(message); return message; } - /// Create or update a tag rule set for a given monitor resource. + /// Get a tag rule set for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Rule set name. - /// The to use. /// The cancellation token to use. - /// , , , or is null. + /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public async Task> CreateOrUpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data, CancellationToken cancellationToken = default) + public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(ruleSetName, nameof(ruleSetName)); - Argument.AssertNotNull(data, nameof(data)); - using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName, data); + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { @@ -200,29 +194,29 @@ public async Task> CreateOrUpdateAsync(string su value = MonitoringTagRuleData.DeserializeMonitoringTagRuleData(document.RootElement); return Response.FromValue(value, message.Response); } + case 404: + return Response.FromValue((MonitoringTagRuleData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - /// Create or update a tag rule set for a given monitor resource. + /// Get a tag rule set for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Rule set name. - /// The to use. /// The cancellation token to use. - /// , , , or is null. + /// , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public Response CreateOrUpdate(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data, CancellationToken cancellationToken = default) + public Response Get(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(ruleSetName, nameof(ruleSetName)); - Argument.AssertNotNull(data, nameof(data)); - using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName, data); + using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { @@ -233,12 +227,14 @@ public Response CreateOrUpdate(string subscriptionId, str value = MonitoringTagRuleData.DeserializeMonitoringTagRuleData(document.RootElement); return Response.FromValue(value, message.Response); } + case 404: + return Response.FromValue((MonitoringTagRuleData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName) + internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -254,11 +250,11 @@ internal RequestUriBuilder CreateGetRequestUri(string subscriptionId, string res return uri; } - internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName) + internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data) { var message = _pipeline.CreateMessage(); var request = message.Request; - request.Method = RequestMethod.Get; + request.Method = RequestMethod.Put; var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); uri.AppendPath("/subscriptions/", false); @@ -272,26 +268,32 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGrou uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(data, ModelSerializationExtensions.WireOptions); + request.Content = content; _userAgent.Apply(message); return message; } - /// Get a tag rule set for a given monitor resource. + /// Create or update a tag rule set for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Rule set name. + /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, CancellationToken cancellationToken = default) + public async Task> CreateOrUpdateAsync(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(ruleSetName, nameof(ruleSetName)); + Argument.AssertNotNull(data, nameof(data)); - using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName); + using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName, data); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { @@ -302,29 +304,29 @@ public async Task> GetAsync(string subscriptionI value = MonitoringTagRuleData.DeserializeMonitoringTagRuleData(document.RootElement); return Response.FromValue(value, message.Response); } - case 404: - return Response.FromValue((MonitoringTagRuleData)null, message.Response); default: throw new RequestFailedException(message.Response); } } - /// Get a tag rule set for a given monitor resource. + /// Create or update a tag rule set for a given monitor resource. /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. /// Rule set name. + /// The to use. /// The cancellation token to use. - /// , , or is null. + /// , , , or is null. /// , , or is an empty string, and was expected to be non-empty. - public Response Get(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, CancellationToken cancellationToken = default) + public Response CreateOrUpdate(string subscriptionId, string resourceGroupName, string monitorName, string ruleSetName, MonitoringTagRuleData data, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); Argument.AssertNotNullOrEmpty(ruleSetName, nameof(ruleSetName)); + Argument.AssertNotNull(data, nameof(data)); - using var message = CreateGetRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName); + using var message = CreateCreateOrUpdateRequest(subscriptionId, resourceGroupName, monitorName, ruleSetName, data); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { @@ -335,8 +337,6 @@ public Response Get(string subscriptionId, string resourc value = MonitoringTagRuleData.DeserializeMonitoringTagRuleData(document.RootElement); return Response.FromValue(value, message.Response); } - case 404: - return Response.FromValue((MonitoringTagRuleData)null, message.Response); default: throw new RequestFailedException(message.Response); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md index ea66a000cbb4..b3e618eb10f6 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md @@ -8,7 +8,8 @@ azure-arm: true csharp: true library-name: Datadog namespace: Azure.ResourceManager.Datadog -require: https://github.com/Azure/azure-rest-api-specs/blob/066eb8c81e14e0f3b22b6700c67693eef5f79ea9/specification/datadog/resource-manager/readme.md +require: https://github.com/Azure/azure-rest-api-specs/blob/c37407dc4b8c49dd01fe73d9278e5c21beea169c/specification/datadog/resource-manager/readme.md +# tag: package-2023-10 output-folder: $(this-folder)/Generated clear-output-folder: true sample-gen: @@ -52,5 +53,8 @@ acronym-mapping: rename-mapping: DatadogAgreementResource: DatadogAgreementResourceProperties MonitoredResource: MonitoredResourceContent + BillingInfoResponse: DatadogBillingInfoResponseResult + CreateResourceSupportedResponse: DatadogCreateResourceSupportedResponseResult + LinkedResource: LinkedInfo ``` diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs index 015ee8b55719..d774715053ba 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs @@ -10,7 +10,6 @@ using Azure.Core; using Azure.Identity; using Azure.ResourceManager.Datadog.Models; -using Azure.ResourceManager.Resources.Models; using NUnit.Framework; namespace Azure.ResourceManager.Datadog.Samples @@ -21,7 +20,7 @@ public partial class Sample_DatadogMonitorResource [Ignore("Only validating compilation of examples")] public async Task Get_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +50,7 @@ public async Task Get_MonitorsGet() [Ignore("Only validating compilation of examples")] public async Task Delete_MonitorsDelete() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Delete.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Delete.json // this example is just showing the usage of "Monitors_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -77,7 +76,7 @@ public async Task Delete_MonitorsDelete() [Ignore("Only validating compilation of examples")] public async Task Update_MonitorsUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Update.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Update.json // this example is just showing the usage of "Monitors_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -94,7 +93,17 @@ public async Task Update_MonitorsUpdate() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogMonitorResourcePatch patch = new DatadogMonitorResourcePatch(); + DatadogMonitorResourcePatch patch = new DatadogMonitorResourcePatch + { + Properties = new MonitorUpdateProperties + { + MonitoringStatus = MonitoringStatus.Enabled, + }, + Tags = +{ +["Environment"] = "Dev" +}, + }; ArmOperation lro = await datadogMonitorResource.UpdateAsync(WaitUntil.Completed, patch); DatadogMonitorResource result = lro.Value; @@ -105,11 +114,37 @@ public async Task Update_MonitorsUpdate() Console.WriteLine($"Succeeded on id: {resourceData.Id}"); } + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetDefaultKey_MonitorsGetDefaultKey() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/ApiKeys_GetDefaultKey.json + // this example is just showing the usage of "Monitors_GetDefaultKey" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this DatadogMonitorResource created on azure + // for more information of creating DatadogMonitorResource, please refer to the document of DatadogMonitorResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); + DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); + + // invoke the operation + DatadogApiKey result = await datadogMonitorResource.GetDefaultKeyAsync(); + + Console.WriteLine($"Succeeded: {result}"); + } + [Test] [Ignore("Only validating compilation of examples")] public async Task GetApiKeys_MonitorsListApiKeys() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/ApiKeys_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/ApiKeys_List.json // this example is just showing the usage of "Monitors_ListApiKeys" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -136,10 +171,10 @@ public async Task GetApiKeys_MonitorsListApiKeys() [Test] [Ignore("Only validating compilation of examples")] - public async Task GetDefaultKey_MonitorsGetDefaultKey() + public async Task GetHosts_MonitorsListHosts() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/ApiKeys_GetDefaultKey.json - // this example is just showing the usage of "Monitors_GetDefaultKey" operation, for the dependent resources, they will have to be created separately. + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Hosts_List.json + // this example is just showing the usage of "Monitors_ListHosts" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line TokenCredential cred = new DefaultAzureCredential(); @@ -154,18 +189,21 @@ public async Task GetDefaultKey_MonitorsGetDefaultKey() ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); - // invoke the operation - DatadogApiKey result = await datadogMonitorResource.GetDefaultKeyAsync(); + // invoke the operation and iterate over the result + await foreach (DatadogHost item in datadogMonitorResource.GetHostsAsync()) + { + Console.WriteLine($"Succeeded: {item}"); + } - Console.WriteLine($"Succeeded: {result}"); + Console.WriteLine("Succeeded"); } [Test] [Ignore("Only validating compilation of examples")] - public async Task SetDefaultKey_MonitorsSetDefaultKey() + public async Task GetLinkedResources_MonitorsListLinkedResources() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/ApiKeys_SetDefaultKey.json - // this example is just showing the usage of "Monitors_SetDefaultKey" operation, for the dependent resources, they will have to be created separately. + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/LinkedResources_List.json + // this example is just showing the usage of "Monitors_ListLinkedResources" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line TokenCredential cred = new DefaultAzureCredential(); @@ -180,18 +218,21 @@ public async Task SetDefaultKey_MonitorsSetDefaultKey() ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); - // invoke the operation - await datadogMonitorResource.SetDefaultKeyAsync(); + // invoke the operation and iterate over the result + await foreach (LinkedInfo item in datadogMonitorResource.GetLinkedResourcesAsync()) + { + Console.WriteLine($"Succeeded: {item}"); + } Console.WriteLine("Succeeded"); } [Test] [Ignore("Only validating compilation of examples")] - public async Task GetHosts_MonitorsListHosts() + public async Task GetMonitoredResources_MonitorsListMonitoredResources() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Hosts_List.json - // this example is just showing the usage of "Monitors_ListHosts" operation, for the dependent resources, they will have to be created separately. + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredResources_List.json + // this example is just showing the usage of "Monitors_ListMonitoredResources" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line TokenCredential cred = new DefaultAzureCredential(); @@ -207,7 +248,7 @@ public async Task GetHosts_MonitorsListHosts() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation and iterate over the result - await foreach (DatadogHost item in datadogMonitorResource.GetHostsAsync()) + await foreach (MonitoredResourceContent item in datadogMonitorResource.GetMonitoredResourcesAsync()) { Console.WriteLine($"Succeeded: {item}"); } @@ -217,10 +258,10 @@ public async Task GetHosts_MonitorsListHosts() [Test] [Ignore("Only validating compilation of examples")] - public async Task GetLinkedResources_MonitorsListLinkedResources() + public async Task RefreshSetPasswordLink_MonitorsRefreshSetPasswordLink() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/LinkedResources_List.json - // this example is just showing the usage of "Monitors_ListLinkedResources" operation, for the dependent resources, they will have to be created separately. + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/RefreshSetPassword_Get.json + // this example is just showing the usage of "Monitors_RefreshSetPasswordLink" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line TokenCredential cred = new DefaultAzureCredential(); @@ -235,21 +276,18 @@ public async Task GetLinkedResources_MonitorsListLinkedResources() ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); - // invoke the operation and iterate over the result - await foreach (SubResource item in datadogMonitorResource.GetLinkedResourcesAsync()) - { - Console.WriteLine($"Succeeded: {item}"); - } + // invoke the operation + DatadogSetPasswordLink result = await datadogMonitorResource.RefreshSetPasswordLinkAsync(); - Console.WriteLine("Succeeded"); + Console.WriteLine($"Succeeded: {result}"); } [Test] [Ignore("Only validating compilation of examples")] - public async Task GetMonitoredResources_MonitorsListMonitoredResources() + public async Task SetDefaultKey_MonitorsSetDefaultKey() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/MonitoredResources_List.json - // this example is just showing the usage of "Monitors_ListMonitoredResources" operation, for the dependent resources, they will have to be created separately. + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/ApiKeys_SetDefaultKey.json + // this example is just showing the usage of "Monitors_SetDefaultKey" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line TokenCredential cred = new DefaultAzureCredential(); @@ -264,21 +302,19 @@ public async Task GetMonitoredResources_MonitorsListMonitoredResources() ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); - // invoke the operation and iterate over the result - await foreach (MonitoredResourceContent item in datadogMonitorResource.GetMonitoredResourcesAsync()) - { - Console.WriteLine($"Succeeded: {item}"); - } + // invoke the operation + DatadogApiKey body = new DatadogApiKey("1111111111111111aaaaaaaaaaaaaaaa"); + await datadogMonitorResource.SetDefaultKeyAsync(body: body); Console.WriteLine("Succeeded"); } [Test] [Ignore("Only validating compilation of examples")] - public async Task RefreshSetPasswordLink_MonitorsRefreshSetPasswordLink() + public async Task GetBillingInfo_BillingInfoGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/RefreshSetPassword_Get.json - // this example is just showing the usage of "Monitors_RefreshSetPasswordLink" operation, for the dependent resources, they will have to be created separately. + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/BillingInfo_Get.json + // this example is just showing the usage of "BillingInfo_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line TokenCredential cred = new DefaultAzureCredential(); @@ -294,7 +330,7 @@ public async Task RefreshSetPasswordLink_MonitorsRefreshSetPasswordLink() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogSetPasswordLink result = await datadogMonitorResource.RefreshSetPasswordLinkAsync(); + DatadogBillingInfoResponseResult result = await datadogMonitorResource.GetBillingInfoAsync(); Console.WriteLine($"Succeeded: {result}"); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs index 85dc7891b709..ba7c90fedf2c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs @@ -9,6 +9,7 @@ using System.Threading.Tasks; using Azure.Core; using Azure.Identity; +using Azure.ResourceManager.Datadog.Models; using Azure.ResourceManager.Resources; using NUnit.Framework; @@ -20,7 +21,7 @@ public partial class Sample_DatadogMonitorResourceCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_MonitorsCreate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Create.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Create.json // this example is just showing the usage of "Monitors_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -40,7 +41,33 @@ public async Task CreateOrUpdate_MonitorsCreate() // invoke the operation string monitorName = "myMonitor"; - DatadogMonitorResourceData data = new DatadogMonitorResourceData(default); + DatadogMonitorResourceData data = new DatadogMonitorResourceData(new AzureLocation("West US")) + { + Properties = new MonitorProperties + { + MonitoringStatus = MonitoringStatus.Enabled, + DatadogOrganizationProperties = new DatadogOrganizationProperties + { + Name = "myOrg", + Id = "myOrg123", + LinkingAuthCode = "someAuthCode", + LinkingClientId = "00000000-0000-0000-0000-000000000000", + EnterpriseAppId = "00000000-0000-0000-0000-000000000000", + Cspm = false, + }, + UserInfo = new UserInfo + { + Name = "Alice", + EmailAddress = "alice@microsoft.com", + PhoneNumber = "123-456-7890", + }, + }, + SkuName = "free_Monthly", + Tags = +{ +["Environment"] = "Dev" +}, + }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, monitorName, data); DatadogMonitorResource result = lro.Value; @@ -55,7 +82,7 @@ public async Task CreateOrUpdate_MonitorsCreate() [Ignore("Only validating compilation of examples")] public async Task Get_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -88,7 +115,7 @@ public async Task Get_MonitorsGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_MonitorsListByResourceGroup() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_ListByResourceGroup.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_ListByResourceGroup.json // this example is just showing the usage of "Monitors_ListByResourceGroup" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -123,7 +150,7 @@ public async Task GetAll_MonitorsListByResourceGroup() [Ignore("Only validating compilation of examples")] public async Task Exists_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -152,7 +179,7 @@ public async Task Exists_MonitorsGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs index b5aa9f9d097e..ed17f56c8320 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs @@ -9,6 +9,7 @@ using System.Threading.Tasks; using Azure.Core; using Azure.Identity; +using Azure.ResourceManager.Datadog.Models; using NUnit.Framework; namespace Azure.ResourceManager.Datadog.Samples @@ -19,7 +20,7 @@ public partial class Sample_DatadogSingleSignOnResource [Ignore("Only validating compilation of examples")] public async Task Get_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +51,7 @@ public async Task Get_SingleSignOnConfigurationsGet() [Ignore("Only validating compilation of examples")] public async Task Update_SingleSignOnConfigurationsCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/SingleSignOnConfigurations_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_CreateOrUpdate.json // this example is just showing the usage of "SingleSignOnConfigurations_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -68,7 +69,14 @@ public async Task Update_SingleSignOnConfigurationsCreateOrUpdate() DatadogSingleSignOnResource datadogSingleSignOnResource = client.GetDatadogSingleSignOnResource(datadogSingleSignOnResourceId); // invoke the operation - DatadogSingleSignOnResourceData data = new DatadogSingleSignOnResourceData(); + DatadogSingleSignOnResourceData data = new DatadogSingleSignOnResourceData + { + Properties = new DatadogSingleSignOnProperties + { + SingleSignOnState = SingleSignOnState.Enable, + EnterpriseAppId = "00000000-0000-0000-0000-000000000000", + }, + }; ArmOperation lro = await datadogSingleSignOnResource.UpdateAsync(WaitUntil.Completed, data); DatadogSingleSignOnResource result = lro.Value; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs index fd2ee71a0950..96d6c99615e7 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs @@ -9,6 +9,7 @@ using System.Threading.Tasks; using Azure.Core; using Azure.Identity; +using Azure.ResourceManager.Datadog.Models; using NUnit.Framework; namespace Azure.ResourceManager.Datadog.Samples @@ -19,7 +20,7 @@ public partial class Sample_DatadogSingleSignOnResourceCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_SingleSignOnConfigurationsCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/SingleSignOnConfigurations_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_CreateOrUpdate.json // this example is just showing the usage of "SingleSignOnConfigurations_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -40,7 +41,14 @@ public async Task CreateOrUpdate_SingleSignOnConfigurationsCreateOrUpdate() // invoke the operation string configurationName = "default"; - DatadogSingleSignOnResourceData data = new DatadogSingleSignOnResourceData(); + DatadogSingleSignOnResourceData data = new DatadogSingleSignOnResourceData + { + Properties = new DatadogSingleSignOnProperties + { + SingleSignOnState = SingleSignOnState.Enable, + EnterpriseAppId = "00000000-0000-0000-0000-000000000000", + }, + }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, configurationName, data); DatadogSingleSignOnResource result = lro.Value; @@ -55,7 +63,7 @@ public async Task CreateOrUpdate_SingleSignOnConfigurationsCreateOrUpdate() [Ignore("Only validating compilation of examples")] public async Task Get_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -89,7 +97,7 @@ public async Task Get_SingleSignOnConfigurationsGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_SingleSignOnConfigurationsList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/SingleSignOnConfigurations_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_List.json // this example is just showing the usage of "SingleSignOnConfigurations_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -125,7 +133,7 @@ public async Task GetAll_SingleSignOnConfigurationsList() [Ignore("Only validating compilation of examples")] public async Task Exists_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -155,7 +163,7 @@ public async Task Exists_SingleSignOnConfigurationsGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs new file mode 100644 index 000000000000..cf4e1174aff5 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs @@ -0,0 +1,256 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Identity; +using Azure.ResourceManager.Datadog.Models; +using NUnit.Framework; + +namespace Azure.ResourceManager.Datadog.Samples +{ + public partial class Sample_MonitoredSubscriptionPropertyCollection + { + [Test] + [Ignore("Only validating compilation of examples")] + public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_CreateorUpdate.json + // this example is just showing the usage of "MonitoredSubscriptions_CreateorUpdate" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this DatadogMonitorResource created on azure + // for more information of creating DatadogMonitorResource, please refer to the document of DatadogMonitorResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); + DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); + + // get the collection of this MonitoredSubscriptionPropertyResource + MonitoredSubscriptionPropertyCollection collection = datadogMonitorResource.GetMonitoredSubscriptionProperties(); + + // invoke the operation + string configurationName = "default"; + MonitoredSubscriptionPropertyData data = new MonitoredSubscriptionPropertyData + { + Properties = new SubscriptionList + { + Operation = Models.Operation.AddBegin, + MonitoredSubscriptionList = {new MonitoredSubscription +{ +SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000000", +Status = Status.Active, +TagRules = new MonitoringTagRulesProperties +{ +LogRules = new LogRules +{ +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, +FilteringTags = {new FilteringTag +{ +Name = "Environment", +Value = "Prod", +Action = TagAction.Include, +}, new FilteringTag +{ +Name = "Environment", +Value = "Dev", +Action = TagAction.Exclude, +}}, +}, +MetricRulesFilteringTags = {}, +Automuting = true, +}, +}, new MonitoredSubscription +{ +SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000001", +Status = Status.Failed, +TagRules = new MonitoringTagRulesProperties +{ +LogRules = new LogRules +{ +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, +FilteringTags = {new FilteringTag +{ +Name = "Environment", +Value = "Prod", +Action = TagAction.Include, +}, new FilteringTag +{ +Name = "Environment", +Value = "Dev", +Action = TagAction.Exclude, +}}, +}, +MetricRulesFilteringTags = {}, +Automuting = true, +}, +}}, + }, + }; + ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, configurationName, data); + MonitoredSubscriptionPropertyResource result = lro.Value; + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + MonitoredSubscriptionPropertyData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Get_MonitorsGetMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this DatadogMonitorResource created on azure + // for more information of creating DatadogMonitorResource, please refer to the document of DatadogMonitorResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); + DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); + + // get the collection of this MonitoredSubscriptionPropertyResource + MonitoredSubscriptionPropertyCollection collection = datadogMonitorResource.GetMonitoredSubscriptionProperties(); + + // invoke the operation + string configurationName = "default"; + MonitoredSubscriptionPropertyResource result = await collection.GetAsync(configurationName); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + MonitoredSubscriptionPropertyData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetAll_MonitorsGetMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_List.json + // this example is just showing the usage of "MonitoredSubscriptions_List" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this DatadogMonitorResource created on azure + // for more information of creating DatadogMonitorResource, please refer to the document of DatadogMonitorResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); + DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); + + // get the collection of this MonitoredSubscriptionPropertyResource + MonitoredSubscriptionPropertyCollection collection = datadogMonitorResource.GetMonitoredSubscriptionProperties(); + + // invoke the operation and iterate over the result + await foreach (MonitoredSubscriptionPropertyResource item in collection.GetAllAsync()) + { + // the variable item is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + MonitoredSubscriptionPropertyData resourceData = item.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + Console.WriteLine("Succeeded"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Exists_MonitorsGetMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this DatadogMonitorResource created on azure + // for more information of creating DatadogMonitorResource, please refer to the document of DatadogMonitorResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); + DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); + + // get the collection of this MonitoredSubscriptionPropertyResource + MonitoredSubscriptionPropertyCollection collection = datadogMonitorResource.GetMonitoredSubscriptionProperties(); + + // invoke the operation + string configurationName = "default"; + bool result = await collection.ExistsAsync(configurationName); + + Console.WriteLine($"Succeeded: {result}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetIfExists_MonitorsGetMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this DatadogMonitorResource created on azure + // for more information of creating DatadogMonitorResource, please refer to the document of DatadogMonitorResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); + DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); + + // get the collection of this MonitoredSubscriptionPropertyResource + MonitoredSubscriptionPropertyCollection collection = datadogMonitorResource.GetMonitoredSubscriptionProperties(); + + // invoke the operation + string configurationName = "default"; + NullableResponse response = await collection.GetIfExistsAsync(configurationName); + MonitoredSubscriptionPropertyResource result = response.HasValue ? response.Value : null; + + if (result == null) + { + Console.WriteLine("Succeeded with null as result"); + } + else + { + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + MonitoredSubscriptionPropertyData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs new file mode 100644 index 000000000000..dd6c2ce7d492 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs @@ -0,0 +1,169 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Identity; +using Azure.ResourceManager.Datadog.Models; +using NUnit.Framework; + +namespace Azure.ResourceManager.Datadog.Samples +{ + public partial class Sample_MonitoredSubscriptionPropertyResource + { + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Get_MonitorsGetMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this MonitoredSubscriptionPropertyResource created on azure + // for more information of creating MonitoredSubscriptionPropertyResource, please refer to the document of MonitoredSubscriptionPropertyResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + string configurationName = "default"; + ResourceIdentifier monitoredSubscriptionPropertyResourceId = MonitoredSubscriptionPropertyResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName, configurationName); + MonitoredSubscriptionPropertyResource monitoredSubscriptionProperty = client.GetMonitoredSubscriptionPropertyResource(monitoredSubscriptionPropertyResourceId); + + // invoke the operation + MonitoredSubscriptionPropertyResource result = await monitoredSubscriptionProperty.GetAsync(); + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + MonitoredSubscriptionPropertyData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Delete_MonitorsDeleteMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Delete.json + // this example is just showing the usage of "MonitoredSubscriptions_Delete" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this MonitoredSubscriptionPropertyResource created on azure + // for more information of creating MonitoredSubscriptionPropertyResource, please refer to the document of MonitoredSubscriptionPropertyResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + string configurationName = "default"; + ResourceIdentifier monitoredSubscriptionPropertyResourceId = MonitoredSubscriptionPropertyResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName, configurationName); + MonitoredSubscriptionPropertyResource monitoredSubscriptionProperty = client.GetMonitoredSubscriptionPropertyResource(monitoredSubscriptionPropertyResourceId); + + // invoke the operation + await monitoredSubscriptionProperty.DeleteAsync(WaitUntil.Completed); + + Console.WriteLine("Succeeded"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task Update_MonitorsUpdateMonitoredSubscriptions() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Update.json + // this example is just showing the usage of "MonitoredSubscriptions_Update" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this MonitoredSubscriptionPropertyResource created on azure + // for more information of creating MonitoredSubscriptionPropertyResource, please refer to the document of MonitoredSubscriptionPropertyResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + string configurationName = "default"; + ResourceIdentifier monitoredSubscriptionPropertyResourceId = MonitoredSubscriptionPropertyResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName, configurationName); + MonitoredSubscriptionPropertyResource monitoredSubscriptionProperty = client.GetMonitoredSubscriptionPropertyResource(monitoredSubscriptionPropertyResourceId); + + // invoke the operation + MonitoredSubscriptionPropertyData data = new MonitoredSubscriptionPropertyData + { + Properties = new SubscriptionList + { + Operation = Models.Operation.AddComplete, + MonitoredSubscriptionList = {new MonitoredSubscription +{ +SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000000", +Status = Status.Active, +TagRules = new MonitoringTagRulesProperties +{ +LogRules = new LogRules +{ +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, +FilteringTags = {new FilteringTag +{ +Name = "Environment", +Value = "Prod", +Action = TagAction.Include, +}, new FilteringTag +{ +Name = "Environment", +Value = "Dev", +Action = TagAction.Exclude, +}}, +}, +MetricRulesFilteringTags = {}, +Automuting = true, +}, +}, new MonitoredSubscription +{ +SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000001", +Status = Status.Failed, +TagRules = new MonitoringTagRulesProperties +{ +LogRules = new LogRules +{ +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, +FilteringTags = {new FilteringTag +{ +Name = "Environment", +Value = "Prod", +Action = TagAction.Include, +}, new FilteringTag +{ +Name = "Environment", +Value = "Dev", +Action = TagAction.Exclude, +}}, +}, +MetricRulesFilteringTags = {}, +Automuting = true, +}, +}}, + }, + }; + ArmOperation lro = await monitoredSubscriptionProperty.UpdateAsync(WaitUntil.Completed, data); + MonitoredSubscriptionPropertyResource result = lro.Value; + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + MonitoredSubscriptionPropertyData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs index 88fdab415ea4..5ec9351b316b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs @@ -9,6 +9,7 @@ using System.Threading.Tasks; using Azure.Core; using Azure.Identity; +using Azure.ResourceManager.Datadog.Models; using NUnit.Framework; namespace Azure.ResourceManager.Datadog.Samples @@ -19,7 +20,7 @@ public partial class Sample_MonitoringTagRuleCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_TagRulesCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/TagRules_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_CreateOrUpdate.json // this example is just showing the usage of "TagRules_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -40,7 +41,31 @@ public async Task CreateOrUpdate_TagRulesCreateOrUpdate() // invoke the operation string ruleSetName = "default"; - MonitoringTagRuleData data = new MonitoringTagRuleData(); + MonitoringTagRuleData data = new MonitoringTagRuleData + { + Properties = new MonitoringTagRulesProperties + { + LogRules = new LogRules + { + SendAadLogs = false, + SendSubscriptionLogs = true, + SendResourceLogs = true, + FilteringTags = {new FilteringTag +{ +Name = "Environment", +Value = "Prod", +Action = TagAction.Include, +}, new FilteringTag +{ +Name = "Environment", +Value = "Dev", +Action = TagAction.Exclude, +}}, + }, + MetricRulesFilteringTags = { }, + Automuting = true, + }, + }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, ruleSetName, data); MonitoringTagRuleResource result = lro.Value; @@ -55,7 +80,7 @@ public async Task CreateOrUpdate_TagRulesCreateOrUpdate() [Ignore("Only validating compilation of examples")] public async Task Get_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -89,7 +114,7 @@ public async Task Get_TagRulesGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_TagRulesList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/TagRules_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_List.json // this example is just showing the usage of "TagRules_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -125,7 +150,7 @@ public async Task GetAll_TagRulesList() [Ignore("Only validating compilation of examples")] public async Task Exists_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -155,7 +180,7 @@ public async Task Exists_TagRulesGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs index 4fd2ac3d570f..190bfe929c3b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs @@ -9,6 +9,7 @@ using System.Threading.Tasks; using Azure.Core; using Azure.Identity; +using Azure.ResourceManager.Datadog.Models; using NUnit.Framework; namespace Azure.ResourceManager.Datadog.Samples @@ -19,7 +20,7 @@ public partial class Sample_MonitoringTagRuleResource [Ignore("Only validating compilation of examples")] public async Task Get_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +51,7 @@ public async Task Get_TagRulesGet() [Ignore("Only validating compilation of examples")] public async Task Update_TagRulesCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/TagRules_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_CreateOrUpdate.json // this example is just showing the usage of "TagRules_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -68,7 +69,31 @@ public async Task Update_TagRulesCreateOrUpdate() MonitoringTagRuleResource monitoringTagRule = client.GetMonitoringTagRuleResource(monitoringTagRuleResourceId); // invoke the operation - MonitoringTagRuleData data = new MonitoringTagRuleData(); + MonitoringTagRuleData data = new MonitoringTagRuleData + { + Properties = new MonitoringTagRulesProperties + { + LogRules = new LogRules + { + SendAadLogs = false, + SendSubscriptionLogs = true, + SendResourceLogs = true, + FilteringTags = {new FilteringTag +{ +Name = "Environment", +Value = "Prod", +Action = TagAction.Include, +}, new FilteringTag +{ +Name = "Environment", +Value = "Dev", +Action = TagAction.Exclude, +}}, + }, + MetricRulesFilteringTags = { }, + Automuting = true, + }, + }; ArmOperation lro = await monitoringTagRule.UpdateAsync(WaitUntil.Completed, data); MonitoringTagRuleResource result = lro.Value; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs index 3059f7e202b5..b3cdf8a14c50 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs @@ -21,7 +21,7 @@ public partial class Sample_SubscriptionResourceExtensions [Ignore("Only validating compilation of examples")] public async Task GetMarketplaceAgreements_MarketplaceAgreementsList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/MarketplaceAgreements_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MarketplaceAgreements_List.json // this example is just showing the usage of "MarketplaceAgreements_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -48,7 +48,7 @@ public async Task GetMarketplaceAgreements_MarketplaceAgreementsList() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/MarketplaceAgreements_Create.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MarketplaceAgreements_Create.json // this example is just showing the usage of "MarketplaceAgreements_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -63,7 +63,14 @@ public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreate SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); // invoke the operation - DatadogAgreementResourceProperties result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(); + DatadogAgreementResourceProperties body = new DatadogAgreementResourceProperties + { + Properties = new DatadogAgreementProperties + { + Accepted = true, + }, + }; + DatadogAgreementResourceProperties result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(body: body); Console.WriteLine($"Succeeded: {result}"); } @@ -72,7 +79,7 @@ public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreate [Ignore("Only validating compilation of examples")] public async Task GetDatadogMonitorResources_MonitorsList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2021-03-01/examples/Monitors_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_List.json // this example is just showing the usage of "Monitors_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -98,5 +105,58 @@ public async Task GetDatadogMonitorResources_MonitorsList() Console.WriteLine("Succeeded"); } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetCreationSupporteds_CreationSupportedList() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/CreationSupported_List.json + // this example is just showing the usage of "CreationSupported_List" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this SubscriptionResource created on azure + // for more information of creating SubscriptionResource, please refer to the document of SubscriptionResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + ResourceIdentifier subscriptionResourceId = SubscriptionResource.CreateResourceIdentifier(subscriptionId); + SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); + + // invoke the operation and iterate over the result + string datadogOrganizationId = "00000000-0000-0000-0000"; + await foreach (DatadogCreateResourceSupportedResponseResult item in subscriptionResource.GetCreationSupportedsAsync(datadogOrganizationId)) + { + Console.WriteLine($"Succeeded: {item}"); + } + + Console.WriteLine("Succeeded"); + } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task GetCreationSupported_CreationSupportedGet() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/CreationSupported_Get.json + // this example is just showing the usage of "CreationSupported_Get" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this SubscriptionResource created on azure + // for more information of creating SubscriptionResource, please refer to the document of SubscriptionResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + ResourceIdentifier subscriptionResourceId = SubscriptionResource.CreateResourceIdentifier(subscriptionId); + SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); + + // invoke the operation + string datadogOrganizationId = "00000000-0000-0000-0000"; + DatadogCreateResourceSupportedResponseResult result = await subscriptionResource.GetCreationSupportedAsync(datadogOrganizationId); + + Console.WriteLine($"Succeeded: {result}"); + } } } From 4ad11c4b316c70571525c0b0ea62dc630a332ff5 Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Wed, 17 Sep 2025 10:58:21 +0800 Subject: [PATCH 2/7] rename classes and bool prop --- .../Azure.ResourceManager.Datadog.net8.0.cs | 208 +++++++++--------- ....ResourceManager.Datadog.netstandard2.0.cs | 208 +++++++++--------- .../src/Generated/ArmDatadogModelFactory.cs | 56 ++--- .../src/Generated/DatadogMonitorResource.cs | 32 +-- .../Generated/Extensions/DatadogExtensions.cs | 36 +-- .../MockableDatadogSubscriptionResource.cs | 40 ++-- .../AzureResourceManagerDatadogContext.cs | 26 +-- ...sourceSupportedProperties.Serialization.cs | 4 +- .../CreateResourceSupportedProperties.cs | 8 +- ...ourceSupportedResultList.Serialization.cs} | 44 ++-- ...s => CreateResourceSupportedResultList.cs} | 16 +- ...atadogAgreementProperties.Serialization.cs | 4 +- .../Models/DatadogAgreementProperties.cs | 8 +- ...AgreementResourceContent.Serialization.cs} | 38 ++-- ....cs => DatadogAgreementResourceContent.cs} | 12 +- ...eementResourceListResult.Serialization.cs} | 44 ++-- ... => DatadogAgreementResourceListResult.cs} | 16 +- ... => DatadogApiKeyContent.Serialization.cs} | 38 ++-- ...tadogApiKey.cs => DatadogApiKeyContent.cs} | 16 +- ... DatadogApiKeyListResult.Serialization.cs} | 44 ++-- ...Response.cs => DatadogApiKeyListResult.cs} | 16 +- ...DatadogBillingInfoResult.Serialization.cs} | 38 ++-- ...eResult.cs => DatadogBillingInfoResult.cs} | 10 +- ...eResourceSupportedResult.Serialization.cs} | 38 ++-- ...> DatadogCreateResourceSupportedResult.cs} | 10 +- ...=> DatadogHostListResult.Serialization.cs} | 44 ++-- ...stResponse.cs => DatadogHostListResult.cs} | 14 +- ...onitorResourceListResult.Serialization.cs} | 44 ++-- ...cs => DatadogMonitorResourceListResult.cs} | 14 +- ...dogOrganizationProperties.Serialization.cs | 4 +- .../Models/DatadogOrganizationProperties.cs | 8 +- ...SignOnResourceListResult.Serialization.cs} | 38 ++-- ... DatadogSingleSignOnResourceListResult.cs} | 14 +- ...LinkedResourceListResult.Serialization.cs} | 38 ++-- ...esponse.cs => LinkedResourceListResult.cs} | 14 +- .../Models/LogRules.Serialization.cs | 12 +- .../src/Generated/Models/LogRules.cs | 20 +- .../MarketplaceSaaSInfo.Serialization.cs | 4 +- .../Generated/Models/MarketplaceSaaSInfo.cs | 8 +- .../MonitorUpdateProperties.Serialization.cs | 4 +- .../Models/MonitorUpdateProperties.cs | 8 +- .../MonitoredResourceContent.Serialization.cs | 8 +- .../Models/MonitoredResourceContent.cs | 14 +- ...itoredResourceListResult.Serialization.cs} | 38 ++-- ...onse.cs => MonitoredResourceListResult.cs} | 14 +- .../Models/{Status.cs => MonitoredStatus.cs} | 30 +-- .../MonitoredSubscription.Serialization.cs | 4 +- .../Generated/Models/MonitoredSubscription.cs | 4 +- ...toringTagRulesListResult.Serialization.cs} | 38 ++-- ...nse.cs => MonitoringTagRulesListResult.cs} | 14 +- ...itoringTagRulesProperties.Serialization.cs | 8 +- .../Models/MonitoringTagRulesProperties.cs | 14 +- .../Models/{Operation.cs => OperationData.cs} | 32 +-- .../Models/SubscriptionList.Serialization.cs | 4 +- .../src/Generated/Models/SubscriptionList.cs | 4 +- .../BillingInfoRestOperations.cs | 12 +- .../CreationSupportedRestOperations.cs | 36 +-- .../MarketplaceAgreementsRestOperations.cs | 56 ++--- .../RestOperations/MonitorsRestOperations.cs | 180 +++++++-------- ...ingleSignOnConfigurationsRestOperations.cs | 24 +- .../RestOperations/TagRulesRestOperations.cs | 24 +- .../src/autorest.md | 31 ++- ...Azure.ResourceManager.Datadog.Tests.csproj | 3 + .../Samples/Sample_DatadogMonitorResource.cs | 10 +- ...Sample_DatadogMonitorResourceCollection.cs | 2 +- ...MonitoredSubscriptionPropertyCollection.cs | 22 +- ...e_MonitoredSubscriptionPropertyResource.cs | 22 +- .../Sample_MonitoringTagRuleCollection.cs | 8 +- .../Sample_MonitoringTagRuleResource.cs | 8 +- .../Sample_SubscriptionResourceExtensions.cs | 12 +- 70 files changed, 1001 insertions(+), 973 deletions(-) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{CreateResourceSupportedResponseList.Serialization.cs => CreateResourceSupportedResultList.Serialization.cs} (65%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{CreateResourceSupportedResponseList.cs => CreateResourceSupportedResultList.cs} (80%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogAgreementResourceProperties.Serialization.cs => DatadogAgreementResourceContent.Serialization.cs} (71%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogAgreementResourceProperties.cs => DatadogAgreementResourceContent.cs} (81%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogMonitorResourceListResponse.Serialization.cs => DatadogAgreementResourceListResult.Serialization.cs} (72%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogAgreementResourceListResponse.cs => DatadogAgreementResourceListResult.cs} (81%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogApiKey.Serialization.cs => DatadogApiKeyContent.Serialization.cs} (72%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogApiKey.cs => DatadogApiKeyContent.cs} (86%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogHostListResponse.Serialization.cs => DatadogApiKeyListResult.Serialization.cs} (73%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogApiKeyListResponse.cs => DatadogApiKeyListResult.cs} (84%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogBillingInfoResponseResult.Serialization.cs => DatadogBillingInfoResult.Serialization.cs} (69%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogBillingInfoResponseResult.cs => DatadogBillingInfoResult.cs} (87%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogCreateResourceSupportedResponseResult.Serialization.cs => DatadogCreateResourceSupportedResult.Serialization.cs} (66%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogCreateResourceSupportedResponseResult.cs => DatadogCreateResourceSupportedResult.cs} (84%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogApiKeyListResponse.Serialization.cs => DatadogHostListResult.Serialization.cs} (67%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogHostListResponse.cs => DatadogHostListResult.cs} (86%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogAgreementResourceListResponse.Serialization.cs => DatadogMonitorResourceListResult.Serialization.cs} (64%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogMonitorResourceListResponse.cs => DatadogMonitorResourceListResult.cs} (83%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogSingleSignOnResourceListResponse.Serialization.cs => DatadogSingleSignOnResourceListResult.Serialization.cs} (71%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogSingleSignOnResourceListResponse.cs => DatadogSingleSignOnResourceListResult.cs} (82%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{LinkedResourceListResponse.Serialization.cs => LinkedResourceListResult.Serialization.cs} (70%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{LinkedResourceListResponse.cs => LinkedResourceListResult.cs} (85%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{MonitoredResourceListResponse.Serialization.cs => MonitoredResourceListResult.Serialization.cs} (71%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{MonitoredResourceListResponse.cs => MonitoredResourceListResult.cs} (84%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{Status.cs => MonitoredStatus.cs} (50%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{MonitoringTagRulesListResponse.Serialization.cs => MonitoringTagRulesListResult.Serialization.cs} (70%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{MonitoringTagRulesListResponse.cs => MonitoringTagRulesListResult.cs} (84%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{Operation.cs => OperationData.cs} (55%) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs index 5687f4dcd7a4..2033b9c342a8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs @@ -8,12 +8,12 @@ internal AzureResourceManagerDatadogContext() { } } public static partial class DatadogExtensions { - public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Response GetDatadogMonitorResource(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetDatadogMonitorResourceAsync(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -21,8 +21,8 @@ public static partial class DatadogExtensions public static Azure.Pageable GetDatadogMonitorResources(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetDatadogMonitorResourcesAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } - public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } @@ -38,16 +38,16 @@ protected DatadogMonitorResource() { } public virtual Azure.ResourceManager.ArmOperation Delete(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task DeleteAsync(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetDatadogSingleSignOnResource(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetDatadogSingleSignOnResourceAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResources() { throw null; } - public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetHosts(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -64,8 +64,8 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> RefreshSetPasswordLinkAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response RemoveTag(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> RemoveTagAsync(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKey body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKey body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetTags(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> SetTagsAsync(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } Azure.ResourceManager.Datadog.DatadogMonitorResourceData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -264,26 +264,26 @@ protected MockableDatadogResourceGroupResource() { } public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager.ArmResource { protected MockableDatadogSubscriptionResource() { } - public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } } namespace Azure.ResourceManager.Datadog.Models { public static partial class ArmDatadogModelFactory { - public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? creationSupported = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties DatadogAgreementResourceProperties(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult DatadogBillingInfoResponseResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult DatadogCreateResourceSupportedResponseResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? isCreationSupported = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent DatadogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult DatadogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult DatadogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } @@ -292,18 +292,18 @@ public static partial class ArmDatadogModelFactory public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.LinkedInfo LinkedInfo(string id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? subscribed = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? sendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? sendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? isSubscribed = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? automuting = default(bool?), bool? customMetrics = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity(string id = null, string name = null, System.Uri partnerEntityUri = null) { throw null; } } public partial class CreateResourceSupportedProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal CreateResourceSupportedProperties() { } - public bool? CreationSupported { get { throw null; } } + public bool? IsCreationSupported { 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.Datadog.Models.CreateResourceSupportedProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -315,7 +315,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogAgreementProperties() { } - public bool? Accepted { get { throw null; } set { } } + public bool? IsAccepted { get { throw null; } set { } } public string LicenseTextLink { get { throw null; } set { } } public string Plan { get { throw null; } set { } } public string PrivacyPolicyLink { get { throw null; } set { } } @@ -330,53 +330,53 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogAgreementResourceProperties : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogAgreementResourceProperties() { } + public DatadogAgreementResourceContent() { } public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties 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.Datadog.Models.DatadogAgreementResourceProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent 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.Datadog.Models.DatadogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogApiKey : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogApiKey(string key) { } + public DatadogApiKeyContent(string key) { } public string Created { get { throw null; } set { } } public string CreatedBy { get { throw null; } set { } } public string Key { 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.Datadog.Models.DatadogApiKey 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.Datadog.Models.DatadogApiKey System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent 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.Datadog.Models.DatadogApiKeyContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogBillingInfoResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogBillingInfoResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogBillingInfoResponseResult() { } + internal DatadogBillingInfoResult() { } public Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaasInfo { get { throw null; } } public Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult 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.Datadog.Models.DatadogBillingInfoResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult 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.Datadog.Models.DatadogBillingInfoResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogCreateResourceSupportedResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogCreateResourceSupportedResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogCreateResourceSupportedResponseResult() { } + internal DatadogCreateResourceSupportedResult() { } public Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties Properties { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult 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.Datadog.Models.DatadogCreateResourceSupportedResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult 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.Datadog.Models.DatadogCreateResourceSupportedResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } public partial class DatadogHost : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { @@ -436,9 +436,9 @@ public partial class DatadogOrganizationProperties : System.ClientModel.Primitiv public DatadogOrganizationProperties() { } public string ApiKey { get { throw null; } set { } } public string ApplicationKey { get { throw null; } set { } } - public bool? Cspm { get { throw null; } set { } } public string EnterpriseAppId { get { throw null; } set { } } public string Id { get { throw null; } set { } } + public bool? IsCspm { get { throw null; } set { } } public string LinkingAuthCode { get { throw null; } set { } } public string LinkingClientId { get { throw null; } set { } } public string Name { get { throw null; } set { } } @@ -522,9 +522,9 @@ public partial class LogRules : System.ClientModel.Primitives.IJsonModel FilteringTags { get { throw null; } } - public bool? SendAadLogs { get { throw null; } set { } } - public bool? SendResourceLogs { get { throw null; } set { } } - public bool? SendSubscriptionLogs { get { throw null; } set { } } + public bool? IsSendAadLogs { get { throw null; } set { } } + public bool? IsSendResourceLogs { get { throw null; } set { } } + public bool? IsSendSubscriptionLogs { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.LogRules 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) { } @@ -536,10 +536,10 @@ public partial class MarketplaceSaaSInfo : System.ClientModel.Primitives.IJsonMo { internal MarketplaceSaaSInfo() { } public string BilledAzureSubscriptionId { get { throw null; } } + public bool? IsSubscribed { get { throw null; } } public string MarketplaceName { get { throw null; } } public string MarketplaceStatus { get { throw null; } } public string MarketplaceSubscriptionId { get { throw null; } } - public bool? Subscribed { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo 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) { } @@ -571,10 +571,10 @@ public partial class MonitoredResourceContent : System.ClientModel.Primitives.IJ { internal MonitoredResourceContent() { } public string Id { get { throw null; } } + public bool? IsSendingLogs { get { throw null; } } + public bool? IsSendingMetrics { get { throw null; } } public string ReasonForLogsStatus { get { throw null; } } public string ReasonForMetricsStatus { get { throw null; } } - public bool? SendingLogs { get { throw null; } } - public bool? SendingMetrics { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitoredResourceContent 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) { } @@ -582,11 +582,31 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct MonitoredStatus : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public MonitoredStatus(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Deleting { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Failed { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus InProgress { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.MonitoredStatus other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.MonitoredStatus (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } + public override string ToString() { throw null; } + } public partial class MonitoredSubscription : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoredSubscription() { } public string Error { get { throw null; } set { } } - public Azure.ResourceManager.Datadog.Models.Status? Status { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitoredStatus? Status { get { throw null; } set { } } public string SubscriptionId { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } @@ -617,8 +637,8 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoringTagRulesProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoringTagRulesProperties() { } - public bool? Automuting { get { throw null; } set { } } - public bool? CustomMetrics { get { throw null; } set { } } + public bool? IsAutomuting { get { throw null; } set { } } + public bool? IsCustomMetrics { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.LogRules LogRules { get { throw null; } set { } } public System.Collections.Generic.IList MetricRulesFilteringTags { get { throw null; } } public Azure.ResourceManager.Datadog.Models.ProvisioningState? ProvisioningState { get { throw null; } } @@ -649,7 +669,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitorUpdateProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitorUpdateProperties() { } - public bool? Cspm { get { throw null; } set { } } + public bool? IsCspm { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitoringStatus { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -659,24 +679,24 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct Operation : System.IEquatable + public readonly partial struct OperationData : System.IEquatable { private readonly object _dummy; private readonly int _dummyPrimitive; - public Operation(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.Operation Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation AddBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation AddComplete { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation DeleteBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation DeleteComplete { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.Operation other) { throw null; } + public OperationData(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.OperationData Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData AddBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData AddComplete { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData DeleteBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData DeleteComplete { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.OperationData other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override bool Equals(object obj) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.Operation (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.OperationData (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } public override string ToString() { throw null; } } public partial class PartnerBillingEntity : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel @@ -737,31 +757,11 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.SingleSignOnState left, Azure.ResourceManager.Datadog.Models.SingleSignOnState right) { throw null; } public override string ToString() { throw null; } } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct Status : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public Status(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.Status Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Status Deleting { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Status Failed { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Status InProgress { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.Status other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.Status (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } - public override string ToString() { throw null; } - } public partial class SubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public SubscriptionList() { } public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } - public Azure.ResourceManager.Datadog.Models.Operation? Operation { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.OperationData? Operation { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.SubscriptionList 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) { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs index 5687f4dcd7a4..2033b9c342a8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs @@ -8,12 +8,12 @@ internal AzureResourceManagerDatadogContext() { } } public static partial class DatadogExtensions { - public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Response GetDatadogMonitorResource(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetDatadogMonitorResourceAsync(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -21,8 +21,8 @@ public static partial class DatadogExtensions public static Azure.Pageable GetDatadogMonitorResources(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetDatadogMonitorResourcesAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } - public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } @@ -38,16 +38,16 @@ protected DatadogMonitorResource() { } public virtual Azure.ResourceManager.ArmOperation Delete(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task DeleteAsync(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetDatadogSingleSignOnResource(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetDatadogSingleSignOnResourceAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResources() { throw null; } - public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetHosts(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -64,8 +64,8 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> RefreshSetPasswordLinkAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response RemoveTag(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> RemoveTagAsync(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKey body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKey body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetTags(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> SetTagsAsync(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } Azure.ResourceManager.Datadog.DatadogMonitorResourceData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -264,26 +264,26 @@ protected MockableDatadogResourceGroupResource() { } public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager.ArmResource { protected MockableDatadogSubscriptionResource() { } - public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } } namespace Azure.ResourceManager.Datadog.Models { public static partial class ArmDatadogModelFactory { - public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? creationSupported = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties DatadogAgreementResourceProperties(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult DatadogBillingInfoResponseResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult DatadogCreateResourceSupportedResponseResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? isCreationSupported = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent DatadogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult DatadogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult DatadogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } @@ -292,18 +292,18 @@ public static partial class ArmDatadogModelFactory public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.LinkedInfo LinkedInfo(string id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? subscribed = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? sendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? sendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? isSubscribed = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? automuting = default(bool?), bool? customMetrics = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity(string id = null, string name = null, System.Uri partnerEntityUri = null) { throw null; } } public partial class CreateResourceSupportedProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal CreateResourceSupportedProperties() { } - public bool? CreationSupported { get { throw null; } } + public bool? IsCreationSupported { 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.Datadog.Models.CreateResourceSupportedProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -315,7 +315,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogAgreementProperties() { } - public bool? Accepted { get { throw null; } set { } } + public bool? IsAccepted { get { throw null; } set { } } public string LicenseTextLink { get { throw null; } set { } } public string Plan { get { throw null; } set { } } public string PrivacyPolicyLink { get { throw null; } set { } } @@ -330,53 +330,53 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogAgreementResourceProperties : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogAgreementResourceProperties() { } + public DatadogAgreementResourceContent() { } public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceProperties 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.Datadog.Models.DatadogAgreementResourceProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent 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.Datadog.Models.DatadogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogApiKey : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogApiKey(string key) { } + public DatadogApiKeyContent(string key) { } public string Created { get { throw null; } set { } } public string CreatedBy { get { throw null; } set { } } public string Key { 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.Datadog.Models.DatadogApiKey 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.Datadog.Models.DatadogApiKey System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent 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.Datadog.Models.DatadogApiKeyContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogBillingInfoResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogBillingInfoResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogBillingInfoResponseResult() { } + internal DatadogBillingInfoResult() { } public Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaasInfo { get { throw null; } } public Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResponseResult 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.Datadog.Models.DatadogBillingInfoResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult 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.Datadog.Models.DatadogBillingInfoResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogCreateResourceSupportedResponseResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DatadogCreateResourceSupportedResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogCreateResourceSupportedResponseResult() { } + internal DatadogCreateResourceSupportedResult() { } public Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties Properties { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResponseResult 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.Datadog.Models.DatadogCreateResourceSupportedResponseResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult 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.Datadog.Models.DatadogCreateResourceSupportedResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } public partial class DatadogHost : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { @@ -436,9 +436,9 @@ public partial class DatadogOrganizationProperties : System.ClientModel.Primitiv public DatadogOrganizationProperties() { } public string ApiKey { get { throw null; } set { } } public string ApplicationKey { get { throw null; } set { } } - public bool? Cspm { get { throw null; } set { } } public string EnterpriseAppId { get { throw null; } set { } } public string Id { get { throw null; } set { } } + public bool? IsCspm { get { throw null; } set { } } public string LinkingAuthCode { get { throw null; } set { } } public string LinkingClientId { get { throw null; } set { } } public string Name { get { throw null; } set { } } @@ -522,9 +522,9 @@ public partial class LogRules : System.ClientModel.Primitives.IJsonModel FilteringTags { get { throw null; } } - public bool? SendAadLogs { get { throw null; } set { } } - public bool? SendResourceLogs { get { throw null; } set { } } - public bool? SendSubscriptionLogs { get { throw null; } set { } } + public bool? IsSendAadLogs { get { throw null; } set { } } + public bool? IsSendResourceLogs { get { throw null; } set { } } + public bool? IsSendSubscriptionLogs { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.LogRules 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) { } @@ -536,10 +536,10 @@ public partial class MarketplaceSaaSInfo : System.ClientModel.Primitives.IJsonMo { internal MarketplaceSaaSInfo() { } public string BilledAzureSubscriptionId { get { throw null; } } + public bool? IsSubscribed { get { throw null; } } public string MarketplaceName { get { throw null; } } public string MarketplaceStatus { get { throw null; } } public string MarketplaceSubscriptionId { get { throw null; } } - public bool? Subscribed { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo 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) { } @@ -571,10 +571,10 @@ public partial class MonitoredResourceContent : System.ClientModel.Primitives.IJ { internal MonitoredResourceContent() { } public string Id { get { throw null; } } + public bool? IsSendingLogs { get { throw null; } } + public bool? IsSendingMetrics { get { throw null; } } public string ReasonForLogsStatus { get { throw null; } } public string ReasonForMetricsStatus { get { throw null; } } - public bool? SendingLogs { get { throw null; } } - public bool? SendingMetrics { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitoredResourceContent 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) { } @@ -582,11 +582,31 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct MonitoredStatus : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public MonitoredStatus(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Deleting { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Failed { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.MonitoredStatus InProgress { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.MonitoredStatus other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.MonitoredStatus (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } + public override string ToString() { throw null; } + } public partial class MonitoredSubscription : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoredSubscription() { } public string Error { get { throw null; } set { } } - public Azure.ResourceManager.Datadog.Models.Status? Status { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.MonitoredStatus? Status { get { throw null; } set { } } public string SubscriptionId { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } @@ -617,8 +637,8 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoringTagRulesProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoringTagRulesProperties() { } - public bool? Automuting { get { throw null; } set { } } - public bool? CustomMetrics { get { throw null; } set { } } + public bool? IsAutomuting { get { throw null; } set { } } + public bool? IsCustomMetrics { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.LogRules LogRules { get { throw null; } set { } } public System.Collections.Generic.IList MetricRulesFilteringTags { get { throw null; } } public Azure.ResourceManager.Datadog.Models.ProvisioningState? ProvisioningState { get { throw null; } } @@ -649,7 +669,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitorUpdateProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitorUpdateProperties() { } - public bool? Cspm { get { throw null; } set { } } + public bool? IsCspm { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitoringStatus { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -659,24 +679,24 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct Operation : System.IEquatable + public readonly partial struct OperationData : System.IEquatable { private readonly object _dummy; private readonly int _dummyPrimitive; - public Operation(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.Operation Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation AddBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation AddComplete { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation DeleteBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Operation DeleteComplete { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.Operation other) { throw null; } + public OperationData(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.OperationData Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData AddBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData AddComplete { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData DeleteBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.OperationData DeleteComplete { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.OperationData other) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override bool Equals(object obj) { throw null; } [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.Operation (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.Operation left, Azure.ResourceManager.Datadog.Models.Operation right) { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.OperationData (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } public override string ToString() { throw null; } } public partial class PartnerBillingEntity : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel @@ -737,31 +757,11 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.SingleSignOnState left, Azure.ResourceManager.Datadog.Models.SingleSignOnState right) { throw null; } public override string ToString() { throw null; } } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct Status : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public Status(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.Status Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Status Deleting { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Status Failed { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.Status InProgress { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.Status other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.Status (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.Status left, Azure.ResourceManager.Datadog.Models.Status right) { throw null; } - public override string ToString() { throw null; } - } public partial class SubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public SubscriptionList() { } public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } - public Azure.ResourceManager.Datadog.Models.Operation? Operation { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.OperationData? Operation { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.SubscriptionList 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) { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs index 8500767ffb59..70e6c9eca3d0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs @@ -16,16 +16,16 @@ namespace Azure.ResourceManager.Datadog.Models /// Model factory for models. public static partial class ArmDatadogModelFactory { - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. /// Represents the properties of the resource. - /// A new instance for mocking. - public static DatadogAgreementResourceProperties DatadogAgreementResourceProperties(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogAgreementProperties properties = null) + /// A new instance for mocking. + public static DatadogAgreementResourceContent DatadogAgreementResourceContent(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogAgreementProperties properties = null) { - return new DatadogAgreementResourceProperties( + return new DatadogAgreementResourceContent( id, name, resourceType, @@ -84,30 +84,30 @@ public static MonitorProperties MonitorProperties(ProvisioningState? provisionin serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Represents the properties of the resource. - /// A new instance for mocking. - public static DatadogCreateResourceSupportedResponseResult DatadogCreateResourceSupportedResponseResult(CreateResourceSupportedProperties properties = null) + /// A new instance for mocking. + public static DatadogCreateResourceSupportedResult DatadogCreateResourceSupportedResult(CreateResourceSupportedProperties properties = null) { - return new DatadogCreateResourceSupportedResponseResult(properties, serializedAdditionalRawData: null); + return new DatadogCreateResourceSupportedResult(properties, serializedAdditionalRawData: null); } /// Initializes a new instance of . /// The ARM id of the subscription. - /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. + /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. /// A new instance for mocking. - public static CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? creationSupported = null) + public static CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? isCreationSupported = null) { - return new CreateResourceSupportedProperties(name, creationSupported, serializedAdditionalRawData: null); + return new CreateResourceSupportedProperties(name, isCreationSupported, serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Marketplace Subscription details. /// Partner Billing Entity details: Organization Info. - /// A new instance for mocking. - public static DatadogBillingInfoResponseResult DatadogBillingInfoResponseResult(MarketplaceSaaSInfo marketplaceSaasInfo = null, PartnerBillingEntity partnerBillingEntity = null) + /// A new instance for mocking. + public static DatadogBillingInfoResult DatadogBillingInfoResult(MarketplaceSaaSInfo marketplaceSaasInfo = null, PartnerBillingEntity partnerBillingEntity = null) { - return new DatadogBillingInfoResponseResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData: null); + return new DatadogBillingInfoResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData: null); } /// Initializes a new instance of . @@ -115,16 +115,16 @@ public static DatadogBillingInfoResponseResult DatadogBillingInfoResponseResult( /// Marketplace Subscription Details: SAAS Name. /// Marketplace Subscription Details: SaaS Subscription Status. /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. - /// Flag specifying if the Marketplace status is subscribed or not. + /// Flag specifying if the Marketplace status is subscribed or not. /// A new instance for mocking. - public static MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? subscribed = null) + public static MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? isSubscribed = null) { return new MarketplaceSaaSInfo( marketplaceSubscriptionId, marketplaceName, marketplaceStatus, billedAzureSubscriptionId, - subscribed, + isSubscribed, serializedAdditionalRawData: null); } @@ -183,18 +183,18 @@ public static LinkedInfo LinkedInfo(string id = null, AzureLocation? location = /// Initializes a new instance of . /// The ARM id of the resource. - /// Flag indicating if resource is sending metrics to Datadog. + /// Flag indicating if resource is sending metrics to Datadog. /// Reason for why the resource is sending metrics (or why it is not sending). - /// Flag indicating if resource is sending logs to Datadog. + /// Flag indicating if resource is sending logs to Datadog. /// Reason for why the resource is sending logs (or why it is not sending). /// A new instance for mocking. - public static MonitoredResourceContent MonitoredResourceContent(string id = null, bool? sendingMetrics = null, string reasonForMetricsStatus = null, bool? sendingLogs = null, string reasonForLogsStatus = null) + public static MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = null, string reasonForMetricsStatus = null, bool? isSendingLogs = null, string reasonForLogsStatus = null) { return new MonitoredResourceContent( id, - sendingMetrics, + isSendingMetrics, reasonForMetricsStatus, - sendingLogs, + isSendingLogs, reasonForLogsStatus, serializedAdditionalRawData: null); } @@ -221,10 +221,10 @@ public static MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyDat /// /// Set of rules for sending logs for the Monitor resource. /// Set of rules for sending metrics for the Monitor resource. - /// Configuration to enable/disable auto-muting flag. - /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. + /// Configuration to enable/disable auto-muting flag. + /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. /// A new instance for mocking. - public static MonitoringTagRulesProperties MonitoringTagRulesProperties(ProvisioningState? provisioningState = null, LogRules logRules = null, IEnumerable metricRulesFilteringTags = null, bool? automuting = null, bool? customMetrics = null) + public static MonitoringTagRulesProperties MonitoringTagRulesProperties(ProvisioningState? provisioningState = null, LogRules logRules = null, IEnumerable metricRulesFilteringTags = null, bool? isAutomuting = null, bool? isCustomMetrics = null) { metricRulesFilteringTags ??= new List(); @@ -232,8 +232,8 @@ public static MonitoringTagRulesProperties MonitoringTagRulesProperties(Provisio provisioningState, logRules, metricRulesFilteringTags != null ? new MetricRules(metricRulesFilteringTags?.ToList(), serializedAdditionalRawData: null) : null, - automuting, - customMetrics, + isAutomuting, + isCustomMetrics, serializedAdditionalRawData: null); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs index 45cf0677f887..d52d1367ccbc 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs @@ -580,7 +580,7 @@ public virtual ArmOperation Update(WaitUntil waitUntil, /// /// /// The cancellation token to use. - public virtual async Task> GetDefaultKeyAsync(CancellationToken cancellationToken = default) + public virtual async Task> GetDefaultKeyAsync(CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.GetDefaultKey"); scope.Start(); @@ -618,7 +618,7 @@ public virtual async Task> GetDefaultKeyAsync(Cancellati /// /// /// The cancellation token to use. - public virtual Response GetDefaultKey(CancellationToken cancellationToken = default) + public virtual Response GetDefaultKey(CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.GetDefaultKey"); scope.Start(); @@ -656,12 +656,12 @@ public virtual Response GetDefaultKey(CancellationToken cancellat /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetApiKeysAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetApiKeysAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogApiKey.DeserializeDatadogApiKey(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogApiKeyContent.DeserializeDatadogApiKeyContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); } /// @@ -686,12 +686,12 @@ public virtual AsyncPageable GetApiKeysAsync(CancellationToken ca /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetApiKeys(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetApiKeys(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogApiKey.DeserializeDatadogApiKey(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogApiKeyContent.DeserializeDatadogApiKeyContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); } /// @@ -971,15 +971,15 @@ public virtual Response RefreshSetPasswordLink(Cancellat /// /// /// - /// The to use. + /// The to use. /// The cancellation token to use. - public virtual async Task SetDefaultKeyAsync(DatadogApiKey body = null, CancellationToken cancellationToken = default) + public virtual async Task SetDefaultKeyAsync(DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); scope.Start(); try { - var response = await _datadogMonitorResourceMonitorsRestClient.SetDefaultKeyAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken).ConfigureAwait(false); + var response = await _datadogMonitorResourceMonitorsRestClient.SetDefaultKeyAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, content, cancellationToken).ConfigureAwait(false); return response; } catch (Exception e) @@ -1010,15 +1010,15 @@ public virtual async Task SetDefaultKeyAsync(DatadogApiKey body = null /// /// /// - /// The to use. + /// The to use. /// The cancellation token to use. - public virtual Response SetDefaultKey(DatadogApiKey body = null, CancellationToken cancellationToken = default) + public virtual Response SetDefaultKey(DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); scope.Start(); try { - var response = _datadogMonitorResourceMonitorsRestClient.SetDefaultKey(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken); + var response = _datadogMonitorResourceMonitorsRestClient.SetDefaultKey(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, content, cancellationToken); return response; } catch (Exception e) @@ -1046,7 +1046,7 @@ public virtual Response SetDefaultKey(DatadogApiKey body = null, CancellationTok /// /// /// The cancellation token to use. - public virtual async Task> GetBillingInfoAsync(CancellationToken cancellationToken = default) + public virtual async Task> GetBillingInfoAsync(CancellationToken cancellationToken = default) { using var scope = _billingInfoClientDiagnostics.CreateScope("DatadogMonitorResource.GetBillingInfo"); scope.Start(); @@ -1080,7 +1080,7 @@ public virtual async Task> GetBilling /// /// /// The cancellation token to use. - public virtual Response GetBillingInfo(CancellationToken cancellationToken = default) + public virtual Response GetBillingInfo(CancellationToken cancellationToken = default) { using var scope = _billingInfoClientDiagnostics.CreateScope("DatadogMonitorResource.GetBillingInfo"); scope.Start(); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs index a46ff4e67607..59ff1797a28a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs @@ -226,8 +226,8 @@ public static Response GetDatadogMonitorResource(this Re /// The instance the method will execute against. /// The cancellation token to use. /// is null. - /// An async collection of that may take multiple service requests to iterate over. - public static AsyncPageable GetMarketplaceAgreementsAsync(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public static AsyncPageable GetMarketplaceAgreementsAsync(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -258,8 +258,8 @@ public static AsyncPageable GetMarketplaceAg /// The instance the method will execute against. /// The cancellation token to use. /// is null. - /// A collection of that may take multiple service requests to iterate over. - public static Pageable GetMarketplaceAgreements(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public static Pageable GetMarketplaceAgreements(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -284,18 +284,18 @@ public static Pageable GetMarketplaceAgreeme /// /// /// Mocking - /// To mock this method, please mock instead. + /// To mock this method, please mock instead. /// /// /// The instance the method will execute against. - /// The request body. + /// The request body. /// The cancellation token to use. /// is null. - public static async Task> CreateOrUpdateMarketplaceAgreementAsync(this SubscriptionResource subscriptionResource, DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) + public static async Task> CreateOrUpdateMarketplaceAgreementAsync(this SubscriptionResource subscriptionResource, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); - return await GetMockableDatadogSubscriptionResource(subscriptionResource).CreateOrUpdateMarketplaceAgreementAsync(body, cancellationToken).ConfigureAwait(false); + return await GetMockableDatadogSubscriptionResource(subscriptionResource).CreateOrUpdateMarketplaceAgreementAsync(content, cancellationToken).ConfigureAwait(false); } /// @@ -316,18 +316,18 @@ public static async Task> CreateOrU /// /// /// Mocking - /// To mock this method, please mock instead. + /// To mock this method, please mock instead. /// /// /// The instance the method will execute against. - /// The request body. + /// The request body. /// The cancellation token to use. /// is null. - public static Response CreateOrUpdateMarketplaceAgreement(this SubscriptionResource subscriptionResource, DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) + public static Response CreateOrUpdateMarketplaceAgreement(this SubscriptionResource subscriptionResource, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); - return GetMockableDatadogSubscriptionResource(subscriptionResource).CreateOrUpdateMarketplaceAgreement(body, cancellationToken); + return GetMockableDatadogSubscriptionResource(subscriptionResource).CreateOrUpdateMarketplaceAgreement(content, cancellationToken); } /// @@ -427,8 +427,8 @@ public static Pageable GetDatadogMonitorResources(this S /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - /// An async collection of that may take multiple service requests to iterate over. - public static AsyncPageable GetCreationSupportedsAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public static AsyncPageable GetCreationSupportedsAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -460,8 +460,8 @@ public static AsyncPageable GetCre /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - /// A collection of that may take multiple service requests to iterate over. - public static Pageable GetCreationSupporteds(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public static Pageable GetCreationSupporteds(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -493,7 +493,7 @@ public static Pageable GetCreation /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - public static async Task> GetCreationSupportedAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + public static async Task> GetCreationSupportedAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -525,7 +525,7 @@ public static async Task> /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - public static Response GetCreationSupported(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + public static Response GetCreationSupported(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs index d8658f57ec61..7556c637ee74 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs @@ -68,12 +68,12 @@ private string GetApiVersionOrNull(ResourceType resourceType) /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetMarketplaceAgreementsAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetMarketplaceAgreementsAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => MarketplaceAgreementsRestClient.CreateListRequest(Id.SubscriptionId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => MarketplaceAgreementsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogAgreementResourceProperties.DeserializeDatadogAgreementResourceProperties(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); } /// @@ -94,12 +94,12 @@ public virtual AsyncPageable GetMarketplaceA /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetMarketplaceAgreements(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetMarketplaceAgreements(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => MarketplaceAgreementsRestClient.CreateListRequest(Id.SubscriptionId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => MarketplaceAgreementsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogAgreementResourceProperties.DeserializeDatadogAgreementResourceProperties(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); } /// @@ -119,15 +119,15 @@ public virtual Pageable GetMarketplaceAgreem /// /// /// - /// The request body. + /// The request body. /// The cancellation token to use. - public virtual async Task> CreateOrUpdateMarketplaceAgreementAsync(DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) + public virtual async Task> CreateOrUpdateMarketplaceAgreementAsync(DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { using var scope = MarketplaceAgreementsClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.CreateOrUpdateMarketplaceAgreement"); scope.Start(); try { - var response = await MarketplaceAgreementsRestClient.CreateOrUpdateAsync(Id.SubscriptionId, body, cancellationToken).ConfigureAwait(false); + var response = await MarketplaceAgreementsRestClient.CreateOrUpdateAsync(Id.SubscriptionId, content, cancellationToken).ConfigureAwait(false); return response; } catch (Exception e) @@ -154,15 +154,15 @@ public virtual async Task> CreateOr /// /// /// - /// The request body. + /// The request body. /// The cancellation token to use. - public virtual Response CreateOrUpdateMarketplaceAgreement(DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) + public virtual Response CreateOrUpdateMarketplaceAgreement(DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { using var scope = MarketplaceAgreementsClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.CreateOrUpdateMarketplaceAgreement"); scope.Start(); try { - var response = MarketplaceAgreementsRestClient.CreateOrUpdate(Id.SubscriptionId, body, cancellationToken); + var response = MarketplaceAgreementsRestClient.CreateOrUpdate(Id.SubscriptionId, content, cancellationToken); return response; } catch (Exception e) @@ -252,14 +252,14 @@ public virtual Pageable GetDatadogMonitorResources(Cance /// Datadog Organization Id. /// The cancellation token to use. /// is null. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); HttpMessage FirstPageRequest(int? pageSizeHint) => CreationSupportedRestClient.CreateListRequest(Id.SubscriptionId, datadogOrganizationId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreationSupportedRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, datadogOrganizationId); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); } /// @@ -282,14 +282,14 @@ public virtual AsyncPageable GetCr /// Datadog Organization Id. /// The cancellation token to use. /// is null. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetCreationSupporteds(string datadogOrganizationId, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetCreationSupporteds(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); HttpMessage FirstPageRequest(int? pageSizeHint) => CreationSupportedRestClient.CreateListRequest(Id.SubscriptionId, datadogOrganizationId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreationSupportedRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, datadogOrganizationId); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); } /// @@ -312,7 +312,7 @@ public virtual Pageable GetCreatio /// Datadog Organization Id. /// The cancellation token to use. /// is null. - public virtual async Task> GetCreationSupportedAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) + public virtual async Task> GetCreationSupportedAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -350,7 +350,7 @@ public virtual async Task /// Datadog Organization Id. /// The cancellation token to use. /// is null. - public virtual Response GetCreationSupported(string datadogOrganizationId, CancellationToken cancellationToken = default) + public virtual Response GetCreationSupported(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs index d59ed830f6ae..266ce61d103b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs @@ -16,45 +16,45 @@ namespace Azure.ResourceManager.Datadog /// For more information see 'https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/System.ClientModel/src/docs/ModelReaderWriterContext.md' /// [ModelReaderWriterBuildable(typeof(CreateResourceSupportedProperties))] - [ModelReaderWriterBuildable(typeof(CreateResourceSupportedResponseList))] + [ModelReaderWriterBuildable(typeof(CreateResourceSupportedResultList))] [ModelReaderWriterBuildable(typeof(DatadogAgreementProperties))] - [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceListResponse))] - [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceProperties))] - [ModelReaderWriterBuildable(typeof(DatadogApiKey))] - [ModelReaderWriterBuildable(typeof(DatadogApiKeyListResponse))] - [ModelReaderWriterBuildable(typeof(DatadogBillingInfoResponseResult))] - [ModelReaderWriterBuildable(typeof(DatadogCreateResourceSupportedResponseResult))] + [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceContent))] + [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceListResult))] + [ModelReaderWriterBuildable(typeof(DatadogApiKeyContent))] + [ModelReaderWriterBuildable(typeof(DatadogApiKeyListResult))] + [ModelReaderWriterBuildable(typeof(DatadogBillingInfoResult))] + [ModelReaderWriterBuildable(typeof(DatadogCreateResourceSupportedResult))] [ModelReaderWriterBuildable(typeof(DatadogHost))] - [ModelReaderWriterBuildable(typeof(DatadogHostListResponse))] + [ModelReaderWriterBuildable(typeof(DatadogHostListResult))] [ModelReaderWriterBuildable(typeof(DatadogHostMetadata))] [ModelReaderWriterBuildable(typeof(DatadogInstallMethod))] [ModelReaderWriterBuildable(typeof(DatadogLogsAgent))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResource))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResourceData))] - [ModelReaderWriterBuildable(typeof(DatadogMonitorResourceListResponse))] + [ModelReaderWriterBuildable(typeof(DatadogMonitorResourceListResult))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResourcePatch))] [ModelReaderWriterBuildable(typeof(DatadogOrganizationProperties))] [ModelReaderWriterBuildable(typeof(DatadogSetPasswordLink))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnProperties))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResource))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResourceData))] - [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResourceListResponse))] + [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResourceListResult))] [ModelReaderWriterBuildable(typeof(FilteringTag))] [ModelReaderWriterBuildable(typeof(LinkedInfo))] - [ModelReaderWriterBuildable(typeof(LinkedResourceListResponse))] + [ModelReaderWriterBuildable(typeof(LinkedResourceListResult))] [ModelReaderWriterBuildable(typeof(LogRules))] [ModelReaderWriterBuildable(typeof(ManagedServiceIdentity))] [ModelReaderWriterBuildable(typeof(MarketplaceSaaSInfo))] [ModelReaderWriterBuildable(typeof(MetricRules))] [ModelReaderWriterBuildable(typeof(MonitoredResourceContent))] - [ModelReaderWriterBuildable(typeof(MonitoredResourceListResponse))] + [ModelReaderWriterBuildable(typeof(MonitoredResourceListResult))] [ModelReaderWriterBuildable(typeof(MonitoredSubscription))] [ModelReaderWriterBuildable(typeof(MonitoredSubscriptionPropertiesList))] [ModelReaderWriterBuildable(typeof(MonitoredSubscriptionPropertyData))] [ModelReaderWriterBuildable(typeof(MonitoredSubscriptionPropertyResource))] [ModelReaderWriterBuildable(typeof(MonitoringTagRuleData))] [ModelReaderWriterBuildable(typeof(MonitoringTagRuleResource))] - [ModelReaderWriterBuildable(typeof(MonitoringTagRulesListResponse))] + [ModelReaderWriterBuildable(typeof(MonitoringTagRulesListResult))] [ModelReaderWriterBuildable(typeof(MonitoringTagRulesProperties))] [ModelReaderWriterBuildable(typeof(MonitorProperties))] [ModelReaderWriterBuildable(typeof(MonitorUpdateProperties))] diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs index 3624fd9665b5..09539abb2221 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.Serialization.cs @@ -39,10 +39,10 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("name"u8); writer.WriteStringValue(Name); } - if (options.Format != "W" && Optional.IsDefined(CreationSupported)) + if (options.Format != "W" && Optional.IsDefined(IsCreationSupported)) { writer.WritePropertyName("creationSupported"u8); - writer.WriteBooleanValue(CreationSupported.Value); + writer.WriteBooleanValue(IsCreationSupported.Value); } if (options.Format != "W" && _serializedAdditionalRawData != null) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs index 5fa80014a575..281b35760e89 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedProperties.cs @@ -52,18 +52,18 @@ internal CreateResourceSupportedProperties() /// Initializes a new instance of . /// The ARM id of the subscription. - /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. + /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. /// Keeps track of any properties unknown to the library. - internal CreateResourceSupportedProperties(string name, bool? creationSupported, IDictionary serializedAdditionalRawData) + internal CreateResourceSupportedProperties(string name, bool? isCreationSupported, IDictionary serializedAdditionalRawData) { Name = name; - CreationSupported = creationSupported; + IsCreationSupported = isCreationSupported; _serializedAdditionalRawData = serializedAdditionalRawData; } /// The ARM id of the subscription. public string Name { get; } /// Indicates if selected subscription supports Datadog resource creation, if not it is already being monitored for the selected organization via multi subscription feature. - public bool? CreationSupported { get; } + public bool? IsCreationSupported { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.Serialization.cs similarity index 65% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.Serialization.cs index d6e2bd63ae5b..7dc86e56f785 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class CreateResourceSupportedResponseList : IUtf8JsonSerializable, IJsonModel + internal partial class CreateResourceSupportedResultList : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(CreateResourceSupportedResultList)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - CreateResourceSupportedResponseList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + CreateResourceSupportedResultList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(CreateResourceSupportedResultList)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeCreateResourceSupportedResponseList(document.RootElement, options); + return DeserializeCreateResourceSupportedResultList(document.RootElement, options); } - internal static CreateResourceSupportedResponseList DeserializeCreateResourceSupportedResponseList(JsonElement element, ModelReaderWriterOptions options = null) + internal static CreateResourceSupportedResultList DeserializeCreateResourceSupportedResultList(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -83,7 +83,7 @@ internal static CreateResourceSupportedResponseList DeserializeCreateResourceSup { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static CreateResourceSupportedResponseList DeserializeCreateResourceSup { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(item, options)); + array.Add(DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(item, options)); } value = array; continue; @@ -114,38 +114,38 @@ internal static CreateResourceSupportedResponseList DeserializeCreateResourceSup } } serializedAdditionalRawData = rawDataDictionary; - return new CreateResourceSupportedResponseList(value, nextLink, serializedAdditionalRawData); + return new CreateResourceSupportedResultList(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(CreateResourceSupportedResultList)} does not support writing '{options.Format}' format."); } } - CreateResourceSupportedResponseList IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + CreateResourceSupportedResultList IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeCreateResourceSupportedResponseList(document.RootElement, options); + return DeserializeCreateResourceSupportedResultList(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(CreateResourceSupportedResponseList)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(CreateResourceSupportedResultList)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.cs similarity index 80% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.cs index b73c2107a43e..a5367a819dd8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResponseList.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Paged collection of CreateResourceSupportedResponse items. - internal partial class CreateResourceSupportedResponseList + internal partial class CreateResourceSupportedResultList { /// /// Keeps track of any properties unknown to the library. @@ -46,34 +46,34 @@ internal partial class CreateResourceSupportedResponseList /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The CreateResourceSupportedResponse items on this page. /// is null. - internal CreateResourceSupportedResponseList(IEnumerable value) + internal CreateResourceSupportedResultList(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The CreateResourceSupportedResponse items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal CreateResourceSupportedResponseList(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal CreateResourceSupportedResultList(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal CreateResourceSupportedResponseList() + /// Initializes a new instance of for deserialization. + internal CreateResourceSupportedResultList() { } /// The CreateResourceSupportedResponse items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.Serialization.cs index d74d60914bd3..cb69c7699065 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.Serialization.cs @@ -69,10 +69,10 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("signature"u8); writer.WriteStringValue(Signature); } - if (Optional.IsDefined(Accepted)) + if (Optional.IsDefined(IsAccepted)) { writer.WritePropertyName("accepted"u8); - writer.WriteBooleanValue(Accepted.Value); + writer.WriteBooleanValue(IsAccepted.Value); } if (options.Format != "W" && _serializedAdditionalRawData != null) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.cs index ab9036e044d8..b6ba3aea9fad 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementProperties.cs @@ -58,9 +58,9 @@ public DatadogAgreementProperties() /// Link to the privacy policy of the publisher. /// Date and time in UTC of when the terms were accepted. This is empty if Accepted is false. /// Terms signature. - /// If any version of the terms have been accepted, otherwise false. + /// If any version of the terms have been accepted, otherwise false. /// Keeps track of any properties unknown to the library. - internal DatadogAgreementProperties(string publisher, string product, string plan, string licenseTextLink, string privacyPolicyLink, DateTimeOffset? retrieveDatetime, string signature, bool? accepted, IDictionary serializedAdditionalRawData) + internal DatadogAgreementProperties(string publisher, string product, string plan, string licenseTextLink, string privacyPolicyLink, DateTimeOffset? retrieveDatetime, string signature, bool? isAccepted, IDictionary serializedAdditionalRawData) { Publisher = publisher; Product = product; @@ -69,7 +69,7 @@ internal DatadogAgreementProperties(string publisher, string product, string pla PrivacyPolicyLink = privacyPolicyLink; RetrieveDatetime = retrieveDatetime; Signature = signature; - Accepted = accepted; + IsAccepted = isAccepted; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -88,6 +88,6 @@ internal DatadogAgreementProperties(string publisher, string product, string pla /// Terms signature. public string Signature { get; set; } /// If any version of the terms have been accepted, otherwise false. - public bool? Accepted { get; set; } + public bool? IsAccepted { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs similarity index 71% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceProperties.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs index 4b000dcc1bda..e45be34a2848 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs @@ -15,11 +15,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogAgreementResourceProperties : IUtf8JsonSerializable, IJsonModel + public partial class DatadogAgreementResourceContent : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -30,10 +30,10 @@ void IJsonModel.Write(Utf8JsonWriter 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceProperties)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support writing '{format}' format."); } base.JsonModelWriteCore(writer, options); @@ -44,19 +44,19 @@ protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWri } } - DatadogAgreementResourceProperties IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogAgreementResourceContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceProperties)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogAgreementResourceProperties(document.RootElement, options); + return DeserializeDatadogAgreementResourceContent(document.RootElement, options); } - internal static DatadogAgreementResourceProperties DeserializeDatadogAgreementResourceProperties(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogAgreementResourceContent DeserializeDatadogAgreementResourceContent(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -112,7 +112,7 @@ internal static DatadogAgreementResourceProperties DeserializeDatadogAgreementRe } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogAgreementResourceProperties( + return new DatadogAgreementResourceContent( id, name, type, @@ -121,35 +121,35 @@ internal static DatadogAgreementResourceProperties DeserializeDatadogAgreementRe serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceProperties)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support writing '{options.Format}' format."); } } - DatadogAgreementResourceProperties IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogAgreementResourceContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogAgreementResourceProperties(document.RootElement, options); + return DeserializeDatadogAgreementResourceContent(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceProperties)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs similarity index 81% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceProperties.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs index 7b4c8f9c6843..91cd7f8b0b57 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs @@ -12,8 +12,8 @@ namespace Azure.ResourceManager.Datadog.Models { - /// The DatadogAgreementResourceProperties. - public partial class DatadogAgreementResourceProperties : ResourceData + /// The DatadogAgreementResourceContent. + public partial class DatadogAgreementResourceContent : ResourceData { /// /// Keeps track of any properties unknown to the library. @@ -47,19 +47,19 @@ public partial class DatadogAgreementResourceProperties : ResourceData /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - public DatadogAgreementResourceProperties() + /// Initializes a new instance of . + public DatadogAgreementResourceContent() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. /// Represents the properties of the resource. /// Keeps track of any properties unknown to the library. - internal DatadogAgreementResourceProperties(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DatadogAgreementProperties properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + internal DatadogAgreementResourceContent(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DatadogAgreementProperties properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) { Properties = properties; _serializedAdditionalRawData = serializedAdditionalRawData; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs similarity index 72% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs index 428baf825728..f50ad1ea8bf3 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogMonitorResourceListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class DatadogAgreementResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogMonitorResourceListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogAgreementResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogMonitorResourceListResponse(document.RootElement, options); + return DeserializeDatadogAgreementResourceListResult(document.RootElement, options); } - internal static DatadogMonitorResourceListResponse DeserializeDatadogMonitorResourceListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogAgreementResourceListResult DeserializeDatadogAgreementResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -83,7 +83,7 @@ internal static DatadogMonitorResourceListResponse DeserializeDatadogMonitorReso { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static DatadogMonitorResourceListResponse DeserializeDatadogMonitorReso { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogMonitorResourceData.DeserializeDatadogMonitorResourceData(item, options)); + array.Add(DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(item, options)); } value = array; continue; @@ -114,38 +114,38 @@ internal static DatadogMonitorResourceListResponse DeserializeDatadogMonitorReso } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogMonitorResourceListResponse(value, nextLink, serializedAdditionalRawData); + return new DatadogAgreementResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support writing '{options.Format}' format."); } } - DatadogMonitorResourceListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogAgreementResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogMonitorResourceListResponse(document.RootElement, options); + return DeserializeDatadogAgreementResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs similarity index 81% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs index 3d53e69d2a58..459081e61381 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogAgreementResourceListResponse + internal partial class DatadogAgreementResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,34 +46,34 @@ internal partial class DatadogAgreementResourceListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogAgreementResource items on this page. /// is null. - internal DatadogAgreementResourceListResponse(IEnumerable value) + internal DatadogAgreementResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogAgreementResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogAgreementResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DatadogAgreementResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogAgreementResourceListResponse() + /// Initializes a new instance of for deserialization. + internal DatadogAgreementResourceListResult() { } /// The DatadogAgreementResource items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKey.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.Serialization.cs similarity index 72% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKey.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.Serialization.cs index 098720ce08c6..a0dcd1a33a8f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKey.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogApiKey : IUtf8JsonSerializable, IJsonModel + public partial class DatadogApiKeyContent : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOpt /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKey)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support writing '{format}' format."); } if (Optional.IsDefined(CreatedBy)) @@ -68,19 +68,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogApiKey IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogApiKeyContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKey)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogApiKey(document.RootElement, options); + return DeserializeDatadogApiKeyContent(document.RootElement, options); } - internal static DatadogApiKey DeserializeDatadogApiKey(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogApiKeyContent DeserializeDatadogApiKeyContent(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -122,38 +122,38 @@ internal static DatadogApiKey DeserializeDatadogApiKey(JsonElement element, Mode } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogApiKey(createdBy, name, key, created, serializedAdditionalRawData); + return new DatadogApiKeyContent(createdBy, name, key, created, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogApiKey)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support writing '{options.Format}' format."); } } - DatadogApiKey IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogApiKeyContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogApiKey(document.RootElement, options); + return DeserializeDatadogApiKeyContent(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogApiKey)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKey.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.cs similarity index 86% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKey.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.cs index f20adab7c8db..fa41ee0d2a27 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKey.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.cs @@ -10,8 +10,8 @@ namespace Azure.ResourceManager.Datadog.Models { - /// The DatadogApiKey. - public partial class DatadogApiKey + /// The DatadogApiKeyContent. + public partial class DatadogApiKeyContent { /// /// Keeps track of any properties unknown to the library. @@ -45,23 +45,23 @@ public partial class DatadogApiKey /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The value of the API key. /// is null. - public DatadogApiKey(string key) + public DatadogApiKeyContent(string key) { Argument.AssertNotNull(key, nameof(key)); Key = key; } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The user that created the API key. /// The name of the API key. /// The value of the API key. /// The time of creation of the API key. /// Keeps track of any properties unknown to the library. - internal DatadogApiKey(string createdBy, string name, string key, string created, IDictionary serializedAdditionalRawData) + internal DatadogApiKeyContent(string createdBy, string name, string key, string created, IDictionary serializedAdditionalRawData) { CreatedBy = createdBy; Name = name; @@ -70,8 +70,8 @@ internal DatadogApiKey(string createdBy, string name, string key, string created _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogApiKey() + /// Initializes a new instance of for deserialization. + internal DatadogApiKeyContent() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.Serialization.cs similarity index 73% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.Serialization.cs index c25b978865d0..085718ca4a33 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogHostListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class DatadogApiKeyListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogHostListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogHostListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogApiKeyListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogHostListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogHostListResponse(document.RootElement, options); + return DeserializeDatadogApiKeyListResult(document.RootElement, options); } - internal static DatadogHostListResponse DeserializeDatadogHostListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogApiKeyListResult DeserializeDatadogApiKeyListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -83,7 +83,7 @@ internal static DatadogHostListResponse DeserializeDatadogHostListResponse(JsonE { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static DatadogHostListResponse DeserializeDatadogHostListResponse(JsonE { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogHost.DeserializeDatadogHost(item, options)); + array.Add(DatadogApiKeyContent.DeserializeDatadogApiKeyContent(item, options)); } value = array; continue; @@ -114,38 +114,38 @@ internal static DatadogHostListResponse DeserializeDatadogHostListResponse(JsonE } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogHostListResponse(value, nextLink, serializedAdditionalRawData); + return new DatadogApiKeyListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogHostListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support writing '{options.Format}' format."); } } - DatadogHostListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogApiKeyListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogHostListResponse(document.RootElement, options); + return DeserializeDatadogApiKeyListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogHostListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.cs similarity index 84% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.cs index a066ca0ba094..f47474be78a8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogApiKeyListResponse + internal partial class DatadogApiKeyListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,34 +46,34 @@ internal partial class DatadogApiKeyListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogApiKey items on this page. /// is null. - internal DatadogApiKeyListResponse(IEnumerable value) + internal DatadogApiKeyListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogApiKey items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogApiKeyListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DatadogApiKeyListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogApiKeyListResponse() + /// Initializes a new instance of for deserialization. + internal DatadogApiKeyListResult() { } /// The DatadogApiKey items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.Serialization.cs similarity index 69% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.Serialization.cs index 8295a783168c..42997513f081 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogBillingInfoResponseResult : IUtf8JsonSerializable, IJsonModel + public partial class DatadogBillingInfoResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, M /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support writing '{format}' format."); } if (Optional.IsDefined(MarketplaceSaasInfo)) @@ -61,19 +61,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogBillingInfoResponseResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogBillingInfoResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogBillingInfoResponseResult(document.RootElement, options); + return DeserializeDatadogBillingInfoResult(document.RootElement, options); } - internal static DatadogBillingInfoResponseResult DeserializeDatadogBillingInfoResponseResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogBillingInfoResult DeserializeDatadogBillingInfoResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -111,38 +111,38 @@ internal static DatadogBillingInfoResponseResult DeserializeDatadogBillingInfoRe } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogBillingInfoResponseResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData); + return new DatadogBillingInfoResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support writing '{options.Format}' format."); } } - DatadogBillingInfoResponseResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogBillingInfoResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogBillingInfoResponseResult(document.RootElement, options); + return DeserializeDatadogBillingInfoResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogBillingInfoResponseResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.cs similarity index 87% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.cs index 1ab8053c7796..7cc739146519 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResponseResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.cs @@ -11,7 +11,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Marketplace Subscription and Organization details to which resource gets billed into. - public partial class DatadogBillingInfoResponseResult + public partial class DatadogBillingInfoResult { /// /// Keeps track of any properties unknown to the library. @@ -45,16 +45,16 @@ public partial class DatadogBillingInfoResponseResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - internal DatadogBillingInfoResponseResult() + /// Initializes a new instance of . + internal DatadogBillingInfoResult() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Marketplace Subscription details. /// Partner Billing Entity details: Organization Info. /// Keeps track of any properties unknown to the library. - internal DatadogBillingInfoResponseResult(MarketplaceSaaSInfo marketplaceSaasInfo, PartnerBillingEntity partnerBillingEntity, IDictionary serializedAdditionalRawData) + internal DatadogBillingInfoResult(MarketplaceSaaSInfo marketplaceSaasInfo, PartnerBillingEntity partnerBillingEntity, IDictionary serializedAdditionalRawData) { MarketplaceSaasInfo = marketplaceSaasInfo; PartnerBillingEntity = partnerBillingEntity; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.Serialization.cs similarity index 66% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.Serialization.cs index 9ba570b81a99..98e337511351 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogCreateResourceSupportedResponseResult : IUtf8JsonSerializable, IJsonModel + public partial class DatadogCreateResourceSupportedResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWrit /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support writing '{format}' format."); } if (Optional.IsDefined(Properties)) @@ -56,19 +56,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogCreateResourceSupportedResponseResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogCreateResourceSupportedResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement, options); + return DeserializeDatadogCreateResourceSupportedResult(document.RootElement, options); } - internal static DatadogCreateResourceSupportedResponseResult DeserializeDatadogCreateResourceSupportedResponseResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogCreateResourceSupportedResult DeserializeDatadogCreateResourceSupportedResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -96,38 +96,38 @@ internal static DatadogCreateResourceSupportedResponseResult DeserializeDatadogC } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogCreateResourceSupportedResponseResult(properties, serializedAdditionalRawData); + return new DatadogCreateResourceSupportedResult(properties, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support writing '{options.Format}' format."); } } - DatadogCreateResourceSupportedResponseResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogCreateResourceSupportedResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement, options); + return DeserializeDatadogCreateResourceSupportedResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResponseResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.cs similarity index 84% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.cs index 16dd65443c66..94dc6dc9b911 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResponseResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.cs @@ -11,7 +11,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Datadog resource can be created or not. - public partial class DatadogCreateResourceSupportedResponseResult + public partial class DatadogCreateResourceSupportedResult { /// /// Keeps track of any properties unknown to the library. @@ -45,15 +45,15 @@ public partial class DatadogCreateResourceSupportedResponseResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - internal DatadogCreateResourceSupportedResponseResult() + /// Initializes a new instance of . + internal DatadogCreateResourceSupportedResult() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Represents the properties of the resource. /// Keeps track of any properties unknown to the library. - internal DatadogCreateResourceSupportedResponseResult(CreateResourceSupportedProperties properties, IDictionary serializedAdditionalRawData) + internal DatadogCreateResourceSupportedResult(CreateResourceSupportedProperties properties, IDictionary serializedAdditionalRawData) { Properties = properties; _serializedAdditionalRawData = serializedAdditionalRawData; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.Serialization.cs similarity index 67% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.Serialization.cs index ccd83e8c0a44..9f95c0cf080a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogApiKeyListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class DatadogHostListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRea /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKeyListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogApiKeyListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogHostListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKeyListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogApiKeyListResponse(document.RootElement, options); + return DeserializeDatadogHostListResult(document.RootElement, options); } - internal static DatadogApiKeyListResponse DeserializeDatadogApiKeyListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogHostListResult DeserializeDatadogHostListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -83,7 +83,7 @@ internal static DatadogApiKeyListResponse DeserializeDatadogApiKeyListResponse(J { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static DatadogApiKeyListResponse DeserializeDatadogApiKeyListResponse(J { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogApiKey.DeserializeDatadogApiKey(item, options)); + array.Add(DatadogHost.DeserializeDatadogHost(item, options)); } value = array; continue; @@ -114,38 +114,38 @@ internal static DatadogApiKeyListResponse DeserializeDatadogApiKeyListResponse(J } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogApiKeyListResponse(value, nextLink, serializedAdditionalRawData); + return new DatadogHostListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogApiKeyListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support writing '{options.Format}' format."); } } - DatadogApiKeyListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogHostListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogApiKeyListResponse(document.RootElement, options); + return DeserializeDatadogHostListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogApiKeyListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.cs similarity index 86% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.cs index c4de4766bf59..c74fd8cbb1b0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogHostListResponse + internal partial class DatadogHostListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class DatadogHostListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogHost items on this page. /// is null. - internal DatadogHostListResponse(IEnumerable value) + internal DatadogHostListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogHost items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogHostListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DatadogHostListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogHostListResponse() + /// Initializes a new instance of for deserialization. + internal DatadogHostListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.Serialization.cs similarity index 64% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.Serialization.cs index 0e274c855f6b..51f45385451f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogAgreementResourceListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class DatadogMonitorResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter write /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogAgreementResourceListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogMonitorResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogAgreementResourceListResponse(document.RootElement, options); + return DeserializeDatadogMonitorResourceListResult(document.RootElement, options); } - internal static DatadogAgreementResourceListResponse DeserializeDatadogAgreementResourceListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogMonitorResourceListResult DeserializeDatadogMonitorResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -83,7 +83,7 @@ internal static DatadogAgreementResourceListResponse DeserializeDatadogAgreement { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static DatadogAgreementResourceListResponse DeserializeDatadogAgreement { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogAgreementResourceProperties.DeserializeDatadogAgreementResourceProperties(item, options)); + array.Add(DatadogMonitorResourceData.DeserializeDatadogMonitorResourceData(item, options)); } value = array; continue; @@ -114,38 +114,38 @@ internal static DatadogAgreementResourceListResponse DeserializeDatadogAgreement } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogAgreementResourceListResponse(value, nextLink, serializedAdditionalRawData); + return new DatadogMonitorResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support writing '{options.Format}' format."); } } - DatadogAgreementResourceListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogMonitorResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogAgreementResourceListResponse(document.RootElement, options); + return DeserializeDatadogMonitorResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.cs similarity index 83% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.cs index d25831fca794..44009740740a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogMonitorResourceListResponse + internal partial class DatadogMonitorResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class DatadogMonitorResourceListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogMonitorResource items on this page. /// is null. - internal DatadogMonitorResourceListResponse(IEnumerable value) + internal DatadogMonitorResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogMonitorResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogMonitorResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DatadogMonitorResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogMonitorResourceListResponse() + /// Initializes a new instance of for deserialization. + internal DatadogMonitorResourceListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs index 5bb76d078f56..660400852982 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs @@ -74,10 +74,10 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("enterpriseAppId"u8); writer.WriteStringValue(EnterpriseAppId); } - if (Optional.IsDefined(Cspm)) + if (Optional.IsDefined(IsCspm)) { writer.WritePropertyName("cspm"u8); - writer.WriteBooleanValue(Cspm.Value); + writer.WriteBooleanValue(IsCspm.Value); } if (options.Format != "W" && _serializedAdditionalRawData != null) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs index 61285439da74..45c8c76c2f09 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs @@ -59,9 +59,9 @@ public DatadogOrganizationProperties() /// Api key associated to the Datadog organization. /// Application key associated to the Datadog organization. /// The Id of the Enterprise App used for Single sign on. - /// The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. + /// The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. /// Keeps track of any properties unknown to the library. - internal DatadogOrganizationProperties(string name, string id, string linkingAuthCode, string linkingClientId, Uri redirectUri, string apiKey, string applicationKey, string enterpriseAppId, bool? cspm, IDictionary serializedAdditionalRawData) + internal DatadogOrganizationProperties(string name, string id, string linkingAuthCode, string linkingClientId, Uri redirectUri, string apiKey, string applicationKey, string enterpriseAppId, bool? isCspm, IDictionary serializedAdditionalRawData) { Name = name; Id = id; @@ -71,7 +71,7 @@ internal DatadogOrganizationProperties(string name, string id, string linkingAut ApiKey = apiKey; ApplicationKey = applicationKey; EnterpriseAppId = enterpriseAppId; - Cspm = cspm; + IsCspm = isCspm; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -92,6 +92,6 @@ internal DatadogOrganizationProperties(string name, string id, string linkingAut /// The Id of the Enterprise App used for Single sign on. public string EnterpriseAppId { get; set; } /// The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. - public bool? Cspm { get; set; } + public bool? IsCspm { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.Serialization.cs similarity index 71% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.Serialization.cs index 30d862477b80..a2b943f9ff43 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogSingleSignOnResourceListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class DatadogSingleSignOnResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter wr /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogSingleSignOnResourceListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DatadogSingleSignOnResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogSingleSignOnResourceListResponse(document.RootElement, options); + return DeserializeDatadogSingleSignOnResourceListResult(document.RootElement, options); } - internal static DatadogSingleSignOnResourceListResponse DeserializeDatadogSingleSignOnResourceListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static DatadogSingleSignOnResourceListResult DeserializeDatadogSingleSignOnResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -114,38 +114,38 @@ internal static DatadogSingleSignOnResourceListResponse DeserializeDatadogSingle } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogSingleSignOnResourceListResponse(value, nextLink, serializedAdditionalRawData); + return new DatadogSingleSignOnResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support writing '{options.Format}' format."); } } - DatadogSingleSignOnResourceListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DatadogSingleSignOnResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogSingleSignOnResourceListResponse(document.RootElement, options); + return DeserializeDatadogSingleSignOnResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.cs similarity index 82% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.cs index 4b3954454aa2..4befa014a412 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogSingleSignOnResourceListResponse + internal partial class DatadogSingleSignOnResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class DatadogSingleSignOnResourceListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogSingleSignOnResource items on this page. /// is null. - internal DatadogSingleSignOnResourceListResponse(IEnumerable value) + internal DatadogSingleSignOnResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogSingleSignOnResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogSingleSignOnResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DatadogSingleSignOnResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogSingleSignOnResourceListResponse() + /// Initializes a new instance of for deserialization. + internal DatadogSingleSignOnResourceListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.Serialization.cs similarity index 70% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.Serialization.cs index 52e636abccce..70ce6baca8b6 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class LinkedResourceListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class LinkedResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRe /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(LinkedResourceListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(LinkedResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - LinkedResourceListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + LinkedResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(LinkedResourceListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(LinkedResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeLinkedResourceListResponse(document.RootElement, options); + return DeserializeLinkedResourceListResult(document.RootElement, options); } - internal static LinkedResourceListResponse DeserializeLinkedResourceListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static LinkedResourceListResult DeserializeLinkedResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -114,38 +114,38 @@ internal static LinkedResourceListResponse DeserializeLinkedResourceListResponse } } serializedAdditionalRawData = rawDataDictionary; - return new LinkedResourceListResponse(value, nextLink, serializedAdditionalRawData); + return new LinkedResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(LinkedResourceListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(LinkedResourceListResult)} does not support writing '{options.Format}' format."); } } - LinkedResourceListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + LinkedResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeLinkedResourceListResponse(document.RootElement, options); + return DeserializeLinkedResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(LinkedResourceListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(LinkedResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.cs similarity index 85% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.cs index 79122f3e1a17..7c661f62e51c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class LinkedResourceListResponse + internal partial class LinkedResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class LinkedResourceListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The LinkedResource items on this page. /// is null. - internal LinkedResourceListResponse(IEnumerable value) + internal LinkedResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The LinkedResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal LinkedResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal LinkedResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal LinkedResourceListResponse() + /// Initializes a new instance of for deserialization. + internal LinkedResourceListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs index da30d3c49b31..01be35c95630 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs @@ -34,20 +34,20 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(LogRules)} does not support writing '{format}' format."); } - if (Optional.IsDefined(SendAadLogs)) + if (Optional.IsDefined(IsSendAadLogs)) { writer.WritePropertyName("sendAadLogs"u8); - writer.WriteBooleanValue(SendAadLogs.Value); + writer.WriteBooleanValue(IsSendAadLogs.Value); } - if (Optional.IsDefined(SendSubscriptionLogs)) + if (Optional.IsDefined(IsSendSubscriptionLogs)) { writer.WritePropertyName("sendSubscriptionLogs"u8); - writer.WriteBooleanValue(SendSubscriptionLogs.Value); + writer.WriteBooleanValue(IsSendSubscriptionLogs.Value); } - if (Optional.IsDefined(SendResourceLogs)) + if (Optional.IsDefined(IsSendResourceLogs)) { writer.WritePropertyName("sendResourceLogs"u8); - writer.WriteBooleanValue(SendResourceLogs.Value); + writer.WriteBooleanValue(IsSendResourceLogs.Value); } if (Optional.IsCollectionDefined(FilteringTags)) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs index e1ef9bc516d7..af7182b4e11f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs @@ -52,26 +52,26 @@ public LogRules() } /// Initializes a new instance of . - /// Flag specifying if AAD logs should be sent for the Monitor resource. - /// Flag specifying if Azure subscription logs should be sent for the Monitor resource. - /// Flag specifying if Azure resource logs should be sent for the Monitor resource. + /// Flag specifying if AAD logs should be sent for the Monitor resource. + /// Flag specifying if Azure subscription logs should be sent for the Monitor resource. + /// Flag specifying if Azure resource logs should be sent for the Monitor resource. /// List of filtering tags to be used for capturing logs. This only takes effect if SendResourceLogs flag is enabled. If empty, all resources will be captured. If only Exclude action is specified, the rules will apply to the list of all available resources. If Include actions are specified, the rules will only include resources with the associated tags. /// Keeps track of any properties unknown to the library. - internal LogRules(bool? sendAadLogs, bool? sendSubscriptionLogs, bool? sendResourceLogs, IList filteringTags, IDictionary serializedAdditionalRawData) + internal LogRules(bool? isSendAadLogs, bool? isSendSubscriptionLogs, bool? isSendResourceLogs, IList filteringTags, IDictionary serializedAdditionalRawData) { - SendAadLogs = sendAadLogs; - SendSubscriptionLogs = sendSubscriptionLogs; - SendResourceLogs = sendResourceLogs; + IsSendAadLogs = isSendAadLogs; + IsSendSubscriptionLogs = isSendSubscriptionLogs; + IsSendResourceLogs = isSendResourceLogs; FilteringTags = filteringTags; _serializedAdditionalRawData = serializedAdditionalRawData; } /// Flag specifying if AAD logs should be sent for the Monitor resource. - public bool? SendAadLogs { get; set; } + public bool? IsSendAadLogs { get; set; } /// Flag specifying if Azure subscription logs should be sent for the Monitor resource. - public bool? SendSubscriptionLogs { get; set; } + public bool? IsSendSubscriptionLogs { get; set; } /// Flag specifying if Azure resource logs should be sent for the Monitor resource. - public bool? SendResourceLogs { get; set; } + public bool? IsSendResourceLogs { get; set; } /// List of filtering tags to be used for capturing logs. This only takes effect if SendResourceLogs flag is enabled. If empty, all resources will be captured. If only Exclude action is specified, the rules will apply to the list of all available resources. If Include actions are specified, the rules will only include resources with the associated tags. public IList FilteringTags { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs index 4f7ef417c6ed..194ebea8a868 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs @@ -54,10 +54,10 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("billedAzureSubscriptionId"u8); writer.WriteStringValue(BilledAzureSubscriptionId); } - if (Optional.IsDefined(Subscribed)) + if (Optional.IsDefined(IsSubscribed)) { writer.WritePropertyName("subscribed"u8); - writer.WriteBooleanValue(Subscribed.Value); + writer.WriteBooleanValue(IsSubscribed.Value); } if (options.Format != "W" && _serializedAdditionalRawData != null) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs index ad032f2cafd6..0124b7d6d0ef 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs @@ -55,15 +55,15 @@ internal MarketplaceSaaSInfo() /// Marketplace Subscription Details: SAAS Name. /// Marketplace Subscription Details: SaaS Subscription Status. /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. - /// Flag specifying if the Marketplace status is subscribed or not. + /// Flag specifying if the Marketplace status is subscribed or not. /// Keeps track of any properties unknown to the library. - internal MarketplaceSaaSInfo(string marketplaceSubscriptionId, string marketplaceName, string marketplaceStatus, string billedAzureSubscriptionId, bool? subscribed, IDictionary serializedAdditionalRawData) + internal MarketplaceSaaSInfo(string marketplaceSubscriptionId, string marketplaceName, string marketplaceStatus, string billedAzureSubscriptionId, bool? isSubscribed, IDictionary serializedAdditionalRawData) { MarketplaceSubscriptionId = marketplaceSubscriptionId; MarketplaceName = marketplaceName; MarketplaceStatus = marketplaceStatus; BilledAzureSubscriptionId = billedAzureSubscriptionId; - Subscribed = subscribed; + IsSubscribed = isSubscribed; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -76,6 +76,6 @@ internal MarketplaceSaaSInfo(string marketplaceSubscriptionId, string marketplac /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. public string BilledAzureSubscriptionId { get; } /// Flag specifying if the Marketplace status is subscribed or not. - public bool? Subscribed { get; } + public bool? IsSubscribed { get; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs index 93d2caae4f12..16c26ced7511 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs @@ -39,10 +39,10 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("monitoringStatus"u8); writer.WriteStringValue(MonitoringStatus.Value.ToString()); } - if (Optional.IsDefined(Cspm)) + if (Optional.IsDefined(IsCspm)) { writer.WritePropertyName("cspm"u8); - writer.WriteBooleanValue(Cspm.Value); + writer.WriteBooleanValue(IsCspm.Value); } if (options.Format != "W" && _serializedAdditionalRawData != null) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs index 3a1e4e1a0eee..094e43f40449 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs @@ -52,18 +52,18 @@ public MonitorUpdateProperties() /// Initializes a new instance of . /// Flag specifying if the resource monitoring is enabled or disabled. - /// The new cloud security posture management value of the monitor resource. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. + /// The new cloud security posture management value of the monitor resource. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. /// Keeps track of any properties unknown to the library. - internal MonitorUpdateProperties(MonitoringStatus? monitoringStatus, bool? cspm, IDictionary serializedAdditionalRawData) + internal MonitorUpdateProperties(MonitoringStatus? monitoringStatus, bool? isCspm, IDictionary serializedAdditionalRawData) { MonitoringStatus = monitoringStatus; - Cspm = cspm; + IsCspm = isCspm; _serializedAdditionalRawData = serializedAdditionalRawData; } /// Flag specifying if the resource monitoring is enabled or disabled. public MonitoringStatus? MonitoringStatus { get; set; } /// The new cloud security posture management value of the monitor resource. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. - public bool? Cspm { get; set; } + public bool? IsCspm { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs index 7d6e43bc3e41..5e4a9e1f50a0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs @@ -39,20 +39,20 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("id"u8); writer.WriteStringValue(Id); } - if (Optional.IsDefined(SendingMetrics)) + if (Optional.IsDefined(IsSendingMetrics)) { writer.WritePropertyName("sendingMetrics"u8); - writer.WriteBooleanValue(SendingMetrics.Value); + writer.WriteBooleanValue(IsSendingMetrics.Value); } if (Optional.IsDefined(ReasonForMetricsStatus)) { writer.WritePropertyName("reasonForMetricsStatus"u8); writer.WriteStringValue(ReasonForMetricsStatus); } - if (Optional.IsDefined(SendingLogs)) + if (Optional.IsDefined(IsSendingLogs)) { writer.WritePropertyName("sendingLogs"u8); - writer.WriteBooleanValue(SendingLogs.Value); + writer.WriteBooleanValue(IsSendingLogs.Value); } if (Optional.IsDefined(ReasonForLogsStatus)) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs index 98961166f7d5..64804e299677 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs @@ -52,17 +52,17 @@ internal MonitoredResourceContent() /// Initializes a new instance of . /// The ARM id of the resource. - /// Flag indicating if resource is sending metrics to Datadog. + /// Flag indicating if resource is sending metrics to Datadog. /// Reason for why the resource is sending metrics (or why it is not sending). - /// Flag indicating if resource is sending logs to Datadog. + /// Flag indicating if resource is sending logs to Datadog. /// Reason for why the resource is sending logs (or why it is not sending). /// Keeps track of any properties unknown to the library. - internal MonitoredResourceContent(string id, bool? sendingMetrics, string reasonForMetricsStatus, bool? sendingLogs, string reasonForLogsStatus, IDictionary serializedAdditionalRawData) + internal MonitoredResourceContent(string id, bool? isSendingMetrics, string reasonForMetricsStatus, bool? isSendingLogs, string reasonForLogsStatus, IDictionary serializedAdditionalRawData) { Id = id; - SendingMetrics = sendingMetrics; + IsSendingMetrics = isSendingMetrics; ReasonForMetricsStatus = reasonForMetricsStatus; - SendingLogs = sendingLogs; + IsSendingLogs = isSendingLogs; ReasonForLogsStatus = reasonForLogsStatus; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -70,11 +70,11 @@ internal MonitoredResourceContent(string id, bool? sendingMetrics, string reason /// The ARM id of the resource. public string Id { get; } /// Flag indicating if resource is sending metrics to Datadog. - public bool? SendingMetrics { get; } + public bool? IsSendingMetrics { get; } /// Reason for why the resource is sending metrics (or why it is not sending). public string ReasonForMetricsStatus { get; } /// Flag indicating if resource is sending logs to Datadog. - public bool? SendingLogs { get; } + public bool? IsSendingLogs { get; } /// Reason for why the resource is sending logs (or why it is not sending). public string ReasonForLogsStatus { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.Serialization.cs similarity index 71% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.Serialization.cs index 8665948d0025..2ca3c7e09a42 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class MonitoredResourceListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class MonitoredResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mode /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(MonitoredResourceListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(MonitoredResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - MonitoredResourceListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + MonitoredResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(MonitoredResourceListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(MonitoredResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeMonitoredResourceListResponse(document.RootElement, options); + return DeserializeMonitoredResourceListResult(document.RootElement, options); } - internal static MonitoredResourceListResponse DeserializeMonitoredResourceListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static MonitoredResourceListResult DeserializeMonitoredResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -114,38 +114,38 @@ internal static MonitoredResourceListResponse DeserializeMonitoredResourceListRe } } serializedAdditionalRawData = rawDataDictionary; - return new MonitoredResourceListResponse(value, nextLink, serializedAdditionalRawData); + return new MonitoredResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(MonitoredResourceListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(MonitoredResourceListResult)} does not support writing '{options.Format}' format."); } } - MonitoredResourceListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + MonitoredResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeMonitoredResourceListResponse(document.RootElement, options); + return DeserializeMonitoredResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(MonitoredResourceListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(MonitoredResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.cs similarity index 84% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.cs index 3234615a062a..80fb32f5ff5c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class MonitoredResourceListResponse + internal partial class MonitoredResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class MonitoredResourceListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The MonitoredResource items on this page. /// is null. - internal MonitoredResourceListResponse(IEnumerable value) + internal MonitoredResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The MonitoredResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal MonitoredResourceListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal MonitoredResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal MonitoredResourceListResponse() + /// Initializes a new instance of for deserialization. + internal MonitoredResourceListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Status.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredStatus.cs similarity index 50% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Status.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredStatus.cs index 1c40c67ad38d..0cb6b285161f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Status.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredStatus.cs @@ -11,13 +11,13 @@ namespace Azure.ResourceManager.Datadog.Models { /// The state of monitoring. - public readonly partial struct Status : IEquatable + public readonly partial struct MonitoredStatus : IEquatable { private readonly string _value; - /// Initializes a new instance of . + /// Initializes a new instance of . /// is null. - public Status(string value) + public MonitoredStatus(string value) { _value = value ?? throw new ArgumentNullException(nameof(value)); } @@ -28,25 +28,25 @@ public Status(string value) private const string DeletingValue = "Deleting"; /// InProgress. - public static Status InProgress { get; } = new Status(InProgressValue); + public static MonitoredStatus InProgress { get; } = new MonitoredStatus(InProgressValue); /// Active. - public static Status Active { get; } = new Status(ActiveValue); + public static MonitoredStatus Active { get; } = new MonitoredStatus(ActiveValue); /// Failed. - public static Status Failed { get; } = new Status(FailedValue); + public static MonitoredStatus Failed { get; } = new MonitoredStatus(FailedValue); /// Deleting. - public static Status Deleting { get; } = new Status(DeletingValue); - /// Determines if two values are the same. - public static bool operator ==(Status left, Status right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(Status left, Status right) => !left.Equals(right); - /// Converts a to a . - public static implicit operator Status(string value) => new Status(value); + public static MonitoredStatus Deleting { get; } = new MonitoredStatus(DeletingValue); + /// Determines if two values are the same. + public static bool operator ==(MonitoredStatus left, MonitoredStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(MonitoredStatus left, MonitoredStatus right) => !left.Equals(right); + /// Converts a to a . + public static implicit operator MonitoredStatus(string value) => new MonitoredStatus(value); /// [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is Status other && Equals(other); + public override bool Equals(object obj) => obj is MonitoredStatus other && Equals(other); /// - public bool Equals(Status other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + public bool Equals(MonitoredStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); /// [EditorBrowsable(EditorBrowsableState.Never)] diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs index 86e4ed1b5c8d..ea97d0cc8fb3 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs @@ -92,7 +92,7 @@ internal static MonitoredSubscription DeserializeMonitoredSubscription(JsonEleme return null; } string subscriptionId = default; - Status? status = default; + MonitoredStatus? status = default; string error = default; MonitoringTagRulesProperties tagRules = default; IDictionary serializedAdditionalRawData = default; @@ -110,7 +110,7 @@ internal static MonitoredSubscription DeserializeMonitoredSubscription(JsonEleme { continue; } - status = new Status(property.Value.GetString()); + status = new MonitoredStatus(property.Value.GetString()); continue; } if (property.NameEquals("error"u8)) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs index edb4deb92a0c..682daee3dfd5 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs @@ -56,7 +56,7 @@ public MonitoredSubscription() /// The reason of not monitoring the subscription. /// Definition of the properties for a TagRules resource. /// Keeps track of any properties unknown to the library. - internal MonitoredSubscription(string subscriptionId, Status? status, string error, MonitoringTagRulesProperties tagRules, IDictionary serializedAdditionalRawData) + internal MonitoredSubscription(string subscriptionId, MonitoredStatus? status, string error, MonitoringTagRulesProperties tagRules, IDictionary serializedAdditionalRawData) { SubscriptionId = subscriptionId; Status = status; @@ -68,7 +68,7 @@ internal MonitoredSubscription(string subscriptionId, Status? status, string err /// The subscriptionId to be monitored. public string SubscriptionId { get; set; } /// The state of monitoring. - public Status? Status { get; set; } + public MonitoredStatus? Status { get; set; } /// The reason of not monitoring the subscription. public string Error { get; set; } /// Definition of the properties for a TagRules resource. diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResult.Serialization.cs similarity index 70% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResult.Serialization.cs index 976ac0b92145..c82160b7d8a9 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class MonitoringTagRulesListResponse : IUtf8JsonSerializable, IJsonModel + internal partial class MonitoringTagRulesListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mod /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(MonitoringTagRulesListResponse)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(MonitoringTagRulesListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - MonitoringTagRulesListResponse IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + MonitoringTagRulesListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(MonitoringTagRulesListResponse)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(MonitoringTagRulesListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeMonitoringTagRulesListResponse(document.RootElement, options); + return DeserializeMonitoringTagRulesListResult(document.RootElement, options); } - internal static MonitoringTagRulesListResponse DeserializeMonitoringTagRulesListResponse(JsonElement element, ModelReaderWriterOptions options = null) + internal static MonitoringTagRulesListResult DeserializeMonitoringTagRulesListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -114,38 +114,38 @@ internal static MonitoringTagRulesListResponse DeserializeMonitoringTagRulesList } } serializedAdditionalRawData = rawDataDictionary; - return new MonitoringTagRulesListResponse(value, nextLink, serializedAdditionalRawData); + return new MonitoringTagRulesListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(MonitoringTagRulesListResponse)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(MonitoringTagRulesListResult)} does not support writing '{options.Format}' format."); } } - MonitoringTagRulesListResponse IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + MonitoringTagRulesListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeMonitoringTagRulesListResponse(document.RootElement, options); + return DeserializeMonitoringTagRulesListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(MonitoringTagRulesListResponse)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(MonitoringTagRulesListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResult.cs similarity index 84% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResult.cs index 5f65a587b643..93ac9757f840 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResponse.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class MonitoringTagRulesListResponse + internal partial class MonitoringTagRulesListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class MonitoringTagRulesListResponse /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The MonitoringTagRules items on this page. /// is null. - internal MonitoringTagRulesListResponse(IEnumerable value) + internal MonitoringTagRulesListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The MonitoringTagRules items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal MonitoringTagRulesListResponse(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal MonitoringTagRulesListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal MonitoringTagRulesListResponse() + /// Initializes a new instance of for deserialization. + internal MonitoringTagRulesListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs index 8037a0303faf..1d6a1c34ed92 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs @@ -49,15 +49,15 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("metricRules"u8); writer.WriteObjectValue(MetricRules, options); } - if (Optional.IsDefined(Automuting)) + if (Optional.IsDefined(IsAutomuting)) { writer.WritePropertyName("automuting"u8); - writer.WriteBooleanValue(Automuting.Value); + writer.WriteBooleanValue(IsAutomuting.Value); } - if (Optional.IsDefined(CustomMetrics)) + if (Optional.IsDefined(IsCustomMetrics)) { writer.WritePropertyName("customMetrics"u8); - writer.WriteBooleanValue(CustomMetrics.Value); + writer.WriteBooleanValue(IsCustomMetrics.Value); } if (options.Format != "W" && _serializedAdditionalRawData != null) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs index 48ab31f866fd..06d4d0266041 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs @@ -54,16 +54,16 @@ public MonitoringTagRulesProperties() /// /// Set of rules for sending logs for the Monitor resource. /// Set of rules for sending metrics for the Monitor resource. - /// Configuration to enable/disable auto-muting flag. - /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. + /// Configuration to enable/disable auto-muting flag. + /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. /// Keeps track of any properties unknown to the library. - internal MonitoringTagRulesProperties(ProvisioningState? provisioningState, LogRules logRules, MetricRules metricRules, bool? automuting, bool? customMetrics, IDictionary serializedAdditionalRawData) + internal MonitoringTagRulesProperties(ProvisioningState? provisioningState, LogRules logRules, MetricRules metricRules, bool? isAutomuting, bool? isCustomMetrics, IDictionary serializedAdditionalRawData) { ProvisioningState = provisioningState; LogRules = logRules; MetricRules = metricRules; - Automuting = automuting; - CustomMetrics = customMetrics; + IsAutomuting = isAutomuting; + IsCustomMetrics = isCustomMetrics; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -85,8 +85,8 @@ public IList MetricRulesFilteringTags } /// Configuration to enable/disable auto-muting flag. - public bool? Automuting { get; set; } + public bool? IsAutomuting { get; set; } /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. - public bool? CustomMetrics { get; set; } + public bool? IsCustomMetrics { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Operation.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/OperationData.cs similarity index 55% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Operation.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/OperationData.cs index 641e3d78b9e7..4bcf2449a07f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/Operation.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/OperationData.cs @@ -11,13 +11,13 @@ namespace Azure.ResourceManager.Datadog.Models { /// The operation for the patch on the resource. - public readonly partial struct Operation : IEquatable + public readonly partial struct OperationData : IEquatable { private readonly string _value; - /// Initializes a new instance of . + /// Initializes a new instance of . /// is null. - public Operation(string value) + public OperationData(string value) { _value = value ?? throw new ArgumentNullException(nameof(value)); } @@ -29,27 +29,27 @@ public Operation(string value) private const string ActiveValue = "Active"; /// AddBegin. - public static Operation AddBegin { get; } = new Operation(AddBeginValue); + public static OperationData AddBegin { get; } = new OperationData(AddBeginValue); /// AddComplete. - public static Operation AddComplete { get; } = new Operation(AddCompleteValue); + public static OperationData AddComplete { get; } = new OperationData(AddCompleteValue); /// DeleteBegin. - public static Operation DeleteBegin { get; } = new Operation(DeleteBeginValue); + public static OperationData DeleteBegin { get; } = new OperationData(DeleteBeginValue); /// DeleteComplete. - public static Operation DeleteComplete { get; } = new Operation(DeleteCompleteValue); + public static OperationData DeleteComplete { get; } = new OperationData(DeleteCompleteValue); /// Active. - public static Operation Active { get; } = new Operation(ActiveValue); - /// Determines if two values are the same. - public static bool operator ==(Operation left, Operation right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(Operation left, Operation right) => !left.Equals(right); - /// Converts a to a . - public static implicit operator Operation(string value) => new Operation(value); + public static OperationData Active { get; } = new OperationData(ActiveValue); + /// Determines if two values are the same. + public static bool operator ==(OperationData left, OperationData right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(OperationData left, OperationData right) => !left.Equals(right); + /// Converts a to a . + public static implicit operator OperationData(string value) => new OperationData(value); /// [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is Operation other && Equals(other); + public override bool Equals(object obj) => obj is OperationData other && Equals(other); /// - public bool Equals(Operation other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + public bool Equals(OperationData other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); /// [EditorBrowsable(EditorBrowsableState.Never)] diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs index ddf39f28327a..99495eddb6ae 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs @@ -86,7 +86,7 @@ internal static SubscriptionList DeserializeSubscriptionList(JsonElement element { return null; } - Operation? operation = default; + OperationData? operation = default; IList monitoredSubscriptionList = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -98,7 +98,7 @@ internal static SubscriptionList DeserializeSubscriptionList(JsonElement element { continue; } - operation = new Operation(property.Value.GetString()); + operation = new OperationData(property.Value.GetString()); continue; } if (property.NameEquals("monitoredSubscriptionList"u8)) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs index ffb0687fac96..4327874c3f18 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs @@ -55,7 +55,7 @@ public SubscriptionList() /// The operation for the patch on the resource. /// List of subscriptions and the state of the monitoring. /// Keeps track of any properties unknown to the library. - internal SubscriptionList(Operation? operation, IList monitoredSubscriptionList, IDictionary serializedAdditionalRawData) + internal SubscriptionList(OperationData? operation, IList monitoredSubscriptionList, IDictionary serializedAdditionalRawData) { Operation = operation; MonitoredSubscriptionList = monitoredSubscriptionList; @@ -63,7 +63,7 @@ internal SubscriptionList(Operation? operation, IList mon } /// The operation for the patch on the resource. - public Operation? Operation { get; set; } + public OperationData? Operation { get; set; } /// List of subscriptions and the state of the monitoring. public IList MonitoredSubscriptionList { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs index 0a40224d5fda..93dcb4a4c9e8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs @@ -79,7 +79,7 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGrou /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -91,9 +91,9 @@ public async Task> GetAsync(string su { case 200: { - DatadogBillingInfoResponseResult value = default; + DatadogBillingInfoResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogBillingInfoResponseResult.DeserializeDatadogBillingInfoResponseResult(document.RootElement); + value = DatadogBillingInfoResult.DeserializeDatadogBillingInfoResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -108,7 +108,7 @@ public async Task> GetAsync(string su /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response Get(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response Get(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -120,9 +120,9 @@ public Response Get(string subscriptionId, str { case 200: { - DatadogBillingInfoResponseResult value = default; + DatadogBillingInfoResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogBillingInfoResponseResult.DeserializeDatadogBillingInfoResponseResult(document.RootElement); + value = DatadogBillingInfoResult.DeserializeDatadogBillingInfoResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs index 209ff2da86e5..02bcd9f707b3 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs @@ -72,7 +72,7 @@ internal HttpMessage CreateListRequest(string subscriptionId, string datadogOrga /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -83,9 +83,9 @@ public async Task> ListAsync(strin { case 200: { - CreateResourceSupportedResponseList value = default; + CreateResourceSupportedResultList value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + value = CreateResourceSupportedResultList.DeserializeCreateResourceSupportedResultList(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -99,7 +99,7 @@ public async Task> ListAsync(strin /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -110,9 +110,9 @@ public Response List(string subscriptionId, { case 200: { - CreateResourceSupportedResponseList value = default; + CreateResourceSupportedResultList value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + value = CreateResourceSupportedResultList.DeserializeCreateResourceSupportedResultList(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -156,7 +156,7 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string datadogOrgan /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public async Task> GetAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public async Task> GetAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -167,9 +167,9 @@ public async Task> GetAsy { case 200: { - DatadogCreateResourceSupportedResponseResult value = default; + DatadogCreateResourceSupportedResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement); + value = DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -183,7 +183,7 @@ public async Task> GetAsy /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public Response Get(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public Response Get(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -194,9 +194,9 @@ public Response Get(string subscri { case 200: { - DatadogCreateResourceSupportedResponseResult value = default; + DatadogCreateResourceSupportedResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogCreateResourceSupportedResponseResult.DeserializeDatadogCreateResourceSupportedResponseResult(document.RootElement); + value = DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -233,7 +233,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// , or is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -245,9 +245,9 @@ public async Task> ListNextPageAsy { case 200: { - CreateResourceSupportedResponseList value = default; + CreateResourceSupportedResultList value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + value = CreateResourceSupportedResultList.DeserializeCreateResourceSupportedResultList(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -262,7 +262,7 @@ public async Task> ListNextPageAsy /// The cancellation token to use. /// , or is null. /// is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -274,9 +274,9 @@ public Response ListNextPage(string nextLin { case 200: { - CreateResourceSupportedResponseList value = default; + CreateResourceSupportedResultList value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = CreateResourceSupportedResponseList.DeserializeCreateResourceSupportedResponseList(document.RootElement); + value = CreateResourceSupportedResultList.DeserializeCreateResourceSupportedResultList(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs index 9221aeaa12ca..1b25b178beb4 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs @@ -69,7 +69,7 @@ internal HttpMessage CreateListRequest(string subscriptionId) /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -79,9 +79,9 @@ public async Task> ListAsync(stri { case 200: { - DatadogAgreementResourceListResponse value = default; + DatadogAgreementResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogAgreementResourceListResponse.DeserializeDatadogAgreementResourceListResponse(document.RootElement); + value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -94,7 +94,7 @@ public async Task> ListAsync(stri /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -104,9 +104,9 @@ public Response List(string subscriptionId { case 200: { - DatadogAgreementResourceListResponse value = default; + DatadogAgreementResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogAgreementResourceListResponse.DeserializeDatadogAgreementResourceListResponse(document.RootElement); + value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -114,7 +114,7 @@ public Response List(string subscriptionId } } - internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, DatadogAgreementResourceProperties body) + internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, DatadogAgreementResourceContent content) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -125,7 +125,7 @@ internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, return uri; } - internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DatadogAgreementResourceProperties body) + internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DatadogAgreementResourceContent content) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -138,12 +138,12 @@ internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DatadogA uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); - if (body != null) + if (content != null) { request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(body, ModelSerializationExtensions.WireOptions); - request.Content = content; + var content0 = new Utf8JsonRequestContent(); + content0.JsonWriter.WriteObjectValue(content, ModelSerializationExtensions.WireOptions); + request.Content = content0; } _userAgent.Apply(message); return message; @@ -151,23 +151,23 @@ internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DatadogA /// Create Datadog marketplace agreement in the subscription. /// The ID of the target subscription. - /// The request body. + /// The request body. /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public async Task> CreateOrUpdateAsync(string subscriptionId, DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) + public async Task> CreateOrUpdateAsync(string subscriptionId, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); - using var message = CreateCreateOrUpdateRequest(subscriptionId, body); + using var message = CreateCreateOrUpdateRequest(subscriptionId, content); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { case 200: { - DatadogAgreementResourceProperties value = default; + DatadogAgreementResourceContent value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogAgreementResourceProperties.DeserializeDatadogAgreementResourceProperties(document.RootElement); + value = DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -177,23 +177,23 @@ public async Task> CreateOrUpdateAs /// Create Datadog marketplace agreement in the subscription. /// The ID of the target subscription. - /// The request body. + /// The request body. /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public Response CreateOrUpdate(string subscriptionId, DatadogAgreementResourceProperties body = null, CancellationToken cancellationToken = default) + public Response CreateOrUpdate(string subscriptionId, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); - using var message = CreateCreateOrUpdateRequest(subscriptionId, body); + using var message = CreateCreateOrUpdateRequest(subscriptionId, content); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { case 200: { - DatadogAgreementResourceProperties value = default; + DatadogAgreementResourceContent value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogAgreementResourceProperties.DeserializeDatadogAgreementResourceProperties(document.RootElement); + value = DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -229,7 +229,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -240,9 +240,9 @@ public async Task> ListNextPageAs { case 200: { - DatadogAgreementResourceListResponse value = default; + DatadogAgreementResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogAgreementResourceListResponse.DeserializeDatadogAgreementResourceListResponse(document.RootElement); + value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -256,7 +256,7 @@ public async Task> ListNextPageAs /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -267,9 +267,9 @@ public Response ListNextPage(string nextLi { case 200: { - DatadogAgreementResourceListResponse value = default; + DatadogAgreementResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogAgreementResourceListResponse.DeserializeDatadogAgreementResourceListResponse(document.RootElement); + value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs index 39e08538e15e..14a53038f43b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs @@ -69,7 +69,7 @@ internal HttpMessage CreateListRequest(string subscriptionId) /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -79,9 +79,9 @@ public async Task> ListAsync(string { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -94,7 +94,7 @@ public async Task> ListAsync(string /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -104,9 +104,9 @@ public Response List(string subscriptionId, { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -152,7 +152,7 @@ internal HttpMessage CreateListByResourceGroupRequest(string subscriptionId, str /// The cancellation token to use. /// or is null. /// or is an empty string, and was expected to be non-empty. - public async Task> ListByResourceGroupAsync(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public async Task> ListByResourceGroupAsync(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -163,9 +163,9 @@ public async Task> ListByResourceGr { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -179,7 +179,7 @@ public async Task> ListByResourceGr /// The cancellation token to use. /// or is null. /// or is an empty string, and was expected to be non-empty. - public Response ListByResourceGroup(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public Response ListByResourceGroup(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -190,9 +190,9 @@ public Response ListByResourceGroup(string s { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -609,7 +609,7 @@ internal HttpMessage CreateGetDefaultKeyRequest(string subscriptionId, string re /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> GetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> GetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -621,9 +621,9 @@ public async Task> GetDefaultKeyAsync(string subscriptio { case 200: { - DatadogApiKey value = default; + DatadogApiKeyContent value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKey.DeserializeDatadogApiKey(document.RootElement); + value = DatadogApiKeyContent.DeserializeDatadogApiKeyContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -638,7 +638,7 @@ public async Task> GetDefaultKeyAsync(string subscriptio /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response GetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response GetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -650,9 +650,9 @@ public Response GetDefaultKey(string subscriptionId, string resou { case 200: { - DatadogApiKey value = default; + DatadogApiKeyContent value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKey.DeserializeDatadogApiKey(document.RootElement); + value = DatadogApiKeyContent.DeserializeDatadogApiKeyContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -703,7 +703,7 @@ internal HttpMessage CreateListApiKeysRequest(string subscriptionId, string reso /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListApiKeysAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListApiKeysAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -715,9 +715,9 @@ public async Task> ListApiKeysAsync(string s { case 200: { - DatadogApiKeyListResponse value = default; + DatadogApiKeyListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -732,7 +732,7 @@ public async Task> ListApiKeysAsync(string s /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListApiKeys(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListApiKeys(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -744,9 +744,9 @@ public Response ListApiKeys(string subscriptionId, st { case 200: { - DatadogApiKeyListResponse value = default; + DatadogApiKeyListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -797,7 +797,7 @@ internal HttpMessage CreateListHostsRequest(string subscriptionId, string resour /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListHostsAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListHostsAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -809,9 +809,9 @@ public async Task> ListHostsAsync(string subsc { case 200: { - DatadogHostListResponse value = default; + DatadogHostListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); + value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -826,7 +826,7 @@ public async Task> ListHostsAsync(string subsc /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListHosts(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListHosts(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -838,9 +838,9 @@ public Response ListHosts(string subscriptionId, string { case 200: { - DatadogHostListResponse value = default; + DatadogHostListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); + value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -891,7 +891,7 @@ internal HttpMessage CreateListLinkedResourcesRequest(string subscriptionId, str /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListLinkedResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListLinkedResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -903,9 +903,9 @@ public async Task> ListLinkedResourcesAsync { case 200: { - LinkedResourceListResponse value = default; + LinkedResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + value = LinkedResourceListResult.DeserializeLinkedResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -920,7 +920,7 @@ public async Task> ListLinkedResourcesAsync /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListLinkedResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListLinkedResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -932,9 +932,9 @@ public Response ListLinkedResources(string subscript { case 200: { - LinkedResourceListResponse value = default; + LinkedResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + value = LinkedResourceListResult.DeserializeLinkedResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -985,7 +985,7 @@ internal HttpMessage CreateListMonitoredResourcesRequest(string subscriptionId, /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListMonitoredResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListMonitoredResourcesAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -997,9 +997,9 @@ public async Task> ListMonitoredResource { case 200: { - MonitoredResourceListResponse value = default; + MonitoredResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + value = MonitoredResourceListResult.DeserializeMonitoredResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1014,7 +1014,7 @@ public async Task> ListMonitoredResource /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListMonitoredResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListMonitoredResources(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -1026,9 +1026,9 @@ public Response ListMonitoredResources(string sub { case 200: { - MonitoredResourceListResponse value = default; + MonitoredResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + value = MonitoredResourceListResult.DeserializeMonitoredResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1130,7 +1130,7 @@ public Response RefreshSetPasswordLink(string subscripti } } - internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body) + internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1145,7 +1145,7 @@ internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, return uri; } - internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body) + internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1162,12 +1162,12 @@ internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string re uri.AppendQuery("api-version", _apiVersion, true); request.Uri = uri; request.Headers.Add("Accept", "application/json"); - if (body != null) + if (content != null) { request.Headers.Add("Content-Type", "application/json"); - var content = new Utf8JsonRequestContent(); - content.JsonWriter.WriteObjectValue(body, ModelSerializationExtensions.WireOptions); - request.Content = content; + var content0 = new Utf8JsonRequestContent(); + content0.JsonWriter.WriteObjectValue(content, ModelSerializationExtensions.WireOptions); + request.Content = content0; } _userAgent.Apply(message); return message; @@ -1177,17 +1177,17 @@ internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string re /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. + /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task SetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body = null, CancellationToken cancellationToken = default) + public async Task SetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, body); + using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, content); await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); switch (message.Response.Status) { @@ -1202,17 +1202,17 @@ public async Task SetDefaultKeyAsync(string subscriptionId, string res /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. + /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response SetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKey body = null, CancellationToken cancellationToken = default) + public Response SetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); - using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, body); + using var message = CreateSetDefaultKeyRequest(subscriptionId, resourceGroupName, monitorName, content); _pipeline.Send(message, cancellationToken); switch (message.Response.Status) { @@ -1251,7 +1251,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1262,9 +1262,9 @@ public async Task> ListNextPageAsyn { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1278,7 +1278,7 @@ public async Task> ListNextPageAsyn /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1289,9 +1289,9 @@ public Response ListNextPage(string nextLink { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1328,7 +1328,7 @@ internal HttpMessage CreateListByResourceGroupNextPageRequest(string nextLink, s /// The cancellation token to use. /// , or is null. /// or is an empty string, and was expected to be non-empty. - public async Task> ListByResourceGroupNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public async Task> ListByResourceGroupNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1340,9 +1340,9 @@ public async Task> ListByResourceGr { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1357,7 +1357,7 @@ public async Task> ListByResourceGr /// The cancellation token to use. /// , or is null. /// or is an empty string, and was expected to be non-empty. - public Response ListByResourceGroupNextPage(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public Response ListByResourceGroupNextPage(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1369,9 +1369,9 @@ public Response ListByResourceGroupNextPage( { case 200: { - DatadogMonitorResourceListResponse value = default; + DatadogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResponse.DeserializeDatadogMonitorResourceListResponse(document.RootElement); + value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1409,7 +1409,7 @@ internal HttpMessage CreateListApiKeysNextPageRequest(string nextLink, string su /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListApiKeysNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListApiKeysNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1422,9 +1422,9 @@ public async Task> ListApiKeysNextPageAsync( { case 200: { - DatadogApiKeyListResponse value = default; + DatadogApiKeyListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1440,7 +1440,7 @@ public async Task> ListApiKeysNextPageAsync( /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListApiKeysNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListApiKeysNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1453,9 +1453,9 @@ public Response ListApiKeysNextPage(string nextLink, { case 200: { - DatadogApiKeyListResponse value = default; + DatadogApiKeyListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKeyListResponse.DeserializeDatadogApiKeyListResponse(document.RootElement); + value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1493,7 +1493,7 @@ internal HttpMessage CreateListHostsNextPageRequest(string nextLink, string subs /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListHostsNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListHostsNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1506,9 +1506,9 @@ public async Task> ListHostsNextPageAsync(stri { case 200: { - DatadogHostListResponse value = default; + DatadogHostListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); + value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1524,7 +1524,7 @@ public async Task> ListHostsNextPageAsync(stri /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListHostsNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListHostsNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1537,9 +1537,9 @@ public Response ListHostsNextPage(string nextLink, stri { case 200: { - DatadogHostListResponse value = default; + DatadogHostListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogHostListResponse.DeserializeDatadogHostListResponse(document.RootElement); + value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1577,7 +1577,7 @@ internal HttpMessage CreateListLinkedResourcesNextPageRequest(string nextLink, s /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListLinkedResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListLinkedResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1590,9 +1590,9 @@ public async Task> ListLinkedResourcesNextP { case 200: { - LinkedResourceListResponse value = default; + LinkedResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + value = LinkedResourceListResult.DeserializeLinkedResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1608,7 +1608,7 @@ public async Task> ListLinkedResourcesNextP /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListLinkedResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListLinkedResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1621,9 +1621,9 @@ public Response ListLinkedResourcesNextPage(string n { case 200: { - LinkedResourceListResponse value = default; + LinkedResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = LinkedResourceListResponse.DeserializeLinkedResourceListResponse(document.RootElement); + value = LinkedResourceListResult.DeserializeLinkedResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1661,7 +1661,7 @@ internal HttpMessage CreateListMonitoredResourcesNextPageRequest(string nextLink /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListMonitoredResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListMonitoredResourcesNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1674,9 +1674,9 @@ public async Task> ListMonitoredResource { case 200: { - MonitoredResourceListResponse value = default; + MonitoredResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + value = MonitoredResourceListResult.DeserializeMonitoredResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1692,7 +1692,7 @@ public async Task> ListMonitoredResource /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListMonitoredResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListMonitoredResourcesNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1705,9 +1705,9 @@ public Response ListMonitoredResourcesNextPage(st { case 200: { - MonitoredResourceListResponse value = default; + MonitoredResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = MonitoredResourceListResponse.DeserializeMonitoredResourceListResponse(document.RootElement); + value = MonitoredResourceListResult.DeserializeMonitoredResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs index 0941daae63e1..62baf9fe7e69 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs @@ -79,7 +79,7 @@ internal HttpMessage CreateListRequest(string subscriptionId, string resourceGro /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -91,9 +91,9 @@ public async Task> ListAsync(s { case 200: { - DatadogSingleSignOnResourceListResponse value = default; + DatadogSingleSignOnResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogSingleSignOnResourceListResponse.DeserializeDatadogSingleSignOnResourceListResponse(document.RootElement); + value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -108,7 +108,7 @@ public async Task> ListAsync(s /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -120,9 +120,9 @@ public Response List(string subscriptio { case 200: { - DatadogSingleSignOnResourceListResponse value = default; + DatadogSingleSignOnResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogSingleSignOnResourceListResponse.DeserializeDatadogSingleSignOnResourceListResponse(document.RootElement); + value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -364,7 +364,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -377,9 +377,9 @@ public async Task> ListNextPag { case 200: { - DatadogSingleSignOnResourceListResponse value = default; + DatadogSingleSignOnResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogSingleSignOnResourceListResponse.DeserializeDatadogSingleSignOnResourceListResponse(document.RootElement); + value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -395,7 +395,7 @@ public async Task> ListNextPag /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -408,9 +408,9 @@ public Response ListNextPage(string nex { case 200: { - DatadogSingleSignOnResourceListResponse value = default; + DatadogSingleSignOnResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogSingleSignOnResourceListResponse.DeserializeDatadogSingleSignOnResourceListResponse(document.RootElement); + value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs index 44f40a6e029e..dece9fa4b1ca 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs @@ -79,7 +79,7 @@ internal HttpMessage CreateListRequest(string subscriptionId, string resourceGro /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -91,9 +91,9 @@ public async Task> ListAsync(string sub { case 200: { - MonitoringTagRulesListResponse value = default; + MonitoringTagRulesListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = MonitoringTagRulesListResponse.DeserializeMonitoringTagRulesListResponse(document.RootElement); + value = MonitoringTagRulesListResult.DeserializeMonitoringTagRulesListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -108,7 +108,7 @@ public async Task> ListAsync(string sub /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -120,9 +120,9 @@ public Response List(string subscriptionId, stri { case 200: { - MonitoringTagRulesListResponse value = default; + MonitoringTagRulesListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = MonitoringTagRulesListResponse.DeserializeMonitoringTagRulesListResponse(document.RootElement); + value = MonitoringTagRulesListResult.DeserializeMonitoringTagRulesListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -372,7 +372,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -385,9 +385,9 @@ public async Task> ListNextPageAsync(st { case 200: { - MonitoringTagRulesListResponse value = default; + MonitoringTagRulesListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = MonitoringTagRulesListResponse.DeserializeMonitoringTagRulesListResponse(document.RootElement); + value = MonitoringTagRulesListResult.DeserializeMonitoringTagRulesListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -403,7 +403,7 @@ public async Task> ListNextPageAsync(st /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -416,9 +416,9 @@ public Response ListNextPage(string nextLink, st { case 200: { - MonitoringTagRulesListResponse value = default; + MonitoringTagRulesListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = MonitoringTagRulesListResponse.DeserializeMonitoringTagRulesListResponse(document.RootElement); + value = MonitoringTagRulesListResult.DeserializeMonitoringTagRulesListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md index b3e618eb10f6..ba20d41d6606 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md @@ -51,10 +51,35 @@ acronym-mapping: Etag: ETag|etag rename-mapping: - DatadogAgreementResource: DatadogAgreementResourceProperties + DatadogAgreementResource: DatadogAgreementResourceContent MonitoredResource: MonitoredResourceContent - BillingInfoResponse: DatadogBillingInfoResponseResult - CreateResourceSupportedResponse: DatadogCreateResourceSupportedResponseResult + BillingInfoResponse: DatadogBillingInfoResult + CreateResourceSupportedResponse: DatadogCreateResourceSupportedResult + DatadogMonitorResourceUpdateParameters: DatadogMonitorResourceUpdateContent + DatadogApiKey: DatadogApiKeyContent LinkedResource: LinkedInfo + Status: MonitoredStatus + DatadogAgreementResourceListResponse: DatadogAgreementResourceListResult + DatadogApiKeyListResponse: DatadogApiKeyListResult + DatadogHostListResponse: DatadogHostListResult + DatadogMonitorResourceListResponse: DatadogMonitorResourceListResult + DatadogSingleSignOnResourceListResponse: DatadogSingleSignOnResourceListResult + LinkedResourceListResponse: LinkedResourceListResult + MonitoredResourceListResponse: MonitoredResourceListResult + MonitoringTagRulesListResponse: MonitoringTagRulesListResult + CreateResourceSupportedResponseList: CreateResourceSupportedResultList + Operation: OperationData + CreateResourceSupportedProperties.creationSupported: IsCreationSupported + MarketplaceSaaSInfo.subscribed: IsSubscribed + DatadogAgreementProperties.accepted: IsAccepted + DatadogOrganizationProperties.cspm: IsCspm + LogRules.sendAadLogs: IsSendAadLogs + LogRules.sendSubscriptionLogs: IsSendSubscriptionLogs + LogRules.sendResourceLogs: IsSendResourceLogs + MonitorUpdateProperties.cspm: IsCspm + MonitoredResource.sendingMetrics: IsSendingMetrics + MonitoredResource.sendingLogs: IsSendingLogs + MonitoringTagRulesProperties.automuting: IsAutomuting + MonitoringTagRulesProperties.customMetrics: IsCustomMetrics ``` diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Azure.ResourceManager.Datadog.Tests.csproj b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Azure.ResourceManager.Datadog.Tests.csproj index 9274d72027b5..8f63856f6b6a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Azure.ResourceManager.Datadog.Tests.csproj +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Azure.ResourceManager.Datadog.Tests.csproj @@ -6,4 +6,7 @@ + + + diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs index d774715053ba..30dc8c692a5e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs @@ -135,7 +135,7 @@ public async Task GetDefaultKey_MonitorsGetDefaultKey() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogApiKey result = await datadogMonitorResource.GetDefaultKeyAsync(); + DatadogApiKeyContent result = await datadogMonitorResource.GetDefaultKeyAsync(); Console.WriteLine($"Succeeded: {result}"); } @@ -161,7 +161,7 @@ public async Task GetApiKeys_MonitorsListApiKeys() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation and iterate over the result - await foreach (DatadogApiKey item in datadogMonitorResource.GetApiKeysAsync()) + await foreach (DatadogApiKeyContent item in datadogMonitorResource.GetApiKeysAsync()) { Console.WriteLine($"Succeeded: {item}"); } @@ -303,8 +303,8 @@ public async Task SetDefaultKey_MonitorsSetDefaultKey() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogApiKey body = new DatadogApiKey("1111111111111111aaaaaaaaaaaaaaaa"); - await datadogMonitorResource.SetDefaultKeyAsync(body: body); + DatadogApiKeyContent content = new DatadogApiKeyContent("1111111111111111aaaaaaaaaaaaaaaa"); + await datadogMonitorResource.SetDefaultKeyAsync(content: content); Console.WriteLine("Succeeded"); } @@ -330,7 +330,7 @@ public async Task GetBillingInfo_BillingInfoGet() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogBillingInfoResponseResult result = await datadogMonitorResource.GetBillingInfoAsync(); + DatadogBillingInfoResult result = await datadogMonitorResource.GetBillingInfoAsync(); Console.WriteLine($"Succeeded: {result}"); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs index ba7c90fedf2c..28441d57f363 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs @@ -53,7 +53,7 @@ public async Task CreateOrUpdate_MonitorsCreate() LinkingAuthCode = "someAuthCode", LinkingClientId = "00000000-0000-0000-0000-000000000000", EnterpriseAppId = "00000000-0000-0000-0000-000000000000", - Cspm = false, + IsCspm = false, }, UserInfo = new UserInfo { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs index cf4e1174aff5..a98a867dc55a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs @@ -45,18 +45,18 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() { Properties = new SubscriptionList { - Operation = Models.Operation.AddBegin, + Operation = OperationData.AddBegin, MonitoredSubscriptionList = {new MonitoredSubscription { SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000000", -Status = Status.Active, +Status = MonitoredStatus.Active, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -SendAadLogs = false, -SendSubscriptionLogs = true, -SendResourceLogs = true, +IsSendAadLogs = false, +IsSendSubscriptionLogs = true, +IsSendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -70,19 +70,19 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() }}, }, MetricRulesFilteringTags = {}, -Automuting = true, +IsAutomuting = true, }, }, new MonitoredSubscription { SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000001", -Status = Status.Failed, +Status = MonitoredStatus.Failed, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -SendAadLogs = false, -SendSubscriptionLogs = true, -SendResourceLogs = true, +IsSendAadLogs = false, +IsSendSubscriptionLogs = true, +IsSendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -96,7 +96,7 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() }}, }, MetricRulesFilteringTags = {}, -Automuting = true, +IsAutomuting = true, }, }}, }, diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs index dd6c2ce7d492..ddc30b5608d0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs @@ -100,18 +100,18 @@ public async Task Update_MonitorsUpdateMonitoredSubscriptions() { Properties = new SubscriptionList { - Operation = Models.Operation.AddComplete, + Operation = OperationData.AddComplete, MonitoredSubscriptionList = {new MonitoredSubscription { SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000000", -Status = Status.Active, +Status = MonitoredStatus.Active, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -SendAadLogs = false, -SendSubscriptionLogs = true, -SendResourceLogs = true, +IsSendAadLogs = false, +IsSendSubscriptionLogs = true, +IsSendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -125,19 +125,19 @@ public async Task Update_MonitorsUpdateMonitoredSubscriptions() }}, }, MetricRulesFilteringTags = {}, -Automuting = true, +IsAutomuting = true, }, }, new MonitoredSubscription { SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000001", -Status = Status.Failed, +Status = MonitoredStatus.Failed, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -SendAadLogs = false, -SendSubscriptionLogs = true, -SendResourceLogs = true, +IsSendAadLogs = false, +IsSendSubscriptionLogs = true, +IsSendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -151,7 +151,7 @@ public async Task Update_MonitorsUpdateMonitoredSubscriptions() }}, }, MetricRulesFilteringTags = {}, -Automuting = true, +IsAutomuting = true, }, }}, }, diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs index 5ec9351b316b..23c29a697689 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs @@ -47,9 +47,9 @@ public async Task CreateOrUpdate_TagRulesCreateOrUpdate() { LogRules = new LogRules { - SendAadLogs = false, - SendSubscriptionLogs = true, - SendResourceLogs = true, + IsSendAadLogs = false, + IsSendSubscriptionLogs = true, + IsSendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -63,7 +63,7 @@ public async Task CreateOrUpdate_TagRulesCreateOrUpdate() }}, }, MetricRulesFilteringTags = { }, - Automuting = true, + IsAutomuting = true, }, }; ArmOperation lro = await collection.CreateOrUpdateAsync(WaitUntil.Completed, ruleSetName, data); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs index 190bfe929c3b..7fdbce7c8419 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs @@ -75,9 +75,9 @@ public async Task Update_TagRulesCreateOrUpdate() { LogRules = new LogRules { - SendAadLogs = false, - SendSubscriptionLogs = true, - SendResourceLogs = true, + IsSendAadLogs = false, + IsSendSubscriptionLogs = true, + IsSendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -91,7 +91,7 @@ public async Task Update_TagRulesCreateOrUpdate() }}, }, MetricRulesFilteringTags = { }, - Automuting = true, + IsAutomuting = true, }, }; ArmOperation lro = await monitoringTagRule.UpdateAsync(WaitUntil.Completed, data); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs index b3cdf8a14c50..3b7e5d728376 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs @@ -36,7 +36,7 @@ public async Task GetMarketplaceAgreements_MarketplaceAgreementsList() SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); // invoke the operation and iterate over the result - await foreach (DatadogAgreementResourceProperties item in subscriptionResource.GetMarketplaceAgreementsAsync()) + await foreach (DatadogAgreementResourceContent item in subscriptionResource.GetMarketplaceAgreementsAsync()) { Console.WriteLine($"Succeeded: {item}"); } @@ -63,14 +63,14 @@ public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreate SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); // invoke the operation - DatadogAgreementResourceProperties body = new DatadogAgreementResourceProperties + DatadogAgreementResourceContent content = new DatadogAgreementResourceContent { Properties = new DatadogAgreementProperties { - Accepted = true, + IsAccepted = true, }, }; - DatadogAgreementResourceProperties result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(body: body); + DatadogAgreementResourceContent result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(content: content); Console.WriteLine($"Succeeded: {result}"); } @@ -126,7 +126,7 @@ public async Task GetCreationSupporteds_CreationSupportedList() // invoke the operation and iterate over the result string datadogOrganizationId = "00000000-0000-0000-0000"; - await foreach (DatadogCreateResourceSupportedResponseResult item in subscriptionResource.GetCreationSupportedsAsync(datadogOrganizationId)) + await foreach (DatadogCreateResourceSupportedResult item in subscriptionResource.GetCreationSupportedsAsync(datadogOrganizationId)) { Console.WriteLine($"Succeeded: {item}"); } @@ -154,7 +154,7 @@ public async Task GetCreationSupported_CreationSupportedGet() // invoke the operation string datadogOrganizationId = "00000000-0000-0000-0000"; - DatadogCreateResourceSupportedResponseResult result = await subscriptionResource.GetCreationSupportedAsync(datadogOrganizationId); + DatadogCreateResourceSupportedResult result = await subscriptionResource.GetCreationSupportedAsync(datadogOrganizationId); Console.WriteLine($"Succeeded: {result}"); } From 5d0ecd71669c3501e7cc640e5d8c47a3197623b2 Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Wed, 17 Sep 2025 11:29:56 +0800 Subject: [PATCH 3/7] fixed spell issue --- .vscode/cspell.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.vscode/cspell.json b/.vscode/cspell.json index 10f1c05482fe..c798d8c17531 100644 --- a/.vscode/cspell.json +++ b/.vscode/cspell.json @@ -540,7 +540,8 @@ { "filename": "**/sdk/datadog/**/*.cs", "words": [ - "liftr" + "liftr", + "Cspm" ] }, { From 94cff3ac5c4a1215fbbd4562f916034e7556a252 Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Tue, 23 Sep 2025 15:05:37 +0800 Subject: [PATCH 4/7] Regenerate the SDK code using the new swagger. --- .../Azure.ResourceManager.Datadog.net8.0.cs | 32 +++- ....ResourceManager.Datadog.netstandard2.0.cs | 32 +++- .../src/Generated/ArmDatadogModelFactory.cs | 6 +- .../src/Generated/DatadogMonitorResource.cs | 150 +++++++++++++---- .../DatadogMonitorResourceCollection.cs | 20 +-- .../Generated/DatadogMonitorResourceData.cs | 6 +- .../Generated/DatadogSingleSignOnResource.cs | 8 +- .../DatadogSingleSignOnResourceCollection.cs | 20 +-- .../Generated/Extensions/DatadogExtensions.cs | 24 +-- .../MockableDatadogResourceGroupResource.cs | 4 +- .../MockableDatadogSubscriptionResource.cs | 20 +-- .../AzureResourceManagerDatadogContext.cs | 2 + .../Models/DataDogAgentRules.Serialization.cs | 158 +++++++++++++++++ .../src/Generated/Models/DataDogAgentRules.cs | 70 ++++++++ ...aDogResubscribeProperties.Serialization.cs | 159 ++++++++++++++++++ .../Models/DataDogResubscribeProperties.cs | 81 +++++++++ .../Models/DatadogMonitorResourcePatch.cs | 6 +- ...dogOrganizationProperties.Serialization.cs | 16 ++ .../Models/DatadogOrganizationProperties.cs | 6 +- .../MonitorUpdateProperties.Serialization.cs | 17 +- .../Models/MonitorUpdateProperties.cs | 6 +- ...itoringTagRulesProperties.Serialization.cs | 16 ++ .../Models/MonitoringTagRulesProperties.cs | 6 +- .../src/Generated/Models/ResourceSku.cs | 8 +- ...MonitoredSubscriptionPropertyCollection.cs | 20 +-- .../MonitoredSubscriptionPropertyResource.cs | 12 +- .../Generated/MonitoringTagRuleCollection.cs | 20 +-- .../Generated/MonitoringTagRuleResource.cs | 8 +- .../BillingInfoRestOperations.cs | 2 +- .../CreationSupportedRestOperations.cs | 2 +- .../MarketplaceAgreementsRestOperations.cs | 2 +- .../MonitoredSubscriptionsRestOperations.cs | 2 +- .../RestOperations/MonitorsRestOperations.cs | 2 +- .../OrganizationsRestOperations.cs | 133 +++++++++++++++ ...ingleSignOnConfigurationsRestOperations.cs | 2 +- .../RestOperations/TagRulesRestOperations.cs | 2 +- .../src/autorest.md | 11 +- .../Samples/Sample_DatadogMonitorResource.cs | 62 +++++-- ...Sample_DatadogMonitorResourceCollection.cs | 11 +- .../Sample_DatadogSingleSignOnResource.cs | 4 +- ...e_DatadogSingleSignOnResourceCollection.cs | 10 +- ...MonitoredSubscriptionPropertyCollection.cs | 10 +- ...e_MonitoredSubscriptionPropertyResource.cs | 6 +- .../Sample_MonitoringTagRuleCollection.cs | 10 +- .../Sample_MonitoringTagRuleResource.cs | 4 +- .../Sample_SubscriptionResourceExtensions.cs | 10 +- 46 files changed, 1034 insertions(+), 184 deletions(-) create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.Serialization.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.cs create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/OrganizationsRestOperations.cs diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs index 2033b9c342a8..b1d3d8169a35 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs @@ -64,6 +64,8 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> RefreshSetPasswordLinkAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response RemoveTag(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> RemoveTagAsync(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.ResourceManager.ArmOperation ResubscribeOrganization(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> ResubscribeOrganizationAsync(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetTags(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -296,7 +298,7 @@ public static partial class ArmDatadogModelFactory public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, Azure.ResourceManager.Datadog.Models.DataDogAgentRules agentRules = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity(string id = null, string name = null, System.Uri partnerEntityUri = null) { throw null; } } @@ -312,6 +314,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogAgentRules : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogAgentRules() { } + public System.Collections.Generic.IList FilteringTags { get { throw null; } } + public bool? IsAgentMonitoringEnabled { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogAgentRules 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.Datadog.Models.DataDogAgentRules System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogAgreementProperties() { } @@ -439,6 +453,7 @@ public DatadogOrganizationProperties() { } public string EnterpriseAppId { get { throw null; } set { } } public string Id { get { throw null; } set { } } public bool? IsCspm { get { throw null; } set { } } + public bool? IsResourceCollection { get { throw null; } set { } } public string LinkingAuthCode { get { throw null; } set { } } public string LinkingClientId { get { throw null; } set { } } public string Name { get { throw null; } set { } } @@ -450,6 +465,19 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogResubscribeProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogResubscribeProperties() { } + public Azure.Core.ResourceIdentifier AzureSubscriptionId { get { throw null; } set { } } + public string ResourceGroup { get { throw null; } set { } } + public string SkuName { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties 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.Datadog.Models.DataDogResubscribeProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogSetPasswordLink : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal DatadogSetPasswordLink() { } @@ -637,6 +665,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoringTagRulesProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoringTagRulesProperties() { } + public Azure.ResourceManager.Datadog.Models.DataDogAgentRules AgentRules { get { throw null; } set { } } public bool? IsAutomuting { get { throw null; } set { } } public bool? IsCustomMetrics { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.LogRules LogRules { get { throw null; } set { } } @@ -670,6 +699,7 @@ public partial class MonitorUpdateProperties : System.ClientModel.Primitives.IJs { public MonitorUpdateProperties() { } public bool? IsCspm { get { throw null; } set { } } + public bool? IsResourceCollection { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitoringStatus { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs index 2033b9c342a8..b1d3d8169a35 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs @@ -64,6 +64,8 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> RefreshSetPasswordLinkAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response RemoveTag(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> RemoveTagAsync(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.ResourceManager.ArmOperation ResubscribeOrganization(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> ResubscribeOrganizationAsync(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetTags(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -296,7 +298,7 @@ public static partial class ArmDatadogModelFactory public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, Azure.ResourceManager.Datadog.Models.DataDogAgentRules agentRules = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity(string id = null, string name = null, System.Uri partnerEntityUri = null) { throw null; } } @@ -312,6 +314,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogAgentRules : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogAgentRules() { } + public System.Collections.Generic.IList FilteringTags { get { throw null; } } + public bool? IsAgentMonitoringEnabled { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogAgentRules 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.Datadog.Models.DataDogAgentRules System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogAgreementProperties() { } @@ -439,6 +453,7 @@ public DatadogOrganizationProperties() { } public string EnterpriseAppId { get { throw null; } set { } } public string Id { get { throw null; } set { } } public bool? IsCspm { get { throw null; } set { } } + public bool? IsResourceCollection { get { throw null; } set { } } public string LinkingAuthCode { get { throw null; } set { } } public string LinkingClientId { get { throw null; } set { } } public string Name { get { throw null; } set { } } @@ -450,6 +465,19 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogResubscribeProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogResubscribeProperties() { } + public Azure.Core.ResourceIdentifier AzureSubscriptionId { get { throw null; } set { } } + public string ResourceGroup { get { throw null; } set { } } + public string SkuName { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties 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.Datadog.Models.DataDogResubscribeProperties System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogSetPasswordLink : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal DatadogSetPasswordLink() { } @@ -637,6 +665,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoringTagRulesProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoringTagRulesProperties() { } + public Azure.ResourceManager.Datadog.Models.DataDogAgentRules AgentRules { get { throw null; } set { } } public bool? IsAutomuting { get { throw null; } set { } } public bool? IsCustomMetrics { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.LogRules LogRules { get { throw null; } set { } } @@ -670,6 +699,7 @@ public partial class MonitorUpdateProperties : System.ClientModel.Primitives.IJs { public MonitorUpdateProperties() { } public bool? IsCspm { get { throw null; } set { } } + public bool? IsResourceCollection { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringStatus? MonitoringStatus { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitorUpdateProperties System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs index 70e6c9eca3d0..0dd53ccef953 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs @@ -42,7 +42,7 @@ public static DatadogAgreementResourceContent DatadogAgreementResourceContent(Re /// The tags. /// The location. /// Properties specific to the monitor resource. - /// Represents the SKU of a resource. + /// /// Gets or sets the identity. Current supported identity types: SystemAssigned, UserAssigned. /// A new instance for mocking. public static DatadogMonitorResourceData DatadogMonitorResourceData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, IDictionary tags = null, AzureLocation location = default, MonitorProperties properties = null, string skuName = null, ManagedServiceIdentity identity = null) @@ -221,10 +221,11 @@ public static MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyDat /// /// Set of rules for sending logs for the Monitor resource. /// Set of rules for sending metrics for the Monitor resource. + /// Set of rules for managing agents for the Monitor resource. /// Configuration to enable/disable auto-muting flag. /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. /// A new instance for mocking. - public static MonitoringTagRulesProperties MonitoringTagRulesProperties(ProvisioningState? provisioningState = null, LogRules logRules = null, IEnumerable metricRulesFilteringTags = null, bool? isAutomuting = null, bool? isCustomMetrics = null) + public static MonitoringTagRulesProperties MonitoringTagRulesProperties(ProvisioningState? provisioningState = null, LogRules logRules = null, IEnumerable metricRulesFilteringTags = null, DataDogAgentRules agentRules = null, bool? isAutomuting = null, bool? isCustomMetrics = null) { metricRulesFilteringTags ??= new List(); @@ -232,6 +233,7 @@ public static MonitoringTagRulesProperties MonitoringTagRulesProperties(Provisio provisioningState, logRules, metricRulesFilteringTags != null ? new MetricRules(metricRulesFilteringTags?.ToList(), serializedAdditionalRawData: null) : null, + agentRules, isAutomuting, isCustomMetrics, serializedAdditionalRawData: null); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs index d52d1367ccbc..d40caf6c39ca 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs @@ -40,6 +40,8 @@ public static ResourceIdentifier CreateResourceIdentifier(string subscriptionId, private readonly MonitorsRestOperations _datadogMonitorResourceMonitorsRestClient; private readonly ClientDiagnostics _billingInfoClientDiagnostics; private readonly BillingInfoRestOperations _billingInfoRestClient; + private readonly ClientDiagnostics _organizationsClientDiagnostics; + private readonly OrganizationsRestOperations _organizationsRestClient; private readonly DatadogMonitorResourceData _data; /// Gets the resource type for the operations. @@ -69,6 +71,8 @@ internal DatadogMonitorResource(ArmClient client, ResourceIdentifier id) : base( _datadogMonitorResourceMonitorsRestClient = new MonitorsRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint, datadogMonitorResourceMonitorsApiVersion); _billingInfoClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.Datadog", ProviderConstants.DefaultProviderNamespace, Diagnostics); _billingInfoRestClient = new BillingInfoRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint); + _organizationsClientDiagnostics = new ClientDiagnostics("Azure.ResourceManager.Datadog", ProviderConstants.DefaultProviderNamespace, Diagnostics); + _organizationsRestClient = new OrganizationsRestOperations(Pipeline, Diagnostics.ApplicationId, Endpoint); #if DEBUG ValidateResourceId(Id); #endif @@ -115,7 +119,7 @@ public virtual MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionP /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -146,7 +150,7 @@ public virtual async Task> GetMo /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -184,7 +188,7 @@ public virtual DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResou /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -215,7 +219,7 @@ public virtual async Task> GetDatadogSingl /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -253,7 +257,7 @@ public virtual MonitoringTagRuleCollection GetMonitoringTagRules() /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -284,7 +288,7 @@ public virtual async Task> GetMonitoringTagR /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -315,7 +319,7 @@ public virtual Response GetMonitoringTagRule(string r /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -355,7 +359,7 @@ public virtual async Task> GetAsync(Cancellatio /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -395,7 +399,7 @@ public virtual Response Get(CancellationToken cancellati /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -437,7 +441,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -479,7 +483,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -525,7 +529,7 @@ public virtual async Task> UpdateAsync(Wait /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -571,7 +575,7 @@ public virtual ArmOperation Update(WaitUntil waitUntil, /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -609,7 +613,7 @@ public virtual async Task> GetDefaultKeyAsync(Can /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -647,7 +651,7 @@ public virtual Response GetDefaultKey(CancellationToken ca /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -677,7 +681,7 @@ public virtual AsyncPageable GetApiKeysAsync(CancellationT /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -707,7 +711,7 @@ public virtual Pageable GetApiKeys(CancellationToken cance /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -737,7 +741,7 @@ public virtual AsyncPageable GetHostsAsync(CancellationToken cancel /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -767,7 +771,7 @@ public virtual Pageable GetHosts(CancellationToken cancellationToke /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -797,7 +801,7 @@ public virtual AsyncPageable GetLinkedResourcesAsync(CancellationTok /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -827,7 +831,7 @@ public virtual Pageable GetLinkedResources(CancellationToken cancell /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -857,7 +861,7 @@ public virtual AsyncPageable GetMonitoredResourcesAsyn /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -887,7 +891,7 @@ public virtual Pageable GetMonitoredResources(Cancella /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -925,7 +929,7 @@ public virtual async Task> RefreshSetPasswordLi /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -963,7 +967,7 @@ public virtual Response RefreshSetPasswordLink(Cancellat /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -1002,7 +1006,7 @@ public virtual async Task SetDefaultKeyAsync(DatadogApiKeyContent cont /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -1041,7 +1045,7 @@ public virtual Response SetDefaultKey(DatadogApiKeyContent content = null, Cance /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -1075,7 +1079,7 @@ public virtual async Task> GetBillingInfoAsyn /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -1096,6 +1100,84 @@ public virtual Response GetBillingInfo(CancellationTok } } + /// + /// Reinstate integration with your Datadog organization by choosing one of the available subscription plans. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/resubscribe + /// + /// + /// Operation Id + /// Organizations_Resubscribe + /// + /// + /// Default Api Version + /// 2025-06-11 + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// Resubscribe Properties. + /// The cancellation token to use. + public virtual async Task> ResubscribeOrganizationAsync(WaitUntil waitUntil, DataDogResubscribeProperties body = null, CancellationToken cancellationToken = default) + { + using var scope = _organizationsClientDiagnostics.CreateScope("DatadogMonitorResource.ResubscribeOrganization"); + scope.Start(); + try + { + var response = await _organizationsRestClient.ResubscribeAsync(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken).ConfigureAwait(false); + var operation = new DatadogArmOperation(new DatadogMonitorResourceOperationSource(Client), _organizationsClientDiagnostics, Pipeline, _organizationsRestClient.CreateResubscribeRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + await operation.WaitForCompletionAsync(cancellationToken).ConfigureAwait(false); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + + /// + /// Reinstate integration with your Datadog organization by choosing one of the available subscription plans. + /// + /// + /// Request Path + /// /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Datadog/monitors/{monitorName}/resubscribe + /// + /// + /// Operation Id + /// Organizations_Resubscribe + /// + /// + /// Default Api Version + /// 2025-06-11 + /// + /// + /// + /// if the method should wait to return until the long-running operation has completed on the service; if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples. + /// Resubscribe Properties. + /// The cancellation token to use. + public virtual ArmOperation ResubscribeOrganization(WaitUntil waitUntil, DataDogResubscribeProperties body = null, CancellationToken cancellationToken = default) + { + using var scope = _organizationsClientDiagnostics.CreateScope("DatadogMonitorResource.ResubscribeOrganization"); + scope.Start(); + try + { + var response = _organizationsRestClient.Resubscribe(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body, cancellationToken); + var operation = new DatadogArmOperation(new DatadogMonitorResourceOperationSource(Client), _organizationsClientDiagnostics, Pipeline, _organizationsRestClient.CreateResubscribeRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, body).Request, response, OperationFinalStateVia.Location); + if (waitUntil == WaitUntil.Completed) + operation.WaitForCompletion(cancellationToken); + return operation; + } + catch (Exception e) + { + scope.Failed(e); + throw; + } + } + /// /// Add a tag to the current resource. /// @@ -1109,7 +1191,7 @@ public virtual Response GetBillingInfo(CancellationTok /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -1171,7 +1253,7 @@ public virtual async Task> AddTagAsync(string k /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -1233,7 +1315,7 @@ public virtual Response AddTag(string key, string value, /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -1290,7 +1372,7 @@ public virtual async Task> SetTagsAsync(IDictio /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -1347,7 +1429,7 @@ public virtual Response SetTags(IDictionary /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -1407,7 +1489,7 @@ public virtual async Task> RemoveTagAsync(strin /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs index b6120a4bf2f2..452d9629b4b0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceCollection.cs @@ -65,7 +65,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -114,7 +114,7 @@ public virtual async Task> CreateOrUpdateAs /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -163,7 +163,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil wai /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -208,7 +208,7 @@ public virtual async Task> GetAsync(string moni /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -253,7 +253,7 @@ public virtual Response Get(string monitorName, Cancella /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -283,7 +283,7 @@ public virtual AsyncPageable GetAllAsync(CancellationTok /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -313,7 +313,7 @@ public virtual Pageable GetAll(CancellationToken cancell /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -356,7 +356,7 @@ public virtual async Task> ExistsAsync(string monitorName, Cancel /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -399,7 +399,7 @@ public virtual Response Exists(string monitorName, CancellationToken cance /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -444,7 +444,7 @@ public virtual async Task> GetIfExistsA /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs index 91bfaf4a23e1..4679c1b3b0ac 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResourceData.cs @@ -65,7 +65,7 @@ public DatadogMonitorResourceData(AzureLocation location) : base(location) /// The tags. /// The location. /// Properties specific to the monitor resource. - /// Represents the SKU of a resource. + /// /// Gets or sets the identity. Current supported identity types: SystemAssigned, UserAssigned. /// Keeps track of any properties unknown to the library. internal DatadogMonitorResourceData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, IDictionary tags, AzureLocation location, MonitorProperties properties, ResourceSku sku, ManagedServiceIdentity identity, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData, tags, location) @@ -83,9 +83,9 @@ internal DatadogMonitorResourceData() /// Properties specific to the monitor resource. public MonitorProperties Properties { get; set; } - /// Represents the SKU of a resource. + /// Gets or sets the sku. internal ResourceSku Sku { get; set; } - /// The name of the SKU. + /// Name of the SKU in {PlanId} format. For Terraform, the only allowed value is 'Linked'. public string SkuName { get => Sku is null ? default : Sku.Name; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs index 03f698358feb..1d9ac6916fef 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(Cancel /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken cance /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -227,7 +227,7 @@ public virtual async Task> UpdateAsync /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs index e20111693211..f38f39dda44a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogSingleSignOnResourceCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -113,7 +113,7 @@ public virtual async Task> CreateOrUpd /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -162,7 +162,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUnti /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -207,7 +207,7 @@ public virtual async Task> GetAsync(string /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -252,7 +252,7 @@ public virtual Response Get(string configurationNam /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -282,7 +282,7 @@ public virtual AsyncPageable GetAllAsync(Cancellati /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -312,7 +312,7 @@ public virtual Pageable GetAll(CancellationToken ca /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -355,7 +355,7 @@ public virtual async Task> ExistsAsync(string configurationName, /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -398,7 +398,7 @@ public virtual Response Exists(string configurationName, CancellationToken /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -443,7 +443,7 @@ public virtual async Task> GetIfEx /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs index 59ff1797a28a..69c3e4c91590 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs @@ -139,7 +139,7 @@ public static DatadogMonitorResourceCollection GetDatadogMonitorResources(this R /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -177,7 +177,7 @@ public static async Task> GetDatadogMonitorReso /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -215,7 +215,7 @@ public static Response GetDatadogMonitorResource(this Re /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -247,7 +247,7 @@ public static AsyncPageable GetMarketplaceAgree /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -279,7 +279,7 @@ public static Pageable GetMarketplaceAgreements /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -311,7 +311,7 @@ public static async Task> CreateOrUpda /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -343,7 +343,7 @@ public static Response CreateOrUpdateMarketplac /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -379,7 +379,7 @@ public static AsyncPageable GetDatadogMonitorResourcesAs /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -415,7 +415,7 @@ public static Pageable GetDatadogMonitorResources(this S /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -448,7 +448,7 @@ public static AsyncPageable GetCreationSup /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -481,7 +481,7 @@ public static Pageable GetCreationSupporte /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -513,7 +513,7 @@ public static async Task> GetCrea /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs index cf8023142f7e..969aed93d137 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogResourceGroupResource.cs @@ -53,7 +53,7 @@ public virtual DatadogMonitorResourceCollection GetDatadogMonitorResources() /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -84,7 +84,7 @@ public virtual async Task> GetDatadogMonitorRes /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs index 7556c637ee74..68b3013ffe30 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs @@ -63,7 +63,7 @@ private string GetApiVersionOrNull(ResourceType resourceType) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -89,7 +89,7 @@ public virtual AsyncPageable GetMarketplaceAgre /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -115,7 +115,7 @@ public virtual Pageable GetMarketplaceAgreement /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -150,7 +150,7 @@ public virtual async Task> CreateOrUpd /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -185,7 +185,7 @@ public virtual Response CreateOrUpdateMarketpla /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -215,7 +215,7 @@ public virtual AsyncPageable GetDatadogMonitorResourcesA /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -245,7 +245,7 @@ public virtual Pageable GetDatadogMonitorResources(Cance /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -275,7 +275,7 @@ public virtual AsyncPageable GetCreationSu /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -305,7 +305,7 @@ public virtual Pageable GetCreationSupport /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// @@ -343,7 +343,7 @@ public virtual async Task> GetCre /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs index 266ce61d103b..fed1d1739730 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs @@ -17,6 +17,7 @@ namespace Azure.ResourceManager.Datadog /// [ModelReaderWriterBuildable(typeof(CreateResourceSupportedProperties))] [ModelReaderWriterBuildable(typeof(CreateResourceSupportedResultList))] + [ModelReaderWriterBuildable(typeof(DataDogAgentRules))] [ModelReaderWriterBuildable(typeof(DatadogAgreementProperties))] [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceContent))] [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceListResult))] @@ -34,6 +35,7 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(DatadogMonitorResourceListResult))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResourcePatch))] [ModelReaderWriterBuildable(typeof(DatadogOrganizationProperties))] + [ModelReaderWriterBuildable(typeof(DataDogResubscribeProperties))] [ModelReaderWriterBuildable(typeof(DatadogSetPasswordLink))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnProperties))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResource))] diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.Serialization.cs new file mode 100644 index 000000000000..3334a913e9fc --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.Serialization.cs @@ -0,0 +1,158 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class DataDogAgentRules : 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") + { + throw new FormatException($"The model {nameof(DataDogAgentRules)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(IsAgentMonitoringEnabled)) + { + writer.WritePropertyName("enableAgentMonitoring"u8); + writer.WriteBooleanValue(IsAgentMonitoringEnabled.Value); + } + if (Optional.IsCollectionDefined(FilteringTags)) + { + writer.WritePropertyName("filteringTags"u8); + writer.WriteStartArray(); + foreach (var item in FilteringTags) + { + writer.WriteObjectValue(item, options); + } + writer.WriteEndArray(); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + DataDogAgentRules IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(DataDogAgentRules)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeDataDogAgentRules(document.RootElement, options); + } + + internal static DataDogAgentRules DeserializeDataDogAgentRules(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + bool? enableAgentMonitoring = default; + IList filteringTags = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("enableAgentMonitoring"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + enableAgentMonitoring = property.Value.GetBoolean(); + continue; + } + if (property.NameEquals("filteringTags"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + List array = new List(); + foreach (var item in property.Value.EnumerateArray()) + { + array.Add(FilteringTag.DeserializeFilteringTag(item, options)); + } + filteringTags = array; + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new DataDogAgentRules(enableAgentMonitoring, filteringTags ?? new ChangeTrackingList(), serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(DataDogAgentRules)} does not support writing '{options.Format}' format."); + } + } + + DataDogAgentRules IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeDataDogAgentRules(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(DataDogAgentRules)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.cs new file mode 100644 index 000000000000..970b52b5b0d1 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgentRules.cs @@ -0,0 +1,70 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Set of rules for managing agents for the Monitor resource. + public partial class DataDogAgentRules + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public DataDogAgentRules() + { + FilteringTags = new ChangeTrackingList(); + } + + /// Initializes a new instance of . + /// Flag specifying if agent monitoring should be enabled for the Monitor resource. + /// List of filtering tags to be used for capturing metrics. If empty, all resources will be captured. If only Exclude action is specified, the rules will apply to the list of all available resources. If Include actions are specified, the rules will only include resources with the associated tags. + /// Keeps track of any properties unknown to the library. + internal DataDogAgentRules(bool? isAgentMonitoringEnabled, IList filteringTags, IDictionary serializedAdditionalRawData) + { + IsAgentMonitoringEnabled = isAgentMonitoringEnabled; + FilteringTags = filteringTags; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Flag specifying if agent monitoring should be enabled for the Monitor resource. + public bool? IsAgentMonitoringEnabled { get; set; } + /// List of filtering tags to be used for capturing metrics. If empty, all resources will be captured. If only Exclude action is specified, the rules will apply to the list of all available resources. If Include actions are specified, the rules will only include resources with the associated tags. + public IList FilteringTags { get; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.Serialization.cs new file mode 100644 index 000000000000..50ba94ef1d27 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.Serialization.cs @@ -0,0 +1,159 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ClientModel.Primitives; +using System.Collections.Generic; +using System.Text.Json; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + public partial class DataDogResubscribeProperties : 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") + { + throw new FormatException($"The model {nameof(DataDogResubscribeProperties)} does not support writing '{format}' format."); + } + + if (Optional.IsDefined(Sku)) + { + writer.WritePropertyName("sku"u8); + writer.WriteObjectValue(Sku, options); + } + if (Optional.IsDefined(AzureSubscriptionId)) + { + writer.WritePropertyName("azureSubscriptionId"u8); + writer.WriteStringValue(AzureSubscriptionId); + } + if (Optional.IsDefined(ResourceGroup)) + { + writer.WritePropertyName("resourceGroup"u8); + writer.WriteStringValue(ResourceGroup); + } + 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, ModelSerializationExtensions.JsonDocumentOptions)) + { + JsonSerializer.Serialize(writer, document.RootElement); + } +#endif + } + } + } + + DataDogResubscribeProperties IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + if (format != "J") + { + throw new FormatException($"The model {nameof(DataDogResubscribeProperties)} does not support reading '{format}' format."); + } + + using JsonDocument document = JsonDocument.ParseValue(ref reader); + return DeserializeDataDogResubscribeProperties(document.RootElement, options); + } + + internal static DataDogResubscribeProperties DeserializeDataDogResubscribeProperties(JsonElement element, ModelReaderWriterOptions options = null) + { + options ??= ModelSerializationExtensions.WireOptions; + + if (element.ValueKind == JsonValueKind.Null) + { + return null; + } + ResourceSku sku = default; + ResourceIdentifier azureSubscriptionId = default; + string resourceGroup = default; + IDictionary serializedAdditionalRawData = default; + Dictionary rawDataDictionary = new Dictionary(); + foreach (var property in element.EnumerateObject()) + { + if (property.NameEquals("sku"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + sku = ResourceSku.DeserializeResourceSku(property.Value, options); + continue; + } + if (property.NameEquals("azureSubscriptionId"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + azureSubscriptionId = new ResourceIdentifier(property.Value.GetString()); + continue; + } + if (property.NameEquals("resourceGroup"u8)) + { + resourceGroup = property.Value.GetString(); + continue; + } + if (options.Format != "W") + { + rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); + } + } + serializedAdditionalRawData = rawDataDictionary; + return new DataDogResubscribeProperties(sku, azureSubscriptionId, resourceGroup, serializedAdditionalRawData); + } + + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); + default: + throw new FormatException($"The model {nameof(DataDogResubscribeProperties)} does not support writing '{options.Format}' format."); + } + } + + DataDogResubscribeProperties IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + { + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + + switch (format) + { + case "J": + { + using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); + return DeserializeDataDogResubscribeProperties(document.RootElement, options); + } + default: + throw new FormatException($"The model {nameof(DataDogResubscribeProperties)} does not support reading '{options.Format}' format."); + } + } + + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.cs new file mode 100644 index 000000000000..feb56b9af1c7 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogResubscribeProperties.cs @@ -0,0 +1,81 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Collections.Generic; +using Azure.Core; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// Resubscribe Properties. + public partial class DataDogResubscribeProperties + { + /// + /// Keeps track of any properties unknown to the library. + /// + /// To assign an object to the value of this property use . + /// + /// + /// To assign an already formatted json string to this property use . + /// + /// + /// Examples: + /// + /// + /// BinaryData.FromObjectAsJson("foo") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromString("\"foo\"") + /// Creates a payload of "foo". + /// + /// + /// BinaryData.FromObjectAsJson(new { key = "value" }) + /// Creates a payload of { "key": "value" }. + /// + /// + /// BinaryData.FromString("{\"key\": \"value\"}") + /// Creates a payload of { "key": "value" }. + /// + /// + /// + /// + private IDictionary _serializedAdditionalRawData; + + /// Initializes a new instance of . + public DataDogResubscribeProperties() + { + } + + /// Initializes a new instance of . + /// + /// Newly selected Azure Subscription Id in which the new Marketplace subscription will be created for Resubscribe. + /// Newly selected Azure resource group in which the new Marketplace subscription will be created for Resubscribe. + /// Keeps track of any properties unknown to the library. + internal DataDogResubscribeProperties(ResourceSku sku, ResourceIdentifier azureSubscriptionId, string resourceGroup, IDictionary serializedAdditionalRawData) + { + Sku = sku; + AzureSubscriptionId = azureSubscriptionId; + ResourceGroup = resourceGroup; + _serializedAdditionalRawData = serializedAdditionalRawData; + } + + /// Gets or sets the sku. + internal ResourceSku Sku { get; set; } + /// Name of the SKU in {PlanId} format. For Terraform, the only allowed value is 'Linked'. + public string SkuName + { + get => Sku is null ? default : Sku.Name; + set => Sku = new ResourceSku(value); + } + + /// Newly selected Azure Subscription Id in which the new Marketplace subscription will be created for Resubscribe. + public ResourceIdentifier AzureSubscriptionId { get; set; } + /// Newly selected Azure resource group in which the new Marketplace subscription will be created for Resubscribe. + public string ResourceGroup { get; set; } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs index e942b976aa35..cb6d1f3f0b30 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourcePatch.cs @@ -54,7 +54,7 @@ public DatadogMonitorResourcePatch() /// Initializes a new instance of . /// The set of properties that can be update in a PATCH request to a monitor resource. /// The new tags of the monitor resource. - /// Represents the SKU of a resource. + /// /// Keeps track of any properties unknown to the library. internal DatadogMonitorResourcePatch(MonitorUpdateProperties properties, IDictionary tags, ResourceSku sku, IDictionary serializedAdditionalRawData) { @@ -68,9 +68,9 @@ internal DatadogMonitorResourcePatch(MonitorUpdateProperties properties, IDictio public MonitorUpdateProperties Properties { get; set; } /// The new tags of the monitor resource. public IDictionary Tags { get; } - /// Represents the SKU of a resource. + /// Gets or sets the sku. internal ResourceSku Sku { get; set; } - /// The name of the SKU. + /// Name of the SKU in {PlanId} format. For Terraform, the only allowed value is 'Linked'. public string SkuName { get => Sku is null ? default : Sku.Name; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs index 660400852982..df3d93deca0f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.Serialization.cs @@ -79,6 +79,11 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("cspm"u8); writer.WriteBooleanValue(IsCspm.Value); } + if (Optional.IsDefined(IsResourceCollection)) + { + writer.WritePropertyName("resourceCollection"u8); + writer.WriteBooleanValue(IsResourceCollection.Value); + } if (options.Format != "W" && _serializedAdditionalRawData != null) { foreach (var item in _serializedAdditionalRawData) @@ -125,6 +130,7 @@ internal static DatadogOrganizationProperties DeserializeDatadogOrganizationProp string applicationKey = default; string enterpriseAppId = default; bool? cspm = default; + bool? resourceCollection = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) @@ -182,6 +188,15 @@ internal static DatadogOrganizationProperties DeserializeDatadogOrganizationProp cspm = property.Value.GetBoolean(); continue; } + if (property.NameEquals("resourceCollection"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + resourceCollection = property.Value.GetBoolean(); + continue; + } if (options.Format != "W") { rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); @@ -198,6 +213,7 @@ internal static DatadogOrganizationProperties DeserializeDatadogOrganizationProp applicationKey, enterpriseAppId, cspm, + resourceCollection, serializedAdditionalRawData); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs index 45c8c76c2f09..8be017ff9aa9 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogOrganizationProperties.cs @@ -60,8 +60,9 @@ public DatadogOrganizationProperties() /// Application key associated to the Datadog organization. /// The Id of the Enterprise App used for Single sign on. /// The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. + /// The configuration which describes the state of resource collection. This collects configuration information for all resources in a subscription. /// Keeps track of any properties unknown to the library. - internal DatadogOrganizationProperties(string name, string id, string linkingAuthCode, string linkingClientId, Uri redirectUri, string apiKey, string applicationKey, string enterpriseAppId, bool? isCspm, IDictionary serializedAdditionalRawData) + internal DatadogOrganizationProperties(string name, string id, string linkingAuthCode, string linkingClientId, Uri redirectUri, string apiKey, string applicationKey, string enterpriseAppId, bool? isCspm, bool? isResourceCollection, IDictionary serializedAdditionalRawData) { Name = name; Id = id; @@ -72,6 +73,7 @@ internal DatadogOrganizationProperties(string name, string id, string linkingAut ApplicationKey = applicationKey; EnterpriseAppId = enterpriseAppId; IsCspm = isCspm; + IsResourceCollection = isResourceCollection; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -93,5 +95,7 @@ internal DatadogOrganizationProperties(string name, string id, string linkingAut public string EnterpriseAppId { get; set; } /// The configuration which describes the state of cloud security posture management. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. public bool? IsCspm { get; set; } + /// The configuration which describes the state of resource collection. This collects configuration information for all resources in a subscription. + public bool? IsResourceCollection { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs index 16c26ced7511..03fcbd1b44d2 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.Serialization.cs @@ -44,6 +44,11 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("cspm"u8); writer.WriteBooleanValue(IsCspm.Value); } + if (Optional.IsDefined(IsResourceCollection)) + { + writer.WritePropertyName("resourceCollection"u8); + writer.WriteBooleanValue(IsResourceCollection.Value); + } if (options.Format != "W" && _serializedAdditionalRawData != null) { foreach (var item in _serializedAdditionalRawData) @@ -83,6 +88,7 @@ internal static MonitorUpdateProperties DeserializeMonitorUpdateProperties(JsonE } MonitoringStatus? monitoringStatus = default; bool? cspm = default; + bool? resourceCollection = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); foreach (var property in element.EnumerateObject()) @@ -105,13 +111,22 @@ internal static MonitorUpdateProperties DeserializeMonitorUpdateProperties(JsonE cspm = property.Value.GetBoolean(); continue; } + if (property.NameEquals("resourceCollection"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + resourceCollection = property.Value.GetBoolean(); + continue; + } if (options.Format != "W") { rawDataDictionary.Add(property.Name, BinaryData.FromString(property.Value.GetRawText())); } } serializedAdditionalRawData = rawDataDictionary; - return new MonitorUpdateProperties(monitoringStatus, cspm, serializedAdditionalRawData); + return new MonitorUpdateProperties(monitoringStatus, cspm, resourceCollection, serializedAdditionalRawData); } BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs index 094e43f40449..d88bb61601b1 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitorUpdateProperties.cs @@ -53,11 +53,13 @@ public MonitorUpdateProperties() /// Initializes a new instance of . /// Flag specifying if the resource monitoring is enabled or disabled. /// The new cloud security posture management value of the monitor resource. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. + /// The new resource collection value of the monitor resource. This collects configuration information for all resources in a subscription. /// Keeps track of any properties unknown to the library. - internal MonitorUpdateProperties(MonitoringStatus? monitoringStatus, bool? isCspm, IDictionary serializedAdditionalRawData) + internal MonitorUpdateProperties(MonitoringStatus? monitoringStatus, bool? isCspm, bool? isResourceCollection, IDictionary serializedAdditionalRawData) { MonitoringStatus = monitoringStatus; IsCspm = isCspm; + IsResourceCollection = isResourceCollection; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -65,5 +67,7 @@ internal MonitorUpdateProperties(MonitoringStatus? monitoringStatus, bool? isCsp public MonitoringStatus? MonitoringStatus { get; set; } /// The new cloud security posture management value of the monitor resource. This collects configuration information for all resources in a subscription and track conformance to industry benchmarks. public bool? IsCspm { get; set; } + /// The new resource collection value of the monitor resource. This collects configuration information for all resources in a subscription. + public bool? IsResourceCollection { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs index 1d6a1c34ed92..31b978235ba3 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.Serialization.cs @@ -49,6 +49,11 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("metricRules"u8); writer.WriteObjectValue(MetricRules, options); } + if (Optional.IsDefined(AgentRules)) + { + writer.WritePropertyName("agentRules"u8); + writer.WriteObjectValue(AgentRules, options); + } if (Optional.IsDefined(IsAutomuting)) { writer.WritePropertyName("automuting"u8); @@ -99,6 +104,7 @@ internal static MonitoringTagRulesProperties DeserializeMonitoringTagRulesProper ProvisioningState? provisioningState = default; LogRules logRules = default; MetricRules metricRules = default; + DataDogAgentRules agentRules = default; bool? automuting = default; bool? customMetrics = default; IDictionary serializedAdditionalRawData = default; @@ -132,6 +138,15 @@ internal static MonitoringTagRulesProperties DeserializeMonitoringTagRulesProper metricRules = MetricRules.DeserializeMetricRules(property.Value, options); continue; } + if (property.NameEquals("agentRules"u8)) + { + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + agentRules = DataDogAgentRules.DeserializeDataDogAgentRules(property.Value, options); + continue; + } if (property.NameEquals("automuting"u8)) { if (property.Value.ValueKind == JsonValueKind.Null) @@ -160,6 +175,7 @@ internal static MonitoringTagRulesProperties DeserializeMonitoringTagRulesProper provisioningState, logRules, metricRules, + agentRules, automuting, customMetrics, serializedAdditionalRawData); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs index 06d4d0266041..c59b005a927e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoringTagRulesProperties.cs @@ -54,14 +54,16 @@ public MonitoringTagRulesProperties() /// /// Set of rules for sending logs for the Monitor resource. /// Set of rules for sending metrics for the Monitor resource. + /// Set of rules for managing agents for the Monitor resource. /// Configuration to enable/disable auto-muting flag. /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. /// Keeps track of any properties unknown to the library. - internal MonitoringTagRulesProperties(ProvisioningState? provisioningState, LogRules logRules, MetricRules metricRules, bool? isAutomuting, bool? isCustomMetrics, IDictionary serializedAdditionalRawData) + internal MonitoringTagRulesProperties(ProvisioningState? provisioningState, LogRules logRules, MetricRules metricRules, DataDogAgentRules agentRules, bool? isAutomuting, bool? isCustomMetrics, IDictionary serializedAdditionalRawData) { ProvisioningState = provisioningState; LogRules = logRules; MetricRules = metricRules; + AgentRules = agentRules; IsAutomuting = isAutomuting; IsCustomMetrics = isCustomMetrics; _serializedAdditionalRawData = serializedAdditionalRawData; @@ -84,6 +86,8 @@ public IList MetricRulesFilteringTags } } + /// Set of rules for managing agents for the Monitor resource. + public DataDogAgentRules AgentRules { get; set; } /// Configuration to enable/disable auto-muting flag. public bool? IsAutomuting { get; set; } /// Configuration to enable/disable custom metrics. If enabled, custom metrics from app insights will be sent. diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs index 4b10f83ae5b2..c48c4c09f4aa 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/ResourceSku.cs @@ -10,7 +10,7 @@ namespace Azure.ResourceManager.Datadog.Models { - /// Represents the SKU of a resource. + /// The ResourceSku. internal partial class ResourceSku { /// @@ -46,7 +46,7 @@ internal partial class ResourceSku private IDictionary _serializedAdditionalRawData; /// Initializes a new instance of . - /// The name of the SKU. + /// Name of the SKU in {PlanId} format. For Terraform, the only allowed value is 'Linked'. /// is null. public ResourceSku(string name) { @@ -56,7 +56,7 @@ public ResourceSku(string name) } /// Initializes a new instance of . - /// The name of the SKU. + /// Name of the SKU in {PlanId} format. For Terraform, the only allowed value is 'Linked'. /// Keeps track of any properties unknown to the library. internal ResourceSku(string name, IDictionary serializedAdditionalRawData) { @@ -69,7 +69,7 @@ internal ResourceSku() { } - /// The name of the SKU. + /// Name of the SKU in {PlanId} format. For Terraform, the only allowed value is 'Linked'. public string Name { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs index e1ff2130fd92..8bb6977b9752 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -113,7 +113,7 @@ public virtual async Task> C /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -162,7 +162,7 @@ public virtual ArmOperation CreateOrUpdat /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -207,7 +207,7 @@ public virtual async Task> GetAs /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -252,7 +252,7 @@ public virtual Response Get(string config /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -282,7 +282,7 @@ public virtual AsyncPageable GetAllAsync( /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -312,7 +312,7 @@ public virtual Pageable GetAll(Cancellati /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -355,7 +355,7 @@ public virtual async Task> ExistsAsync(string configurationName, /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -398,7 +398,7 @@ public virtual Response Exists(string configurationName, CancellationToken /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -443,7 +443,7 @@ public virtual async Task /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs index 65e9ca04179e..1919d2ba8a0c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAs /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationT /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -223,7 +223,7 @@ public virtual async Task DeleteAsync(WaitUntil waitUntil, Cancell /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -265,7 +265,7 @@ public virtual ArmOperation Delete(WaitUntil waitUntil, CancellationToken cancel /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -311,7 +311,7 @@ public virtual async Task> U /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs index 42bbbf22a087..d5f013ae7c0f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleCollection.cs @@ -64,7 +64,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -115,7 +115,7 @@ public virtual async Task> CreateOrUpdat /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -166,7 +166,7 @@ public virtual ArmOperation CreateOrUpdate(WaitUntil /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -211,7 +211,7 @@ public virtual async Task> GetAsync(string r /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -256,7 +256,7 @@ public virtual Response Get(string ruleSetName, Cance /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -286,7 +286,7 @@ public virtual AsyncPageable GetAllAsync(Cancellation /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -316,7 +316,7 @@ public virtual Pageable GetAll(CancellationToken canc /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -359,7 +359,7 @@ public virtual async Task> ExistsAsync(string ruleSetName, Cancel /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -402,7 +402,7 @@ public virtual Response Exists(string ruleSetName, CancellationToken cance /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -447,7 +447,7 @@ public virtual async Task> GetIfExis /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs index 4301e45b49a3..3126fa35173c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoringTagRuleResource.cs @@ -101,7 +101,7 @@ internal static void ValidateResourceId(ResourceIdentifier id) /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -141,7 +141,7 @@ public virtual async Task> GetAsync(Cancella /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -181,7 +181,7 @@ public virtual Response Get(CancellationToken cancell /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource @@ -229,7 +229,7 @@ public virtual async Task> UpdateAsync(W /// /// /// Default Api Version - /// 2023-10-20 + /// 2025-06-11 /// /// /// Resource diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs index 93dcb4a4c9e8..157dc8cbb9e2 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs @@ -32,7 +32,7 @@ public BillingInfoRestOperations(HttpPipeline pipeline, string applicationId, Ur { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-10-20"; + _apiVersion = apiVersion ?? "2025-06-11"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs index 02bcd9f707b3..97bed3259fd8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs @@ -32,7 +32,7 @@ public CreationSupportedRestOperations(HttpPipeline pipeline, string application { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-10-20"; + _apiVersion = apiVersion ?? "2025-06-11"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs index 1b25b178beb4..181dbe80651e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs @@ -32,7 +32,7 @@ public MarketplaceAgreementsRestOperations(HttpPipeline pipeline, string applica { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-10-20"; + _apiVersion = apiVersion ?? "2025-06-11"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs index 2f7ced44c7e7..b2bb3b3d59a1 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitoredSubscriptionsRestOperations.cs @@ -32,7 +32,7 @@ public MonitoredSubscriptionsRestOperations(HttpPipeline pipeline, string applic { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-10-20"; + _apiVersion = apiVersion ?? "2025-06-11"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs index 14a53038f43b..0c2cf261df21 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs @@ -32,7 +32,7 @@ public MonitorsRestOperations(HttpPipeline pipeline, string applicationId, Uri e { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-10-20"; + _apiVersion = apiVersion ?? "2025-06-11"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/OrganizationsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/OrganizationsRestOperations.cs new file mode 100644 index 000000000000..04fd97820e67 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/OrganizationsRestOperations.cs @@ -0,0 +1,133 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.Threading; +using System.Threading.Tasks; +using Azure.Core; +using Azure.Core.Pipeline; +using Azure.ResourceManager.Datadog.Models; + +namespace Azure.ResourceManager.Datadog +{ + internal partial class OrganizationsRestOperations + { + private readonly TelemetryDetails _userAgent; + private readonly HttpPipeline _pipeline; + private readonly Uri _endpoint; + private readonly string _apiVersion; + + /// Initializes a new instance of OrganizationsRestOperations. + /// The HTTP pipeline for sending and receiving REST requests and responses. + /// The application id to use for user agent. + /// server parameter. + /// Api Version. + /// or is null. + public OrganizationsRestOperations(HttpPipeline pipeline, string applicationId, Uri endpoint = null, string apiVersion = default) + { + _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); + _endpoint = endpoint ?? new Uri("https://management.azure.com"); + _apiVersion = apiVersion ?? "2025-06-11"; + _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); + } + + internal RequestUriBuilder CreateResubscribeRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DataDogResubscribeProperties body) + { + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/resubscribe", false); + uri.AppendQuery("api-version", _apiVersion, true); + return uri; + } + + internal HttpMessage CreateResubscribeRequest(string subscriptionId, string resourceGroupName, string monitorName, DataDogResubscribeProperties body) + { + var message = _pipeline.CreateMessage(); + var request = message.Request; + request.Method = RequestMethod.Post; + var uri = new RawRequestUriBuilder(); + uri.Reset(_endpoint); + uri.AppendPath("/subscriptions/", false); + uri.AppendPath(subscriptionId, true); + uri.AppendPath("/resourceGroups/", false); + uri.AppendPath(resourceGroupName, true); + uri.AppendPath("/providers/Microsoft.Datadog/monitors/", false); + uri.AppendPath(monitorName, true); + uri.AppendPath("/resubscribe", false); + uri.AppendQuery("api-version", _apiVersion, true); + request.Uri = uri; + request.Headers.Add("Accept", "application/json"); + if (body != null) + { + request.Headers.Add("Content-Type", "application/json"); + var content = new Utf8JsonRequestContent(); + content.JsonWriter.WriteObjectValue(body, ModelSerializationExtensions.WireOptions); + request.Content = content; + } + _userAgent.Apply(message); + return message; + } + + /// Reinstate integration with your Datadog organization by choosing one of the available subscription plans. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// Resubscribe Properties. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public async Task ResubscribeAsync(string subscriptionId, string resourceGroupName, string monitorName, DataDogResubscribeProperties body = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateResubscribeRequest(subscriptionId, resourceGroupName, monitorName, body); + await _pipeline.SendAsync(message, cancellationToken).ConfigureAwait(false); + switch (message.Response.Status) + { + case 200: + case 202: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + + /// Reinstate integration with your Datadog organization by choosing one of the available subscription plans. + /// The ID of the target subscription. + /// The name of the resource group. The name is case insensitive. + /// Monitor resource name. + /// Resubscribe Properties. + /// The cancellation token to use. + /// , or is null. + /// , or is an empty string, and was expected to be non-empty. + public Response Resubscribe(string subscriptionId, string resourceGroupName, string monitorName, DataDogResubscribeProperties body = null, CancellationToken cancellationToken = default) + { + Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); + Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); + Argument.AssertNotNullOrEmpty(monitorName, nameof(monitorName)); + + using var message = CreateResubscribeRequest(subscriptionId, resourceGroupName, monitorName, body); + _pipeline.Send(message, cancellationToken); + switch (message.Response.Status) + { + case 200: + case 202: + return message.Response; + default: + throw new RequestFailedException(message.Response); + } + } + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs index 62baf9fe7e69..2222039d0a6c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs @@ -32,7 +32,7 @@ public SingleSignOnConfigurationsRestOperations(HttpPipeline pipeline, string ap { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-10-20"; + _apiVersion = apiVersion ?? "2025-06-11"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs index dece9fa4b1ca..65d53681d86a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/TagRulesRestOperations.cs @@ -32,7 +32,7 @@ public TagRulesRestOperations(HttpPipeline pipeline, string applicationId, Uri e { _pipeline = pipeline ?? throw new ArgumentNullException(nameof(pipeline)); _endpoint = endpoint ?? new Uri("https://management.azure.com"); - _apiVersion = apiVersion ?? "2023-10-20"; + _apiVersion = apiVersion ?? "2025-06-11"; _userAgent = new TelemetryDetails(GetType().Assembly, applicationId); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md index ba20d41d6606..302f9a99cf8c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md @@ -8,8 +8,9 @@ azure-arm: true csharp: true library-name: Datadog namespace: Azure.ResourceManager.Datadog -require: https://github.com/Azure/azure-rest-api-specs/blob/c37407dc4b8c49dd01fe73d9278e5c21beea169c/specification/datadog/resource-manager/readme.md -# tag: package-2023-10 +require: https://github.com/Azure/azure-rest-api-specs-pr/blob/30f23d89b + 692f80b495fb7f45c3e695872460bd1/specification/datadog/resource-manager/readme.md +# tag: package-2025-06 rpaas output-folder: $(this-folder)/Generated clear-output-folder: true sample-gen: @@ -73,13 +74,19 @@ rename-mapping: MarketplaceSaaSInfo.subscribed: IsSubscribed DatadogAgreementProperties.accepted: IsAccepted DatadogOrganizationProperties.cspm: IsCspm + DatadogOrganizationProperties.resourceCollection: IsResourceCollection LogRules.sendAadLogs: IsSendAadLogs LogRules.sendSubscriptionLogs: IsSendSubscriptionLogs LogRules.sendResourceLogs: IsSendResourceLogs MonitorUpdateProperties.cspm: IsCspm + MonitorUpdateProperties.resourceCollection: IsResourceCollection MonitoredResource.sendingMetrics: IsSendingMetrics MonitoredResource.sendingLogs: IsSendingLogs MonitoringTagRulesProperties.automuting: IsAutomuting MonitoringTagRulesProperties.customMetrics: IsCustomMetrics + AgentRules: DataDogAgentRules + AgentRules.enableAgentMonitoring: IsAgentMonitoringEnabled + ResubscribeProperties: DataDogResubscribeProperties + ResubscribeProperties.azureSubscriptionId: -|arm-id ``` diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs index 30dc8c692a5e..da2432af46c1 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs @@ -20,7 +20,7 @@ public partial class Sample_DatadogMonitorResource [Ignore("Only validating compilation of examples")] public async Task Get_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -50,7 +50,7 @@ public async Task Get_MonitorsGet() [Ignore("Only validating compilation of examples")] public async Task Delete_MonitorsDelete() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Delete.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_Delete.json // this example is just showing the usage of "Monitors_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -76,7 +76,7 @@ public async Task Delete_MonitorsDelete() [Ignore("Only validating compilation of examples")] public async Task Update_MonitorsUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Update.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_Update.json // this example is just showing the usage of "Monitors_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -118,7 +118,7 @@ public async Task Update_MonitorsUpdate() [Ignore("Only validating compilation of examples")] public async Task GetDefaultKey_MonitorsGetDefaultKey() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/ApiKeys_GetDefaultKey.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/ApiKeys_GetDefaultKey.json // this example is just showing the usage of "Monitors_GetDefaultKey" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -144,7 +144,7 @@ public async Task GetDefaultKey_MonitorsGetDefaultKey() [Ignore("Only validating compilation of examples")] public async Task GetApiKeys_MonitorsListApiKeys() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/ApiKeys_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/ApiKeys_List.json // this example is just showing the usage of "Monitors_ListApiKeys" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -173,7 +173,7 @@ public async Task GetApiKeys_MonitorsListApiKeys() [Ignore("Only validating compilation of examples")] public async Task GetHosts_MonitorsListHosts() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Hosts_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Hosts_List.json // this example is just showing the usage of "Monitors_ListHosts" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -202,7 +202,7 @@ public async Task GetHosts_MonitorsListHosts() [Ignore("Only validating compilation of examples")] public async Task GetLinkedResources_MonitorsListLinkedResources() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/LinkedResources_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/LinkedResources_List.json // this example is just showing the usage of "Monitors_ListLinkedResources" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -231,7 +231,7 @@ public async Task GetLinkedResources_MonitorsListLinkedResources() [Ignore("Only validating compilation of examples")] public async Task GetMonitoredResources_MonitorsListMonitoredResources() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredResources_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredResources_List.json // this example is just showing the usage of "Monitors_ListMonitoredResources" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -260,7 +260,7 @@ public async Task GetMonitoredResources_MonitorsListMonitoredResources() [Ignore("Only validating compilation of examples")] public async Task RefreshSetPasswordLink_MonitorsRefreshSetPasswordLink() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/RefreshSetPassword_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/RefreshSetPassword_Get.json // this example is just showing the usage of "Monitors_RefreshSetPasswordLink" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -286,7 +286,7 @@ public async Task RefreshSetPasswordLink_MonitorsRefreshSetPasswordLink() [Ignore("Only validating compilation of examples")] public async Task SetDefaultKey_MonitorsSetDefaultKey() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/ApiKeys_SetDefaultKey.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/ApiKeys_SetDefaultKey.json // this example is just showing the usage of "Monitors_SetDefaultKey" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -303,8 +303,7 @@ public async Task SetDefaultKey_MonitorsSetDefaultKey() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogApiKeyContent content = new DatadogApiKeyContent("1111111111111111aaaaaaaaaaaaaaaa"); - await datadogMonitorResource.SetDefaultKeyAsync(content: content); + await datadogMonitorResource.SetDefaultKeyAsync(); Console.WriteLine("Succeeded"); } @@ -313,7 +312,7 @@ public async Task SetDefaultKey_MonitorsSetDefaultKey() [Ignore("Only validating compilation of examples")] public async Task GetBillingInfo_BillingInfoGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/BillingInfo_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/BillingInfo_Get.json // this example is just showing the usage of "BillingInfo_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -334,5 +333,42 @@ public async Task GetBillingInfo_BillingInfoGet() Console.WriteLine($"Succeeded: {result}"); } + + [Test] + [Ignore("Only validating compilation of examples")] + public async Task ResubscribeOrganization_OrganizationsResubscribe() + { + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Organizations_Resubscribe.json + // this example is just showing the usage of "Organizations_Resubscribe" operation, for the dependent resources, they will have to be created separately. + + // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line + TokenCredential cred = new DefaultAzureCredential(); + // authenticate your client + ArmClient client = new ArmClient(cred); + + // this example assumes you already have this DatadogMonitorResource created on azure + // for more information of creating DatadogMonitorResource, please refer to the document of DatadogMonitorResource + string subscriptionId = "00000000-0000-0000-0000-000000000000"; + string resourceGroupName = "myResourceGroup"; + string monitorName = "myMonitor"; + ResourceIdentifier datadogMonitorResourceId = DatadogMonitorResource.CreateResourceIdentifier(subscriptionId, resourceGroupName, monitorName); + DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); + + // invoke the operation + DataDogResubscribeProperties body = new DataDogResubscribeProperties + { + SkuName = "planName", + AzureSubscriptionId = new ResourceIdentifier("subscriptionId"), + ResourceGroup = "resourceGroup", + }; + ArmOperation lro = await datadogMonitorResource.ResubscribeOrganizationAsync(WaitUntil.Completed, body: body); + DatadogMonitorResource result = lro.Value; + + // the variable result is a resource, you could call other operations on this instance as well + // but just for demo, we get its data from this resource instance + DatadogMonitorResourceData resourceData = result.Data; + // for demo we just print out the id + Console.WriteLine($"Succeeded on id: {resourceData.Id}"); + } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs index 28441d57f363..6978728bf008 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResourceCollection.cs @@ -21,7 +21,7 @@ public partial class Sample_DatadogMonitorResourceCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_MonitorsCreate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Create.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_Create.json // this example is just showing the usage of "Monitors_Create" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -54,6 +54,7 @@ public async Task CreateOrUpdate_MonitorsCreate() LinkingClientId = "00000000-0000-0000-0000-000000000000", EnterpriseAppId = "00000000-0000-0000-0000-000000000000", IsCspm = false, + IsResourceCollection = false, }, UserInfo = new UserInfo { @@ -82,7 +83,7 @@ public async Task CreateOrUpdate_MonitorsCreate() [Ignore("Only validating compilation of examples")] public async Task Get_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -115,7 +116,7 @@ public async Task Get_MonitorsGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_MonitorsListByResourceGroup() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_ListByResourceGroup.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_ListByResourceGroup.json // this example is just showing the usage of "Monitors_ListByResourceGroup" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -150,7 +151,7 @@ public async Task GetAll_MonitorsListByResourceGroup() [Ignore("Only validating compilation of examples")] public async Task Exists_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -179,7 +180,7 @@ public async Task Exists_MonitorsGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_MonitorsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_Get.json // this example is just showing the usage of "Monitors_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs index ed17f56c8320..c6b1efae1356 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResource.cs @@ -20,7 +20,7 @@ public partial class Sample_DatadogSingleSignOnResource [Ignore("Only validating compilation of examples")] public async Task Get_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_SingleSignOnConfigurationsGet() [Ignore("Only validating compilation of examples")] public async Task Update_SingleSignOnConfigurationsCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/SingleSignOnConfigurations_CreateOrUpdate.json // this example is just showing the usage of "SingleSignOnConfigurations_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs index 96d6c99615e7..a4ebcff13eeb 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogSingleSignOnResourceCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_DatadogSingleSignOnResourceCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_SingleSignOnConfigurationsCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/SingleSignOnConfigurations_CreateOrUpdate.json // this example is just showing the usage of "SingleSignOnConfigurations_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -63,7 +63,7 @@ public async Task CreateOrUpdate_SingleSignOnConfigurationsCreateOrUpdate() [Ignore("Only validating compilation of examples")] public async Task Get_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -97,7 +97,7 @@ public async Task Get_SingleSignOnConfigurationsGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_SingleSignOnConfigurationsList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/SingleSignOnConfigurations_List.json // this example is just showing the usage of "SingleSignOnConfigurations_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -133,7 +133,7 @@ public async Task GetAll_SingleSignOnConfigurationsList() [Ignore("Only validating compilation of examples")] public async Task Exists_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -163,7 +163,7 @@ public async Task Exists_SingleSignOnConfigurationsGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_SingleSignOnConfigurationsGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/SingleSignOnConfigurations_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/SingleSignOnConfigurations_Get.json // this example is just showing the usage of "SingleSignOnConfigurations_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs index a98a867dc55a..b98a10b8d13a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_MonitoredSubscriptionPropertyCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_CreateorUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_CreateorUpdate.json // this example is just showing the usage of "MonitoredSubscriptions_CreateorUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -115,7 +115,7 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() [Ignore("Only validating compilation of examples")] public async Task Get_MonitorsGetMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_Get.json // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -149,7 +149,7 @@ public async Task Get_MonitorsGetMonitoredSubscriptions() [Ignore("Only validating compilation of examples")] public async Task GetAll_MonitorsGetMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_List.json // this example is just showing the usage of "MonitoredSubscriptions_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -185,7 +185,7 @@ public async Task GetAll_MonitorsGetMonitoredSubscriptions() [Ignore("Only validating compilation of examples")] public async Task Exists_MonitorsGetMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_Get.json // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -215,7 +215,7 @@ public async Task Exists_MonitorsGetMonitoredSubscriptions() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_MonitorsGetMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_Get.json // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs index ddc30b5608d0..b456a08630ca 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs @@ -20,7 +20,7 @@ public partial class Sample_MonitoredSubscriptionPropertyResource [Ignore("Only validating compilation of examples")] public async Task Get_MonitorsGetMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_Get.json // this example is just showing the usage of "MonitoredSubscriptions_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_MonitorsGetMonitoredSubscriptions() [Ignore("Only validating compilation of examples")] public async Task Delete_MonitorsDeleteMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Delete.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_Delete.json // this example is just showing the usage of "MonitoredSubscriptions_Delete" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -78,7 +78,7 @@ public async Task Delete_MonitorsDeleteMonitoredSubscriptions() [Ignore("Only validating compilation of examples")] public async Task Update_MonitorsUpdateMonitoredSubscriptions() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MonitoredSubscriptions_Update.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MonitoredSubscriptions_Update.json // this example is just showing the usage of "MonitoredSubscriptions_Update" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs index 23c29a697689..5deb34d95b80 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs @@ -20,7 +20,7 @@ public partial class Sample_MonitoringTagRuleCollection [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdate_TagRulesCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/TagRules_CreateOrUpdate.json // this example is just showing the usage of "TagRules_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -80,7 +80,7 @@ public async Task CreateOrUpdate_TagRulesCreateOrUpdate() [Ignore("Only validating compilation of examples")] public async Task Get_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -114,7 +114,7 @@ public async Task Get_TagRulesGet() [Ignore("Only validating compilation of examples")] public async Task GetAll_TagRulesList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/TagRules_List.json // this example is just showing the usage of "TagRules_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -150,7 +150,7 @@ public async Task GetAll_TagRulesList() [Ignore("Only validating compilation of examples")] public async Task Exists_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -180,7 +180,7 @@ public async Task Exists_TagRulesGet() [Ignore("Only validating compilation of examples")] public async Task GetIfExists_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs index 7fdbce7c8419..369e0e81edda 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs @@ -20,7 +20,7 @@ public partial class Sample_MonitoringTagRuleResource [Ignore("Only validating compilation of examples")] public async Task Get_TagRulesGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/TagRules_Get.json // this example is just showing the usage of "TagRules_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -51,7 +51,7 @@ public async Task Get_TagRulesGet() [Ignore("Only validating compilation of examples")] public async Task Update_TagRulesCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/TagRules_CreateOrUpdate.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/TagRules_CreateOrUpdate.json // this example is just showing the usage of "TagRules_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs index 3b7e5d728376..4624738603f8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs @@ -21,7 +21,7 @@ public partial class Sample_SubscriptionResourceExtensions [Ignore("Only validating compilation of examples")] public async Task GetMarketplaceAgreements_MarketplaceAgreementsList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MarketplaceAgreements_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MarketplaceAgreements_List.json // this example is just showing the usage of "MarketplaceAgreements_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -48,7 +48,7 @@ public async Task GetMarketplaceAgreements_MarketplaceAgreementsList() [Ignore("Only validating compilation of examples")] public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreateOrUpdate() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/MarketplaceAgreements_Create.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/MarketplaceAgreements_Create.json // this example is just showing the usage of "MarketplaceAgreements_CreateOrUpdate" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -79,7 +79,7 @@ public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreate [Ignore("Only validating compilation of examples")] public async Task GetDatadogMonitorResources_MonitorsList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/Monitors_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/Monitors_List.json // this example is just showing the usage of "Monitors_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -110,7 +110,7 @@ public async Task GetDatadogMonitorResources_MonitorsList() [Ignore("Only validating compilation of examples")] public async Task GetCreationSupporteds_CreationSupportedList() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/CreationSupported_List.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/CreationSupported_List.json // this example is just showing the usage of "CreationSupported_List" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line @@ -138,7 +138,7 @@ public async Task GetCreationSupporteds_CreationSupportedList() [Ignore("Only validating compilation of examples")] public async Task GetCreationSupported_CreationSupportedGet() { - // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2023-10-20/examples/CreationSupported_Get.json + // Generated from example definition: specification/datadog/resource-manager/Microsoft.Datadog/stable/2025-06-11/examples/CreationSupported_Get.json // this example is just showing the usage of "CreationSupported_Get" operation, for the dependent resources, they will have to be created separately. // get your azure access token, for more details of how Azure SDK get your access token, please refer to https://learn.microsoft.com/en-us/dotnet/azure/sdk/authentication?tabs=command-line From d2a25314bb2e0983e2b8b1a66aef4b740f05b97b Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Tue, 23 Sep 2025 15:54:11 +0800 Subject: [PATCH 5/7] renaming --- .../Azure.ResourceManager.Datadog.net8.0.cs | 222 +++++++++--------- ....ResourceManager.Datadog.netstandard2.0.cs | 222 +++++++++--------- .../src/Azure.ResourceManager.Datadog.csproj | 3 + .../src/Generated/ArmDatadogModelFactory.cs | 38 +-- .../src/Generated/DatadogMonitorResource.cs | 40 ++-- .../Generated/Extensions/DatadogExtensions.cs | 28 +-- .../MockableDatadogSubscriptionResource.cs | 32 +-- .../AzureResourceManagerDatadogContext.cs | 22 +- ...sourceSupportedResultList.Serialization.cs | 6 +- .../CreateResourceSupportedResultList.cs | 6 +- ....cs => DataDogLinkedInfo.Serialization.cs} | 46 ++-- .../{LinkedInfo.cs => DataDogLinkedInfo.cs} | 12 +- .../Generated/Models/DataDogOperationData.cs | 60 +++++ ... DataDogSubscriptionList.Serialization.cs} | 42 ++-- ...tionList.cs => DataDogSubscriptionList.cs} | 12 +- ...gAgreementResourceContent.Serialization.cs | 38 +-- .../Models/DatadogAgreementResourceContent.cs | 12 +- ...reementResourceListResult.Serialization.cs | 44 ++-- .../DatadogAgreementResourceListResult.cs | 16 +- .../DatadogApiKeyContent.Serialization.cs | 38 +-- .../Generated/Models/DatadogApiKeyContent.cs | 16 +- .../DatadogApiKeyListResult.Serialization.cs | 44 ++-- .../Models/DatadogApiKeyListResult.cs | 16 +- .../DatadogBillingInfoResult.Serialization.cs | 38 +-- .../Models/DatadogBillingInfoResult.cs | 10 +- ...teResourceSupportedResult.Serialization.cs | 38 +-- .../DatadogCreateResourceSupportedResult.cs | 10 +- .../DatadogHostListResult.Serialization.cs | 38 +-- .../Generated/Models/DatadogHostListResult.cs | 14 +- ...MonitorResourceListResult.Serialization.cs | 38 +-- .../DatadogMonitorResourceListResult.cs | 14 +- ...eSignOnResourceListResult.Serialization.cs | 38 +-- .../DatadogSingleSignOnResourceListResult.cs | 14 +- .../LinkedResourceListResult.Serialization.cs | 6 +- .../Models/LinkedResourceListResult.cs | 6 +- .../MarketplaceSaaSInfo.Serialization.cs | 20 +- .../Generated/Models/MarketplaceSaaSInfo.cs | 6 +- .../MonitoredResourceContent.Serialization.cs | 8 +- .../Models/MonitoredResourceContent.cs | 5 +- .../MonitoredSubscription.Serialization.cs | 10 +- .../Generated/Models/MonitoredSubscription.cs | 4 +- .../src/Generated/Models/OperationData.cs | 60 ----- ...dSubscriptionPropertyData.Serialization.cs | 4 +- .../MonitoredSubscriptionPropertyData.cs | 4 +- .../BillingInfoRestOperations.cs | 12 +- .../CreationSupportedRestOperations.cs | 12 +- .../MarketplaceAgreementsRestOperations.cs | 40 ++-- .../RestOperations/MonitorsRestOperations.cs | 120 +++++----- ...ingleSignOnConfigurationsRestOperations.cs | 24 +- .../src/autorest.md | 34 +-- .../Samples/Sample_DatadogMonitorResource.cs | 8 +- ...MonitoredSubscriptionPropertyCollection.cs | 8 +- ...e_MonitoredSubscriptionPropertyResource.cs | 8 +- .../Sample_SubscriptionResourceExtensions.cs | 10 +- 54 files changed, 853 insertions(+), 823 deletions(-) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{LinkedInfo.Serialization.cs => DataDogLinkedInfo.Serialization.cs} (65%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{LinkedInfo.cs => DataDogLinkedInfo.cs} (83%) create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogOperationData.cs rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{SubscriptionList.Serialization.cs => DataDogSubscriptionList.Serialization.cs} (68%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{SubscriptionList.cs => DataDogSubscriptionList.cs} (82%) delete mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/OperationData.cs diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs index b1d3d8169a35..7515b46700f5 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs @@ -8,12 +8,12 @@ internal AzureResourceManagerDatadogContext() { } } public static partial class DatadogExtensions { - public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Response GetDatadogMonitorResource(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetDatadogMonitorResourceAsync(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -21,8 +21,8 @@ public static partial class DatadogExtensions public static Azure.Pageable GetDatadogMonitorResources(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetDatadogMonitorResourcesAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } - public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } @@ -38,20 +38,20 @@ protected DatadogMonitorResource() { } public virtual Azure.ResourceManager.ArmOperation Delete(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task DeleteAsync(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetDatadogSingleSignOnResource(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetDatadogSingleSignOnResourceAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResources() { throw null; } - public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetHosts(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionProperties() { throw null; } @@ -66,8 +66,8 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> RemoveTagAsync(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.ArmOperation ResubscribeOrganization(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> ResubscribeOrganizationAsync(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DataDogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DataDogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetTags(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> SetTagsAsync(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } Azure.ResourceManager.Datadog.DatadogMonitorResourceData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -173,7 +173,7 @@ protected MonitoredSubscriptionPropertyCollection() { } public partial class MonitoredSubscriptionPropertyData : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoredSubscriptionPropertyData() { } - public Azure.ResourceManager.Datadog.Models.SubscriptionList Properties { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList Properties { get { throw null; } set { } } protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData 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) { } @@ -266,16 +266,16 @@ protected MockableDatadogResourceGroupResource() { } public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager.ArmResource { protected MockableDatadogSubscriptionResource() { } - public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } } namespace Azure.ResourceManager.Datadog.Models @@ -283,20 +283,20 @@ namespace Azure.ResourceManager.Datadog.Models public static partial class ArmDatadogModelFactory { public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? isCreationSupported = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent DatadogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult DatadogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult DatadogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent DataDogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogBillingInfoResult DataDogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogCreateResourceSupportedResult DataDogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogLinkedInfo DataDogLinkedInfo(Azure.Core.ResourceIdentifier id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, string skuName = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSetPasswordLink DatadogSetPasswordLink(string setPasswordLink = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.LinkedInfo LinkedInfo(string id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? isSubscribed = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } - public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(System.Guid? marketplaceSubscriptionId = default(System.Guid?), string marketplaceName = null, string marketplaceStatus = null, System.Guid? billedAzureSubscriptionId = default(System.Guid?), bool? isSubscribed = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(Azure.Core.ResourceIdentifier id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } + public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, Azure.ResourceManager.Datadog.Models.DataDogAgentRules agentRules = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } @@ -344,53 +344,53 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogAgreementResourceContent() { } + public DataDogAgreementResourceContent() { } public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent 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.Datadog.Models.DatadogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent 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.Datadog.Models.DataDogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogApiKeyContent(string key) { } + public DataDogApiKeyContent(string key) { } public string Created { get { throw null; } set { } } public string CreatedBy { get { throw null; } set { } } public string Key { 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.Datadog.Models.DatadogApiKeyContent 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.Datadog.Models.DatadogApiKeyContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogApiKeyContent 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.Datadog.Models.DataDogApiKeyContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogBillingInfoResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogBillingInfoResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogBillingInfoResult() { } + internal DataDogBillingInfoResult() { } public Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaasInfo { get { throw null; } } public Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult 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.Datadog.Models.DatadogBillingInfoResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogBillingInfoResult 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.Datadog.Models.DataDogBillingInfoResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogCreateResourceSupportedResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogCreateResourceSupportedResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogCreateResourceSupportedResult() { } + internal DataDogCreateResourceSupportedResult() { } public Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties Properties { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult 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.Datadog.Models.DatadogCreateResourceSupportedResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogCreateResourceSupportedResult 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.Datadog.Models.DataDogCreateResourceSupportedResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } public partial class DatadogHost : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { @@ -432,6 +432,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogLinkedInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DataDogLinkedInfo() { } + public Azure.Core.ResourceIdentifier Id { get { throw null; } } + public Azure.Core.AzureLocation? Location { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogLinkedInfo 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.Datadog.Models.DataDogLinkedInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogMonitorResourcePatch : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogMonitorResourcePatch() { } @@ -445,6 +457,27 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct DataDogOperationData : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public DataDogOperationData(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData AddBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData AddComplete { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData DeleteBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData DeleteComplete { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.DataDogOperationData other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.DataDogOperationData left, Azure.ResourceManager.Datadog.Models.DataDogOperationData right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.DataDogOperationData (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.DataDogOperationData left, Azure.ResourceManager.Datadog.Models.DataDogOperationData right) { throw null; } + public override string ToString() { throw null; } + } public partial class DatadogOrganizationProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogOrganizationProperties() { } @@ -503,6 +536,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogSubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogSubscriptionList() { } + public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } + public Azure.ResourceManager.Datadog.Models.DataDogOperationData? Operation { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList 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.Datadog.Models.DataDogSubscriptionList System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class FilteringTag : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public FilteringTag() { } @@ -534,18 +579,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory left, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory right) { throw null; } public override string ToString() { throw null; } } - public partial class LinkedInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - internal LinkedInfo() { } - public string Id { get { throw null; } } - public Azure.Core.AzureLocation? Location { get { throw null; } } - protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.LinkedInfo 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.Datadog.Models.LinkedInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } public partial class LogRules : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public LogRules() { } @@ -563,11 +596,11 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MarketplaceSaaSInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal MarketplaceSaaSInfo() { } - public string BilledAzureSubscriptionId { get { throw null; } } + public System.Guid? BilledAzureSubscriptionId { get { throw null; } } public bool? IsSubscribed { get { throw null; } } public string MarketplaceName { get { throw null; } } public string MarketplaceStatus { get { throw null; } } - public string MarketplaceSubscriptionId { get { throw null; } } + public System.Guid? MarketplaceSubscriptionId { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo 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) { } @@ -598,7 +631,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoredResourceContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal MonitoredResourceContent() { } - public string Id { get { throw null; } } + public Azure.Core.ResourceIdentifier Id { get { throw null; } } public bool? IsSendingLogs { get { throw null; } } public bool? IsSendingMetrics { get { throw null; } } public string ReasonForLogsStatus { get { throw null; } } @@ -635,7 +668,7 @@ public partial class MonitoredSubscription : System.ClientModel.Primitives.IJson public MonitoredSubscription() { } public string Error { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoredStatus? Status { get { throw null; } set { } } - public string SubscriptionId { get { throw null; } set { } } + public System.Guid? SubscriptionId { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitoredSubscription System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -708,27 +741,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct OperationData : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public OperationData(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.OperationData Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData AddBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData AddComplete { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData DeleteBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData DeleteComplete { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.OperationData other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.OperationData (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } - public override string ToString() { throw null; } - } public partial class PartnerBillingEntity : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal PartnerBillingEntity() { } @@ -787,18 +799,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.SingleSignOnState left, Azure.ResourceManager.Datadog.Models.SingleSignOnState right) { throw null; } public override string ToString() { throw null; } } - public partial class SubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - public SubscriptionList() { } - public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } - public Azure.ResourceManager.Datadog.Models.OperationData? Operation { get { throw null; } set { } } - protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.SubscriptionList 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.Datadog.Models.SubscriptionList System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct TagAction : System.IEquatable { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs index b1d3d8169a35..7515b46700f5 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs @@ -8,12 +8,12 @@ internal AzureResourceManagerDatadogContext() { } } public static partial class DatadogExtensions { - public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetCreationSupportedsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResource GetDatadogMonitorResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.Response GetDatadogMonitorResource(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetDatadogMonitorResourceAsync(this Azure.ResourceManager.Resources.ResourceGroupResource resourceGroupResource, string monitorName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -21,8 +21,8 @@ public static partial class DatadogExtensions public static Azure.Pageable GetDatadogMonitorResources(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetDatadogMonitorResourcesAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } - public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } @@ -38,20 +38,20 @@ protected DatadogMonitorResource() { } public virtual Azure.ResourceManager.ArmOperation Delete(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task DeleteAsync(Azure.WaitUntil waitUntil, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response Get(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetApiKeys(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetApiKeysAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetBillingInfo(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetBillingInfoAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetDatadogSingleSignOnResource(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetDatadogSingleSignOnResourceAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceCollection GetDatadogSingleSignOnResources() { throw null; } - public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetDefaultKey(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetDefaultKeyAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetHosts(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionProperties() { throw null; } @@ -66,8 +66,8 @@ protected DatadogMonitorResource() { } public virtual System.Threading.Tasks.Task> RemoveTagAsync(string key, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.ArmOperation ResubscribeOrganization(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> ResubscribeOrganizationAsync(Azure.WaitUntil waitUntil, Azure.ResourceManager.Datadog.Models.DataDogResubscribeProperties body = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DatadogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response SetDefaultKey(Azure.ResourceManager.Datadog.Models.DataDogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task SetDefaultKeyAsync(Azure.ResourceManager.Datadog.Models.DataDogApiKeyContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response SetTags(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> SetTagsAsync(System.Collections.Generic.IDictionary tags, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } Azure.ResourceManager.Datadog.DatadogMonitorResourceData System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -173,7 +173,7 @@ protected MonitoredSubscriptionPropertyCollection() { } public partial class MonitoredSubscriptionPropertyData : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoredSubscriptionPropertyData() { } - public Azure.ResourceManager.Datadog.Models.SubscriptionList Properties { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList Properties { get { throw null; } set { } } protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData 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) { } @@ -266,16 +266,16 @@ protected MockableDatadogResourceGroupResource() { } public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager.ArmResource { protected MockableDatadogSubscriptionResource() { } - public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } } namespace Azure.ResourceManager.Datadog.Models @@ -283,20 +283,20 @@ namespace Azure.ResourceManager.Datadog.Models public static partial class ArmDatadogModelFactory { public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? isCreationSupported = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent DatadogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult DatadogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult DatadogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent DataDogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogBillingInfoResult DataDogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogCreateResourceSupportedResult DataDogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogLinkedInfo DataDogLinkedInfo(Azure.Core.ResourceIdentifier id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, string skuName = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSetPasswordLink DatadogSetPasswordLink(string setPasswordLink = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } - public static Azure.ResourceManager.Datadog.Models.LinkedInfo LinkedInfo(string id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? isSubscribed = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } - public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.SubscriptionList properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(System.Guid? marketplaceSubscriptionId = default(System.Guid?), string marketplaceName = null, string marketplaceStatus = null, System.Guid? billedAzureSubscriptionId = default(System.Guid?), bool? isSubscribed = default(bool?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(Azure.Core.ResourceIdentifier id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } + public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, Azure.ResourceManager.Datadog.Models.DataDogAgentRules agentRules = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitorProperties MonitorProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.MonitoringStatus? monitoringStatus = default(Azure.ResourceManager.Datadog.Models.MonitoringStatus?), Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus? marketplaceSubscriptionStatus = default(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus?), Azure.ResourceManager.Datadog.Models.DatadogOrganizationProperties datadogOrganizationProperties = null, Azure.ResourceManager.Datadog.Models.UserInfo userInfo = null, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory? liftrResourceCategory = default(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory?), int? liftrResourcePreference = default(int?)) { throw null; } @@ -344,53 +344,53 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogAgreementResourceContent() { } + public DataDogAgreementResourceContent() { } public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogAgreementResourceContent 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.Datadog.Models.DatadogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent 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.Datadog.Models.DataDogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - public DatadogApiKeyContent(string key) { } + public DataDogApiKeyContent(string key) { } public string Created { get { throw null; } set { } } public string CreatedBy { get { throw null; } set { } } public string Key { 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.Datadog.Models.DatadogApiKeyContent 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.Datadog.Models.DatadogApiKeyContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogApiKeyContent 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.Datadog.Models.DataDogApiKeyContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogBillingInfoResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogBillingInfoResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogBillingInfoResult() { } + internal DataDogBillingInfoResult() { } public Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaasInfo { get { throw null; } } public Azure.ResourceManager.Datadog.Models.PartnerBillingEntity PartnerBillingEntity { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogBillingInfoResult 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.Datadog.Models.DatadogBillingInfoResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogBillingInfoResult 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.Datadog.Models.DataDogBillingInfoResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DatadogCreateResourceSupportedResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + public partial class DataDogCreateResourceSupportedResult : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { - internal DatadogCreateResourceSupportedResult() { } + internal DataDogCreateResourceSupportedResult() { } public Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties Properties { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DatadogCreateResourceSupportedResult 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.Datadog.Models.DatadogCreateResourceSupportedResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + Azure.ResourceManager.Datadog.Models.DataDogCreateResourceSupportedResult 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.Datadog.Models.DataDogCreateResourceSupportedResult System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } public partial class DatadogHost : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { @@ -432,6 +432,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogLinkedInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DataDogLinkedInfo() { } + public Azure.Core.ResourceIdentifier Id { get { throw null; } } + public Azure.Core.AzureLocation? Location { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogLinkedInfo 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.Datadog.Models.DataDogLinkedInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogMonitorResourcePatch : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogMonitorResourcePatch() { } @@ -445,6 +457,27 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct DataDogOperationData : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public DataDogOperationData(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData AddBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData AddComplete { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData DeleteBegin { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogOperationData DeleteComplete { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.DataDogOperationData other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.DataDogOperationData left, Azure.ResourceManager.Datadog.Models.DataDogOperationData right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.DataDogOperationData (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.DataDogOperationData left, Azure.ResourceManager.Datadog.Models.DataDogOperationData right) { throw null; } + public override string ToString() { throw null; } + } public partial class DatadogOrganizationProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogOrganizationProperties() { } @@ -503,6 +536,18 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogSubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogSubscriptionList() { } + public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } + public Azure.ResourceManager.Datadog.Models.DataDogOperationData? Operation { get { throw null; } set { } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList 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.Datadog.Models.DataDogSubscriptionList System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class FilteringTag : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public FilteringTag() { } @@ -534,18 +579,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.LiftrResourceCategory left, Azure.ResourceManager.Datadog.Models.LiftrResourceCategory right) { throw null; } public override string ToString() { throw null; } } - public partial class LinkedInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - internal LinkedInfo() { } - public string Id { get { throw null; } } - public Azure.Core.AzureLocation? Location { get { throw null; } } - protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.LinkedInfo 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.Datadog.Models.LinkedInfo System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } public partial class LogRules : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public LogRules() { } @@ -563,11 +596,11 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MarketplaceSaaSInfo : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal MarketplaceSaaSInfo() { } - public string BilledAzureSubscriptionId { get { throw null; } } + public System.Guid? BilledAzureSubscriptionId { get { throw null; } } public bool? IsSubscribed { get { throw null; } } public string MarketplaceName { get { throw null; } } public string MarketplaceStatus { get { throw null; } } - public string MarketplaceSubscriptionId { get { throw null; } } + public System.Guid? MarketplaceSubscriptionId { get { throw null; } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo 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) { } @@ -598,7 +631,7 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public partial class MonitoredResourceContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal MonitoredResourceContent() { } - public string Id { get { throw null; } } + public Azure.Core.ResourceIdentifier Id { get { throw null; } } public bool? IsSendingLogs { get { throw null; } } public bool? IsSendingMetrics { get { throw null; } } public string ReasonForLogsStatus { get { throw null; } } @@ -635,7 +668,7 @@ public partial class MonitoredSubscription : System.ClientModel.Primitives.IJson public MonitoredSubscription() { } public string Error { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoredStatus? Status { get { throw null; } set { } } - public string SubscriptionId { get { throw null; } set { } } + public System.Guid? SubscriptionId { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.MonitoredSubscription System.ClientModel.Primitives.IJsonModel.Create(ref System.Text.Json.Utf8JsonReader reader, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } @@ -708,27 +741,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct OperationData : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public OperationData(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.OperationData Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData AddBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData AddComplete { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData DeleteBegin { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.OperationData DeleteComplete { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.OperationData other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.OperationData (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.OperationData left, Azure.ResourceManager.Datadog.Models.OperationData right) { throw null; } - public override string ToString() { throw null; } - } public partial class PartnerBillingEntity : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { internal PartnerBillingEntity() { } @@ -787,18 +799,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.SingleSignOnState left, Azure.ResourceManager.Datadog.Models.SingleSignOnState right) { throw null; } public override string ToString() { throw null; } } - public partial class SubscriptionList : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - public SubscriptionList() { } - public System.Collections.Generic.IList MonitoredSubscriptionList { get { throw null; } } - public Azure.ResourceManager.Datadog.Models.OperationData? Operation { get { throw null; } set { } } - protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.SubscriptionList 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.Datadog.Models.SubscriptionList System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] public readonly partial struct TagAction : System.IEquatable { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Azure.ResourceManager.Datadog.csproj b/sdk/datadog/Azure.ResourceManager.Datadog/src/Azure.ResourceManager.Datadog.csproj index 667e35371636..4808704f744d 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Azure.ResourceManager.Datadog.csproj +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Azure.ResourceManager.Datadog.csproj @@ -5,4 +5,7 @@ Microsoft Azure Resource Manager client SDK for Azure resource provider Microsoft.Datadog. azure;management;arm;resource manager;datadog + + + diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs index 0dd53ccef953..68df54ec62bd 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs @@ -16,16 +16,16 @@ namespace Azure.ResourceManager.Datadog.Models /// Model factory for models. public static partial class ArmDatadogModelFactory { - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. /// Represents the properties of the resource. - /// A new instance for mocking. - public static DatadogAgreementResourceContent DatadogAgreementResourceContent(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogAgreementProperties properties = null) + /// A new instance for mocking. + public static DataDogAgreementResourceContent DataDogAgreementResourceContent(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogAgreementProperties properties = null) { - return new DatadogAgreementResourceContent( + return new DataDogAgreementResourceContent( id, name, resourceType, @@ -84,12 +84,12 @@ public static MonitorProperties MonitorProperties(ProvisioningState? provisionin serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Represents the properties of the resource. - /// A new instance for mocking. - public static DatadogCreateResourceSupportedResult DatadogCreateResourceSupportedResult(CreateResourceSupportedProperties properties = null) + /// A new instance for mocking. + public static DataDogCreateResourceSupportedResult DataDogCreateResourceSupportedResult(CreateResourceSupportedProperties properties = null) { - return new DatadogCreateResourceSupportedResult(properties, serializedAdditionalRawData: null); + return new DataDogCreateResourceSupportedResult(properties, serializedAdditionalRawData: null); } /// Initializes a new instance of . @@ -101,13 +101,13 @@ public static CreateResourceSupportedProperties CreateResourceSupportedPropertie return new CreateResourceSupportedProperties(name, isCreationSupported, serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Marketplace Subscription details. /// Partner Billing Entity details: Organization Info. - /// A new instance for mocking. - public static DatadogBillingInfoResult DatadogBillingInfoResult(MarketplaceSaaSInfo marketplaceSaasInfo = null, PartnerBillingEntity partnerBillingEntity = null) + /// A new instance for mocking. + public static DataDogBillingInfoResult DataDogBillingInfoResult(MarketplaceSaaSInfo marketplaceSaasInfo = null, PartnerBillingEntity partnerBillingEntity = null) { - return new DatadogBillingInfoResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData: null); + return new DataDogBillingInfoResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData: null); } /// Initializes a new instance of . @@ -117,7 +117,7 @@ public static DatadogBillingInfoResult DatadogBillingInfoResult(MarketplaceSaaSI /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. /// Flag specifying if the Marketplace status is subscribed or not. /// A new instance for mocking. - public static MarketplaceSaaSInfo MarketplaceSaaSInfo(string marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, string billedAzureSubscriptionId = null, bool? isSubscribed = null) + public static MarketplaceSaaSInfo MarketplaceSaaSInfo(Guid? marketplaceSubscriptionId = null, string marketplaceName = null, string marketplaceStatus = null, Guid? billedAzureSubscriptionId = null, bool? isSubscribed = null) { return new MarketplaceSaaSInfo( marketplaceSubscriptionId, @@ -172,13 +172,13 @@ public static DatadogInstallMethod DatadogInstallMethod(string tool = null, stri return new DatadogInstallMethod(tool, toolVersion, installerVersion, serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The ARM id of the linked resource. /// The location of the linked resource. - /// A new instance for mocking. - public static LinkedInfo LinkedInfo(string id = null, AzureLocation? location = null) + /// A new instance for mocking. + public static DataDogLinkedInfo DataDogLinkedInfo(ResourceIdentifier id = null, AzureLocation? location = null) { - return new LinkedInfo(id, location, serializedAdditionalRawData: null); + return new DataDogLinkedInfo(id, location, serializedAdditionalRawData: null); } /// Initializes a new instance of . @@ -188,7 +188,7 @@ public static LinkedInfo LinkedInfo(string id = null, AzureLocation? location = /// Flag indicating if resource is sending logs to Datadog. /// Reason for why the resource is sending logs (or why it is not sending). /// A new instance for mocking. - public static MonitoredResourceContent MonitoredResourceContent(string id = null, bool? isSendingMetrics = null, string reasonForMetricsStatus = null, bool? isSendingLogs = null, string reasonForLogsStatus = null) + public static MonitoredResourceContent MonitoredResourceContent(ResourceIdentifier id = null, bool? isSendingMetrics = null, string reasonForMetricsStatus = null, bool? isSendingLogs = null, string reasonForLogsStatus = null) { return new MonitoredResourceContent( id, @@ -206,7 +206,7 @@ public static MonitoredResourceContent MonitoredResourceContent(string id = null /// The systemData. /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. /// A new instance for mocking. - public static MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, SubscriptionList properties = null) + public static MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DataDogSubscriptionList properties = null) { return new MonitoredSubscriptionPropertyData( id, diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs index d40caf6c39ca..a3429a6e537f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs @@ -584,7 +584,7 @@ public virtual ArmOperation Update(WaitUntil waitUntil, /// /// /// The cancellation token to use. - public virtual async Task> GetDefaultKeyAsync(CancellationToken cancellationToken = default) + public virtual async Task> GetDefaultKeyAsync(CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.GetDefaultKey"); scope.Start(); @@ -622,7 +622,7 @@ public virtual async Task> GetDefaultKeyAsync(Can /// /// /// The cancellation token to use. - public virtual Response GetDefaultKey(CancellationToken cancellationToken = default) + public virtual Response GetDefaultKey(CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.GetDefaultKey"); scope.Start(); @@ -660,12 +660,12 @@ public virtual Response GetDefaultKey(CancellationToken ca /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetApiKeysAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetApiKeysAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogApiKeyContent.DeserializeDatadogApiKeyContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DataDogApiKeyContent.DeserializeDataDogApiKeyContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); } /// @@ -690,12 +690,12 @@ public virtual AsyncPageable GetApiKeysAsync(CancellationT /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetApiKeys(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetApiKeys(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListApiKeysNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogApiKeyContent.DeserializeDatadogApiKeyContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DataDogApiKeyContent.DeserializeDataDogApiKeyContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetApiKeys", "value", "nextLink", cancellationToken); } /// @@ -780,12 +780,12 @@ public virtual Pageable GetHosts(CancellationToken cancellationToke /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetLinkedResourcesAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetLinkedResourcesAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => LinkedInfo.DeserializeLinkedInfo(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DataDogLinkedInfo.DeserializeDataDogLinkedInfo(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); } /// @@ -810,12 +810,12 @@ public virtual AsyncPageable GetLinkedResourcesAsync(CancellationTok /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetLinkedResources(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetLinkedResources(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListLinkedResourcesNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => LinkedInfo.DeserializeLinkedInfo(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DataDogLinkedInfo.DeserializeDataDogLinkedInfo(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetLinkedResources", "value", "nextLink", cancellationToken); } /// @@ -975,9 +975,9 @@ public virtual Response RefreshSetPasswordLink(Cancellat /// /// /// - /// The to use. + /// The to use. /// The cancellation token to use. - public virtual async Task SetDefaultKeyAsync(DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) + public virtual async Task SetDefaultKeyAsync(DataDogApiKeyContent content = null, CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); scope.Start(); @@ -1014,9 +1014,9 @@ public virtual async Task SetDefaultKeyAsync(DatadogApiKeyContent cont /// /// /// - /// The to use. + /// The to use. /// The cancellation token to use. - public virtual Response SetDefaultKey(DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) + public virtual Response SetDefaultKey(DataDogApiKeyContent content = null, CancellationToken cancellationToken = default) { using var scope = _datadogMonitorResourceMonitorsClientDiagnostics.CreateScope("DatadogMonitorResource.SetDefaultKey"); scope.Start(); @@ -1050,7 +1050,7 @@ public virtual Response SetDefaultKey(DatadogApiKeyContent content = null, Cance /// /// /// The cancellation token to use. - public virtual async Task> GetBillingInfoAsync(CancellationToken cancellationToken = default) + public virtual async Task> GetBillingInfoAsync(CancellationToken cancellationToken = default) { using var scope = _billingInfoClientDiagnostics.CreateScope("DatadogMonitorResource.GetBillingInfo"); scope.Start(); @@ -1084,7 +1084,7 @@ public virtual async Task> GetBillingInfoAsyn /// /// /// The cancellation token to use. - public virtual Response GetBillingInfo(CancellationToken cancellationToken = default) + public virtual Response GetBillingInfo(CancellationToken cancellationToken = default) { using var scope = _billingInfoClientDiagnostics.CreateScope("DatadogMonitorResource.GetBillingInfo"); scope.Start(); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs index 69c3e4c91590..0d0683a9c62f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs @@ -226,8 +226,8 @@ public static Response GetDatadogMonitorResource(this Re /// The instance the method will execute against. /// The cancellation token to use. /// is null. - /// An async collection of that may take multiple service requests to iterate over. - public static AsyncPageable GetMarketplaceAgreementsAsync(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public static AsyncPageable GetMarketplaceAgreementsAsync(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -258,8 +258,8 @@ public static AsyncPageable GetMarketplaceAgree /// The instance the method will execute against. /// The cancellation token to use. /// is null. - /// A collection of that may take multiple service requests to iterate over. - public static Pageable GetMarketplaceAgreements(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public static Pageable GetMarketplaceAgreements(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -284,14 +284,14 @@ public static Pageable GetMarketplaceAgreements /// /// /// Mocking - /// To mock this method, please mock instead. + /// To mock this method, please mock instead. /// /// /// The instance the method will execute against. /// The request body. /// The cancellation token to use. /// is null. - public static async Task> CreateOrUpdateMarketplaceAgreementAsync(this SubscriptionResource subscriptionResource, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public static async Task> CreateOrUpdateMarketplaceAgreementAsync(this SubscriptionResource subscriptionResource, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -316,14 +316,14 @@ public static async Task> CreateOrUpda /// /// /// Mocking - /// To mock this method, please mock instead. + /// To mock this method, please mock instead. /// /// /// The instance the method will execute against. /// The request body. /// The cancellation token to use. /// is null. - public static Response CreateOrUpdateMarketplaceAgreement(this SubscriptionResource subscriptionResource, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public static Response CreateOrUpdateMarketplaceAgreement(this SubscriptionResource subscriptionResource, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -427,8 +427,8 @@ public static Pageable GetDatadogMonitorResources(this S /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - /// An async collection of that may take multiple service requests to iterate over. - public static AsyncPageable GetCreationSupportedsAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public static AsyncPageable GetCreationSupportedsAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -460,8 +460,8 @@ public static AsyncPageable GetCreationSup /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - /// A collection of that may take multiple service requests to iterate over. - public static Pageable GetCreationSupporteds(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public static Pageable GetCreationSupporteds(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -493,7 +493,7 @@ public static Pageable GetCreationSupporte /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - public static async Task> GetCreationSupportedAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + public static async Task> GetCreationSupportedAsync(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -525,7 +525,7 @@ public static async Task> GetCrea /// Datadog Organization Id. /// The cancellation token to use. /// or is null. - public static Response GetCreationSupported(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) + public static Response GetCreationSupported(this SubscriptionResource subscriptionResource, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs index 68b3013ffe30..17de196befe5 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs @@ -68,12 +68,12 @@ private string GetApiVersionOrNull(ResourceType resourceType) /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetMarketplaceAgreementsAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetMarketplaceAgreementsAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => MarketplaceAgreementsRestClient.CreateListRequest(Id.SubscriptionId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => MarketplaceAgreementsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); } /// @@ -94,12 +94,12 @@ public virtual AsyncPageable GetMarketplaceAgre /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetMarketplaceAgreements(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetMarketplaceAgreements(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => MarketplaceAgreementsRestClient.CreateListRequest(Id.SubscriptionId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => MarketplaceAgreementsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); } /// @@ -121,7 +121,7 @@ public virtual Pageable GetMarketplaceAgreement /// /// The request body. /// The cancellation token to use. - public virtual async Task> CreateOrUpdateMarketplaceAgreementAsync(DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public virtual async Task> CreateOrUpdateMarketplaceAgreementAsync(DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { using var scope = MarketplaceAgreementsClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.CreateOrUpdateMarketplaceAgreement"); scope.Start(); @@ -156,7 +156,7 @@ public virtual async Task> CreateOrUpd /// /// The request body. /// The cancellation token to use. - public virtual Response CreateOrUpdateMarketplaceAgreement(DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public virtual Response CreateOrUpdateMarketplaceAgreement(DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { using var scope = MarketplaceAgreementsClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.CreateOrUpdateMarketplaceAgreement"); scope.Start(); @@ -252,14 +252,14 @@ public virtual Pageable GetDatadogMonitorResources(Cance /// Datadog Organization Id. /// The cancellation token to use. /// is null. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); HttpMessage FirstPageRequest(int? pageSizeHint) => CreationSupportedRestClient.CreateListRequest(Id.SubscriptionId, datadogOrganizationId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreationSupportedRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, datadogOrganizationId); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DataDogCreateResourceSupportedResult.DeserializeDataDogCreateResourceSupportedResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); } /// @@ -282,14 +282,14 @@ public virtual AsyncPageable GetCreationSu /// Datadog Organization Id. /// The cancellation token to use. /// is null. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetCreationSupporteds(string datadogOrganizationId, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetCreationSupporteds(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); HttpMessage FirstPageRequest(int? pageSizeHint) => CreationSupportedRestClient.CreateListRequest(Id.SubscriptionId, datadogOrganizationId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreationSupportedRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId, datadogOrganizationId); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DataDogCreateResourceSupportedResult.DeserializeDataDogCreateResourceSupportedResult(e), CreationSupportedClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetCreationSupporteds", "value", "nextLink", cancellationToken); } /// @@ -312,7 +312,7 @@ public virtual Pageable GetCreationSupport /// Datadog Organization Id. /// The cancellation token to use. /// is null. - public virtual async Task> GetCreationSupportedAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) + public virtual async Task> GetCreationSupportedAsync(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -350,7 +350,7 @@ public virtual async Task> GetCre /// Datadog Organization Id. /// The cancellation token to use. /// is null. - public virtual Response GetCreationSupported(string datadogOrganizationId, CancellationToken cancellationToken = default) + public virtual Response GetCreationSupported(string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs index fed1d1739730..ad5f3a1c9a59 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs @@ -19,20 +19,21 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(CreateResourceSupportedResultList))] [ModelReaderWriterBuildable(typeof(DataDogAgentRules))] [ModelReaderWriterBuildable(typeof(DatadogAgreementProperties))] - [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceContent))] - [ModelReaderWriterBuildable(typeof(DatadogAgreementResourceListResult))] - [ModelReaderWriterBuildable(typeof(DatadogApiKeyContent))] - [ModelReaderWriterBuildable(typeof(DatadogApiKeyListResult))] - [ModelReaderWriterBuildable(typeof(DatadogBillingInfoResult))] - [ModelReaderWriterBuildable(typeof(DatadogCreateResourceSupportedResult))] + [ModelReaderWriterBuildable(typeof(DataDogAgreementResourceContent))] + [ModelReaderWriterBuildable(typeof(DataDogAgreementResourceListResult))] + [ModelReaderWriterBuildable(typeof(DataDogApiKeyContent))] + [ModelReaderWriterBuildable(typeof(DataDogApiKeyListResult))] + [ModelReaderWriterBuildable(typeof(DataDogBillingInfoResult))] + [ModelReaderWriterBuildable(typeof(DataDogCreateResourceSupportedResult))] [ModelReaderWriterBuildable(typeof(DatadogHost))] - [ModelReaderWriterBuildable(typeof(DatadogHostListResult))] + [ModelReaderWriterBuildable(typeof(DataDogHostListResult))] [ModelReaderWriterBuildable(typeof(DatadogHostMetadata))] [ModelReaderWriterBuildable(typeof(DatadogInstallMethod))] + [ModelReaderWriterBuildable(typeof(DataDogLinkedInfo))] [ModelReaderWriterBuildable(typeof(DatadogLogsAgent))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResource))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResourceData))] - [ModelReaderWriterBuildable(typeof(DatadogMonitorResourceListResult))] + [ModelReaderWriterBuildable(typeof(DataDogMonitorResourceListResult))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResourcePatch))] [ModelReaderWriterBuildable(typeof(DatadogOrganizationProperties))] [ModelReaderWriterBuildable(typeof(DataDogResubscribeProperties))] @@ -40,9 +41,9 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnProperties))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResource))] [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResourceData))] - [ModelReaderWriterBuildable(typeof(DatadogSingleSignOnResourceListResult))] + [ModelReaderWriterBuildable(typeof(DataDogSingleSignOnResourceListResult))] + [ModelReaderWriterBuildable(typeof(DataDogSubscriptionList))] [ModelReaderWriterBuildable(typeof(FilteringTag))] - [ModelReaderWriterBuildable(typeof(LinkedInfo))] [ModelReaderWriterBuildable(typeof(LinkedResourceListResult))] [ModelReaderWriterBuildable(typeof(LogRules))] [ModelReaderWriterBuildable(typeof(ManagedServiceIdentity))] @@ -63,7 +64,6 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(PartnerBillingEntity))] [ModelReaderWriterBuildable(typeof(ResourceSku))] [ModelReaderWriterBuildable(typeof(ResponseError))] - [ModelReaderWriterBuildable(typeof(SubscriptionList))] [ModelReaderWriterBuildable(typeof(SystemData))] [ModelReaderWriterBuildable(typeof(UserInfo))] public partial class AzureResourceManagerDatadogContext : ModelReaderWriterContext diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.Serialization.cs index 7dc86e56f785..ceaaa7d59316 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.Serialization.cs @@ -83,7 +83,7 @@ internal static CreateResourceSupportedResultList DeserializeCreateResourceSuppo { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static CreateResourceSupportedResultList DeserializeCreateResourceSuppo { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(item, options)); + array.Add(DataDogCreateResourceSupportedResult.DeserializeDataDogCreateResourceSupportedResult(item, options)); } value = array; continue; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.cs index a5367a819dd8..583cf2558b6a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/CreateResourceSupportedResultList.cs @@ -49,7 +49,7 @@ internal partial class CreateResourceSupportedResultList /// Initializes a new instance of . /// The CreateResourceSupportedResponse items on this page. /// is null. - internal CreateResourceSupportedResultList(IEnumerable value) + internal CreateResourceSupportedResultList(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); @@ -60,7 +60,7 @@ internal CreateResourceSupportedResultList(IEnumerable The CreateResourceSupportedResponse items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal CreateResourceSupportedResultList(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal CreateResourceSupportedResultList(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; @@ -73,7 +73,7 @@ internal CreateResourceSupportedResultList() } /// The CreateResourceSupportedResponse items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogLinkedInfo.Serialization.cs similarity index 65% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogLinkedInfo.Serialization.cs index 73547aa1249a..da8f7452649b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogLinkedInfo.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class LinkedInfo : IUtf8JsonSerializable, IJsonModel + public partial class DataDogLinkedInfo : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOption /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(LinkedInfo)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogLinkedInfo)} does not support writing '{format}' format."); } if (Optional.IsDefined(Id)) @@ -61,19 +61,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - LinkedInfo IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogLinkedInfo IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(LinkedInfo)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogLinkedInfo)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeLinkedInfo(document.RootElement, options); + return DeserializeDataDogLinkedInfo(document.RootElement, options); } - internal static LinkedInfo DeserializeLinkedInfo(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogLinkedInfo DeserializeDataDogLinkedInfo(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -81,7 +81,7 @@ internal static LinkedInfo DeserializeLinkedInfo(JsonElement element, ModelReade { return null; } - string id = default; + ResourceIdentifier id = default; AzureLocation? location = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -89,7 +89,11 @@ internal static LinkedInfo DeserializeLinkedInfo(JsonElement element, ModelReade { if (property.NameEquals("id"u8)) { - id = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + id = new ResourceIdentifier(property.Value.GetString()); continue; } if (property.NameEquals("location"u8)) @@ -107,38 +111,38 @@ internal static LinkedInfo DeserializeLinkedInfo(JsonElement element, ModelReade } } serializedAdditionalRawData = rawDataDictionary; - return new LinkedInfo(id, location, serializedAdditionalRawData); + return new DataDogLinkedInfo(id, location, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(LinkedInfo)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogLinkedInfo)} does not support writing '{options.Format}' format."); } } - LinkedInfo IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogLinkedInfo IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeLinkedInfo(document.RootElement, options); + return DeserializeDataDogLinkedInfo(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(LinkedInfo)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogLinkedInfo)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogLinkedInfo.cs similarity index 83% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogLinkedInfo.cs index a4c3f046e0c7..db52558ae5e6 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedInfo.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogLinkedInfo.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// The definition of a linked resource. - public partial class LinkedInfo + public partial class DataDogLinkedInfo { /// /// Keeps track of any properties unknown to the library. @@ -46,16 +46,16 @@ public partial class LinkedInfo /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - internal LinkedInfo() + /// Initializes a new instance of . + internal DataDogLinkedInfo() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The ARM id of the linked resource. /// The location of the linked resource. /// Keeps track of any properties unknown to the library. - internal LinkedInfo(string id, AzureLocation? location, IDictionary serializedAdditionalRawData) + internal DataDogLinkedInfo(ResourceIdentifier id, AzureLocation? location, IDictionary serializedAdditionalRawData) { Id = id; Location = location; @@ -63,7 +63,7 @@ internal LinkedInfo(string id, AzureLocation? location, IDictionary The ARM id of the linked resource. - public string Id { get; } + public ResourceIdentifier Id { get; } /// The location of the linked resource. public AzureLocation? Location { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogOperationData.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogOperationData.cs new file mode 100644 index 000000000000..12c62fb62401 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogOperationData.cs @@ -0,0 +1,60 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// The operation for the patch on the resource. + public readonly partial struct DataDogOperationData : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public DataDogOperationData(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string AddBeginValue = "AddBegin"; + private const string AddCompleteValue = "AddComplete"; + private const string DeleteBeginValue = "DeleteBegin"; + private const string DeleteCompleteValue = "DeleteComplete"; + private const string ActiveValue = "Active"; + + /// AddBegin. + public static DataDogOperationData AddBegin { get; } = new DataDogOperationData(AddBeginValue); + /// AddComplete. + public static DataDogOperationData AddComplete { get; } = new DataDogOperationData(AddCompleteValue); + /// DeleteBegin. + public static DataDogOperationData DeleteBegin { get; } = new DataDogOperationData(DeleteBeginValue); + /// DeleteComplete. + public static DataDogOperationData DeleteComplete { get; } = new DataDogOperationData(DeleteCompleteValue); + /// Active. + public static DataDogOperationData Active { get; } = new DataDogOperationData(ActiveValue); + /// Determines if two values are the same. + public static bool operator ==(DataDogOperationData left, DataDogOperationData right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(DataDogOperationData left, DataDogOperationData right) => !left.Equals(right); + /// Converts a to a . + public static implicit operator DataDogOperationData(string value) => new DataDogOperationData(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is DataDogOperationData other && Equals(other); + /// + public bool Equals(DataDogOperationData other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogSubscriptionList.Serialization.cs similarity index 68% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogSubscriptionList.Serialization.cs index 99495eddb6ae..744f1af59f8c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogSubscriptionList.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class SubscriptionList : IUtf8JsonSerializable, IJsonModel + public partial class DataDogSubscriptionList : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriter /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(SubscriptionList)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogSubscriptionList)} does not support writing '{format}' format."); } if (Optional.IsDefined(Operation)) @@ -66,19 +66,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - SubscriptionList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogSubscriptionList IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(SubscriptionList)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogSubscriptionList)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeSubscriptionList(document.RootElement, options); + return DeserializeDataDogSubscriptionList(document.RootElement, options); } - internal static SubscriptionList DeserializeSubscriptionList(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogSubscriptionList DeserializeDataDogSubscriptionList(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -86,7 +86,7 @@ internal static SubscriptionList DeserializeSubscriptionList(JsonElement element { return null; } - OperationData? operation = default; + DataDogOperationData? operation = default; IList monitoredSubscriptionList = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -98,7 +98,7 @@ internal static SubscriptionList DeserializeSubscriptionList(JsonElement element { continue; } - operation = new OperationData(property.Value.GetString()); + operation = new DataDogOperationData(property.Value.GetString()); continue; } if (property.NameEquals("monitoredSubscriptionList"u8)) @@ -121,38 +121,38 @@ internal static SubscriptionList DeserializeSubscriptionList(JsonElement element } } serializedAdditionalRawData = rawDataDictionary; - return new SubscriptionList(operation, monitoredSubscriptionList ?? new ChangeTrackingList(), serializedAdditionalRawData); + return new DataDogSubscriptionList(operation, monitoredSubscriptionList ?? new ChangeTrackingList(), serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(SubscriptionList)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogSubscriptionList)} does not support writing '{options.Format}' format."); } } - SubscriptionList IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogSubscriptionList IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeSubscriptionList(document.RootElement, options); + return DeserializeDataDogSubscriptionList(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(SubscriptionList)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogSubscriptionList)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogSubscriptionList.cs similarity index 82% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogSubscriptionList.cs index 4327874c3f18..af087465af95 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/SubscriptionList.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogSubscriptionList.cs @@ -11,7 +11,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. - public partial class SubscriptionList + public partial class DataDogSubscriptionList { /// /// Keeps track of any properties unknown to the library. @@ -45,17 +45,17 @@ public partial class SubscriptionList /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - public SubscriptionList() + /// Initializes a new instance of . + public DataDogSubscriptionList() { MonitoredSubscriptionList = new ChangeTrackingList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The operation for the patch on the resource. /// List of subscriptions and the state of the monitoring. /// Keeps track of any properties unknown to the library. - internal SubscriptionList(OperationData? operation, IList monitoredSubscriptionList, IDictionary serializedAdditionalRawData) + internal DataDogSubscriptionList(DataDogOperationData? operation, IList monitoredSubscriptionList, IDictionary serializedAdditionalRawData) { Operation = operation; MonitoredSubscriptionList = monitoredSubscriptionList; @@ -63,7 +63,7 @@ internal SubscriptionList(OperationData? operation, IList } /// The operation for the patch on the resource. - public OperationData? Operation { get; set; } + public DataDogOperationData? Operation { get; set; } /// List of subscriptions and the state of the monitoring. public IList MonitoredSubscriptionList { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs index e45be34a2848..3294a267ed74 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs @@ -15,11 +15,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogAgreementResourceContent : IUtf8JsonSerializable, IJsonModel + public partial class DataDogAgreementResourceContent : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -30,10 +30,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support writing '{format}' format."); } base.JsonModelWriteCore(writer, options); @@ -44,19 +44,19 @@ protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWri } } - DatadogAgreementResourceContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogAgreementResourceContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogAgreementResourceContent(document.RootElement, options); + return DeserializeDataDogAgreementResourceContent(document.RootElement, options); } - internal static DatadogAgreementResourceContent DeserializeDatadogAgreementResourceContent(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogAgreementResourceContent DeserializeDataDogAgreementResourceContent(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -112,7 +112,7 @@ internal static DatadogAgreementResourceContent DeserializeDatadogAgreementResou } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogAgreementResourceContent( + return new DataDogAgreementResourceContent( id, name, type, @@ -121,35 +121,35 @@ internal static DatadogAgreementResourceContent DeserializeDatadogAgreementResou serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support writing '{options.Format}' format."); } } - DatadogAgreementResourceContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogAgreementResourceContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogAgreementResourceContent(document.RootElement, options); + return DeserializeDataDogAgreementResourceContent(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceContent)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs index 91cd7f8b0b57..2c65869648da 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs @@ -12,8 +12,8 @@ namespace Azure.ResourceManager.Datadog.Models { - /// The DatadogAgreementResourceContent. - public partial class DatadogAgreementResourceContent : ResourceData + /// The DataDogAgreementResourceContent. + public partial class DataDogAgreementResourceContent : ResourceData { /// /// Keeps track of any properties unknown to the library. @@ -47,19 +47,19 @@ public partial class DatadogAgreementResourceContent : ResourceData /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - public DatadogAgreementResourceContent() + /// Initializes a new instance of . + public DataDogAgreementResourceContent() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. /// Represents the properties of the resource. /// Keeps track of any properties unknown to the library. - internal DatadogAgreementResourceContent(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DatadogAgreementProperties properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + internal DataDogAgreementResourceContent(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DatadogAgreementProperties properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) { Properties = properties; _serializedAdditionalRawData = serializedAdditionalRawData; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs index f50ad1ea8bf3..7fd45d7f54c6 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogAgreementResourceListResult : IUtf8JsonSerializable, IJsonModel + internal partial class DataDogAgreementResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogAgreementResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogAgreementResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogAgreementResourceListResult(document.RootElement, options); + return DeserializeDataDogAgreementResourceListResult(document.RootElement, options); } - internal static DatadogAgreementResourceListResult DeserializeDatadogAgreementResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogAgreementResourceListResult DeserializeDataDogAgreementResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -83,7 +83,7 @@ internal static DatadogAgreementResourceListResult DeserializeDatadogAgreementRe { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static DatadogAgreementResourceListResult DeserializeDatadogAgreementRe { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(item, options)); + array.Add(DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(item, options)); } value = array; continue; @@ -114,38 +114,38 @@ internal static DatadogAgreementResourceListResult DeserializeDatadogAgreementRe } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogAgreementResourceListResult(value, nextLink, serializedAdditionalRawData); + return new DataDogAgreementResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceListResult)} does not support writing '{options.Format}' format."); } } - DatadogAgreementResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogAgreementResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogAgreementResourceListResult(document.RootElement, options); + return DeserializeDataDogAgreementResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogAgreementResourceListResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs index 459081e61381..3631af9df30b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogAgreementResourceListResult + internal partial class DataDogAgreementResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,34 +46,34 @@ internal partial class DatadogAgreementResourceListResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogAgreementResource items on this page. /// is null. - internal DatadogAgreementResourceListResult(IEnumerable value) + internal DataDogAgreementResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogAgreementResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogAgreementResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DataDogAgreementResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogAgreementResourceListResult() + /// Initializes a new instance of for deserialization. + internal DataDogAgreementResourceListResult() { } /// The DatadogAgreementResource items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.Serialization.cs index a0dcd1a33a8f..1710922c7834 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogApiKeyContent : IUtf8JsonSerializable, IJsonModel + public partial class DataDogApiKeyContent : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWr /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyContent)} does not support writing '{format}' format."); } if (Optional.IsDefined(CreatedBy)) @@ -68,19 +68,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogApiKeyContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogApiKeyContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyContent)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogApiKeyContent(document.RootElement, options); + return DeserializeDataDogApiKeyContent(document.RootElement, options); } - internal static DatadogApiKeyContent DeserializeDatadogApiKeyContent(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogApiKeyContent DeserializeDataDogApiKeyContent(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -122,38 +122,38 @@ internal static DatadogApiKeyContent DeserializeDatadogApiKeyContent(JsonElement } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogApiKeyContent(createdBy, name, key, created, serializedAdditionalRawData); + return new DataDogApiKeyContent(createdBy, name, key, created, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyContent)} does not support writing '{options.Format}' format."); } } - DatadogApiKeyContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogApiKeyContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogApiKeyContent(document.RootElement, options); + return DeserializeDataDogApiKeyContent(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogApiKeyContent)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyContent)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.cs index fa41ee0d2a27..9253e29ecaf3 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyContent.cs @@ -10,8 +10,8 @@ namespace Azure.ResourceManager.Datadog.Models { - /// The DatadogApiKeyContent. - public partial class DatadogApiKeyContent + /// The DataDogApiKeyContent. + public partial class DataDogApiKeyContent { /// /// Keeps track of any properties unknown to the library. @@ -45,23 +45,23 @@ public partial class DatadogApiKeyContent /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The value of the API key. /// is null. - public DatadogApiKeyContent(string key) + public DataDogApiKeyContent(string key) { Argument.AssertNotNull(key, nameof(key)); Key = key; } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The user that created the API key. /// The name of the API key. /// The value of the API key. /// The time of creation of the API key. /// Keeps track of any properties unknown to the library. - internal DatadogApiKeyContent(string createdBy, string name, string key, string created, IDictionary serializedAdditionalRawData) + internal DataDogApiKeyContent(string createdBy, string name, string key, string created, IDictionary serializedAdditionalRawData) { CreatedBy = createdBy; Name = name; @@ -70,8 +70,8 @@ internal DatadogApiKeyContent(string createdBy, string name, string key, string _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogApiKeyContent() + /// Initializes a new instance of for deserialization. + internal DataDogApiKeyContent() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.Serialization.cs index 085718ca4a33..34f387134675 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogApiKeyListResult : IUtf8JsonSerializable, IJsonModel + internal partial class DataDogApiKeyListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReade /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogApiKeyListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogApiKeyListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogApiKeyListResult(document.RootElement, options); + return DeserializeDataDogApiKeyListResult(document.RootElement, options); } - internal static DatadogApiKeyListResult DeserializeDatadogApiKeyListResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogApiKeyListResult DeserializeDataDogApiKeyListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -83,7 +83,7 @@ internal static DatadogApiKeyListResult DeserializeDatadogApiKeyListResult(JsonE { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static DatadogApiKeyListResult DeserializeDatadogApiKeyListResult(JsonE { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DatadogApiKeyContent.DeserializeDatadogApiKeyContent(item, options)); + array.Add(DataDogApiKeyContent.DeserializeDataDogApiKeyContent(item, options)); } value = array; continue; @@ -114,38 +114,38 @@ internal static DatadogApiKeyListResult DeserializeDatadogApiKeyListResult(JsonE } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogApiKeyListResult(value, nextLink, serializedAdditionalRawData); + return new DataDogApiKeyListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyListResult)} does not support writing '{options.Format}' format."); } } - DatadogApiKeyListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogApiKeyListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogApiKeyListResult(document.RootElement, options); + return DeserializeDataDogApiKeyListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogApiKeyListResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogApiKeyListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.cs index f47474be78a8..bbff7d35ae1b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogApiKeyListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogApiKeyListResult + internal partial class DataDogApiKeyListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,34 +46,34 @@ internal partial class DatadogApiKeyListResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogApiKey items on this page. /// is null. - internal DatadogApiKeyListResult(IEnumerable value) + internal DataDogApiKeyListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogApiKey items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogApiKeyListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DataDogApiKeyListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogApiKeyListResult() + /// Initializes a new instance of for deserialization. + internal DataDogApiKeyListResult() { } /// The DatadogApiKey items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.Serialization.cs index 42997513f081..240f7688e85b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogBillingInfoResult : IUtf8JsonSerializable, IJsonModel + public partial class DataDogBillingInfoResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogBillingInfoResult)} does not support writing '{format}' format."); } if (Optional.IsDefined(MarketplaceSaasInfo)) @@ -61,19 +61,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogBillingInfoResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogBillingInfoResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogBillingInfoResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogBillingInfoResult(document.RootElement, options); + return DeserializeDataDogBillingInfoResult(document.RootElement, options); } - internal static DatadogBillingInfoResult DeserializeDatadogBillingInfoResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogBillingInfoResult DeserializeDataDogBillingInfoResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -111,38 +111,38 @@ internal static DatadogBillingInfoResult DeserializeDatadogBillingInfoResult(Jso } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogBillingInfoResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData); + return new DataDogBillingInfoResult(marketplaceSaasInfo, partnerBillingEntity, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogBillingInfoResult)} does not support writing '{options.Format}' format."); } } - DatadogBillingInfoResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogBillingInfoResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogBillingInfoResult(document.RootElement, options); + return DeserializeDataDogBillingInfoResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogBillingInfoResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogBillingInfoResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.cs index 7cc739146519..968caa9c16de 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogBillingInfoResult.cs @@ -11,7 +11,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Marketplace Subscription and Organization details to which resource gets billed into. - public partial class DatadogBillingInfoResult + public partial class DataDogBillingInfoResult { /// /// Keeps track of any properties unknown to the library. @@ -45,16 +45,16 @@ public partial class DatadogBillingInfoResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - internal DatadogBillingInfoResult() + /// Initializes a new instance of . + internal DataDogBillingInfoResult() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Marketplace Subscription details. /// Partner Billing Entity details: Organization Info. /// Keeps track of any properties unknown to the library. - internal DatadogBillingInfoResult(MarketplaceSaaSInfo marketplaceSaasInfo, PartnerBillingEntity partnerBillingEntity, IDictionary serializedAdditionalRawData) + internal DataDogBillingInfoResult(MarketplaceSaaSInfo marketplaceSaasInfo, PartnerBillingEntity partnerBillingEntity, IDictionary serializedAdditionalRawData) { MarketplaceSaasInfo = marketplaceSaasInfo; PartnerBillingEntity = partnerBillingEntity; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.Serialization.cs index 98e337511351..4dcf9996916d 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DatadogCreateResourceSupportedResult : IUtf8JsonSerializable, IJsonModel + public partial class DataDogCreateResourceSupportedResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter write /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogCreateResourceSupportedResult)} does not support writing '{format}' format."); } if (Optional.IsDefined(Properties)) @@ -56,19 +56,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogCreateResourceSupportedResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogCreateResourceSupportedResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogCreateResourceSupportedResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogCreateResourceSupportedResult(document.RootElement, options); + return DeserializeDataDogCreateResourceSupportedResult(document.RootElement, options); } - internal static DatadogCreateResourceSupportedResult DeserializeDatadogCreateResourceSupportedResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogCreateResourceSupportedResult DeserializeDataDogCreateResourceSupportedResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -96,38 +96,38 @@ internal static DatadogCreateResourceSupportedResult DeserializeDatadogCreateRes } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogCreateResourceSupportedResult(properties, serializedAdditionalRawData); + return new DataDogCreateResourceSupportedResult(properties, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogCreateResourceSupportedResult)} does not support writing '{options.Format}' format."); } } - DatadogCreateResourceSupportedResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogCreateResourceSupportedResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogCreateResourceSupportedResult(document.RootElement, options); + return DeserializeDataDogCreateResourceSupportedResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogCreateResourceSupportedResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogCreateResourceSupportedResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.cs index 94dc6dc9b911..4d0f96a3d5db 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogCreateResourceSupportedResult.cs @@ -11,7 +11,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Datadog resource can be created or not. - public partial class DatadogCreateResourceSupportedResult + public partial class DataDogCreateResourceSupportedResult { /// /// Keeps track of any properties unknown to the library. @@ -45,15 +45,15 @@ public partial class DatadogCreateResourceSupportedResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - internal DatadogCreateResourceSupportedResult() + /// Initializes a new instance of . + internal DataDogCreateResourceSupportedResult() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// Represents the properties of the resource. /// Keeps track of any properties unknown to the library. - internal DatadogCreateResourceSupportedResult(CreateResourceSupportedProperties properties, IDictionary serializedAdditionalRawData) + internal DataDogCreateResourceSupportedResult(CreateResourceSupportedProperties properties, IDictionary serializedAdditionalRawData) { Properties = properties; _serializedAdditionalRawData = serializedAdditionalRawData; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.Serialization.cs index 9f95c0cf080a..e5a2824c95ec 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogHostListResult : IUtf8JsonSerializable, IJsonModel + internal partial class DataDogHostListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderW /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogHostListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogHostListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogHostListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogHostListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogHostListResult(document.RootElement, options); + return DeserializeDataDogHostListResult(document.RootElement, options); } - internal static DatadogHostListResult DeserializeDatadogHostListResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogHostListResult DeserializeDataDogHostListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -114,38 +114,38 @@ internal static DatadogHostListResult DeserializeDatadogHostListResult(JsonEleme } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogHostListResult(value, nextLink, serializedAdditionalRawData); + return new DataDogHostListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogHostListResult)} does not support writing '{options.Format}' format."); } } - DatadogHostListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogHostListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogHostListResult(document.RootElement, options); + return DeserializeDataDogHostListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogHostListResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogHostListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.cs index c74fd8cbb1b0..40a34d8a7608 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogHostListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogHostListResult + internal partial class DataDogHostListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class DatadogHostListResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogHost items on this page. /// is null. - internal DatadogHostListResult(IEnumerable value) + internal DataDogHostListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogHost items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogHostListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DataDogHostListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogHostListResult() + /// Initializes a new instance of for deserialization. + internal DataDogHostListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.Serialization.cs index 51f45385451f..dfc1937210ca 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogMonitorResourceListResult : IUtf8JsonSerializable, IJsonModel + internal partial class DataDogMonitorResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, M /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitorResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogMonitorResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogMonitorResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitorResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogMonitorResourceListResult(document.RootElement, options); + return DeserializeDataDogMonitorResourceListResult(document.RootElement, options); } - internal static DatadogMonitorResourceListResult DeserializeDatadogMonitorResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogMonitorResourceListResult DeserializeDataDogMonitorResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -114,38 +114,38 @@ internal static DatadogMonitorResourceListResult DeserializeDatadogMonitorResour } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogMonitorResourceListResult(value, nextLink, serializedAdditionalRawData); + return new DataDogMonitorResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitorResourceListResult)} does not support writing '{options.Format}' format."); } } - DatadogMonitorResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogMonitorResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogMonitorResourceListResult(document.RootElement, options); + return DeserializeDataDogMonitorResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogMonitorResourceListResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitorResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.cs index 44009740740a..3196434a492e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogMonitorResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogMonitorResourceListResult + internal partial class DataDogMonitorResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class DatadogMonitorResourceListResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogMonitorResource items on this page. /// is null. - internal DatadogMonitorResourceListResult(IEnumerable value) + internal DataDogMonitorResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogMonitorResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogMonitorResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DataDogMonitorResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogMonitorResourceListResult() + /// Initializes a new instance of for deserialization. + internal DataDogMonitorResourceListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.Serialization.cs index a2b943f9ff43..20fbb7a923c8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - internal partial class DatadogSingleSignOnResourceListResult : IUtf8JsonSerializable, IJsonModel + internal partial class DataDogSingleSignOnResourceListResult : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writ /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogSingleSignOnResourceListResult)} does not support writing '{format}' format."); } writer.WritePropertyName("value"u8); @@ -63,19 +63,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - DatadogSingleSignOnResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogSingleSignOnResourceListResult IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogSingleSignOnResourceListResult)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDatadogSingleSignOnResourceListResult(document.RootElement, options); + return DeserializeDataDogSingleSignOnResourceListResult(document.RootElement, options); } - internal static DatadogSingleSignOnResourceListResult DeserializeDatadogSingleSignOnResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogSingleSignOnResourceListResult DeserializeDataDogSingleSignOnResourceListResult(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -114,38 +114,38 @@ internal static DatadogSingleSignOnResourceListResult DeserializeDatadogSingleSi } } serializedAdditionalRawData = rawDataDictionary; - return new DatadogSingleSignOnResourceListResult(value, nextLink, serializedAdditionalRawData); + return new DataDogSingleSignOnResourceListResult(value, nextLink, serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogSingleSignOnResourceListResult)} does not support writing '{options.Format}' format."); } } - DatadogSingleSignOnResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogSingleSignOnResourceListResult IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDatadogSingleSignOnResourceListResult(document.RootElement, options); + return DeserializeDataDogSingleSignOnResourceListResult(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DatadogSingleSignOnResourceListResult)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogSingleSignOnResourceListResult)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.cs index 4befa014a412..e34c82c6436a 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogSingleSignOnResourceListResult.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// Response of a list operation. - internal partial class DatadogSingleSignOnResourceListResult + internal partial class DataDogSingleSignOnResourceListResult { /// /// Keeps track of any properties unknown to the library. @@ -46,29 +46,29 @@ internal partial class DatadogSingleSignOnResourceListResult /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogSingleSignOnResource items on this page. /// is null. - internal DatadogSingleSignOnResourceListResult(IEnumerable value) + internal DataDogSingleSignOnResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); Value = value.ToList(); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The DatadogSingleSignOnResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DatadogSingleSignOnResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DataDogSingleSignOnResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; _serializedAdditionalRawData = serializedAdditionalRawData; } - /// Initializes a new instance of for deserialization. - internal DatadogSingleSignOnResourceListResult() + /// Initializes a new instance of for deserialization. + internal DataDogSingleSignOnResourceListResult() { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.Serialization.cs index 70ce6baca8b6..a44c305d9eb5 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.Serialization.cs @@ -83,7 +83,7 @@ internal static LinkedResourceListResult DeserializeLinkedResourceListResult(Jso { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static LinkedResourceListResult DeserializeLinkedResourceListResult(Jso { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(LinkedInfo.DeserializeLinkedInfo(item, options)); + array.Add(DataDogLinkedInfo.DeserializeDataDogLinkedInfo(item, options)); } value = array; continue; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.cs index 7c661f62e51c..d486ce9ab395 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LinkedResourceListResult.cs @@ -49,7 +49,7 @@ internal partial class LinkedResourceListResult /// Initializes a new instance of . /// The LinkedResource items on this page. /// is null. - internal LinkedResourceListResult(IEnumerable value) + internal LinkedResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); @@ -60,7 +60,7 @@ internal LinkedResourceListResult(IEnumerable value) /// The LinkedResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal LinkedResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal LinkedResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; @@ -73,7 +73,7 @@ internal LinkedResourceListResult() } /// The LinkedResource items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs index 194ebea8a868..53b13b35e11f 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.Serialization.cs @@ -37,7 +37,7 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit if (Optional.IsDefined(MarketplaceSubscriptionId)) { writer.WritePropertyName("marketplaceSubscriptionId"u8); - writer.WriteStringValue(MarketplaceSubscriptionId); + writer.WriteStringValue(MarketplaceSubscriptionId.Value); } if (Optional.IsDefined(MarketplaceName)) { @@ -52,7 +52,7 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit if (Optional.IsDefined(BilledAzureSubscriptionId)) { writer.WritePropertyName("billedAzureSubscriptionId"u8); - writer.WriteStringValue(BilledAzureSubscriptionId); + writer.WriteStringValue(BilledAzureSubscriptionId.Value); } if (Optional.IsDefined(IsSubscribed)) { @@ -96,10 +96,10 @@ internal static MarketplaceSaaSInfo DeserializeMarketplaceSaaSInfo(JsonElement e { return null; } - string marketplaceSubscriptionId = default; + Guid? marketplaceSubscriptionId = default; string marketplaceName = default; string marketplaceStatus = default; - string billedAzureSubscriptionId = default; + Guid? billedAzureSubscriptionId = default; bool? subscribed = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -107,7 +107,11 @@ internal static MarketplaceSaaSInfo DeserializeMarketplaceSaaSInfo(JsonElement e { if (property.NameEquals("marketplaceSubscriptionId"u8)) { - marketplaceSubscriptionId = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + marketplaceSubscriptionId = property.Value.GetGuid(); continue; } if (property.NameEquals("marketplaceName"u8)) @@ -122,7 +126,11 @@ internal static MarketplaceSaaSInfo DeserializeMarketplaceSaaSInfo(JsonElement e } if (property.NameEquals("billedAzureSubscriptionId"u8)) { - billedAzureSubscriptionId = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + billedAzureSubscriptionId = property.Value.GetGuid(); continue; } if (property.NameEquals("subscribed"u8)) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs index 0124b7d6d0ef..964eb662ec56 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MarketplaceSaaSInfo.cs @@ -57,7 +57,7 @@ internal MarketplaceSaaSInfo() /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. /// Flag specifying if the Marketplace status is subscribed or not. /// Keeps track of any properties unknown to the library. - internal MarketplaceSaaSInfo(string marketplaceSubscriptionId, string marketplaceName, string marketplaceStatus, string billedAzureSubscriptionId, bool? isSubscribed, IDictionary serializedAdditionalRawData) + internal MarketplaceSaaSInfo(Guid? marketplaceSubscriptionId, string marketplaceName, string marketplaceStatus, Guid? billedAzureSubscriptionId, bool? isSubscribed, IDictionary serializedAdditionalRawData) { MarketplaceSubscriptionId = marketplaceSubscriptionId; MarketplaceName = marketplaceName; @@ -68,13 +68,13 @@ internal MarketplaceSaaSInfo(string marketplaceSubscriptionId, string marketplac } /// Marketplace Subscription Id. This is a GUID-formatted string. - public string MarketplaceSubscriptionId { get; } + public Guid? MarketplaceSubscriptionId { get; } /// Marketplace Subscription Details: SAAS Name. public string MarketplaceName { get; } /// Marketplace Subscription Details: SaaS Subscription Status. public string MarketplaceStatus { get; } /// The Azure Subscription ID to which the Marketplace Subscription belongs and gets billed into. - public string BilledAzureSubscriptionId { get; } + public Guid? BilledAzureSubscriptionId { get; } /// Flag specifying if the Marketplace status is subscribed or not. public bool? IsSubscribed { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs index 5e4a9e1f50a0..7725ab5ca079 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs @@ -96,7 +96,7 @@ internal static MonitoredResourceContent DeserializeMonitoredResourceContent(Jso { return null; } - string id = default; + ResourceIdentifier id = default; bool? sendingMetrics = default; string reasonForMetricsStatus = default; bool? sendingLogs = default; @@ -107,7 +107,11 @@ internal static MonitoredResourceContent DeserializeMonitoredResourceContent(Jso { if (property.NameEquals("id"u8)) { - id = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + id = new ResourceIdentifier(property.Value.GetString()); continue; } if (property.NameEquals("sendingMetrics"u8)) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs index 64804e299677..6dba70fefa68 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs @@ -7,6 +7,7 @@ using System; using System.Collections.Generic; +using Azure.Core; namespace Azure.ResourceManager.Datadog.Models { @@ -57,7 +58,7 @@ internal MonitoredResourceContent() /// Flag indicating if resource is sending logs to Datadog. /// Reason for why the resource is sending logs (or why it is not sending). /// Keeps track of any properties unknown to the library. - internal MonitoredResourceContent(string id, bool? isSendingMetrics, string reasonForMetricsStatus, bool? isSendingLogs, string reasonForLogsStatus, IDictionary serializedAdditionalRawData) + internal MonitoredResourceContent(ResourceIdentifier id, bool? isSendingMetrics, string reasonForMetricsStatus, bool? isSendingLogs, string reasonForLogsStatus, IDictionary serializedAdditionalRawData) { Id = id; IsSendingMetrics = isSendingMetrics; @@ -68,7 +69,7 @@ internal MonitoredResourceContent(string id, bool? isSendingMetrics, string reas } /// The ARM id of the resource. - public string Id { get; } + public ResourceIdentifier Id { get; } /// Flag indicating if resource is sending metrics to Datadog. public bool? IsSendingMetrics { get; } /// Reason for why the resource is sending metrics (or why it is not sending). diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs index ea97d0cc8fb3..59bef683e262 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs @@ -37,7 +37,7 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit if (Optional.IsDefined(SubscriptionId)) { writer.WritePropertyName("subscriptionId"u8); - writer.WriteStringValue(SubscriptionId); + writer.WriteStringValue(SubscriptionId.Value); } if (Optional.IsDefined(Status)) { @@ -91,7 +91,7 @@ internal static MonitoredSubscription DeserializeMonitoredSubscription(JsonEleme { return null; } - string subscriptionId = default; + Guid? subscriptionId = default; MonitoredStatus? status = default; string error = default; MonitoringTagRulesProperties tagRules = default; @@ -101,7 +101,11 @@ internal static MonitoredSubscription DeserializeMonitoredSubscription(JsonEleme { if (property.NameEquals("subscriptionId"u8)) { - subscriptionId = property.Value.GetString(); + if (property.Value.ValueKind == JsonValueKind.Null) + { + continue; + } + subscriptionId = property.Value.GetGuid(); continue; } if (property.NameEquals("status"u8)) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs index 682daee3dfd5..37f0d781c332 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs @@ -56,7 +56,7 @@ public MonitoredSubscription() /// The reason of not monitoring the subscription. /// Definition of the properties for a TagRules resource. /// Keeps track of any properties unknown to the library. - internal MonitoredSubscription(string subscriptionId, MonitoredStatus? status, string error, MonitoringTagRulesProperties tagRules, IDictionary serializedAdditionalRawData) + internal MonitoredSubscription(Guid? subscriptionId, MonitoredStatus? status, string error, MonitoringTagRulesProperties tagRules, IDictionary serializedAdditionalRawData) { SubscriptionId = subscriptionId; Status = status; @@ -66,7 +66,7 @@ internal MonitoredSubscription(string subscriptionId, MonitoredStatus? status, s } /// The subscriptionId to be monitored. - public string SubscriptionId { get; set; } + public Guid? SubscriptionId { get; set; } /// The state of monitoring. public MonitoredStatus? Status { get; set; } /// The reason of not monitoring the subscription. diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/OperationData.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/OperationData.cs deleted file mode 100644 index 4bcf2449a07f..000000000000 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/OperationData.cs +++ /dev/null @@ -1,60 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.ResourceManager.Datadog.Models -{ - /// The operation for the patch on the resource. - public readonly partial struct OperationData : IEquatable - { - private readonly string _value; - - /// Initializes a new instance of . - /// is null. - public OperationData(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string AddBeginValue = "AddBegin"; - private const string AddCompleteValue = "AddComplete"; - private const string DeleteBeginValue = "DeleteBegin"; - private const string DeleteCompleteValue = "DeleteComplete"; - private const string ActiveValue = "Active"; - - /// AddBegin. - public static OperationData AddBegin { get; } = new OperationData(AddBeginValue); - /// AddComplete. - public static OperationData AddComplete { get; } = new OperationData(AddCompleteValue); - /// DeleteBegin. - public static OperationData DeleteBegin { get; } = new OperationData(DeleteBeginValue); - /// DeleteComplete. - public static OperationData DeleteComplete { get; } = new OperationData(DeleteCompleteValue); - /// Active. - public static OperationData Active { get; } = new OperationData(ActiveValue); - /// Determines if two values are the same. - public static bool operator ==(OperationData left, OperationData right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(OperationData left, OperationData right) => !left.Equals(right); - /// Converts a to a . - public static implicit operator OperationData(string value) => new OperationData(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is OperationData other && Equals(other); - /// - public bool Equals(OperationData other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs index 222d1a924ff8..aa25a189d4e7 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.Serialization.cs @@ -65,7 +65,7 @@ internal static MonitoredSubscriptionPropertyData DeserializeMonitoredSubscripti { return null; } - SubscriptionList properties = default; + DataDogSubscriptionList properties = default; ResourceIdentifier id = default; string name = default; ResourceType type = default; @@ -80,7 +80,7 @@ internal static MonitoredSubscriptionPropertyData DeserializeMonitoredSubscripti { continue; } - properties = SubscriptionList.DeserializeSubscriptionList(property.Value, options); + properties = DataDogSubscriptionList.DeserializeDataDogSubscriptionList(property.Value, options); continue; } if (property.NameEquals("id"u8)) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs index 4adef9a407c3..dca9b1bab871 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/MonitoredSubscriptionPropertyData.cs @@ -63,13 +63,13 @@ public MonitoredSubscriptionPropertyData() /// The systemData. /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. /// Keeps track of any properties unknown to the library. - internal MonitoredSubscriptionPropertyData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, SubscriptionList properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + internal MonitoredSubscriptionPropertyData(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DataDogSubscriptionList properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) { Properties = properties; _serializedAdditionalRawData = serializedAdditionalRawData; } /// The request to update subscriptions needed to be monitored by the Datadog monitor resource. - public SubscriptionList Properties { get; set; } + public DataDogSubscriptionList Properties { get; set; } } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs index 157dc8cbb9e2..de83f5488eac 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/BillingInfoRestOperations.cs @@ -79,7 +79,7 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string resourceGrou /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> GetAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -91,9 +91,9 @@ public async Task> GetAsync(string subscripti { case 200: { - DatadogBillingInfoResult value = default; + DataDogBillingInfoResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogBillingInfoResult.DeserializeDatadogBillingInfoResult(document.RootElement); + value = DataDogBillingInfoResult.DeserializeDataDogBillingInfoResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -108,7 +108,7 @@ public async Task> GetAsync(string subscripti /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response Get(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response Get(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -120,9 +120,9 @@ public Response Get(string subscriptionId, string reso { case 200: { - DatadogBillingInfoResult value = default; + DataDogBillingInfoResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogBillingInfoResult.DeserializeDatadogBillingInfoResult(document.RootElement); + value = DataDogBillingInfoResult.DeserializeDataDogBillingInfoResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs index 97bed3259fd8..94ee10da8846 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/CreationSupportedRestOperations.cs @@ -156,7 +156,7 @@ internal HttpMessage CreateGetRequest(string subscriptionId, string datadogOrgan /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public async Task> GetAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public async Task> GetAsync(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -167,9 +167,9 @@ public async Task> GetAsync(strin { case 200: { - DatadogCreateResourceSupportedResult value = default; + DataDogCreateResourceSupportedResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(document.RootElement); + value = DataDogCreateResourceSupportedResult.DeserializeDataDogCreateResourceSupportedResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -183,7 +183,7 @@ public async Task> GetAsync(strin /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public Response Get(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) + public Response Get(string subscriptionId, string datadogOrganizationId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNull(datadogOrganizationId, nameof(datadogOrganizationId)); @@ -194,9 +194,9 @@ public Response Get(string subscriptionId, { case 200: { - DatadogCreateResourceSupportedResult value = default; + DataDogCreateResourceSupportedResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogCreateResourceSupportedResult.DeserializeDatadogCreateResourceSupportedResult(document.RootElement); + value = DataDogCreateResourceSupportedResult.DeserializeDataDogCreateResourceSupportedResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs index 181dbe80651e..c60290898e36 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs @@ -69,7 +69,7 @@ internal HttpMessage CreateListRequest(string subscriptionId) /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -79,9 +79,9 @@ public async Task> ListAsync(string { case 200: { - DatadogAgreementResourceListResult value = default; + DataDogAgreementResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); + value = DataDogAgreementResourceListResult.DeserializeDataDogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -94,7 +94,7 @@ public async Task> ListAsync(string /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -104,9 +104,9 @@ public Response List(string subscriptionId, { case 200: { - DatadogAgreementResourceListResult value = default; + DataDogAgreementResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); + value = DataDogAgreementResourceListResult.DeserializeDataDogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -114,7 +114,7 @@ public Response List(string subscriptionId, } } - internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, DatadogAgreementResourceContent content) + internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, DataDogAgreementResourceContent content) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -125,7 +125,7 @@ internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, return uri; } - internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DatadogAgreementResourceContent content) + internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DataDogAgreementResourceContent content) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -155,7 +155,7 @@ internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DatadogA /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public async Task> CreateOrUpdateAsync(string subscriptionId, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public async Task> CreateOrUpdateAsync(string subscriptionId, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -165,9 +165,9 @@ public async Task> CreateOrUpdateAsync { case 200: { - DatadogAgreementResourceContent value = default; + DataDogAgreementResourceContent value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(document.RootElement); + value = DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -181,7 +181,7 @@ public async Task> CreateOrUpdateAsync /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public Response CreateOrUpdate(string subscriptionId, DatadogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public Response CreateOrUpdate(string subscriptionId, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -191,9 +191,9 @@ public Response CreateOrUpdate(string subscript { case 200: { - DatadogAgreementResourceContent value = default; + DataDogAgreementResourceContent value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogAgreementResourceContent.DeserializeDatadogAgreementResourceContent(document.RootElement); + value = DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -229,7 +229,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -240,9 +240,9 @@ public async Task> ListNextPageAsyn { case 200: { - DatadogAgreementResourceListResult value = default; + DataDogAgreementResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); + value = DataDogAgreementResourceListResult.DeserializeDataDogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -256,7 +256,7 @@ public async Task> ListNextPageAsyn /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -267,9 +267,9 @@ public Response ListNextPage(string nextLink { case 200: { - DatadogAgreementResourceListResult value = default; + DataDogAgreementResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogAgreementResourceListResult.DeserializeDatadogAgreementResourceListResult(document.RootElement); + value = DataDogAgreementResourceListResult.DeserializeDataDogAgreementResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs index 0c2cf261df21..296b8e53c50b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MonitorsRestOperations.cs @@ -69,7 +69,7 @@ internal HttpMessage CreateListRequest(string subscriptionId) /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -79,9 +79,9 @@ public async Task> ListAsync(string s { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -94,7 +94,7 @@ public async Task> ListAsync(string s /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -104,9 +104,9 @@ public Response List(string subscriptionId, Ca { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -152,7 +152,7 @@ internal HttpMessage CreateListByResourceGroupRequest(string subscriptionId, str /// The cancellation token to use. /// or is null. /// or is an empty string, and was expected to be non-empty. - public async Task> ListByResourceGroupAsync(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public async Task> ListByResourceGroupAsync(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -163,9 +163,9 @@ public async Task> ListByResourceGrou { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -179,7 +179,7 @@ public async Task> ListByResourceGrou /// The cancellation token to use. /// or is null. /// or is an empty string, and was expected to be non-empty. - public Response ListByResourceGroup(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public Response ListByResourceGroup(string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -190,9 +190,9 @@ public Response ListByResourceGroup(string sub { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -609,7 +609,7 @@ internal HttpMessage CreateGetDefaultKeyRequest(string subscriptionId, string re /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> GetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> GetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -621,9 +621,9 @@ public async Task> GetDefaultKeyAsync(string subs { case 200: { - DatadogApiKeyContent value = default; + DataDogApiKeyContent value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKeyContent.DeserializeDatadogApiKeyContent(document.RootElement); + value = DataDogApiKeyContent.DeserializeDataDogApiKeyContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -638,7 +638,7 @@ public async Task> GetDefaultKeyAsync(string subs /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response GetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response GetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -650,9 +650,9 @@ public Response GetDefaultKey(string subscriptionId, strin { case 200: { - DatadogApiKeyContent value = default; + DataDogApiKeyContent value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKeyContent.DeserializeDatadogApiKeyContent(document.RootElement); + value = DataDogApiKeyContent.DeserializeDataDogApiKeyContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -703,7 +703,7 @@ internal HttpMessage CreateListApiKeysRequest(string subscriptionId, string reso /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListApiKeysAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListApiKeysAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -715,9 +715,9 @@ public async Task> ListApiKeysAsync(string sub { case 200: { - DatadogApiKeyListResult value = default; + DataDogApiKeyListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); + value = DataDogApiKeyListResult.DeserializeDataDogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -732,7 +732,7 @@ public async Task> ListApiKeysAsync(string sub /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListApiKeys(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListApiKeys(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -744,9 +744,9 @@ public Response ListApiKeys(string subscriptionId, stri { case 200: { - DatadogApiKeyListResult value = default; + DataDogApiKeyListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); + value = DataDogApiKeyListResult.DeserializeDataDogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -797,7 +797,7 @@ internal HttpMessage CreateListHostsRequest(string subscriptionId, string resour /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListHostsAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListHostsAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -809,9 +809,9 @@ public async Task> ListHostsAsync(string subscri { case 200: { - DatadogHostListResult value = default; + DataDogHostListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); + value = DataDogHostListResult.DeserializeDataDogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -826,7 +826,7 @@ public async Task> ListHostsAsync(string subscri /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListHosts(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListHosts(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -838,9 +838,9 @@ public Response ListHosts(string subscriptionId, string r { case 200: { - DatadogHostListResult value = default; + DataDogHostListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); + value = DataDogHostListResult.DeserializeDataDogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1130,7 +1130,7 @@ public Response RefreshSetPasswordLink(string subscripti } } - internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content) + internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, string resourceGroupName, string monitorName, DataDogApiKeyContent content) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -1145,7 +1145,7 @@ internal RequestUriBuilder CreateSetDefaultKeyRequestUri(string subscriptionId, return uri; } - internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content) + internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string resourceGroupName, string monitorName, DataDogApiKeyContent content) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -1177,11 +1177,11 @@ internal HttpMessage CreateSetDefaultKeyRequest(string subscriptionId, string re /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. + /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task SetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) + public async Task SetDefaultKeyAsync(string subscriptionId, string resourceGroupName, string monitorName, DataDogApiKeyContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -1202,11 +1202,11 @@ public async Task SetDefaultKeyAsync(string subscriptionId, string res /// The ID of the target subscription. /// The name of the resource group. The name is case insensitive. /// Monitor resource name. - /// The to use. + /// The to use. /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response SetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, DatadogApiKeyContent content = null, CancellationToken cancellationToken = default) + public Response SetDefaultKey(string subscriptionId, string resourceGroupName, string monitorName, DataDogApiKeyContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -1251,7 +1251,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1262,9 +1262,9 @@ public async Task> ListNextPageAsync( { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1278,7 +1278,7 @@ public async Task> ListNextPageAsync( /// The cancellation token to use. /// or is null. /// is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1289,9 +1289,9 @@ public Response ListNextPage(string nextLink, { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1328,7 +1328,7 @@ internal HttpMessage CreateListByResourceGroupNextPageRequest(string nextLink, s /// The cancellation token to use. /// , or is null. /// or is an empty string, and was expected to be non-empty. - public async Task> ListByResourceGroupNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public async Task> ListByResourceGroupNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1340,9 +1340,9 @@ public async Task> ListByResourceGrou { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1357,7 +1357,7 @@ public async Task> ListByResourceGrou /// The cancellation token to use. /// , or is null. /// or is an empty string, and was expected to be non-empty. - public Response ListByResourceGroupNextPage(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) + public Response ListByResourceGroupNextPage(string nextLink, string subscriptionId, string resourceGroupName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1369,9 +1369,9 @@ public Response ListByResourceGroupNextPage(st { case 200: { - DatadogMonitorResourceListResult value = default; + DataDogMonitorResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogMonitorResourceListResult.DeserializeDatadogMonitorResourceListResult(document.RootElement); + value = DataDogMonitorResourceListResult.DeserializeDataDogMonitorResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1409,7 +1409,7 @@ internal HttpMessage CreateListApiKeysNextPageRequest(string nextLink, string su /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListApiKeysNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListApiKeysNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1422,9 +1422,9 @@ public async Task> ListApiKeysNextPageAsync(st { case 200: { - DatadogApiKeyListResult value = default; + DataDogApiKeyListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); + value = DataDogApiKeyListResult.DeserializeDataDogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1440,7 +1440,7 @@ public async Task> ListApiKeysNextPageAsync(st /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListApiKeysNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListApiKeysNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1453,9 +1453,9 @@ public Response ListApiKeysNextPage(string nextLink, st { case 200: { - DatadogApiKeyListResult value = default; + DataDogApiKeyListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogApiKeyListResult.DeserializeDatadogApiKeyListResult(document.RootElement); + value = DataDogApiKeyListResult.DeserializeDataDogApiKeyListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1493,7 +1493,7 @@ internal HttpMessage CreateListHostsNextPageRequest(string nextLink, string subs /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListHostsNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListHostsNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1506,9 +1506,9 @@ public async Task> ListHostsNextPageAsync(string { case 200: { - DatadogHostListResult value = default; + DataDogHostListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); + value = DataDogHostListResult.DeserializeDataDogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -1524,7 +1524,7 @@ public async Task> ListHostsNextPageAsync(string /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListHostsNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListHostsNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -1537,9 +1537,9 @@ public Response ListHostsNextPage(string nextLink, string { case 200: { - DatadogHostListResult value = default; + DataDogHostListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogHostListResult.DeserializeDatadogHostListResult(document.RootElement); + value = DataDogHostListResult.DeserializeDataDogHostListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs index 2222039d0a6c..90bca147f2f4 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/SingleSignOnConfigurationsRestOperations.cs @@ -79,7 +79,7 @@ internal HttpMessage CreateListRequest(string subscriptionId, string resourceGro /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListAsync(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -91,9 +91,9 @@ public async Task> ListAsync(str { case 200: { - DatadogSingleSignOnResourceListResult value = default; + DataDogSingleSignOnResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); + value = DataDogSingleSignOnResourceListResult.DeserializeDataDogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -108,7 +108,7 @@ public async Task> ListAsync(str /// The cancellation token to use. /// , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response List(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response List(string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); Argument.AssertNotNullOrEmpty(resourceGroupName, nameof(resourceGroupName)); @@ -120,9 +120,9 @@ public Response List(string subscriptionI { case 200: { - DatadogSingleSignOnResourceListResult value = default; + DataDogSingleSignOnResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); + value = DataDogSingleSignOnResourceListResult.DeserializeDataDogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -364,7 +364,7 @@ internal HttpMessage CreateListNextPageRequest(string nextLink, string subscript /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public async Task> ListNextPageAsync(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -377,9 +377,9 @@ public async Task> ListNextPageA { case 200: { - DatadogSingleSignOnResourceListResult value = default; + DataDogSingleSignOnResourceListResult value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); + value = DataDogSingleSignOnResourceListResult.DeserializeDataDogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -395,7 +395,7 @@ public async Task> ListNextPageA /// The cancellation token to use. /// , , or is null. /// , or is an empty string, and was expected to be non-empty. - public Response ListNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) + public Response ListNextPage(string nextLink, string subscriptionId, string resourceGroupName, string monitorName, CancellationToken cancellationToken = default) { Argument.AssertNotNull(nextLink, nameof(nextLink)); Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -408,9 +408,9 @@ public Response ListNextPage(string nextL { case 200: { - DatadogSingleSignOnResourceListResult value = default; + DataDogSingleSignOnResourceListResult value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DatadogSingleSignOnResourceListResult.DeserializeDatadogSingleSignOnResourceListResult(document.RootElement); + value = DataDogSingleSignOnResourceListResult.DeserializeDataDogSingleSignOnResourceListResult(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md index 302f9a99cf8c..b147e7bd451c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md @@ -8,8 +8,8 @@ azure-arm: true csharp: true library-name: Datadog namespace: Azure.ResourceManager.Datadog -require: https://github.com/Azure/azure-rest-api-specs-pr/blob/30f23d89b - 692f80b495fb7f45c3e695872460bd1/specification/datadog/resource-manager/readme.md +require: D:\Workspace\Repo\azure-rest-api-specs-pr\specification\datadog\resource-manager\readme.md +#require: https://github.com/Azure/azure-rest-api-specs-pr/blob/30f23d89b692f80b495fb7f45c3e695872460bd1/specification/datadog/resource-manager/readme.md # tag: package-2025-06 rpaas output-folder: $(this-folder)/Generated clear-output-folder: true @@ -52,24 +52,24 @@ acronym-mapping: Etag: ETag|etag rename-mapping: - DatadogAgreementResource: DatadogAgreementResourceContent + DatadogAgreementResource: DataDogAgreementResourceContent MonitoredResource: MonitoredResourceContent - BillingInfoResponse: DatadogBillingInfoResult - CreateResourceSupportedResponse: DatadogCreateResourceSupportedResult - DatadogMonitorResourceUpdateParameters: DatadogMonitorResourceUpdateContent - DatadogApiKey: DatadogApiKeyContent - LinkedResource: LinkedInfo + BillingInfoResponse: DataDogBillingInfoResult + CreateResourceSupportedResponse: DataDogCreateResourceSupportedResult + DatadogMonitorResourceUpdateParameters: DataDogMonitorResourceUpdateContent + DatadogApiKey: DataDogApiKeyContent + LinkedResource: DataDogLinkedInfo Status: MonitoredStatus - DatadogAgreementResourceListResponse: DatadogAgreementResourceListResult - DatadogApiKeyListResponse: DatadogApiKeyListResult - DatadogHostListResponse: DatadogHostListResult - DatadogMonitorResourceListResponse: DatadogMonitorResourceListResult - DatadogSingleSignOnResourceListResponse: DatadogSingleSignOnResourceListResult + DatadogAgreementResourceListResponse: DataDogAgreementResourceListResult + DatadogApiKeyListResponse: DataDogApiKeyListResult + DatadogHostListResponse: DataDogHostListResult + DatadogMonitorResourceListResponse: DataDogMonitorResourceListResult + DatadogSingleSignOnResourceListResponse: DataDogSingleSignOnResourceListResult LinkedResourceListResponse: LinkedResourceListResult MonitoredResourceListResponse: MonitoredResourceListResult MonitoringTagRulesListResponse: MonitoringTagRulesListResult CreateResourceSupportedResponseList: CreateResourceSupportedResultList - Operation: OperationData + Operation: DataDogOperationData CreateResourceSupportedProperties.creationSupported: IsCreationSupported MarketplaceSaaSInfo.subscribed: IsSubscribed DatadogAgreementProperties.accepted: IsAccepted @@ -88,5 +88,11 @@ rename-mapping: AgentRules.enableAgentMonitoring: IsAgentMonitoringEnabled ResubscribeProperties: DataDogResubscribeProperties ResubscribeProperties.azureSubscriptionId: -|arm-id + LinkedResource.id: -|arm-id + MarketplaceSaaSInfo.billedAzureSubscriptionId: -|uuid + MarketplaceSaaSInfo.marketplaceSubscriptionId: -|uuid + MonitoredResource.id: -|arm-id + MonitoredSubscription.subscriptionId: -|uuid + SubscriptionList: DataDogSubscriptionList ``` diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs index da2432af46c1..7dfdddbb0ce7 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs @@ -135,7 +135,7 @@ public async Task GetDefaultKey_MonitorsGetDefaultKey() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogApiKeyContent result = await datadogMonitorResource.GetDefaultKeyAsync(); + DataDogApiKeyContent result = await datadogMonitorResource.GetDefaultKeyAsync(); Console.WriteLine($"Succeeded: {result}"); } @@ -161,7 +161,7 @@ public async Task GetApiKeys_MonitorsListApiKeys() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation and iterate over the result - await foreach (DatadogApiKeyContent item in datadogMonitorResource.GetApiKeysAsync()) + await foreach (DataDogApiKeyContent item in datadogMonitorResource.GetApiKeysAsync()) { Console.WriteLine($"Succeeded: {item}"); } @@ -219,7 +219,7 @@ public async Task GetLinkedResources_MonitorsListLinkedResources() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation and iterate over the result - await foreach (LinkedInfo item in datadogMonitorResource.GetLinkedResourcesAsync()) + await foreach (DataDogLinkedInfo item in datadogMonitorResource.GetLinkedResourcesAsync()) { Console.WriteLine($"Succeeded: {item}"); } @@ -329,7 +329,7 @@ public async Task GetBillingInfo_BillingInfoGet() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation - DatadogBillingInfoResult result = await datadogMonitorResource.GetBillingInfoAsync(); + DataDogBillingInfoResult result = await datadogMonitorResource.GetBillingInfoAsync(); Console.WriteLine($"Succeeded: {result}"); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs index b98a10b8d13a..e9a7de88f1f8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs @@ -43,12 +43,12 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() string configurationName = "default"; MonitoredSubscriptionPropertyData data = new MonitoredSubscriptionPropertyData { - Properties = new SubscriptionList + Properties = new DataDogSubscriptionList { - Operation = OperationData.AddBegin, + Operation = DataDogOperationData.AddBegin, MonitoredSubscriptionList = {new MonitoredSubscription { -SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000000", +SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000000"), Status = MonitoredStatus.Active, TagRules = new MonitoringTagRulesProperties { @@ -74,7 +74,7 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() }, }, new MonitoredSubscription { -SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000001", +SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000001"), Status = MonitoredStatus.Failed, TagRules = new MonitoringTagRulesProperties { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs index b456a08630ca..021a9afdec1e 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs @@ -98,12 +98,12 @@ public async Task Update_MonitorsUpdateMonitoredSubscriptions() // invoke the operation MonitoredSubscriptionPropertyData data = new MonitoredSubscriptionPropertyData { - Properties = new SubscriptionList + Properties = new DataDogSubscriptionList { - Operation = OperationData.AddComplete, + Operation = DataDogOperationData.AddComplete, MonitoredSubscriptionList = {new MonitoredSubscription { -SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000000", +SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000000"), Status = MonitoredStatus.Active, TagRules = new MonitoringTagRulesProperties { @@ -129,7 +129,7 @@ public async Task Update_MonitorsUpdateMonitoredSubscriptions() }, }, new MonitoredSubscription { -SubscriptionId = "/subscriptions/00000000-0000-0000-0000-000000000001", +SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000001"), Status = MonitoredStatus.Failed, TagRules = new MonitoringTagRulesProperties { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs index 4624738603f8..8aacdfbd8b3b 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs @@ -36,7 +36,7 @@ public async Task GetMarketplaceAgreements_MarketplaceAgreementsList() SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); // invoke the operation and iterate over the result - await foreach (DatadogAgreementResourceContent item in subscriptionResource.GetMarketplaceAgreementsAsync()) + await foreach (DataDogAgreementResourceContent item in subscriptionResource.GetMarketplaceAgreementsAsync()) { Console.WriteLine($"Succeeded: {item}"); } @@ -63,14 +63,14 @@ public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreate SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); // invoke the operation - DatadogAgreementResourceContent content = new DatadogAgreementResourceContent + DataDogAgreementResourceContent content = new DataDogAgreementResourceContent { Properties = new DatadogAgreementProperties { IsAccepted = true, }, }; - DatadogAgreementResourceContent result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(content: content); + DataDogAgreementResourceContent result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(content: content); Console.WriteLine($"Succeeded: {result}"); } @@ -126,7 +126,7 @@ public async Task GetCreationSupporteds_CreationSupportedList() // invoke the operation and iterate over the result string datadogOrganizationId = "00000000-0000-0000-0000"; - await foreach (DatadogCreateResourceSupportedResult item in subscriptionResource.GetCreationSupportedsAsync(datadogOrganizationId)) + await foreach (DataDogCreateResourceSupportedResult item in subscriptionResource.GetCreationSupportedsAsync(datadogOrganizationId)) { Console.WriteLine($"Succeeded: {item}"); } @@ -154,7 +154,7 @@ public async Task GetCreationSupported_CreationSupportedGet() // invoke the operation string datadogOrganizationId = "00000000-0000-0000-0000"; - DatadogCreateResourceSupportedResult result = await subscriptionResource.GetCreationSupportedAsync(datadogOrganizationId); + DataDogCreateResourceSupportedResult result = await subscriptionResource.GetCreationSupportedAsync(datadogOrganizationId); Console.WriteLine($"Succeeded: {result}"); } From 1a72049e5b98e33451504a6e563104544e31b4d5 Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Tue, 23 Sep 2025 15:56:15 +0800 Subject: [PATCH 6/7] updated --- sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md index b147e7bd451c..978e41f36f67 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md @@ -8,8 +8,7 @@ azure-arm: true csharp: true library-name: Datadog namespace: Azure.ResourceManager.Datadog -require: D:\Workspace\Repo\azure-rest-api-specs-pr\specification\datadog\resource-manager\readme.md -#require: https://github.com/Azure/azure-rest-api-specs-pr/blob/30f23d89b692f80b495fb7f45c3e695872460bd1/specification/datadog/resource-manager/readme.md +require: https://github.com/Azure/azure-rest-api-specs-pr/blob/30f23d89b692f80b495fb7f45c3e695872460bd1/specification/datadog/resource-manager/readme.md # tag: package-2025-06 rpaas output-folder: $(this-folder)/Generated clear-output-folder: true From c124c0bcf5ce6f4f01c39646a29c951ad9e95c83 Mon Sep 17 00:00:00 2001 From: Zhonglei Ma Date: Tue, 23 Sep 2025 17:38:55 +0800 Subject: [PATCH 7/7] updated --- .../Azure.ResourceManager.Datadog.net8.0.cs | 124 +++++++++--------- ....ResourceManager.Datadog.netstandard2.0.cs | 124 +++++++++--------- .../src/Generated/ArmDatadogModelFactory.cs | 24 ++-- .../src/Generated/DatadogMonitorResource.cs | 12 +- .../Generated/Extensions/DatadogExtensions.cs | 16 +-- .../MockableDatadogSubscriptionResource.cs | 16 +-- .../AzureResourceManagerDatadogContext.cs | 4 +- ... DataDogAgreementContent.Serialization.cs} | 38 +++--- ...eContent.cs => DataDogAgreementContent.cs} | 12 +- ...MonitoredResourceContent.Serialization.cs} | 46 +++---- ....cs => DataDogMonitoredResourceContent.cs} | 22 ++-- .../Models/DataDogMonitoredStatus.cs | 57 ++++++++ ...reementResourceListResult.Serialization.cs | 6 +- .../DatadogAgreementResourceListResult.cs | 6 +- .../Models/LogRules.Serialization.cs | 12 +- .../src/Generated/Models/LogRules.cs | 20 +-- ...nitoredResourceListResult.Serialization.cs | 6 +- .../Models/MonitoredResourceListResult.cs | 6 +- .../src/Generated/Models/MonitoredStatus.cs | 57 -------- .../MonitoredSubscription.Serialization.cs | 4 +- .../Generated/Models/MonitoredSubscription.cs | 4 +- .../MarketplaceAgreementsRestOperations.cs | 16 +-- .../src/autorest.md | 11 +- .../Samples/Sample_DatadogMonitorResource.cs | 2 +- ...MonitoredSubscriptionPropertyCollection.cs | 16 +-- ...e_MonitoredSubscriptionPropertyResource.cs | 16 +-- .../Sample_MonitoringTagRuleCollection.cs | 6 +- .../Sample_MonitoringTagRuleResource.cs | 6 +- .../Sample_SubscriptionResourceExtensions.cs | 6 +- 29 files changed, 345 insertions(+), 350 deletions(-) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogAgreementResourceContent.Serialization.cs => DataDogAgreementContent.Serialization.cs} (71%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{DatadogAgreementResourceContent.cs => DataDogAgreementContent.cs} (81%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{MonitoredResourceContent.Serialization.cs => DataDogMonitoredResourceContent.Serialization.cs} (71%) rename sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/{MonitoredResourceContent.cs => DataDogMonitoredResourceContent.cs} (76%) create mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredStatus.cs delete mode 100644 sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredStatus.cs diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs index 7515b46700f5..5cd71a9748a0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.net8.0.cs @@ -8,8 +8,8 @@ internal AzureResourceManagerDatadogContext() { } } public static partial class DatadogExtensions { - public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -21,8 +21,8 @@ public static partial class DatadogExtensions public static Azure.Pageable GetDatadogMonitorResources(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetDatadogMonitorResourcesAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } - public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } @@ -52,8 +52,8 @@ protected DatadogMonitorResource() { } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionProperties() { throw null; } public virtual Azure.Response GetMonitoredSubscriptionProperty(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetMonitoredSubscriptionPropertyAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -266,16 +266,16 @@ protected MockableDatadogResourceGroupResource() { } public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager.ArmResource { protected MockableDatadogSubscriptionResource() { } - public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } } namespace Azure.ResourceManager.Datadog.Models @@ -283,19 +283,19 @@ namespace Azure.ResourceManager.Datadog.Models public static partial class ArmDatadogModelFactory { public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? isCreationSupported = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent DataDogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogAgreementContent DataDogAgreementContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DataDogBillingInfoResult DataDogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DataDogCreateResourceSupportedResult DataDogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DataDogLinkedInfo DataDogLinkedInfo(Azure.Core.ResourceIdentifier id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredResourceContent DataDogMonitoredResourceContent(Azure.Core.ResourceIdentifier id = null, bool? sendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? sendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, string skuName = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSetPasswordLink DatadogSetPasswordLink(string setPasswordLink = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(System.Guid? marketplaceSubscriptionId = default(System.Guid?), string marketplaceName = null, string marketplaceStatus = null, System.Guid? billedAzureSubscriptionId = default(System.Guid?), bool? isSubscribed = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(Azure.Core.ResourceIdentifier id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, Azure.ResourceManager.Datadog.Models.DataDogAgentRules agentRules = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } @@ -326,6 +326,17 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogAgreementContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogAgreementContent() { } + public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogAgreementContent 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.Datadog.Models.DataDogAgreementContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogAgreementProperties() { } @@ -344,17 +355,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DataDogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - public DataDogAgreementResourceContent() { } - public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } - protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent 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.Datadog.Models.DataDogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } public partial class DataDogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DataDogApiKeyContent(string key) { } @@ -444,6 +444,41 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogMonitoredResourceContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DataDogMonitoredResourceContent() { } + public Azure.Core.ResourceIdentifier Id { get { throw null; } } + public string ReasonForLogsStatus { get { throw null; } } + public string ReasonForMetricsStatus { get { throw null; } } + public bool? SendingLogs { get { throw null; } } + public bool? SendingMetrics { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogMonitoredResourceContent 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.Datadog.Models.DataDogMonitoredResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct DataDogMonitoredStatus : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public DataDogMonitoredStatus(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus Deleting { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus Failed { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus InProgress { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus left, Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus left, Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus right) { throw null; } + public override string ToString() { throw null; } + } public partial class DatadogMonitorResourcePatch : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogMonitorResourcePatch() { } @@ -583,9 +618,9 @@ public partial class LogRules : System.ClientModel.Primitives.IJsonModel FilteringTags { get { throw null; } } - public bool? IsSendAadLogs { get { throw null; } set { } } - public bool? IsSendResourceLogs { get { throw null; } set { } } - public bool? IsSendSubscriptionLogs { get { throw null; } set { } } + public bool? SendAadLogs { get { throw null; } set { } } + public bool? SendResourceLogs { get { throw null; } set { } } + public bool? SendSubscriptionLogs { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.LogRules 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) { } @@ -628,46 +663,11 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus left, Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus right) { throw null; } public override string ToString() { throw null; } } - public partial class MonitoredResourceContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - internal MonitoredResourceContent() { } - public Azure.Core.ResourceIdentifier Id { get { throw null; } } - public bool? IsSendingLogs { get { throw null; } } - public bool? IsSendingMetrics { get { throw null; } } - public string ReasonForLogsStatus { get { throw null; } } - public string ReasonForMetricsStatus { get { throw null; } } - protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.MonitoredResourceContent 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.Datadog.Models.MonitoredResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct MonitoredStatus : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public MonitoredStatus(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Deleting { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Failed { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus InProgress { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.MonitoredStatus other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.MonitoredStatus (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } - public override string ToString() { throw null; } - } public partial class MonitoredSubscription : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoredSubscription() { } public string Error { get { throw null; } set { } } - public Azure.ResourceManager.Datadog.Models.MonitoredStatus? Status { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus? Status { get { throw null; } set { } } public System.Guid? SubscriptionId { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs index 7515b46700f5..5cd71a9748a0 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/api/Azure.ResourceManager.Datadog.netstandard2.0.cs @@ -8,8 +8,8 @@ internal AzureResourceManagerDatadogContext() { } } public static partial class DatadogExtensions { - public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Response CreateOrUpdateMarketplaceAgreement(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.Response GetCreationSupported(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static System.Threading.Tasks.Task> GetCreationSupportedAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.Pageable GetCreationSupporteds(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -21,8 +21,8 @@ public static partial class DatadogExtensions public static Azure.Pageable GetDatadogMonitorResources(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.AsyncPageable GetDatadogMonitorResourcesAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResource GetDatadogSingleSignOnResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } - public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.Pageable GetMarketplaceAgreements(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public static Azure.AsyncPageable GetMarketplaceAgreementsAsync(this Azure.ResourceManager.Resources.SubscriptionResource subscriptionResource, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyResource GetMonitoredSubscriptionPropertyResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleResource GetMonitoringTagRuleResource(this Azure.ResourceManager.ArmClient client, Azure.Core.ResourceIdentifier id) { throw null; } } @@ -52,8 +52,8 @@ protected DatadogMonitorResource() { } public virtual Azure.AsyncPageable GetHostsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetLinkedResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetLinkedResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMonitoredResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMonitoredResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyCollection GetMonitoredSubscriptionProperties() { throw null; } public virtual Azure.Response GetMonitoredSubscriptionProperty(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetMonitoredSubscriptionPropertyAsync(string configurationName, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } @@ -266,16 +266,16 @@ protected MockableDatadogResourceGroupResource() { } public partial class MockableDatadogSubscriptionResource : Azure.ResourceManager.ArmResource { protected MockableDatadogSubscriptionResource() { } - public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Response CreateOrUpdateMarketplaceAgreement(Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual System.Threading.Tasks.Task> CreateOrUpdateMarketplaceAgreementAsync(Azure.ResourceManager.Datadog.Models.DataDogAgreementContent content = null, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Response GetCreationSupported(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual System.Threading.Tasks.Task> GetCreationSupportedAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetCreationSupporteds(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetCreationSupportedsAsync(string datadogOrganizationId, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.Pageable GetDatadogMonitorResources(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } public virtual Azure.AsyncPageable GetDatadogMonitorResourcesAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } - public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.Pageable GetMarketplaceAgreements(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } + public virtual Azure.AsyncPageable GetMarketplaceAgreementsAsync(System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) { throw null; } } } namespace Azure.ResourceManager.Datadog.Models @@ -283,19 +283,19 @@ namespace Azure.ResourceManager.Datadog.Models public static partial class ArmDatadogModelFactory { public static Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties CreateResourceSupportedProperties(string name = null, bool? isCreationSupported = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent DataDogAgreementResourceContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogAgreementContent DataDogAgreementContent(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DataDogBillingInfoResult DataDogBillingInfoResult(Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo marketplaceSaasInfo = null, Azure.ResourceManager.Datadog.Models.PartnerBillingEntity partnerBillingEntity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DataDogCreateResourceSupportedResult DataDogCreateResourceSupportedResult(Azure.ResourceManager.Datadog.Models.CreateResourceSupportedProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHost DatadogHost(string name = null, System.Collections.Generic.IEnumerable aliases = null, System.Collections.Generic.IEnumerable apps = null, Azure.ResourceManager.Datadog.Models.DatadogHostMetadata meta = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogHostMetadata DatadogHostMetadata(string agentVersion = null, Azure.ResourceManager.Datadog.Models.DatadogInstallMethod installMethod = null, string logsAgentTransport = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogInstallMethod DatadogInstallMethod(string tool = null, string toolVersion = null, string installerVersion = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DataDogLinkedInfo DataDogLinkedInfo(Azure.Core.ResourceIdentifier id = null, Azure.Core.AzureLocation? location = default(Azure.Core.AzureLocation?)) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredResourceContent DataDogMonitoredResourceContent(Azure.Core.ResourceIdentifier id = null, bool? sendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? sendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogMonitorResourceData DatadogMonitorResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, System.Collections.Generic.IDictionary tags = null, Azure.Core.AzureLocation location = default(Azure.Core.AzureLocation), Azure.ResourceManager.Datadog.Models.MonitorProperties properties = null, string skuName = null, Azure.ResourceManager.Models.ManagedServiceIdentity identity = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSetPasswordLink DatadogSetPasswordLink(string setPasswordLink = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties DatadogSingleSignOnProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.SingleSignOnState? singleSignOnState = default(Azure.ResourceManager.Datadog.Models.SingleSignOnState?), string enterpriseAppId = null, System.Uri singleSignOnUri = null) { throw null; } public static Azure.ResourceManager.Datadog.DatadogSingleSignOnResourceData DatadogSingleSignOnResourceData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DatadogSingleSignOnProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.MarketplaceSaaSInfo MarketplaceSaaSInfo(System.Guid? marketplaceSubscriptionId = default(System.Guid?), string marketplaceName = null, string marketplaceStatus = null, System.Guid? billedAzureSubscriptionId = default(System.Guid?), bool? isSubscribed = default(bool?)) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredResourceContent MonitoredResourceContent(Azure.Core.ResourceIdentifier id = null, bool? isSendingMetrics = default(bool?), string reasonForMetricsStatus = null, bool? isSendingLogs = default(bool?), string reasonForLogsStatus = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoredSubscriptionPropertyData MonitoredSubscriptionPropertyData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.DataDogSubscriptionList properties = null) { throw null; } public static Azure.ResourceManager.Datadog.MonitoringTagRuleData MonitoringTagRuleData(Azure.Core.ResourceIdentifier id = null, string name = null, Azure.Core.ResourceType resourceType = default(Azure.Core.ResourceType), Azure.ResourceManager.Models.SystemData systemData = null, Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties properties = null) { throw null; } public static Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties MonitoringTagRulesProperties(Azure.ResourceManager.Datadog.Models.ProvisioningState? provisioningState = default(Azure.ResourceManager.Datadog.Models.ProvisioningState?), Azure.ResourceManager.Datadog.Models.LogRules logRules = null, System.Collections.Generic.IEnumerable metricRulesFilteringTags = null, Azure.ResourceManager.Datadog.Models.DataDogAgentRules agentRules = null, bool? isAutomuting = default(bool?), bool? isCustomMetrics = default(bool?)) { throw null; } @@ -326,6 +326,17 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogAgreementContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + public DataDogAgreementContent() { } + public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } + protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogAgreementContent 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.Datadog.Models.DataDogAgreementContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } public partial class DatadogAgreementProperties : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogAgreementProperties() { } @@ -344,17 +355,6 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } - public partial class DataDogAgreementResourceContent : Azure.ResourceManager.Models.ResourceData, System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - public DataDogAgreementResourceContent() { } - public Azure.ResourceManager.Datadog.Models.DatadogAgreementProperties Properties { get { throw null; } set { } } - protected override void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.DataDogAgreementResourceContent 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.Datadog.Models.DataDogAgreementResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } public partial class DataDogApiKeyContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DataDogApiKeyContent(string key) { } @@ -444,6 +444,41 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } } + public partial class DataDogMonitoredResourceContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel + { + internal DataDogMonitoredResourceContent() { } + public Azure.Core.ResourceIdentifier Id { get { throw null; } } + public string ReasonForLogsStatus { get { throw null; } } + public string ReasonForMetricsStatus { get { throw null; } } + public bool? SendingLogs { get { throw null; } } + public bool? SendingMetrics { get { throw null; } } + protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } + Azure.ResourceManager.Datadog.Models.DataDogMonitoredResourceContent 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.Datadog.Models.DataDogMonitoredResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } + } + [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] + public readonly partial struct DataDogMonitoredStatus : System.IEquatable + { + private readonly object _dummy; + private readonly int _dummyPrimitive; + public DataDogMonitoredStatus(string value) { throw null; } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus Active { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus Deleting { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus Failed { get { throw null; } } + public static Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus InProgress { get { throw null; } } + public bool Equals(Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus other) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override bool Equals(object obj) { throw null; } + [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] + public override int GetHashCode() { throw null; } + public static bool operator ==(Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus left, Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus right) { throw null; } + public static implicit operator Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus (string value) { throw null; } + public static bool operator !=(Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus left, Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus right) { throw null; } + public override string ToString() { throw null; } + } public partial class DatadogMonitorResourcePatch : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public DatadogMonitorResourcePatch() { } @@ -583,9 +618,9 @@ public partial class LogRules : System.ClientModel.Primitives.IJsonModel FilteringTags { get { throw null; } } - public bool? IsSendAadLogs { get { throw null; } set { } } - public bool? IsSendResourceLogs { get { throw null; } set { } } - public bool? IsSendSubscriptionLogs { get { throw null; } set { } } + public bool? SendAadLogs { get { throw null; } set { } } + public bool? SendResourceLogs { get { throw null; } set { } } + public bool? SendSubscriptionLogs { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } Azure.ResourceManager.Datadog.Models.LogRules 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) { } @@ -628,46 +663,11 @@ protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer public static bool operator !=(Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus left, Azure.ResourceManager.Datadog.Models.MarketplaceSubscriptionStatus right) { throw null; } public override string ToString() { throw null; } } - public partial class MonitoredResourceContent : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel - { - internal MonitoredResourceContent() { } - public Azure.Core.ResourceIdentifier Id { get { throw null; } } - public bool? IsSendingLogs { get { throw null; } } - public bool? IsSendingMetrics { get { throw null; } } - public string ReasonForLogsStatus { get { throw null; } } - public string ReasonForMetricsStatus { get { throw null; } } - protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } - Azure.ResourceManager.Datadog.Models.MonitoredResourceContent 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.Datadog.Models.MonitoredResourceContent System.ClientModel.Primitives.IPersistableModel.Create(System.BinaryData data, System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - string System.ClientModel.Primitives.IPersistableModel.GetFormatFromOptions(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - System.BinaryData System.ClientModel.Primitives.IPersistableModel.Write(System.ClientModel.Primitives.ModelReaderWriterOptions options) { throw null; } - } - [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Sequential)] - public readonly partial struct MonitoredStatus : System.IEquatable - { - private readonly object _dummy; - private readonly int _dummyPrimitive; - public MonitoredStatus(string value) { throw null; } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Active { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Deleting { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus Failed { get { throw null; } } - public static Azure.ResourceManager.Datadog.Models.MonitoredStatus InProgress { get { throw null; } } - public bool Equals(Azure.ResourceManager.Datadog.Models.MonitoredStatus other) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override bool Equals(object obj) { throw null; } - [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)] - public override int GetHashCode() { throw null; } - public static bool operator ==(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } - public static implicit operator Azure.ResourceManager.Datadog.Models.MonitoredStatus (string value) { throw null; } - public static bool operator !=(Azure.ResourceManager.Datadog.Models.MonitoredStatus left, Azure.ResourceManager.Datadog.Models.MonitoredStatus right) { throw null; } - public override string ToString() { throw null; } - } public partial class MonitoredSubscription : System.ClientModel.Primitives.IJsonModel, System.ClientModel.Primitives.IPersistableModel { public MonitoredSubscription() { } public string Error { get { throw null; } set { } } - public Azure.ResourceManager.Datadog.Models.MonitoredStatus? Status { get { throw null; } set { } } + public Azure.ResourceManager.Datadog.Models.DataDogMonitoredStatus? Status { get { throw null; } set { } } public System.Guid? SubscriptionId { get { throw null; } set { } } public Azure.ResourceManager.Datadog.Models.MonitoringTagRulesProperties TagRules { get { throw null; } set { } } protected virtual void JsonModelWriteCore(System.Text.Json.Utf8JsonWriter writer, System.ClientModel.Primitives.ModelReaderWriterOptions options) { } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs index 68df54ec62bd..0acef961f712 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/ArmDatadogModelFactory.cs @@ -16,16 +16,16 @@ namespace Azure.ResourceManager.Datadog.Models /// Model factory for models. public static partial class ArmDatadogModelFactory { - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. /// Represents the properties of the resource. - /// A new instance for mocking. - public static DataDogAgreementResourceContent DataDogAgreementResourceContent(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogAgreementProperties properties = null) + /// A new instance for mocking. + public static DataDogAgreementContent DataDogAgreementContent(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, DatadogAgreementProperties properties = null) { - return new DataDogAgreementResourceContent( + return new DataDogAgreementContent( id, name, resourceType, @@ -181,20 +181,20 @@ public static DataDogLinkedInfo DataDogLinkedInfo(ResourceIdentifier id = null, return new DataDogLinkedInfo(id, location, serializedAdditionalRawData: null); } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The ARM id of the resource. - /// Flag indicating if resource is sending metrics to Datadog. + /// Flag indicating if resource is sending metrics to Datadog. /// Reason for why the resource is sending metrics (or why it is not sending). - /// Flag indicating if resource is sending logs to Datadog. + /// Flag indicating if resource is sending logs to Datadog. /// Reason for why the resource is sending logs (or why it is not sending). - /// A new instance for mocking. - public static MonitoredResourceContent MonitoredResourceContent(ResourceIdentifier id = null, bool? isSendingMetrics = null, string reasonForMetricsStatus = null, bool? isSendingLogs = null, string reasonForLogsStatus = null) + /// A new instance for mocking. + public static DataDogMonitoredResourceContent DataDogMonitoredResourceContent(ResourceIdentifier id = null, bool? sendingMetrics = null, string reasonForMetricsStatus = null, bool? sendingLogs = null, string reasonForLogsStatus = null) { - return new MonitoredResourceContent( + return new DataDogMonitoredResourceContent( id, - isSendingMetrics, + sendingMetrics, reasonForMetricsStatus, - isSendingLogs, + sendingLogs, reasonForLogsStatus, serializedAdditionalRawData: null); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs index a3429a6e537f..2d320f2df0ce 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/DatadogMonitorResource.cs @@ -840,12 +840,12 @@ public virtual Pageable GetLinkedResources(CancellationToken /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetMonitoredResourcesAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetMonitoredResourcesAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListMonitoredResourcesRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListMonitoredResourcesNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => MonitoredResourceContent.DeserializeMonitoredResourceContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetMonitoredResources", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DataDogMonitoredResourceContent.DeserializeDataDogMonitoredResourceContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetMonitoredResources", "value", "nextLink", cancellationToken); } /// @@ -870,12 +870,12 @@ public virtual AsyncPageable GetMonitoredResourcesAsyn /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetMonitoredResources(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetMonitoredResources(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => _datadogMonitorResourceMonitorsRestClient.CreateListMonitoredResourcesRequest(Id.SubscriptionId, Id.ResourceGroupName, Id.Name); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => _datadogMonitorResourceMonitorsRestClient.CreateListMonitoredResourcesNextPageRequest(nextLink, Id.SubscriptionId, Id.ResourceGroupName, Id.Name); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => MonitoredResourceContent.DeserializeMonitoredResourceContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetMonitoredResources", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DataDogMonitoredResourceContent.DeserializeDataDogMonitoredResourceContent(e), _datadogMonitorResourceMonitorsClientDiagnostics, Pipeline, "DatadogMonitorResource.GetMonitoredResources", "value", "nextLink", cancellationToken); } /// diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs index 0d0683a9c62f..06e57e526cfd 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/DatadogExtensions.cs @@ -226,8 +226,8 @@ public static Response GetDatadogMonitorResource(this Re /// The instance the method will execute against. /// The cancellation token to use. /// is null. - /// An async collection of that may take multiple service requests to iterate over. - public static AsyncPageable GetMarketplaceAgreementsAsync(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public static AsyncPageable GetMarketplaceAgreementsAsync(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -258,8 +258,8 @@ public static AsyncPageable GetMarketplaceAgree /// The instance the method will execute against. /// The cancellation token to use. /// is null. - /// A collection of that may take multiple service requests to iterate over. - public static Pageable GetMarketplaceAgreements(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public static Pageable GetMarketplaceAgreements(this SubscriptionResource subscriptionResource, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -284,14 +284,14 @@ public static Pageable GetMarketplaceAgreements /// /// /// Mocking - /// To mock this method, please mock instead. + /// To mock this method, please mock instead. /// /// /// The instance the method will execute against. /// The request body. /// The cancellation token to use. /// is null. - public static async Task> CreateOrUpdateMarketplaceAgreementAsync(this SubscriptionResource subscriptionResource, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public static async Task> CreateOrUpdateMarketplaceAgreementAsync(this SubscriptionResource subscriptionResource, DataDogAgreementContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); @@ -316,14 +316,14 @@ public static async Task> CreateOrUpda /// /// /// Mocking - /// To mock this method, please mock instead. + /// To mock this method, please mock instead. /// /// /// The instance the method will execute against. /// The request body. /// The cancellation token to use. /// is null. - public static Response CreateOrUpdateMarketplaceAgreement(this SubscriptionResource subscriptionResource, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public static Response CreateOrUpdateMarketplaceAgreement(this SubscriptionResource subscriptionResource, DataDogAgreementContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNull(subscriptionResource, nameof(subscriptionResource)); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs index 17de196befe5..867b2c9f4ebd 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Extensions/MockableDatadogSubscriptionResource.cs @@ -68,12 +68,12 @@ private string GetApiVersionOrNull(ResourceType resourceType) /// /// /// The cancellation token to use. - /// An async collection of that may take multiple service requests to iterate over. - public virtual AsyncPageable GetMarketplaceAgreementsAsync(CancellationToken cancellationToken = default) + /// An async collection of that may take multiple service requests to iterate over. + public virtual AsyncPageable GetMarketplaceAgreementsAsync(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => MarketplaceAgreementsRestClient.CreateListRequest(Id.SubscriptionId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => MarketplaceAgreementsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId); - return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => DataDogAgreementContent.DeserializeDataDogAgreementContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); } /// @@ -94,12 +94,12 @@ public virtual AsyncPageable GetMarketplaceAgre /// /// /// The cancellation token to use. - /// A collection of that may take multiple service requests to iterate over. - public virtual Pageable GetMarketplaceAgreements(CancellationToken cancellationToken = default) + /// A collection of that may take multiple service requests to iterate over. + public virtual Pageable GetMarketplaceAgreements(CancellationToken cancellationToken = default) { HttpMessage FirstPageRequest(int? pageSizeHint) => MarketplaceAgreementsRestClient.CreateListRequest(Id.SubscriptionId); HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => MarketplaceAgreementsRestClient.CreateListNextPageRequest(nextLink, Id.SubscriptionId); - return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); + return GeneratorPageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => DataDogAgreementContent.DeserializeDataDogAgreementContent(e), MarketplaceAgreementsClientDiagnostics, Pipeline, "MockableDatadogSubscriptionResource.GetMarketplaceAgreements", "value", "nextLink", cancellationToken); } /// @@ -121,7 +121,7 @@ public virtual Pageable GetMarketplaceAgreement /// /// The request body. /// The cancellation token to use. - public virtual async Task> CreateOrUpdateMarketplaceAgreementAsync(DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public virtual async Task> CreateOrUpdateMarketplaceAgreementAsync(DataDogAgreementContent content = null, CancellationToken cancellationToken = default) { using var scope = MarketplaceAgreementsClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.CreateOrUpdateMarketplaceAgreement"); scope.Start(); @@ -156,7 +156,7 @@ public virtual async Task> CreateOrUpd /// /// The request body. /// The cancellation token to use. - public virtual Response CreateOrUpdateMarketplaceAgreement(DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public virtual Response CreateOrUpdateMarketplaceAgreement(DataDogAgreementContent content = null, CancellationToken cancellationToken = default) { using var scope = MarketplaceAgreementsClientDiagnostics.CreateScope("MockableDatadogSubscriptionResource.CreateOrUpdateMarketplaceAgreement"); scope.Start(); diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs index ad5f3a1c9a59..bc683c81d40c 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/AzureResourceManagerDatadogContext.cs @@ -18,8 +18,8 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(CreateResourceSupportedProperties))] [ModelReaderWriterBuildable(typeof(CreateResourceSupportedResultList))] [ModelReaderWriterBuildable(typeof(DataDogAgentRules))] + [ModelReaderWriterBuildable(typeof(DataDogAgreementContent))] [ModelReaderWriterBuildable(typeof(DatadogAgreementProperties))] - [ModelReaderWriterBuildable(typeof(DataDogAgreementResourceContent))] [ModelReaderWriterBuildable(typeof(DataDogAgreementResourceListResult))] [ModelReaderWriterBuildable(typeof(DataDogApiKeyContent))] [ModelReaderWriterBuildable(typeof(DataDogApiKeyListResult))] @@ -31,6 +31,7 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(DatadogInstallMethod))] [ModelReaderWriterBuildable(typeof(DataDogLinkedInfo))] [ModelReaderWriterBuildable(typeof(DatadogLogsAgent))] + [ModelReaderWriterBuildable(typeof(DataDogMonitoredResourceContent))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResource))] [ModelReaderWriterBuildable(typeof(DatadogMonitorResourceData))] [ModelReaderWriterBuildable(typeof(DataDogMonitorResourceListResult))] @@ -49,7 +50,6 @@ namespace Azure.ResourceManager.Datadog [ModelReaderWriterBuildable(typeof(ManagedServiceIdentity))] [ModelReaderWriterBuildable(typeof(MarketplaceSaaSInfo))] [ModelReaderWriterBuildable(typeof(MetricRules))] - [ModelReaderWriterBuildable(typeof(MonitoredResourceContent))] [ModelReaderWriterBuildable(typeof(MonitoredResourceListResult))] [ModelReaderWriterBuildable(typeof(MonitoredSubscription))] [ModelReaderWriterBuildable(typeof(MonitoredSubscriptionPropertiesList))] diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgreementContent.Serialization.cs similarity index 71% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgreementContent.Serialization.cs index 3294a267ed74..e2328a7853c4 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgreementContent.Serialization.cs @@ -15,11 +15,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class DataDogAgreementResourceContent : IUtf8JsonSerializable, IJsonModel + public partial class DataDogAgreementContent : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -30,10 +30,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, Mo /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementContent)} does not support writing '{format}' format."); } base.JsonModelWriteCore(writer, options); @@ -44,19 +44,19 @@ protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWri } } - DataDogAgreementResourceContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogAgreementContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementContent)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeDataDogAgreementResourceContent(document.RootElement, options); + return DeserializeDataDogAgreementContent(document.RootElement, options); } - internal static DataDogAgreementResourceContent DeserializeDataDogAgreementResourceContent(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogAgreementContent DeserializeDataDogAgreementContent(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -112,7 +112,7 @@ internal static DataDogAgreementResourceContent DeserializeDataDogAgreementResou } } serializedAdditionalRawData = rawDataDictionary; - return new DataDogAgreementResourceContent( + return new DataDogAgreementContent( id, name, type, @@ -121,35 +121,35 @@ internal static DataDogAgreementResourceContent DeserializeDataDogAgreementResou serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementContent)} does not support writing '{options.Format}' format."); } } - DataDogAgreementResourceContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogAgreementContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeDataDogAgreementResourceContent(document.RootElement, options); + return DeserializeDataDogAgreementContent(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(DataDogAgreementResourceContent)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogAgreementContent)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgreementContent.cs similarity index 81% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgreementContent.cs index 2c65869648da..754e44c4642d 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceContent.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogAgreementContent.cs @@ -12,8 +12,8 @@ namespace Azure.ResourceManager.Datadog.Models { - /// The DataDogAgreementResourceContent. - public partial class DataDogAgreementResourceContent : ResourceData + /// The DataDogAgreementContent. + public partial class DataDogAgreementContent : ResourceData { /// /// Keeps track of any properties unknown to the library. @@ -47,19 +47,19 @@ public partial class DataDogAgreementResourceContent : ResourceData /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - public DataDogAgreementResourceContent() + /// Initializes a new instance of . + public DataDogAgreementContent() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The id. /// The name. /// The resourceType. /// The systemData. /// Represents the properties of the resource. /// Keeps track of any properties unknown to the library. - internal DataDogAgreementResourceContent(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DatadogAgreementProperties properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) + internal DataDogAgreementContent(ResourceIdentifier id, string name, ResourceType resourceType, SystemData systemData, DatadogAgreementProperties properties, IDictionary serializedAdditionalRawData) : base(id, name, resourceType, systemData) { Properties = properties; _serializedAdditionalRawData = serializedAdditionalRawData; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredResourceContent.Serialization.cs similarity index 71% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredResourceContent.Serialization.cs index 7725ab5ca079..60a4184f5ed1 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredResourceContent.Serialization.cs @@ -13,11 +13,11 @@ namespace Azure.ResourceManager.Datadog.Models { - public partial class MonitoredResourceContent : IUtf8JsonSerializable, IJsonModel + public partial class DataDogMonitoredResourceContent : IUtf8JsonSerializable, IJsonModel { - void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); + void IUtf8JsonSerializable.Write(Utf8JsonWriter writer) => ((IJsonModel)this).Write(writer, ModelSerializationExtensions.WireOptions); - void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) + void IJsonModel.Write(Utf8JsonWriter writer, ModelReaderWriterOptions options) { writer.WriteStartObject(); JsonModelWriteCore(writer, options); @@ -28,10 +28,10 @@ void IJsonModel.Write(Utf8JsonWriter writer, ModelRead /// 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; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(MonitoredResourceContent)} does not support writing '{format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitoredResourceContent)} does not support writing '{format}' format."); } if (Optional.IsDefined(Id)) @@ -39,20 +39,20 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit writer.WritePropertyName("id"u8); writer.WriteStringValue(Id); } - if (Optional.IsDefined(IsSendingMetrics)) + if (Optional.IsDefined(SendingMetrics)) { writer.WritePropertyName("sendingMetrics"u8); - writer.WriteBooleanValue(IsSendingMetrics.Value); + writer.WriteBooleanValue(SendingMetrics.Value); } if (Optional.IsDefined(ReasonForMetricsStatus)) { writer.WritePropertyName("reasonForMetricsStatus"u8); writer.WriteStringValue(ReasonForMetricsStatus); } - if (Optional.IsDefined(IsSendingLogs)) + if (Optional.IsDefined(SendingLogs)) { writer.WritePropertyName("sendingLogs"u8); - writer.WriteBooleanValue(IsSendingLogs.Value); + writer.WriteBooleanValue(SendingLogs.Value); } if (Optional.IsDefined(ReasonForLogsStatus)) { @@ -76,19 +76,19 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit } } - MonitoredResourceContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) + DataDogMonitoredResourceContent IJsonModel.Create(ref Utf8JsonReader reader, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; if (format != "J") { - throw new FormatException($"The model {nameof(MonitoredResourceContent)} does not support reading '{format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitoredResourceContent)} does not support reading '{format}' format."); } using JsonDocument document = JsonDocument.ParseValue(ref reader); - return DeserializeMonitoredResourceContent(document.RootElement, options); + return DeserializeDataDogMonitoredResourceContent(document.RootElement, options); } - internal static MonitoredResourceContent DeserializeMonitoredResourceContent(JsonElement element, ModelReaderWriterOptions options = null) + internal static DataDogMonitoredResourceContent DeserializeDataDogMonitoredResourceContent(JsonElement element, ModelReaderWriterOptions options = null) { options ??= ModelSerializationExtensions.WireOptions; @@ -148,7 +148,7 @@ internal static MonitoredResourceContent DeserializeMonitoredResourceContent(Jso } } serializedAdditionalRawData = rawDataDictionary; - return new MonitoredResourceContent( + return new DataDogMonitoredResourceContent( id, sendingMetrics, reasonForMetricsStatus, @@ -157,35 +157,35 @@ internal static MonitoredResourceContent DeserializeMonitoredResourceContent(Jso serializedAdditionalRawData); } - BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) + BinaryData IPersistableModel.Write(ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": return ModelReaderWriter.Write(this, options, AzureResourceManagerDatadogContext.Default); default: - throw new FormatException($"The model {nameof(MonitoredResourceContent)} does not support writing '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitoredResourceContent)} does not support writing '{options.Format}' format."); } } - MonitoredResourceContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) + DataDogMonitoredResourceContent IPersistableModel.Create(BinaryData data, ModelReaderWriterOptions options) { - var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; + var format = options.Format == "W" ? ((IPersistableModel)this).GetFormatFromOptions(options) : options.Format; switch (format) { case "J": { using JsonDocument document = JsonDocument.Parse(data, ModelSerializationExtensions.JsonDocumentOptions); - return DeserializeMonitoredResourceContent(document.RootElement, options); + return DeserializeDataDogMonitoredResourceContent(document.RootElement, options); } default: - throw new FormatException($"The model {nameof(MonitoredResourceContent)} does not support reading '{options.Format}' format."); + throw new FormatException($"The model {nameof(DataDogMonitoredResourceContent)} does not support reading '{options.Format}' format."); } } - string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; + string IPersistableModel.GetFormatFromOptions(ModelReaderWriterOptions options) => "J"; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredResourceContent.cs similarity index 76% rename from sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs rename to sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredResourceContent.cs index 6dba70fefa68..814508fa08ce 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceContent.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredResourceContent.cs @@ -12,7 +12,7 @@ namespace Azure.ResourceManager.Datadog.Models { /// The properties of a resource currently being monitored by the Datadog monitor resource. - public partial class MonitoredResourceContent + public partial class DataDogMonitoredResourceContent { /// /// Keeps track of any properties unknown to the library. @@ -46,24 +46,24 @@ public partial class MonitoredResourceContent /// private IDictionary _serializedAdditionalRawData; - /// Initializes a new instance of . - internal MonitoredResourceContent() + /// Initializes a new instance of . + internal DataDogMonitoredResourceContent() { } - /// Initializes a new instance of . + /// Initializes a new instance of . /// The ARM id of the resource. - /// Flag indicating if resource is sending metrics to Datadog. + /// Flag indicating if resource is sending metrics to Datadog. /// Reason for why the resource is sending metrics (or why it is not sending). - /// Flag indicating if resource is sending logs to Datadog. + /// Flag indicating if resource is sending logs to Datadog. /// Reason for why the resource is sending logs (or why it is not sending). /// Keeps track of any properties unknown to the library. - internal MonitoredResourceContent(ResourceIdentifier id, bool? isSendingMetrics, string reasonForMetricsStatus, bool? isSendingLogs, string reasonForLogsStatus, IDictionary serializedAdditionalRawData) + internal DataDogMonitoredResourceContent(ResourceIdentifier id, bool? sendingMetrics, string reasonForMetricsStatus, bool? sendingLogs, string reasonForLogsStatus, IDictionary serializedAdditionalRawData) { Id = id; - IsSendingMetrics = isSendingMetrics; + SendingMetrics = sendingMetrics; ReasonForMetricsStatus = reasonForMetricsStatus; - IsSendingLogs = isSendingLogs; + SendingLogs = sendingLogs; ReasonForLogsStatus = reasonForLogsStatus; _serializedAdditionalRawData = serializedAdditionalRawData; } @@ -71,11 +71,11 @@ internal MonitoredResourceContent(ResourceIdentifier id, bool? isSendingMetrics, /// The ARM id of the resource. public ResourceIdentifier Id { get; } /// Flag indicating if resource is sending metrics to Datadog. - public bool? IsSendingMetrics { get; } + public bool? SendingMetrics { get; } /// Reason for why the resource is sending metrics (or why it is not sending). public string ReasonForMetricsStatus { get; } /// Flag indicating if resource is sending logs to Datadog. - public bool? IsSendingLogs { get; } + public bool? SendingLogs { get; } /// Reason for why the resource is sending logs (or why it is not sending). public string ReasonForLogsStatus { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredStatus.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredStatus.cs new file mode 100644 index 000000000000..f62b59ca9cc5 --- /dev/null +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DataDogMonitoredStatus.cs @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. + +// + +#nullable disable + +using System; +using System.ComponentModel; + +namespace Azure.ResourceManager.Datadog.Models +{ + /// The state of monitoring. + public readonly partial struct DataDogMonitoredStatus : IEquatable + { + private readonly string _value; + + /// Initializes a new instance of . + /// is null. + public DataDogMonitoredStatus(string value) + { + _value = value ?? throw new ArgumentNullException(nameof(value)); + } + + private const string InProgressValue = "InProgress"; + private const string ActiveValue = "Active"; + private const string FailedValue = "Failed"; + private const string DeletingValue = "Deleting"; + + /// InProgress. + public static DataDogMonitoredStatus InProgress { get; } = new DataDogMonitoredStatus(InProgressValue); + /// Active. + public static DataDogMonitoredStatus Active { get; } = new DataDogMonitoredStatus(ActiveValue); + /// Failed. + public static DataDogMonitoredStatus Failed { get; } = new DataDogMonitoredStatus(FailedValue); + /// Deleting. + public static DataDogMonitoredStatus Deleting { get; } = new DataDogMonitoredStatus(DeletingValue); + /// Determines if two values are the same. + public static bool operator ==(DataDogMonitoredStatus left, DataDogMonitoredStatus right) => left.Equals(right); + /// Determines if two values are not the same. + public static bool operator !=(DataDogMonitoredStatus left, DataDogMonitoredStatus right) => !left.Equals(right); + /// Converts a to a . + public static implicit operator DataDogMonitoredStatus(string value) => new DataDogMonitoredStatus(value); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override bool Equals(object obj) => obj is DataDogMonitoredStatus other && Equals(other); + /// + public bool Equals(DataDogMonitoredStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); + + /// + [EditorBrowsable(EditorBrowsableState.Never)] + public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0; + /// + public override string ToString() => _value; + } +} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs index 7fd45d7f54c6..06e5390936d5 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.Serialization.cs @@ -83,7 +83,7 @@ internal static DataDogAgreementResourceListResult DeserializeDataDogAgreementRe { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static DataDogAgreementResourceListResult DeserializeDataDogAgreementRe { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(item, options)); + array.Add(DataDogAgreementContent.DeserializeDataDogAgreementContent(item, options)); } value = array; continue; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs index 3631af9df30b..e0f712aa7b40 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/DatadogAgreementResourceListResult.cs @@ -49,7 +49,7 @@ internal partial class DataDogAgreementResourceListResult /// Initializes a new instance of . /// The DatadogAgreementResource items on this page. /// is null. - internal DataDogAgreementResourceListResult(IEnumerable value) + internal DataDogAgreementResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); @@ -60,7 +60,7 @@ internal DataDogAgreementResourceListResult(IEnumerable The DatadogAgreementResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal DataDogAgreementResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal DataDogAgreementResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; @@ -73,7 +73,7 @@ internal DataDogAgreementResourceListResult() } /// The DatadogAgreementResource items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs index 01be35c95630..da30d3c49b31 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.Serialization.cs @@ -34,20 +34,20 @@ protected virtual void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWrit throw new FormatException($"The model {nameof(LogRules)} does not support writing '{format}' format."); } - if (Optional.IsDefined(IsSendAadLogs)) + if (Optional.IsDefined(SendAadLogs)) { writer.WritePropertyName("sendAadLogs"u8); - writer.WriteBooleanValue(IsSendAadLogs.Value); + writer.WriteBooleanValue(SendAadLogs.Value); } - if (Optional.IsDefined(IsSendSubscriptionLogs)) + if (Optional.IsDefined(SendSubscriptionLogs)) { writer.WritePropertyName("sendSubscriptionLogs"u8); - writer.WriteBooleanValue(IsSendSubscriptionLogs.Value); + writer.WriteBooleanValue(SendSubscriptionLogs.Value); } - if (Optional.IsDefined(IsSendResourceLogs)) + if (Optional.IsDefined(SendResourceLogs)) { writer.WritePropertyName("sendResourceLogs"u8); - writer.WriteBooleanValue(IsSendResourceLogs.Value); + writer.WriteBooleanValue(SendResourceLogs.Value); } if (Optional.IsCollectionDefined(FilteringTags)) { diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs index af7182b4e11f..e1ef9bc516d7 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/LogRules.cs @@ -52,26 +52,26 @@ public LogRules() } /// Initializes a new instance of . - /// Flag specifying if AAD logs should be sent for the Monitor resource. - /// Flag specifying if Azure subscription logs should be sent for the Monitor resource. - /// Flag specifying if Azure resource logs should be sent for the Monitor resource. + /// Flag specifying if AAD logs should be sent for the Monitor resource. + /// Flag specifying if Azure subscription logs should be sent for the Monitor resource. + /// Flag specifying if Azure resource logs should be sent for the Monitor resource. /// List of filtering tags to be used for capturing logs. This only takes effect if SendResourceLogs flag is enabled. If empty, all resources will be captured. If only Exclude action is specified, the rules will apply to the list of all available resources. If Include actions are specified, the rules will only include resources with the associated tags. /// Keeps track of any properties unknown to the library. - internal LogRules(bool? isSendAadLogs, bool? isSendSubscriptionLogs, bool? isSendResourceLogs, IList filteringTags, IDictionary serializedAdditionalRawData) + internal LogRules(bool? sendAadLogs, bool? sendSubscriptionLogs, bool? sendResourceLogs, IList filteringTags, IDictionary serializedAdditionalRawData) { - IsSendAadLogs = isSendAadLogs; - IsSendSubscriptionLogs = isSendSubscriptionLogs; - IsSendResourceLogs = isSendResourceLogs; + SendAadLogs = sendAadLogs; + SendSubscriptionLogs = sendSubscriptionLogs; + SendResourceLogs = sendResourceLogs; FilteringTags = filteringTags; _serializedAdditionalRawData = serializedAdditionalRawData; } /// Flag specifying if AAD logs should be sent for the Monitor resource. - public bool? IsSendAadLogs { get; set; } + public bool? SendAadLogs { get; set; } /// Flag specifying if Azure subscription logs should be sent for the Monitor resource. - public bool? IsSendSubscriptionLogs { get; set; } + public bool? SendSubscriptionLogs { get; set; } /// Flag specifying if Azure resource logs should be sent for the Monitor resource. - public bool? IsSendResourceLogs { get; set; } + public bool? SendResourceLogs { get; set; } /// List of filtering tags to be used for capturing logs. This only takes effect if SendResourceLogs flag is enabled. If empty, all resources will be captured. If only Exclude action is specified, the rules will apply to the list of all available resources. If Include actions are specified, the rules will only include resources with the associated tags. public IList FilteringTags { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.Serialization.cs index 2ca3c7e09a42..54107a49aed2 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.Serialization.cs @@ -83,7 +83,7 @@ internal static MonitoredResourceListResult DeserializeMonitoredResourceListResu { return null; } - IReadOnlyList value = default; + IReadOnlyList value = default; Uri nextLink = default; IDictionary serializedAdditionalRawData = default; Dictionary rawDataDictionary = new Dictionary(); @@ -91,10 +91,10 @@ internal static MonitoredResourceListResult DeserializeMonitoredResourceListResu { if (property.NameEquals("value"u8)) { - List array = new List(); + List array = new List(); foreach (var item in property.Value.EnumerateArray()) { - array.Add(MonitoredResourceContent.DeserializeMonitoredResourceContent(item, options)); + array.Add(DataDogMonitoredResourceContent.DeserializeDataDogMonitoredResourceContent(item, options)); } value = array; continue; diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.cs index 80fb32f5ff5c..2737054b7bac 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredResourceListResult.cs @@ -49,7 +49,7 @@ internal partial class MonitoredResourceListResult /// Initializes a new instance of . /// The MonitoredResource items on this page. /// is null. - internal MonitoredResourceListResult(IEnumerable value) + internal MonitoredResourceListResult(IEnumerable value) { Argument.AssertNotNull(value, nameof(value)); @@ -60,7 +60,7 @@ internal MonitoredResourceListResult(IEnumerable value /// The MonitoredResource items on this page. /// The link to the next page of items. /// Keeps track of any properties unknown to the library. - internal MonitoredResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) + internal MonitoredResourceListResult(IReadOnlyList value, Uri nextLink, IDictionary serializedAdditionalRawData) { Value = value; NextLink = nextLink; @@ -73,7 +73,7 @@ internal MonitoredResourceListResult() } /// The MonitoredResource items on this page. - public IReadOnlyList Value { get; } + public IReadOnlyList Value { get; } /// The link to the next page of items. public Uri NextLink { get; } } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredStatus.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredStatus.cs deleted file mode 100644 index 0cb6b285161f..000000000000 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredStatus.cs +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. - -// - -#nullable disable - -using System; -using System.ComponentModel; - -namespace Azure.ResourceManager.Datadog.Models -{ - /// The state of monitoring. - public readonly partial struct MonitoredStatus : IEquatable - { - private readonly string _value; - - /// Initializes a new instance of . - /// is null. - public MonitoredStatus(string value) - { - _value = value ?? throw new ArgumentNullException(nameof(value)); - } - - private const string InProgressValue = "InProgress"; - private const string ActiveValue = "Active"; - private const string FailedValue = "Failed"; - private const string DeletingValue = "Deleting"; - - /// InProgress. - public static MonitoredStatus InProgress { get; } = new MonitoredStatus(InProgressValue); - /// Active. - public static MonitoredStatus Active { get; } = new MonitoredStatus(ActiveValue); - /// Failed. - public static MonitoredStatus Failed { get; } = new MonitoredStatus(FailedValue); - /// Deleting. - public static MonitoredStatus Deleting { get; } = new MonitoredStatus(DeletingValue); - /// Determines if two values are the same. - public static bool operator ==(MonitoredStatus left, MonitoredStatus right) => left.Equals(right); - /// Determines if two values are not the same. - public static bool operator !=(MonitoredStatus left, MonitoredStatus right) => !left.Equals(right); - /// Converts a to a . - public static implicit operator MonitoredStatus(string value) => new MonitoredStatus(value); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override bool Equals(object obj) => obj is MonitoredStatus other && Equals(other); - /// - public bool Equals(MonitoredStatus other) => string.Equals(_value, other._value, StringComparison.InvariantCultureIgnoreCase); - - /// - [EditorBrowsable(EditorBrowsableState.Never)] - public override int GetHashCode() => _value != null ? StringComparer.InvariantCultureIgnoreCase.GetHashCode(_value) : 0; - /// - public override string ToString() => _value; - } -} diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs index 59bef683e262..d85d8368a404 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.Serialization.cs @@ -92,7 +92,7 @@ internal static MonitoredSubscription DeserializeMonitoredSubscription(JsonEleme return null; } Guid? subscriptionId = default; - MonitoredStatus? status = default; + DataDogMonitoredStatus? status = default; string error = default; MonitoringTagRulesProperties tagRules = default; IDictionary serializedAdditionalRawData = default; @@ -114,7 +114,7 @@ internal static MonitoredSubscription DeserializeMonitoredSubscription(JsonEleme { continue; } - status = new MonitoredStatus(property.Value.GetString()); + status = new DataDogMonitoredStatus(property.Value.GetString()); continue; } if (property.NameEquals("error"u8)) diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs index 37f0d781c332..741c808eb019 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/Models/MonitoredSubscription.cs @@ -56,7 +56,7 @@ public MonitoredSubscription() /// The reason of not monitoring the subscription. /// Definition of the properties for a TagRules resource. /// Keeps track of any properties unknown to the library. - internal MonitoredSubscription(Guid? subscriptionId, MonitoredStatus? status, string error, MonitoringTagRulesProperties tagRules, IDictionary serializedAdditionalRawData) + internal MonitoredSubscription(Guid? subscriptionId, DataDogMonitoredStatus? status, string error, MonitoringTagRulesProperties tagRules, IDictionary serializedAdditionalRawData) { SubscriptionId = subscriptionId; Status = status; @@ -68,7 +68,7 @@ internal MonitoredSubscription(Guid? subscriptionId, MonitoredStatus? status, st /// The subscriptionId to be monitored. public Guid? SubscriptionId { get; set; } /// The state of monitoring. - public MonitoredStatus? Status { get; set; } + public DataDogMonitoredStatus? Status { get; set; } /// The reason of not monitoring the subscription. public string Error { get; set; } /// Definition of the properties for a TagRules resource. diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs index c60290898e36..134422f71fde 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/Generated/RestOperations/MarketplaceAgreementsRestOperations.cs @@ -114,7 +114,7 @@ public Response List(string subscriptionId, } } - internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, DataDogAgreementResourceContent content) + internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, DataDogAgreementContent content) { var uri = new RawRequestUriBuilder(); uri.Reset(_endpoint); @@ -125,7 +125,7 @@ internal RequestUriBuilder CreateCreateOrUpdateRequestUri(string subscriptionId, return uri; } - internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DataDogAgreementResourceContent content) + internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DataDogAgreementContent content) { var message = _pipeline.CreateMessage(); var request = message.Request; @@ -155,7 +155,7 @@ internal HttpMessage CreateCreateOrUpdateRequest(string subscriptionId, DataDogA /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public async Task> CreateOrUpdateAsync(string subscriptionId, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public async Task> CreateOrUpdateAsync(string subscriptionId, DataDogAgreementContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -165,9 +165,9 @@ public async Task> CreateOrUpdateAsync { case 200: { - DataDogAgreementResourceContent value = default; + DataDogAgreementContent value = default; using var document = await JsonDocument.ParseAsync(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions, cancellationToken).ConfigureAwait(false); - value = DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(document.RootElement); + value = DataDogAgreementContent.DeserializeDataDogAgreementContent(document.RootElement); return Response.FromValue(value, message.Response); } default: @@ -181,7 +181,7 @@ public async Task> CreateOrUpdateAsync /// The cancellation token to use. /// is null. /// is an empty string, and was expected to be non-empty. - public Response CreateOrUpdate(string subscriptionId, DataDogAgreementResourceContent content = null, CancellationToken cancellationToken = default) + public Response CreateOrUpdate(string subscriptionId, DataDogAgreementContent content = null, CancellationToken cancellationToken = default) { Argument.AssertNotNullOrEmpty(subscriptionId, nameof(subscriptionId)); @@ -191,9 +191,9 @@ public Response CreateOrUpdate(string subscript { case 200: { - DataDogAgreementResourceContent value = default; + DataDogAgreementContent value = default; using var document = JsonDocument.Parse(message.Response.ContentStream, ModelSerializationExtensions.JsonDocumentOptions); - value = DataDogAgreementResourceContent.DeserializeDataDogAgreementResourceContent(document.RootElement); + value = DataDogAgreementContent.DeserializeDataDogAgreementContent(document.RootElement); return Response.FromValue(value, message.Response); } default: diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md index 978e41f36f67..72d63f9d9274 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md +++ b/sdk/datadog/Azure.ResourceManager.Datadog/src/autorest.md @@ -51,14 +51,14 @@ acronym-mapping: Etag: ETag|etag rename-mapping: - DatadogAgreementResource: DataDogAgreementResourceContent - MonitoredResource: MonitoredResourceContent + DatadogAgreementResource: DataDogAgreementContent + MonitoredResource: DataDogMonitoredResourceContent BillingInfoResponse: DataDogBillingInfoResult CreateResourceSupportedResponse: DataDogCreateResourceSupportedResult DatadogMonitorResourceUpdateParameters: DataDogMonitorResourceUpdateContent DatadogApiKey: DataDogApiKeyContent LinkedResource: DataDogLinkedInfo - Status: MonitoredStatus + Status: DataDogMonitoredStatus DatadogAgreementResourceListResponse: DataDogAgreementResourceListResult DatadogApiKeyListResponse: DataDogApiKeyListResult DatadogHostListResponse: DataDogHostListResult @@ -74,13 +74,8 @@ rename-mapping: DatadogAgreementProperties.accepted: IsAccepted DatadogOrganizationProperties.cspm: IsCspm DatadogOrganizationProperties.resourceCollection: IsResourceCollection - LogRules.sendAadLogs: IsSendAadLogs - LogRules.sendSubscriptionLogs: IsSendSubscriptionLogs - LogRules.sendResourceLogs: IsSendResourceLogs MonitorUpdateProperties.cspm: IsCspm MonitorUpdateProperties.resourceCollection: IsResourceCollection - MonitoredResource.sendingMetrics: IsSendingMetrics - MonitoredResource.sendingLogs: IsSendingLogs MonitoringTagRulesProperties.automuting: IsAutomuting MonitoringTagRulesProperties.customMetrics: IsCustomMetrics AgentRules: DataDogAgentRules diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs index 7dfdddbb0ce7..058f7845621d 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_DatadogMonitorResource.cs @@ -248,7 +248,7 @@ public async Task GetMonitoredResources_MonitorsListMonitoredResources() DatadogMonitorResource datadogMonitorResource = client.GetDatadogMonitorResource(datadogMonitorResourceId); // invoke the operation and iterate over the result - await foreach (MonitoredResourceContent item in datadogMonitorResource.GetMonitoredResourcesAsync()) + await foreach (DataDogMonitoredResourceContent item in datadogMonitorResource.GetMonitoredResourcesAsync()) { Console.WriteLine($"Succeeded: {item}"); } diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs index e9a7de88f1f8..7efd349c7c59 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyCollection.cs @@ -49,14 +49,14 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() MonitoredSubscriptionList = {new MonitoredSubscription { SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000000"), -Status = MonitoredStatus.Active, +Status = DataDogMonitoredStatus.Active, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -IsSendAadLogs = false, -IsSendSubscriptionLogs = true, -IsSendResourceLogs = true, +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -75,14 +75,14 @@ public async Task CreateOrUpdate_MonitorsAddMonitoredSubscriptions() }, new MonitoredSubscription { SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000001"), -Status = MonitoredStatus.Failed, +Status = DataDogMonitoredStatus.Failed, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -IsSendAadLogs = false, -IsSendSubscriptionLogs = true, -IsSendResourceLogs = true, +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs index 021a9afdec1e..c3a0de89bc53 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoredSubscriptionPropertyResource.cs @@ -104,14 +104,14 @@ public async Task Update_MonitorsUpdateMonitoredSubscriptions() MonitoredSubscriptionList = {new MonitoredSubscription { SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000000"), -Status = MonitoredStatus.Active, +Status = DataDogMonitoredStatus.Active, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -IsSendAadLogs = false, -IsSendSubscriptionLogs = true, -IsSendResourceLogs = true, +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", @@ -130,14 +130,14 @@ public async Task Update_MonitorsUpdateMonitoredSubscriptions() }, new MonitoredSubscription { SubscriptionId = Guid.Parse("/subscriptions/00000000-0000-0000-0000-000000000001"), -Status = MonitoredStatus.Failed, +Status = DataDogMonitoredStatus.Failed, TagRules = new MonitoringTagRulesProperties { LogRules = new LogRules { -IsSendAadLogs = false, -IsSendSubscriptionLogs = true, -IsSendResourceLogs = true, +SendAadLogs = false, +SendSubscriptionLogs = true, +SendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs index 5deb34d95b80..f04b31a19cf6 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleCollection.cs @@ -47,9 +47,9 @@ public async Task CreateOrUpdate_TagRulesCreateOrUpdate() { LogRules = new LogRules { - IsSendAadLogs = false, - IsSendSubscriptionLogs = true, - IsSendResourceLogs = true, + SendAadLogs = false, + SendSubscriptionLogs = true, + SendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs index 369e0e81edda..03fe1a44f1a8 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_MonitoringTagRuleResource.cs @@ -75,9 +75,9 @@ public async Task Update_TagRulesCreateOrUpdate() { LogRules = new LogRules { - IsSendAadLogs = false, - IsSendSubscriptionLogs = true, - IsSendResourceLogs = true, + SendAadLogs = false, + SendSubscriptionLogs = true, + SendResourceLogs = true, FilteringTags = {new FilteringTag { Name = "Environment", diff --git a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs index 8aacdfbd8b3b..e8279f9ddbe4 100644 --- a/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs +++ b/sdk/datadog/Azure.ResourceManager.Datadog/tests/Generated/Samples/Sample_SubscriptionResourceExtensions.cs @@ -36,7 +36,7 @@ public async Task GetMarketplaceAgreements_MarketplaceAgreementsList() SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); // invoke the operation and iterate over the result - await foreach (DataDogAgreementResourceContent item in subscriptionResource.GetMarketplaceAgreementsAsync()) + await foreach (DataDogAgreementContent item in subscriptionResource.GetMarketplaceAgreementsAsync()) { Console.WriteLine($"Succeeded: {item}"); } @@ -63,14 +63,14 @@ public async Task CreateOrUpdateMarketplaceAgreement_MarketplaceAgreementsCreate SubscriptionResource subscriptionResource = client.GetSubscriptionResource(subscriptionResourceId); // invoke the operation - DataDogAgreementResourceContent content = new DataDogAgreementResourceContent + DataDogAgreementContent content = new DataDogAgreementContent { Properties = new DatadogAgreementProperties { IsAccepted = true, }, }; - DataDogAgreementResourceContent result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(content: content); + DataDogAgreementContent result = await subscriptionResource.CreateOrUpdateMarketplaceAgreementAsync(content: content); Console.WriteLine($"Succeeded: {result}"); }