diff --git a/eng/versioning/version_client.txt b/eng/versioning/version_client.txt
index 9a13937e1fdb9..3ed39a1ff2834 100644
--- a/eng/versioning/version_client.txt
+++ b/eng/versioning/version_client.txt
@@ -302,7 +302,7 @@ com.azure.resourcemanager:azure-resourcemanager-redisenterprise;2.0.0;2.1.0-beta
com.azure.resourcemanager:azure-resourcemanager-hybridkubernetes;1.0.0-beta.3;1.0.0-beta.4
com.azure.resourcemanager:azure-resourcemanager-iothub;1.2.0;1.3.0-beta.1
com.azure.resourcemanager:azure-resourcemanager-datadog;1.0.0;1.1.0-beta.1
-com.azure.resourcemanager:azure-resourcemanager-communication;2.0.0;2.1.0-beta.3
+com.azure.resourcemanager:azure-resourcemanager-communication;2.0.0;2.1.0
com.azure.resourcemanager:azure-resourcemanager-apimanagement;1.0.0-beta.4;1.0.0-beta.5
com.azure.resourcemanager:azure-resourcemanager-kubernetesconfiguration;1.0.0;1.1.0-beta.1
com.azure.resourcemanager:azure-resourcemanager-resourcegraph;1.0.0;1.1.0-beta.1
diff --git a/sdk/communication/azure-resourcemanager-communication/CHANGELOG.md b/sdk/communication/azure-resourcemanager-communication/CHANGELOG.md
index aedda9d24eb99..ff8c0fded6c84 100644
--- a/sdk/communication/azure-resourcemanager-communication/CHANGELOG.md
+++ b/sdk/communication/azure-resourcemanager-communication/CHANGELOG.md
@@ -1,14 +1,33 @@
# Release History
-## 2.1.0-beta.3 (Unreleased)
+## 2.1.0 (2024-03-18)
+
+- Azure Resource Manager Communication client library for Java. This package contains Microsoft Azure SDK for Communication Management SDK. REST API for Azure Communication Services. Package tag package-2023-04. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
### Features Added
-### Breaking Changes
+* `models.ManagedServiceIdentityType` was added
+
+* `models.ManagedServiceIdentity` was added
+
+* `models.UserAssignedIdentity` was added
+
+#### `models.CommunicationServiceResource$Update` was modified
+
+* `withIdentity(models.ManagedServiceIdentity)` was added
-### Bugs Fixed
+#### `models.CommunicationServiceResource$Definition` was modified
+
+* `withIdentity(models.ManagedServiceIdentity)` was added
-### Other Changes
+#### `models.CommunicationServiceResourceUpdate` was modified
+
+* `withIdentity(models.ManagedServiceIdentity)` was added
+* `identity()` was added
+
+#### `models.CommunicationServiceResource` was modified
+
+* `identity()` was added
## 2.1.0-beta.2 (2023-11-23)
diff --git a/sdk/communication/azure-resourcemanager-communication/README.md b/sdk/communication/azure-resourcemanager-communication/README.md
index 62e1a98711c57..cfc9dbda5c21f 100644
--- a/sdk/communication/azure-resourcemanager-communication/README.md
+++ b/sdk/communication/azure-resourcemanager-communication/README.md
@@ -2,7 +2,7 @@
Azure Resource Manager Communication client library for Java.
-This package contains Microsoft Azure SDK for Communication Management SDK. REST API for Azure Communication Services. Package tag package-preview-2023-06. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
+This package contains Microsoft Azure SDK for Communication Management SDK. REST API for Azure Communication Services. Package tag package-2023-04. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## We'd love to hear your feedback
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
com.azure.resourcemanager
azure-resourcemanager-communication
- 2.1.0-beta.2
+ 2.1.0
```
[//]: # ({x-version-update-end})
diff --git a/sdk/communication/azure-resourcemanager-communication/SAMPLE.md b/sdk/communication/azure-resourcemanager-communication/SAMPLE.md
index bfa8e9baae0e4..69b2739b02863 100644
--- a/sdk/communication/azure-resourcemanager-communication/SAMPLE.md
+++ b/sdk/communication/azure-resourcemanager-communication/SAMPLE.md
@@ -44,20 +44,6 @@
- [Delete](#senderusernames_delete)
- [Get](#senderusernames_get)
- [ListByDomains](#senderusernames_listbydomains)
-
-## SuppressionListAddresses
-
-- [CreateOrUpdate](#suppressionlistaddresses_createorupdate)
-- [Delete](#suppressionlistaddresses_delete)
-- [Get](#suppressionlistaddresses_get)
-- [List](#suppressionlistaddresses_list)
-
-## SuppressionLists
-
-- [CreateOrUpdate](#suppressionlists_createorupdate)
-- [Delete](#suppressionlists_delete)
-- [Get](#suppressionlists_get)
-- [ListByDomain](#suppressionlists_listbydomain)
### CommunicationServices_CheckNameAvailability
```java
@@ -68,27 +54,37 @@ import com.azure.resourcemanager.communication.models.NameAvailabilityParameters
*/
public final class CommunicationServicesCheckNameAvailabilitySamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/checkNameAvailabilityAvailable.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/checkNameAvailabilityAvailable.json
*/
/**
* Sample code: Check name availability available.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void checkNameAvailabilityAvailable(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().checkNameAvailabilityWithResponse(new NameAvailabilityParameters().withName("MyCommunicationService").withType("Microsoft.Communication/CommunicationServices"), com.azure.core.util.Context.NONE);
+ public static void
+ checkNameAvailabilityAvailable(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.communicationServices().checkNameAvailabilityWithResponse(new NameAvailabilityParameters()
+ .withName("MyCommunicationService").withType("Microsoft.Communication/CommunicationServices"),
+ com.azure.core.util.Context.NONE);
}
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/checkNameAvailabilityUnavailable.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/checkNameAvailabilityUnavailable.json
*/
/**
* Sample code: Check name availability unavailable.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void checkNameAvailabilityUnavailable(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().checkNameAvailabilityWithResponse(new NameAvailabilityParameters().withName("MyCommunicationService").withType("Microsoft.Communication/CommunicationServices"), com.azure.core.util.Context.NONE);
+ public static void
+ checkNameAvailabilityUnavailable(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.communicationServices().checkNameAvailabilityWithResponse(new NameAvailabilityParameters()
+ .withName("MyCommunicationService").withType("Microsoft.Communication/CommunicationServices"),
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -98,14 +94,15 @@ public final class CommunicationServicesCheckNameAvailabilitySamples {
```java
import com.azure.resourcemanager.communication.models.ManagedServiceIdentity;
import com.azure.resourcemanager.communication.models.ManagedServiceIdentityType;
-import java.util.stream.Collectors;
/**
* Samples for CommunicationServices CreateOrUpdate.
*/
public final class CommunicationServicesCreateOrUpdateSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/createOrUpdate.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/createOrUpdate.json
*/
/**
* Sample code: Create or update resource.
@@ -113,19 +110,26 @@ public final class CommunicationServicesCreateOrUpdateSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void createOrUpdateResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().define("MyCommunicationResource").withRegion("Global").withExistingResourceGroup("MyResourceGroup").withDataLocation("United States").create();
+ manager.communicationServices().define("MyCommunicationResource").withRegion("Global")
+ .withExistingResourceGroup("MyResourceGroup").withDataLocation("United States").create();
}
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/createOrUpdateWithSystemAssignedIdentity.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/createOrUpdateWithSystemAssignedIdentity.json
*/
/**
* Sample code: Create or update resource with managed identity.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void createOrUpdateResourceWithManagedIdentity(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().define("MyCommunicationResource").withRegion("Global").withExistingResourceGroup("MyResourceGroup").withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED)).withDataLocation("United States").create();
+ public static void createOrUpdateResourceWithManagedIdentity(
+ com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.communicationServices().define("MyCommunicationResource").withRegion("Global")
+ .withExistingResourceGroup("MyResourceGroup")
+ .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED))
+ .withDataLocation("United States").create();
}
}
```
@@ -138,7 +142,9 @@ public final class CommunicationServicesCreateOrUpdateSamples {
*/
public final class CommunicationServicesDeleteSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/delete.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/delete.json
*/
/**
* Sample code: Delete resource.
@@ -146,7 +152,8 @@ public final class CommunicationServicesDeleteSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void deleteResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().delete("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE);
+ manager.communicationServices().delete("MyResourceGroup", "MyCommunicationResource",
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -159,7 +166,9 @@ public final class CommunicationServicesDeleteSamples {
*/
public final class CommunicationServicesGetByResourceGroupSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/get.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/get.json
*/
/**
* Sample code: Get resource.
@@ -167,7 +176,8 @@ public final class CommunicationServicesGetByResourceGroupSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void getResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE);
+ manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup", "MyCommunicationResource",
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -182,7 +192,9 @@ import com.azure.resourcemanager.communication.models.LinkNotificationHubParamet
*/
public final class CommunicationServicesLinkNotificationHubSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/linkNotificationHub.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/linkNotificationHub.json
*/
/**
* Sample code: Link notification hub.
@@ -190,7 +202,11 @@ public final class CommunicationServicesLinkNotificationHubSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void linkNotificationHub(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().linkNotificationHubWithResponse("MyResourceGroup", "MyCommunicationResource", new LinkNotificationHubParameters().withResourceId("/subscriptions/11112222-3333-4444-5555-666677778888/resourceGroups/MyOtherResourceGroup/providers/Microsoft.NotificationHubs/namespaces/MyNamespace/notificationHubs/MyHub").withConnectionString("Endpoint=sb://MyNamespace.servicebus.windows.net/;SharedAccessKey=abcd1234"), com.azure.core.util.Context.NONE);
+ manager.communicationServices().linkNotificationHubWithResponse("MyResourceGroup", "MyCommunicationResource",
+ new LinkNotificationHubParameters().withResourceId(
+ "/subscriptions/11112222-3333-4444-5555-666677778888/resourceGroups/MyOtherResourceGroup/providers/Microsoft.NotificationHubs/namespaces/MyNamespace/notificationHubs/MyHub")
+ .withConnectionString("Endpoint=sb://MyNamespace.servicebus.windows.net/;SharedAccessKey=abcd1234"),
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -203,7 +219,9 @@ public final class CommunicationServicesLinkNotificationHubSamples {
*/
public final class CommunicationServicesListSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/listBySubscription.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/listBySubscription.json
*/
/**
* Sample code: List by subscription.
@@ -224,7 +242,9 @@ public final class CommunicationServicesListSamples {
*/
public final class CommunicationServicesListByResourceGroupSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/listByResourceGroup.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/listByResourceGroup.json
*/
/**
* Sample code: List by resource group.
@@ -245,7 +265,9 @@ public final class CommunicationServicesListByResourceGroupSamples {
*/
public final class CommunicationServicesListKeysSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/listKeys.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/listKeys.json
*/
/**
* Sample code: List keys.
@@ -253,7 +275,8 @@ public final class CommunicationServicesListKeysSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void listKeys(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().listKeysWithResponse("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE);
+ manager.communicationServices().listKeysWithResponse("MyResourceGroup", "MyCommunicationResource",
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -263,14 +286,15 @@ public final class CommunicationServicesListKeysSamples {
```java
import com.azure.resourcemanager.communication.models.KeyType;
import com.azure.resourcemanager.communication.models.RegenerateKeyParameters;
-import java.util.stream.Collectors;
/**
* Samples for CommunicationServices RegenerateKey.
*/
public final class CommunicationServicesRegenerateKeySamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/regenerateKey.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/regenerateKey.json
*/
/**
* Sample code: Regenerate key.
@@ -278,7 +302,8 @@ public final class CommunicationServicesRegenerateKeySamples {
* @param manager Entry point to CommunicationManager.
*/
public static void regenerateKey(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.communicationServices().regenerateKeyWithResponse("MyResourceGroup", "MyCommunicationResource", new RegenerateKeyParameters().withKeyType(KeyType.PRIMARY), com.azure.core.util.Context.NONE);
+ manager.communicationServices().regenerateKeyWithResponse("MyResourceGroup", "MyCommunicationResource",
+ new RegenerateKeyParameters().withKeyType(KeyType.PRIMARY), com.azure.core.util.Context.NONE);
}
}
```
@@ -292,14 +317,15 @@ import com.azure.resourcemanager.communication.models.ManagedServiceIdentityType
import com.azure.resourcemanager.communication.models.UserAssignedIdentity;
import java.util.HashMap;
import java.util.Map;
-import java.util.stream.Collectors;
/**
* Samples for CommunicationServices Update.
*/
public final class CommunicationServicesUpdateSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/update.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/update.json
*/
/**
* Sample code: Update resource.
@@ -307,60 +333,91 @@ public final class CommunicationServicesUpdateSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void updateResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- CommunicationServiceResource resource = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
- resource.update().withTags(mapOf("newTag", "newVal")).withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED)).apply();
+ CommunicationServiceResource resource
+ = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup",
+ "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
+ resource.update().withTags(mapOf("newTag", "newVal")).apply();
}
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/updateWithUserAssignedIdentity.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/updateWithUserAssignedIdentity.json
*/
/**
* Sample code: Update resource to add a User Assigned managed identity.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void updateResourceToAddAUserAssignedManagedIdentity(com.azure.resourcemanager.communication.CommunicationManager manager) {
- CommunicationServiceResource resource = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
- resource.update().withTags(mapOf("newTag", "newVal")).withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.USER_ASSIGNED).withUserAssignedIdentities(mapOf("/user/assigned/resource/id", new UserAssignedIdentity()))).apply();
+ public static void updateResourceToAddAUserAssignedManagedIdentity(
+ com.azure.resourcemanager.communication.CommunicationManager manager) {
+ CommunicationServiceResource resource
+ = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup",
+ "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
+ resource.update().withTags(mapOf("newTag", "newVal"))
+ .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.USER_ASSIGNED)
+ .withUserAssignedIdentities(mapOf("/user/assigned/resource/id", new UserAssignedIdentity())))
+ .apply();
}
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/updateWithSystemAssignedIdentity.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/updateWithSystemAssignedIdentity.json
*/
/**
* Sample code: Update resource to add a System Assigned managed identity.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void updateResourceToAddASystemAssignedManagedIdentity(com.azure.resourcemanager.communication.CommunicationManager manager) {
- CommunicationServiceResource resource = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
- resource.update().withTags(mapOf("newTag", "newVal")).withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED)).apply();
+ public static void updateResourceToAddASystemAssignedManagedIdentity(
+ com.azure.resourcemanager.communication.CommunicationManager manager) {
+ CommunicationServiceResource resource
+ = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup",
+ "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
+ resource.update().withTags(mapOf("newTag", "newVal"))
+ .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED)).apply();
}
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/updateRemoveSystemIdentity.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/updateRemoveSystemIdentity.json
*/
/**
* Sample code: Update resource to remove identity.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void updateResourceToRemoveIdentity(com.azure.resourcemanager.communication.CommunicationManager manager) {
- CommunicationServiceResource resource = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
- resource.update().withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.NONE)).apply();
+ public static void
+ updateResourceToRemoveIdentity(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ CommunicationServiceResource resource
+ = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup",
+ "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
+ resource.update().withTags(mapOf("newTag", "newVal"))
+ .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.NONE)).apply();
}
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/updateWithSystemAndUserIdentity.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/updateWithSystemAndUserIdentity.json
*/
/**
* Sample code: Update resource to add System and User managed identities.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void updateResourceToAddSystemAndUserManagedIdentities(com.azure.resourcemanager.communication.CommunicationManager manager) {
- CommunicationServiceResource resource = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup", "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
- resource.update().withTags(mapOf("newTag", "newVal")).withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED).withUserAssignedIdentities(mapOf("/user/assigned/resource/id", new UserAssignedIdentity()))).apply();
+ public static void updateResourceToAddSystemAndUserManagedIdentities(
+ com.azure.resourcemanager.communication.CommunicationManager manager) {
+ CommunicationServiceResource resource
+ = manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup",
+ "MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
+ resource.update().withTags(mapOf("newTag", "newVal"))
+ .withIdentity(
+ new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED)
+ .withUserAssignedIdentities(mapOf("/user/assigned/resource/id", new UserAssignedIdentity())))
+ .apply();
}
// Use "Map.of" if available
@@ -382,14 +439,15 @@ public final class CommunicationServicesUpdateSamples {
```java
import com.azure.resourcemanager.communication.models.VerificationParameter;
import com.azure.resourcemanager.communication.models.VerificationType;
-import java.util.stream.Collectors;
/**
* Samples for Domains CancelVerification.
*/
public final class DomainsCancelVerificationSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/cancelVerification.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
+ * cancelVerification.json
*/
/**
* Sample code: Cancel verification.
@@ -397,7 +455,8 @@ public final class DomainsCancelVerificationSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void cancelVerification(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.domains().cancelVerification("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", new VerificationParameter().withVerificationType(VerificationType.SPF), com.azure.core.util.Context.NONE);
+ manager.domains().cancelVerification("MyResourceGroup", "MyEmailServiceResource", "mydomain.com",
+ new VerificationParameter().withVerificationType(VerificationType.SPF), com.azure.core.util.Context.NONE);
}
}
```
@@ -406,22 +465,26 @@ public final class DomainsCancelVerificationSamples {
```java
import com.azure.resourcemanager.communication.models.DomainManagement;
-import java.util.stream.Collectors;
/**
* Samples for Domains CreateOrUpdate.
*/
public final class DomainsCreateOrUpdateSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/createOrUpdate.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
+ * createOrUpdate.json
*/
/**
* Sample code: Create or update Domains resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void createOrUpdateDomainsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.domains().define("mydomain.com").withRegion("Global").withExistingEmailService("MyResourceGroup", "MyEmailServiceResource").withDomainManagement(DomainManagement.CUSTOMER_MANAGED).create();
+ public static void
+ createOrUpdateDomainsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.domains().define("mydomain.com").withRegion("Global")
+ .withExistingEmailService("MyResourceGroup", "MyEmailServiceResource")
+ .withDomainManagement(DomainManagement.CUSTOMER_MANAGED).create();
}
}
```
@@ -434,7 +497,9 @@ public final class DomainsCreateOrUpdateSamples {
*/
public final class DomainsDeleteSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/delete.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/delete.
+ * json
*/
/**
* Sample code: Delete Domains resource.
@@ -442,7 +507,8 @@ public final class DomainsDeleteSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void deleteDomainsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.domains().delete("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", com.azure.core.util.Context.NONE);
+ manager.domains().delete("MyResourceGroup", "MyEmailServiceResource", "mydomain.com",
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -455,7 +521,8 @@ public final class DomainsDeleteSamples {
*/
public final class DomainsGetSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/get.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/get.json
*/
/**
* Sample code: Get Domains resource.
@@ -463,7 +530,8 @@ public final class DomainsGetSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void getDomainsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.domains().getWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", com.azure.core.util.Context.NONE);
+ manager.domains().getWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com",
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -473,14 +541,15 @@ public final class DomainsGetSamples {
```java
import com.azure.resourcemanager.communication.models.VerificationParameter;
import com.azure.resourcemanager.communication.models.VerificationType;
-import java.util.stream.Collectors;
/**
* Samples for Domains InitiateVerification.
*/
public final class DomainsInitiateVerificationSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/initiateVerification.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
+ * initiateVerification.json
*/
/**
* Sample code: Initiate verification.
@@ -488,7 +557,8 @@ public final class DomainsInitiateVerificationSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void initiateVerification(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.domains().initiateVerification("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", new VerificationParameter().withVerificationType(VerificationType.SPF), com.azure.core.util.Context.NONE);
+ manager.domains().initiateVerification("MyResourceGroup", "MyEmailServiceResource", "mydomain.com",
+ new VerificationParameter().withVerificationType(VerificationType.SPF), com.azure.core.util.Context.NONE);
}
}
```
@@ -501,15 +571,19 @@ public final class DomainsInitiateVerificationSamples {
*/
public final class DomainsListByEmailServiceResourceSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/listByEmailService.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
+ * listByEmailService.json
*/
/**
* Sample code: List Domains resources by EmailServiceName.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void listDomainsResourcesByEmailServiceName(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.domains().listByEmailServiceResource("MyResourceGroup", "MyEmailServiceResource", com.azure.core.util.Context.NONE);
+ public static void
+ listDomainsResourcesByEmailServiceName(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.domains().listByEmailServiceResource("MyResourceGroup", "MyEmailServiceResource",
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -519,14 +593,15 @@ public final class DomainsListByEmailServiceResourceSamples {
```java
import com.azure.resourcemanager.communication.models.DomainResource;
import com.azure.resourcemanager.communication.models.UserEngagementTracking;
-import java.util.stream.Collectors;
/**
* Samples for Domains Update.
*/
public final class DomainsUpdateSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/update.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/update.
+ * json
*/
/**
* Sample code: Update Domains resource.
@@ -534,7 +609,8 @@ public final class DomainsUpdateSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void updateDomainsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- DomainResource resource = manager.domains().getWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", com.azure.core.util.Context.NONE).getValue();
+ DomainResource resource = manager.domains().getWithResponse("MyResourceGroup", "MyEmailServiceResource",
+ "mydomain.com", com.azure.core.util.Context.NONE).getValue();
resource.update().withUserEngagementTracking(UserEngagementTracking.ENABLED).apply();
}
}
@@ -548,15 +624,19 @@ public final class DomainsUpdateSamples {
*/
public final class EmailServicesCreateOrUpdateSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/emailServices/createOrUpdate.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * createOrUpdate.json
*/
/**
* Sample code: Create or update EmailService resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void createOrUpdateEmailServiceResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.emailServices().define("MyEmailServiceResource").withRegion("Global").withExistingResourceGroup("MyResourceGroup").withDataLocation("United States").create();
+ public static void
+ createOrUpdateEmailServiceResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.emailServices().define("MyEmailServiceResource").withRegion("Global")
+ .withExistingResourceGroup("MyResourceGroup").withDataLocation("United States").create();
}
}
```
@@ -569,14 +649,17 @@ public final class EmailServicesCreateOrUpdateSamples {
*/
public final class EmailServicesDeleteSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/emailServices/delete.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * delete.json
*/
/**
* Sample code: Delete EmailService resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void deleteEmailServiceResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ public static void
+ deleteEmailServiceResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
manager.emailServices().delete("MyResourceGroup", "MyEmailServiceResource", com.azure.core.util.Context.NONE);
}
}
@@ -590,7 +673,9 @@ public final class EmailServicesDeleteSamples {
*/
public final class EmailServicesGetByResourceGroupSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/emailServices/get.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/get
+ * .json
*/
/**
* Sample code: Get EmailService resource.
@@ -598,7 +683,8 @@ public final class EmailServicesGetByResourceGroupSamples {
* @param manager Entry point to CommunicationManager.
*/
public static void getEmailServiceResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.emailServices().getByResourceGroupWithResponse("MyResourceGroup", "MyEmailServiceResource", com.azure.core.util.Context.NONE);
+ manager.emailServices().getByResourceGroupWithResponse("MyResourceGroup", "MyEmailServiceResource",
+ com.azure.core.util.Context.NONE);
}
}
```
@@ -611,14 +697,17 @@ public final class EmailServicesGetByResourceGroupSamples {
*/
public final class EmailServicesListSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/emailServices/listBySubscription.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * listBySubscription.json
*/
/**
* Sample code: List EmailService resources by subscription.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void listEmailServiceResourcesBySubscription(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ public static void
+ listEmailServiceResourcesBySubscription(com.azure.resourcemanager.communication.CommunicationManager manager) {
manager.emailServices().list(com.azure.core.util.Context.NONE);
}
}
@@ -632,14 +721,17 @@ public final class EmailServicesListSamples {
*/
public final class EmailServicesListByResourceGroupSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/emailServices/listByResourceGroup.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * listByResourceGroup.json
*/
/**
* Sample code: List EmailService resources by resource group.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void listEmailServiceResourcesByResourceGroup(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ public static void
+ listEmailServiceResourcesByResourceGroup(com.azure.resourcemanager.communication.CommunicationManager manager) {
manager.emailServices().listByResourceGroup("MyResourceGroup", com.azure.core.util.Context.NONE);
}
}
@@ -653,14 +745,17 @@ public final class EmailServicesListByResourceGroupSamples {
*/
public final class EmailServicesListVerifiedExchangeOnlineDomainsSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/emailServices/getVerifiedExchangeOnlineDomains.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * getVerifiedExchangeOnlineDomains.json
*/
/**
* Sample code: Get verified Exchange Online domains.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void getVerifiedExchangeOnlineDomains(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ public static void
+ getVerifiedExchangeOnlineDomains(com.azure.resourcemanager.communication.CommunicationManager manager) {
manager.emailServices().listVerifiedExchangeOnlineDomainsWithResponse(com.azure.core.util.Context.NONE);
}
}
@@ -678,15 +773,19 @@ import java.util.Map;
*/
public final class EmailServicesUpdateSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/emailServices/update.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * update.json
*/
/**
* Sample code: Update EmailService resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void updateEmailServiceResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- EmailServiceResource resource = manager.emailServices().getByResourceGroupWithResponse("MyResourceGroup", "MyEmailServiceResource", com.azure.core.util.Context.NONE).getValue();
+ public static void
+ updateEmailServiceResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ EmailServiceResource resource = manager.emailServices().getByResourceGroupWithResponse("MyResourceGroup",
+ "MyEmailServiceResource", com.azure.core.util.Context.NONE).getValue();
resource.update().withTags(mapOf("newTag", "newVal")).apply();
}
@@ -712,7 +811,9 @@ public final class EmailServicesUpdateSamples {
*/
public final class OperationsListSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/communicationServices/operationsList.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
+ * communicationServices/operationsList.json
*/
/**
* Sample code: Operations_List.
@@ -733,15 +834,20 @@ public final class OperationsListSamples {
*/
public final class SenderUsernamesCreateOrUpdateSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/senderUsernames/createOrUpdate.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * createOrUpdate.json
*/
/**
* Sample code: Create or update SenderUsernames resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void createOrUpdateSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.senderUsernames().define("contosoNewsAlerts").withExistingDomain("contosoResourceGroup", "contosoEmailService", "contoso.com").withUsername("contosoNewsAlerts").withDisplayName("Contoso News Alerts").create();
+ public static void
+ createOrUpdateSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.senderUsernames().define("contosoNewsAlerts")
+ .withExistingDomain("contosoResourceGroup", "contosoEmailService", "contoso.com")
+ .withUsername("contosoNewsAlerts").withDisplayName("Contoso News Alerts").create();
}
}
```
@@ -754,15 +860,19 @@ public final class SenderUsernamesCreateOrUpdateSamples {
*/
public final class SenderUsernamesDeleteSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/senderUsernames/delete.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * delete.json
*/
/**
* Sample code: Delete SenderUsernames resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void deleteSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.senderUsernames().deleteWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", "contosoNewsAlerts", com.azure.core.util.Context.NONE);
+ public static void
+ deleteSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.senderUsernames().deleteWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com",
+ "contosoNewsAlerts", com.azure.core.util.Context.NONE);
}
}
```
@@ -775,15 +885,19 @@ public final class SenderUsernamesDeleteSamples {
*/
public final class SenderUsernamesGetSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/senderUsernames/get.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * get.json
*/
/**
* Sample code: Get SenderUsernames resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void getSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.senderUsernames().getWithResponse("contosoResourceGroup", "contosoEmailService", "contoso.com", "contosoNewsAlerts", com.azure.core.util.Context.NONE);
+ public static void
+ getSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.senderUsernames().getWithResponse("contosoResourceGroup", "contosoEmailService", "contoso.com",
+ "contosoNewsAlerts", com.azure.core.util.Context.NONE);
}
}
```
@@ -796,183 +910,19 @@ public final class SenderUsernamesGetSamples {
*/
public final class SenderUsernamesListByDomainsSamples {
/*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/senderUsernames/listByDomain.json
- */
- /**
- * Sample code: Get all SenderUsernames resources for a Domain.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void getAllSenderUsernamesResourcesForADomain(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.senderUsernames().listByDomains("contosoResourceGroup", "contosoEmailService", "contoso.com", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SuppressionListAddresses_CreateOrUpdate
-
-```java
-/**
- * Samples for SuppressionListAddresses CreateOrUpdate.
- */
-public final class SuppressionListAddressesCreateOrUpdateSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/createOrUpdateAddress.json
- */
- /**
- * Sample code: CreateOrUpdate SuppressionListAddress resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void createOrUpdateSuppressionListAddressResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().define("11112222-3333-4444-5555-aaaabbbbcccc").withExistingSuppressionList("contosoResourceGroup", "contosoEmailService", "contoso.com", "aaaa1111-bbbb-2222-3333-aaaa11112222").withEmail("newuser1@fabrikam.com").withFirstName("updatedFirstName").create();
- }
-}
-```
-
-### SuppressionListAddresses_Delete
-
-```java
-/**
- * Samples for SuppressionListAddresses Delete.
- */
-public final class SuppressionListAddressesDeleteSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/deleteAddress.json
- */
- /**
- * Sample code: Delete a SuppressionListAddress resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void deleteASuppressionListAddressResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().deleteWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", "aaaa1111-bbbb-2222-3333-aaaa11112222", "11112222-3333-4444-5555-999999999999", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SuppressionListAddresses_Get
-
-```java
-/**
- * Samples for SuppressionListAddresses Get.
- */
-public final class SuppressionListAddressesGetSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/getAddress.json
- */
- /**
- * Sample code: Get a SuppressionListAddress resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void getASuppressionListAddressResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().getWithResponse("contosoResourceGroup", "contosoEmailService", "contoso.com", "aaaa1111-bbbb-2222-3333-aaaa11112222", "11112222-3333-4444-5555-aaaabbbbcccc", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SuppressionListAddresses_List
-
-```java
-/**
- * Samples for SuppressionListAddresses List.
- */
-public final class SuppressionListAddressesListSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/getAddresses.json
- */
- /**
- * Sample code: Get all SuppressionListAddresses resources for a SuppressionList resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void getAllSuppressionListAddressesResourcesForASuppressionListResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().list("contosoResourceGroup", "contosoEmailService", "contoso.com", "aaaa1111-bbbb-2222-3333-aaaa11112222", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SuppressionLists_CreateOrUpdate
-
-```java
-/**
- * Samples for SuppressionLists CreateOrUpdate.
- */
-public final class SuppressionListsCreateOrUpdateSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/createOrUpdateSuppressionList.json
- */
- /**
- * Sample code: CreateOrUpdate SuppressionLists resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void createOrUpdateSuppressionListsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().define("aaaa1111-bbbb-2222-3333-aaaa11112222").withExistingDomain("contosoResourceGroup", "contosoEmailService", "contoso.com").withListName("contosoNewsAlerts").create();
- }
-}
-```
-
-### SuppressionLists_Delete
-
-```java
-/**
- * Samples for SuppressionLists Delete.
- */
-public final class SuppressionListsDeleteSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/deleteSuppressionList.json
+ * x-ms-original-file:
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * listByDomain.json
*/
/**
- * Sample code: Delete a SuppressionLists resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void deleteASuppressionListsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().deleteWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com", "aaaa1111-bbbb-2222-3333-aaaa11112222", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SuppressionLists_Get
-
-```java
-/**
- * Samples for SuppressionLists Get.
- */
-public final class SuppressionListsGetSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/getSuppressionList.json
- */
- /**
- * Sample code: Get a SuppressionList resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void getASuppressionListResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().getWithResponse("contosoResourceGroup", "contosoEmailService", "contoso.com", "aaaa1111-bbbb-2222-3333-aaaa11112222", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SuppressionLists_ListByDomain
-
-```java
-/**
- * Samples for SuppressionLists ListByDomain.
- */
-public final class SuppressionListsListByDomainSamples {
- /*
- * x-ms-original-file: specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/suppressionLists/getSuppressionLists.json
- */
- /**
- * Sample code: Get all SuppressionLists resources.
+ * Sample code: Get SenderUsernames resource.
*
* @param manager Entry point to CommunicationManager.
*/
- public static void getAllSuppressionListsResources(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().listByDomain("contosoResourceGroup", "contosoEmailService", "contoso.com", com.azure.core.util.Context.NONE);
+ public static void
+ getSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ manager.senderUsernames().listByDomains("contosoResourceGroup", "contosoEmailService", "contoso.com",
+ com.azure.core.util.Context.NONE);
}
}
```
diff --git a/sdk/communication/azure-resourcemanager-communication/pom.xml b/sdk/communication/azure-resourcemanager-communication/pom.xml
index b4e7649309961..7326161d5673c 100644
--- a/sdk/communication/azure-resourcemanager-communication/pom.xml
+++ b/sdk/communication/azure-resourcemanager-communication/pom.xml
@@ -14,11 +14,11 @@
com.azure.resourcemanager
azure-resourcemanager-communication
- 2.1.0-beta.3
+ 2.1.0
jar
Microsoft Azure SDK for Communication Management
- This package contains Microsoft Azure SDK for Communication Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. REST API for Azure Communication Services. Package tag package-preview-2023-06.
+ This package contains Microsoft Azure SDK for Communication Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. REST API for Azure Communication Services. Package tag package-2023-04.
https://github.com/Azure/azure-sdk-for-java
@@ -45,7 +45,6 @@
UTF-8
0
0
- true
@@ -88,8 +87,6 @@
4.11.0
test
-
-
net.bytebuddy
byte-buddy
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/CommunicationManager.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/CommunicationManager.java
index f87406b77d587..2d522afcf29eb 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/CommunicationManager.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/CommunicationManager.java
@@ -30,15 +30,11 @@
import com.azure.resourcemanager.communication.implementation.EmailServicesImpl;
import com.azure.resourcemanager.communication.implementation.OperationsImpl;
import com.azure.resourcemanager.communication.implementation.SenderUsernamesImpl;
-import com.azure.resourcemanager.communication.implementation.SuppressionListAddressesImpl;
-import com.azure.resourcemanager.communication.implementation.SuppressionListsImpl;
import com.azure.resourcemanager.communication.models.CommunicationServices;
import com.azure.resourcemanager.communication.models.Domains;
import com.azure.resourcemanager.communication.models.EmailServices;
import com.azure.resourcemanager.communication.models.Operations;
import com.azure.resourcemanager.communication.models.SenderUsernames;
-import com.azure.resourcemanager.communication.models.SuppressionListAddresses;
-import com.azure.resourcemanager.communication.models.SuppressionLists;
import java.time.Duration;
import java.time.temporal.ChronoUnit;
import java.util.ArrayList;
@@ -61,10 +57,6 @@ public final class CommunicationManager {
private SenderUsernames senderUsernames;
- private SuppressionLists suppressionLists;
-
- private SuppressionListAddresses suppressionListAddresses;
-
private final CommunicationServiceManagementClient clientObject;
private CommunicationManager(HttpPipeline httpPipeline, AzureProfile profile, Duration defaultPollInterval) {
@@ -224,7 +216,7 @@ public CommunicationManager authenticate(TokenCredential credential, AzureProfil
StringBuilder userAgentBuilder = new StringBuilder();
userAgentBuilder.append("azsdk-java").append("-").append("com.azure.resourcemanager.communication")
- .append("/").append("2.1.0-beta.2");
+ .append("/").append("2.1.0");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder.append(" (").append(Configuration.getGlobalConfiguration().get("java.version"))
.append("; ").append(Configuration.getGlobalConfiguration().get("os.name")).append("; ")
@@ -323,31 +315,6 @@ public SenderUsernames senderUsernames() {
return senderUsernames;
}
- /**
- * Gets the resource collection API of SuppressionLists. It manages SuppressionListResource.
- *
- * @return Resource collection API of SuppressionLists.
- */
- public SuppressionLists suppressionLists() {
- if (this.suppressionLists == null) {
- this.suppressionLists = new SuppressionListsImpl(clientObject.getSuppressionLists(), this);
- }
- return suppressionLists;
- }
-
- /**
- * Gets the resource collection API of SuppressionListAddresses. It manages SuppressionListAddressResource.
- *
- * @return Resource collection API of SuppressionListAddresses.
- */
- public SuppressionListAddresses suppressionListAddresses() {
- if (this.suppressionListAddresses == null) {
- this.suppressionListAddresses
- = new SuppressionListAddressesImpl(clientObject.getSuppressionListAddresses(), this);
- }
- return suppressionListAddresses;
- }
-
/**
* Gets wrapped service client CommunicationServiceManagementClient providing direct access to the underlying
* auto-generated API implementation, based on Azure REST API.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/CommunicationServiceManagementClient.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/CommunicationServiceManagementClient.java
index 5d6ab146d318c..d24e14239ffe7 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/CommunicationServiceManagementClient.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/CommunicationServiceManagementClient.java
@@ -80,18 +80,4 @@ public interface CommunicationServiceManagementClient {
* @return the SenderUsernamesClient object.
*/
SenderUsernamesClient getSenderUsernames();
-
- /**
- * Gets the SuppressionListsClient object to access its operations.
- *
- * @return the SuppressionListsClient object.
- */
- SuppressionListsClient getSuppressionLists();
-
- /**
- * Gets the SuppressionListAddressesClient object to access its operations.
- *
- * @return the SuppressionListAddressesClient object.
- */
- SuppressionListAddressesClient getSuppressionListAddresses();
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/SuppressionListAddressesClient.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/SuppressionListAddressesClient.java
deleted file mode 100644
index 869f0e4239d4e..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/SuppressionListAddressesClient.java
+++ /dev/null
@@ -1,174 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-
-/**
- * An instance of this class provides access to all the operations defined in SuppressionListAddressesClient.
- */
-public interface SuppressionListAddressesClient {
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName);
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SuppressionListAddressResourceInner get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId);
-
- /**
- * Create Or Update
- *
- * Create or update a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param parameters Parameters for the create or update operation.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a object that represents a SuppressionList record along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, String addressId,
- SuppressionListAddressResourceInner parameters, Context context);
-
- /**
- * Create Or Update
- *
- * Create or update a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a object that represents a SuppressionList record.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SuppressionListAddressResourceInner createOrUpdate(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId,
- SuppressionListAddressResourceInner parameters);
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId, Context context);
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String emailServiceName, String domainName, String suppressionListName,
- String addressId);
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/SuppressionListsClient.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/SuppressionListsClient.java
deleted file mode 100644
index 799363d149f52..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/SuppressionListsClient.java
+++ /dev/null
@@ -1,167 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-
-/**
- * An instance of this class provides access to all the operations defined in SuppressionListsClient.
- */
-public interface SuppressionListsClient {
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName);
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SuppressionListResourceInner get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName);
-
- /**
- * Create Or Update
- *
- * Add a new SuppressionList resource under the parent Domains resource or update an existing SuppressionList
- * resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param parameters Parameters for the create or update operation.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a SuppressionList resource along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, SuppressionListResourceInner parameters, Context context);
-
- /**
- * Create Or Update
- *
- * Add a new SuppressionList resource under the parent Domains resource or update an existing SuppressionList
- * resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a SuppressionList resource.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SuppressionListResourceInner createOrUpdate(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, SuppressionListResourceInner parameters);
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, Context context);
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String emailServiceName, String domainName, String suppressionListName);
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListAddressProperties.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListAddressProperties.java
deleted file mode 100644
index d872601d82ee3..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListAddressProperties.java
+++ /dev/null
@@ -1,172 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.time.OffsetDateTime;
-
-/**
- * A class that describes the properties of a SuppressionListAddress resource.
- */
-@Fluent
-public final class SuppressionListAddressProperties {
- /*
- * Email address of the recipient.
- */
- @JsonProperty(value = "email", required = true)
- private String email;
-
- /*
- * The first name of the email recipient.
- */
- @JsonProperty(value = "firstName")
- private String firstName;
-
- /*
- * The last name of the email recipient.
- */
- @JsonProperty(value = "lastName")
- private String lastName;
-
- /*
- * An optional property to provide contextual notes or a description for an address.
- */
- @JsonProperty(value = "notes")
- private String notes;
-
- /*
- * The date the address was last updated in a suppression list.
- */
- @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastModified;
-
- /*
- * The location where the SuppressionListAddress data is stored at rest. This value is inherited from the parent
- * Domains resource.
- */
- @JsonProperty(value = "dataLocation", access = JsonProperty.Access.WRITE_ONLY)
- private String dataLocation;
-
- /**
- * Creates an instance of SuppressionListAddressProperties class.
- */
- public SuppressionListAddressProperties() {
- }
-
- /**
- * Get the email property: Email address of the recipient.
- *
- * @return the email value.
- */
- public String email() {
- return this.email;
- }
-
- /**
- * Set the email property: Email address of the recipient.
- *
- * @param email the email value to set.
- * @return the SuppressionListAddressProperties object itself.
- */
- public SuppressionListAddressProperties withEmail(String email) {
- this.email = email;
- return this;
- }
-
- /**
- * Get the firstName property: The first name of the email recipient.
- *
- * @return the firstName value.
- */
- public String firstName() {
- return this.firstName;
- }
-
- /**
- * Set the firstName property: The first name of the email recipient.
- *
- * @param firstName the firstName value to set.
- * @return the SuppressionListAddressProperties object itself.
- */
- public SuppressionListAddressProperties withFirstName(String firstName) {
- this.firstName = firstName;
- return this;
- }
-
- /**
- * Get the lastName property: The last name of the email recipient.
- *
- * @return the lastName value.
- */
- public String lastName() {
- return this.lastName;
- }
-
- /**
- * Set the lastName property: The last name of the email recipient.
- *
- * @param lastName the lastName value to set.
- * @return the SuppressionListAddressProperties object itself.
- */
- public SuppressionListAddressProperties withLastName(String lastName) {
- this.lastName = lastName;
- return this;
- }
-
- /**
- * Get the notes property: An optional property to provide contextual notes or a description for an address.
- *
- * @return the notes value.
- */
- public String notes() {
- return this.notes;
- }
-
- /**
- * Set the notes property: An optional property to provide contextual notes or a description for an address.
- *
- * @param notes the notes value to set.
- * @return the SuppressionListAddressProperties object itself.
- */
- public SuppressionListAddressProperties withNotes(String notes) {
- this.notes = notes;
- return this;
- }
-
- /**
- * Get the lastModified property: The date the address was last updated in a suppression list.
- *
- * @return the lastModified value.
- */
- public OffsetDateTime lastModified() {
- return this.lastModified;
- }
-
- /**
- * Get the dataLocation property: The location where the SuppressionListAddress data is stored at rest. This value
- * is inherited from the parent Domains resource.
- *
- * @return the dataLocation value.
- */
- public String dataLocation() {
- return this.dataLocation;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (email() == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- "Missing required property email in model SuppressionListAddressProperties"));
- }
- }
-
- private static final ClientLogger LOGGER = new ClientLogger(SuppressionListAddressProperties.class);
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListAddressResourceInner.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListAddressResourceInner.java
deleted file mode 100644
index 1ec545359920a..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListAddressResourceInner.java
+++ /dev/null
@@ -1,175 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.time.OffsetDateTime;
-
-/**
- * A object that represents a SuppressionList record.
- */
-@Fluent
-public final class SuppressionListAddressResourceInner extends ProxyResource {
- /*
- * The properties of a SuppressionListAddress resource.
- */
- @JsonProperty(value = "properties")
- private SuppressionListAddressProperties innerProperties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /**
- * Creates an instance of SuppressionListAddressResourceInner class.
- */
- public SuppressionListAddressResourceInner() {
- }
-
- /**
- * Get the innerProperties property: The properties of a SuppressionListAddress resource.
- *
- * @return the innerProperties value.
- */
- private SuppressionListAddressProperties innerProperties() {
- return this.innerProperties;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the email property: Email address of the recipient.
- *
- * @return the email value.
- */
- public String email() {
- return this.innerProperties() == null ? null : this.innerProperties().email();
- }
-
- /**
- * Set the email property: Email address of the recipient.
- *
- * @param email the email value to set.
- * @return the SuppressionListAddressResourceInner object itself.
- */
- public SuppressionListAddressResourceInner withEmail(String email) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SuppressionListAddressProperties();
- }
- this.innerProperties().withEmail(email);
- return this;
- }
-
- /**
- * Get the firstName property: The first name of the email recipient.
- *
- * @return the firstName value.
- */
- public String firstName() {
- return this.innerProperties() == null ? null : this.innerProperties().firstName();
- }
-
- /**
- * Set the firstName property: The first name of the email recipient.
- *
- * @param firstName the firstName value to set.
- * @return the SuppressionListAddressResourceInner object itself.
- */
- public SuppressionListAddressResourceInner withFirstName(String firstName) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SuppressionListAddressProperties();
- }
- this.innerProperties().withFirstName(firstName);
- return this;
- }
-
- /**
- * Get the lastName property: The last name of the email recipient.
- *
- * @return the lastName value.
- */
- public String lastName() {
- return this.innerProperties() == null ? null : this.innerProperties().lastName();
- }
-
- /**
- * Set the lastName property: The last name of the email recipient.
- *
- * @param lastName the lastName value to set.
- * @return the SuppressionListAddressResourceInner object itself.
- */
- public SuppressionListAddressResourceInner withLastName(String lastName) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SuppressionListAddressProperties();
- }
- this.innerProperties().withLastName(lastName);
- return this;
- }
-
- /**
- * Get the notes property: An optional property to provide contextual notes or a description for an address.
- *
- * @return the notes value.
- */
- public String notes() {
- return this.innerProperties() == null ? null : this.innerProperties().notes();
- }
-
- /**
- * Set the notes property: An optional property to provide contextual notes or a description for an address.
- *
- * @param notes the notes value to set.
- * @return the SuppressionListAddressResourceInner object itself.
- */
- public SuppressionListAddressResourceInner withNotes(String notes) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SuppressionListAddressProperties();
- }
- this.innerProperties().withNotes(notes);
- return this;
- }
-
- /**
- * Get the lastModified property: The date the address was last updated in a suppression list.
- *
- * @return the lastModified value.
- */
- public OffsetDateTime lastModified() {
- return this.innerProperties() == null ? null : this.innerProperties().lastModified();
- }
-
- /**
- * Get the dataLocation property: The location where the SuppressionListAddress data is stored at rest. This value
- * is inherited from the parent Domains resource.
- *
- * @return the dataLocation value.
- */
- public String dataLocation() {
- return this.innerProperties() == null ? null : this.innerProperties().dataLocation();
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListProperties.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListProperties.java
deleted file mode 100644
index 60665aea39266..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListProperties.java
+++ /dev/null
@@ -1,104 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/**
- * A class that describes the properties of a SuppressionList resource.
- */
-@Fluent
-public final class SuppressionListProperties {
- /*
- * The the name of the suppression list. This value must match one of the valid sender usernames of the sending
- * domain.
- */
- @JsonProperty(value = "listName")
- private String listName;
-
- /*
- * The date the resource was last updated.
- */
- @JsonProperty(value = "lastUpdatedTimeStamp", access = JsonProperty.Access.WRITE_ONLY)
- private String lastUpdatedTimestamp;
-
- /*
- * The date the resource was created.
- */
- @JsonProperty(value = "createdTimeStamp", access = JsonProperty.Access.WRITE_ONLY)
- private String createdTimestamp;
-
- /*
- * The location where the SuppressionListAddress data is stored at rest. This value is inherited from the parent
- * Domains resource.
- */
- @JsonProperty(value = "dataLocation", access = JsonProperty.Access.WRITE_ONLY)
- private String dataLocation;
-
- /**
- * Creates an instance of SuppressionListProperties class.
- */
- public SuppressionListProperties() {
- }
-
- /**
- * Get the listName property: The the name of the suppression list. This value must match one of the valid sender
- * usernames of the sending domain.
- *
- * @return the listName value.
- */
- public String listName() {
- return this.listName;
- }
-
- /**
- * Set the listName property: The the name of the suppression list. This value must match one of the valid sender
- * usernames of the sending domain.
- *
- * @param listName the listName value to set.
- * @return the SuppressionListProperties object itself.
- */
- public SuppressionListProperties withListName(String listName) {
- this.listName = listName;
- return this;
- }
-
- /**
- * Get the lastUpdatedTimestamp property: The date the resource was last updated.
- *
- * @return the lastUpdatedTimestamp value.
- */
- public String lastUpdatedTimestamp() {
- return this.lastUpdatedTimestamp;
- }
-
- /**
- * Get the createdTimestamp property: The date the resource was created.
- *
- * @return the createdTimestamp value.
- */
- public String createdTimestamp() {
- return this.createdTimestamp;
- }
-
- /**
- * Get the dataLocation property: The location where the SuppressionListAddress data is stored at rest. This value
- * is inherited from the parent Domains resource.
- *
- * @return the dataLocation value.
- */
- public String dataLocation() {
- return this.dataLocation;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListResourceInner.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListResourceInner.java
deleted file mode 100644
index 7c6c73180aab3..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/fluent/models/SuppressionListResourceInner.java
+++ /dev/null
@@ -1,116 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/**
- * A class representing a SuppressionList resource.
- */
-@Fluent
-public final class SuppressionListResourceInner extends ProxyResource {
- /*
- * The properties of a SuppressionList resource.
- */
- @JsonProperty(value = "properties")
- private SuppressionListProperties innerProperties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
- private SystemData systemData;
-
- /**
- * Creates an instance of SuppressionListResourceInner class.
- */
- public SuppressionListResourceInner() {
- }
-
- /**
- * Get the innerProperties property: The properties of a SuppressionList resource.
- *
- * @return the innerProperties value.
- */
- private SuppressionListProperties innerProperties() {
- return this.innerProperties;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the listName property: The the name of the suppression list. This value must match one of the valid sender
- * usernames of the sending domain.
- *
- * @return the listName value.
- */
- public String listName() {
- return this.innerProperties() == null ? null : this.innerProperties().listName();
- }
-
- /**
- * Set the listName property: The the name of the suppression list. This value must match one of the valid sender
- * usernames of the sending domain.
- *
- * @param listName the listName value to set.
- * @return the SuppressionListResourceInner object itself.
- */
- public SuppressionListResourceInner withListName(String listName) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SuppressionListProperties();
- }
- this.innerProperties().withListName(listName);
- return this;
- }
-
- /**
- * Get the lastUpdatedTimestamp property: The date the resource was last updated.
- *
- * @return the lastUpdatedTimestamp value.
- */
- public String lastUpdatedTimestamp() {
- return this.innerProperties() == null ? null : this.innerProperties().lastUpdatedTimestamp();
- }
-
- /**
- * Get the createdTimestamp property: The date the resource was created.
- *
- * @return the createdTimestamp value.
- */
- public String createdTimestamp() {
- return this.innerProperties() == null ? null : this.innerProperties().createdTimestamp();
- }
-
- /**
- * Get the dataLocation property: The location where the SuppressionListAddress data is stored at rest. This value
- * is inherited from the parent Domains resource.
- *
- * @return the dataLocation value.
- */
- public String dataLocation() {
- return this.innerProperties() == null ? null : this.innerProperties().dataLocation();
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceManagementClientImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceManagementClientImpl.java
index 2b69cf4b39121..f297a227c9385 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceManagementClientImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceManagementClientImpl.java
@@ -28,8 +28,6 @@
import com.azure.resourcemanager.communication.fluent.EmailServicesClient;
import com.azure.resourcemanager.communication.fluent.OperationsClient;
import com.azure.resourcemanager.communication.fluent.SenderUsernamesClient;
-import com.azure.resourcemanager.communication.fluent.SuppressionListAddressesClient;
-import com.azure.resourcemanager.communication.fluent.SuppressionListsClient;
import java.io.IOException;
import java.lang.reflect.Type;
import java.nio.ByteBuffer;
@@ -198,34 +196,6 @@ public SenderUsernamesClient getSenderUsernames() {
return this.senderUsernames;
}
- /**
- * The SuppressionListsClient object to access its operations.
- */
- private final SuppressionListsClient suppressionLists;
-
- /**
- * Gets the SuppressionListsClient object to access its operations.
- *
- * @return the SuppressionListsClient object.
- */
- public SuppressionListsClient getSuppressionLists() {
- return this.suppressionLists;
- }
-
- /**
- * The SuppressionListAddressesClient object to access its operations.
- */
- private final SuppressionListAddressesClient suppressionListAddresses;
-
- /**
- * Gets the SuppressionListAddressesClient object to access its operations.
- *
- * @return the SuppressionListAddressesClient object.
- */
- public SuppressionListAddressesClient getSuppressionListAddresses() {
- return this.suppressionListAddresses;
- }
-
/**
* Initializes an instance of CommunicationServiceManagementClient client.
*
@@ -243,14 +213,12 @@ public SuppressionListAddressesClient getSuppressionListAddresses() {
this.defaultPollInterval = defaultPollInterval;
this.subscriptionId = subscriptionId;
this.endpoint = endpoint;
- this.apiVersion = "2023-06-01-preview";
+ this.apiVersion = "2023-04-01";
this.operations = new OperationsClientImpl(this);
this.communicationServices = new CommunicationServicesClientImpl(this);
this.domains = new DomainsClientImpl(this);
this.emailServices = new EmailServicesClientImpl(this);
this.senderUsernames = new SenderUsernamesClientImpl(this);
- this.suppressionLists = new SuppressionListsClientImpl(this);
- this.suppressionListAddresses = new SuppressionListAddressesClientImpl(this);
}
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceResourceImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceResourceImpl.java
index f6dc1574b70cf..35e0b47bb48a8 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceResourceImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServiceResourceImpl.java
@@ -164,8 +164,9 @@ public CommunicationServiceResource apply(Context context) {
com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.communicationServiceName = Utils.getValueFromIdByName(innerObject.id(), "communicationServices");
+ this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.communicationServiceName
+ = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "communicationServices");
}
public CommunicationServiceResource refresh() {
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServicesImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServicesImpl.java
index f3afb6fd3bf71..575c15c42268a 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServicesImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/CommunicationServicesImpl.java
@@ -82,24 +82,28 @@ public LinkedNotificationHub linkNotificationHub(String resourceGroupName, Strin
public PagedIterable list() {
PagedIterable inner = this.serviceClient().list();
- return Utils.mapPage(inner, inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
}
public PagedIterable list(Context context) {
PagedIterable inner = this.serviceClient().list(context);
- return Utils.mapPage(inner, inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
}
public PagedIterable listByResourceGroup(String resourceGroupName) {
PagedIterable inner
= this.serviceClient().listByResourceGroup(resourceGroupName);
- return Utils.mapPage(inner, inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
}
public PagedIterable listByResourceGroup(String resourceGroupName, Context context) {
PagedIterable inner
= this.serviceClient().listByResourceGroup(resourceGroupName, context);
- return Utils.mapPage(inner, inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new CommunicationServiceResourceImpl(inner1, this.manager()));
}
public Response getByResourceGroupWithResponse(String resourceGroupName,
@@ -178,12 +182,12 @@ public CommunicationServiceKeys regenerateKey(String resourceGroupName, String c
}
public CommunicationServiceResource getById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String communicationServiceName = Utils.getValueFromIdByName(id, "communicationServices");
+ String communicationServiceName = ResourceManagerUtils.getValueFromIdByName(id, "communicationServices");
if (communicationServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'communicationServices'.", id)));
@@ -193,12 +197,12 @@ public CommunicationServiceResource getById(String id) {
}
public Response getByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String communicationServiceName = Utils.getValueFromIdByName(id, "communicationServices");
+ String communicationServiceName = ResourceManagerUtils.getValueFromIdByName(id, "communicationServices");
if (communicationServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'communicationServices'.", id)));
@@ -207,12 +211,12 @@ public Response getByIdWithResponse(String id, Con
}
public void deleteById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String communicationServiceName = Utils.getValueFromIdByName(id, "communicationServices");
+ String communicationServiceName = ResourceManagerUtils.getValueFromIdByName(id, "communicationServices");
if (communicationServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'communicationServices'.", id)));
@@ -221,12 +225,12 @@ public void deleteById(String id) {
}
public void deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String communicationServiceName = Utils.getValueFromIdByName(id, "communicationServices");
+ String communicationServiceName = ResourceManagerUtils.getValueFromIdByName(id, "communicationServices");
if (communicationServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'communicationServices'.", id)));
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainResourceImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainResourceImpl.java
index 4cb397ef66dc7..9ccd9a727e910 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainResourceImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainResourceImpl.java
@@ -158,9 +158,9 @@ public DomainResource apply(Context context) {
com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.emailServiceName = Utils.getValueFromIdByName(innerObject.id(), "emailServices");
- this.domainName = Utils.getValueFromIdByName(innerObject.id(), "domains");
+ this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.emailServiceName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "emailServices");
+ this.domainName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "domains");
}
public DomainResource refresh() {
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainsImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainsImpl.java
index d4211e204ebe8..1b33deb6111ab 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainsImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/DomainsImpl.java
@@ -60,14 +60,14 @@ public void delete(String resourceGroupName, String emailServiceName, String dom
public PagedIterable listByEmailServiceResource(String resourceGroupName, String emailServiceName) {
PagedIterable inner
= this.serviceClient().listByEmailServiceResource(resourceGroupName, emailServiceName);
- return Utils.mapPage(inner, inner1 -> new DomainResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new DomainResourceImpl(inner1, this.manager()));
}
public PagedIterable listByEmailServiceResource(String resourceGroupName, String emailServiceName,
Context context) {
PagedIterable inner
= this.serviceClient().listByEmailServiceResource(resourceGroupName, emailServiceName, context);
- return Utils.mapPage(inner, inner1 -> new DomainResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new DomainResourceImpl(inner1, this.manager()));
}
public void initiateVerification(String resourceGroupName, String emailServiceName, String domainName,
@@ -91,17 +91,17 @@ public void cancelVerification(String resourceGroupName, String emailServiceName
}
public DomainResource getById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
@@ -110,17 +110,17 @@ public DomainResource getById(String id) {
}
public Response getByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
@@ -129,17 +129,17 @@ public Response getByIdWithResponse(String id, Context context)
}
public void deleteById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
@@ -148,17 +148,17 @@ public void deleteById(String id) {
}
public void deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServiceResourceImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServiceResourceImpl.java
index e0f8c95daa74e..b90d6eaab9c82 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServiceResourceImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServiceResourceImpl.java
@@ -127,8 +127,8 @@ public EmailServiceResource apply(Context context) {
com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.emailServiceName = Utils.getValueFromIdByName(innerObject.id(), "emailServices");
+ this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.emailServiceName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "emailServices");
}
public EmailServiceResource refresh() {
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServicesImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServicesImpl.java
index c5eb60ab3d84c..1bded74cf4130 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServicesImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/EmailServicesImpl.java
@@ -60,23 +60,23 @@ public void delete(String resourceGroupName, String emailServiceName, Context co
public PagedIterable list() {
PagedIterable inner = this.serviceClient().list();
- return Utils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
}
public PagedIterable list(Context context) {
PagedIterable inner = this.serviceClient().list(context);
- return Utils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
}
public PagedIterable listByResourceGroup(String resourceGroupName) {
PagedIterable inner = this.serviceClient().listByResourceGroup(resourceGroupName);
- return Utils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
}
public PagedIterable listByResourceGroup(String resourceGroupName, Context context) {
PagedIterable inner
= this.serviceClient().listByResourceGroup(resourceGroupName, context);
- return Utils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new EmailServiceResourceImpl(inner1, this.manager()));
}
public Response> listVerifiedExchangeOnlineDomainsWithResponse(Context context) {
@@ -93,12 +93,12 @@ public List listVerifiedExchangeOnlineDomains() {
}
public EmailServiceResource getById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
@@ -107,12 +107,12 @@ public EmailServiceResource getById(String id) {
}
public Response getByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
@@ -121,12 +121,12 @@ public Response getByIdWithResponse(String id, Context con
}
public void deleteById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
@@ -135,12 +135,12 @@ public void deleteById(String id) {
}
public void deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/OperationsImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/OperationsImpl.java
index 9ae692e3eb4fc..00ae41663b401 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/OperationsImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/OperationsImpl.java
@@ -27,12 +27,12 @@ public OperationsImpl(OperationsClient innerClient,
public PagedIterable list() {
PagedIterable inner = this.serviceClient().list();
- return Utils.mapPage(inner, inner1 -> new OperationImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new OperationImpl(inner1, this.manager()));
}
public PagedIterable list(Context context) {
PagedIterable inner = this.serviceClient().list(context);
- return Utils.mapPage(inner, inner1 -> new OperationImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new OperationImpl(inner1, this.manager()));
}
private OperationsClient serviceClient() {
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/Utils.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/ResourceManagerUtils.java
similarity index 99%
rename from sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/Utils.java
rename to sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/ResourceManagerUtils.java
index 948ad475cf5d9..31004fac799fa 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/Utils.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/ResourceManagerUtils.java
@@ -19,8 +19,8 @@
import java.util.stream.Stream;
import reactor.core.publisher.Flux;
-final class Utils {
- private Utils() {
+final class ResourceManagerUtils {
+ private ResourceManagerUtils() {
}
static String getValueFromIdByName(String id, String name) {
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernameResourceImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernameResourceImpl.java
index c03428c1b0ed9..990d14def0cfe 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernameResourceImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernameResourceImpl.java
@@ -119,10 +119,10 @@ public SenderUsernameResource apply(Context context) {
com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.emailServiceName = Utils.getValueFromIdByName(innerObject.id(), "emailServices");
- this.domainName = Utils.getValueFromIdByName(innerObject.id(), "domains");
- this.senderUsername = Utils.getValueFromIdByName(innerObject.id(), "senderUsernames");
+ this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.emailServiceName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "emailServices");
+ this.domainName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "domains");
+ this.senderUsername = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "senderUsernames");
}
public SenderUsernameResource refresh() {
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernamesImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernamesImpl.java
index 8952ec9d44d4d..b83e97238d9ec 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernamesImpl.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SenderUsernamesImpl.java
@@ -31,14 +31,14 @@ public PagedIterable listByDomains(String resourceGroupN
String domainName) {
PagedIterable inner
= this.serviceClient().listByDomains(resourceGroupName, emailServiceName, domainName);
- return Utils.mapPage(inner, inner1 -> new SenderUsernameResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new SenderUsernameResourceImpl(inner1, this.manager()));
}
public PagedIterable listByDomains(String resourceGroupName, String emailServiceName,
String domainName, Context context) {
PagedIterable inner
= this.serviceClient().listByDomains(resourceGroupName, emailServiceName, domainName, context);
- return Utils.mapPage(inner, inner1 -> new SenderUsernameResourceImpl(inner1, this.manager()));
+ return ResourceManagerUtils.mapPage(inner, inner1 -> new SenderUsernameResourceImpl(inner1, this.manager()));
}
public Response getWithResponse(String resourceGroupName, String emailServiceName,
@@ -75,22 +75,22 @@ public void delete(String resourceGroupName, String emailServiceName, String dom
}
public SenderUsernameResource getById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
}
- String senderUsername = Utils.getValueFromIdByName(id, "senderUsernames");
+ String senderUsername = ResourceManagerUtils.getValueFromIdByName(id, "senderUsernames");
if (senderUsername == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'senderUsernames'.", id)));
@@ -100,22 +100,22 @@ public SenderUsernameResource getById(String id) {
}
public Response getByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
}
- String senderUsername = Utils.getValueFromIdByName(id, "senderUsernames");
+ String senderUsername = ResourceManagerUtils.getValueFromIdByName(id, "senderUsernames");
if (senderUsername == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'senderUsernames'.", id)));
@@ -124,22 +124,22 @@ public Response getByIdWithResponse(String id, Context c
}
public void deleteById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
}
- String senderUsername = Utils.getValueFromIdByName(id, "senderUsernames");
+ String senderUsername = ResourceManagerUtils.getValueFromIdByName(id, "senderUsernames");
if (senderUsername == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'senderUsernames'.", id)));
@@ -148,22 +148,22 @@ public void deleteById(String id) {
}
public Response deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
+ String emailServiceName = ResourceManagerUtils.getValueFromIdByName(id, "emailServices");
if (emailServiceName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
}
- String domainName = Utils.getValueFromIdByName(id, "domains");
+ String domainName = ResourceManagerUtils.getValueFromIdByName(id, "domains");
if (domainName == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
}
- String senderUsername = Utils.getValueFromIdByName(id, "senderUsernames");
+ String senderUsername = ResourceManagerUtils.getValueFromIdByName(id, "senderUsernames");
if (senderUsername == null) {
throw LOGGER.logExceptionAsError(new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'senderUsernames'.", id)));
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressResourceImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressResourceImpl.java
deleted file mode 100644
index 79ae511bb3ac0..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressResourceImpl.java
+++ /dev/null
@@ -1,179 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.implementation;
-
-import com.azure.core.management.SystemData;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListAddressResource;
-import java.time.OffsetDateTime;
-
-public final class SuppressionListAddressResourceImpl implements SuppressionListAddressResource,
- SuppressionListAddressResource.Definition, SuppressionListAddressResource.Update {
- private SuppressionListAddressResourceInner innerObject;
-
- private final com.azure.resourcemanager.communication.CommunicationManager serviceManager;
-
- public String id() {
- return this.innerModel().id();
- }
-
- public String name() {
- return this.innerModel().name();
- }
-
- public String type() {
- return this.innerModel().type();
- }
-
- public SystemData systemData() {
- return this.innerModel().systemData();
- }
-
- public String email() {
- return this.innerModel().email();
- }
-
- public String firstName() {
- return this.innerModel().firstName();
- }
-
- public String lastName() {
- return this.innerModel().lastName();
- }
-
- public String notes() {
- return this.innerModel().notes();
- }
-
- public OffsetDateTime lastModified() {
- return this.innerModel().lastModified();
- }
-
- public String dataLocation() {
- return this.innerModel().dataLocation();
- }
-
- public String resourceGroupName() {
- return resourceGroupName;
- }
-
- public SuppressionListAddressResourceInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.communication.CommunicationManager manager() {
- return this.serviceManager;
- }
-
- private String resourceGroupName;
-
- private String emailServiceName;
-
- private String domainName;
-
- private String suppressionListName;
-
- private String addressId;
-
- public SuppressionListAddressResourceImpl withExistingSuppressionList(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName) {
- this.resourceGroupName = resourceGroupName;
- this.emailServiceName = emailServiceName;
- this.domainName = domainName;
- this.suppressionListName = suppressionListName;
- return this;
- }
-
- public SuppressionListAddressResource create() {
- this.innerObject = serviceManager
- .serviceClient().getSuppressionListAddresses().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, addressId, this.innerModel(), Context.NONE)
- .getValue();
- return this;
- }
-
- public SuppressionListAddressResource create(Context context) {
- this.innerObject
- = serviceManager
- .serviceClient().getSuppressionListAddresses().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, addressId, this.innerModel(), context)
- .getValue();
- return this;
- }
-
- SuppressionListAddressResourceImpl(String name,
- com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
- this.innerObject = new SuppressionListAddressResourceInner();
- this.serviceManager = serviceManager;
- this.addressId = name;
- }
-
- public SuppressionListAddressResourceImpl update() {
- return this;
- }
-
- public SuppressionListAddressResource apply() {
- this.innerObject = serviceManager
- .serviceClient().getSuppressionListAddresses().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, addressId, this.innerModel(), Context.NONE)
- .getValue();
- return this;
- }
-
- public SuppressionListAddressResource apply(Context context) {
- this.innerObject
- = serviceManager
- .serviceClient().getSuppressionListAddresses().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, addressId, this.innerModel(), context)
- .getValue();
- return this;
- }
-
- SuppressionListAddressResourceImpl(SuppressionListAddressResourceInner innerObject,
- com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.emailServiceName = Utils.getValueFromIdByName(innerObject.id(), "emailServices");
- this.domainName = Utils.getValueFromIdByName(innerObject.id(), "domains");
- this.suppressionListName = Utils.getValueFromIdByName(innerObject.id(), "suppressionLists");
- this.addressId = Utils.getValueFromIdByName(innerObject.id(), "suppressionListAddresses");
- }
-
- public SuppressionListAddressResource refresh() {
- this.innerObject
- = serviceManager.serviceClient().getSuppressionListAddresses().getWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, addressId, Context.NONE).getValue();
- return this;
- }
-
- public SuppressionListAddressResource refresh(Context context) {
- this.innerObject = serviceManager.serviceClient().getSuppressionListAddresses()
- .getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId, context)
- .getValue();
- return this;
- }
-
- public SuppressionListAddressResourceImpl withEmail(String email) {
- this.innerModel().withEmail(email);
- return this;
- }
-
- public SuppressionListAddressResourceImpl withFirstName(String firstName) {
- this.innerModel().withFirstName(firstName);
- return this;
- }
-
- public SuppressionListAddressResourceImpl withLastName(String lastName) {
- this.innerModel().withLastName(lastName);
- return this;
- }
-
- public SuppressionListAddressResourceImpl withNotes(String notes) {
- this.innerModel().withNotes(notes);
- return this;
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressesClientImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressesClientImpl.java
deleted file mode 100644
index 48f9c40e59a57..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressesClientImpl.java
+++ /dev/null
@@ -1,900 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.implementation;
-
-import com.azure.core.annotation.BodyParam;
-import com.azure.core.annotation.Delete;
-import com.azure.core.annotation.ExpectedResponses;
-import com.azure.core.annotation.Get;
-import com.azure.core.annotation.HeaderParam;
-import com.azure.core.annotation.Headers;
-import com.azure.core.annotation.Host;
-import com.azure.core.annotation.HostParam;
-import com.azure.core.annotation.PathParam;
-import com.azure.core.annotation.Put;
-import com.azure.core.annotation.QueryParam;
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceInterface;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.annotation.UnexpectedResponseExceptionType;
-import com.azure.core.http.rest.PagedFlux;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.PagedResponse;
-import com.azure.core.http.rest.PagedResponseBase;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.RestProxy;
-import com.azure.core.management.exception.ManagementException;
-import com.azure.core.util.Context;
-import com.azure.core.util.FluxUtil;
-import com.azure.resourcemanager.communication.fluent.SuppressionListAddressesClient;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListAddressResourceCollection;
-import reactor.core.publisher.Mono;
-
-/**
- * An instance of this class provides access to all the operations defined in SuppressionListAddressesClient.
- */
-public final class SuppressionListAddressesClientImpl implements SuppressionListAddressesClient {
- /**
- * The proxy service used to perform REST calls.
- */
- private final SuppressionListAddressesService service;
-
- /**
- * The service client containing this operation class.
- */
- private final CommunicationServiceManagementClientImpl client;
-
- /**
- * Initializes an instance of SuppressionListAddressesClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- SuppressionListAddressesClientImpl(CommunicationServiceManagementClientImpl client) {
- this.service = RestProxy.create(SuppressionListAddressesService.class, client.getHttpPipeline(),
- client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for CommunicationServiceManagementClientSuppressionListAddresses to be
- * used by the proxy service to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "CommunicationService")
- public interface SuppressionListAddressesService {
- @Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists/{suppressionListName}/suppressionListAddresses")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @PathParam("suppressionListName") String suppressionListName, @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists/{suppressionListName}/suppressionListAddresses/{addressId}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @PathParam("suppressionListName") String suppressionListName, @PathParam("addressId") String addressId,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists/{suppressionListName}/suppressionListAddresses/{addressId}")
- @ExpectedResponses({ 200, 201 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> createOrUpdate(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @PathParam("suppressionListName") String suppressionListName, @PathParam("addressId") String addressId,
- @BodyParam("application/json") SuppressionListAddressResourceInner parameters,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists/{suppressionListName}/suppressionListAddresses/{addressId}")
- @ExpectedResponses({ 200, 204 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> delete(@HostParam("$host") String endpoint, @QueryParam("api-version") String apiVersion,
- @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @PathParam("suppressionListName") String suppressionListName, @PathParam("addressId") String addressId,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("{nextLink}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listNext(
- @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
- @HeaderParam("Accept") String accept, Context context);
- }
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list along with {@link PagedResponse} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.list(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list along with {@link PagedResponse} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, emailServiceName, domainName, suppressionListName, accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(resourceGroupName, emailServiceName, domainName, suppressionListName),
- nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, context),
- nextLink -> listNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName) {
- return new PagedIterable<>(listAsync(resourceGroupName, emailServiceName, domainName, suppressionListName));
- }
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context) {
- return new PagedIterable<>(
- listAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, context));
- }
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress along with {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, String addressId) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (addressId == null) {
- return Mono.error(new IllegalArgumentException("Parameter addressId is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.get(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- addressId, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress along with {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, String addressId, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (addressId == null) {
- return Mono.error(new IllegalArgumentException("Parameter addressId is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.get(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, emailServiceName, domainName, suppressionListName, addressId, accept, context);
- }
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId) {
- return getWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, String addressId, Context context) {
- return getWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- context).block();
- }
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public SuppressionListAddressResourceInner get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId) {
- return getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- Context.NONE).getValue();
- }
-
- /**
- * Create Or Update
- *
- * Create or update a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a object that represents a SuppressionList record along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(
- String resourceGroupName, String emailServiceName, String domainName, String suppressionListName,
- String addressId, SuppressionListAddressResourceInner parameters) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (addressId == null) {
- return Mono.error(new IllegalArgumentException("Parameter addressId is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- addressId, parameters, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Create Or Update
- *
- * Create or update a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param parameters Parameters for the create or update operation.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a object that represents a SuppressionList record along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(
- String resourceGroupName, String emailServiceName, String domainName, String suppressionListName,
- String addressId, SuppressionListAddressResourceInner parameters, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (addressId == null) {
- return Mono.error(new IllegalArgumentException("Parameter addressId is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- addressId, parameters, accept, context);
- }
-
- /**
- * Create Or Update
- *
- * Create or update a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a object that represents a SuppressionList record on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, String addressId,
- SuppressionListAddressResourceInner parameters) {
- return createOrUpdateWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName,
- addressId, parameters).flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Create Or Update
- *
- * Create or update a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param parameters Parameters for the create or update operation.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a object that represents a SuppressionList record along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response createOrUpdateWithResponse(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, String addressId,
- SuppressionListAddressResourceInner parameters, Context context) {
- return createOrUpdateWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName,
- addressId, parameters, context).block();
- }
-
- /**
- * Create Or Update
- *
- * Create or update a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a object that represents a SuppressionList record.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public SuppressionListAddressResourceInner createOrUpdate(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId,
- SuppressionListAddressResourceInner parameters) {
- return createOrUpdateWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName,
- addressId, parameters, Context.NONE).getValue();
- }
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (addressId == null) {
- return Mono.error(new IllegalArgumentException("Parameter addressId is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.delete(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- addressId, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (addressId == null) {
- return Mono.error(new IllegalArgumentException("Parameter addressId is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.delete(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, emailServiceName, domainName, suppressionListName, addressId, accept, context);
- }
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return A {@link Mono} that completes when a successful response is received.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono deleteAsync(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId) {
- return deleteWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId)
- .flatMap(ignored -> Mono.empty());
- }
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId, Context context) {
- return deleteWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- context).block();
- }
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public void delete(String resourceGroupName, String emailServiceName, String domainName, String suppressionListName,
- String addressId) {
- deleteWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- Context.NONE);
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items
- *
- * The nextLink parameter.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return collection of addresses in a suppression list along with {@link PagedResponse} on successful completion
- * of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil.withContext(context -> service.listNext(nextLink, this.client.getEndpoint(), accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items
- *
- * The nextLink parameter.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return collection of addresses in a suppression list along with {@link PagedResponse} on successful completion
- * of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink,
- Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.listNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressesImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressesImpl.java
deleted file mode 100644
index 6611b075166ce..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListAddressesImpl.java
+++ /dev/null
@@ -1,209 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.implementation;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.SimpleResponse;
-import com.azure.core.util.Context;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.communication.fluent.SuppressionListAddressesClient;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListAddressResource;
-import com.azure.resourcemanager.communication.models.SuppressionListAddresses;
-
-public final class SuppressionListAddressesImpl implements SuppressionListAddresses {
- private static final ClientLogger LOGGER = new ClientLogger(SuppressionListAddressesImpl.class);
-
- private final SuppressionListAddressesClient innerClient;
-
- private final com.azure.resourcemanager.communication.CommunicationManager serviceManager;
-
- public SuppressionListAddressesImpl(SuppressionListAddressesClient innerClient,
- com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
- this.innerClient = innerClient;
- this.serviceManager = serviceManager;
- }
-
- public PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName) {
- PagedIterable inner
- = this.serviceClient().list(resourceGroupName, emailServiceName, domainName, suppressionListName);
- return Utils.mapPage(inner, inner1 -> new SuppressionListAddressResourceImpl(inner1, this.manager()));
- }
-
- public PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context) {
- PagedIterable inner
- = this.serviceClient().list(resourceGroupName, emailServiceName, domainName, suppressionListName, context);
- return Utils.mapPage(inner, inner1 -> new SuppressionListAddressResourceImpl(inner1, this.manager()));
- }
-
- public Response getWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId, Context context) {
- Response inner = this.serviceClient().getWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, addressId, context);
- if (inner != null) {
- return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
- new SuppressionListAddressResourceImpl(inner.getValue(), this.manager()));
- } else {
- return null;
- }
- }
-
- public SuppressionListAddressResource get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId) {
- SuppressionListAddressResourceInner inner
- = this.serviceClient().get(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId);
- if (inner != null) {
- return new SuppressionListAddressResourceImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
- public Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId, Context context) {
- return this.serviceClient().deleteWithResponse(resourceGroupName, emailServiceName, domainName,
- suppressionListName, addressId, context);
- }
-
- public void delete(String resourceGroupName, String emailServiceName, String domainName, String suppressionListName,
- String addressId) {
- this.serviceClient().delete(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId);
- }
-
- public SuppressionListAddressResource getById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- String addressId = Utils.getValueFromIdByName(id, "suppressionListAddresses");
- if (addressId == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
- .format("The resource ID '%s' is not valid. Missing path segment 'suppressionListAddresses'.", id)));
- }
- return this.getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- Context.NONE).getValue();
- }
-
- public Response getByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- String addressId = Utils.getValueFromIdByName(id, "suppressionListAddresses");
- if (addressId == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
- .format("The resource ID '%s' is not valid. Missing path segment 'suppressionListAddresses'.", id)));
- }
- return this.getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- context);
- }
-
- public void deleteById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- String addressId = Utils.getValueFromIdByName(id, "suppressionListAddresses");
- if (addressId == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
- .format("The resource ID '%s' is not valid. Missing path segment 'suppressionListAddresses'.", id)));
- }
- this.deleteWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- Context.NONE);
- }
-
- public Response deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- String addressId = Utils.getValueFromIdByName(id, "suppressionListAddresses");
- if (addressId == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
- .format("The resource ID '%s' is not valid. Missing path segment 'suppressionListAddresses'.", id)));
- }
- return this.deleteWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, addressId,
- context);
- }
-
- private SuppressionListAddressesClient serviceClient() {
- return this.innerClient;
- }
-
- private com.azure.resourcemanager.communication.CommunicationManager manager() {
- return this.serviceManager;
- }
-
- public SuppressionListAddressResourceImpl define(String name) {
- return new SuppressionListAddressResourceImpl(name, this.manager());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListResourceImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListResourceImpl.java
deleted file mode 100644
index 5a49c380727be..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListResourceImpl.java
+++ /dev/null
@@ -1,144 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.implementation;
-
-import com.azure.core.management.SystemData;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListResource;
-
-public final class SuppressionListResourceImpl
- implements SuppressionListResource, SuppressionListResource.Definition, SuppressionListResource.Update {
- private SuppressionListResourceInner innerObject;
-
- private final com.azure.resourcemanager.communication.CommunicationManager serviceManager;
-
- public String id() {
- return this.innerModel().id();
- }
-
- public String name() {
- return this.innerModel().name();
- }
-
- public String type() {
- return this.innerModel().type();
- }
-
- public SystemData systemData() {
- return this.innerModel().systemData();
- }
-
- public String listName() {
- return this.innerModel().listName();
- }
-
- public String lastUpdatedTimestamp() {
- return this.innerModel().lastUpdatedTimestamp();
- }
-
- public String createdTimestamp() {
- return this.innerModel().createdTimestamp();
- }
-
- public String dataLocation() {
- return this.innerModel().dataLocation();
- }
-
- public String resourceGroupName() {
- return resourceGroupName;
- }
-
- public SuppressionListResourceInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.communication.CommunicationManager manager() {
- return this.serviceManager;
- }
-
- private String resourceGroupName;
-
- private String emailServiceName;
-
- private String domainName;
-
- private String suppressionListName;
-
- public SuppressionListResourceImpl withExistingDomain(String resourceGroupName, String emailServiceName,
- String domainName) {
- this.resourceGroupName = resourceGroupName;
- this.emailServiceName = emailServiceName;
- this.domainName = domainName;
- return this;
- }
-
- public SuppressionListResource create() {
- this.innerObject
- = serviceManager.serviceClient().getSuppressionLists().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, this.innerModel(), Context.NONE).getValue();
- return this;
- }
-
- public SuppressionListResource create(Context context) {
- this.innerObject
- = serviceManager.serviceClient().getSuppressionLists().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, this.innerModel(), context).getValue();
- return this;
- }
-
- SuppressionListResourceImpl(String name,
- com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
- this.innerObject = new SuppressionListResourceInner();
- this.serviceManager = serviceManager;
- this.suppressionListName = name;
- }
-
- public SuppressionListResourceImpl update() {
- return this;
- }
-
- public SuppressionListResource apply() {
- this.innerObject
- = serviceManager.serviceClient().getSuppressionLists().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, this.innerModel(), Context.NONE).getValue();
- return this;
- }
-
- public SuppressionListResource apply(Context context) {
- this.innerObject
- = serviceManager.serviceClient().getSuppressionLists().createOrUpdateWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, this.innerModel(), context).getValue();
- return this;
- }
-
- SuppressionListResourceImpl(SuppressionListResourceInner innerObject,
- com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.emailServiceName = Utils.getValueFromIdByName(innerObject.id(), "emailServices");
- this.domainName = Utils.getValueFromIdByName(innerObject.id(), "domains");
- this.suppressionListName = Utils.getValueFromIdByName(innerObject.id(), "suppressionLists");
- }
-
- public SuppressionListResource refresh() {
- this.innerObject = serviceManager.serviceClient().getSuppressionLists()
- .getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, Context.NONE)
- .getValue();
- return this;
- }
-
- public SuppressionListResource refresh(Context context) {
- this.innerObject = serviceManager.serviceClient().getSuppressionLists()
- .getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, context).getValue();
- return this;
- }
-
- public SuppressionListResourceImpl withListName(String listName) {
- this.innerModel().withListName(listName);
- return this;
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListsClientImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListsClientImpl.java
deleted file mode 100644
index 65bf17e244c73..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListsClientImpl.java
+++ /dev/null
@@ -1,856 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.implementation;
-
-import com.azure.core.annotation.BodyParam;
-import com.azure.core.annotation.Delete;
-import com.azure.core.annotation.ExpectedResponses;
-import com.azure.core.annotation.Get;
-import com.azure.core.annotation.HeaderParam;
-import com.azure.core.annotation.Headers;
-import com.azure.core.annotation.Host;
-import com.azure.core.annotation.HostParam;
-import com.azure.core.annotation.PathParam;
-import com.azure.core.annotation.Put;
-import com.azure.core.annotation.QueryParam;
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceInterface;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.annotation.UnexpectedResponseExceptionType;
-import com.azure.core.http.rest.PagedFlux;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.PagedResponse;
-import com.azure.core.http.rest.PagedResponseBase;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.RestProxy;
-import com.azure.core.management.exception.ManagementException;
-import com.azure.core.util.Context;
-import com.azure.core.util.FluxUtil;
-import com.azure.resourcemanager.communication.fluent.SuppressionListsClient;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListResourceCollection;
-import reactor.core.publisher.Mono;
-
-/**
- * An instance of this class provides access to all the operations defined in SuppressionListsClient.
- */
-public final class SuppressionListsClientImpl implements SuppressionListsClient {
- /**
- * The proxy service used to perform REST calls.
- */
- private final SuppressionListsService service;
-
- /**
- * The service client containing this operation class.
- */
- private final CommunicationServiceManagementClientImpl client;
-
- /**
- * Initializes an instance of SuppressionListsClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- SuppressionListsClientImpl(CommunicationServiceManagementClientImpl client) {
- this.service
- = RestProxy.create(SuppressionListsService.class, client.getHttpPipeline(), client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for CommunicationServiceManagementClientSuppressionLists to be used by
- * the proxy service to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "CommunicationService")
- public interface SuppressionListsService {
- @Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByDomain(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists/{suppressionListName}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @PathParam("suppressionListName") String suppressionListName, @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists/{suppressionListName}")
- @ExpectedResponses({ 200, 201 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> createOrUpdate(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @PathParam("suppressionListName") String suppressionListName,
- @BodyParam("application/json") SuppressionListResourceInner parameters,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Communication/emailServices/{emailServiceName}/domains/{domainName}/suppressionLists/{suppressionListName}")
- @ExpectedResponses({ 200, 204 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> delete(@HostParam("$host") String endpoint, @QueryParam("api-version") String apiVersion,
- @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("emailServiceName") String emailServiceName, @PathParam("domainName") String domainName,
- @PathParam("suppressionListName") String suppressionListName, @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("{nextLink}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByDomainNext(
- @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
- @HeaderParam("Accept") String accept, Context context);
- }
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByDomainSinglePageAsync(String resourceGroupName,
- String emailServiceName, String domainName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.listByDomain(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByDomainSinglePageAsync(String resourceGroupName,
- String emailServiceName, String domainName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .listByDomain(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, emailServiceName, domainName, accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByDomainAsync(String resourceGroupName, String emailServiceName,
- String domainName) {
- return new PagedFlux<>(() -> listByDomainSinglePageAsync(resourceGroupName, emailServiceName, domainName),
- nextLink -> listByDomainNextSinglePageAsync(nextLink));
- }
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByDomainAsync(String resourceGroupName, String emailServiceName,
- String domainName, Context context) {
- return new PagedFlux<>(
- () -> listByDomainSinglePageAsync(resourceGroupName, emailServiceName, domainName, context),
- nextLink -> listByDomainNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName) {
- return new PagedIterable<>(listByDomainAsync(resourceGroupName, emailServiceName, domainName));
- }
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName, Context context) {
- return new PagedIterable<>(listByDomainAsync(resourceGroupName, emailServiceName, domainName, context));
- }
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource along with {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.get(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource along with {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.get(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, emailServiceName, domainName, suppressionListName, accept, context);
- }
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName) {
- return getWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context) {
- return getWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, context)
- .block();
- }
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public SuppressionListResourceInner get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName) {
- return getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, Context.NONE)
- .getValue();
- }
-
- /**
- * Create Or Update
- *
- * Add a new SuppressionList resource under the parent Domains resource or update an existing SuppressionList
- * resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a SuppressionList resource along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName,
- SuppressionListResourceInner parameters) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- parameters, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Create Or Update
- *
- * Add a new SuppressionList resource under the parent Domains resource or update an existing SuppressionList
- * resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param parameters Parameters for the create or update operation.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a SuppressionList resource along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, SuppressionListResourceInner parameters,
- Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- parameters, accept, context);
- }
-
- /**
- * Create Or Update
- *
- * Add a new SuppressionList resource under the parent Domains resource or update an existing SuppressionList
- * resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a SuppressionList resource on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, SuppressionListResourceInner parameters) {
- return createOrUpdateWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName,
- parameters).flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Create Or Update
- *
- * Add a new SuppressionList resource under the parent Domains resource or update an existing SuppressionList
- * resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param parameters Parameters for the create or update operation.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a SuppressionList resource along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response createOrUpdateWithResponse(String resourceGroupName,
- String emailServiceName, String domainName, String suppressionListName, SuppressionListResourceInner parameters,
- Context context) {
- return createOrUpdateWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName,
- parameters, context).block();
- }
-
- /**
- * Create Or Update
- *
- * Add a new SuppressionList resource under the parent Domains resource or update an existing SuppressionList
- * resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param parameters Parameters for the create or update operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a SuppressionList resource.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public SuppressionListResourceInner createOrUpdate(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, SuppressionListResourceInner parameters) {
- return createOrUpdateWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName,
- parameters, Context.NONE).getValue();
- }
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.delete(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, emailServiceName, domainName, suppressionListName,
- accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (emailServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter emailServiceName is required and cannot be null."));
- }
- if (domainName == null) {
- return Mono.error(new IllegalArgumentException("Parameter domainName is required and cannot be null."));
- }
- if (suppressionListName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter suppressionListName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.delete(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, emailServiceName, domainName, suppressionListName, accept, context);
- }
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return A {@link Mono} that completes when a successful response is received.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono deleteAsync(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName) {
- return deleteWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName)
- .flatMap(ignored -> Mono.empty());
- }
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, Context context) {
- return deleteWithResponseAsync(resourceGroupName, emailServiceName, domainName, suppressionListName, context)
- .block();
- }
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public void delete(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName) {
- deleteWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, Context.NONE);
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items
- *
- * The nextLink parameter.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByDomainNextSinglePageAsync(String nextLink) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.listByDomainNext(nextLink, this.client.getEndpoint(), accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items
- *
- * The nextLink parameter.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByDomainNextSinglePageAsync(String nextLink,
- Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.listByDomainNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListsImpl.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListsImpl.java
deleted file mode 100644
index da7eb0ac9b929..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/implementation/SuppressionListsImpl.java
+++ /dev/null
@@ -1,186 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.implementation;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.SimpleResponse;
-import com.azure.core.util.Context;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.communication.fluent.SuppressionListsClient;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListResource;
-import com.azure.resourcemanager.communication.models.SuppressionLists;
-
-public final class SuppressionListsImpl implements SuppressionLists {
- private static final ClientLogger LOGGER = new ClientLogger(SuppressionListsImpl.class);
-
- private final SuppressionListsClient innerClient;
-
- private final com.azure.resourcemanager.communication.CommunicationManager serviceManager;
-
- public SuppressionListsImpl(SuppressionListsClient innerClient,
- com.azure.resourcemanager.communication.CommunicationManager serviceManager) {
- this.innerClient = innerClient;
- this.serviceManager = serviceManager;
- }
-
- public PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName) {
- PagedIterable inner
- = this.serviceClient().listByDomain(resourceGroupName, emailServiceName, domainName);
- return Utils.mapPage(inner, inner1 -> new SuppressionListResourceImpl(inner1, this.manager()));
- }
-
- public PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName, Context context) {
- PagedIterable inner
- = this.serviceClient().listByDomain(resourceGroupName, emailServiceName, domainName, context);
- return Utils.mapPage(inner, inner1 -> new SuppressionListResourceImpl(inner1, this.manager()));
- }
-
- public Response getWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context) {
- Response inner = this.serviceClient().getWithResponse(resourceGroupName,
- emailServiceName, domainName, suppressionListName, context);
- if (inner != null) {
- return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
- new SuppressionListResourceImpl(inner.getValue(), this.manager()));
- } else {
- return null;
- }
- }
-
- public SuppressionListResource get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName) {
- SuppressionListResourceInner inner
- = this.serviceClient().get(resourceGroupName, emailServiceName, domainName, suppressionListName);
- if (inner != null) {
- return new SuppressionListResourceImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
- public Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, Context context) {
- return this.serviceClient().deleteWithResponse(resourceGroupName, emailServiceName, domainName,
- suppressionListName, context);
- }
-
- public void delete(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName) {
- this.serviceClient().delete(resourceGroupName, emailServiceName, domainName, suppressionListName);
- }
-
- public SuppressionListResource getById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- return this.getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, Context.NONE)
- .getValue();
- }
-
- public Response getByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- return this.getWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, context);
- }
-
- public void deleteById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- this.deleteWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, Context.NONE);
- }
-
- public Response deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String emailServiceName = Utils.getValueFromIdByName(id, "emailServices");
- if (emailServiceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'emailServices'.", id)));
- }
- String domainName = Utils.getValueFromIdByName(id, "domains");
- if (domainName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'domains'.", id)));
- }
- String suppressionListName = Utils.getValueFromIdByName(id, "suppressionLists");
- if (suppressionListName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'suppressionLists'.", id)));
- }
- return this.deleteWithResponse(resourceGroupName, emailServiceName, domainName, suppressionListName, context);
- }
-
- private SuppressionListsClient serviceClient() {
- return this.innerClient;
- }
-
- private com.azure.resourcemanager.communication.CommunicationManager manager() {
- return this.serviceManager;
- }
-
- public SuppressionListResourceImpl define(String name) {
- return new SuppressionListResourceImpl(name, this.manager());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddressResource.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddressResource.java
deleted file mode 100644
index bcd43c596fdc6..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddressResource.java
+++ /dev/null
@@ -1,311 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.models;
-
-import com.azure.core.management.SystemData;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-import java.time.OffsetDateTime;
-
-/**
- * An immutable client-side representation of SuppressionListAddressResource.
- */
-public interface SuppressionListAddressResource {
- /**
- * Gets the id property: Fully qualified resource Id for the resource.
- *
- * @return the id value.
- */
- String id();
-
- /**
- * Gets the name property: The name of the resource.
- *
- * @return the name value.
- */
- String name();
-
- /**
- * Gets the type property: The type of the resource.
- *
- * @return the type value.
- */
- String type();
-
- /**
- * Gets the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- SystemData systemData();
-
- /**
- * Gets the email property: Email address of the recipient.
- *
- * @return the email value.
- */
- String email();
-
- /**
- * Gets the firstName property: The first name of the email recipient.
- *
- * @return the firstName value.
- */
- String firstName();
-
- /**
- * Gets the lastName property: The last name of the email recipient.
- *
- * @return the lastName value.
- */
- String lastName();
-
- /**
- * Gets the notes property: An optional property to provide contextual notes or a description for an address.
- *
- * @return the notes value.
- */
- String notes();
-
- /**
- * Gets the lastModified property: The date the address was last updated in a suppression list.
- *
- * @return the lastModified value.
- */
- OffsetDateTime lastModified();
-
- /**
- * Gets the dataLocation property: The location where the SuppressionListAddress data is stored at rest. This value
- * is inherited from the parent Domains resource.
- *
- * @return the dataLocation value.
- */
- String dataLocation();
-
- /**
- * Gets the name of the resource group.
- *
- * @return the name of the resource group.
- */
- String resourceGroupName();
-
- /**
- * Gets the inner com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner object.
- *
- * @return the inner object.
- */
- SuppressionListAddressResourceInner innerModel();
-
- /**
- * The entirety of the SuppressionListAddressResource definition.
- */
- interface Definition
- extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate {
- }
-
- /**
- * The SuppressionListAddressResource definition stages.
- */
- interface DefinitionStages {
- /**
- * The first stage of the SuppressionListAddressResource definition.
- */
- interface Blank extends WithParentResource {
- }
-
- /**
- * The stage of the SuppressionListAddressResource definition allowing to specify parent resource.
- */
- interface WithParentResource {
- /**
- * Specifies resourceGroupName, emailServiceName, domainName, suppressionListName.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @return the next definition stage.
- */
- WithCreate withExistingSuppressionList(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName);
- }
-
- /**
- * The stage of the SuppressionListAddressResource definition which contains all the minimum required properties
- * for the resource to be created, but also allows for any other optional properties to be specified.
- */
- interface WithCreate extends DefinitionStages.WithEmail, DefinitionStages.WithFirstName,
- DefinitionStages.WithLastName, DefinitionStages.WithNotes {
- /**
- * Executes the create request.
- *
- * @return the created resource.
- */
- SuppressionListAddressResource create();
-
- /**
- * Executes the create request.
- *
- * @param context The context to associate with this operation.
- * @return the created resource.
- */
- SuppressionListAddressResource create(Context context);
- }
-
- /**
- * The stage of the SuppressionListAddressResource definition allowing to specify email.
- */
- interface WithEmail {
- /**
- * Specifies the email property: Email address of the recipient..
- *
- * @param email Email address of the recipient.
- * @return the next definition stage.
- */
- WithCreate withEmail(String email);
- }
-
- /**
- * The stage of the SuppressionListAddressResource definition allowing to specify firstName.
- */
- interface WithFirstName {
- /**
- * Specifies the firstName property: The first name of the email recipient..
- *
- * @param firstName The first name of the email recipient.
- * @return the next definition stage.
- */
- WithCreate withFirstName(String firstName);
- }
-
- /**
- * The stage of the SuppressionListAddressResource definition allowing to specify lastName.
- */
- interface WithLastName {
- /**
- * Specifies the lastName property: The last name of the email recipient..
- *
- * @param lastName The last name of the email recipient.
- * @return the next definition stage.
- */
- WithCreate withLastName(String lastName);
- }
-
- /**
- * The stage of the SuppressionListAddressResource definition allowing to specify notes.
- */
- interface WithNotes {
- /**
- * Specifies the notes property: An optional property to provide contextual notes or a description for an
- * address..
- *
- * @param notes An optional property to provide contextual notes or a description for an address.
- * @return the next definition stage.
- */
- WithCreate withNotes(String notes);
- }
- }
-
- /**
- * Begins update for the SuppressionListAddressResource resource.
- *
- * @return the stage of resource update.
- */
- SuppressionListAddressResource.Update update();
-
- /**
- * The template for SuppressionListAddressResource update.
- */
- interface Update
- extends UpdateStages.WithEmail, UpdateStages.WithFirstName, UpdateStages.WithLastName, UpdateStages.WithNotes {
- /**
- * Executes the update request.
- *
- * @return the updated resource.
- */
- SuppressionListAddressResource apply();
-
- /**
- * Executes the update request.
- *
- * @param context The context to associate with this operation.
- * @return the updated resource.
- */
- SuppressionListAddressResource apply(Context context);
- }
-
- /**
- * The SuppressionListAddressResource update stages.
- */
- interface UpdateStages {
- /**
- * The stage of the SuppressionListAddressResource update allowing to specify email.
- */
- interface WithEmail {
- /**
- * Specifies the email property: Email address of the recipient..
- *
- * @param email Email address of the recipient.
- * @return the next definition stage.
- */
- Update withEmail(String email);
- }
-
- /**
- * The stage of the SuppressionListAddressResource update allowing to specify firstName.
- */
- interface WithFirstName {
- /**
- * Specifies the firstName property: The first name of the email recipient..
- *
- * @param firstName The first name of the email recipient.
- * @return the next definition stage.
- */
- Update withFirstName(String firstName);
- }
-
- /**
- * The stage of the SuppressionListAddressResource update allowing to specify lastName.
- */
- interface WithLastName {
- /**
- * Specifies the lastName property: The last name of the email recipient..
- *
- * @param lastName The last name of the email recipient.
- * @return the next definition stage.
- */
- Update withLastName(String lastName);
- }
-
- /**
- * The stage of the SuppressionListAddressResource update allowing to specify notes.
- */
- interface WithNotes {
- /**
- * Specifies the notes property: An optional property to provide contextual notes or a description for an
- * address..
- *
- * @param notes An optional property to provide contextual notes or a description for an address.
- * @return the next definition stage.
- */
- Update withNotes(String notes);
- }
- }
-
- /**
- * Refreshes the resource to sync with Azure.
- *
- * @return the refreshed resource.
- */
- SuppressionListAddressResource refresh();
-
- /**
- * Refreshes the resource to sync with Azure.
- *
- * @param context The context to associate with this operation.
- * @return the refreshed resource.
- */
- SuppressionListAddressResource refresh(Context context);
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddressResourceCollection.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddressResourceCollection.java
deleted file mode 100644
index 11d67128edf82..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddressResourceCollection.java
+++ /dev/null
@@ -1,85 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
-
-/**
- * Collection of addresses in a suppression list. Response will include a nextLink if response contains more pages.
- */
-@Fluent
-public final class SuppressionListAddressResourceCollection {
- /*
- * List of suppressed email addresses.
- */
- @JsonProperty(value = "value")
- private List value;
-
- /*
- * The URL the client should use to fetch the next page (per server side paging).
- */
- @JsonProperty(value = "nextLink")
- private String nextLink;
-
- /**
- * Creates an instance of SuppressionListAddressResourceCollection class.
- */
- public SuppressionListAddressResourceCollection() {
- }
-
- /**
- * Get the value property: List of suppressed email addresses.
- *
- * @return the value value.
- */
- public List value() {
- return this.value;
- }
-
- /**
- * Set the value property: List of suppressed email addresses.
- *
- * @param value the value value to set.
- * @return the SuppressionListAddressResourceCollection object itself.
- */
- public SuppressionListAddressResourceCollection withValue(List value) {
- this.value = value;
- return this;
- }
-
- /**
- * Get the nextLink property: The URL the client should use to fetch the next page (per server side paging).
- *
- * @return the nextLink value.
- */
- public String nextLink() {
- return this.nextLink;
- }
-
- /**
- * Set the nextLink property: The URL the client should use to fetch the next page (per server side paging).
- *
- * @param nextLink the nextLink value to set.
- * @return the SuppressionListAddressResourceCollection object itself.
- */
- public SuppressionListAddressResourceCollection withNextLink(String nextLink) {
- this.nextLink = nextLink;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (value() != null) {
- value().forEach(e -> e.validate());
- }
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddresses.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddresses.java
deleted file mode 100644
index 141fa327d1f0a..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListAddresses.java
+++ /dev/null
@@ -1,183 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.models;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-
-/**
- * Resource collection API of SuppressionListAddresses.
- */
-public interface SuppressionListAddresses {
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedIterable}.
- */
- PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName);
-
- /**
- * Get
- *
- * Get all the addresses in a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the addresses in a suppression list as paginated response with {@link PagedIterable}.
- */
- PagedIterable list(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress along with {@link Response}.
- */
- Response getWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, String addressId, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress.
- */
- SuppressionListAddressResource get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId);
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, String addressId, Context context);
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param addressId The id of the address in a suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- void delete(String resourceGroupName, String emailServiceName, String domainName, String suppressionListName,
- String addressId);
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param id the resource ID.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress along with {@link Response}.
- */
- SuppressionListAddressResource getById(String id);
-
- /**
- * Get
- *
- * Get a SuppressionListAddress.
- *
- * @param id the resource ID.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionListAddress along with {@link Response}.
- */
- Response getByIdWithResponse(String id, Context context);
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param id the resource ID.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- void deleteById(String id);
-
- /**
- * Delete
- *
- * Operation to delete a single address from a suppression list.
- *
- * @param id the resource ID.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- Response deleteByIdWithResponse(String id, Context context);
-
- /**
- * Begins definition for a new SuppressionListAddressResource resource.
- *
- * @param name resource name.
- * @return the first stage of the new SuppressionListAddressResource definition.
- */
- SuppressionListAddressResource.DefinitionStages.Blank define(String name);
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListResource.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListResource.java
deleted file mode 100644
index 9bc0a9e516374..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListResource.java
+++ /dev/null
@@ -1,217 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.models;
-
-import com.azure.core.management.SystemData;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-
-/**
- * An immutable client-side representation of SuppressionListResource.
- */
-public interface SuppressionListResource {
- /**
- * Gets the id property: Fully qualified resource Id for the resource.
- *
- * @return the id value.
- */
- String id();
-
- /**
- * Gets the name property: The name of the resource.
- *
- * @return the name value.
- */
- String name();
-
- /**
- * Gets the type property: The type of the resource.
- *
- * @return the type value.
- */
- String type();
-
- /**
- * Gets the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- SystemData systemData();
-
- /**
- * Gets the listName property: The the name of the suppression list. This value must match one of the valid sender
- * usernames of the sending domain.
- *
- * @return the listName value.
- */
- String listName();
-
- /**
- * Gets the lastUpdatedTimestamp property: The date the resource was last updated.
- *
- * @return the lastUpdatedTimestamp value.
- */
- String lastUpdatedTimestamp();
-
- /**
- * Gets the createdTimestamp property: The date the resource was created.
- *
- * @return the createdTimestamp value.
- */
- String createdTimestamp();
-
- /**
- * Gets the dataLocation property: The location where the SuppressionListAddress data is stored at rest. This value
- * is inherited from the parent Domains resource.
- *
- * @return the dataLocation value.
- */
- String dataLocation();
-
- /**
- * Gets the name of the resource group.
- *
- * @return the name of the resource group.
- */
- String resourceGroupName();
-
- /**
- * Gets the inner com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner object.
- *
- * @return the inner object.
- */
- SuppressionListResourceInner innerModel();
-
- /**
- * The entirety of the SuppressionListResource definition.
- */
- interface Definition
- extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate {
- }
-
- /**
- * The SuppressionListResource definition stages.
- */
- interface DefinitionStages {
- /**
- * The first stage of the SuppressionListResource definition.
- */
- interface Blank extends WithParentResource {
- }
-
- /**
- * The stage of the SuppressionListResource definition allowing to specify parent resource.
- */
- interface WithParentResource {
- /**
- * Specifies resourceGroupName, emailServiceName, domainName.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @return the next definition stage.
- */
- WithCreate withExistingDomain(String resourceGroupName, String emailServiceName, String domainName);
- }
-
- /**
- * The stage of the SuppressionListResource definition which contains all the minimum required properties for
- * the resource to be created, but also allows for any other optional properties to be specified.
- */
- interface WithCreate extends DefinitionStages.WithListName {
- /**
- * Executes the create request.
- *
- * @return the created resource.
- */
- SuppressionListResource create();
-
- /**
- * Executes the create request.
- *
- * @param context The context to associate with this operation.
- * @return the created resource.
- */
- SuppressionListResource create(Context context);
- }
-
- /**
- * The stage of the SuppressionListResource definition allowing to specify listName.
- */
- interface WithListName {
- /**
- * Specifies the listName property: The the name of the suppression list. This value must match one of the
- * valid sender usernames of the sending domain..
- *
- * @param listName The the name of the suppression list. This value must match one of the valid sender
- * usernames of the sending domain.
- * @return the next definition stage.
- */
- WithCreate withListName(String listName);
- }
- }
-
- /**
- * Begins update for the SuppressionListResource resource.
- *
- * @return the stage of resource update.
- */
- SuppressionListResource.Update update();
-
- /**
- * The template for SuppressionListResource update.
- */
- interface Update extends UpdateStages.WithListName {
- /**
- * Executes the update request.
- *
- * @return the updated resource.
- */
- SuppressionListResource apply();
-
- /**
- * Executes the update request.
- *
- * @param context The context to associate with this operation.
- * @return the updated resource.
- */
- SuppressionListResource apply(Context context);
- }
-
- /**
- * The SuppressionListResource update stages.
- */
- interface UpdateStages {
- /**
- * The stage of the SuppressionListResource update allowing to specify listName.
- */
- interface WithListName {
- /**
- * Specifies the listName property: The the name of the suppression list. This value must match one of the
- * valid sender usernames of the sending domain..
- *
- * @param listName The the name of the suppression list. This value must match one of the valid sender
- * usernames of the sending domain.
- * @return the next definition stage.
- */
- Update withListName(String listName);
- }
- }
-
- /**
- * Refreshes the resource to sync with Azure.
- *
- * @return the refreshed resource.
- */
- SuppressionListResource refresh();
-
- /**
- * Refreshes the resource to sync with Azure.
- *
- * @param context The context to associate with this operation.
- * @return the refreshed resource.
- */
- SuppressionListResource refresh(Context context);
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListResourceCollection.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListResourceCollection.java
deleted file mode 100644
index 4d53a64e2ee4c..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionListResourceCollection.java
+++ /dev/null
@@ -1,85 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
-
-/**
- * A class representing a Domains SuppressionListResource collection.
- */
-@Fluent
-public final class SuppressionListResourceCollection {
- /*
- * List of SuppressionListResource
- */
- @JsonProperty(value = "value")
- private List value;
-
- /*
- * The URL the client should use to fetch the next page (per server side paging).
- */
- @JsonProperty(value = "nextLink")
- private String nextLink;
-
- /**
- * Creates an instance of SuppressionListResourceCollection class.
- */
- public SuppressionListResourceCollection() {
- }
-
- /**
- * Get the value property: List of SuppressionListResource.
- *
- * @return the value value.
- */
- public List value() {
- return this.value;
- }
-
- /**
- * Set the value property: List of SuppressionListResource.
- *
- * @param value the value value to set.
- * @return the SuppressionListResourceCollection object itself.
- */
- public SuppressionListResourceCollection withValue(List value) {
- this.value = value;
- return this;
- }
-
- /**
- * Get the nextLink property: The URL the client should use to fetch the next page (per server side paging).
- *
- * @return the nextLink value.
- */
- public String nextLink() {
- return this.nextLink;
- }
-
- /**
- * Set the nextLink property: The URL the client should use to fetch the next page (per server side paging).
- *
- * @param nextLink the nextLink value to set.
- * @return the SuppressionListResourceCollection object itself.
- */
- public SuppressionListResourceCollection withNextLink(String nextLink) {
- this.nextLink = nextLink;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (value() != null) {
- value().forEach(e -> e.validate());
- }
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionLists.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionLists.java
deleted file mode 100644
index bf22eb6235c95..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/com/azure/resourcemanager/communication/models/SuppressionLists.java
+++ /dev/null
@@ -1,178 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.models;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-
-/**
- * Resource collection API of SuppressionLists.
- */
-public interface SuppressionLists {
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedIterable}.
- */
- PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName);
-
- /**
- * List
- *
- * List all suppression lists for a domains resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a class representing a Domains SuppressionListResource collection as paginated response with
- * {@link PagedIterable}.
- */
- PagedIterable listByDomain(String resourceGroupName, String emailServiceName,
- String domainName, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource along with {@link Response}.
- */
- Response getWithResponse(String resourceGroupName, String emailServiceName,
- String domainName, String suppressionListName, Context context);
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource.
- */
- SuppressionListResource get(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName);
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- Response deleteWithResponse(String resourceGroupName, String emailServiceName, String domainName,
- String suppressionListName, Context context);
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param emailServiceName The name of the EmailService resource.
- * @param domainName The name of the Domains resource.
- * @param suppressionListName The name of the suppression list.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- void delete(String resourceGroupName, String emailServiceName, String domainName, String suppressionListName);
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param id the resource ID.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource along with {@link Response}.
- */
- SuppressionListResource getById(String id);
-
- /**
- * Get
- *
- * Get a SuppressionList resource.
- *
- * @param id the resource ID.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return a SuppressionList resource along with {@link Response}.
- */
- Response getByIdWithResponse(String id, Context context);
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param id the resource ID.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- void deleteById(String id);
-
- /**
- * Delete
- *
- * Delete a SuppressionList.
- *
- * @param id the resource ID.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- Response deleteByIdWithResponse(String id, Context context);
-
- /**
- * Begins definition for a new SuppressionListResource resource.
- *
- * @param name resource name.
- * @return the first stage of the new SuppressionListResource definition.
- */
- SuppressionListResource.DefinitionStages.Blank define(String name);
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/java/module-info.java b/sdk/communication/azure-resourcemanager-communication/src/main/java/module-info.java
index 742f4c0af53a3..1a22b6345135e 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/java/module-info.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/java/module-info.java
@@ -4,12 +4,10 @@
module com.azure.resourcemanager.communication {
requires transitive com.azure.core.management;
-
exports com.azure.resourcemanager.communication;
exports com.azure.resourcemanager.communication.fluent;
exports com.azure.resourcemanager.communication.fluent.models;
exports com.azure.resourcemanager.communication.models;
-
opens com.azure.resourcemanager.communication.fluent.models to com.azure.core, com.fasterxml.jackson.databind;
opens com.azure.resourcemanager.communication.models to com.azure.core, com.fasterxml.jackson.databind;
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/proxy-config.json b/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/proxy-config.json
index ad2ec93356c5e..066a7deb03188 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/proxy-config.json
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/proxy-config.json
@@ -1 +1 @@
-[ [ "com.azure.resourcemanager.communication.implementation.OperationsClientImpl$OperationsService" ], [ "com.azure.resourcemanager.communication.implementation.CommunicationServicesClientImpl$CommunicationServicesService" ], [ "com.azure.resourcemanager.communication.implementation.DomainsClientImpl$DomainsService" ], [ "com.azure.resourcemanager.communication.implementation.EmailServicesClientImpl$EmailServicesService" ], [ "com.azure.resourcemanager.communication.implementation.SenderUsernamesClientImpl$SenderUsernamesService" ], [ "com.azure.resourcemanager.communication.implementation.SuppressionListsClientImpl$SuppressionListsService" ], [ "com.azure.resourcemanager.communication.implementation.SuppressionListAddressesClientImpl$SuppressionListAddressesService" ] ]
\ No newline at end of file
+[ [ "com.azure.resourcemanager.communication.implementation.OperationsClientImpl$OperationsService" ], [ "com.azure.resourcemanager.communication.implementation.CommunicationServicesClientImpl$CommunicationServicesService" ], [ "com.azure.resourcemanager.communication.implementation.DomainsClientImpl$DomainsService" ], [ "com.azure.resourcemanager.communication.implementation.EmailServicesClientImpl$EmailServicesService" ], [ "com.azure.resourcemanager.communication.implementation.SenderUsernamesClientImpl$SenderUsernamesService" ] ]
\ No newline at end of file
diff --git a/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/reflect-config.json b/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/reflect-config.json
index ed4dd8c577598..13883cefcfb4e 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/reflect-config.json
+++ b/sdk/communication/azure-resourcemanager-communication/src/main/resources/META-INF/native-image/com.azure.resourcemanager/azure-resourcemanager-communication/reflect-config.json
@@ -173,36 +173,6 @@
"allDeclaredConstructors" : true,
"allDeclaredFields" : true,
"allDeclaredMethods" : true
-}, {
- "name" : "com.azure.resourcemanager.communication.models.SuppressionListResourceCollection",
- "allDeclaredConstructors" : true,
- "allDeclaredFields" : true,
- "allDeclaredMethods" : true
-}, {
- "name" : "com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner",
- "allDeclaredConstructors" : true,
- "allDeclaredFields" : true,
- "allDeclaredMethods" : true
-}, {
- "name" : "com.azure.resourcemanager.communication.fluent.models.SuppressionListProperties",
- "allDeclaredConstructors" : true,
- "allDeclaredFields" : true,
- "allDeclaredMethods" : true
-}, {
- "name" : "com.azure.resourcemanager.communication.models.SuppressionListAddressResourceCollection",
- "allDeclaredConstructors" : true,
- "allDeclaredFields" : true,
- "allDeclaredMethods" : true
-}, {
- "name" : "com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner",
- "allDeclaredConstructors" : true,
- "allDeclaredFields" : true,
- "allDeclaredMethods" : true
-}, {
- "name" : "com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressProperties",
- "allDeclaredConstructors" : true,
- "allDeclaredFields" : true,
- "allDeclaredMethods" : true
}, {
"name" : "com.azure.resourcemanager.communication.models.Origin",
"allDeclaredConstructors" : true,
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilitySamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilitySamples.java
index d54724fd2359f..7b5b100a733d2 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilitySamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilitySamples.java
@@ -12,7 +12,7 @@
public final class CommunicationServicesCheckNameAvailabilitySamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/checkNameAvailabilityAvailable.json
*/
/**
@@ -29,7 +29,7 @@ public final class CommunicationServicesCheckNameAvailabilitySamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/checkNameAvailabilityUnavailable.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateSamples.java
index a02af9e01f85e..c0ef8e0533ea1 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateSamples.java
@@ -13,7 +13,7 @@
public final class CommunicationServicesCreateOrUpdateSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/createOrUpdate.json
*/
/**
@@ -28,7 +28,7 @@ public static void createOrUpdateResource(com.azure.resourcemanager.communicatio
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/createOrUpdateWithSystemAssignedIdentity.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteSamples.java
index db6ec059486be..51f7e71f26f92 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteSamples.java
@@ -10,7 +10,7 @@
public final class CommunicationServicesDeleteSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/delete.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupSamples.java
index 3884c8f5867be..ddb5c746d0843 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupSamples.java
@@ -10,7 +10,7 @@
public final class CommunicationServicesGetByResourceGroupSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/get.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubSamples.java
index 1300edb3e443c..1a344e25ec799 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubSamples.java
@@ -12,7 +12,7 @@
public final class CommunicationServicesLinkNotificationHubSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/linkNotificationHub.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupSamples.java
index e8a216aeaec00..341fcfbc849c6 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupSamples.java
@@ -10,7 +10,7 @@
public final class CommunicationServicesListByResourceGroupSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/listByResourceGroup.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListKeysSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListKeysSamples.java
index 8b9b24691e83d..5be88879ee4bd 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListKeysSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListKeysSamples.java
@@ -10,7 +10,7 @@
public final class CommunicationServicesListKeysSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/listKeys.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListSamples.java
index 0a1555164427f..bd0f4147bed32 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListSamples.java
@@ -10,7 +10,7 @@
public final class CommunicationServicesListSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/listBySubscription.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesRegenerateKeySamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesRegenerateKeySamples.java
index e9f08b5530c62..fe9a09952eaa0 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesRegenerateKeySamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesRegenerateKeySamples.java
@@ -13,7 +13,7 @@
public final class CommunicationServicesRegenerateKeySamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/regenerateKey.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesUpdateSamples.java
index 2f2cb03e74bb6..d7bedd5b90e89 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesUpdateSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/CommunicationServicesUpdateSamples.java
@@ -17,7 +17,7 @@
public final class CommunicationServicesUpdateSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/update.json
*/
/**
@@ -29,13 +29,12 @@ public static void updateResource(com.azure.resourcemanager.communication.Commun
CommunicationServiceResource resource
= manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup",
"MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
- resource.update().withTags(mapOf("newTag", "newVal"))
- .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED)).apply();
+ resource.update().withTags(mapOf("newTag", "newVal")).apply();
}
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/updateWithUserAssignedIdentity.json
*/
/**
@@ -56,7 +55,7 @@ public static void updateResourceToAddAUserAssignedManagedIdentity(
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/updateWithSystemAssignedIdentity.json
*/
/**
@@ -75,7 +74,7 @@ public static void updateResourceToAddASystemAssignedManagedIdentity(
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/updateRemoveSystemIdentity.json
*/
/**
@@ -88,12 +87,13 @@ public static void updateResourceToAddASystemAssignedManagedIdentity(
CommunicationServiceResource resource
= manager.communicationServices().getByResourceGroupWithResponse("MyResourceGroup",
"MyCommunicationResource", com.azure.core.util.Context.NONE).getValue();
- resource.update().withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.NONE)).apply();
+ resource.update().withTags(mapOf("newTag", "newVal"))
+ .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.NONE)).apply();
}
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/updateWithSystemAndUserIdentity.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCancelVerificationSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCancelVerificationSamples.java
index 9f6133a52b278..5174fb25105bf 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCancelVerificationSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCancelVerificationSamples.java
@@ -13,7 +13,7 @@
public final class DomainsCancelVerificationSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
* cancelVerification.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCreateOrUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCreateOrUpdateSamples.java
index f19f411171796..4ed0aa6e3bf92 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCreateOrUpdateSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsCreateOrUpdateSamples.java
@@ -12,7 +12,7 @@
public final class DomainsCreateOrUpdateSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
* createOrUpdate.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsDeleteSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsDeleteSamples.java
index 21b285508e546..e24f594cc2c51 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsDeleteSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsDeleteSamples.java
@@ -10,8 +10,8 @@
public final class DomainsDeleteSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/
- * delete.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/delete.
+ * json
*/
/**
* Sample code: Delete Domains resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsGetSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsGetSamples.java
index 1efcf0811bbb4..0cdc1b87862c5 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsGetSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsGetSamples.java
@@ -10,8 +10,7 @@
public final class DomainsGetSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/
- * get.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/get.json
*/
/**
* Sample code: Get Domains resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsInitiateVerificationSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsInitiateVerificationSamples.java
index 88f7b5f42a9c4..88c3b133e4795 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsInitiateVerificationSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsInitiateVerificationSamples.java
@@ -13,7 +13,7 @@
public final class DomainsInitiateVerificationSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
* initiateVerification.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsListByEmailServiceResourceSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsListByEmailServiceResourceSamples.java
index dd2d048387531..f13500d4c989e 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsListByEmailServiceResourceSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsListByEmailServiceResourceSamples.java
@@ -10,7 +10,7 @@
public final class DomainsListByEmailServiceResourceSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/
* listByEmailService.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsUpdateSamples.java
index eeeea15474df6..ae5a64899dcdf 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsUpdateSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/DomainsUpdateSamples.java
@@ -13,8 +13,8 @@
public final class DomainsUpdateSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/domains/
- * update.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/domains/update.
+ * json
*/
/**
* Sample code: Update Domains resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateSamples.java
index c4d1f6742264f..61f8ceba24424 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateSamples.java
@@ -10,8 +10,8 @@
public final class EmailServicesCreateOrUpdateSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * emailServices/createOrUpdate.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * createOrUpdate.json
*/
/**
* Sample code: Create or update EmailService resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteSamples.java
index 602adbc1af537..f2f87f8196bf8 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteSamples.java
@@ -10,8 +10,8 @@
public final class EmailServicesDeleteSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * emailServices/delete.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * delete.json
*/
/**
* Sample code: Delete EmailService resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupSamples.java
index e57d7b4382898..7f5f09eaefc0f 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupSamples.java
@@ -10,8 +10,8 @@
public final class EmailServicesGetByResourceGroupSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * emailServices/get.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/get
+ * .json
*/
/**
* Sample code: Get EmailService resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupSamples.java
index c25238a605dd4..71e848533b301 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupSamples.java
@@ -10,8 +10,8 @@
public final class EmailServicesListByResourceGroupSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * emailServices/listByResourceGroup.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * listByResourceGroup.json
*/
/**
* Sample code: List EmailService resources by resource group.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListSamples.java
index 97083f6bbff25..6c08aae8b9bf1 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListSamples.java
@@ -10,8 +10,8 @@
public final class EmailServicesListSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * emailServices/listBySubscription.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * listBySubscription.json
*/
/**
* Sample code: List EmailService resources by subscription.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsSamples.java
index 9e6daaa3471fc..577b34d64a73f 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsSamples.java
@@ -10,8 +10,8 @@
public final class EmailServicesListVerifiedExchangeOnlineDomainsSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * emailServices/getVerifiedExchangeOnlineDomains.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * getVerifiedExchangeOnlineDomains.json
*/
/**
* Sample code: Get verified Exchange Online domains.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesUpdateSamples.java
index 9d29d469a5a1b..6234c0f31ba8a 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesUpdateSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/EmailServicesUpdateSamples.java
@@ -14,8 +14,8 @@
public final class EmailServicesUpdateSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * emailServices/update.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/emailServices/
+ * update.json
*/
/**
* Sample code: Update EmailService resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/OperationsListSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/OperationsListSamples.java
index 584f921d1d06e..4585b92af1729 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/OperationsListSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/OperationsListSamples.java
@@ -10,7 +10,7 @@
public final class OperationsListSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/
* communicationServices/operationsList.json
*/
/**
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateSamples.java
index 42bbf7c995f17..39a1a9e47691d 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateSamples.java
@@ -10,8 +10,8 @@
public final class SenderUsernamesCreateOrUpdateSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * senderUsernames/createOrUpdate.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * createOrUpdate.json
*/
/**
* Sample code: Create or update SenderUsernames resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteSamples.java
index 6329d8aca9656..dafdb1813a6f0 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteSamples.java
@@ -10,8 +10,8 @@
public final class SenderUsernamesDeleteSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * senderUsernames/delete.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * delete.json
*/
/**
* Sample code: Delete SenderUsernames resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetSamples.java
index 971245520e655..640700a845d2b 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetSamples.java
@@ -10,8 +10,8 @@
public final class SenderUsernamesGetSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * senderUsernames/get.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * get.json
*/
/**
* Sample code: Get SenderUsernames resource.
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsSamples.java
index 0f3e21f7f8d94..2b5e206b125f8 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsSamples.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsSamples.java
@@ -10,16 +10,16 @@
public final class SenderUsernamesListByDomainsSamples {
/*
* x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * senderUsernames/listByDomain.json
+ * specification/communication/resource-manager/Microsoft.Communication/stable/2023-04-01/examples/senderUsernames/
+ * listByDomain.json
*/
/**
- * Sample code: Get all SenderUsernames resources for a Domain.
+ * Sample code: Get SenderUsernames resource.
*
* @param manager Entry point to CommunicationManager.
*/
public static void
- getAllSenderUsernamesResourcesForADomain(com.azure.resourcemanager.communication.CommunicationManager manager) {
+ getSenderUsernamesResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
manager.senderUsernames().listByDomains("contosoResourceGroup", "contosoEmailService", "contoso.com",
com.azure.core.util.Context.NONE);
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesCreateOrUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesCreateOrUpdateSamples.java
deleted file mode 100644
index 3c80491ed8756..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesCreateOrUpdateSamples.java
+++ /dev/null
@@ -1,28 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionListAddresses CreateOrUpdate.
- */
-public final class SuppressionListAddressesCreateOrUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/createOrUpdateAddress.json
- */
- /**
- * Sample code: CreateOrUpdate SuppressionListAddress resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void createOrUpdateSuppressionListAddressResource(
- com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().define("11112222-3333-4444-5555-aaaabbbbcccc")
- .withExistingSuppressionList("contosoResourceGroup", "contosoEmailService", "contoso.com",
- "aaaa1111-bbbb-2222-3333-aaaa11112222")
- .withEmail("newuser1@fabrikam.com").withFirstName("updatedFirstName").create();
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesDeleteSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesDeleteSamples.java
deleted file mode 100644
index 866a99a1b2f20..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesDeleteSamples.java
+++ /dev/null
@@ -1,27 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionListAddresses Delete.
- */
-public final class SuppressionListAddressesDeleteSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/deleteAddress.json
- */
- /**
- * Sample code: Delete a SuppressionListAddress resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void
- deleteASuppressionListAddressResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().deleteWithResponse("MyResourceGroup", "MyEmailServiceResource",
- "mydomain.com", "aaaa1111-bbbb-2222-3333-aaaa11112222", "11112222-3333-4444-5555-999999999999",
- com.azure.core.util.Context.NONE);
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesGetSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesGetSamples.java
deleted file mode 100644
index 373c99924bec9..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesGetSamples.java
+++ /dev/null
@@ -1,27 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionListAddresses Get.
- */
-public final class SuppressionListAddressesGetSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/getAddress.json
- */
- /**
- * Sample code: Get a SuppressionListAddress resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void
- getASuppressionListAddressResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().getWithResponse("contosoResourceGroup", "contosoEmailService", "contoso.com",
- "aaaa1111-bbbb-2222-3333-aaaa11112222", "11112222-3333-4444-5555-aaaabbbbcccc",
- com.azure.core.util.Context.NONE);
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesListSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesListSamples.java
deleted file mode 100644
index 32fb10618f993..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesListSamples.java
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionListAddresses List.
- */
-public final class SuppressionListAddressesListSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/getAddresses.json
- */
- /**
- * Sample code: Get all SuppressionListAddresses resources for a SuppressionList resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void getAllSuppressionListAddressesResourcesForASuppressionListResource(
- com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionListAddresses().list("contosoResourceGroup", "contosoEmailService", "contoso.com",
- "aaaa1111-bbbb-2222-3333-aaaa11112222", com.azure.core.util.Context.NONE);
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsCreateOrUpdateSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsCreateOrUpdateSamples.java
deleted file mode 100644
index cec7541cbd0c3..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsCreateOrUpdateSamples.java
+++ /dev/null
@@ -1,27 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionLists CreateOrUpdate.
- */
-public final class SuppressionListsCreateOrUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/createOrUpdateSuppressionList.json
- */
- /**
- * Sample code: CreateOrUpdate SuppressionLists resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void
- createOrUpdateSuppressionListsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().define("aaaa1111-bbbb-2222-3333-aaaa11112222")
- .withExistingDomain("contosoResourceGroup", "contosoEmailService", "contoso.com")
- .withListName("contosoNewsAlerts").create();
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsDeleteSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsDeleteSamples.java
deleted file mode 100644
index e07609776f31b..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsDeleteSamples.java
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionLists Delete.
- */
-public final class SuppressionListsDeleteSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/deleteSuppressionList.json
- */
- /**
- * Sample code: Delete a SuppressionLists resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void
- deleteASuppressionListsResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().deleteWithResponse("MyResourceGroup", "MyEmailServiceResource", "mydomain.com",
- "aaaa1111-bbbb-2222-3333-aaaa11112222", com.azure.core.util.Context.NONE);
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsGetSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsGetSamples.java
deleted file mode 100644
index 28a2edb3079a8..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsGetSamples.java
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionLists Get.
- */
-public final class SuppressionListsGetSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/getSuppressionList.json
- */
- /**
- * Sample code: Get a SuppressionList resource.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void
- getASuppressionListResource(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().getWithResponse("contosoResourceGroup", "contosoEmailService", "contoso.com",
- "aaaa1111-bbbb-2222-3333-aaaa11112222", com.azure.core.util.Context.NONE);
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsListByDomainSamples.java b/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsListByDomainSamples.java
deleted file mode 100644
index 313c2d8a40aba..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/samples/java/com/azure/resourcemanager/communication/generated/SuppressionListsListByDomainSamples.java
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-/**
- * Samples for SuppressionLists ListByDomain.
- */
-public final class SuppressionListsListByDomainSamples {
- /*
- * x-ms-original-file:
- * specification/communication/resource-manager/Microsoft.Communication/preview/2023-06-01-preview/examples/
- * suppressionLists/getSuppressionLists.json
- */
- /**
- * Sample code: Get all SuppressionLists resources.
- *
- * @param manager Entry point to CommunicationManager.
- */
- public static void
- getAllSuppressionListsResources(com.azure.resourcemanager.communication.CommunicationManager manager) {
- manager.suppressionLists().listByDomain("contosoResourceGroup", "contosoEmailService", "contoso.com",
- com.azure.core.util.Context.NONE);
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceInnerTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceInnerTests.java
index 26ea6a96e533d..97a08b2778288 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceInnerTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceInnerTests.java
@@ -18,7 +18,7 @@ public final class CommunicationServiceResourceInnerTests {
@org.junit.jupiter.api.Test
public void testDeserialize() throws Exception {
CommunicationServiceResourceInner model = BinaryData.fromString(
- "{\"properties\":{\"provisioningState\":\"Updating\",\"hostName\":\"ljfmppee\",\"dataLocation\":\"vmgxsab\",\"notificationHubId\":\"qduujitcjczdz\",\"version\":\"ndhkrw\",\"immutableResourceId\":\"appd\",\"linkedDomains\":[\"kvwrwjfeu\",\"nhutjeltmrldhugj\",\"zdatqxhocdg\"]},\"identity\":{\"principalId\":\"3364eec9-ade1-40e9-a6b6-c1ebdbb90729\",\"tenantId\":\"4d6900be-a481-4fe4-8f6c-0f9ac88c28f4\",\"type\":\"UserAssigned\",\"userAssignedIdentities\":{\"icndvkaozwyifty\":{\"principalId\":\"3e6b52c5-3b05-4ff7-8a7a-68fa15023315\",\"clientId\":\"c61c00e7-4756-49b4-b899-415d17db5edf\"},\"urokft\":{\"principalId\":\"e977beae-b8a5-426d-9b27-894420e6ba02\",\"clientId\":\"5e81e17e-fe2c-4cf3-822a-3776dc7075d2\"},\"lniwpwcukjfkgiaw\":{\"principalId\":\"b0400f16-b86f-47bf-be2c-2902a6ecefc9\",\"clientId\":\"5c4ab0f5-66b3-4383-bdd3-221551430340\"}}},\"location\":\"lryplwckbasyy\",\"tags\":{\"phejkotynqgoulz\":\"dhsgcba\",\"gakeqsr\":\"dlikwyqkgfgibma\",\"qqedqytbciqfou\":\"yb\"},\"id\":\"lmmnkzsmodmglo\",\"name\":\"gpbkwtmut\",\"type\":\"uqktap\"}")
+ "{\"properties\":{\"provisioningState\":\"Updating\",\"hostName\":\"ljfmppee\",\"dataLocation\":\"vmgxsab\",\"notificationHubId\":\"qduujitcjczdz\",\"version\":\"ndhkrw\",\"immutableResourceId\":\"appd\",\"linkedDomains\":[\"kvwrwjfeu\",\"nhutjeltmrldhugj\",\"zdatqxhocdg\"]},\"identity\":{\"principalId\":\"3be39144-f5db-4d95-a423-901fe2c71743\",\"tenantId\":\"5eed8049-2baf-4291-8ae1-a28d5ca55c0f\",\"type\":\"UserAssigned\",\"userAssignedIdentities\":{\"icndvkaozwyifty\":{\"principalId\":\"2dba58c6-e1b7-48a0-8457-6f9eda4da645\",\"clientId\":\"39146c26-b00c-4f50-8261-625c41383ead\"},\"urokft\":{\"principalId\":\"2affca77-44bb-412b-923b-629c333f41b1\",\"clientId\":\"d9e394ab-bcf6-427f-8a26-28182ed95220\"},\"lniwpwcukjfkgiaw\":{\"principalId\":\"8680008c-30a6-4d01-8316-a3a6716c164d\",\"clientId\":\"19d70193-a0f9-41f3-ba3a-40df75ed6670\"}}},\"location\":\"lryplwckbasyy\",\"tags\":{\"phejkotynqgoulz\":\"dhsgcba\",\"gakeqsr\":\"dlikwyqkgfgibma\",\"qqedqytbciqfou\":\"yb\"},\"id\":\"lmmnkzsmodmglo\",\"name\":\"gpbkwtmut\",\"type\":\"uqktap\"}")
.toObject(CommunicationServiceResourceInner.class);
Assertions.assertEquals("lryplwckbasyy", model.location());
Assertions.assertEquals("dhsgcba", model.tags().get("phejkotynqgoulz"));
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceListTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceListTests.java
index b89d186effcfa..510c778a19b97 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceListTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceListTests.java
@@ -19,7 +19,7 @@ public final class CommunicationServiceResourceListTests {
@org.junit.jupiter.api.Test
public void testDeserialize() throws Exception {
CommunicationServiceResourceList model = BinaryData.fromString(
- "{\"value\":[{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"mkkvnip\",\"dataLocation\":\"oxzjnchgejspod\",\"notificationHubId\":\"ilzyd\",\"version\":\"o\",\"immutableResourceId\":\"yahux\",\"linkedDomains\":[\"mqnjaqw\",\"xj\"]},\"identity\":{\"principalId\":\"f23243a9-97a8-4db7-9630-79edf0f5ec5b\",\"tenantId\":\"8bda4b90-13fd-4b49-967f-939e714660f3\",\"type\":\"SystemAssigned,UserAssigned\",\"userAssignedIdentities\":{\"tegjvwmf\":{\"principalId\":\"918e4f18-5c32-48e7-b6fd-ffac2b2256f4\",\"clientId\":\"05fae119-b77b-4d17-8814-96e439c2fb82\"},\"scmdvpjhulsuu\":{\"principalId\":\"3a087802-ad98-4d9d-9f8f-6217eba9e6ce\",\"clientId\":\"a378160e-3ffa-4c66-88a3-403fabb2932b\"},\"jozkrwfndiod\":{\"principalId\":\"5e1a04a4-5740-460c-8ed5-423b2500ba73\",\"clientId\":\"b4b0ea7a-f230-4708-8133-960a22271c73\"},\"lwejdpv\":{\"principalId\":\"9ec2ade8-bd9d-4015-b062-94498fb8d4cb\",\"clientId\":\"f49d609a-4d01-4c6e-9317-3466b417bd76\"}}},\"location\":\"yoqpsoaccta\",\"tags\":{\"dfdosygexp\":\"ljlahbcryf\",\"dphlxaolt\":\"ojakhmsbzjhcrze\"},\"id\":\"qtrgqjbpfzfsinzg\",\"name\":\"f\",\"type\":\"jrwzox\"},{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"lluwfzitonpeq\",\"dataLocation\":\"pjkjlxofpdv\",\"notificationHubId\":\"fxxypininmayhuy\",\"version\":\"kpode\",\"immutableResourceId\":\"oginuvamiheognar\",\"linkedDomains\":[\"theotusiv\"]},\"identity\":{\"principalId\":\"ca5f15e1-4a32-4f3d-b695-af9387168a20\",\"tenantId\":\"e9113944-d7cd-4fa8-b7ea-9324f26b9eb5\",\"type\":\"UserAssigned\",\"userAssignedIdentities\":{\"nhungbw\":{\"principalId\":\"ae3f5fa4-ccd9-4efe-b9fb-5a87f0690c7e\",\"clientId\":\"a4717b06-5633-4bac-aa21-86fac88b45fc\"}}},\"location\":\"rnfygxgispem\",\"tags\":{\"fxqeof\":\"fkufublj\",\"jqul\":\"aeqjhqjbasvms\",\"clxxwrljdo\":\"gsntnbybkzgcwr\"},\"id\":\"skcqvkocrcjd\",\"name\":\"wtnhxbnjbiksqr\",\"type\":\"lssai\"}],\"nextLink\":\"p\"}")
+ "{\"value\":[{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"mkkvnip\",\"dataLocation\":\"oxzjnchgejspod\",\"notificationHubId\":\"ilzyd\",\"version\":\"o\",\"immutableResourceId\":\"yahux\",\"linkedDomains\":[\"mqnjaqw\",\"xj\"]},\"identity\":{\"principalId\":\"ef9eb9da-900a-4144-ad27-a9b0a76e515d\",\"tenantId\":\"ee78ee04-5488-49a6-b105-eaa8a59fd4b0\",\"type\":\"SystemAssigned,UserAssigned\",\"userAssignedIdentities\":{\"tegjvwmf\":{\"principalId\":\"86be38b7-b6b7-4b42-bd48-8be5806672da\",\"clientId\":\"b7b48f5e-f095-4c96-96a6-554206c17dd1\"},\"scmdvpjhulsuu\":{\"principalId\":\"b9807eea-7284-4e49-9b53-ca66d768d5cb\",\"clientId\":\"bdce0daa-ecdc-4e3a-8ffe-97c4b145c93a\"},\"jozkrwfndiod\":{\"principalId\":\"fd1ce9f2-ee54-4212-abbc-317e0597ecaf\",\"clientId\":\"82f841a7-6458-4ad9-9b7f-5ca541098843\"},\"lwejdpv\":{\"principalId\":\"09c23d8b-6df2-4ef9-a643-2e400db91f86\",\"clientId\":\"09585243-6cce-4b77-a7c8-021c95eb8e16\"}}},\"location\":\"yoqpsoaccta\",\"tags\":{\"dfdosygexp\":\"ljlahbcryf\",\"dphlxaolt\":\"ojakhmsbzjhcrze\"},\"id\":\"qtrgqjbpfzfsinzg\",\"name\":\"f\",\"type\":\"jrwzox\"},{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"lluwfzitonpeq\",\"dataLocation\":\"pjkjlxofpdv\",\"notificationHubId\":\"fxxypininmayhuy\",\"version\":\"kpode\",\"immutableResourceId\":\"oginuvamiheognar\",\"linkedDomains\":[\"theotusiv\"]},\"identity\":{\"principalId\":\"b384ea4b-2bc3-4f19-9d4a-c97ac5dfcda2\",\"tenantId\":\"3d8dba7a-3e4b-44cd-9473-650ba5b0d1cb\",\"type\":\"UserAssigned\",\"userAssignedIdentities\":{\"nhungbw\":{\"principalId\":\"ecf55d34-1c17-4213-8a5b-b05dcccdc962\",\"clientId\":\"b6ed71ad-2d97-4eec-b344-85f512a698be\"}}},\"location\":\"rnfygxgispem\",\"tags\":{\"fxqeof\":\"fkufublj\",\"jqul\":\"aeqjhqjbasvms\",\"clxxwrljdo\":\"gsntnbybkzgcwr\"},\"id\":\"skcqvkocrcjd\",\"name\":\"wtnhxbnjbiksqr\",\"type\":\"lssai\"}],\"nextLink\":\"p\"}")
.toObject(CommunicationServiceResourceList.class);
Assertions.assertEquals("yoqpsoaccta", model.value().get(0).location());
Assertions.assertEquals("ljlahbcryf", model.value().get(0).tags().get("dfdosygexp"));
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceUpdateTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceUpdateTests.java
index 1fc4a26486b36..8eb78e0926395 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceUpdateTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServiceResourceUpdateTests.java
@@ -18,7 +18,7 @@ public final class CommunicationServiceResourceUpdateTests {
@org.junit.jupiter.api.Test
public void testDeserialize() throws Exception {
CommunicationServiceResourceUpdate model = BinaryData.fromString(
- "{\"properties\":{\"linkedDomains\":[\"jvtbvpyss\",\"dnrujqguhmuouqfp\"]},\"identity\":{\"principalId\":\"51901feb-bc28-41a5-a7c6-f4eebc3d2566\",\"tenantId\":\"e97f6445-65e2-45aa-a746-a642218ffb13\",\"type\":\"SystemAssigned\",\"userAssignedIdentities\":{\"tnwu\":{\"principalId\":\"2b601cee-d688-4cc6-8cfc-aaa8f3e38af9\",\"clientId\":\"81a43ba3-be08-4adb-a815-cabb740eed27\"}}},\"tags\":{\"x\":\"a\",\"hr\":\"fizuckyf\"}}")
+ "{\"properties\":{\"linkedDomains\":[\"jvtbvpyss\",\"dnrujqguhmuouqfp\"]},\"identity\":{\"principalId\":\"6211b490-391f-4b88-a622-b29fa0524dee\",\"tenantId\":\"49124dfc-70a5-407e-941f-67e66e775255\",\"type\":\"SystemAssigned\",\"userAssignedIdentities\":{\"tnwu\":{\"principalId\":\"d34810c6-782e-42c1-9285-10f9e3568d49\",\"clientId\":\"5d70e04d-9075-4b18-8d87-b46281661276\"}}},\"tags\":{\"x\":\"a\",\"hr\":\"fizuckyf\"}}")
.toObject(CommunicationServiceResourceUpdate.class);
Assertions.assertEquals("a", model.tags().get("x"));
Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED, model.identity().type());
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilityWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilityWithResponseMockTests.java
index d5f349f8d14a2..99d2b86cd9aca 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilityWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCheckNameAvailabilityWithResponseMockTests.java
@@ -32,7 +32,7 @@ public void testCheckNameAvailabilityWithResponse() throws Exception {
HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
- String responseStr = "{\"nameAvailable\":true,\"reason\":\"AlreadyExists\",\"message\":\"lxotogtwrupq\"}";
+ String responseStr = "{\"nameAvailable\":false,\"reason\":\"Invalid\",\"message\":\"eyp\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -51,12 +51,12 @@ public void testCheckNameAvailabilityWithResponse() throws Exception {
CheckNameAvailabilityResponse response = manager.communicationServices()
.checkNameAvailabilityWithResponse(
- new NameAvailabilityParameters().withName("rdqmhjjdhtldwkyz").withType("utknc"),
+ new NameAvailabilityParameters().withName("xzko").withType("cukoklyaxuconu"),
com.azure.core.util.Context.NONE)
.getValue();
- Assertions.assertEquals(true, response.nameAvailable());
- Assertions.assertEquals(CheckNameAvailabilityReason.ALREADY_EXISTS, response.reason());
- Assertions.assertEquals("lxotogtwrupq", response.message());
+ Assertions.assertEquals(false, response.nameAvailable());
+ Assertions.assertEquals(CheckNameAvailabilityReason.INVALID, response.reason());
+ Assertions.assertEquals("eyp", response.message());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateMockTests.java
index 0710fe2fa3349..bceb5521724ba 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesCreateOrUpdateMockTests.java
@@ -37,7 +37,7 @@ public void testCreateOrUpdate() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"properties\":{\"provisioningState\":\"Succeeded\",\"hostName\":\"vwvxyslqbhsfx\",\"dataLocation\":\"blytk\",\"notificationHubId\":\"mpew\",\"version\":\"fbkrvrnsvs\",\"immutableResourceId\":\"johxcrsb\",\"linkedDomains\":[\"asrru\",\"wbhsqfsub\",\"gjb\"]},\"identity\":{\"principalId\":\"974e5b1a-902e-4a38-b9c0-f30b360899b1\",\"tenantId\":\"dea5e349-e51c-42d7-be6a-f3f0da212032\",\"type\":\"UserAssigned\",\"userAssignedIdentities\":{\"fbjfdtwssotftpvj\":{\"principalId\":\"3d583232-f6aa-4850-84e7-5f64daa54956\",\"clientId\":\"53e4bbc9-815a-4ac8-b954-cac4e7201cdb\"},\"xilzznf\":{\"principalId\":\"eac58f4a-2e55-476f-b158-d385f59cd9c2\",\"clientId\":\"5557c7dc-b550-4e11-87d7-2a0f7c9c3b4d\"}}},\"location\":\"nvwpmqtaruouj\",\"tags\":{\"ewgdrjervn\":\"jhwqytjrybnw\",\"eh\":\"enq\"},\"id\":\"ndoygmifthnzdnd\",\"name\":\"l\",\"type\":\"nayqi\"}";
+ = "{\"properties\":{\"provisioningState\":\"Succeeded\",\"hostName\":\"sfwxosowzxc\",\"dataLocation\":\"gicjooxdjeb\",\"notificationHubId\":\"ucww\",\"version\":\"ovbvmeueciv\",\"immutableResourceId\":\"zceuojgjrw\",\"linkedDomains\":[\"iotwmcdytdxwit\",\"nrjawgqwg\",\"hniskxfbkpyc\"]},\"identity\":{\"principalId\":\"81106beb-092d-40db-ba2b-4f7e526ae0c0\",\"tenantId\":\"80113ea7-1002-4294-a060-b9b71f05085d\",\"type\":\"SystemAssigned\",\"userAssignedIdentities\":{\"dauwhvylwzbtd\":{\"principalId\":\"fc83ff1f-459a-446d-be3a-41088cf5e029\",\"clientId\":\"a6ee0e13-1149-444f-8ca1-eafb2a27af50\"},\"jznb\":{\"principalId\":\"6212c5f4-7e5f-47cb-8702-39f5f15b8259\",\"clientId\":\"42a647a1-eccd-4289-9371-48ded81c8b76\"}}},\"location\":\"ow\",\"tags\":{\"lupj\":\"rzqlveu\",\"riplrbpbewtg\":\"khfxobbcswsrt\"},\"id\":\"fgb\",\"name\":\"c\",\"type\":\"wxzvlvqhjkb\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -54,20 +54,19 @@ public void testCreateOrUpdate() throws Exception {
tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
new AzureProfile("", "", AzureEnvironment.AZURE));
- CommunicationServiceResource response = manager.communicationServices().define("lhbnxkna")
- .withRegion("uaopppcqeq").withExistingResourceGroup("ixhnrztf")
- .withTags(mapOf("ahzxctobgbk", "z", "mgrcfbu", "moizpos", "mjh", "rmfqjhhkxbpvj", "tswb", "xjyngudivk"))
- .withIdentity(
- new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED)
- .withUserAssignedIdentities(mapOf("kteo", new UserAssignedIdentity(), "wptfdy",
- new UserAssignedIdentity(), "qbuaceopzfqr", new UserAssignedIdentity())))
- .withDataLocation("gdtpnapnyiro").withLinkedDomains(Arrays.asList("xgk")).create();
+ CommunicationServiceResource response
+ = manager.communicationServices().define("kfrlhrxsbky").withRegion("hcdhmdual")
+ .withExistingResourceGroup("bh").withTags(mapOf("adm", "qpv", "r", "sr", "fmisg", "vxpvgomz"))
+ .withIdentity(
+ new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED)
+ .withUserAssignedIdentities(mapOf("ahvljuaha", new UserAssignedIdentity())))
+ .withDataLocation("z").withLinkedDomains(Arrays.asList("eyvjusrtslhspkde", "maofmxagkv")).create();
- Assertions.assertEquals("nvwpmqtaruouj", response.location());
- Assertions.assertEquals("jhwqytjrybnw", response.tags().get("ewgdrjervn"));
- Assertions.assertEquals(ManagedServiceIdentityType.USER_ASSIGNED, response.identity().type());
- Assertions.assertEquals("blytk", response.dataLocation());
- Assertions.assertEquals("asrru", response.linkedDomains().get(0));
+ Assertions.assertEquals("ow", response.location());
+ Assertions.assertEquals("rzqlveu", response.tags().get("lupj"));
+ Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED, response.identity().type());
+ Assertions.assertEquals("gicjooxdjeb", response.dataLocation());
+ Assertions.assertEquals("iotwmcdytdxwit", response.linkedDomains().get(0));
}
// Use "Map.of" if available
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteMockTests.java
index 7f7ba762c1f00..9e29fe4973ccd 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesDeleteMockTests.java
@@ -45,7 +45,7 @@ public void testDelete() throws Exception {
tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
new AzureProfile("", "", AzureEnvironment.AZURE));
- manager.communicationServices().delete("oekqvk", "lns", com.azure.core.util.Context.NONE);
+ manager.communicationServices().delete("uscrpabgyepsb", "tazqugxywpmueefj", com.azure.core.util.Context.NONE);
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupWithResponseMockTests.java
index 7ff7a41783f5e..4ca0737f4029b 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesGetByResourceGroupWithResponseMockTests.java
@@ -32,7 +32,7 @@ public void testGetByResourceGroupWithResponse() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"properties\":{\"provisioningState\":\"Unknown\",\"hostName\":\"zvlvqhjkbegib\",\"dataLocation\":\"nmxiebwwaloayqc\",\"notificationHubId\":\"rtzju\",\"version\":\"wyzmhtxon\",\"immutableResourceId\":\"ts\",\"linkedDomains\":[\"cbpwxqpsrknft\",\"uvriuhprwm\",\"yvxqtayriwwroy\",\"bexrmcq\"]},\"identity\":{\"principalId\":\"0d7ca64b-8a60-40d3-b8a4-0fb239e8b065\",\"tenantId\":\"704faab2-1e7c-4462-83e3-6c11b6771823\",\"type\":\"UserAssigned\",\"userAssignedIdentities\":{\"nmefqsgzvahapj\":{\"principalId\":\"720a123b-41c3-43db-a217-e374a01ddf7b\",\"clientId\":\"db121949-3483-4c70-87bf-9e3eec546ade\"}}},\"location\":\"hpvgqz\",\"tags\":{\"zovawjvz\":\"vxdjzlmwlxkvugf\",\"nxipeil\":\"nluthnnp\",\"dzumveekg\":\"jzuaejxdultskzbb\"},\"id\":\"wozuhkf\",\"name\":\"bsjyofdx\",\"type\":\"uusdttouwa\"}";
+ = "{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"vmkfssxqu\",\"dataLocation\":\"kfplgmgsxnk\",\"notificationHubId\":\"kde\",\"version\":\"pvlopwiyighxpkd\",\"immutableResourceId\":\"baiuebbaumny\",\"linkedDomains\":[\"edeojnabc\"]},\"identity\":{\"principalId\":\"90fdda1a-2423-45b5-b479-d2875d87c96a\",\"tenantId\":\"90b43a81-6830-43c7-95fa-530d23bbd8e2\",\"type\":\"None\",\"userAssignedIdentities\":{\"ebtfhvpesap\":{\"principalId\":\"36b69f17-8df3-4d27-87c9-5b344e36ea49\",\"clientId\":\"a6beacf0-a8b3-42d5-b5e2-90c549cec587\"},\"dqmh\":{\"principalId\":\"639a2178-e33d-4939-8fa0-52a5a9c226aa\",\"clientId\":\"1944f363-64fc-450c-8df0-f000f6bca8df\"},\"htldwk\":{\"principalId\":\"94579b49-d73c-4fef-b4b8-87e7d6301a16\",\"clientId\":\"9af4da14-ac33-4e0a-877a-d9a295dc0d35\"}}},\"location\":\"xuutkncwscwsv\",\"tags\":{\"rupqsxvnmicy\":\"togt\",\"vei\":\"vce\",\"dhbt\":\"ovnotyfjfcnjbkcn\"},\"id\":\"kphywpnvjto\",\"name\":\"nermcl\",\"type\":\"plpho\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -50,12 +50,12 @@ public void testGetByResourceGroupWithResponse() throws Exception {
new AzureProfile("", "", AzureEnvironment.AZURE));
CommunicationServiceResource response = manager.communicationServices()
- .getByResourceGroupWithResponse("riplrbpbewtg", "fgb", com.azure.core.util.Context.NONE).getValue();
+ .getByResourceGroupWithResponse("ovplw", "bhvgy", com.azure.core.util.Context.NONE).getValue();
- Assertions.assertEquals("hpvgqz", response.location());
- Assertions.assertEquals("vxdjzlmwlxkvugf", response.tags().get("zovawjvz"));
- Assertions.assertEquals(ManagedServiceIdentityType.USER_ASSIGNED, response.identity().type());
- Assertions.assertEquals("nmxiebwwaloayqc", response.dataLocation());
- Assertions.assertEquals("cbpwxqpsrknft", response.linkedDomains().get(0));
+ Assertions.assertEquals("xuutkncwscwsv", response.location());
+ Assertions.assertEquals("togt", response.tags().get("rupqsxvnmicy"));
+ Assertions.assertEquals(ManagedServiceIdentityType.NONE, response.identity().type());
+ Assertions.assertEquals("kfplgmgsxnk", response.dataLocation());
+ Assertions.assertEquals("edeojnabc", response.linkedDomains().get(0));
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubWithResponseMockTests.java
index adeafecbf7e8a..ab9d87051b2da 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesLinkNotificationHubWithResponseMockTests.java
@@ -31,7 +31,7 @@ public void testLinkNotificationHubWithResponse() throws Exception {
HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
- String responseStr = "{\"resourceId\":\"phywpnvj\"}";
+ String responseStr = "{\"resourceId\":\"civfsnkymuctq\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -49,11 +49,11 @@ public void testLinkNotificationHubWithResponse() throws Exception {
new AzureProfile("", "", AzureEnvironment.AZURE));
LinkedNotificationHub response = manager.communicationServices()
- .linkNotificationHubWithResponse("xvnmicykvceov", "ilovnot",
- new LinkNotificationHubParameters().withResourceId("fj").withConnectionString("cnjbkcnxdhbt"),
+ .linkNotificationHubWithResponse("wrmjmwvvjektc", "senhwlrs",
+ new LinkNotificationHubParameters().withResourceId("frzpwvlqdqgb").withConnectionString("qylihkaetckt"),
com.azure.core.util.Context.NONE)
.getValue();
- Assertions.assertEquals("phywpnvj", response.resourceId());
+ Assertions.assertEquals("civfsnkymuctq", response.resourceId());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupMockTests.java
index 6f5617efde707..6f7856f58e7ba 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListByResourceGroupMockTests.java
@@ -33,7 +33,7 @@ public void testListByResourceGroup() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"value\":[{\"properties\":{\"provisioningState\":\"Succeeded\",\"hostName\":\"zlfmisgwbnbbeld\",\"dataLocation\":\"wkz\",\"notificationHubId\":\"liourqhak\",\"version\":\"hashsfwxosow\",\"immutableResourceId\":\"cugicjoox\",\"linkedDomains\":[\"bwpucwwfvovbv\",\"euecivyhzceuoj\",\"jrwjueiotwm\"]},\"identity\":{\"principalId\":\"2fd1e2fe-543c-45e1-a389-77c60fad415a\",\"tenantId\":\"dc909fc1-c659-4b48-9dac-d0d8e9bc696f\",\"type\":\"SystemAssigned\",\"userAssignedIdentities\":{\"xnrj\":{\"principalId\":\"289bdce0-818e-482d-bc4b-86ecee3e8a42\",\"clientId\":\"bc2b9b90-1c59-421f-a915-257be86f90c5\"}}},\"location\":\"gqwgxhniskxfbkp\",\"tags\":{\"l\":\"klwndnhjdauwhv\",\"xujznbmpowu\":\"zbtd\"},\"id\":\"przqlveu\",\"name\":\"lupj\",\"type\":\"khfxobbcswsrt\"}]}";
+ = "{\"value\":[{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"arbu\",\"dataLocation\":\"rcvpnazzmhjrunmp\",\"notificationHubId\":\"tdbhrbnla\",\"version\":\"xmyskp\",\"immutableResourceId\":\"enbtkcxywny\",\"linkedDomains\":[\"synlqidybyxczfc\"]},\"identity\":{\"principalId\":\"bf2be09a-79d1-4bfd-8556-fdcfa2f1c7d1\",\"tenantId\":\"7272b381-7584-43b2-9f5d-9987dbf5ed10\",\"type\":\"UserAssigned\",\"userAssignedIdentities\":{\"p\":{\"principalId\":\"41190edf-d46b-47c5-b956-6de1e0f169b6\",\"clientId\":\"f540ba33-a605-41e3-bb82-9635801f5ec5\"},\"rqlfktsthsucocmn\":{\"principalId\":\"2960e378-b58a-46d4-9647-3731440d096a\",\"clientId\":\"34d003dd-841b-4af2-ae4b-23dd8601e310\"},\"zt\":{\"principalId\":\"73f7f370-6377-4fa5-b684-b37feee8e273\",\"clientId\":\"4c7ff0ab-7003-4ee7-97b3-faef757a6879\"}}},\"location\":\"twwrqp\",\"tags\":{\"xibxujwbhqwalm\":\"ckzywbiexzfeyue\",\"ux\":\"zyoxaepdkzjan\",\"zt\":\"hdwbavxbniwdjs\"},\"id\":\"dbpgnxytxhp\",\"name\":\"xbzpfzab\",\"type\":\"lcuhxwtctyqiklb\"}]}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -51,13 +51,12 @@ public void testListByResourceGroup() throws Exception {
new AzureProfile("", "", AzureEnvironment.AZURE));
PagedIterable response
- = manager.communicationServices().listByResourceGroup("rcrgvx", com.azure.core.util.Context.NONE);
-
- Assertions.assertEquals("gqwgxhniskxfbkp", response.iterator().next().location());
- Assertions.assertEquals("klwndnhjdauwhv", response.iterator().next().tags().get("l"));
- Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED,
- response.iterator().next().identity().type());
- Assertions.assertEquals("wkz", response.iterator().next().dataLocation());
- Assertions.assertEquals("bwpucwwfvovbv", response.iterator().next().linkedDomains().get(0));
+ = manager.communicationServices().listByResourceGroup("buynhijggm", com.azure.core.util.Context.NONE);
+
+ Assertions.assertEquals("twwrqp", response.iterator().next().location());
+ Assertions.assertEquals("ckzywbiexzfeyue", response.iterator().next().tags().get("xibxujwbhqwalm"));
+ Assertions.assertEquals(ManagedServiceIdentityType.USER_ASSIGNED, response.iterator().next().identity().type());
+ Assertions.assertEquals("rcvpnazzmhjrunmp", response.iterator().next().dataLocation());
+ Assertions.assertEquals("synlqidybyxczfc", response.iterator().next().linkedDomains().get(0));
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListMockTests.java
index f3703c656b114..9460b6767a49d 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/CommunicationServicesListMockTests.java
@@ -33,7 +33,7 @@ public void testList() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"value\":[{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"rmclfplphoxu\",\"dataLocation\":\"crpab\",\"notificationHubId\":\"epsbjtazqu\",\"version\":\"ywpmueefjzwfqkq\",\"immutableResourceId\":\"ids\",\"linkedDomains\":[\"nobglaocq\",\"tcc\",\"g\"]},\"identity\":{\"principalId\":\"7003f4bf-93d3-453d-9de3-0be1a5e78250\",\"tenantId\":\"0d8d20d9-f552-447e-b412-91d468ba50ac\",\"type\":\"SystemAssigned,UserAssigned\",\"userAssignedIdentities\":{\"yrxvwfudwpznt\":{\"principalId\":\"f164af8c-2ede-4e44-82d8-78154418b5f0\",\"clientId\":\"6bf885ab-5a37-435a-b09a-88c9cc2fd899\"},\"zhlrqjb\":{\"principalId\":\"6660e23a-50ce-4f20-8f7d-4a7df832b73d\",\"clientId\":\"6fccf7f4-49c4-4207-8224-43a5cfb1cbb2\"}}},\"location\":\"kfrlhrxsbky\",\"tags\":{\"uzbpzkafku\":\"ca\",\"rnwb\":\"b\",\"hspkdeemao\":\"ehhseyvjusrts\",\"gkvtmelmqkrhah\":\"mx\"},\"id\":\"ljuahaquhcdh\",\"name\":\"duala\",\"type\":\"xqpvfadmw\"}]}";
+ = "{\"value\":[{\"properties\":{\"provisioningState\":\"Running\",\"hostName\":\"brjcxe\",\"dataLocation\":\"fuwutttxf\",\"notificationHubId\":\"rbirphxe\",\"version\":\"yva\",\"immutableResourceId\":\"nljky\",\"linkedDomains\":[\"vuujq\"]},\"identity\":{\"principalId\":\"d1370ea4-70f5-4ddf-bb49-cb5a41fbae09\",\"tenantId\":\"f90dff6b-94fb-40e7-83dc-85438df93e2f\",\"type\":\"None\",\"userAssignedIdentities\":{\"yoxgvcltbgsnc\":{\"principalId\":\"191c3c83-857b-4b1a-bcda-1b65b274bc6a\",\"clientId\":\"2942f4e1-ae8f-4303-b88f-2ca0345e5ee2\"},\"jeszzhbijhtxfv\":{\"principalId\":\"9cd64346-ab86-4494-8699-1fa0d1670311\",\"clientId\":\"e5d37ff6-9006-4a9c-85bd-7d287ddbc539\"}}},\"location\":\"bfs\",\"tags\":{\"pvecxgodeb\":\"eh\",\"pukgriwflzlfb\":\"qkkrb\",\"qzahmgkbrp\":\"zpuzycisp\"},\"id\":\"y\",\"name\":\"hibnuqqkpika\",\"type\":\"rgvtqag\"}]}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -53,11 +53,10 @@ public void testList() throws Exception {
PagedIterable response
= manager.communicationServices().list(com.azure.core.util.Context.NONE);
- Assertions.assertEquals("kfrlhrxsbky", response.iterator().next().location());
- Assertions.assertEquals("ca", response.iterator().next().tags().get("uzbpzkafku"));
- Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED,
- response.iterator().next().identity().type());
- Assertions.assertEquals("crpab", response.iterator().next().dataLocation());
- Assertions.assertEquals("nobglaocq", response.iterator().next().linkedDomains().get(0));
+ Assertions.assertEquals("bfs", response.iterator().next().location());
+ Assertions.assertEquals("eh", response.iterator().next().tags().get("pvecxgodeb"));
+ Assertions.assertEquals(ManagedServiceIdentityType.NONE, response.iterator().next().identity().type());
+ Assertions.assertEquals("fuwutttxf", response.iterator().next().dataLocation());
+ Assertions.assertEquals("vuujq", response.iterator().next().linkedDomains().get(0));
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/DomainsDeleteMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/DomainsDeleteMockTests.java
index 2bab7b106a68a..ebfd25caa0cfe 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/DomainsDeleteMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/DomainsDeleteMockTests.java
@@ -45,7 +45,7 @@ public void testDelete() throws Exception {
tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
new AzureProfile("", "", AzureEnvironment.AZURE));
- manager.domains().delete("od", "xzb", "cblylpstdbhhxsr", com.azure.core.util.Context.NONE);
+ manager.domains().delete("yriwwroyqb", "xrmcqibycnojvk", "mefqsgzvahapjyzh", com.azure.core.util.Context.NONE);
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateMockTests.java
index 3016de4e9a866..241724500860e 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesCreateOrUpdateMockTests.java
@@ -33,7 +33,7 @@ public void testCreateOrUpdate() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"properties\":{\"provisioningState\":\"Succeeded\",\"dataLocation\":\"qxwbpokulpiu\"},\"location\":\"aasipqi\",\"tags\":{\"rpqlp\":\"yuq\",\"auvfbtkuwhhmhyk\":\"wcciuqgbdbu\",\"hkoymkcdyhbp\":\"joxafnndlpi\"},\"id\":\"kpw\",\"name\":\"reqnovvqfov\",\"type\":\"jxywsuws\"}";
+ = "{\"properties\":{\"provisioningState\":\"Succeeded\",\"dataLocation\":\"xogaokonzmnsikv\"},\"location\":\"qzeqqkdltfzxm\",\"tags\":{\"dkwobdagx\":\"hgure\"},\"id\":\"ibqdxbxwakbogqx\",\"name\":\"dlkzgxhuri\",\"type\":\"lbpodxunk\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -50,14 +50,14 @@ public void testCreateOrUpdate() throws Exception {
tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
new AzureProfile("", "", AzureEnvironment.AZURE));
- EmailServiceResource response = manager.emailServices().define("gkopkwhojvpajqgx").withRegion("oz")
- .withExistingResourceGroup("mquxvypo").withTags(mapOf("dd", "helxprglya", "rjxgciqib", "kcbcue",
- "sdqrhzoymibmrq", "hos", "dtmhrkwofyyvoqa", "ibahwflus"))
- .withDataLocation("cmbqfqvmk").create();
+ EmailServiceResource response
+ = manager.emailServices().define("mnvdfzn").withRegion("hh").withExistingResourceGroup("mcwyhzdxssadb")
+ .withTags(mapOf("wjmy", "zdzucerscdntnevf", "s", "tdss", "emwabnet", "tmweriofzpyq", "d", "hhszh"))
+ .withDataLocation("dvxzbncblylpst").create();
- Assertions.assertEquals("aasipqi", response.location());
- Assertions.assertEquals("yuq", response.tags().get("rpqlp"));
- Assertions.assertEquals("qxwbpokulpiu", response.dataLocation());
+ Assertions.assertEquals("qzeqqkdltfzxm", response.location());
+ Assertions.assertEquals("hgure", response.tags().get("dkwobdagx"));
+ Assertions.assertEquals("xogaokonzmnsikv", response.dataLocation());
}
// Use "Map.of" if available
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteMockTests.java
index f5ab6677190a0..dbea86887aa5c 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesDeleteMockTests.java
@@ -45,7 +45,7 @@ public void testDelete() throws Exception {
tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
new AzureProfile("", "", AzureEnvironment.AZURE));
- manager.emailServices().delete("ohdneuel", "phsdyhto", com.azure.core.util.Context.NONE);
+ manager.emailServices().delete("j", "n", com.azure.core.util.Context.NONE);
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupWithResponseMockTests.java
index 4fdf78c390ce8..d373dd89895f5 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesGetByResourceGroupWithResponseMockTests.java
@@ -31,7 +31,7 @@ public void testGetByResourceGroupWithResponse() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"properties\":{\"provisioningState\":\"Creating\",\"dataLocation\":\"zgx\"},\"location\":\"ripl\",\"tags\":{\"wlrbqtkoievseo\":\"dxunkbebxmubyyn\",\"wzizxbmpgcjefuzm\":\"gqrlltmuwla\"},\"id\":\"vpbttd\",\"name\":\"morppxebmnzbtbh\",\"type\":\"pglkf\"}";
+ = "{\"properties\":{\"provisioningState\":\"Running\",\"dataLocation\":\"gylgqgitxmedjvcs\"},\"location\":\"n\",\"tags\":{\"zhxgktrmgucn\":\"ncw\",\"llwptfdy\":\"pkteo\",\"rhhuaopppcqeqx\":\"pfqbuaceopzf\",\"izpost\":\"lzdahzxctobgbkdm\"},\"id\":\"grcfb\",\"name\":\"nrmfqjhhk\",\"type\":\"bpvjymjhx\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -49,11 +49,11 @@ public void testGetByResourceGroupWithResponse() throws Exception {
new AzureProfile("", "", AzureEnvironment.AZURE));
EmailServiceResource response = manager.emailServices()
- .getByResourceGroupWithResponse("dkwobdagx", "ibqdxbxwakbogqx", com.azure.core.util.Context.NONE)
+ .getByResourceGroupWithResponse("bnxknalaulppg", "dtpnapnyiropuhp", com.azure.core.util.Context.NONE)
.getValue();
- Assertions.assertEquals("ripl", response.location());
- Assertions.assertEquals("dxunkbebxmubyyn", response.tags().get("wlrbqtkoievseo"));
- Assertions.assertEquals("zgx", response.dataLocation());
+ Assertions.assertEquals("n", response.location());
+ Assertions.assertEquals("ncw", response.tags().get("zhxgktrmgucn"));
+ Assertions.assertEquals("gylgqgitxmedjvcs", response.dataLocation());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupMockTests.java
index 942c67f99bda4..5feebaecd34f3 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListByResourceGroupMockTests.java
@@ -32,7 +32,7 @@ public void testListByResourceGroup() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"value\":[{\"properties\":{\"provisioningState\":\"Succeeded\",\"dataLocation\":\"bobzdopcjwvnhd\"},\"location\":\"wmgxcxrsl\",\"tags\":{\"qsluicp\":\"twuoegrpkhjwni\"},\"id\":\"ggkzzlvmbmpa\",\"name\":\"modfvuefywsbpfvm\",\"type\":\"yhrfouyftaakcpw\"}]}";
+ = "{\"value\":[{\"properties\":{\"provisioningState\":\"Updating\",\"dataLocation\":\"jzbexilzznfq\"},\"location\":\"vwpm\",\"tags\":{\"jhwqytjrybnw\":\"ruoujmk\",\"enq\":\"ewgdrjervn\",\"ndoygmifthnzdnd\":\"eh\",\"nayqi\":\"l\"},\"id\":\"ynduha\",\"name\":\"hqlkthumaqo\",\"type\":\"bgycduiertgccym\"}]}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -50,10 +50,10 @@ public void testListByResourceGroup() throws Exception {
new AzureProfile("", "", AzureEnvironment.AZURE));
PagedIterable response
- = manager.emailServices().listByResourceGroup("pkeqdcvdrhvoo", com.azure.core.util.Context.NONE);
+ = manager.emailServices().listByResourceGroup("t", com.azure.core.util.Context.NONE);
- Assertions.assertEquals("wmgxcxrsl", response.iterator().next().location());
- Assertions.assertEquals("twuoegrpkhjwni", response.iterator().next().tags().get("qsluicp"));
- Assertions.assertEquals("bobzdopcjwvnhd", response.iterator().next().dataLocation());
+ Assertions.assertEquals("vwpm", response.iterator().next().location());
+ Assertions.assertEquals("ruoujmk", response.iterator().next().tags().get("jhwqytjrybnw"));
+ Assertions.assertEquals("jzbexilzznfq", response.iterator().next().dataLocation());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListMockTests.java
index 1169ea28f4bf3..03b8ff7ed227d 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListMockTests.java
@@ -32,7 +32,7 @@ public void testList() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"value\":[{\"properties\":{\"provisioningState\":\"Moving\",\"dataLocation\":\"dowwquuvxzxclvit\"},\"location\":\"qzonosggbhcohf\",\"tags\":{\"dkzzewkfvhqcrail\":\"jnkaljutiiswacff\",\"rwdmhdlxyjrxsa\":\"pnppfuf\"},\"id\":\"afcnih\",\"name\":\"wqapnedgfbcvk\",\"type\":\"vq\"}]}";
+ = "{\"value\":[{\"properties\":{\"provisioningState\":\"Creating\",\"dataLocation\":\"vkr\"},\"location\":\"wbxqzvszjfau\",\"tags\":{\"tvtc\":\"dxxiv\",\"wvxysl\":\"aqtdoqmcbx\",\"ytkblmpew\":\"bhsfxob\",\"shqjohxcrsbf\":\"wfbkrvrns\"},\"id\":\"vasrruvwb\",\"name\":\"sqfsubcgjbirxb\",\"type\":\"ybsrfbjfdtwss\"}]}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -51,8 +51,8 @@ public void testList() throws Exception {
PagedIterable response = manager.emailServices().list(com.azure.core.util.Context.NONE);
- Assertions.assertEquals("qzonosggbhcohf", response.iterator().next().location());
- Assertions.assertEquals("jnkaljutiiswacff", response.iterator().next().tags().get("dkzzewkfvhqcrail"));
- Assertions.assertEquals("dowwquuvxzxclvit", response.iterator().next().dataLocation());
+ Assertions.assertEquals("wbxqzvszjfau", response.iterator().next().location());
+ Assertions.assertEquals("dxxiv", response.iterator().next().tags().get("tvtc"));
+ Assertions.assertEquals("vkr", response.iterator().next().dataLocation());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsWithResponseMockTests.java
index c04d9dd9284a4..2dd28ba89640d 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/EmailServicesListVerifiedExchangeOnlineDomainsWithResponseMockTests.java
@@ -30,7 +30,7 @@ public void testListVerifiedExchangeOnlineDomainsWithResponse() throws Exception
HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
- String responseStr = "[\"zvqtmnubexkp\",\"ksmond\"]";
+ String responseStr = "[\"olpsslqlf\",\"mdnbbglzpswiy\"]";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -50,6 +50,6 @@ public void testListVerifiedExchangeOnlineDomainsWithResponse() throws Exception
List response = manager.emailServices()
.listVerifiedExchangeOnlineDomainsWithResponse(com.azure.core.util.Context.NONE).getValue();
- Assertions.assertEquals("zvqtmnubexkp", response.get(0));
+ Assertions.assertEquals("olpsslqlf", response.get(0));
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/ManagedServiceIdentityTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/ManagedServiceIdentityTests.java
index cf0f0a56858d6..fd700b0ae41d9 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/ManagedServiceIdentityTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/ManagedServiceIdentityTests.java
@@ -16,7 +16,7 @@ public final class ManagedServiceIdentityTests {
@org.junit.jupiter.api.Test
public void testDeserialize() throws Exception {
ManagedServiceIdentity model = BinaryData.fromString(
- "{\"principalId\":\"7da3f15f-3155-44b6-af7b-57d700e8f3dc\",\"tenantId\":\"49937368-fbce-4402-86f3-d3aa0a9448f0\",\"type\":\"None\",\"userAssignedIdentities\":{\"txilnerkujy\":{\"principalId\":\"67f3950e-cd0f-487e-816c-470e8537908e\",\"clientId\":\"59f0b0a9-0888-4c2b-ac73-b383c3bc4c43\"},\"eju\":{\"principalId\":\"28575b7b-d38a-4ae5-b132-6015536496ec\",\"clientId\":\"a64c4366-9d5f-4d2d-a216-cdc7b15630f9\"},\"awrlyx\":{\"principalId\":\"fbdd6559-a515-49de-8f75-d3f5ee30a72a\",\"clientId\":\"71db179b-92ad-4b09-830b-cfe4be1c994e\"},\"cpr\":{\"principalId\":\"10c013a1-f476-4177-9ed5-85e204c97d46\",\"clientId\":\"0f13e40b-e69a-425e-bc08-3d4491477e09\"}}}")
+ "{\"principalId\":\"bebc74ca-97ca-44ea-b2d5-b55c1210d16f\",\"tenantId\":\"f5291bd7-d061-4a17-9d4a-c6f025d175a6\",\"type\":\"None\",\"userAssignedIdentities\":{\"txilnerkujy\":{\"principalId\":\"4f4d8daf-9f71-44c5-ba07-b2172fb018a3\",\"clientId\":\"2421076f-59d0-4b0c-9893-f5e492a2ea38\"},\"eju\":{\"principalId\":\"5e7b6896-820d-42ee-bb9f-d596b1919f12\",\"clientId\":\"92a91233-d202-4ba9-989d-b036975c0d20\"},\"awrlyx\":{\"principalId\":\"bf808346-170c-4992-86a8-e44f9f227be1\",\"clientId\":\"e6ec8881-63f6-4bbc-99ae-c2e74353c994\"},\"cpr\":{\"principalId\":\"67c80dc7-9173-4dc8-be62-a43794323825\",\"clientId\":\"aff379ad-161b-4630-a4b8-5a5d9036999f\"}}}")
.toObject(ManagedServiceIdentity.class);
Assertions.assertEquals(ManagedServiceIdentityType.NONE, model.type());
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/OperationsListMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/OperationsListMockTests.java
index db96b8934e2c3..fa93a4597df0f 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/OperationsListMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/OperationsListMockTests.java
@@ -31,7 +31,7 @@ public void testList() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"value\":[{\"name\":\"ghxpkdw\",\"isDataAction\":true,\"display\":{\"provider\":\"ebb\",\"resource\":\"m\",\"operation\":\"qupedeojnab\",\"description\":\"hsmtxpsiebtfhvp\"},\"origin\":\"user\",\"actionType\":\"Internal\"}]}";
+ = "{\"value\":[{\"name\":\"qftiy\",\"isDataAction\":true,\"display\":{\"provider\":\"cqvyxlwhzlsico\",\"resource\":\"qqn\",\"operation\":\"lryav\",\"description\":\"heun\"},\"origin\":\"system\",\"actionType\":\"Internal\"}]}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateWithResponseMockTests.java
index b3eb3ebcffe0a..2cca857d1184b 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesCreateOrUpdateWithResponseMockTests.java
@@ -31,7 +31,7 @@ public void testCreateOrUpdateWithResponse() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"properties\":{\"dataLocation\":\"pxgy\",\"username\":\"agvrvmnpkuk\",\"displayName\":\"i\",\"provisioningState\":\"Updating\"},\"id\":\"xgwim\",\"name\":\"njhf\",\"type\":\"xw\"}";
+ = "{\"properties\":{\"dataLocation\":\"vqtmnub\",\"username\":\"xkp\",\"displayName\":\"smond\",\"provisioningState\":\"Creating\"},\"id\":\"xvy\",\"name\":\"omgkopkwho\",\"type\":\"v\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -49,10 +49,10 @@ public void testCreateOrUpdateWithResponse() throws Exception {
new AzureProfile("", "", AzureEnvironment.AZURE));
SenderUsernameResource response
- = manager.senderUsernames().define("v").withExistingDomain("lla", "melwuipiccjz", "z")
- .withUsername("ayrhyrnx").withDisplayName("ueedndrdvs").create();
+ = manager.senderUsernames().define("opcjwvnhd").withExistingDomain("cvkcvqvpkeqdcv", "rhvoods", "tbobz")
+ .withUsername("twuoegrpkhjwni").withDisplayName("sluicpdggkzz").create();
- Assertions.assertEquals("agvrvmnpkuk", response.username());
- Assertions.assertEquals("i", response.displayName());
+ Assertions.assertEquals("xkp", response.username());
+ Assertions.assertEquals("smond", response.displayName());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteWithResponseMockTests.java
index a222b53cfd714..7541539748e07 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesDeleteWithResponseMockTests.java
@@ -45,7 +45,7 @@ public void testDeleteWithResponse() throws Exception {
tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
new AzureProfile("", "", AzureEnvironment.AZURE));
- manager.senderUsernames().deleteWithResponse("syocogjltdtbnnha", "oocrkvcikhnv", "amqgxqquezikyw", "gxk",
+ manager.senderUsernames().deleteWithResponse("lxyjr", "sag", "fcnihgwq", "pnedgf",
com.azure.core.util.Context.NONE);
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetWithResponseMockTests.java
index 8473d4bb825f2..162afa504a495 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetWithResponseMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesGetWithResponseMockTests.java
@@ -31,7 +31,7 @@ public void testGetWithResponse() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"properties\":{\"dataLocation\":\"yhqmibzyhwi\",\"username\":\"smypyynpc\",\"displayName\":\"umnzgmwznmabik\",\"provisioningState\":\"Updating\"},\"id\":\"gj\",\"name\":\"xbldtlwwrlkdmtn\",\"type\":\"vokotllxdyh\"}";
+ = "{\"properties\":{\"dataLocation\":\"hfwdsjnkaljutiis\",\"username\":\"acffgdkzzewkfvhq\",\"displayName\":\"a\",\"provisioningState\":\"Updating\"},\"id\":\"n\",\"name\":\"pfuflrw\",\"type\":\"mh\"}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -49,10 +49,9 @@ public void testGetWithResponse() throws Exception {
new AzureProfile("", "", AzureEnvironment.AZURE));
SenderUsernameResource response = manager.senderUsernames()
- .getWithResponse("sjswsrms", "yzrpzbchckqqzq", "ox", "ysuiizynkedya", com.azure.core.util.Context.NONE)
- .getValue();
+ .getWithResponse("quuvxzxcl", "ithhqzon", "sg", "b", com.azure.core.util.Context.NONE).getValue();
- Assertions.assertEquals("smypyynpc", response.username());
- Assertions.assertEquals("umnzgmwznmabik", response.displayName());
+ Assertions.assertEquals("acffgdkzzewkfvhq", response.username());
+ Assertions.assertEquals("a", response.displayName());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsMockTests.java
index 3d440f5f4301c..56f11ba4254f4 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsMockTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SenderUsernamesListByDomainsMockTests.java
@@ -32,7 +32,7 @@ public void testListByDomains() throws Exception {
ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
String responseStr
- = "{\"value\":[{\"properties\":{\"dataLocation\":\"qkacewii\",\"username\":\"fpubjibwwi\",\"displayName\":\"ohqkvpuvksgpls\",\"provisioningState\":\"Failed\"},\"id\":\"n\",\"name\":\"synljphuopxodl\",\"type\":\"iyntorzihle\"}]}";
+ = "{\"value\":[{\"properties\":{\"dataLocation\":\"tmuwlauwzi\",\"username\":\"xbmp\",\"displayName\":\"jefuzmuvpbttdumo\",\"provisioningState\":\"Succeeded\"},\"id\":\"ebmnzbtbhjpglk\",\"name\":\"gohdneuelfphsd\",\"type\":\"htozfikdow\"}]}";
Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
@@ -49,10 +49,10 @@ public void testListByDomains() throws Exception {
tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
new AzureProfile("", "", AzureEnvironment.AZURE));
- PagedIterable response = manager.senderUsernames().listByDomains("rsndsytgadgvra",
- "aeneqnzarrwl", "uu", com.azure.core.util.Context.NONE);
+ PagedIterable response = manager.senderUsernames().listByDomains("ebxmubyynt", "lrb",
+ "tkoievseotgq", com.azure.core.util.Context.NONE);
- Assertions.assertEquals("fpubjibwwi", response.iterator().next().username());
- Assertions.assertEquals("ohqkvpuvksgpls", response.iterator().next().displayName());
+ Assertions.assertEquals("xbmp", response.iterator().next().username());
+ Assertions.assertEquals("jefuzmuvpbttdumo", response.iterator().next().displayName());
}
}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressPropertiesTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressPropertiesTests.java
deleted file mode 100644
index 4a93a2ff0a3de..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressPropertiesTests.java
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.util.BinaryData;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressProperties;
-import org.junit.jupiter.api.Assertions;
-
-public final class SuppressionListAddressPropertiesTests {
- @org.junit.jupiter.api.Test
- public void testDeserialize() throws Exception {
- SuppressionListAddressProperties model = BinaryData.fromString(
- "{\"email\":\"bhvgy\",\"firstName\":\"uosvmkfssxqukk\",\"lastName\":\"l\",\"notes\":\"gsxnkjzkdeslpv\",\"lastModified\":\"2021-06-26T13:13:32Z\",\"dataLocation\":\"i\"}")
- .toObject(SuppressionListAddressProperties.class);
- Assertions.assertEquals("bhvgy", model.email());
- Assertions.assertEquals("uosvmkfssxqukk", model.firstName());
- Assertions.assertEquals("l", model.lastName());
- Assertions.assertEquals("gsxnkjzkdeslpv", model.notes());
- }
-
- @org.junit.jupiter.api.Test
- public void testSerialize() throws Exception {
- SuppressionListAddressProperties model = new SuppressionListAddressProperties().withEmail("bhvgy")
- .withFirstName("uosvmkfssxqukk").withLastName("l").withNotes("gsxnkjzkdeslpv");
- model = BinaryData.fromObject(model).toObject(SuppressionListAddressProperties.class);
- Assertions.assertEquals("bhvgy", model.email());
- Assertions.assertEquals("uosvmkfssxqukk", model.firstName());
- Assertions.assertEquals("l", model.lastName());
- Assertions.assertEquals("gsxnkjzkdeslpv", model.notes());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressResourceCollectionTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressResourceCollectionTests.java
deleted file mode 100644
index 8d313aabb1501..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressResourceCollectionTests.java
+++ /dev/null
@@ -1,42 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.util.BinaryData;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListAddressResourceCollection;
-import java.util.Arrays;
-import org.junit.jupiter.api.Assertions;
-
-public final class SuppressionListAddressResourceCollectionTests {
- @org.junit.jupiter.api.Test
- public void testDeserialize() throws Exception {
- SuppressionListAddressResourceCollection model = BinaryData.fromString(
- "{\"value\":[{\"properties\":{\"email\":\"ibnuqqkpik\",\"firstName\":\"rgvtqag\",\"lastName\":\"uynhijg\",\"notes\":\"ebf\",\"lastModified\":\"2021-09-24T19:25:12Z\",\"dataLocation\":\"butr\"},\"id\":\"pnazzm\",\"name\":\"jrunmpxtt\",\"type\":\"bh\"},{\"properties\":{\"email\":\"nlankxmyskpb\",\"firstName\":\"nbtkcxywnytnr\",\"lastName\":\"nlqidybyxczf\",\"notes\":\"haaxdbabphl\",\"lastModified\":\"2021-02-16T08:29:45Z\",\"dataLocation\":\"fkts\"},\"id\":\"sucocmnyyazttbtw\",\"name\":\"rq\",\"type\":\"uedck\"}],\"nextLink\":\"wbiexzfey\"}")
- .toObject(SuppressionListAddressResourceCollection.class);
- Assertions.assertEquals("ibnuqqkpik", model.value().get(0).email());
- Assertions.assertEquals("rgvtqag", model.value().get(0).firstName());
- Assertions.assertEquals("uynhijg", model.value().get(0).lastName());
- Assertions.assertEquals("ebf", model.value().get(0).notes());
- Assertions.assertEquals("wbiexzfey", model.nextLink());
- }
-
- @org.junit.jupiter.api.Test
- public void testSerialize() throws Exception {
- SuppressionListAddressResourceCollection model
- = new SuppressionListAddressResourceCollection().withValue(Arrays.asList(
- new SuppressionListAddressResourceInner().withEmail("ibnuqqkpik").withFirstName("rgvtqag")
- .withLastName("uynhijg").withNotes("ebf"),
- new SuppressionListAddressResourceInner().withEmail("nlankxmyskpb").withFirstName("nbtkcxywnytnr")
- .withLastName("nlqidybyxczf").withNotes("haaxdbabphl")))
- .withNextLink("wbiexzfey");
- model = BinaryData.fromObject(model).toObject(SuppressionListAddressResourceCollection.class);
- Assertions.assertEquals("ibnuqqkpik", model.value().get(0).email());
- Assertions.assertEquals("rgvtqag", model.value().get(0).firstName());
- Assertions.assertEquals("uynhijg", model.value().get(0).lastName());
- Assertions.assertEquals("ebf", model.value().get(0).notes());
- Assertions.assertEquals("wbiexzfey", model.nextLink());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressResourceInnerTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressResourceInnerTests.java
deleted file mode 100644
index 62960286b5189..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressResourceInnerTests.java
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.util.BinaryData;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListAddressResourceInner;
-import org.junit.jupiter.api.Assertions;
-
-public final class SuppressionListAddressResourceInnerTests {
- @org.junit.jupiter.api.Test
- public void testDeserialize() throws Exception {
- SuppressionListAddressResourceInner model = BinaryData.fromString(
- "{\"properties\":{\"email\":\"axibxujw\",\"firstName\":\"qwalmuzyoxaepd\",\"lastName\":\"jancu\",\"notes\":\"hdwbavxbniwdjs\",\"lastModified\":\"2021-12-07T05:36:29Z\",\"dataLocation\":\"dbpgnxytxhp\"},\"id\":\"bzpfzab\",\"name\":\"lcuhxwtctyqiklb\",\"type\":\"ovplw\"}")
- .toObject(SuppressionListAddressResourceInner.class);
- Assertions.assertEquals("axibxujw", model.email());
- Assertions.assertEquals("qwalmuzyoxaepd", model.firstName());
- Assertions.assertEquals("jancu", model.lastName());
- Assertions.assertEquals("hdwbavxbniwdjs", model.notes());
- }
-
- @org.junit.jupiter.api.Test
- public void testSerialize() throws Exception {
- SuppressionListAddressResourceInner model = new SuppressionListAddressResourceInner().withEmail("axibxujw")
- .withFirstName("qwalmuzyoxaepd").withLastName("jancu").withNotes("hdwbavxbniwdjs");
- model = BinaryData.fromObject(model).toObject(SuppressionListAddressResourceInner.class);
- Assertions.assertEquals("axibxujw", model.email());
- Assertions.assertEquals("qwalmuzyoxaepd", model.firstName());
- Assertions.assertEquals("jancu", model.lastName());
- Assertions.assertEquals("hdwbavxbniwdjs", model.notes());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesCreateOrUpdateWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesCreateOrUpdateWithResponseMockTests.java
deleted file mode 100644
index febe4e7e5b004..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesCreateOrUpdateWithResponseMockTests.java
+++ /dev/null
@@ -1,60 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import com.azure.resourcemanager.communication.models.SuppressionListAddressResource;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListAddressesCreateOrUpdateWithResponseMockTests {
- @Test
- public void testCreateOrUpdateWithResponse() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr
- = "{\"properties\":{\"email\":\"skdsnfdsdoakg\",\"firstName\":\"lmkk\",\"lastName\":\"vdlhewpusdsttwv\",\"notes\":\"vbbejdcng\",\"lastModified\":\"2021-02-12T16:56:22Z\",\"dataLocation\":\"akufgmjz\"},\"id\":\"rdgrtw\",\"name\":\"enuuzkopbm\",\"type\":\"nrfdw\"}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- SuppressionListAddressResource response = manager.suppressionListAddresses().define("hkh")
- .withExistingSuppressionList("ojvdcpzfoqo", "i", "ybxarzgszu", "oxciqopidoamcio").withEmail("xkhnzbonlwnto")
- .withFirstName("okdwb").withLastName("kszzcmrvexztv").withNotes("qgsfraoyzkoow").create();
-
- Assertions.assertEquals("skdsnfdsdoakg", response.email());
- Assertions.assertEquals("lmkk", response.firstName());
- Assertions.assertEquals("vdlhewpusdsttwv", response.lastName());
- Assertions.assertEquals("vbbejdcng", response.notes());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesDeleteWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesDeleteWithResponseMockTests.java
deleted file mode 100644
index e1a9fe98c373f..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesDeleteWithResponseMockTests.java
+++ /dev/null
@@ -1,52 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListAddressesDeleteWithResponseMockTests {
- @Test
- public void testDeleteWithResponse() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr = "{}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- manager.suppressionListAddresses().deleteWithResponse("kif", "vtpuqujmqlgk", "btndo", "ongbjcnt",
- "jitcjedftwwaez", com.azure.core.util.Context.NONE);
-
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesGetWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesGetWithResponseMockTests.java
deleted file mode 100644
index eafd9773e8403..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesGetWithResponseMockTests.java
+++ /dev/null
@@ -1,59 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import com.azure.resourcemanager.communication.models.SuppressionListAddressResource;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListAddressesGetWithResponseMockTests {
- @Test
- public void testGetWithResponse() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr
- = "{\"properties\":{\"email\":\"lvkgju\",\"firstName\":\"dknnqvsazn\",\"lastName\":\"tor\",\"notes\":\"sgsahmkycgr\",\"lastModified\":\"2021-04-05T08:15:46Z\",\"dataLocation\":\"uetae\"},\"id\":\"ruvdmov\",\"name\":\"mz\",\"type\":\"xwabmqoe\"}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- SuppressionListAddressResource response = manager.suppressionListAddresses().getWithResponse("wdcfhucqdpfuv",
- "lsbjjcanvxbv", "vudutncor", "r", "xqtvcofu", com.azure.core.util.Context.NONE).getValue();
-
- Assertions.assertEquals("lvkgju", response.email());
- Assertions.assertEquals("dknnqvsazn", response.firstName());
- Assertions.assertEquals("tor", response.lastName());
- Assertions.assertEquals("sgsahmkycgr", response.notes());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesListMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesListMockTests.java
deleted file mode 100644
index 8d599e900a7d5..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListAddressesListMockTests.java
+++ /dev/null
@@ -1,60 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import com.azure.resourcemanager.communication.models.SuppressionListAddressResource;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListAddressesListMockTests {
- @Test
- public void testList() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr
- = "{\"value\":[{\"properties\":{\"email\":\"cvinvkjjxdxrbuuk\",\"firstName\":\"lewyhmlwpaz\",\"lastName\":\"pofncck\",\"notes\":\"fz\",\"lastModified\":\"2021-06-21T11:47:26Z\",\"dataLocation\":\"xbuy\"},\"id\":\"xzfe\",\"name\":\"ztppriolxorjalto\",\"type\":\"mncwsobqwcsdb\"}]}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- PagedIterable response = manager.suppressionListAddresses().list("r", "tiagx",
- "dszue", "psbzkfzbeyvpn", com.azure.core.util.Context.NONE);
-
- Assertions.assertEquals("cvinvkjjxdxrbuuk", response.iterator().next().email());
- Assertions.assertEquals("lewyhmlwpaz", response.iterator().next().firstName());
- Assertions.assertEquals("pofncck", response.iterator().next().lastName());
- Assertions.assertEquals("fz", response.iterator().next().notes());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListPropertiesTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListPropertiesTests.java
deleted file mode 100644
index 362c8677713d2..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListPropertiesTests.java
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.util.BinaryData;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListProperties;
-import org.junit.jupiter.api.Assertions;
-
-public final class SuppressionListPropertiesTests {
- @org.junit.jupiter.api.Test
- public void testDeserialize() throws Exception {
- SuppressionListProperties model = BinaryData.fromString(
- "{\"listName\":\"odebfqkkrbmpu\",\"lastUpdatedTimeStamp\":\"riwflzlfb\",\"createdTimeStamp\":\"puz\",\"dataLocation\":\"ispnqzahmgkbrp\"}")
- .toObject(SuppressionListProperties.class);
- Assertions.assertEquals("odebfqkkrbmpu", model.listName());
- }
-
- @org.junit.jupiter.api.Test
- public void testSerialize() throws Exception {
- SuppressionListProperties model = new SuppressionListProperties().withListName("odebfqkkrbmpu");
- model = BinaryData.fromObject(model).toObject(SuppressionListProperties.class);
- Assertions.assertEquals("odebfqkkrbmpu", model.listName());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListResourceCollectionTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListResourceCollectionTests.java
deleted file mode 100644
index e90c818895397..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListResourceCollectionTests.java
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.util.BinaryData;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-import com.azure.resourcemanager.communication.models.SuppressionListResourceCollection;
-import java.util.Arrays;
-import org.junit.jupiter.api.Assertions;
-
-public final class SuppressionListResourceCollectionTests {
- @org.junit.jupiter.api.Test
- public void testDeserialize() throws Exception {
- SuppressionListResourceCollection model = BinaryData.fromString(
- "{\"value\":[{\"properties\":{\"listName\":\"iyqzrnk\",\"lastUpdatedTimeStamp\":\"vyxlwhzlsicohoqq\",\"createdTimeStamp\":\"vlryavwhheunmmq\",\"dataLocation\":\"yxzk\"},\"id\":\"ocukoklyax\",\"name\":\"conuqszfkbeype\",\"type\":\"rmjmwvvjektc\"},{\"properties\":{\"listName\":\"nhwlrsffrzpwvl\",\"lastUpdatedTimeStamp\":\"q\",\"createdTimeStamp\":\"iqylihkaetck\",\"dataLocation\":\"fcivfsnkym\"},\"id\":\"tqhjfbebrjcx\",\"name\":\"rfuwutt\",\"type\":\"xfvjrbirp\"}],\"nextLink\":\"epcyvahfnlj\"}")
- .toObject(SuppressionListResourceCollection.class);
- Assertions.assertEquals("iyqzrnk", model.value().get(0).listName());
- Assertions.assertEquals("epcyvahfnlj", model.nextLink());
- }
-
- @org.junit.jupiter.api.Test
- public void testSerialize() throws Exception {
- SuppressionListResourceCollection model = new SuppressionListResourceCollection()
- .withValue(Arrays.asList(new SuppressionListResourceInner().withListName("iyqzrnk"),
- new SuppressionListResourceInner().withListName("nhwlrsffrzpwvl")))
- .withNextLink("epcyvahfnlj");
- model = BinaryData.fromObject(model).toObject(SuppressionListResourceCollection.class);
- Assertions.assertEquals("iyqzrnk", model.value().get(0).listName());
- Assertions.assertEquals("epcyvahfnlj", model.nextLink());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListResourceInnerTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListResourceInnerTests.java
deleted file mode 100644
index 42bb1c1317922..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListResourceInnerTests.java
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.util.BinaryData;
-import com.azure.resourcemanager.communication.fluent.models.SuppressionListResourceInner;
-import org.junit.jupiter.api.Assertions;
-
-public final class SuppressionListResourceInnerTests {
- @org.junit.jupiter.api.Test
- public void testDeserialize() throws Exception {
- SuppressionListResourceInner model = BinaryData.fromString(
- "{\"properties\":{\"listName\":\"xjvuujqgidokg\",\"lastUpdatedTimeStamp\":\"jyoxgvclt\",\"createdTimeStamp\":\"sncghkjeszz\",\"dataLocation\":\"ijhtxf\"},\"id\":\"xbf\",\"name\":\"mxnehmp\",\"type\":\"ec\"}")
- .toObject(SuppressionListResourceInner.class);
- Assertions.assertEquals("xjvuujqgidokg", model.listName());
- }
-
- @org.junit.jupiter.api.Test
- public void testSerialize() throws Exception {
- SuppressionListResourceInner model = new SuppressionListResourceInner().withListName("xjvuujqgidokg");
- model = BinaryData.fromObject(model).toObject(SuppressionListResourceInner.class);
- Assertions.assertEquals("xjvuujqgidokg", model.listName());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsCreateOrUpdateWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsCreateOrUpdateWithResponseMockTests.java
deleted file mode 100644
index 6cdd0c0d80f35..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsCreateOrUpdateWithResponseMockTests.java
+++ /dev/null
@@ -1,56 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import com.azure.resourcemanager.communication.models.SuppressionListResource;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListsCreateOrUpdateWithResponseMockTests {
- @Test
- public void testCreateOrUpdateWithResponse() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr
- = "{\"properties\":{\"listName\":\"ooaojkniodkooebw\",\"lastUpdatedTimeStamp\":\"jhemms\",\"createdTimeStamp\":\"dkcrodt\",\"dataLocation\":\"nfwjlfltkacjvefk\"},\"id\":\"foakgg\",\"name\":\"fpagaowpulp\",\"type\":\"blylsyxkqjnsj\"}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- SuppressionListResource response = manager.suppressionLists().define("zsoibjudpfrxtr")
- .withExistingDomain("imrzrtuzqog", "exn", "vfdnwnwmewzsyyce").withListName("vaytdwkqbrq").create();
-
- Assertions.assertEquals("ooaojkniodkooebw", response.listName());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsDeleteWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsDeleteWithResponseMockTests.java
deleted file mode 100644
index 1bbdb598438da..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsDeleteWithResponseMockTests.java
+++ /dev/null
@@ -1,52 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListsDeleteWithResponseMockTests {
- @Test
- public void testDeleteWithResponse() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr = "{}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- manager.suppressionLists().deleteWithResponse("ubeddg", "sofwqmzqalkrmnji", "pxacqqudfn", "yxbaaabjyvayf",
- com.azure.core.util.Context.NONE);
-
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsGetWithResponseMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsGetWithResponseMockTests.java
deleted file mode 100644
index 89686aaee7114..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsGetWithResponseMockTests.java
+++ /dev/null
@@ -1,56 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import com.azure.resourcemanager.communication.models.SuppressionListResource;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListsGetWithResponseMockTests {
- @Test
- public void testGetWithResponse() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr
- = "{\"properties\":{\"listName\":\"atpxl\",\"lastUpdatedTimeStamp\":\"xcyjmoadsuvarmy\",\"createdTimeStamp\":\"mjsjqb\",\"dataLocation\":\"hyxxrwlycoduhpk\"},\"id\":\"gymare\",\"name\":\"n\",\"type\":\"jxqugjhky\"}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- SuppressionListResource response = manager.suppressionLists().getWithResponse("rvimjwosytxitcsk",
- "cktqumiekkezzi", "hlyfjhdgqgg", "bdunygaeqid", com.azure.core.util.Context.NONE).getValue();
-
- Assertions.assertEquals("atpxl", response.listName());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsListByDomainMockTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsListByDomainMockTests.java
deleted file mode 100644
index df770f114f50c..0000000000000
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/SuppressionListsListByDomainMockTests.java
+++ /dev/null
@@ -1,57 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.communication.generated;
-
-import com.azure.core.credential.AccessToken;
-import com.azure.core.http.HttpClient;
-import com.azure.core.http.HttpHeaders;
-import com.azure.core.http.HttpRequest;
-import com.azure.core.http.HttpResponse;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.management.AzureEnvironment;
-import com.azure.core.management.profile.AzureProfile;
-import com.azure.resourcemanager.communication.CommunicationManager;
-import com.azure.resourcemanager.communication.models.SuppressionListResource;
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
-import java.time.OffsetDateTime;
-import org.junit.jupiter.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.mockito.ArgumentCaptor;
-import org.mockito.Mockito;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-public final class SuppressionListsListByDomainMockTests {
- @Test
- public void testListByDomain() throws Exception {
- HttpClient httpClient = Mockito.mock(HttpClient.class);
- HttpResponse httpResponse = Mockito.mock(HttpResponse.class);
- ArgumentCaptor httpRequest = ArgumentCaptor.forClass(HttpRequest.class);
-
- String responseStr
- = "{\"value\":[{\"properties\":{\"listName\":\"zel\",\"lastUpdatedTimeStamp\":\"irels\",\"createdTimeStamp\":\"aenwabf\",\"dataLocation\":\"kl\"},\"id\":\"xbjhwuaanozjosph\",\"name\":\"oulpjrv\",\"type\":\"ag\"}]}";
-
- Mockito.when(httpResponse.getStatusCode()).thenReturn(200);
- Mockito.when(httpResponse.getHeaders()).thenReturn(new HttpHeaders());
- Mockito.when(httpResponse.getBody())
- .thenReturn(Flux.just(ByteBuffer.wrap(responseStr.getBytes(StandardCharsets.UTF_8))));
- Mockito.when(httpResponse.getBodyAsByteArray())
- .thenReturn(Mono.just(responseStr.getBytes(StandardCharsets.UTF_8)));
- Mockito.when(httpClient.send(httpRequest.capture(), Mockito.any())).thenReturn(Mono.defer(() -> {
- Mockito.when(httpResponse.getRequest()).thenReturn(httpRequest.getValue());
- return Mono.just(httpResponse);
- }));
-
- CommunicationManager manager = CommunicationManager.configure().withHttpClient(httpClient).authenticate(
- tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)),
- new AzureProfile("", "", AzureEnvironment.AZURE));
-
- PagedIterable response = manager.suppressionLists().listByDomain("szkkfoqre",
- "fkzikfj", "wneaiv", com.azure.core.util.Context.NONE);
-
- Assertions.assertEquals("zel", response.iterator().next().listName());
- }
-}
diff --git a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/UserAssignedIdentityTests.java b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/UserAssignedIdentityTests.java
index 5d8da4c074c8e..6d555ee7cf05e 100644
--- a/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/UserAssignedIdentityTests.java
+++ b/sdk/communication/azure-resourcemanager-communication/src/test/java/com/azure/resourcemanager/communication/generated/UserAssignedIdentityTests.java
@@ -11,7 +11,7 @@ public final class UserAssignedIdentityTests {
@org.junit.jupiter.api.Test
public void testDeserialize() throws Exception {
UserAssignedIdentity model = BinaryData.fromString(
- "{\"principalId\":\"5688cec6-fe41-47f6-b13e-8bf2b671e519\",\"clientId\":\"b428f3e0-2e4a-4810-b7f6-927949014134\"}")
+ "{\"principalId\":\"31004c3d-9ac5-4e79-bf00-0c50e42a2fdf\",\"clientId\":\"3f12c4e5-9bcd-457f-8bba-911e58c6db1d\"}")
.toObject(UserAssignedIdentity.class);
}