scopes = new ArrayList<>();
+ private RetryPolicy retryPolicy;
+ private RetryOptions retryOptions;
+ private Duration defaultPollInterval;
+
+ private Configurable() {
+ }
+
+ /**
+ * Sets the http client.
+ *
+ * @param httpClient the HTTP client.
+ * @return the configurable object itself.
+ */
+ public Configurable withHttpClient(HttpClient httpClient) {
+ this.httpClient = Objects.requireNonNull(httpClient, "'httpClient' cannot be null.");
+ return this;
+ }
+
+ /**
+ * Sets the logging options to the HTTP pipeline.
+ *
+ * @param httpLogOptions the HTTP log options.
+ * @return the configurable object itself.
+ */
+ public Configurable withLogOptions(HttpLogOptions httpLogOptions) {
+ this.httpLogOptions = Objects.requireNonNull(httpLogOptions, "'httpLogOptions' cannot be null.");
+ return this;
+ }
+
+ /**
+ * Adds the pipeline policy to the HTTP pipeline.
+ *
+ * @param policy the HTTP pipeline policy.
+ * @return the configurable object itself.
+ */
+ public Configurable withPolicy(HttpPipelinePolicy policy) {
+ this.policies.add(Objects.requireNonNull(policy, "'policy' cannot be null."));
+ return this;
+ }
+
+ /**
+ * Adds the scope to permission sets.
+ *
+ * @param scope the scope.
+ * @return the configurable object itself.
+ */
+ public Configurable withScope(String scope) {
+ this.scopes.add(Objects.requireNonNull(scope, "'scope' cannot be null."));
+ return this;
+ }
+
+ /**
+ * Sets the retry policy to the HTTP pipeline.
+ *
+ * @param retryPolicy the HTTP pipeline retry policy.
+ * @return the configurable object itself.
+ */
+ public Configurable withRetryPolicy(RetryPolicy retryPolicy) {
+ this.retryPolicy = Objects.requireNonNull(retryPolicy, "'retryPolicy' cannot be null.");
+ return this;
+ }
+
+ /**
+ * Sets the retry options for the HTTP pipeline retry policy.
+ *
+ * This setting has no effect, if retry policy is set via {@link #withRetryPolicy(RetryPolicy)}.
+ *
+ * @param retryOptions the retry options for the HTTP pipeline retry policy.
+ * @return the configurable object itself.
+ */
+ public Configurable withRetryOptions(RetryOptions retryOptions) {
+ this.retryOptions = Objects.requireNonNull(retryOptions, "'retryOptions' cannot be null.");
+ return this;
+ }
+
+ /**
+ * Sets the default poll interval, used when service does not provide "Retry-After" header.
+ *
+ * @param defaultPollInterval the default poll interval.
+ * @return the configurable object itself.
+ */
+ public Configurable withDefaultPollInterval(Duration defaultPollInterval) {
+ this.defaultPollInterval
+ = Objects.requireNonNull(defaultPollInterval, "'defaultPollInterval' cannot be null.");
+ if (this.defaultPollInterval.isNegative()) {
+ throw LOGGER
+ .logExceptionAsError(new IllegalArgumentException("'defaultPollInterval' cannot be negative"));
+ }
+ return this;
+ }
+
+ /**
+ * Creates an instance of keyvault service API entry point.
+ *
+ * @param credential the credential to use.
+ * @param profile the Azure profile for client.
+ * @return the keyvault service API instance.
+ */
+ public KeyvaultManager authenticate(TokenCredential credential, AzureProfile profile) {
+ Objects.requireNonNull(credential, "'credential' cannot be null.");
+ Objects.requireNonNull(profile, "'profile' cannot be null.");
+
+ String clientVersion = PROPERTIES.getOrDefault(SDK_VERSION, "UnknownVersion");
+
+ StringBuilder userAgentBuilder = new StringBuilder();
+ userAgentBuilder.append("azsdk-java")
+ .append("-")
+ .append("com.azure.resourcemanager.keyvault.generated")
+ .append("/")
+ .append(clientVersion);
+ if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
+ userAgentBuilder.append(" (")
+ .append(Configuration.getGlobalConfiguration().get("java.version"))
+ .append("; ")
+ .append(Configuration.getGlobalConfiguration().get("os.name"))
+ .append("; ")
+ .append(Configuration.getGlobalConfiguration().get("os.version"))
+ .append("; auto-generated)");
+ } else {
+ userAgentBuilder.append(" (auto-generated)");
+ }
+
+ if (scopes.isEmpty()) {
+ scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default");
+ }
+ if (retryPolicy == null) {
+ if (retryOptions != null) {
+ retryPolicy = new RetryPolicy(retryOptions);
+ } else {
+ retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS);
+ }
+ }
+ List policies = new ArrayList<>();
+ policies.add(new UserAgentPolicy(userAgentBuilder.toString()));
+ policies.add(new AddHeadersFromContextPolicy());
+ policies.add(new RequestIdPolicy());
+ policies.addAll(this.policies.stream()
+ .filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_CALL)
+ .collect(Collectors.toList()));
+ HttpPolicyProviders.addBeforeRetryPolicies(policies);
+ policies.add(retryPolicy);
+ policies.add(new AddDatePolicy());
+ policies.add(new BearerTokenAuthenticationPolicy(credential, scopes.toArray(new String[0])));
+ policies.addAll(this.policies.stream()
+ .filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_RETRY)
+ .collect(Collectors.toList()));
+ HttpPolicyProviders.addAfterRetryPolicies(policies);
+ policies.add(new HttpLoggingPolicy(httpLogOptions));
+ HttpPipeline httpPipeline = new HttpPipelineBuilder().httpClient(httpClient)
+ .policies(policies.toArray(new HttpPipelinePolicy[0]))
+ .build();
+ return new KeyvaultManager(httpPipeline, profile, defaultPollInterval);
+ }
+ }
+
+ /**
+ * Gets the resource collection API of Operations.
+ *
+ * @return Resource collection API of Operations.
+ */
+ public Operations operations() {
+ if (this.operations == null) {
+ this.operations = new OperationsImpl(clientObject.getOperations(), this);
+ }
+ return operations;
+ }
+
+ /**
+ * Gets the resource collection API of ManagedHsms. It manages ManagedHsm.
+ *
+ * @return Resource collection API of ManagedHsms.
+ */
+ public ManagedHsms managedHsms() {
+ if (this.managedHsms == null) {
+ this.managedHsms = new ManagedHsmsImpl(clientObject.getManagedHsms(), this);
+ }
+ return managedHsms;
+ }
+
+ /**
+ * Gets the resource collection API of Vaults. It manages Vault.
+ *
+ * @return Resource collection API of Vaults.
+ */
+ public Vaults vaults() {
+ if (this.vaults == null) {
+ this.vaults = new VaultsImpl(clientObject.getVaults(), this);
+ }
+ return vaults;
+ }
+
+ /**
+ * Gets the resource collection API of MhsmPrivateEndpointConnections. It manages MhsmPrivateEndpointConnection.
+ *
+ * @return Resource collection API of MhsmPrivateEndpointConnections.
+ */
+ public MhsmPrivateEndpointConnections mhsmPrivateEndpointConnections() {
+ if (this.mhsmPrivateEndpointConnections == null) {
+ this.mhsmPrivateEndpointConnections
+ = new MhsmPrivateEndpointConnectionsImpl(clientObject.getMhsmPrivateEndpointConnections(), this);
+ }
+ return mhsmPrivateEndpointConnections;
+ }
+
+ /**
+ * Gets the resource collection API of MhsmPrivateLinkResources.
+ *
+ * @return Resource collection API of MhsmPrivateLinkResources.
+ */
+ public MhsmPrivateLinkResources mhsmPrivateLinkResources() {
+ if (this.mhsmPrivateLinkResources == null) {
+ this.mhsmPrivateLinkResources
+ = new MhsmPrivateLinkResourcesImpl(clientObject.getMhsmPrivateLinkResources(), this);
+ }
+ return mhsmPrivateLinkResources;
+ }
+
+ /**
+ * Gets the resource collection API of MhsmRegions.
+ *
+ * @return Resource collection API of MhsmRegions.
+ */
+ public MhsmRegions mhsmRegions() {
+ if (this.mhsmRegions == null) {
+ this.mhsmRegions = new MhsmRegionsImpl(clientObject.getMhsmRegions(), this);
+ }
+ return mhsmRegions;
+ }
+
+ /**
+ * Gets the resource collection API of PrivateEndpointConnections. It manages PrivateEndpointConnection.
+ *
+ * @return Resource collection API of PrivateEndpointConnections.
+ */
+ public PrivateEndpointConnections privateEndpointConnections() {
+ if (this.privateEndpointConnections == null) {
+ this.privateEndpointConnections
+ = new PrivateEndpointConnectionsImpl(clientObject.getPrivateEndpointConnections(), this);
+ }
+ return privateEndpointConnections;
+ }
+
+ /**
+ * Gets the resource collection API of PrivateLinkResources.
+ *
+ * @return Resource collection API of PrivateLinkResources.
+ */
+ public PrivateLinkResources privateLinkResources() {
+ if (this.privateLinkResources == null) {
+ this.privateLinkResources = new PrivateLinkResourcesImpl(clientObject.getPrivateLinkResources(), this);
+ }
+ return privateLinkResources;
+ }
+
+ /**
+ * Gets the resource collection API of Secrets. It manages Secret.
+ *
+ * @return Resource collection API of Secrets.
+ */
+ public Secrets secrets() {
+ if (this.secrets == null) {
+ this.secrets = new SecretsImpl(clientObject.getSecrets(), this);
+ }
+ return secrets;
+ }
+
+ /**
+ * Gets wrapped service client AzureStorageResourceManagementApi providing direct access to the underlying
+ * auto-generated API implementation, based on Azure REST API.
+ *
+ * @return Wrapped service client AzureStorageResourceManagementApi.
+ */
+ public AzureStorageResourceManagementApi serviceClient() {
+ return this.clientObject;
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/AzureStorageResourceManagementApi.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/AzureStorageResourceManagementApi.java
new file mode 100644
index 000000000000..9ba8a39e4797
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/AzureStorageResourceManagementApi.java
@@ -0,0 +1,111 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent;
+
+import com.azure.core.http.HttpPipeline;
+import java.time.Duration;
+
+/**
+ * The interface for AzureStorageResourceManagementApi class.
+ */
+public interface AzureStorageResourceManagementApi {
+ /**
+ * Gets The ID of the target subscription. The value must be an UUID.
+ *
+ * @return the subscriptionId value.
+ */
+ String getSubscriptionId();
+
+ /**
+ * Gets server parameter.
+ *
+ * @return the endpoint value.
+ */
+ String getEndpoint();
+
+ /**
+ * Gets Api Version.
+ *
+ * @return the apiVersion value.
+ */
+ String getApiVersion();
+
+ /**
+ * Gets The HTTP pipeline to send requests through.
+ *
+ * @return the httpPipeline value.
+ */
+ HttpPipeline getHttpPipeline();
+
+ /**
+ * Gets The default poll interval for long-running operation.
+ *
+ * @return the defaultPollInterval value.
+ */
+ Duration getDefaultPollInterval();
+
+ /**
+ * Gets the OperationsClient object to access its operations.
+ *
+ * @return the OperationsClient object.
+ */
+ OperationsClient getOperations();
+
+ /**
+ * Gets the ManagedHsmsClient object to access its operations.
+ *
+ * @return the ManagedHsmsClient object.
+ */
+ ManagedHsmsClient getManagedHsms();
+
+ /**
+ * Gets the VaultsClient object to access its operations.
+ *
+ * @return the VaultsClient object.
+ */
+ VaultsClient getVaults();
+
+ /**
+ * Gets the MhsmPrivateEndpointConnectionsClient object to access its operations.
+ *
+ * @return the MhsmPrivateEndpointConnectionsClient object.
+ */
+ MhsmPrivateEndpointConnectionsClient getMhsmPrivateEndpointConnections();
+
+ /**
+ * Gets the MhsmPrivateLinkResourcesClient object to access its operations.
+ *
+ * @return the MhsmPrivateLinkResourcesClient object.
+ */
+ MhsmPrivateLinkResourcesClient getMhsmPrivateLinkResources();
+
+ /**
+ * Gets the MhsmRegionsClient object to access its operations.
+ *
+ * @return the MhsmRegionsClient object.
+ */
+ MhsmRegionsClient getMhsmRegions();
+
+ /**
+ * Gets the PrivateEndpointConnectionsClient object to access its operations.
+ *
+ * @return the PrivateEndpointConnectionsClient object.
+ */
+ PrivateEndpointConnectionsClient getPrivateEndpointConnections();
+
+ /**
+ * Gets the PrivateLinkResourcesClient object to access its operations.
+ *
+ * @return the PrivateLinkResourcesClient object.
+ */
+ PrivateLinkResourcesClient getPrivateLinkResources();
+
+ /**
+ * Gets the SecretsClient object to access its operations.
+ *
+ * @return the SecretsClient object.
+ */
+ SecretsClient getSecrets();
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/ManagedHsmsClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/ManagedHsmsClient.java
new file mode 100644
index 000000000000..8bffcc2db157
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/ManagedHsmsClient.java
@@ -0,0 +1,399 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.CheckMhsmNameAvailabilityResultInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.DeletedManagedHsmInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.ManagedHsmInner;
+import com.azure.resourcemanager.keyvault.generated.models.CheckMhsmNameAvailabilityParameters;
+
+/**
+ * An instance of this class provides access to all the operations defined in ManagedHsmsClient.
+ */
+public interface ManagedHsmsClient {
+ /**
+ * Checks that the managed hsm name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckMhsmNameAvailability operation response along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response
+ checkMhsmNameAvailabilityWithResponse(CheckMhsmNameAvailabilityParameters body, Context context);
+
+ /**
+ * Checks that the managed hsm name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckMhsmNameAvailability operation response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ CheckMhsmNameAvailabilityResultInner checkMhsmNameAvailability(CheckMhsmNameAvailabilityParameters body);
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list();
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(Context context);
+
+ /**
+ * Gets the specified deleted managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 specified deleted managed HSM along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getDeletedWithResponse(String location, String name, Context context);
+
+ /**
+ * Gets the specified deleted managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 specified deleted managed HSM.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ DeletedManagedHsmInner getDeleted(String location, String name);
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginPurgeDeleted(String location, String name);
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginPurgeDeleted(String location, String name, Context context);
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 purgeDeleted(String location, String name);
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void purgeDeleted(String location, String name, Context context);
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listBySubscription();
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listBySubscription(Integer top, Context context);
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName);
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName, Integer top, Context context);
+
+ /**
+ * Gets the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 specified managed HSM Pool along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getByResourceGroupWithResponse(String resourceGroupName, String name, Context context);
+
+ /**
+ * Gets the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 specified managed HSM Pool.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ManagedHsmInner getByResourceGroup(String resourceGroupName, String name);
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ManagedHsmInner> beginCreateOrUpdate(String resourceGroupName, String name,
+ ManagedHsmInner resource);
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ManagedHsmInner> beginCreateOrUpdate(String resourceGroupName, String name,
+ ManagedHsmInner resource, Context context);
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ManagedHsmInner createOrUpdate(String resourceGroupName, String name, ManagedHsmInner resource);
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ManagedHsmInner createOrUpdate(String resourceGroupName, String name, ManagedHsmInner resource, Context context);
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ManagedHsmInner> beginUpdate(String resourceGroupName, String name,
+ ManagedHsmInner properties);
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ManagedHsmInner> beginUpdate(String resourceGroupName, String name,
+ ManagedHsmInner properties, Context context);
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ManagedHsmInner update(String resourceGroupName, String name, ManagedHsmInner properties);
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ManagedHsmInner update(String resourceGroupName, String name, ManagedHsmInner properties, Context context);
+
+ /**
+ * Deletes the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(String resourceGroupName, String name);
+
+ /**
+ * Deletes the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(String resourceGroupName, String name, Context context);
+
+ /**
+ * Deletes the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 name);
+
+ /**
+ * Deletes the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String name, Context context);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmPrivateEndpointConnectionsClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmPrivateEndpointConnectionsClient.java
new file mode 100644
index 000000000000..255e9917d5ba
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmPrivateEndpointConnectionsClient.java
@@ -0,0 +1,183 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.MhsmPrivateEndpointConnectionInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in MhsmPrivateEndpointConnectionsClient.
+ */
+public interface MhsmPrivateEndpointConnectionsClient {
+ /**
+ * The List operation gets information about the private endpoint connections associated with the managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 response of a MhsmPrivateEndpointConnection list operation as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResource(String resourceGroupName, String name);
+
+ /**
+ * The List operation gets information about the private endpoint connections associated with the managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 response of a MhsmPrivateEndpointConnection list operation as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResource(String resourceGroupName, String name,
+ Context context);
+
+ /**
+ * Gets the specified private endpoint connection associated with the managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @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 specified private endpoint connection associated with the managed HSM Pool along with
+ * {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String resourceGroupName, String name,
+ String privateEndpointConnectionName, Context context);
+
+ /**
+ * Gets the specified private endpoint connection associated with the managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @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 specified private endpoint connection associated with the managed HSM Pool.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ MhsmPrivateEndpointConnectionInner get(String resourceGroupName, String name, String privateEndpointConnectionName);
+
+ /**
+ * Updates the specified private endpoint connection associated with the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @param resource The intended state of private endpoint connection.
+ * @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 private endpoint connection resource along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response putWithResponse(String resourceGroupName, String name,
+ String privateEndpointConnectionName, MhsmPrivateEndpointConnectionInner resource, Context context);
+
+ /**
+ * Updates the specified private endpoint connection associated with the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @param resource The intended state of private endpoint connection.
+ * @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 private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ MhsmPrivateEndpointConnectionInner put(String resourceGroupName, String name, String privateEndpointConnectionName,
+ MhsmPrivateEndpointConnectionInner resource);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @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 SyncPoller} for polling of private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, MhsmPrivateEndpointConnectionInner>
+ beginDelete(String resourceGroupName, String name, String privateEndpointConnectionName);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @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 SyncPoller} for polling of private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, MhsmPrivateEndpointConnectionInner>
+ beginDelete(String resourceGroupName, String name, String privateEndpointConnectionName, Context context);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @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 private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ MhsmPrivateEndpointConnectionInner delete(String resourceGroupName, String name,
+ String privateEndpointConnectionName);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the managed hsm
+ * pool.
+ * @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 private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ MhsmPrivateEndpointConnectionInner delete(String resourceGroupName, String name,
+ String privateEndpointConnectionName, Context context);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmPrivateLinkResourcesClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmPrivateLinkResourcesClient.java
new file mode 100644
index 000000000000..4b654c49fa3e
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmPrivateLinkResourcesClient.java
@@ -0,0 +1,44 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.http.rest.Response;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.MhsmPrivateLinkResourceListResultInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in MhsmPrivateLinkResourcesClient.
+ */
+public interface MhsmPrivateLinkResourcesClient {
+ /**
+ * Gets the private link resources supported for the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 private link resources supported for the managed hsm pool along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response listByMhsmResourceWithResponse(String resourceGroupName,
+ String name, Context context);
+
+ /**
+ * Gets the private link resources supported for the managed hsm pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 private link resources supported for the managed hsm pool.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ MhsmPrivateLinkResourceListResultInner listByMhsmResource(String resourceGroupName, String name);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmRegionsClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmRegionsClient.java
new file mode 100644
index 000000000000..2ba97ce0273b
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/MhsmRegionsClient.java
@@ -0,0 +1,43 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.MhsmGeoReplicatedRegionInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in MhsmRegionsClient.
+ */
+public interface MhsmRegionsClient {
+ /**
+ * The List operation gets information about the regions associated with the managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 list of regions associated with a managed HSM Pools as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResource(String resourceGroupName, String name);
+
+ /**
+ * The List operation gets information about the regions associated with the managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 list of regions associated with a managed HSM Pools as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResource(String resourceGroupName, String name, Context context);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/OperationsClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/OperationsClient.java
new file mode 100644
index 000000000000..4358c47f0b99
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/OperationsClient.java
@@ -0,0 +1,40 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.OperationInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in OperationsClient.
+ */
+public interface OperationsClient {
+ /**
+ * List the operations for the provider.
+ *
+ * @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 list of REST API operations supported by an Azure Resource Provider as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list();
+
+ /**
+ * List the operations for the provider.
+ *
+ * @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 list of REST API operations supported by an Azure Resource Provider as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(Context context);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/PrivateEndpointConnectionsClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/PrivateEndpointConnectionsClient.java
new file mode 100644
index 000000000000..0f5768a95a11
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/PrivateEndpointConnectionsClient.java
@@ -0,0 +1,175 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.PrivateEndpointConnectionInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in PrivateEndpointConnectionsClient.
+ */
+public interface PrivateEndpointConnectionsClient {
+ /**
+ * The List operation gets information about the private endpoint connections associated with the vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 response of a PrivateEndpointConnection list operation as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResource(String resourceGroupName, String vaultName);
+
+ /**
+ * The List operation gets information about the private endpoint connections associated with the vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 response of a PrivateEndpointConnection list operation as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResource(String resourceGroupName, String vaultName,
+ Context context);
+
+ /**
+ * Gets the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @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 specified private endpoint connection associated with the key vault along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String resourceGroupName, String vaultName,
+ String privateEndpointConnectionName, Context context);
+
+ /**
+ * Gets the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @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 specified private endpoint connection associated with the key vault.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner get(String resourceGroupName, String vaultName,
+ String privateEndpointConnectionName);
+
+ /**
+ * Updates the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @param resource The intended state of private endpoint connection.
+ * @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 private endpoint connection resource along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response putWithResponse(String resourceGroupName, String vaultName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner resource, Context context);
+
+ /**
+ * Updates the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @param resource The intended state of private endpoint connection.
+ * @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 private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner put(String resourceGroupName, String vaultName, String privateEndpointConnectionName,
+ PrivateEndpointConnectionInner resource);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @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 SyncPoller} for polling of private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, PrivateEndpointConnectionInner>
+ beginDelete(String resourceGroupName, String vaultName, String privateEndpointConnectionName);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @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 SyncPoller} for polling of private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, PrivateEndpointConnectionInner>
+ beginDelete(String resourceGroupName, String vaultName, String privateEndpointConnectionName, Context context);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @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 private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner delete(String resourceGroupName, String vaultName,
+ String privateEndpointConnectionName);
+
+ /**
+ * Deletes the specified private endpoint connection associated with the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param privateEndpointConnectionName Name of the private endpoint connection associated with the key vault.
+ * @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 private endpoint connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner delete(String resourceGroupName, String vaultName,
+ String privateEndpointConnectionName, Context context);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/PrivateLinkResourcesClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/PrivateLinkResourcesClient.java
new file mode 100644
index 000000000000..8ef76dce1f01
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/PrivateLinkResourcesClient.java
@@ -0,0 +1,44 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.http.rest.Response;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.PrivateLinkResourceListResultInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in PrivateLinkResourcesClient.
+ */
+public interface PrivateLinkResourcesClient {
+ /**
+ * Gets the private link resources supported for the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 private link resources supported for the key vault along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response listByVaultWithResponse(String resourceGroupName, String vaultName,
+ Context context);
+
+ /**
+ * Gets the private link resources supported for the key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 private link resources supported for the key vault.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateLinkResourceListResultInner listByVault(String resourceGroupName, String vaultName);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/SecretsClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/SecretsClient.java
new file mode 100644
index 000000000000..c0d980d13c24
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/SecretsClient.java
@@ -0,0 +1,148 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.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.keyvault.generated.fluent.models.SecretInner;
+import com.azure.resourcemanager.keyvault.generated.models.SecretPatchParameters;
+
+/**
+ * An instance of this class provides access to all the operations defined in SecretsClient.
+ */
+public interface SecretsClient {
+ /**
+ * The List operation gets information about the secrets in a vault. NOTE: This API is intended for internal use in
+ * ARM deployments. Users should use the data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 response of a Secret list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String vaultName);
+
+ /**
+ * The List operation gets information about the secrets in a vault. NOTE: This API is intended for internal use in
+ * ARM deployments. Users should use the data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param top Maximum number of results to return.
+ * @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 response of a Secret list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String resourceGroupName, String vaultName, Integer top, Context context);
+
+ /**
+ * Gets the specified secret. NOTE: This API is intended for internal use in ARM deployments. Users should use the
+ * data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param secretName The name of the secret.
+ * @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 specified secret along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String resourceGroupName, String vaultName, String secretName,
+ Context context);
+
+ /**
+ * Gets the specified secret. NOTE: This API is intended for internal use in ARM deployments. Users should use the
+ * data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param secretName The name of the secret.
+ * @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 specified secret.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ SecretInner get(String resourceGroupName, String vaultName, String secretName);
+
+ /**
+ * Create or update a secret in a key vault in the specified subscription. NOTE: This API is intended for internal
+ * use in ARM deployments. Users should use the data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param secretName The name of the secret.
+ * @param resource Parameters to create or update the secret.
+ * @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 resource information with extended details along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response createOrUpdateWithResponse(String resourceGroupName, String vaultName, String secretName,
+ SecretInner resource, Context context);
+
+ /**
+ * Create or update a secret in a key vault in the specified subscription. NOTE: This API is intended for internal
+ * use in ARM deployments. Users should use the data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param secretName The name of the secret.
+ * @param resource Parameters to create or update the secret.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ SecretInner createOrUpdate(String resourceGroupName, String vaultName, String secretName, SecretInner resource);
+
+ /**
+ * Update a secret in the specified subscription. NOTE: This API is intended for internal use in ARM deployments.
+ * Users should use the data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param secretName The name of the secret.
+ * @param properties Parameters to patch the secret.
+ * @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 resource information with extended details along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response updateWithResponse(String resourceGroupName, String vaultName, String secretName,
+ SecretPatchParameters properties, Context context);
+
+ /**
+ * Update a secret in the specified subscription. NOTE: This API is intended for internal use in ARM deployments.
+ * Users should use the data-plane REST service for interaction with vault secrets.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param secretName The name of the secret.
+ * @param properties Parameters to patch the secret.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ SecretInner update(String resourceGroupName, String vaultName, String secretName, SecretPatchParameters properties);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/VaultsClient.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/VaultsClient.java
new file mode 100644
index 000000000000..af10ad3330c2
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/VaultsClient.java
@@ -0,0 +1,380 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.CheckNameAvailabilityResultInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.DeletedVaultInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.VaultAccessPolicyParametersInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.VaultInner;
+import com.azure.resourcemanager.keyvault.generated.models.AccessPolicyUpdateKind;
+import com.azure.resourcemanager.keyvault.generated.models.VaultCheckNameAvailabilityParameters;
+import com.azure.resourcemanager.keyvault.generated.models.VaultPatchParameters;
+import com.azure.resourcemanager.keyvault.generated.models.VaultsUpdateAccessPolicyResponse;
+
+/**
+ * An instance of this class provides access to all the operations defined in VaultsClient.
+ */
+public interface VaultsClient {
+ /**
+ * Checks that the vault name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckNameAvailability operation response along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response
+ checkNameAvailabilityWithResponse(VaultCheckNameAvailabilityParameters body, Context context);
+
+ /**
+ * Checks that the vault name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckNameAvailability operation response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ CheckNameAvailabilityResultInner checkNameAvailability(VaultCheckNameAvailabilityParameters body);
+
+ /**
+ * Gets information about the deleted vaults in a subscription.
+ *
+ * @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 information about the deleted vaults in a subscription as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list();
+
+ /**
+ * Gets information about the deleted vaults in a subscription.
+ *
+ * @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 information about the deleted vaults in a subscription as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(Context context);
+
+ /**
+ * Gets the deleted Azure key vault.
+ *
+ * @param location The name of the Azure region.
+ * @param vaultName The name of the vault.
+ * @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 deleted Azure key vault along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getDeletedWithResponse(String location, String vaultName, Context context);
+
+ /**
+ * Gets the deleted Azure key vault.
+ *
+ * @param location The name of the Azure region.
+ * @param vaultName The name of the vault.
+ * @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 deleted Azure key vault.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ DeletedVaultInner getDeleted(String location, String vaultName);
+
+ /**
+ * Permanently deletes the specified vault. aka Purges the deleted Azure key vault.
+ *
+ * @param location The name of the Azure region.
+ * @param vaultName The name of the vault.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginPurgeDeleted(String location, String vaultName);
+
+ /**
+ * Permanently deletes the specified vault. aka Purges the deleted Azure key vault.
+ *
+ * @param location The name of the Azure region.
+ * @param vaultName The name of the vault.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginPurgeDeleted(String location, String vaultName, Context context);
+
+ /**
+ * Permanently deletes the specified vault. aka Purges the deleted Azure key vault.
+ *
+ * @param location The name of the Azure region.
+ * @param vaultName The name of the vault.
+ * @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 purgeDeleted(String location, String vaultName);
+
+ /**
+ * Permanently deletes the specified vault. aka Purges the deleted Azure key vault.
+ *
+ * @param location The name of the Azure region.
+ * @param vaultName The name of the vault.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void purgeDeleted(String location, String vaultName, Context context);
+
+ /**
+ * The List operation gets information about the vaults associated with the subscription.
+ *
+ * @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 response of a Vault list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listBySubscription();
+
+ /**
+ * The List operation gets information about the vaults associated with the subscription.
+ *
+ * @param top Maximum number of results to return.
+ * @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 response of a Vault list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listBySubscription(Integer top, Context context);
+
+ /**
+ * The List operation gets information about the vaults associated with the subscription and within the specified
+ * resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 response of a Vault list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName);
+
+ /**
+ * The List operation gets information about the vaults associated with the subscription and within the specified
+ * resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param top Maximum number of results to return.
+ * @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 response of a Vault list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName, Integer top, Context context);
+
+ /**
+ * Gets the specified Azure key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 specified Azure key vault along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getByResourceGroupWithResponse(String resourceGroupName, String vaultName, Context context);
+
+ /**
+ * Gets the specified Azure key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 specified Azure key vault.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VaultInner getByResourceGroup(String resourceGroupName, String vaultName);
+
+ /**
+ * Create or update a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param resource Parameters to create or update the vault.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, VaultInner> beginCreateOrUpdate(String resourceGroupName, String vaultName,
+ VaultInner resource);
+
+ /**
+ * Create or update a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param resource Parameters to create or update the vault.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, VaultInner> beginCreateOrUpdate(String resourceGroupName, String vaultName,
+ VaultInner resource, Context context);
+
+ /**
+ * Create or update a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param resource Parameters to create or update the vault.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VaultInner createOrUpdate(String resourceGroupName, String vaultName, VaultInner resource);
+
+ /**
+ * Create or update a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param resource Parameters to create or update the vault.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VaultInner createOrUpdate(String resourceGroupName, String vaultName, VaultInner resource, Context context);
+
+ /**
+ * Update a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param properties Parameters to patch the vault.
+ * @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 resource information with extended details along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response updateWithResponse(String resourceGroupName, String vaultName, VaultPatchParameters properties,
+ Context context);
+
+ /**
+ * Update a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param properties Parameters to patch the vault.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VaultInner update(String resourceGroupName, String vaultName, VaultPatchParameters properties);
+
+ /**
+ * Deletes the specified Azure key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 vaultName, Context context);
+
+ /**
+ * Deletes the specified Azure key vault.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @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 vaultName);
+
+ /**
+ * Update access policies in a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param operationKind Name of the operation.
+ * @param body Access policy to merge into the vault.
+ * @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 parameters for updating the access policy in a vault.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VaultsUpdateAccessPolicyResponse updateAccessPolicyWithResponse(String resourceGroupName, String vaultName,
+ AccessPolicyUpdateKind operationKind, VaultAccessPolicyParametersInner body, Context context);
+
+ /**
+ * Update access policies in a key vault in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param vaultName The name of the vault.
+ * @param operationKind Name of the operation.
+ * @param body Access policy to merge into the vault.
+ * @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 parameters for updating the access policy in a vault.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ VaultAccessPolicyParametersInner updateAccessPolicy(String resourceGroupName, String vaultName,
+ AccessPolicyUpdateKind operationKind, VaultAccessPolicyParametersInner body);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/CheckMhsmNameAvailabilityResultInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/CheckMhsmNameAvailabilityResultInner.java
new file mode 100644
index 000000000000..ab83dd91ff49
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/CheckMhsmNameAvailabilityResultInner.java
@@ -0,0 +1,121 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.Reason;
+import java.io.IOException;
+
+/**
+ * The CheckMhsmNameAvailability operation response.
+ */
+@Immutable
+public final class CheckMhsmNameAvailabilityResultInner
+ implements JsonSerializable {
+ /*
+ * A boolean value that indicates whether the name is available for you to use. If true, the name is available. If
+ * false, the name has already been taken or is invalid and cannot be used.
+ */
+ private Boolean nameAvailable;
+
+ /*
+ * The reason that a managed hsm name could not be used. The reason element is only returned if NameAvailable is
+ * false.
+ */
+ private Reason reason;
+
+ /*
+ * An error message explaining the Reason value in more detail.
+ */
+ private String message;
+
+ /**
+ * Creates an instance of CheckMhsmNameAvailabilityResultInner class.
+ */
+ public CheckMhsmNameAvailabilityResultInner() {
+ }
+
+ /**
+ * Get the nameAvailable property: A boolean value that indicates whether the name is available for you to use. If
+ * true, the name is available. If false, the name has already been taken or is invalid and cannot be used.
+ *
+ * @return the nameAvailable value.
+ */
+ public Boolean nameAvailable() {
+ return this.nameAvailable;
+ }
+
+ /**
+ * Get the reason property: The reason that a managed hsm name could not be used. The reason element is only
+ * returned if NameAvailable is false.
+ *
+ * @return the reason value.
+ */
+ public Reason reason() {
+ return this.reason;
+ }
+
+ /**
+ * Get the message property: An error message explaining the Reason value in more detail.
+ *
+ * @return the message value.
+ */
+ public String message() {
+ return this.message;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of CheckMhsmNameAvailabilityResultInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of CheckMhsmNameAvailabilityResultInner if the JsonReader was pointing to an instance of it,
+ * or null if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the CheckMhsmNameAvailabilityResultInner.
+ */
+ public static CheckMhsmNameAvailabilityResultInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ CheckMhsmNameAvailabilityResultInner deserializedCheckMhsmNameAvailabilityResultInner
+ = new CheckMhsmNameAvailabilityResultInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("nameAvailable".equals(fieldName)) {
+ deserializedCheckMhsmNameAvailabilityResultInner.nameAvailable
+ = reader.getNullable(JsonReader::getBoolean);
+ } else if ("reason".equals(fieldName)) {
+ deserializedCheckMhsmNameAvailabilityResultInner.reason = Reason.fromString(reader.getString());
+ } else if ("message".equals(fieldName)) {
+ deserializedCheckMhsmNameAvailabilityResultInner.message = reader.getString();
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedCheckMhsmNameAvailabilityResultInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/CheckNameAvailabilityResultInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/CheckNameAvailabilityResultInner.java
new file mode 100644
index 000000000000..67aa84516ec5
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/CheckNameAvailabilityResultInner.java
@@ -0,0 +1,120 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.KeyVaultNameUnavailableReason;
+import java.io.IOException;
+
+/**
+ * The CheckNameAvailability operation response.
+ */
+@Immutable
+public final class CheckNameAvailabilityResultInner implements JsonSerializable {
+ /*
+ * A boolean value that indicates whether the name is available for you to use. If true, the name is available. If
+ * false, the name has already been taken or is invalid and cannot be used.
+ */
+ private Boolean nameAvailable;
+
+ /*
+ * The reason that a vault name could not be used. The Reason element is only returned if NameAvailable is false.
+ */
+ private KeyVaultNameUnavailableReason reason;
+
+ /*
+ * An error message explaining the Reason value in more detail.
+ */
+ private String message;
+
+ /**
+ * Creates an instance of CheckNameAvailabilityResultInner class.
+ */
+ public CheckNameAvailabilityResultInner() {
+ }
+
+ /**
+ * Get the nameAvailable property: A boolean value that indicates whether the name is available for you to use. If
+ * true, the name is available. If false, the name has already been taken or is invalid and cannot be used.
+ *
+ * @return the nameAvailable value.
+ */
+ public Boolean nameAvailable() {
+ return this.nameAvailable;
+ }
+
+ /**
+ * Get the reason property: The reason that a vault name could not be used. The Reason element is only returned if
+ * NameAvailable is false.
+ *
+ * @return the reason value.
+ */
+ public KeyVaultNameUnavailableReason reason() {
+ return this.reason;
+ }
+
+ /**
+ * Get the message property: An error message explaining the Reason value in more detail.
+ *
+ * @return the message value.
+ */
+ public String message() {
+ return this.message;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of CheckNameAvailabilityResultInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of CheckNameAvailabilityResultInner if the JsonReader was pointing to an instance of it, or
+ * null if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the CheckNameAvailabilityResultInner.
+ */
+ public static CheckNameAvailabilityResultInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ CheckNameAvailabilityResultInner deserializedCheckNameAvailabilityResultInner
+ = new CheckNameAvailabilityResultInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("nameAvailable".equals(fieldName)) {
+ deserializedCheckNameAvailabilityResultInner.nameAvailable
+ = reader.getNullable(JsonReader::getBoolean);
+ } else if ("reason".equals(fieldName)) {
+ deserializedCheckNameAvailabilityResultInner.reason
+ = KeyVaultNameUnavailableReason.fromString(reader.getString());
+ } else if ("message".equals(fieldName)) {
+ deserializedCheckNameAvailabilityResultInner.message = reader.getString();
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedCheckNameAvailabilityResultInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedManagedHsmInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedManagedHsmInner.java
new file mode 100644
index 000000000000..e9e7ee8aa62a
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedManagedHsmInner.java
@@ -0,0 +1,210 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.management.ProxyResource;
+import com.azure.core.management.SystemData;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import java.io.IOException;
+import java.time.OffsetDateTime;
+import java.util.Map;
+
+/**
+ * Concrete proxy resource types can be created by aliasing this type using a specific property type.
+ */
+@Immutable
+public final class DeletedManagedHsmInner extends ProxyResource {
+ /*
+ * Properties of the deleted managed HSM
+ */
+ private DeletedManagedHsmProperties innerProperties;
+
+ /*
+ * Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ */
+ private SystemData systemData;
+
+ /*
+ * The type of the resource.
+ */
+ private String type;
+
+ /*
+ * The name of the resource.
+ */
+ private String name;
+
+ /*
+ * Fully qualified resource Id for the resource.
+ */
+ private String id;
+
+ /**
+ * Creates an instance of DeletedManagedHsmInner class.
+ */
+ public DeletedManagedHsmInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Properties of the deleted managed HSM.
+ *
+ * @return the innerProperties value.
+ */
+ private DeletedManagedHsmProperties 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 type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ @Override
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ @Override
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ @Override
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * Get the mhsmId property: The resource id of the original managed HSM.
+ *
+ * @return the mhsmId value.
+ */
+ public String mhsmId() {
+ return this.innerProperties() == null ? null : this.innerProperties().mhsmId();
+ }
+
+ /**
+ * Get the location property: The location of the original managed HSM.
+ *
+ * @return the location value.
+ */
+ public String location() {
+ return this.innerProperties() == null ? null : this.innerProperties().location();
+ }
+
+ /**
+ * Get the deletionDate property: The deleted date.
+ *
+ * @return the deletionDate value.
+ */
+ public OffsetDateTime deletionDate() {
+ return this.innerProperties() == null ? null : this.innerProperties().deletionDate();
+ }
+
+ /**
+ * Get the scheduledPurgeDate property: The scheduled purged date.
+ *
+ * @return the scheduledPurgeDate value.
+ */
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.innerProperties() == null ? null : this.innerProperties().scheduledPurgeDate();
+ }
+
+ /**
+ * Get the purgeProtectionEnabled property: Purge protection status of the original managed HSM.
+ *
+ * @return the purgeProtectionEnabled value.
+ */
+ public Boolean purgeProtectionEnabled() {
+ return this.innerProperties() == null ? null : this.innerProperties().purgeProtectionEnabled();
+ }
+
+ /**
+ * Get the tags property: Tags of the original managed HSM.
+ *
+ * @return the tags value.
+ */
+ public Map tags() {
+ return this.innerProperties() == null ? null : this.innerProperties().tags();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeJsonField("properties", this.innerProperties);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of DeletedManagedHsmInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of DeletedManagedHsmInner if the JsonReader was pointing to an instance of it, or null if it
+ * was pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the DeletedManagedHsmInner.
+ */
+ public static DeletedManagedHsmInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ DeletedManagedHsmInner deserializedDeletedManagedHsmInner = new DeletedManagedHsmInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedDeletedManagedHsmInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedDeletedManagedHsmInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedDeletedManagedHsmInner.type = reader.getString();
+ } else if ("properties".equals(fieldName)) {
+ deserializedDeletedManagedHsmInner.innerProperties = DeletedManagedHsmProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedDeletedManagedHsmInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedDeletedManagedHsmInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedManagedHsmProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedManagedHsmProperties.java
new file mode 100644
index 000000000000..c01efda07a63
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedManagedHsmProperties.java
@@ -0,0 +1,168 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.CoreUtils;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import java.io.IOException;
+import java.time.OffsetDateTime;
+import java.util.Map;
+
+/**
+ * Properties of the deleted managed HSM.
+ */
+@Immutable
+public final class DeletedManagedHsmProperties implements JsonSerializable {
+ /*
+ * The resource id of the original managed HSM.
+ */
+ private String mhsmId;
+
+ /*
+ * The location of the original managed HSM.
+ */
+ private String location;
+
+ /*
+ * The deleted date.
+ */
+ private OffsetDateTime deletionDate;
+
+ /*
+ * The scheduled purged date.
+ */
+ private OffsetDateTime scheduledPurgeDate;
+
+ /*
+ * Purge protection status of the original managed HSM.
+ */
+ private Boolean purgeProtectionEnabled;
+
+ /*
+ * Tags of the original managed HSM.
+ */
+ private Map tags;
+
+ /**
+ * Creates an instance of DeletedManagedHsmProperties class.
+ */
+ public DeletedManagedHsmProperties() {
+ }
+
+ /**
+ * Get the mhsmId property: The resource id of the original managed HSM.
+ *
+ * @return the mhsmId value.
+ */
+ public String mhsmId() {
+ return this.mhsmId;
+ }
+
+ /**
+ * Get the location property: The location of the original managed HSM.
+ *
+ * @return the location value.
+ */
+ public String location() {
+ return this.location;
+ }
+
+ /**
+ * Get the deletionDate property: The deleted date.
+ *
+ * @return the deletionDate value.
+ */
+ public OffsetDateTime deletionDate() {
+ return this.deletionDate;
+ }
+
+ /**
+ * Get the scheduledPurgeDate property: The scheduled purged date.
+ *
+ * @return the scheduledPurgeDate value.
+ */
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.scheduledPurgeDate;
+ }
+
+ /**
+ * Get the purgeProtectionEnabled property: Purge protection status of the original managed HSM.
+ *
+ * @return the purgeProtectionEnabled value.
+ */
+ public Boolean purgeProtectionEnabled() {
+ return this.purgeProtectionEnabled;
+ }
+
+ /**
+ * Get the tags property: Tags of the original managed HSM.
+ *
+ * @return the tags value.
+ */
+ public Map tags() {
+ return this.tags;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of DeletedManagedHsmProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of DeletedManagedHsmProperties if the JsonReader was pointing to an instance of it, or null
+ * if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the DeletedManagedHsmProperties.
+ */
+ public static DeletedManagedHsmProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ DeletedManagedHsmProperties deserializedDeletedManagedHsmProperties = new DeletedManagedHsmProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("mhsmId".equals(fieldName)) {
+ deserializedDeletedManagedHsmProperties.mhsmId = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedDeletedManagedHsmProperties.location = reader.getString();
+ } else if ("deletionDate".equals(fieldName)) {
+ deserializedDeletedManagedHsmProperties.deletionDate = reader
+ .getNullable(nonNullReader -> CoreUtils.parseBestOffsetDateTime(nonNullReader.getString()));
+ } else if ("scheduledPurgeDate".equals(fieldName)) {
+ deserializedDeletedManagedHsmProperties.scheduledPurgeDate = reader
+ .getNullable(nonNullReader -> CoreUtils.parseBestOffsetDateTime(nonNullReader.getString()));
+ } else if ("purgeProtectionEnabled".equals(fieldName)) {
+ deserializedDeletedManagedHsmProperties.purgeProtectionEnabled
+ = reader.getNullable(JsonReader::getBoolean);
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedDeletedManagedHsmProperties.tags = tags;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedDeletedManagedHsmProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedVaultInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedVaultInner.java
new file mode 100644
index 000000000000..b4feb5d71f76
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedVaultInner.java
@@ -0,0 +1,210 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.management.ProxyResource;
+import com.azure.core.management.SystemData;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import java.io.IOException;
+import java.time.OffsetDateTime;
+import java.util.Map;
+
+/**
+ * Deleted vault information with extended details.
+ */
+@Immutable
+public final class DeletedVaultInner extends ProxyResource {
+ /*
+ * Properties of the vault
+ */
+ private DeletedVaultProperties innerProperties;
+
+ /*
+ * Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ */
+ private SystemData systemData;
+
+ /*
+ * The type of the resource.
+ */
+ private String type;
+
+ /*
+ * The name of the resource.
+ */
+ private String name;
+
+ /*
+ * Fully qualified resource Id for the resource.
+ */
+ private String id;
+
+ /**
+ * Creates an instance of DeletedVaultInner class.
+ */
+ public DeletedVaultInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Properties of the vault.
+ *
+ * @return the innerProperties value.
+ */
+ private DeletedVaultProperties 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 type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ @Override
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ @Override
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ @Override
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * Get the vaultId property: The resource id of the original vault.
+ *
+ * @return the vaultId value.
+ */
+ public String vaultId() {
+ return this.innerProperties() == null ? null : this.innerProperties().vaultId();
+ }
+
+ /**
+ * Get the location property: The location of the original vault.
+ *
+ * @return the location value.
+ */
+ public String location() {
+ return this.innerProperties() == null ? null : this.innerProperties().location();
+ }
+
+ /**
+ * Get the deletionDate property: The deleted date.
+ *
+ * @return the deletionDate value.
+ */
+ public OffsetDateTime deletionDate() {
+ return this.innerProperties() == null ? null : this.innerProperties().deletionDate();
+ }
+
+ /**
+ * Get the scheduledPurgeDate property: The scheduled purged date.
+ *
+ * @return the scheduledPurgeDate value.
+ */
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.innerProperties() == null ? null : this.innerProperties().scheduledPurgeDate();
+ }
+
+ /**
+ * Get the tags property: Tags of the original vault.
+ *
+ * @return the tags value.
+ */
+ public Map tags() {
+ return this.innerProperties() == null ? null : this.innerProperties().tags();
+ }
+
+ /**
+ * Get the purgeProtectionEnabled property: Purge protection status of the original vault.
+ *
+ * @return the purgeProtectionEnabled value.
+ */
+ public Boolean purgeProtectionEnabled() {
+ return this.innerProperties() == null ? null : this.innerProperties().purgeProtectionEnabled();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeJsonField("properties", this.innerProperties);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of DeletedVaultInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of DeletedVaultInner if the JsonReader was pointing to an instance of it, or null if it was
+ * pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the DeletedVaultInner.
+ */
+ public static DeletedVaultInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ DeletedVaultInner deserializedDeletedVaultInner = new DeletedVaultInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedDeletedVaultInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedDeletedVaultInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedDeletedVaultInner.type = reader.getString();
+ } else if ("properties".equals(fieldName)) {
+ deserializedDeletedVaultInner.innerProperties = DeletedVaultProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedDeletedVaultInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedDeletedVaultInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedVaultProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedVaultProperties.java
new file mode 100644
index 000000000000..c0c340a88299
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/DeletedVaultProperties.java
@@ -0,0 +1,168 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.CoreUtils;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import java.io.IOException;
+import java.time.OffsetDateTime;
+import java.util.Map;
+
+/**
+ * Properties of the deleted vault.
+ */
+@Immutable
+public final class DeletedVaultProperties implements JsonSerializable {
+ /*
+ * The resource id of the original vault.
+ */
+ private String vaultId;
+
+ /*
+ * The location of the original vault.
+ */
+ private String location;
+
+ /*
+ * The deleted date.
+ */
+ private OffsetDateTime deletionDate;
+
+ /*
+ * The scheduled purged date.
+ */
+ private OffsetDateTime scheduledPurgeDate;
+
+ /*
+ * Tags of the original vault.
+ */
+ private Map tags;
+
+ /*
+ * Purge protection status of the original vault.
+ */
+ private Boolean purgeProtectionEnabled;
+
+ /**
+ * Creates an instance of DeletedVaultProperties class.
+ */
+ public DeletedVaultProperties() {
+ }
+
+ /**
+ * Get the vaultId property: The resource id of the original vault.
+ *
+ * @return the vaultId value.
+ */
+ public String vaultId() {
+ return this.vaultId;
+ }
+
+ /**
+ * Get the location property: The location of the original vault.
+ *
+ * @return the location value.
+ */
+ public String location() {
+ return this.location;
+ }
+
+ /**
+ * Get the deletionDate property: The deleted date.
+ *
+ * @return the deletionDate value.
+ */
+ public OffsetDateTime deletionDate() {
+ return this.deletionDate;
+ }
+
+ /**
+ * Get the scheduledPurgeDate property: The scheduled purged date.
+ *
+ * @return the scheduledPurgeDate value.
+ */
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.scheduledPurgeDate;
+ }
+
+ /**
+ * Get the tags property: Tags of the original vault.
+ *
+ * @return the tags value.
+ */
+ public Map tags() {
+ return this.tags;
+ }
+
+ /**
+ * Get the purgeProtectionEnabled property: Purge protection status of the original vault.
+ *
+ * @return the purgeProtectionEnabled value.
+ */
+ public Boolean purgeProtectionEnabled() {
+ return this.purgeProtectionEnabled;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of DeletedVaultProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of DeletedVaultProperties if the JsonReader was pointing to an instance of it, or null if it
+ * was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the DeletedVaultProperties.
+ */
+ public static DeletedVaultProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ DeletedVaultProperties deserializedDeletedVaultProperties = new DeletedVaultProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("vaultId".equals(fieldName)) {
+ deserializedDeletedVaultProperties.vaultId = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedDeletedVaultProperties.location = reader.getString();
+ } else if ("deletionDate".equals(fieldName)) {
+ deserializedDeletedVaultProperties.deletionDate = reader
+ .getNullable(nonNullReader -> CoreUtils.parseBestOffsetDateTime(nonNullReader.getString()));
+ } else if ("scheduledPurgeDate".equals(fieldName)) {
+ deserializedDeletedVaultProperties.scheduledPurgeDate = reader
+ .getNullable(nonNullReader -> CoreUtils.parseBestOffsetDateTime(nonNullReader.getString()));
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedDeletedVaultProperties.tags = tags;
+ } else if ("purgeProtectionEnabled".equals(fieldName)) {
+ deserializedDeletedVaultProperties.purgeProtectionEnabled
+ = reader.getNullable(JsonReader::getBoolean);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedDeletedVaultProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/ManagedHsmInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/ManagedHsmInner.java
new file mode 100644
index 000000000000..b6ce35435bab
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/ManagedHsmInner.java
@@ -0,0 +1,467 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.Resource;
+import com.azure.core.management.SystemData;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.CreateMode;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmSecurityDomainProperties;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmNetworkRuleSet;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateEndpointConnectionItem;
+import com.azure.resourcemanager.keyvault.generated.models.PublicNetworkAccess;
+import java.io.IOException;
+import java.time.OffsetDateTime;
+import java.util.List;
+import java.util.Map;
+import java.util.UUID;
+
+/**
+ * Resource information with extended details.
+ */
+@Fluent
+public final class ManagedHsmInner extends Resource {
+ /*
+ * Properties of the managed HSM
+ */
+ private ManagedHsmProperties innerProperties;
+
+ /*
+ * Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ */
+ private SystemData systemData;
+
+ /*
+ * The type of the resource.
+ */
+ private String type;
+
+ /*
+ * The name of the resource.
+ */
+ private String name;
+
+ /*
+ * Fully qualified resource Id for the resource.
+ */
+ private String id;
+
+ /**
+ * Creates an instance of ManagedHsmInner class.
+ */
+ public ManagedHsmInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Properties of the managed HSM.
+ *
+ * @return the innerProperties value.
+ */
+ private ManagedHsmProperties 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 type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ @Override
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ @Override
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ @Override
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public ManagedHsmInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public ManagedHsmInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
+ /**
+ * Get the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the managed HSM pool.
+ *
+ * @return the tenantId value.
+ */
+ public UUID tenantId() {
+ return this.innerProperties() == null ? null : this.innerProperties().tenantId();
+ }
+
+ /**
+ * Set the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the managed HSM pool.
+ *
+ * @param tenantId the tenantId value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withTenantId(UUID tenantId) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withTenantId(tenantId);
+ return this;
+ }
+
+ /**
+ * Get the initialAdminObjectIds property: Array of initial administrators object ids for this managed hsm pool.
+ *
+ * @return the initialAdminObjectIds value.
+ */
+ public List initialAdminObjectIds() {
+ return this.innerProperties() == null ? null : this.innerProperties().initialAdminObjectIds();
+ }
+
+ /**
+ * Set the initialAdminObjectIds property: Array of initial administrators object ids for this managed hsm pool.
+ *
+ * @param initialAdminObjectIds the initialAdminObjectIds value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withInitialAdminObjectIds(List initialAdminObjectIds) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withInitialAdminObjectIds(initialAdminObjectIds);
+ return this;
+ }
+
+ /**
+ * Get the hsmUri property: The URI of the managed hsm pool for performing operations on keys.
+ *
+ * @return the hsmUri value.
+ */
+ public String hsmUri() {
+ return this.innerProperties() == null ? null : this.innerProperties().hsmUri();
+ }
+
+ /**
+ * Get the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this managed HSM pool. Soft delete is enabled by default for all managed HSMs and is immutable.
+ *
+ * @return the enableSoftDelete value.
+ */
+ public Boolean enableSoftDelete() {
+ return this.innerProperties() == null ? null : this.innerProperties().enableSoftDelete();
+ }
+
+ /**
+ * Set the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this managed HSM pool. Soft delete is enabled by default for all managed HSMs and is immutable.
+ *
+ * @param enableSoftDelete the enableSoftDelete value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withEnableSoftDelete(Boolean enableSoftDelete) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withEnableSoftDelete(enableSoftDelete);
+ return this;
+ }
+
+ /**
+ * Get the softDeleteRetentionInDays property: Soft deleted data retention days. When you delete an HSM or a key, it
+ * will remain recoverable for the configured retention period or for a default period of 90 days. It accepts values
+ * between 7 and 90.
+ *
+ * @return the softDeleteRetentionInDays value.
+ */
+ public Integer softDeleteRetentionInDays() {
+ return this.innerProperties() == null ? null : this.innerProperties().softDeleteRetentionInDays();
+ }
+
+ /**
+ * Set the softDeleteRetentionInDays property: Soft deleted data retention days. When you delete an HSM or a key, it
+ * will remain recoverable for the configured retention period or for a default period of 90 days. It accepts values
+ * between 7 and 90.
+ *
+ * @param softDeleteRetentionInDays the softDeleteRetentionInDays value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withSoftDeleteRetentionInDays(Integer softDeleteRetentionInDays) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withSoftDeleteRetentionInDays(softDeleteRetentionInDays);
+ return this;
+ }
+
+ /**
+ * Get the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * managed HSM pool. Setting this property to true activates protection against purge for this managed HSM pool and
+ * its content - only the Managed HSM service may initiate a hard, irrecoverable deletion. Enabling this
+ * functionality is irreversible.
+ *
+ * @return the enablePurgeProtection value.
+ */
+ public Boolean enablePurgeProtection() {
+ return this.innerProperties() == null ? null : this.innerProperties().enablePurgeProtection();
+ }
+
+ /**
+ * Set the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * managed HSM pool. Setting this property to true activates protection against purge for this managed HSM pool and
+ * its content - only the Managed HSM service may initiate a hard, irrecoverable deletion. Enabling this
+ * functionality is irreversible.
+ *
+ * @param enablePurgeProtection the enablePurgeProtection value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withEnablePurgeProtection(Boolean enablePurgeProtection) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withEnablePurgeProtection(enablePurgeProtection);
+ return this;
+ }
+
+ /**
+ * Get the createMode property: The create mode to indicate whether the resource is being created or is being
+ * recovered from a deleted resource.
+ *
+ * @return the createMode value.
+ */
+ public CreateMode createMode() {
+ return this.innerProperties() == null ? null : this.innerProperties().createMode();
+ }
+
+ /**
+ * Set the createMode property: The create mode to indicate whether the resource is being created or is being
+ * recovered from a deleted resource.
+ *
+ * @param createMode the createMode value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withCreateMode(CreateMode createMode) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withCreateMode(createMode);
+ return this;
+ }
+
+ /**
+ * Get the statusMessage property: Resource Status Message.
+ *
+ * @return the statusMessage value.
+ */
+ public String statusMessage() {
+ return this.innerProperties() == null ? null : this.innerProperties().statusMessage();
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state.
+ *
+ * @return the provisioningState value.
+ */
+ public ManagedHsmProvisioningState provisioningState() {
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
+ }
+
+ /**
+ * Get the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @return the networkAcls value.
+ */
+ public MhsmNetworkRuleSet networkAcls() {
+ return this.innerProperties() == null ? null : this.innerProperties().networkAcls();
+ }
+
+ /**
+ * Set the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @param networkAcls the networkAcls value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withNetworkAcls(MhsmNetworkRuleSet networkAcls) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withNetworkAcls(networkAcls);
+ return this;
+ }
+
+ /**
+ * Get the regions property: List of all regions associated with the managed hsm pool.
+ *
+ * @return the regions value.
+ */
+ public List regions() {
+ return this.innerProperties() == null ? null : this.innerProperties().regions();
+ }
+
+ /**
+ * Set the regions property: List of all regions associated with the managed hsm pool.
+ *
+ * @param regions the regions value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withRegions(List regions) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withRegions(regions);
+ return this;
+ }
+
+ /**
+ * Get the privateEndpointConnections property: List of private endpoint connections associated with the managed hsm
+ * pool.
+ *
+ * @return the privateEndpointConnections value.
+ */
+ public List privateEndpointConnections() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpointConnections();
+ }
+
+ /**
+ * Get the publicNetworkAccess property: Control permission to the managed HSM from public networks.
+ *
+ * @return the publicNetworkAccess value.
+ */
+ public PublicNetworkAccess publicNetworkAccess() {
+ return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess();
+ }
+
+ /**
+ * Set the publicNetworkAccess property: Control permission to the managed HSM from public networks.
+ *
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
+ * @return the ManagedHsmInner object itself.
+ */
+ public ManagedHsmInner withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ManagedHsmProperties();
+ }
+ this.innerProperties().withPublicNetworkAccess(publicNetworkAccess);
+ return this;
+ }
+
+ /**
+ * Get the scheduledPurgeDate property: The scheduled purge date in UTC.
+ *
+ * @return the scheduledPurgeDate value.
+ */
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.innerProperties() == null ? null : this.innerProperties().scheduledPurgeDate();
+ }
+
+ /**
+ * Get the securityDomainProperties property: Managed HSM security domain properties.
+ *
+ * @return the securityDomainProperties value.
+ */
+ public ManagedHsmSecurityDomainProperties securityDomainProperties() {
+ return this.innerProperties() == null ? null : this.innerProperties().securityDomainProperties();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("location", location());
+ jsonWriter.writeMapField("tags", tags(), (writer, element) -> writer.writeString(element));
+ jsonWriter.writeJsonField("properties", this.innerProperties);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of ManagedHsmInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of ManagedHsmInner if the JsonReader was pointing to an instance of it, or null if it was
+ * pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the ManagedHsmInner.
+ */
+ public static ManagedHsmInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ ManagedHsmInner deserializedManagedHsmInner = new ManagedHsmInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedManagedHsmInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedManagedHsmInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedManagedHsmInner.type = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedManagedHsmInner.withLocation(reader.getString());
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedManagedHsmInner.withTags(tags);
+ } else if ("properties".equals(fieldName)) {
+ deserializedManagedHsmInner.innerProperties = ManagedHsmProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedManagedHsmInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedManagedHsmInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/ManagedHsmProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/ManagedHsmProperties.java
new file mode 100644
index 000000000000..e7d49ed87492
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/ManagedHsmProperties.java
@@ -0,0 +1,469 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.CoreUtils;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.CreateMode;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmSecurityDomainProperties;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmNetworkRuleSet;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateEndpointConnectionItem;
+import com.azure.resourcemanager.keyvault.generated.models.PublicNetworkAccess;
+import java.io.IOException;
+import java.time.OffsetDateTime;
+import java.util.List;
+import java.util.Objects;
+import java.util.UUID;
+
+/**
+ * Properties of the managed HSM Pool.
+ */
+@Fluent
+public final class ManagedHsmProperties implements JsonSerializable {
+ /*
+ * The Azure Active Directory tenant ID that should be used for authenticating requests to the managed HSM pool.
+ */
+ private UUID tenantId;
+
+ /*
+ * Array of initial administrators object ids for this managed hsm pool.
+ */
+ private List initialAdminObjectIds;
+
+ /*
+ * The URI of the managed hsm pool for performing operations on keys.
+ */
+ private String hsmUri;
+
+ /*
+ * Property to specify whether the 'soft delete' functionality is enabled for this managed HSM pool. Soft delete is
+ * enabled by default for all managed HSMs and is immutable.
+ */
+ private Boolean enableSoftDelete;
+
+ /*
+ * Soft deleted data retention days. When you delete an HSM or a key, it will remain recoverable for the configured
+ * retention period or for a default period of 90 days. It accepts values between 7 and 90.
+ */
+ private Integer softDeleteRetentionInDays;
+
+ /*
+ * Property specifying whether protection against purge is enabled for this managed HSM pool. Setting this property
+ * to true activates protection against purge for this managed HSM pool and its content - only the Managed HSM
+ * service may initiate a hard, irrecoverable deletion. Enabling this functionality is irreversible.
+ */
+ private Boolean enablePurgeProtection;
+
+ /*
+ * The create mode to indicate whether the resource is being created or is being recovered from a deleted resource.
+ */
+ private CreateMode createMode;
+
+ /*
+ * Resource Status Message.
+ */
+ private String statusMessage;
+
+ /*
+ * Provisioning state.
+ */
+ private ManagedHsmProvisioningState provisioningState;
+
+ /*
+ * Rules governing the accessibility of the key vault from specific network locations.
+ */
+ private MhsmNetworkRuleSet networkAcls;
+
+ /*
+ * List of all regions associated with the managed hsm pool.
+ */
+ private List regions;
+
+ /*
+ * List of private endpoint connections associated with the managed hsm pool.
+ */
+ private List privateEndpointConnections;
+
+ /*
+ * Control permission to the managed HSM from public networks.
+ */
+ private PublicNetworkAccess publicNetworkAccess;
+
+ /*
+ * The scheduled purge date in UTC.
+ */
+ private OffsetDateTime scheduledPurgeDate;
+
+ /*
+ * Managed HSM security domain properties.
+ */
+ private ManagedHsmSecurityDomainProperties securityDomainProperties;
+
+ /**
+ * Creates an instance of ManagedHsmProperties class.
+ */
+ public ManagedHsmProperties() {
+ }
+
+ /**
+ * Get the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the managed HSM pool.
+ *
+ * @return the tenantId value.
+ */
+ public UUID tenantId() {
+ return this.tenantId;
+ }
+
+ /**
+ * Set the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the managed HSM pool.
+ *
+ * @param tenantId the tenantId value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withTenantId(UUID tenantId) {
+ this.tenantId = tenantId;
+ return this;
+ }
+
+ /**
+ * Get the initialAdminObjectIds property: Array of initial administrators object ids for this managed hsm pool.
+ *
+ * @return the initialAdminObjectIds value.
+ */
+ public List initialAdminObjectIds() {
+ return this.initialAdminObjectIds;
+ }
+
+ /**
+ * Set the initialAdminObjectIds property: Array of initial administrators object ids for this managed hsm pool.
+ *
+ * @param initialAdminObjectIds the initialAdminObjectIds value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withInitialAdminObjectIds(List initialAdminObjectIds) {
+ this.initialAdminObjectIds = initialAdminObjectIds;
+ return this;
+ }
+
+ /**
+ * Get the hsmUri property: The URI of the managed hsm pool for performing operations on keys.
+ *
+ * @return the hsmUri value.
+ */
+ public String hsmUri() {
+ return this.hsmUri;
+ }
+
+ /**
+ * Get the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this managed HSM pool. Soft delete is enabled by default for all managed HSMs and is immutable.
+ *
+ * @return the enableSoftDelete value.
+ */
+ public Boolean enableSoftDelete() {
+ return this.enableSoftDelete;
+ }
+
+ /**
+ * Set the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this managed HSM pool. Soft delete is enabled by default for all managed HSMs and is immutable.
+ *
+ * @param enableSoftDelete the enableSoftDelete value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withEnableSoftDelete(Boolean enableSoftDelete) {
+ this.enableSoftDelete = enableSoftDelete;
+ return this;
+ }
+
+ /**
+ * Get the softDeleteRetentionInDays property: Soft deleted data retention days. When you delete an HSM or a key, it
+ * will remain recoverable for the configured retention period or for a default period of 90 days. It accepts values
+ * between 7 and 90.
+ *
+ * @return the softDeleteRetentionInDays value.
+ */
+ public Integer softDeleteRetentionInDays() {
+ return this.softDeleteRetentionInDays;
+ }
+
+ /**
+ * Set the softDeleteRetentionInDays property: Soft deleted data retention days. When you delete an HSM or a key, it
+ * will remain recoverable for the configured retention period or for a default period of 90 days. It accepts values
+ * between 7 and 90.
+ *
+ * @param softDeleteRetentionInDays the softDeleteRetentionInDays value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withSoftDeleteRetentionInDays(Integer softDeleteRetentionInDays) {
+ this.softDeleteRetentionInDays = softDeleteRetentionInDays;
+ return this;
+ }
+
+ /**
+ * Get the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * managed HSM pool. Setting this property to true activates protection against purge for this managed HSM pool and
+ * its content - only the Managed HSM service may initiate a hard, irrecoverable deletion. Enabling this
+ * functionality is irreversible.
+ *
+ * @return the enablePurgeProtection value.
+ */
+ public Boolean enablePurgeProtection() {
+ return this.enablePurgeProtection;
+ }
+
+ /**
+ * Set the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * managed HSM pool. Setting this property to true activates protection against purge for this managed HSM pool and
+ * its content - only the Managed HSM service may initiate a hard, irrecoverable deletion. Enabling this
+ * functionality is irreversible.
+ *
+ * @param enablePurgeProtection the enablePurgeProtection value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withEnablePurgeProtection(Boolean enablePurgeProtection) {
+ this.enablePurgeProtection = enablePurgeProtection;
+ return this;
+ }
+
+ /**
+ * Get the createMode property: The create mode to indicate whether the resource is being created or is being
+ * recovered from a deleted resource.
+ *
+ * @return the createMode value.
+ */
+ public CreateMode createMode() {
+ return this.createMode;
+ }
+
+ /**
+ * Set the createMode property: The create mode to indicate whether the resource is being created or is being
+ * recovered from a deleted resource.
+ *
+ * @param createMode the createMode value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withCreateMode(CreateMode createMode) {
+ this.createMode = createMode;
+ return this;
+ }
+
+ /**
+ * Get the statusMessage property: Resource Status Message.
+ *
+ * @return the statusMessage value.
+ */
+ public String statusMessage() {
+ return this.statusMessage;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state.
+ *
+ * @return the provisioningState value.
+ */
+ public ManagedHsmProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @return the networkAcls value.
+ */
+ public MhsmNetworkRuleSet networkAcls() {
+ return this.networkAcls;
+ }
+
+ /**
+ * Set the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @param networkAcls the networkAcls value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withNetworkAcls(MhsmNetworkRuleSet networkAcls) {
+ this.networkAcls = networkAcls;
+ return this;
+ }
+
+ /**
+ * Get the regions property: List of all regions associated with the managed hsm pool.
+ *
+ * @return the regions value.
+ */
+ public List regions() {
+ return this.regions;
+ }
+
+ /**
+ * Set the regions property: List of all regions associated with the managed hsm pool.
+ *
+ * @param regions the regions value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withRegions(List regions) {
+ this.regions = regions;
+ return this;
+ }
+
+ /**
+ * Get the privateEndpointConnections property: List of private endpoint connections associated with the managed hsm
+ * pool.
+ *
+ * @return the privateEndpointConnections value.
+ */
+ public List privateEndpointConnections() {
+ return this.privateEndpointConnections;
+ }
+
+ /**
+ * Get the publicNetworkAccess property: Control permission to the managed HSM from public networks.
+ *
+ * @return the publicNetworkAccess value.
+ */
+ public PublicNetworkAccess publicNetworkAccess() {
+ return this.publicNetworkAccess;
+ }
+
+ /**
+ * Set the publicNetworkAccess property: Control permission to the managed HSM from public networks.
+ *
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
+ * @return the ManagedHsmProperties object itself.
+ */
+ public ManagedHsmProperties withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) {
+ this.publicNetworkAccess = publicNetworkAccess;
+ return this;
+ }
+
+ /**
+ * Get the scheduledPurgeDate property: The scheduled purge date in UTC.
+ *
+ * @return the scheduledPurgeDate value.
+ */
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.scheduledPurgeDate;
+ }
+
+ /**
+ * Get the securityDomainProperties property: Managed HSM security domain properties.
+ *
+ * @return the securityDomainProperties value.
+ */
+ public ManagedHsmSecurityDomainProperties securityDomainProperties() {
+ return this.securityDomainProperties;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (networkAcls() != null) {
+ networkAcls().validate();
+ }
+ if (regions() != null) {
+ regions().forEach(e -> e.validate());
+ }
+ if (privateEndpointConnections() != null) {
+ privateEndpointConnections().forEach(e -> e.validate());
+ }
+ if (securityDomainProperties() != null) {
+ securityDomainProperties().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("tenantId", Objects.toString(this.tenantId, null));
+ jsonWriter.writeArrayField("initialAdminObjectIds", this.initialAdminObjectIds,
+ (writer, element) -> writer.writeString(element));
+ jsonWriter.writeBooleanField("enableSoftDelete", this.enableSoftDelete);
+ jsonWriter.writeNumberField("softDeleteRetentionInDays", this.softDeleteRetentionInDays);
+ jsonWriter.writeBooleanField("enablePurgeProtection", this.enablePurgeProtection);
+ jsonWriter.writeStringField("createMode", this.createMode == null ? null : this.createMode.toString());
+ jsonWriter.writeJsonField("networkAcls", this.networkAcls);
+ jsonWriter.writeArrayField("regions", this.regions, (writer, element) -> writer.writeJson(element));
+ jsonWriter.writeStringField("publicNetworkAccess",
+ this.publicNetworkAccess == null ? null : this.publicNetworkAccess.toString());
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of ManagedHsmProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of ManagedHsmProperties if the JsonReader was pointing to an instance of it, or null if it
+ * was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the ManagedHsmProperties.
+ */
+ public static ManagedHsmProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ ManagedHsmProperties deserializedManagedHsmProperties = new ManagedHsmProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("tenantId".equals(fieldName)) {
+ deserializedManagedHsmProperties.tenantId
+ = reader.getNullable(nonNullReader -> UUID.fromString(nonNullReader.getString()));
+ } else if ("initialAdminObjectIds".equals(fieldName)) {
+ List initialAdminObjectIds = reader.readArray(reader1 -> reader1.getString());
+ deserializedManagedHsmProperties.initialAdminObjectIds = initialAdminObjectIds;
+ } else if ("hsmUri".equals(fieldName)) {
+ deserializedManagedHsmProperties.hsmUri = reader.getString();
+ } else if ("enableSoftDelete".equals(fieldName)) {
+ deserializedManagedHsmProperties.enableSoftDelete = reader.getNullable(JsonReader::getBoolean);
+ } else if ("softDeleteRetentionInDays".equals(fieldName)) {
+ deserializedManagedHsmProperties.softDeleteRetentionInDays = reader.getNullable(JsonReader::getInt);
+ } else if ("enablePurgeProtection".equals(fieldName)) {
+ deserializedManagedHsmProperties.enablePurgeProtection = reader.getNullable(JsonReader::getBoolean);
+ } else if ("createMode".equals(fieldName)) {
+ deserializedManagedHsmProperties.createMode = CreateMode.fromString(reader.getString());
+ } else if ("statusMessage".equals(fieldName)) {
+ deserializedManagedHsmProperties.statusMessage = reader.getString();
+ } else if ("provisioningState".equals(fieldName)) {
+ deserializedManagedHsmProperties.provisioningState
+ = ManagedHsmProvisioningState.fromString(reader.getString());
+ } else if ("networkAcls".equals(fieldName)) {
+ deserializedManagedHsmProperties.networkAcls = MhsmNetworkRuleSet.fromJson(reader);
+ } else if ("regions".equals(fieldName)) {
+ List regions
+ = reader.readArray(reader1 -> MhsmGeoReplicatedRegionInner.fromJson(reader1));
+ deserializedManagedHsmProperties.regions = regions;
+ } else if ("privateEndpointConnections".equals(fieldName)) {
+ List privateEndpointConnections
+ = reader.readArray(reader1 -> MhsmPrivateEndpointConnectionItem.fromJson(reader1));
+ deserializedManagedHsmProperties.privateEndpointConnections = privateEndpointConnections;
+ } else if ("publicNetworkAccess".equals(fieldName)) {
+ deserializedManagedHsmProperties.publicNetworkAccess
+ = PublicNetworkAccess.fromString(reader.getString());
+ } else if ("scheduledPurgeDate".equals(fieldName)) {
+ deserializedManagedHsmProperties.scheduledPurgeDate = reader
+ .getNullable(nonNullReader -> CoreUtils.parseBestOffsetDateTime(nonNullReader.getString()));
+ } else if ("securityDomainProperties".equals(fieldName)) {
+ deserializedManagedHsmProperties.securityDomainProperties
+ = ManagedHsmSecurityDomainProperties.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedManagedHsmProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmGeoReplicatedRegionInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmGeoReplicatedRegionInner.java
new file mode 100644
index 000000000000..9db8f3930003
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmGeoReplicatedRegionInner.java
@@ -0,0 +1,141 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.GeoReplicationRegionProvisioningState;
+import java.io.IOException;
+
+/**
+ * A region that this managed HSM Pool has been extended to.
+ */
+@Fluent
+public final class MhsmGeoReplicatedRegionInner implements JsonSerializable {
+ /*
+ * Name of the geo replicated region.
+ */
+ private String name;
+
+ /*
+ * Provisioning state of the geo replicated region.
+ */
+ private GeoReplicationRegionProvisioningState provisioningState;
+
+ /*
+ * A boolean value that indicates whether the region is the primary region or a secondary region.
+ */
+ private Boolean isPrimary;
+
+ /**
+ * Creates an instance of MhsmGeoReplicatedRegionInner class.
+ */
+ public MhsmGeoReplicatedRegionInner() {
+ }
+
+ /**
+ * Get the name property: Name of the geo replicated region.
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Set the name property: Name of the geo replicated region.
+ *
+ * @param name the name value to set.
+ * @return the MhsmGeoReplicatedRegionInner object itself.
+ */
+ public MhsmGeoReplicatedRegionInner withName(String name) {
+ this.name = name;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the geo replicated region.
+ *
+ * @return the provisioningState value.
+ */
+ public GeoReplicationRegionProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the isPrimary property: A boolean value that indicates whether the region is the primary region or a
+ * secondary region.
+ *
+ * @return the isPrimary value.
+ */
+ public Boolean isPrimary() {
+ return this.isPrimary;
+ }
+
+ /**
+ * Set the isPrimary property: A boolean value that indicates whether the region is the primary region or a
+ * secondary region.
+ *
+ * @param isPrimary the isPrimary value to set.
+ * @return the MhsmGeoReplicatedRegionInner object itself.
+ */
+ public MhsmGeoReplicatedRegionInner withIsPrimary(Boolean isPrimary) {
+ this.isPrimary = isPrimary;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("name", this.name);
+ jsonWriter.writeBooleanField("isPrimary", this.isPrimary);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of MhsmGeoReplicatedRegionInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of MhsmGeoReplicatedRegionInner if the JsonReader was pointing to an instance of it, or null
+ * if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the MhsmGeoReplicatedRegionInner.
+ */
+ public static MhsmGeoReplicatedRegionInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ MhsmGeoReplicatedRegionInner deserializedMhsmGeoReplicatedRegionInner = new MhsmGeoReplicatedRegionInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("name".equals(fieldName)) {
+ deserializedMhsmGeoReplicatedRegionInner.name = reader.getString();
+ } else if ("provisioningState".equals(fieldName)) {
+ deserializedMhsmGeoReplicatedRegionInner.provisioningState
+ = GeoReplicationRegionProvisioningState.fromString(reader.getString());
+ } else if ("isPrimary".equals(fieldName)) {
+ deserializedMhsmGeoReplicatedRegionInner.isPrimary = reader.getNullable(JsonReader::getBoolean);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedMhsmGeoReplicatedRegionInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateEndpointConnectionInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateEndpointConnectionInner.java
new file mode 100644
index 000000000000..d81aa1425e00
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateEndpointConnectionInner.java
@@ -0,0 +1,269 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.Resource;
+import com.azure.core.management.SystemData;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmPrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateEndpoint;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateLinkServiceConnectionState;
+import java.io.IOException;
+import java.util.Map;
+
+/**
+ * Private endpoint connection resource.
+ */
+@Fluent
+public final class MhsmPrivateEndpointConnectionInner extends Resource {
+ /*
+ * Resource properties.
+ */
+ private MhsmPrivateEndpointConnectionProperties innerProperties;
+
+ /*
+ * Modified whenever there is a change in the state of private endpoint connection.
+ */
+ private String etag;
+
+ /*
+ * Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ */
+ private SystemData systemData;
+
+ /*
+ * The type of the resource.
+ */
+ private String type;
+
+ /*
+ * The name of the resource.
+ */
+ private String name;
+
+ /*
+ * Fully qualified resource Id for the resource.
+ */
+ private String id;
+
+ /**
+ * Creates an instance of MhsmPrivateEndpointConnectionInner class.
+ */
+ public MhsmPrivateEndpointConnectionInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private MhsmPrivateEndpointConnectionProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the etag property: Modified whenever there is a change in the state of private endpoint connection.
+ *
+ * @return the etag value.
+ */
+ public String etag() {
+ return this.etag;
+ }
+
+ /**
+ * Set the etag property: Modified whenever there is a change in the state of private endpoint connection.
+ *
+ * @param etag the etag value to set.
+ * @return the MhsmPrivateEndpointConnectionInner object itself.
+ */
+ public MhsmPrivateEndpointConnectionInner withEtag(String etag) {
+ this.etag = etag;
+ return this;
+ }
+
+ /**
+ * 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 type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ @Override
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ @Override
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ @Override
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public MhsmPrivateEndpointConnectionInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public MhsmPrivateEndpointConnectionInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
+ /**
+ * Get the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @return the privateEndpoint value.
+ */
+ public MhsmPrivateEndpoint privateEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpoint();
+ }
+
+ /**
+ * Set the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @param privateEndpoint the privateEndpoint value to set.
+ * @return the MhsmPrivateEndpointConnectionInner object itself.
+ */
+ public MhsmPrivateEndpointConnectionInner withPrivateEndpoint(MhsmPrivateEndpoint privateEndpoint) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MhsmPrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateEndpoint(privateEndpoint);
+ return this;
+ }
+
+ /**
+ * Get the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public MhsmPrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateLinkServiceConnectionState();
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set.
+ * @return the MhsmPrivateEndpointConnectionInner object itself.
+ */
+ public MhsmPrivateEndpointConnectionInner
+ withPrivateLinkServiceConnectionState(MhsmPrivateLinkServiceConnectionState privateLinkServiceConnectionState) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new MhsmPrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState);
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the private endpoint connection.
+ *
+ * @return the provisioningState value.
+ */
+ public ManagedHsmPrivateEndpointConnectionProvisioningState provisioningState() {
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("location", location());
+ jsonWriter.writeMapField("tags", tags(), (writer, element) -> writer.writeString(element));
+ jsonWriter.writeJsonField("properties", this.innerProperties);
+ jsonWriter.writeStringField("etag", this.etag);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of MhsmPrivateEndpointConnectionInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of MhsmPrivateEndpointConnectionInner if the JsonReader was pointing to an instance of it, or
+ * null if it was pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the MhsmPrivateEndpointConnectionInner.
+ */
+ public static MhsmPrivateEndpointConnectionInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ MhsmPrivateEndpointConnectionInner deserializedMhsmPrivateEndpointConnectionInner
+ = new MhsmPrivateEndpointConnectionInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionInner.type = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionInner.withLocation(reader.getString());
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedMhsmPrivateEndpointConnectionInner.withTags(tags);
+ } else if ("properties".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionInner.innerProperties
+ = MhsmPrivateEndpointConnectionProperties.fromJson(reader);
+ } else if ("etag".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionInner.etag = reader.getString();
+ } else if ("systemData".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedMhsmPrivateEndpointConnectionInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateEndpointConnectionProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateEndpointConnectionProperties.java
new file mode 100644
index 000000000000..a27a3df43f80
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateEndpointConnectionProperties.java
@@ -0,0 +1,152 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmPrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateEndpoint;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateLinkServiceConnectionState;
+import java.io.IOException;
+
+/**
+ * Properties of the private endpoint connection resource.
+ */
+@Fluent
+public final class MhsmPrivateEndpointConnectionProperties
+ implements JsonSerializable {
+ /*
+ * Properties of the private endpoint object.
+ */
+ private MhsmPrivateEndpoint privateEndpoint;
+
+ /*
+ * Approval state of the private link connection.
+ */
+ private MhsmPrivateLinkServiceConnectionState privateLinkServiceConnectionState;
+
+ /*
+ * Provisioning state of the private endpoint connection.
+ */
+ private ManagedHsmPrivateEndpointConnectionProvisioningState provisioningState;
+
+ /**
+ * Creates an instance of MhsmPrivateEndpointConnectionProperties class.
+ */
+ public MhsmPrivateEndpointConnectionProperties() {
+ }
+
+ /**
+ * Get the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @return the privateEndpoint value.
+ */
+ public MhsmPrivateEndpoint privateEndpoint() {
+ return this.privateEndpoint;
+ }
+
+ /**
+ * Set the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @param privateEndpoint the privateEndpoint value to set.
+ * @return the MhsmPrivateEndpointConnectionProperties object itself.
+ */
+ public MhsmPrivateEndpointConnectionProperties withPrivateEndpoint(MhsmPrivateEndpoint privateEndpoint) {
+ this.privateEndpoint = privateEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public MhsmPrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.privateLinkServiceConnectionState;
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set.
+ * @return the MhsmPrivateEndpointConnectionProperties object itself.
+ */
+ public MhsmPrivateEndpointConnectionProperties
+ withPrivateLinkServiceConnectionState(MhsmPrivateLinkServiceConnectionState privateLinkServiceConnectionState) {
+ this.privateLinkServiceConnectionState = privateLinkServiceConnectionState;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the private endpoint connection.
+ *
+ * @return the provisioningState value.
+ */
+ public ManagedHsmPrivateEndpointConnectionProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (privateEndpoint() != null) {
+ privateEndpoint().validate();
+ }
+ if (privateLinkServiceConnectionState() != null) {
+ privateLinkServiceConnectionState().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeJsonField("privateEndpoint", this.privateEndpoint);
+ jsonWriter.writeJsonField("privateLinkServiceConnectionState", this.privateLinkServiceConnectionState);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of MhsmPrivateEndpointConnectionProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of MhsmPrivateEndpointConnectionProperties if the JsonReader was pointing to an instance of
+ * it, or null if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the MhsmPrivateEndpointConnectionProperties.
+ */
+ public static MhsmPrivateEndpointConnectionProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ MhsmPrivateEndpointConnectionProperties deserializedMhsmPrivateEndpointConnectionProperties
+ = new MhsmPrivateEndpointConnectionProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("privateEndpoint".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionProperties.privateEndpoint
+ = MhsmPrivateEndpoint.fromJson(reader);
+ } else if ("privateLinkServiceConnectionState".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionProperties.privateLinkServiceConnectionState
+ = MhsmPrivateLinkServiceConnectionState.fromJson(reader);
+ } else if ("provisioningState".equals(fieldName)) {
+ deserializedMhsmPrivateEndpointConnectionProperties.provisioningState
+ = ManagedHsmPrivateEndpointConnectionProvisioningState.fromString(reader.getString());
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedMhsmPrivateEndpointConnectionProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateLinkResourceListResultInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateLinkResourceListResultInner.java
new file mode 100644
index 000000000000..a97086236979
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateLinkResourceListResultInner.java
@@ -0,0 +1,102 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateLinkResource;
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * A list of private link resources.
+ */
+@Fluent
+public final class MhsmPrivateLinkResourceListResultInner
+ implements JsonSerializable {
+ /*
+ * Array of private link resources
+ */
+ private List value;
+
+ /**
+ * Creates an instance of MhsmPrivateLinkResourceListResultInner class.
+ */
+ public MhsmPrivateLinkResourceListResultInner() {
+ }
+
+ /**
+ * Get the value property: Array of private link resources.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Set the value property: Array of private link resources.
+ *
+ * @param value the value value to set.
+ * @return the MhsmPrivateLinkResourceListResultInner object itself.
+ */
+ public MhsmPrivateLinkResourceListResultInner withValue(List value) {
+ this.value = value;
+ 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());
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeArrayField("value", this.value, (writer, element) -> writer.writeJson(element));
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of MhsmPrivateLinkResourceListResultInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of MhsmPrivateLinkResourceListResultInner if the JsonReader was pointing to an instance of
+ * it, or null if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the MhsmPrivateLinkResourceListResultInner.
+ */
+ public static MhsmPrivateLinkResourceListResultInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ MhsmPrivateLinkResourceListResultInner deserializedMhsmPrivateLinkResourceListResultInner
+ = new MhsmPrivateLinkResourceListResultInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("value".equals(fieldName)) {
+ List value
+ = reader.readArray(reader1 -> MhsmPrivateLinkResource.fromJson(reader1));
+ deserializedMhsmPrivateLinkResourceListResultInner.value = value;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedMhsmPrivateLinkResourceListResultInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateLinkResourceProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateLinkResourceProperties.java
new file mode 100644
index 000000000000..918d8ca1c2b7
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/MhsmPrivateLinkResourceProperties.java
@@ -0,0 +1,130 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * Properties of a private link resource.
+ */
+@Fluent
+public final class MhsmPrivateLinkResourceProperties implements JsonSerializable {
+ /*
+ * Group identifier of private link resource.
+ */
+ private String groupId;
+
+ /*
+ * Required member names of private link resource.
+ */
+ private List requiredMembers;
+
+ /*
+ * Required DNS zone names of the the private link resource.
+ */
+ private List requiredZoneNames;
+
+ /**
+ * Creates an instance of MhsmPrivateLinkResourceProperties class.
+ */
+ public MhsmPrivateLinkResourceProperties() {
+ }
+
+ /**
+ * Get the groupId property: Group identifier of private link resource.
+ *
+ * @return the groupId value.
+ */
+ public String groupId() {
+ return this.groupId;
+ }
+
+ /**
+ * Get the requiredMembers property: Required member names of private link resource.
+ *
+ * @return the requiredMembers value.
+ */
+ public List requiredMembers() {
+ return this.requiredMembers;
+ }
+
+ /**
+ * Get the requiredZoneNames property: Required DNS zone names of the the private link resource.
+ *
+ * @return the requiredZoneNames value.
+ */
+ public List requiredZoneNames() {
+ return this.requiredZoneNames;
+ }
+
+ /**
+ * Set the requiredZoneNames property: Required DNS zone names of the the private link resource.
+ *
+ * @param requiredZoneNames the requiredZoneNames value to set.
+ * @return the MhsmPrivateLinkResourceProperties object itself.
+ */
+ public MhsmPrivateLinkResourceProperties withRequiredZoneNames(List requiredZoneNames) {
+ this.requiredZoneNames = requiredZoneNames;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeArrayField("requiredZoneNames", this.requiredZoneNames,
+ (writer, element) -> writer.writeString(element));
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of MhsmPrivateLinkResourceProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of MhsmPrivateLinkResourceProperties if the JsonReader was pointing to an instance of it, or
+ * null if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the MhsmPrivateLinkResourceProperties.
+ */
+ public static MhsmPrivateLinkResourceProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ MhsmPrivateLinkResourceProperties deserializedMhsmPrivateLinkResourceProperties
+ = new MhsmPrivateLinkResourceProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("groupId".equals(fieldName)) {
+ deserializedMhsmPrivateLinkResourceProperties.groupId = reader.getString();
+ } else if ("requiredMembers".equals(fieldName)) {
+ List requiredMembers = reader.readArray(reader1 -> reader1.getString());
+ deserializedMhsmPrivateLinkResourceProperties.requiredMembers = requiredMembers;
+ } else if ("requiredZoneNames".equals(fieldName)) {
+ List requiredZoneNames = reader.readArray(reader1 -> reader1.getString());
+ deserializedMhsmPrivateLinkResourceProperties.requiredZoneNames = requiredZoneNames;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedMhsmPrivateLinkResourceProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/OperationInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/OperationInner.java
new file mode 100644
index 000000000000..f7ba64e44b2e
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/OperationInner.java
@@ -0,0 +1,172 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.ActionType;
+import com.azure.resourcemanager.keyvault.generated.models.OperationDisplay;
+import com.azure.resourcemanager.keyvault.generated.models.Origin;
+import java.io.IOException;
+
+/**
+ * REST API Operation
+ *
+ * Details of a REST API operation, returned from the Resource Provider Operations API.
+ */
+@Fluent
+public final class OperationInner implements JsonSerializable {
+ /*
+ * The name of the operation, as per Resource-Based Access Control (RBAC). Examples:
+ * "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action"
+ */
+ private String name;
+
+ /*
+ * Whether the operation applies to data-plane. This is "true" for data-plane operations and "false" for
+ * ARM/control-plane operations.
+ */
+ private Boolean isDataAction;
+
+ /*
+ * Localized display information for this particular operation.
+ */
+ private OperationDisplay display;
+
+ /*
+ * The intended executor of the operation; as in Resource Based Access Control (RBAC) and audit logs UX. Default
+ * value is "user,system"
+ */
+ private Origin origin;
+
+ /*
+ * Enum. Indicates the action type. "Internal" refers to actions that are for internal only APIs.
+ */
+ private ActionType actionType;
+
+ /**
+ * Creates an instance of OperationInner class.
+ */
+ public OperationInner() {
+ }
+
+ /**
+ * Get the name property: The name of the operation, as per Resource-Based Access Control (RBAC). Examples:
+ * "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action".
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the isDataAction property: Whether the operation applies to data-plane. This is "true" for data-plane
+ * operations and "false" for ARM/control-plane operations.
+ *
+ * @return the isDataAction value.
+ */
+ public Boolean isDataAction() {
+ return this.isDataAction;
+ }
+
+ /**
+ * Get the display property: Localized display information for this particular operation.
+ *
+ * @return the display value.
+ */
+ public OperationDisplay display() {
+ return this.display;
+ }
+
+ /**
+ * Set the display property: Localized display information for this particular operation.
+ *
+ * @param display the display value to set.
+ * @return the OperationInner object itself.
+ */
+ public OperationInner withDisplay(OperationDisplay display) {
+ this.display = display;
+ return this;
+ }
+
+ /**
+ * Get the origin property: The intended executor of the operation; as in Resource Based Access Control (RBAC) and
+ * audit logs UX. Default value is "user,system".
+ *
+ * @return the origin value.
+ */
+ public Origin origin() {
+ return this.origin;
+ }
+
+ /**
+ * Get the actionType property: Enum. Indicates the action type. "Internal" refers to actions that are for internal
+ * only APIs.
+ *
+ * @return the actionType value.
+ */
+ public ActionType actionType() {
+ return this.actionType;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (display() != null) {
+ display().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeJsonField("display", this.display);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of OperationInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of OperationInner if the JsonReader was pointing to an instance of it, or null if it was
+ * pointing to JSON null.
+ * @throws IOException If an error occurs while reading the OperationInner.
+ */
+ public static OperationInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ OperationInner deserializedOperationInner = new OperationInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("name".equals(fieldName)) {
+ deserializedOperationInner.name = reader.getString();
+ } else if ("isDataAction".equals(fieldName)) {
+ deserializedOperationInner.isDataAction = reader.getNullable(JsonReader::getBoolean);
+ } else if ("display".equals(fieldName)) {
+ deserializedOperationInner.display = OperationDisplay.fromJson(reader);
+ } else if ("origin".equals(fieldName)) {
+ deserializedOperationInner.origin = Origin.fromString(reader.getString());
+ } else if ("actionType".equals(fieldName)) {
+ deserializedOperationInner.actionType = ActionType.fromString(reader.getString());
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedOperationInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateEndpointConnectionInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateEndpointConnectionInner.java
new file mode 100644
index 000000000000..d4306a17441c
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateEndpointConnectionInner.java
@@ -0,0 +1,269 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.Resource;
+import com.azure.core.management.SystemData;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateEndpoint;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateLinkServiceConnectionState;
+import java.io.IOException;
+import java.util.Map;
+
+/**
+ * Private endpoint connection resource.
+ */
+@Fluent
+public final class PrivateEndpointConnectionInner extends Resource {
+ /*
+ * Resource properties.
+ */
+ private PrivateEndpointConnectionProperties innerProperties;
+
+ /*
+ * Modified whenever there is a change in the state of private endpoint connection.
+ */
+ private String etag;
+
+ /*
+ * Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ */
+ private SystemData systemData;
+
+ /*
+ * The type of the resource.
+ */
+ private String type;
+
+ /*
+ * The name of the resource.
+ */
+ private String name;
+
+ /*
+ * Fully qualified resource Id for the resource.
+ */
+ private String id;
+
+ /**
+ * Creates an instance of PrivateEndpointConnectionInner class.
+ */
+ public PrivateEndpointConnectionInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private PrivateEndpointConnectionProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the etag property: Modified whenever there is a change in the state of private endpoint connection.
+ *
+ * @return the etag value.
+ */
+ public String etag() {
+ return this.etag;
+ }
+
+ /**
+ * Set the etag property: Modified whenever there is a change in the state of private endpoint connection.
+ *
+ * @param etag the etag value to set.
+ * @return the PrivateEndpointConnectionInner object itself.
+ */
+ public PrivateEndpointConnectionInner withEtag(String etag) {
+ this.etag = etag;
+ return this;
+ }
+
+ /**
+ * 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 type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ @Override
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ @Override
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ @Override
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public PrivateEndpointConnectionInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public PrivateEndpointConnectionInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
+ /**
+ * Get the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @return the privateEndpoint value.
+ */
+ public PrivateEndpoint privateEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpoint();
+ }
+
+ /**
+ * Set the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @param privateEndpoint the privateEndpoint value to set.
+ * @return the PrivateEndpointConnectionInner object itself.
+ */
+ public PrivateEndpointConnectionInner withPrivateEndpoint(PrivateEndpoint privateEndpoint) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateEndpoint(privateEndpoint);
+ return this;
+ }
+
+ /**
+ * Get the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateLinkServiceConnectionState();
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set.
+ * @return the PrivateEndpointConnectionInner object itself.
+ */
+ public PrivateEndpointConnectionInner
+ withPrivateLinkServiceConnectionState(PrivateLinkServiceConnectionState privateLinkServiceConnectionState) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateEndpointConnectionProperties();
+ }
+ this.innerProperties().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState);
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the private endpoint connection.
+ *
+ * @return the provisioningState value.
+ */
+ public PrivateEndpointConnectionProvisioningState provisioningState() {
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("location", location());
+ jsonWriter.writeMapField("tags", tags(), (writer, element) -> writer.writeString(element));
+ jsonWriter.writeJsonField("properties", this.innerProperties);
+ jsonWriter.writeStringField("etag", this.etag);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of PrivateEndpointConnectionInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of PrivateEndpointConnectionInner if the JsonReader was pointing to an instance of it, or
+ * null if it was pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the PrivateEndpointConnectionInner.
+ */
+ public static PrivateEndpointConnectionInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ PrivateEndpointConnectionInner deserializedPrivateEndpointConnectionInner
+ = new PrivateEndpointConnectionInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.type = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.withLocation(reader.getString());
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedPrivateEndpointConnectionInner.withTags(tags);
+ } else if ("properties".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.innerProperties
+ = PrivateEndpointConnectionProperties.fromJson(reader);
+ } else if ("etag".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.etag = reader.getString();
+ } else if ("systemData".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateEndpointConnectionInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateEndpointConnectionProperties.java
new file mode 100644
index 000000000000..1f1a221d6e73
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateEndpointConnectionProperties.java
@@ -0,0 +1,151 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateEndpoint;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateLinkServiceConnectionState;
+import java.io.IOException;
+
+/**
+ * Properties of the private endpoint connection resource.
+ */
+@Fluent
+public final class PrivateEndpointConnectionProperties
+ implements JsonSerializable {
+ /*
+ * Properties of the private endpoint object.
+ */
+ private PrivateEndpoint privateEndpoint;
+
+ /*
+ * Approval state of the private link connection.
+ */
+ private PrivateLinkServiceConnectionState privateLinkServiceConnectionState;
+
+ /*
+ * Provisioning state of the private endpoint connection.
+ */
+ private PrivateEndpointConnectionProvisioningState provisioningState;
+
+ /**
+ * Creates an instance of PrivateEndpointConnectionProperties class.
+ */
+ public PrivateEndpointConnectionProperties() {
+ }
+
+ /**
+ * Get the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @return the privateEndpoint value.
+ */
+ public PrivateEndpoint privateEndpoint() {
+ return this.privateEndpoint;
+ }
+
+ /**
+ * Set the privateEndpoint property: Properties of the private endpoint object.
+ *
+ * @param privateEndpoint the privateEndpoint value to set.
+ * @return the PrivateEndpointConnectionProperties object itself.
+ */
+ public PrivateEndpointConnectionProperties withPrivateEndpoint(PrivateEndpoint privateEndpoint) {
+ this.privateEndpoint = privateEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.privateLinkServiceConnectionState;
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: Approval state of the private link connection.
+ *
+ * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set.
+ * @return the PrivateEndpointConnectionProperties object itself.
+ */
+ public PrivateEndpointConnectionProperties
+ withPrivateLinkServiceConnectionState(PrivateLinkServiceConnectionState privateLinkServiceConnectionState) {
+ this.privateLinkServiceConnectionState = privateLinkServiceConnectionState;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the private endpoint connection.
+ *
+ * @return the provisioningState value.
+ */
+ public PrivateEndpointConnectionProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (privateEndpoint() != null) {
+ privateEndpoint().validate();
+ }
+ if (privateLinkServiceConnectionState() != null) {
+ privateLinkServiceConnectionState().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeJsonField("privateEndpoint", this.privateEndpoint);
+ jsonWriter.writeJsonField("privateLinkServiceConnectionState", this.privateLinkServiceConnectionState);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of PrivateEndpointConnectionProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of PrivateEndpointConnectionProperties if the JsonReader was pointing to an instance of it,
+ * or null if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the PrivateEndpointConnectionProperties.
+ */
+ public static PrivateEndpointConnectionProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ PrivateEndpointConnectionProperties deserializedPrivateEndpointConnectionProperties
+ = new PrivateEndpointConnectionProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("privateEndpoint".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionProperties.privateEndpoint = PrivateEndpoint.fromJson(reader);
+ } else if ("privateLinkServiceConnectionState".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionProperties.privateLinkServiceConnectionState
+ = PrivateLinkServiceConnectionState.fromJson(reader);
+ } else if ("provisioningState".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionProperties.provisioningState
+ = PrivateEndpointConnectionProvisioningState.fromString(reader.getString());
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateEndpointConnectionProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateLinkResourceListResultInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateLinkResourceListResultInner.java
new file mode 100644
index 000000000000..aa31cf4fa224
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateLinkResourceListResultInner.java
@@ -0,0 +1,101 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateLinkResource;
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * A list of private link resources.
+ */
+@Fluent
+public final class PrivateLinkResourceListResultInner implements JsonSerializable {
+ /*
+ * Array of private link resources
+ */
+ private List value;
+
+ /**
+ * Creates an instance of PrivateLinkResourceListResultInner class.
+ */
+ public PrivateLinkResourceListResultInner() {
+ }
+
+ /**
+ * Get the value property: Array of private link resources.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Set the value property: Array of private link resources.
+ *
+ * @param value the value value to set.
+ * @return the PrivateLinkResourceListResultInner object itself.
+ */
+ public PrivateLinkResourceListResultInner withValue(List value) {
+ this.value = value;
+ 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());
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeArrayField("value", this.value, (writer, element) -> writer.writeJson(element));
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of PrivateLinkResourceListResultInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of PrivateLinkResourceListResultInner if the JsonReader was pointing to an instance of it, or
+ * null if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the PrivateLinkResourceListResultInner.
+ */
+ public static PrivateLinkResourceListResultInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ PrivateLinkResourceListResultInner deserializedPrivateLinkResourceListResultInner
+ = new PrivateLinkResourceListResultInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("value".equals(fieldName)) {
+ List value
+ = reader.readArray(reader1 -> PrivateLinkResource.fromJson(reader1));
+ deserializedPrivateLinkResourceListResultInner.value = value;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateLinkResourceListResultInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateLinkResourceProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateLinkResourceProperties.java
new file mode 100644
index 000000000000..cf34a1b6fcff
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/PrivateLinkResourceProperties.java
@@ -0,0 +1,130 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * Properties of a private link resource.
+ */
+@Fluent
+public final class PrivateLinkResourceProperties implements JsonSerializable {
+ /*
+ * Group identifier of private link resource.
+ */
+ private String groupId;
+
+ /*
+ * Required member names of private link resource.
+ */
+ private List requiredMembers;
+
+ /*
+ * Required DNS zone names of the the private link resource.
+ */
+ private List requiredZoneNames;
+
+ /**
+ * Creates an instance of PrivateLinkResourceProperties class.
+ */
+ public PrivateLinkResourceProperties() {
+ }
+
+ /**
+ * Get the groupId property: Group identifier of private link resource.
+ *
+ * @return the groupId value.
+ */
+ public String groupId() {
+ return this.groupId;
+ }
+
+ /**
+ * Get the requiredMembers property: Required member names of private link resource.
+ *
+ * @return the requiredMembers value.
+ */
+ public List requiredMembers() {
+ return this.requiredMembers;
+ }
+
+ /**
+ * Get the requiredZoneNames property: Required DNS zone names of the the private link resource.
+ *
+ * @return the requiredZoneNames value.
+ */
+ public List requiredZoneNames() {
+ return this.requiredZoneNames;
+ }
+
+ /**
+ * Set the requiredZoneNames property: Required DNS zone names of the the private link resource.
+ *
+ * @param requiredZoneNames the requiredZoneNames value to set.
+ * @return the PrivateLinkResourceProperties object itself.
+ */
+ public PrivateLinkResourceProperties withRequiredZoneNames(List requiredZoneNames) {
+ this.requiredZoneNames = requiredZoneNames;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeArrayField("requiredZoneNames", this.requiredZoneNames,
+ (writer, element) -> writer.writeString(element));
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of PrivateLinkResourceProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of PrivateLinkResourceProperties if the JsonReader was pointing to an instance of it, or null
+ * if it was pointing to JSON null.
+ * @throws IOException If an error occurs while reading the PrivateLinkResourceProperties.
+ */
+ public static PrivateLinkResourceProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ PrivateLinkResourceProperties deserializedPrivateLinkResourceProperties
+ = new PrivateLinkResourceProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("groupId".equals(fieldName)) {
+ deserializedPrivateLinkResourceProperties.groupId = reader.getString();
+ } else if ("requiredMembers".equals(fieldName)) {
+ List requiredMembers = reader.readArray(reader1 -> reader1.getString());
+ deserializedPrivateLinkResourceProperties.requiredMembers = requiredMembers;
+ } else if ("requiredZoneNames".equals(fieldName)) {
+ List requiredZoneNames = reader.readArray(reader1 -> reader1.getString());
+ deserializedPrivateLinkResourceProperties.requiredZoneNames = requiredZoneNames;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateLinkResourceProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/SecretInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/SecretInner.java
new file mode 100644
index 000000000000..cf548b586a70
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/SecretInner.java
@@ -0,0 +1,278 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.Resource;
+import com.azure.core.management.SystemData;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.SecretAttributes;
+import java.io.IOException;
+import java.util.Map;
+
+/**
+ * Resource information with extended details.
+ */
+@Fluent
+public final class SecretInner extends Resource {
+ /*
+ * Properties of the secret
+ */
+ private SecretProperties innerProperties = new SecretProperties();
+
+ /*
+ * Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ */
+ private SystemData systemData;
+
+ /*
+ * The type of the resource.
+ */
+ private String type;
+
+ /*
+ * The name of the resource.
+ */
+ private String name;
+
+ /*
+ * Fully qualified resource Id for the resource.
+ */
+ private String id;
+
+ /**
+ * Creates an instance of SecretInner class.
+ */
+ public SecretInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Properties of the secret.
+ *
+ * @return the innerProperties value.
+ */
+ private SecretProperties 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 type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ @Override
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ @Override
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ @Override
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public SecretInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public SecretInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
+ /**
+ * Get the value property: The value of the secret. NOTE: 'value' will never be returned from the service, as APIs
+ * using this model are is intended for internal use in ARM deployments. Users should use the data-plane REST
+ * service for interaction with vault secrets.
+ *
+ * @return the value value.
+ */
+ public String value() {
+ return this.innerProperties() == null ? null : this.innerProperties().value();
+ }
+
+ /**
+ * Set the value property: The value of the secret. NOTE: 'value' will never be returned from the service, as APIs
+ * using this model are is intended for internal use in ARM deployments. Users should use the data-plane REST
+ * service for interaction with vault secrets.
+ *
+ * @param value the value value to set.
+ * @return the SecretInner object itself.
+ */
+ public SecretInner withValue(String value) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecretProperties();
+ }
+ this.innerProperties().withValue(value);
+ return this;
+ }
+
+ /**
+ * Get the contentType property: The content type of the secret.
+ *
+ * @return the contentType value.
+ */
+ public String contentType() {
+ return this.innerProperties() == null ? null : this.innerProperties().contentType();
+ }
+
+ /**
+ * Set the contentType property: The content type of the secret.
+ *
+ * @param contentType the contentType value to set.
+ * @return the SecretInner object itself.
+ */
+ public SecretInner withContentType(String contentType) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecretProperties();
+ }
+ this.innerProperties().withContentType(contentType);
+ return this;
+ }
+
+ /**
+ * Get the attributes property: The attributes of the secret.
+ *
+ * @return the attributes value.
+ */
+ public SecretAttributes attributes() {
+ return this.innerProperties() == null ? null : this.innerProperties().attributes();
+ }
+
+ /**
+ * Set the attributes property: The attributes of the secret.
+ *
+ * @param attributes the attributes value to set.
+ * @return the SecretInner object itself.
+ */
+ public SecretInner withAttributes(SecretAttributes attributes) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new SecretProperties();
+ }
+ this.innerProperties().withAttributes(attributes);
+ return this;
+ }
+
+ /**
+ * Get the secretUri property: The URI to retrieve the current version of the secret.
+ *
+ * @return the secretUri value.
+ */
+ public String secretUri() {
+ return this.innerProperties() == null ? null : this.innerProperties().secretUri();
+ }
+
+ /**
+ * Get the secretUriWithVersion property: The URI to retrieve the specific version of the secret.
+ *
+ * @return the secretUriWithVersion value.
+ */
+ public String secretUriWithVersion() {
+ return this.innerProperties() == null ? null : this.innerProperties().secretUriWithVersion();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Missing required property innerProperties in model SecretInner"));
+ } else {
+ innerProperties().validate();
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(SecretInner.class);
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("location", location());
+ jsonWriter.writeMapField("tags", tags(), (writer, element) -> writer.writeString(element));
+ jsonWriter.writeJsonField("properties", this.innerProperties);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of SecretInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of SecretInner if the JsonReader was pointing to an instance of it, or null if it was
+ * pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the SecretInner.
+ */
+ public static SecretInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ SecretInner deserializedSecretInner = new SecretInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedSecretInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedSecretInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedSecretInner.type = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedSecretInner.withLocation(reader.getString());
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedSecretInner.withTags(tags);
+ } else if ("properties".equals(fieldName)) {
+ deserializedSecretInner.innerProperties = SecretProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedSecretInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedSecretInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/SecretProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/SecretProperties.java
new file mode 100644
index 000000000000..dc0a9586300f
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/SecretProperties.java
@@ -0,0 +1,191 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.SecretAttributes;
+import java.io.IOException;
+
+/**
+ * Properties of the secret.
+ */
+@Fluent
+public final class SecretProperties implements JsonSerializable {
+ /*
+ * The value of the secret. NOTE: 'value' will never be returned from the service, as APIs using this model are is
+ * intended for internal use in ARM deployments. Users should use the data-plane REST service for interaction with
+ * vault secrets.
+ */
+ private String value;
+
+ /*
+ * The content type of the secret.
+ */
+ private String contentType;
+
+ /*
+ * The attributes of the secret.
+ */
+ private SecretAttributes attributes;
+
+ /*
+ * The URI to retrieve the current version of the secret.
+ */
+ private String secretUri;
+
+ /*
+ * The URI to retrieve the specific version of the secret.
+ */
+ private String secretUriWithVersion;
+
+ /**
+ * Creates an instance of SecretProperties class.
+ */
+ public SecretProperties() {
+ }
+
+ /**
+ * Get the value property: The value of the secret. NOTE: 'value' will never be returned from the service, as APIs
+ * using this model are is intended for internal use in ARM deployments. Users should use the data-plane REST
+ * service for interaction with vault secrets.
+ *
+ * @return the value value.
+ */
+ public String value() {
+ return this.value;
+ }
+
+ /**
+ * Set the value property: The value of the secret. NOTE: 'value' will never be returned from the service, as APIs
+ * using this model are is intended for internal use in ARM deployments. Users should use the data-plane REST
+ * service for interaction with vault secrets.
+ *
+ * @param value the value value to set.
+ * @return the SecretProperties object itself.
+ */
+ public SecretProperties withValue(String value) {
+ this.value = value;
+ return this;
+ }
+
+ /**
+ * Get the contentType property: The content type of the secret.
+ *
+ * @return the contentType value.
+ */
+ public String contentType() {
+ return this.contentType;
+ }
+
+ /**
+ * Set the contentType property: The content type of the secret.
+ *
+ * @param contentType the contentType value to set.
+ * @return the SecretProperties object itself.
+ */
+ public SecretProperties withContentType(String contentType) {
+ this.contentType = contentType;
+ return this;
+ }
+
+ /**
+ * Get the attributes property: The attributes of the secret.
+ *
+ * @return the attributes value.
+ */
+ public SecretAttributes attributes() {
+ return this.attributes;
+ }
+
+ /**
+ * Set the attributes property: The attributes of the secret.
+ *
+ * @param attributes the attributes value to set.
+ * @return the SecretProperties object itself.
+ */
+ public SecretProperties withAttributes(SecretAttributes attributes) {
+ this.attributes = attributes;
+ return this;
+ }
+
+ /**
+ * Get the secretUri property: The URI to retrieve the current version of the secret.
+ *
+ * @return the secretUri value.
+ */
+ public String secretUri() {
+ return this.secretUri;
+ }
+
+ /**
+ * Get the secretUriWithVersion property: The URI to retrieve the specific version of the secret.
+ *
+ * @return the secretUriWithVersion value.
+ */
+ public String secretUriWithVersion() {
+ return this.secretUriWithVersion;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (attributes() != null) {
+ attributes().validate();
+ }
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("value", this.value);
+ jsonWriter.writeStringField("contentType", this.contentType);
+ jsonWriter.writeJsonField("attributes", this.attributes);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of SecretProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of SecretProperties if the JsonReader was pointing to an instance of it, or null if it was
+ * pointing to JSON null.
+ * @throws IOException If an error occurs while reading the SecretProperties.
+ */
+ public static SecretProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ SecretProperties deserializedSecretProperties = new SecretProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("value".equals(fieldName)) {
+ deserializedSecretProperties.value = reader.getString();
+ } else if ("contentType".equals(fieldName)) {
+ deserializedSecretProperties.contentType = reader.getString();
+ } else if ("attributes".equals(fieldName)) {
+ deserializedSecretProperties.attributes = SecretAttributes.fromJson(reader);
+ } else if ("secretUri".equals(fieldName)) {
+ deserializedSecretProperties.secretUri = reader.getString();
+ } else if ("secretUriWithVersion".equals(fieldName)) {
+ deserializedSecretProperties.secretUriWithVersion = reader.getString();
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedSecretProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultAccessPolicyParametersInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultAccessPolicyParametersInner.java
new file mode 100644
index 000000000000..4b8f1789869a
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultAccessPolicyParametersInner.java
@@ -0,0 +1,171 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.VaultAccessPolicyProperties;
+import java.io.IOException;
+
+/**
+ * Parameters for updating the access policy in a vault.
+ */
+@Fluent
+public final class VaultAccessPolicyParametersInner implements JsonSerializable {
+ /*
+ * The resource id of the access policy.
+ */
+ private String id;
+
+ /*
+ * The resource name of the access policy.
+ */
+ private String name;
+
+ /*
+ * The resource name of the access policy.
+ */
+ private String type;
+
+ /*
+ * The resource type of the access policy.
+ */
+ private String location;
+
+ /*
+ * Properties of the access policy
+ */
+ private VaultAccessPolicyProperties properties;
+
+ /**
+ * Creates an instance of VaultAccessPolicyParametersInner class.
+ */
+ public VaultAccessPolicyParametersInner() {
+ }
+
+ /**
+ * Get the id property: The resource id of the access policy.
+ *
+ * @return the id value.
+ */
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * Get the name property: The resource name of the access policy.
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the type property: The resource name of the access policy.
+ *
+ * @return the type value.
+ */
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the location property: The resource type of the access policy.
+ *
+ * @return the location value.
+ */
+ public String location() {
+ return this.location;
+ }
+
+ /**
+ * Get the properties property: Properties of the access policy.
+ *
+ * @return the properties value.
+ */
+ public VaultAccessPolicyProperties properties() {
+ return this.properties;
+ }
+
+ /**
+ * Set the properties property: Properties of the access policy.
+ *
+ * @param properties the properties value to set.
+ * @return the VaultAccessPolicyParametersInner object itself.
+ */
+ public VaultAccessPolicyParametersInner withProperties(VaultAccessPolicyProperties properties) {
+ this.properties = properties;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (properties() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Missing required property properties in model VaultAccessPolicyParametersInner"));
+ } else {
+ properties().validate();
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(VaultAccessPolicyParametersInner.class);
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeJsonField("properties", this.properties);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of VaultAccessPolicyParametersInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of VaultAccessPolicyParametersInner if the JsonReader was pointing to an instance of it, or
+ * null if it was pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the VaultAccessPolicyParametersInner.
+ */
+ public static VaultAccessPolicyParametersInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ VaultAccessPolicyParametersInner deserializedVaultAccessPolicyParametersInner
+ = new VaultAccessPolicyParametersInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("properties".equals(fieldName)) {
+ deserializedVaultAccessPolicyParametersInner.properties
+ = VaultAccessPolicyProperties.fromJson(reader);
+ } else if ("id".equals(fieldName)) {
+ deserializedVaultAccessPolicyParametersInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedVaultAccessPolicyParametersInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedVaultAccessPolicyParametersInner.type = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedVaultAccessPolicyParametersInner.location = reader.getString();
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedVaultAccessPolicyParametersInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultInner.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultInner.java
new file mode 100644
index 000000000000..8ac6e3443615
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultInner.java
@@ -0,0 +1,597 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.Resource;
+import com.azure.core.management.SystemData;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.AccessPolicyEntry;
+import com.azure.resourcemanager.keyvault.generated.models.KeyVaultCreateMode;
+import com.azure.resourcemanager.keyvault.generated.models.KeyVaultProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.NetworkRuleSet;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateEndpointConnectionItem;
+import com.azure.resourcemanager.keyvault.generated.models.Sku;
+import java.io.IOException;
+import java.util.List;
+import java.util.Map;
+import java.util.UUID;
+
+/**
+ * Resource information with extended details.
+ */
+@Fluent
+public final class VaultInner extends Resource {
+ /*
+ * Properties of the vault
+ */
+ private VaultProperties innerProperties = new VaultProperties();
+
+ /*
+ * Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ */
+ private SystemData systemData;
+
+ /*
+ * The type of the resource.
+ */
+ private String type;
+
+ /*
+ * The name of the resource.
+ */
+ private String name;
+
+ /*
+ * Fully qualified resource Id for the resource.
+ */
+ private String id;
+
+ /**
+ * Creates an instance of VaultInner class.
+ */
+ public VaultInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Properties of the vault.
+ *
+ * @return the innerProperties value.
+ */
+ private VaultProperties 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 type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ @Override
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Get the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ @Override
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ @Override
+ public String id() {
+ return this.id;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public VaultInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public VaultInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
+ /**
+ * Get the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the key vault.
+ *
+ * @return the tenantId value.
+ */
+ public UUID tenantId() {
+ return this.innerProperties() == null ? null : this.innerProperties().tenantId();
+ }
+
+ /**
+ * Set the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the key vault.
+ *
+ * @param tenantId the tenantId value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withTenantId(UUID tenantId) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withTenantId(tenantId);
+ return this;
+ }
+
+ /**
+ * Get the sku property: SKU details.
+ *
+ * @return the sku value.
+ */
+ public Sku sku() {
+ return this.innerProperties() == null ? null : this.innerProperties().sku();
+ }
+
+ /**
+ * Set the sku property: SKU details.
+ *
+ * @param sku the sku value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withSku(Sku sku) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withSku(sku);
+ return this;
+ }
+
+ /**
+ * Get the accessPolicies property: An array of 0 to 1024 identities that have access to the key vault. All
+ * identities in the array must use the same tenant ID as the key vault's tenant ID. When `createMode` is set to
+ * `recover`, access policies are not required. Otherwise, access policies are required.
+ *
+ * @return the accessPolicies value.
+ */
+ public List accessPolicies() {
+ return this.innerProperties() == null ? null : this.innerProperties().accessPolicies();
+ }
+
+ /**
+ * Set the accessPolicies property: An array of 0 to 1024 identities that have access to the key vault. All
+ * identities in the array must use the same tenant ID as the key vault's tenant ID. When `createMode` is set to
+ * `recover`, access policies are not required. Otherwise, access policies are required.
+ *
+ * @param accessPolicies the accessPolicies value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withAccessPolicies(List accessPolicies) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withAccessPolicies(accessPolicies);
+ return this;
+ }
+
+ /**
+ * Get the vaultUri property: The URI of the vault for performing operations on keys and secrets.
+ *
+ * @return the vaultUri value.
+ */
+ public String vaultUri() {
+ return this.innerProperties() == null ? null : this.innerProperties().vaultUri();
+ }
+
+ /**
+ * Set the vaultUri property: The URI of the vault for performing operations on keys and secrets.
+ *
+ * @param vaultUri the vaultUri value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withVaultUri(String vaultUri) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withVaultUri(vaultUri);
+ return this;
+ }
+
+ /**
+ * Get the hsmPoolResourceId property: The resource id of HSM Pool.
+ *
+ * @return the hsmPoolResourceId value.
+ */
+ public String hsmPoolResourceId() {
+ return this.innerProperties() == null ? null : this.innerProperties().hsmPoolResourceId();
+ }
+
+ /**
+ * Get the enabledForDeployment property: Property to specify whether Azure Virtual Machines are permitted to
+ * retrieve certificates stored as secrets from the key vault.
+ *
+ * @return the enabledForDeployment value.
+ */
+ public Boolean enabledForDeployment() {
+ return this.innerProperties() == null ? null : this.innerProperties().enabledForDeployment();
+ }
+
+ /**
+ * Set the enabledForDeployment property: Property to specify whether Azure Virtual Machines are permitted to
+ * retrieve certificates stored as secrets from the key vault.
+ *
+ * @param enabledForDeployment the enabledForDeployment value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withEnabledForDeployment(Boolean enabledForDeployment) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withEnabledForDeployment(enabledForDeployment);
+ return this;
+ }
+
+ /**
+ * Get the enabledForDiskEncryption property: Property to specify whether Azure Disk Encryption is permitted to
+ * retrieve secrets from the vault and unwrap keys.
+ *
+ * @return the enabledForDiskEncryption value.
+ */
+ public Boolean enabledForDiskEncryption() {
+ return this.innerProperties() == null ? null : this.innerProperties().enabledForDiskEncryption();
+ }
+
+ /**
+ * Set the enabledForDiskEncryption property: Property to specify whether Azure Disk Encryption is permitted to
+ * retrieve secrets from the vault and unwrap keys.
+ *
+ * @param enabledForDiskEncryption the enabledForDiskEncryption value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withEnabledForDiskEncryption(Boolean enabledForDiskEncryption) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withEnabledForDiskEncryption(enabledForDiskEncryption);
+ return this;
+ }
+
+ /**
+ * Get the enabledForTemplateDeployment property: Property to specify whether Azure Resource Manager is permitted to
+ * retrieve secrets from the key vault.
+ *
+ * @return the enabledForTemplateDeployment value.
+ */
+ public Boolean enabledForTemplateDeployment() {
+ return this.innerProperties() == null ? null : this.innerProperties().enabledForTemplateDeployment();
+ }
+
+ /**
+ * Set the enabledForTemplateDeployment property: Property to specify whether Azure Resource Manager is permitted to
+ * retrieve secrets from the key vault.
+ *
+ * @param enabledForTemplateDeployment the enabledForTemplateDeployment value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withEnabledForTemplateDeployment(Boolean enabledForTemplateDeployment) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withEnabledForTemplateDeployment(enabledForTemplateDeployment);
+ return this;
+ }
+
+ /**
+ * Get the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this key vault. If it's not set to any value(true or false) when creating new key vault, it will be set to true
+ * by default. Once set to true, it cannot be reverted to false.
+ *
+ * @return the enableSoftDelete value.
+ */
+ public Boolean enableSoftDelete() {
+ return this.innerProperties() == null ? null : this.innerProperties().enableSoftDelete();
+ }
+
+ /**
+ * Set the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this key vault. If it's not set to any value(true or false) when creating new key vault, it will be set to true
+ * by default. Once set to true, it cannot be reverted to false.
+ *
+ * @param enableSoftDelete the enableSoftDelete value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withEnableSoftDelete(Boolean enableSoftDelete) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withEnableSoftDelete(enableSoftDelete);
+ return this;
+ }
+
+ /**
+ * Get the softDeleteRetentionInDays property: softDelete data retention days. It accepts >=7 and <=90.
+ *
+ * @return the softDeleteRetentionInDays value.
+ */
+ public Integer softDeleteRetentionInDays() {
+ return this.innerProperties() == null ? null : this.innerProperties().softDeleteRetentionInDays();
+ }
+
+ /**
+ * Set the softDeleteRetentionInDays property: softDelete data retention days. It accepts >=7 and <=90.
+ *
+ * @param softDeleteRetentionInDays the softDeleteRetentionInDays value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withSoftDeleteRetentionInDays(Integer softDeleteRetentionInDays) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withSoftDeleteRetentionInDays(softDeleteRetentionInDays);
+ return this;
+ }
+
+ /**
+ * Get the enableRbacAuthorization property: Property that controls how data actions are authorized. When true, the
+ * key vault will use Role Based Access Control (RBAC) for authorization of data actions, and the access policies
+ * specified in vault properties will be ignored. When false, the key vault will use the access policies specified
+ * in vault properties, and any policy stored on Azure Resource Manager will be ignored. If null or not specified,
+ * the vault is created with the default value of false. Note that management actions are always authorized with
+ * RBAC.
+ *
+ * @return the enableRbacAuthorization value.
+ */
+ public Boolean enableRbacAuthorization() {
+ return this.innerProperties() == null ? null : this.innerProperties().enableRbacAuthorization();
+ }
+
+ /**
+ * Set the enableRbacAuthorization property: Property that controls how data actions are authorized. When true, the
+ * key vault will use Role Based Access Control (RBAC) for authorization of data actions, and the access policies
+ * specified in vault properties will be ignored. When false, the key vault will use the access policies specified
+ * in vault properties, and any policy stored on Azure Resource Manager will be ignored. If null or not specified,
+ * the vault is created with the default value of false. Note that management actions are always authorized with
+ * RBAC.
+ *
+ * @param enableRbacAuthorization the enableRbacAuthorization value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withEnableRbacAuthorization(Boolean enableRbacAuthorization) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withEnableRbacAuthorization(enableRbacAuthorization);
+ return this;
+ }
+
+ /**
+ * Get the createMode property: The vault's create mode to indicate whether the vault need to be recovered or not.
+ *
+ * @return the createMode value.
+ */
+ public KeyVaultCreateMode createMode() {
+ return this.innerProperties() == null ? null : this.innerProperties().createMode();
+ }
+
+ /**
+ * Set the createMode property: The vault's create mode to indicate whether the vault need to be recovered or not.
+ *
+ * @param createMode the createMode value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withCreateMode(KeyVaultCreateMode createMode) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withCreateMode(createMode);
+ return this;
+ }
+
+ /**
+ * Get the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * vault. Setting this property to true activates protection against purge for this vault and its content - only the
+ * Key Vault service may initiate a hard, irrecoverable deletion. The setting is effective only if soft delete is
+ * also enabled. Enabling this functionality is irreversible - that is, the property does not accept false as its
+ * value.
+ *
+ * @return the enablePurgeProtection value.
+ */
+ public Boolean enablePurgeProtection() {
+ return this.innerProperties() == null ? null : this.innerProperties().enablePurgeProtection();
+ }
+
+ /**
+ * Set the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * vault. Setting this property to true activates protection against purge for this vault and its content - only the
+ * Key Vault service may initiate a hard, irrecoverable deletion. The setting is effective only if soft delete is
+ * also enabled. Enabling this functionality is irreversible - that is, the property does not accept false as its
+ * value.
+ *
+ * @param enablePurgeProtection the enablePurgeProtection value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withEnablePurgeProtection(Boolean enablePurgeProtection) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withEnablePurgeProtection(enablePurgeProtection);
+ return this;
+ }
+
+ /**
+ * Get the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @return the networkAcls value.
+ */
+ public NetworkRuleSet networkAcls() {
+ return this.innerProperties() == null ? null : this.innerProperties().networkAcls();
+ }
+
+ /**
+ * Set the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @param networkAcls the networkAcls value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withNetworkAcls(NetworkRuleSet networkAcls) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withNetworkAcls(networkAcls);
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the vault.
+ *
+ * @return the provisioningState value.
+ */
+ public KeyVaultProvisioningState provisioningState() {
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
+ }
+
+ /**
+ * Set the provisioningState property: Provisioning state of the vault.
+ *
+ * @param provisioningState the provisioningState value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withProvisioningState(KeyVaultProvisioningState provisioningState) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withProvisioningState(provisioningState);
+ return this;
+ }
+
+ /**
+ * Get the privateEndpointConnections property: List of private endpoint connections associated with the key vault.
+ *
+ * @return the privateEndpointConnections value.
+ */
+ public List privateEndpointConnections() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpointConnections();
+ }
+
+ /**
+ * Get the publicNetworkAccess property: Property to specify whether the vault will accept traffic from public
+ * internet. If set to 'disabled' all traffic except private endpoint traffic and that that originates from trusted
+ * services will be blocked. This will override the set firewall rules, meaning that even if the firewall rules are
+ * present we will not honor the rules.
+ *
+ * @return the publicNetworkAccess value.
+ */
+ public String publicNetworkAccess() {
+ return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess();
+ }
+
+ /**
+ * Set the publicNetworkAccess property: Property to specify whether the vault will accept traffic from public
+ * internet. If set to 'disabled' all traffic except private endpoint traffic and that that originates from trusted
+ * services will be blocked. This will override the set firewall rules, meaning that even if the firewall rules are
+ * present we will not honor the rules.
+ *
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
+ * @return the VaultInner object itself.
+ */
+ public VaultInner withPublicNetworkAccess(String publicNetworkAccess) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new VaultProperties();
+ }
+ this.innerProperties().withPublicNetworkAccess(publicNetworkAccess);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Missing required property innerProperties in model VaultInner"));
+ } else {
+ innerProperties().validate();
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(VaultInner.class);
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("location", location());
+ jsonWriter.writeMapField("tags", tags(), (writer, element) -> writer.writeString(element));
+ jsonWriter.writeJsonField("properties", this.innerProperties);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of VaultInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of VaultInner if the JsonReader was pointing to an instance of it, or null if it was pointing
+ * to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the VaultInner.
+ */
+ public static VaultInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ VaultInner deserializedVaultInner = new VaultInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedVaultInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedVaultInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedVaultInner.type = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedVaultInner.withLocation(reader.getString());
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedVaultInner.withTags(tags);
+ } else if ("properties".equals(fieldName)) {
+ deserializedVaultInner.innerProperties = VaultProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedVaultInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedVaultInner;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultProperties.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultProperties.java
new file mode 100644
index 000000000000..23e0c7720d57
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/VaultProperties.java
@@ -0,0 +1,613 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.json.JsonReader;
+import com.azure.json.JsonSerializable;
+import com.azure.json.JsonToken;
+import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.keyvault.generated.models.AccessPolicyEntry;
+import com.azure.resourcemanager.keyvault.generated.models.KeyVaultCreateMode;
+import com.azure.resourcemanager.keyvault.generated.models.KeyVaultProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.NetworkRuleSet;
+import com.azure.resourcemanager.keyvault.generated.models.PrivateEndpointConnectionItem;
+import com.azure.resourcemanager.keyvault.generated.models.Sku;
+import java.io.IOException;
+import java.util.List;
+import java.util.Objects;
+import java.util.UUID;
+
+/**
+ * Properties of the vault.
+ */
+@Fluent
+public final class VaultProperties implements JsonSerializable {
+ /*
+ * The Azure Active Directory tenant ID that should be used for authenticating requests to the key vault.
+ */
+ private UUID tenantId;
+
+ /*
+ * SKU details
+ */
+ private Sku sku;
+
+ /*
+ * An array of 0 to 1024 identities that have access to the key vault. All identities in the array must use the same
+ * tenant ID as the key vault's tenant ID. When `createMode` is set to `recover`, access policies are not required.
+ * Otherwise, access policies are required.
+ */
+ private List accessPolicies;
+
+ /*
+ * The URI of the vault for performing operations on keys and secrets.
+ */
+ private String vaultUri;
+
+ /*
+ * The resource id of HSM Pool.
+ */
+ private String hsmPoolResourceId;
+
+ /*
+ * Property to specify whether Azure Virtual Machines are permitted to retrieve certificates stored as secrets from
+ * the key vault.
+ */
+ private Boolean enabledForDeployment;
+
+ /*
+ * Property to specify whether Azure Disk Encryption is permitted to retrieve secrets from the vault and unwrap
+ * keys.
+ */
+ private Boolean enabledForDiskEncryption;
+
+ /*
+ * Property to specify whether Azure Resource Manager is permitted to retrieve secrets from the key vault.
+ */
+ private Boolean enabledForTemplateDeployment;
+
+ /*
+ * Property to specify whether the 'soft delete' functionality is enabled for this key vault. If it's not set to any
+ * value(true or false) when creating new key vault, it will be set to true by default. Once set to true, it cannot
+ * be reverted to false.
+ */
+ private Boolean enableSoftDelete;
+
+ /*
+ * softDelete data retention days. It accepts >=7 and <=90.
+ */
+ private Integer softDeleteRetentionInDays;
+
+ /*
+ * Property that controls how data actions are authorized. When true, the key vault will use Role Based Access
+ * Control (RBAC) for authorization of data actions, and the access policies specified in vault properties will be
+ * ignored. When false, the key vault will use the access policies specified in vault properties, and any policy
+ * stored on Azure Resource Manager will be ignored. If null or not specified, the vault is created with the default
+ * value of false. Note that management actions are always authorized with RBAC.
+ */
+ private Boolean enableRbacAuthorization;
+
+ /*
+ * The vault's create mode to indicate whether the vault need to be recovered or not.
+ */
+ private KeyVaultCreateMode createMode;
+
+ /*
+ * Property specifying whether protection against purge is enabled for this vault. Setting this property to true
+ * activates protection against purge for this vault and its content - only the Key Vault service may initiate a
+ * hard, irrecoverable deletion. The setting is effective only if soft delete is also enabled. Enabling this
+ * functionality is irreversible - that is, the property does not accept false as its value.
+ */
+ private Boolean enablePurgeProtection;
+
+ /*
+ * Rules governing the accessibility of the key vault from specific network locations.
+ */
+ private NetworkRuleSet networkAcls;
+
+ /*
+ * Provisioning state of the vault.
+ */
+ private KeyVaultProvisioningState provisioningState;
+
+ /*
+ * List of private endpoint connections associated with the key vault.
+ */
+ private List privateEndpointConnections;
+
+ /*
+ * Property to specify whether the vault will accept traffic from public internet. If set to 'disabled' all traffic
+ * except private endpoint traffic and that that originates from trusted services will be blocked. This will
+ * override the set firewall rules, meaning that even if the firewall rules are present we will not honor the rules.
+ */
+ private String publicNetworkAccess;
+
+ /**
+ * Creates an instance of VaultProperties class.
+ */
+ public VaultProperties() {
+ }
+
+ /**
+ * Get the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the key vault.
+ *
+ * @return the tenantId value.
+ */
+ public UUID tenantId() {
+ return this.tenantId;
+ }
+
+ /**
+ * Set the tenantId property: The Azure Active Directory tenant ID that should be used for authenticating requests
+ * to the key vault.
+ *
+ * @param tenantId the tenantId value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withTenantId(UUID tenantId) {
+ this.tenantId = tenantId;
+ return this;
+ }
+
+ /**
+ * Get the sku property: SKU details.
+ *
+ * @return the sku value.
+ */
+ public Sku sku() {
+ return this.sku;
+ }
+
+ /**
+ * Set the sku property: SKU details.
+ *
+ * @param sku the sku value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withSku(Sku sku) {
+ this.sku = sku;
+ return this;
+ }
+
+ /**
+ * Get the accessPolicies property: An array of 0 to 1024 identities that have access to the key vault. All
+ * identities in the array must use the same tenant ID as the key vault's tenant ID. When `createMode` is set to
+ * `recover`, access policies are not required. Otherwise, access policies are required.
+ *
+ * @return the accessPolicies value.
+ */
+ public List accessPolicies() {
+ return this.accessPolicies;
+ }
+
+ /**
+ * Set the accessPolicies property: An array of 0 to 1024 identities that have access to the key vault. All
+ * identities in the array must use the same tenant ID as the key vault's tenant ID. When `createMode` is set to
+ * `recover`, access policies are not required. Otherwise, access policies are required.
+ *
+ * @param accessPolicies the accessPolicies value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withAccessPolicies(List accessPolicies) {
+ this.accessPolicies = accessPolicies;
+ return this;
+ }
+
+ /**
+ * Get the vaultUri property: The URI of the vault for performing operations on keys and secrets.
+ *
+ * @return the vaultUri value.
+ */
+ public String vaultUri() {
+ return this.vaultUri;
+ }
+
+ /**
+ * Set the vaultUri property: The URI of the vault for performing operations on keys and secrets.
+ *
+ * @param vaultUri the vaultUri value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withVaultUri(String vaultUri) {
+ this.vaultUri = vaultUri;
+ return this;
+ }
+
+ /**
+ * Get the hsmPoolResourceId property: The resource id of HSM Pool.
+ *
+ * @return the hsmPoolResourceId value.
+ */
+ public String hsmPoolResourceId() {
+ return this.hsmPoolResourceId;
+ }
+
+ /**
+ * Get the enabledForDeployment property: Property to specify whether Azure Virtual Machines are permitted to
+ * retrieve certificates stored as secrets from the key vault.
+ *
+ * @return the enabledForDeployment value.
+ */
+ public Boolean enabledForDeployment() {
+ return this.enabledForDeployment;
+ }
+
+ /**
+ * Set the enabledForDeployment property: Property to specify whether Azure Virtual Machines are permitted to
+ * retrieve certificates stored as secrets from the key vault.
+ *
+ * @param enabledForDeployment the enabledForDeployment value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withEnabledForDeployment(Boolean enabledForDeployment) {
+ this.enabledForDeployment = enabledForDeployment;
+ return this;
+ }
+
+ /**
+ * Get the enabledForDiskEncryption property: Property to specify whether Azure Disk Encryption is permitted to
+ * retrieve secrets from the vault and unwrap keys.
+ *
+ * @return the enabledForDiskEncryption value.
+ */
+ public Boolean enabledForDiskEncryption() {
+ return this.enabledForDiskEncryption;
+ }
+
+ /**
+ * Set the enabledForDiskEncryption property: Property to specify whether Azure Disk Encryption is permitted to
+ * retrieve secrets from the vault and unwrap keys.
+ *
+ * @param enabledForDiskEncryption the enabledForDiskEncryption value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withEnabledForDiskEncryption(Boolean enabledForDiskEncryption) {
+ this.enabledForDiskEncryption = enabledForDiskEncryption;
+ return this;
+ }
+
+ /**
+ * Get the enabledForTemplateDeployment property: Property to specify whether Azure Resource Manager is permitted to
+ * retrieve secrets from the key vault.
+ *
+ * @return the enabledForTemplateDeployment value.
+ */
+ public Boolean enabledForTemplateDeployment() {
+ return this.enabledForTemplateDeployment;
+ }
+
+ /**
+ * Set the enabledForTemplateDeployment property: Property to specify whether Azure Resource Manager is permitted to
+ * retrieve secrets from the key vault.
+ *
+ * @param enabledForTemplateDeployment the enabledForTemplateDeployment value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withEnabledForTemplateDeployment(Boolean enabledForTemplateDeployment) {
+ this.enabledForTemplateDeployment = enabledForTemplateDeployment;
+ return this;
+ }
+
+ /**
+ * Get the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this key vault. If it's not set to any value(true or false) when creating new key vault, it will be set to true
+ * by default. Once set to true, it cannot be reverted to false.
+ *
+ * @return the enableSoftDelete value.
+ */
+ public Boolean enableSoftDelete() {
+ return this.enableSoftDelete;
+ }
+
+ /**
+ * Set the enableSoftDelete property: Property to specify whether the 'soft delete' functionality is enabled for
+ * this key vault. If it's not set to any value(true or false) when creating new key vault, it will be set to true
+ * by default. Once set to true, it cannot be reverted to false.
+ *
+ * @param enableSoftDelete the enableSoftDelete value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withEnableSoftDelete(Boolean enableSoftDelete) {
+ this.enableSoftDelete = enableSoftDelete;
+ return this;
+ }
+
+ /**
+ * Get the softDeleteRetentionInDays property: softDelete data retention days. It accepts >=7 and <=90.
+ *
+ * @return the softDeleteRetentionInDays value.
+ */
+ public Integer softDeleteRetentionInDays() {
+ return this.softDeleteRetentionInDays;
+ }
+
+ /**
+ * Set the softDeleteRetentionInDays property: softDelete data retention days. It accepts >=7 and <=90.
+ *
+ * @param softDeleteRetentionInDays the softDeleteRetentionInDays value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withSoftDeleteRetentionInDays(Integer softDeleteRetentionInDays) {
+ this.softDeleteRetentionInDays = softDeleteRetentionInDays;
+ return this;
+ }
+
+ /**
+ * Get the enableRbacAuthorization property: Property that controls how data actions are authorized. When true, the
+ * key vault will use Role Based Access Control (RBAC) for authorization of data actions, and the access policies
+ * specified in vault properties will be ignored. When false, the key vault will use the access policies specified
+ * in vault properties, and any policy stored on Azure Resource Manager will be ignored. If null or not specified,
+ * the vault is created with the default value of false. Note that management actions are always authorized with
+ * RBAC.
+ *
+ * @return the enableRbacAuthorization value.
+ */
+ public Boolean enableRbacAuthorization() {
+ return this.enableRbacAuthorization;
+ }
+
+ /**
+ * Set the enableRbacAuthorization property: Property that controls how data actions are authorized. When true, the
+ * key vault will use Role Based Access Control (RBAC) for authorization of data actions, and the access policies
+ * specified in vault properties will be ignored. When false, the key vault will use the access policies specified
+ * in vault properties, and any policy stored on Azure Resource Manager will be ignored. If null or not specified,
+ * the vault is created with the default value of false. Note that management actions are always authorized with
+ * RBAC.
+ *
+ * @param enableRbacAuthorization the enableRbacAuthorization value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withEnableRbacAuthorization(Boolean enableRbacAuthorization) {
+ this.enableRbacAuthorization = enableRbacAuthorization;
+ return this;
+ }
+
+ /**
+ * Get the createMode property: The vault's create mode to indicate whether the vault need to be recovered or not.
+ *
+ * @return the createMode value.
+ */
+ public KeyVaultCreateMode createMode() {
+ return this.createMode;
+ }
+
+ /**
+ * Set the createMode property: The vault's create mode to indicate whether the vault need to be recovered or not.
+ *
+ * @param createMode the createMode value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withCreateMode(KeyVaultCreateMode createMode) {
+ this.createMode = createMode;
+ return this;
+ }
+
+ /**
+ * Get the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * vault. Setting this property to true activates protection against purge for this vault and its content - only the
+ * Key Vault service may initiate a hard, irrecoverable deletion. The setting is effective only if soft delete is
+ * also enabled. Enabling this functionality is irreversible - that is, the property does not accept false as its
+ * value.
+ *
+ * @return the enablePurgeProtection value.
+ */
+ public Boolean enablePurgeProtection() {
+ return this.enablePurgeProtection;
+ }
+
+ /**
+ * Set the enablePurgeProtection property: Property specifying whether protection against purge is enabled for this
+ * vault. Setting this property to true activates protection against purge for this vault and its content - only the
+ * Key Vault service may initiate a hard, irrecoverable deletion. The setting is effective only if soft delete is
+ * also enabled. Enabling this functionality is irreversible - that is, the property does not accept false as its
+ * value.
+ *
+ * @param enablePurgeProtection the enablePurgeProtection value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withEnablePurgeProtection(Boolean enablePurgeProtection) {
+ this.enablePurgeProtection = enablePurgeProtection;
+ return this;
+ }
+
+ /**
+ * Get the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @return the networkAcls value.
+ */
+ public NetworkRuleSet networkAcls() {
+ return this.networkAcls;
+ }
+
+ /**
+ * Set the networkAcls property: Rules governing the accessibility of the key vault from specific network locations.
+ *
+ * @param networkAcls the networkAcls value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withNetworkAcls(NetworkRuleSet networkAcls) {
+ this.networkAcls = networkAcls;
+ return this;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the vault.
+ *
+ * @return the provisioningState value.
+ */
+ public KeyVaultProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Set the provisioningState property: Provisioning state of the vault.
+ *
+ * @param provisioningState the provisioningState value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withProvisioningState(KeyVaultProvisioningState provisioningState) {
+ this.provisioningState = provisioningState;
+ return this;
+ }
+
+ /**
+ * Get the privateEndpointConnections property: List of private endpoint connections associated with the key vault.
+ *
+ * @return the privateEndpointConnections value.
+ */
+ public List privateEndpointConnections() {
+ return this.privateEndpointConnections;
+ }
+
+ /**
+ * Get the publicNetworkAccess property: Property to specify whether the vault will accept traffic from public
+ * internet. If set to 'disabled' all traffic except private endpoint traffic and that that originates from trusted
+ * services will be blocked. This will override the set firewall rules, meaning that even if the firewall rules are
+ * present we will not honor the rules.
+ *
+ * @return the publicNetworkAccess value.
+ */
+ public String publicNetworkAccess() {
+ return this.publicNetworkAccess;
+ }
+
+ /**
+ * Set the publicNetworkAccess property: Property to specify whether the vault will accept traffic from public
+ * internet. If set to 'disabled' all traffic except private endpoint traffic and that that originates from trusted
+ * services will be blocked. This will override the set firewall rules, meaning that even if the firewall rules are
+ * present we will not honor the rules.
+ *
+ * @param publicNetworkAccess the publicNetworkAccess value to set.
+ * @return the VaultProperties object itself.
+ */
+ public VaultProperties withPublicNetworkAccess(String publicNetworkAccess) {
+ this.publicNetworkAccess = publicNetworkAccess;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (tenantId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Missing required property tenantId in model VaultProperties"));
+ }
+ if (sku() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Missing required property sku in model VaultProperties"));
+ } else {
+ sku().validate();
+ }
+ if (accessPolicies() != null) {
+ accessPolicies().forEach(e -> e.validate());
+ }
+ if (networkAcls() != null) {
+ networkAcls().validate();
+ }
+ if (privateEndpointConnections() != null) {
+ privateEndpointConnections().forEach(e -> e.validate());
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(VaultProperties.class);
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("tenantId", Objects.toString(this.tenantId, null));
+ jsonWriter.writeJsonField("sku", this.sku);
+ jsonWriter.writeArrayField("accessPolicies", this.accessPolicies,
+ (writer, element) -> writer.writeJson(element));
+ jsonWriter.writeStringField("vaultUri", this.vaultUri);
+ jsonWriter.writeBooleanField("enabledForDeployment", this.enabledForDeployment);
+ jsonWriter.writeBooleanField("enabledForDiskEncryption", this.enabledForDiskEncryption);
+ jsonWriter.writeBooleanField("enabledForTemplateDeployment", this.enabledForTemplateDeployment);
+ jsonWriter.writeBooleanField("enableSoftDelete", this.enableSoftDelete);
+ jsonWriter.writeNumberField("softDeleteRetentionInDays", this.softDeleteRetentionInDays);
+ jsonWriter.writeBooleanField("enableRbacAuthorization", this.enableRbacAuthorization);
+ jsonWriter.writeStringField("createMode", this.createMode == null ? null : this.createMode.toString());
+ jsonWriter.writeBooleanField("enablePurgeProtection", this.enablePurgeProtection);
+ jsonWriter.writeJsonField("networkAcls", this.networkAcls);
+ jsonWriter.writeStringField("provisioningState",
+ this.provisioningState == null ? null : this.provisioningState.toString());
+ jsonWriter.writeStringField("publicNetworkAccess", this.publicNetworkAccess);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of VaultProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of VaultProperties if the JsonReader was pointing to an instance of it, or null if it was
+ * pointing to JSON null.
+ * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @throws IOException If an error occurs while reading the VaultProperties.
+ */
+ public static VaultProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ VaultProperties deserializedVaultProperties = new VaultProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("tenantId".equals(fieldName)) {
+ deserializedVaultProperties.tenantId
+ = reader.getNullable(nonNullReader -> UUID.fromString(nonNullReader.getString()));
+ } else if ("sku".equals(fieldName)) {
+ deserializedVaultProperties.sku = Sku.fromJson(reader);
+ } else if ("accessPolicies".equals(fieldName)) {
+ List accessPolicies
+ = reader.readArray(reader1 -> AccessPolicyEntry.fromJson(reader1));
+ deserializedVaultProperties.accessPolicies = accessPolicies;
+ } else if ("vaultUri".equals(fieldName)) {
+ deserializedVaultProperties.vaultUri = reader.getString();
+ } else if ("hsmPoolResourceId".equals(fieldName)) {
+ deserializedVaultProperties.hsmPoolResourceId = reader.getString();
+ } else if ("enabledForDeployment".equals(fieldName)) {
+ deserializedVaultProperties.enabledForDeployment = reader.getNullable(JsonReader::getBoolean);
+ } else if ("enabledForDiskEncryption".equals(fieldName)) {
+ deserializedVaultProperties.enabledForDiskEncryption = reader.getNullable(JsonReader::getBoolean);
+ } else if ("enabledForTemplateDeployment".equals(fieldName)) {
+ deserializedVaultProperties.enabledForTemplateDeployment
+ = reader.getNullable(JsonReader::getBoolean);
+ } else if ("enableSoftDelete".equals(fieldName)) {
+ deserializedVaultProperties.enableSoftDelete = reader.getNullable(JsonReader::getBoolean);
+ } else if ("softDeleteRetentionInDays".equals(fieldName)) {
+ deserializedVaultProperties.softDeleteRetentionInDays = reader.getNullable(JsonReader::getInt);
+ } else if ("enableRbacAuthorization".equals(fieldName)) {
+ deserializedVaultProperties.enableRbacAuthorization = reader.getNullable(JsonReader::getBoolean);
+ } else if ("createMode".equals(fieldName)) {
+ deserializedVaultProperties.createMode = KeyVaultCreateMode.fromString(reader.getString());
+ } else if ("enablePurgeProtection".equals(fieldName)) {
+ deserializedVaultProperties.enablePurgeProtection = reader.getNullable(JsonReader::getBoolean);
+ } else if ("networkAcls".equals(fieldName)) {
+ deserializedVaultProperties.networkAcls = NetworkRuleSet.fromJson(reader);
+ } else if ("provisioningState".equals(fieldName)) {
+ deserializedVaultProperties.provisioningState
+ = KeyVaultProvisioningState.fromString(reader.getString());
+ } else if ("privateEndpointConnections".equals(fieldName)) {
+ List privateEndpointConnections
+ = reader.readArray(reader1 -> PrivateEndpointConnectionItem.fromJson(reader1));
+ deserializedVaultProperties.privateEndpointConnections = privateEndpointConnections;
+ } else if ("publicNetworkAccess".equals(fieldName)) {
+ deserializedVaultProperties.publicNetworkAccess = reader.getString();
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedVaultProperties;
+ });
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/package-info.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/package-info.java
new file mode 100644
index 000000000000..9792b9ea734c
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/models/package-info.java
@@ -0,0 +1,9 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+/**
+ * Package containing the inner data models for AzureStorageResourceManagementApi.
+ * The Azure management API provides a RESTful set of web services that interact with Azure Key Vault.
+ */
+package com.azure.resourcemanager.keyvault.generated.fluent.models;
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/package-info.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/package-info.java
new file mode 100644
index 000000000000..f0894c39da02
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/fluent/package-info.java
@@ -0,0 +1,9 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+/**
+ * Package containing the service clients for AzureStorageResourceManagementApi.
+ * The Azure management API provides a RESTful set of web services that interact with Azure Key Vault.
+ */
+package com.azure.resourcemanager.keyvault.generated.fluent;
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/AzureStorageResourceManagementApiBuilder.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/AzureStorageResourceManagementApiBuilder.java
new file mode 100644
index 000000000000..311cae964f8d
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/AzureStorageResourceManagementApiBuilder.java
@@ -0,0 +1,138 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.implementation;
+
+import com.azure.core.annotation.ServiceClientBuilder;
+import com.azure.core.http.HttpPipeline;
+import com.azure.core.http.HttpPipelineBuilder;
+import com.azure.core.http.policy.RetryPolicy;
+import com.azure.core.http.policy.UserAgentPolicy;
+import com.azure.core.management.AzureEnvironment;
+import com.azure.core.management.serializer.SerializerFactory;
+import com.azure.core.util.serializer.SerializerAdapter;
+import java.time.Duration;
+
+/**
+ * A builder for creating a new instance of the AzureStorageResourceManagementApiImpl type.
+ */
+@ServiceClientBuilder(serviceClients = { AzureStorageResourceManagementApiImpl.class })
+public final class AzureStorageResourceManagementApiBuilder {
+ /*
+ * The ID of the target subscription. The value must be an UUID.
+ */
+ private String subscriptionId;
+
+ /**
+ * Sets The ID of the target subscription. The value must be an UUID.
+ *
+ * @param subscriptionId the subscriptionId value.
+ * @return the AzureStorageResourceManagementApiBuilder.
+ */
+ public AzureStorageResourceManagementApiBuilder subscriptionId(String subscriptionId) {
+ this.subscriptionId = subscriptionId;
+ return this;
+ }
+
+ /*
+ * server parameter
+ */
+ private String endpoint;
+
+ /**
+ * Sets server parameter.
+ *
+ * @param endpoint the endpoint value.
+ * @return the AzureStorageResourceManagementApiBuilder.
+ */
+ public AzureStorageResourceManagementApiBuilder endpoint(String endpoint) {
+ this.endpoint = endpoint;
+ return this;
+ }
+
+ /*
+ * The environment to connect to
+ */
+ private AzureEnvironment environment;
+
+ /**
+ * Sets The environment to connect to.
+ *
+ * @param environment the environment value.
+ * @return the AzureStorageResourceManagementApiBuilder.
+ */
+ public AzureStorageResourceManagementApiBuilder environment(AzureEnvironment environment) {
+ this.environment = environment;
+ return this;
+ }
+
+ /*
+ * The HTTP pipeline to send requests through
+ */
+ private HttpPipeline pipeline;
+
+ /**
+ * Sets The HTTP pipeline to send requests through.
+ *
+ * @param pipeline the pipeline value.
+ * @return the AzureStorageResourceManagementApiBuilder.
+ */
+ public AzureStorageResourceManagementApiBuilder pipeline(HttpPipeline pipeline) {
+ this.pipeline = pipeline;
+ return this;
+ }
+
+ /*
+ * The default poll interval for long-running operation
+ */
+ private Duration defaultPollInterval;
+
+ /**
+ * Sets The default poll interval for long-running operation.
+ *
+ * @param defaultPollInterval the defaultPollInterval value.
+ * @return the AzureStorageResourceManagementApiBuilder.
+ */
+ public AzureStorageResourceManagementApiBuilder defaultPollInterval(Duration defaultPollInterval) {
+ this.defaultPollInterval = defaultPollInterval;
+ return this;
+ }
+
+ /*
+ * The serializer to serialize an object into a string
+ */
+ private SerializerAdapter serializerAdapter;
+
+ /**
+ * Sets The serializer to serialize an object into a string.
+ *
+ * @param serializerAdapter the serializerAdapter value.
+ * @return the AzureStorageResourceManagementApiBuilder.
+ */
+ public AzureStorageResourceManagementApiBuilder serializerAdapter(SerializerAdapter serializerAdapter) {
+ this.serializerAdapter = serializerAdapter;
+ return this;
+ }
+
+ /**
+ * Builds an instance of AzureStorageResourceManagementApiImpl with the provided parameters.
+ *
+ * @return an instance of AzureStorageResourceManagementApiImpl.
+ */
+ public AzureStorageResourceManagementApiImpl buildClient() {
+ String localEndpoint = (endpoint != null) ? endpoint : "https://management.azure.com";
+ AzureEnvironment localEnvironment = (environment != null) ? environment : AzureEnvironment.AZURE;
+ HttpPipeline localPipeline = (pipeline != null)
+ ? pipeline
+ : new HttpPipelineBuilder().policies(new UserAgentPolicy(), new RetryPolicy()).build();
+ Duration localDefaultPollInterval
+ = (defaultPollInterval != null) ? defaultPollInterval : Duration.ofSeconds(30);
+ SerializerAdapter localSerializerAdapter = (serializerAdapter != null)
+ ? serializerAdapter
+ : SerializerFactory.createDefaultManagementSerializerAdapter();
+ AzureStorageResourceManagementApiImpl client = new AzureStorageResourceManagementApiImpl(localPipeline,
+ localSerializerAdapter, localDefaultPollInterval, localEnvironment, this.subscriptionId, localEndpoint);
+ return client;
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/AzureStorageResourceManagementApiImpl.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/AzureStorageResourceManagementApiImpl.java
new file mode 100644
index 000000000000..4cc7ad9be321
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/AzureStorageResourceManagementApiImpl.java
@@ -0,0 +1,416 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.implementation;
+
+import com.azure.core.annotation.ServiceClient;
+import com.azure.core.http.HttpHeaderName;
+import com.azure.core.http.HttpHeaders;
+import com.azure.core.http.HttpPipeline;
+import com.azure.core.http.HttpResponse;
+import com.azure.core.http.rest.Response;
+import com.azure.core.management.AzureEnvironment;
+import com.azure.core.management.exception.ManagementError;
+import com.azure.core.management.exception.ManagementException;
+import com.azure.core.management.polling.PollResult;
+import com.azure.core.management.polling.PollerFactory;
+import com.azure.core.util.Context;
+import com.azure.core.util.CoreUtils;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.core.util.polling.AsyncPollResponse;
+import com.azure.core.util.polling.LongRunningOperationStatus;
+import com.azure.core.util.polling.PollerFlux;
+import com.azure.core.util.serializer.SerializerAdapter;
+import com.azure.core.util.serializer.SerializerEncoding;
+import com.azure.resourcemanager.keyvault.generated.fluent.AzureStorageResourceManagementApi;
+import com.azure.resourcemanager.keyvault.generated.fluent.ManagedHsmsClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.MhsmPrivateEndpointConnectionsClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.MhsmPrivateLinkResourcesClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.MhsmRegionsClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.OperationsClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.PrivateEndpointConnectionsClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.PrivateLinkResourcesClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.SecretsClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.VaultsClient;
+import java.io.IOException;
+import java.lang.reflect.Type;
+import java.nio.ByteBuffer;
+import java.nio.charset.Charset;
+import java.nio.charset.StandardCharsets;
+import java.time.Duration;
+import reactor.core.publisher.Flux;
+import reactor.core.publisher.Mono;
+
+/**
+ * Initializes a new instance of the AzureStorageResourceManagementApiImpl type.
+ */
+@ServiceClient(builder = AzureStorageResourceManagementApiBuilder.class)
+public final class AzureStorageResourceManagementApiImpl implements AzureStorageResourceManagementApi {
+ /**
+ * The ID of the target subscription. The value must be an UUID.
+ */
+ private final String subscriptionId;
+
+ /**
+ * Gets The ID of the target subscription. The value must be an UUID.
+ *
+ * @return the subscriptionId value.
+ */
+ public String getSubscriptionId() {
+ return this.subscriptionId;
+ }
+
+ /**
+ * server parameter.
+ */
+ private final String endpoint;
+
+ /**
+ * Gets server parameter.
+ *
+ * @return the endpoint value.
+ */
+ public String getEndpoint() {
+ return this.endpoint;
+ }
+
+ /**
+ * Api Version.
+ */
+ private final String apiVersion;
+
+ /**
+ * Gets Api Version.
+ *
+ * @return the apiVersion value.
+ */
+ public String getApiVersion() {
+ return this.apiVersion;
+ }
+
+ /**
+ * The HTTP pipeline to send requests through.
+ */
+ private final HttpPipeline httpPipeline;
+
+ /**
+ * Gets The HTTP pipeline to send requests through.
+ *
+ * @return the httpPipeline value.
+ */
+ public HttpPipeline getHttpPipeline() {
+ return this.httpPipeline;
+ }
+
+ /**
+ * The serializer to serialize an object into a string.
+ */
+ private final SerializerAdapter serializerAdapter;
+
+ /**
+ * Gets The serializer to serialize an object into a string.
+ *
+ * @return the serializerAdapter value.
+ */
+ SerializerAdapter getSerializerAdapter() {
+ return this.serializerAdapter;
+ }
+
+ /**
+ * The default poll interval for long-running operation.
+ */
+ private final Duration defaultPollInterval;
+
+ /**
+ * Gets The default poll interval for long-running operation.
+ *
+ * @return the defaultPollInterval value.
+ */
+ public Duration getDefaultPollInterval() {
+ return this.defaultPollInterval;
+ }
+
+ /**
+ * The OperationsClient object to access its operations.
+ */
+ private final OperationsClient operations;
+
+ /**
+ * Gets the OperationsClient object to access its operations.
+ *
+ * @return the OperationsClient object.
+ */
+ public OperationsClient getOperations() {
+ return this.operations;
+ }
+
+ /**
+ * The ManagedHsmsClient object to access its operations.
+ */
+ private final ManagedHsmsClient managedHsms;
+
+ /**
+ * Gets the ManagedHsmsClient object to access its operations.
+ *
+ * @return the ManagedHsmsClient object.
+ */
+ public ManagedHsmsClient getManagedHsms() {
+ return this.managedHsms;
+ }
+
+ /**
+ * The VaultsClient object to access its operations.
+ */
+ private final VaultsClient vaults;
+
+ /**
+ * Gets the VaultsClient object to access its operations.
+ *
+ * @return the VaultsClient object.
+ */
+ public VaultsClient getVaults() {
+ return this.vaults;
+ }
+
+ /**
+ * The MhsmPrivateEndpointConnectionsClient object to access its operations.
+ */
+ private final MhsmPrivateEndpointConnectionsClient mhsmPrivateEndpointConnections;
+
+ /**
+ * Gets the MhsmPrivateEndpointConnectionsClient object to access its operations.
+ *
+ * @return the MhsmPrivateEndpointConnectionsClient object.
+ */
+ public MhsmPrivateEndpointConnectionsClient getMhsmPrivateEndpointConnections() {
+ return this.mhsmPrivateEndpointConnections;
+ }
+
+ /**
+ * The MhsmPrivateLinkResourcesClient object to access its operations.
+ */
+ private final MhsmPrivateLinkResourcesClient mhsmPrivateLinkResources;
+
+ /**
+ * Gets the MhsmPrivateLinkResourcesClient object to access its operations.
+ *
+ * @return the MhsmPrivateLinkResourcesClient object.
+ */
+ public MhsmPrivateLinkResourcesClient getMhsmPrivateLinkResources() {
+ return this.mhsmPrivateLinkResources;
+ }
+
+ /**
+ * The MhsmRegionsClient object to access its operations.
+ */
+ private final MhsmRegionsClient mhsmRegions;
+
+ /**
+ * Gets the MhsmRegionsClient object to access its operations.
+ *
+ * @return the MhsmRegionsClient object.
+ */
+ public MhsmRegionsClient getMhsmRegions() {
+ return this.mhsmRegions;
+ }
+
+ /**
+ * The PrivateEndpointConnectionsClient object to access its operations.
+ */
+ private final PrivateEndpointConnectionsClient privateEndpointConnections;
+
+ /**
+ * Gets the PrivateEndpointConnectionsClient object to access its operations.
+ *
+ * @return the PrivateEndpointConnectionsClient object.
+ */
+ public PrivateEndpointConnectionsClient getPrivateEndpointConnections() {
+ return this.privateEndpointConnections;
+ }
+
+ /**
+ * The PrivateLinkResourcesClient object to access its operations.
+ */
+ private final PrivateLinkResourcesClient privateLinkResources;
+
+ /**
+ * Gets the PrivateLinkResourcesClient object to access its operations.
+ *
+ * @return the PrivateLinkResourcesClient object.
+ */
+ public PrivateLinkResourcesClient getPrivateLinkResources() {
+ return this.privateLinkResources;
+ }
+
+ /**
+ * The SecretsClient object to access its operations.
+ */
+ private final SecretsClient secrets;
+
+ /**
+ * Gets the SecretsClient object to access its operations.
+ *
+ * @return the SecretsClient object.
+ */
+ public SecretsClient getSecrets() {
+ return this.secrets;
+ }
+
+ /**
+ * Initializes an instance of AzureStorageResourceManagementApi client.
+ *
+ * @param httpPipeline The HTTP pipeline to send requests through.
+ * @param serializerAdapter The serializer to serialize an object into a string.
+ * @param defaultPollInterval The default poll interval for long-running operation.
+ * @param environment The Azure environment.
+ * @param subscriptionId The ID of the target subscription. The value must be an UUID.
+ * @param endpoint server parameter.
+ */
+ AzureStorageResourceManagementApiImpl(HttpPipeline httpPipeline, SerializerAdapter serializerAdapter,
+ Duration defaultPollInterval, AzureEnvironment environment, String subscriptionId, String endpoint) {
+ this.httpPipeline = httpPipeline;
+ this.serializerAdapter = serializerAdapter;
+ this.defaultPollInterval = defaultPollInterval;
+ this.subscriptionId = subscriptionId;
+ this.endpoint = endpoint;
+ this.apiVersion = "2024-11-01";
+ this.operations = new OperationsClientImpl(this);
+ this.managedHsms = new ManagedHsmsClientImpl(this);
+ this.vaults = new VaultsClientImpl(this);
+ this.mhsmPrivateEndpointConnections = new MhsmPrivateEndpointConnectionsClientImpl(this);
+ this.mhsmPrivateLinkResources = new MhsmPrivateLinkResourcesClientImpl(this);
+ this.mhsmRegions = new MhsmRegionsClientImpl(this);
+ this.privateEndpointConnections = new PrivateEndpointConnectionsClientImpl(this);
+ this.privateLinkResources = new PrivateLinkResourcesClientImpl(this);
+ this.secrets = new SecretsClientImpl(this);
+ }
+
+ /**
+ * Gets default client context.
+ *
+ * @return the default client context.
+ */
+ public Context getContext() {
+ return Context.NONE;
+ }
+
+ /**
+ * Merges default client context with provided context.
+ *
+ * @param context the context to be merged with default client context.
+ * @return the merged context.
+ */
+ public Context mergeContext(Context context) {
+ return CoreUtils.mergeContexts(this.getContext(), context);
+ }
+
+ /**
+ * Gets long running operation result.
+ *
+ * @param activationResponse the response of activation operation.
+ * @param httpPipeline the http pipeline.
+ * @param pollResultType type of poll result.
+ * @param finalResultType type of final result.
+ * @param context the context shared by all requests.
+ * @param type of poll result.
+ * @param type of final result.
+ * @return poller flux for poll result and final result.
+ */
+ public PollerFlux, U> getLroResult(Mono>> activationResponse,
+ HttpPipeline httpPipeline, Type pollResultType, Type finalResultType, Context context) {
+ return PollerFactory.create(serializerAdapter, httpPipeline, pollResultType, finalResultType,
+ defaultPollInterval, activationResponse, context);
+ }
+
+ /**
+ * Gets the final result, or an error, based on last async poll response.
+ *
+ * @param response the last async poll response.
+ * @param type of poll result.
+ * @param type of final result.
+ * @return the final result, or an error.
+ */
+ public Mono getLroFinalResultOrError(AsyncPollResponse, U> response) {
+ if (response.getStatus() != LongRunningOperationStatus.SUCCESSFULLY_COMPLETED) {
+ String errorMessage;
+ ManagementError managementError = null;
+ HttpResponse errorResponse = null;
+ PollResult.Error lroError = response.getValue().getError();
+ if (lroError != null) {
+ errorResponse = new HttpResponseImpl(lroError.getResponseStatusCode(), lroError.getResponseHeaders(),
+ lroError.getResponseBody());
+
+ errorMessage = response.getValue().getError().getMessage();
+ String errorBody = response.getValue().getError().getResponseBody();
+ if (errorBody != null) {
+ // try to deserialize error body to ManagementError
+ try {
+ managementError = this.getSerializerAdapter()
+ .deserialize(errorBody, ManagementError.class, SerializerEncoding.JSON);
+ if (managementError.getCode() == null || managementError.getMessage() == null) {
+ managementError = null;
+ }
+ } catch (IOException | RuntimeException ioe) {
+ LOGGER.logThrowableAsWarning(ioe);
+ }
+ }
+ } else {
+ // fallback to default error message
+ errorMessage = "Long running operation failed.";
+ }
+ if (managementError == null) {
+ // fallback to default ManagementError
+ managementError = new ManagementError(response.getStatus().toString(), errorMessage);
+ }
+ return Mono.error(new ManagementException(errorMessage, errorResponse, managementError));
+ } else {
+ return response.getFinalResult();
+ }
+ }
+
+ private static final class HttpResponseImpl extends HttpResponse {
+ private final int statusCode;
+
+ private final byte[] responseBody;
+
+ private final HttpHeaders httpHeaders;
+
+ HttpResponseImpl(int statusCode, HttpHeaders httpHeaders, String responseBody) {
+ super(null);
+ this.statusCode = statusCode;
+ this.httpHeaders = httpHeaders;
+ this.responseBody = responseBody == null ? null : responseBody.getBytes(StandardCharsets.UTF_8);
+ }
+
+ public int getStatusCode() {
+ return statusCode;
+ }
+
+ public String getHeaderValue(String s) {
+ return httpHeaders.getValue(HttpHeaderName.fromString(s));
+ }
+
+ public HttpHeaders getHeaders() {
+ return httpHeaders;
+ }
+
+ public Flux getBody() {
+ return Flux.just(ByteBuffer.wrap(responseBody));
+ }
+
+ public Mono getBodyAsByteArray() {
+ return Mono.just(responseBody);
+ }
+
+ public Mono getBodyAsString() {
+ return Mono.just(new String(responseBody, StandardCharsets.UTF_8));
+ }
+
+ public Mono getBodyAsString(Charset charset) {
+ return Mono.just(new String(responseBody, charset));
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(AzureStorageResourceManagementApiImpl.class);
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/CheckMhsmNameAvailabilityResultImpl.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/CheckMhsmNameAvailabilityResultImpl.java
new file mode 100644
index 000000000000..db99aedf2226
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/CheckMhsmNameAvailabilityResultImpl.java
@@ -0,0 +1,41 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.implementation;
+
+import com.azure.resourcemanager.keyvault.generated.fluent.models.CheckMhsmNameAvailabilityResultInner;
+import com.azure.resourcemanager.keyvault.generated.models.CheckMhsmNameAvailabilityResult;
+import com.azure.resourcemanager.keyvault.generated.models.Reason;
+
+public final class CheckMhsmNameAvailabilityResultImpl implements CheckMhsmNameAvailabilityResult {
+ private CheckMhsmNameAvailabilityResultInner innerObject;
+
+ private final com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager;
+
+ CheckMhsmNameAvailabilityResultImpl(CheckMhsmNameAvailabilityResultInner innerObject,
+ com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ }
+
+ public Boolean nameAvailable() {
+ return this.innerModel().nameAvailable();
+ }
+
+ public Reason reason() {
+ return this.innerModel().reason();
+ }
+
+ public String message() {
+ return this.innerModel().message();
+ }
+
+ public CheckMhsmNameAvailabilityResultInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.keyvault.generated.KeyvaultManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/CheckNameAvailabilityResultImpl.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/CheckNameAvailabilityResultImpl.java
new file mode 100644
index 000000000000..9cc16364d2c3
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/CheckNameAvailabilityResultImpl.java
@@ -0,0 +1,41 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.implementation;
+
+import com.azure.resourcemanager.keyvault.generated.fluent.models.CheckNameAvailabilityResultInner;
+import com.azure.resourcemanager.keyvault.generated.models.CheckNameAvailabilityResult;
+import com.azure.resourcemanager.keyvault.generated.models.KeyVaultNameUnavailableReason;
+
+public final class CheckNameAvailabilityResultImpl implements CheckNameAvailabilityResult {
+ private CheckNameAvailabilityResultInner innerObject;
+
+ private final com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager;
+
+ CheckNameAvailabilityResultImpl(CheckNameAvailabilityResultInner innerObject,
+ com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ }
+
+ public Boolean nameAvailable() {
+ return this.innerModel().nameAvailable();
+ }
+
+ public KeyVaultNameUnavailableReason reason() {
+ return this.innerModel().reason();
+ }
+
+ public String message() {
+ return this.innerModel().message();
+ }
+
+ public CheckNameAvailabilityResultInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.keyvault.generated.KeyvaultManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/DeletedManagedHsmImpl.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/DeletedManagedHsmImpl.java
new file mode 100644
index 000000000000..693ed2d70a5d
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/DeletedManagedHsmImpl.java
@@ -0,0 +1,77 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.implementation;
+
+import com.azure.core.management.SystemData;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.DeletedManagedHsmInner;
+import com.azure.resourcemanager.keyvault.generated.models.DeletedManagedHsm;
+import java.time.OffsetDateTime;
+import java.util.Collections;
+import java.util.Map;
+
+public final class DeletedManagedHsmImpl implements DeletedManagedHsm {
+ private DeletedManagedHsmInner innerObject;
+
+ private final com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager;
+
+ DeletedManagedHsmImpl(DeletedManagedHsmInner innerObject,
+ com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = 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 mhsmId() {
+ return this.innerModel().mhsmId();
+ }
+
+ public String location() {
+ return this.innerModel().location();
+ }
+
+ public OffsetDateTime deletionDate() {
+ return this.innerModel().deletionDate();
+ }
+
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.innerModel().scheduledPurgeDate();
+ }
+
+ public Boolean purgeProtectionEnabled() {
+ return this.innerModel().purgeProtectionEnabled();
+ }
+
+ public Map tags() {
+ Map inner = this.innerModel().tags();
+ if (inner != null) {
+ return Collections.unmodifiableMap(inner);
+ } else {
+ return Collections.emptyMap();
+ }
+ }
+
+ public DeletedManagedHsmInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.keyvault.generated.KeyvaultManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/DeletedVaultImpl.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/DeletedVaultImpl.java
new file mode 100644
index 000000000000..cf64c86b3b33
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/DeletedVaultImpl.java
@@ -0,0 +1,77 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.implementation;
+
+import com.azure.core.management.SystemData;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.DeletedVaultInner;
+import com.azure.resourcemanager.keyvault.generated.models.DeletedVault;
+import java.time.OffsetDateTime;
+import java.util.Collections;
+import java.util.Map;
+
+public final class DeletedVaultImpl implements DeletedVault {
+ private DeletedVaultInner innerObject;
+
+ private final com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager;
+
+ DeletedVaultImpl(DeletedVaultInner innerObject,
+ com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = 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 vaultId() {
+ return this.innerModel().vaultId();
+ }
+
+ public String location() {
+ return this.innerModel().location();
+ }
+
+ public OffsetDateTime deletionDate() {
+ return this.innerModel().deletionDate();
+ }
+
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.innerModel().scheduledPurgeDate();
+ }
+
+ public Map tags() {
+ Map inner = this.innerModel().tags();
+ if (inner != null) {
+ return Collections.unmodifiableMap(inner);
+ } else {
+ return Collections.emptyMap();
+ }
+ }
+
+ public Boolean purgeProtectionEnabled() {
+ return this.innerModel().purgeProtectionEnabled();
+ }
+
+ public DeletedVaultInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.keyvault.generated.KeyvaultManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/ManagedHsmImpl.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/ManagedHsmImpl.java
new file mode 100644
index 000000000000..64542f48eca9
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/ManagedHsmImpl.java
@@ -0,0 +1,288 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.implementation;
+
+import com.azure.core.management.Region;
+import com.azure.core.management.SystemData;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.ManagedHsmInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.MhsmGeoReplicatedRegionInner;
+import com.azure.resourcemanager.keyvault.generated.models.CreateMode;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsm;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmProvisioningState;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmSecurityDomainProperties;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmGeoReplicatedRegion;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmNetworkRuleSet;
+import com.azure.resourcemanager.keyvault.generated.models.MhsmPrivateEndpointConnectionItem;
+import com.azure.resourcemanager.keyvault.generated.models.PublicNetworkAccess;
+import java.time.OffsetDateTime;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.UUID;
+import java.util.stream.Collectors;
+
+public final class ManagedHsmImpl implements ManagedHsm, ManagedHsm.Definition, ManagedHsm.Update {
+ private ManagedHsmInner innerObject;
+
+ private final com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager;
+
+ public String id() {
+ return this.innerModel().id();
+ }
+
+ public String name() {
+ return this.innerModel().name();
+ }
+
+ public String type() {
+ return this.innerModel().type();
+ }
+
+ public String location() {
+ return this.innerModel().location();
+ }
+
+ public Map tags() {
+ Map inner = this.innerModel().tags();
+ if (inner != null) {
+ return Collections.unmodifiableMap(inner);
+ } else {
+ return Collections.emptyMap();
+ }
+ }
+
+ public SystemData systemData() {
+ return this.innerModel().systemData();
+ }
+
+ public UUID tenantId() {
+ return this.innerModel().tenantId();
+ }
+
+ public List initialAdminObjectIds() {
+ List inner = this.innerModel().initialAdminObjectIds();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public String hsmUri() {
+ return this.innerModel().hsmUri();
+ }
+
+ public Boolean enableSoftDelete() {
+ return this.innerModel().enableSoftDelete();
+ }
+
+ public Integer softDeleteRetentionInDays() {
+ return this.innerModel().softDeleteRetentionInDays();
+ }
+
+ public Boolean enablePurgeProtection() {
+ return this.innerModel().enablePurgeProtection();
+ }
+
+ public CreateMode createMode() {
+ return this.innerModel().createMode();
+ }
+
+ public String statusMessage() {
+ return this.innerModel().statusMessage();
+ }
+
+ public ManagedHsmProvisioningState provisioningState() {
+ return this.innerModel().provisioningState();
+ }
+
+ public MhsmNetworkRuleSet networkAcls() {
+ return this.innerModel().networkAcls();
+ }
+
+ public List regions() {
+ List inner = this.innerModel().regions();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner.stream()
+ .map(inner1 -> new MhsmGeoReplicatedRegionImpl(inner1, this.manager()))
+ .collect(Collectors.toList()));
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public List privateEndpointConnections() {
+ List inner = this.innerModel().privateEndpointConnections();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public PublicNetworkAccess publicNetworkAccess() {
+ return this.innerModel().publicNetworkAccess();
+ }
+
+ public OffsetDateTime scheduledPurgeDate() {
+ return this.innerModel().scheduledPurgeDate();
+ }
+
+ public ManagedHsmSecurityDomainProperties securityDomainProperties() {
+ return this.innerModel().securityDomainProperties();
+ }
+
+ public Region region() {
+ return Region.fromName(this.regionName());
+ }
+
+ public String regionName() {
+ return this.location();
+ }
+
+ public String resourceGroupName() {
+ return resourceGroupName;
+ }
+
+ public ManagedHsmInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.keyvault.generated.KeyvaultManager manager() {
+ return this.serviceManager;
+ }
+
+ private String resourceGroupName;
+
+ private String name;
+
+ public ManagedHsmImpl withExistingResourceGroup(String resourceGroupName) {
+ this.resourceGroupName = resourceGroupName;
+ return this;
+ }
+
+ public ManagedHsm create() {
+ this.innerObject = serviceManager.serviceClient()
+ .getManagedHsms()
+ .createOrUpdate(resourceGroupName, name, this.innerModel(), Context.NONE);
+ return this;
+ }
+
+ public ManagedHsm create(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getManagedHsms()
+ .createOrUpdate(resourceGroupName, name, this.innerModel(), context);
+ return this;
+ }
+
+ ManagedHsmImpl(String name, com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager) {
+ this.innerObject = new ManagedHsmInner();
+ this.serviceManager = serviceManager;
+ this.name = name;
+ }
+
+ public ManagedHsmImpl update() {
+ return this;
+ }
+
+ public ManagedHsm apply() {
+ this.innerObject = serviceManager.serviceClient()
+ .getManagedHsms()
+ .update(resourceGroupName, name, this.innerModel(), Context.NONE);
+ return this;
+ }
+
+ public ManagedHsm apply(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getManagedHsms()
+ .update(resourceGroupName, name, this.innerModel(), context);
+ return this;
+ }
+
+ ManagedHsmImpl(ManagedHsmInner innerObject,
+ com.azure.resourcemanager.keyvault.generated.KeyvaultManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.name = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "managedHSMs");
+ }
+
+ public ManagedHsm refresh() {
+ this.innerObject = serviceManager.serviceClient()
+ .getManagedHsms()
+ .getByResourceGroupWithResponse(resourceGroupName, name, Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public ManagedHsm refresh(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getManagedHsms()
+ .getByResourceGroupWithResponse(resourceGroupName, name, context)
+ .getValue();
+ return this;
+ }
+
+ public ManagedHsmImpl withRegion(Region location) {
+ this.innerModel().withLocation(location.toString());
+ return this;
+ }
+
+ public ManagedHsmImpl withRegion(String location) {
+ this.innerModel().withLocation(location);
+ return this;
+ }
+
+ public ManagedHsmImpl withTags(Map tags) {
+ this.innerModel().withTags(tags);
+ return this;
+ }
+
+ public ManagedHsmImpl withTenantId(UUID tenantId) {
+ this.innerModel().withTenantId(tenantId);
+ return this;
+ }
+
+ public ManagedHsmImpl withInitialAdminObjectIds(List initialAdminObjectIds) {
+ this.innerModel().withInitialAdminObjectIds(initialAdminObjectIds);
+ return this;
+ }
+
+ public ManagedHsmImpl withEnableSoftDelete(Boolean enableSoftDelete) {
+ this.innerModel().withEnableSoftDelete(enableSoftDelete);
+ return this;
+ }
+
+ public ManagedHsmImpl withSoftDeleteRetentionInDays(Integer softDeleteRetentionInDays) {
+ this.innerModel().withSoftDeleteRetentionInDays(softDeleteRetentionInDays);
+ return this;
+ }
+
+ public ManagedHsmImpl withEnablePurgeProtection(Boolean enablePurgeProtection) {
+ this.innerModel().withEnablePurgeProtection(enablePurgeProtection);
+ return this;
+ }
+
+ public ManagedHsmImpl withCreateMode(CreateMode createMode) {
+ this.innerModel().withCreateMode(createMode);
+ return this;
+ }
+
+ public ManagedHsmImpl withNetworkAcls(MhsmNetworkRuleSet networkAcls) {
+ this.innerModel().withNetworkAcls(networkAcls);
+ return this;
+ }
+
+ public ManagedHsmImpl withRegions(List regions) {
+ this.innerModel().withRegions(regions);
+ return this;
+ }
+
+ public ManagedHsmImpl withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) {
+ this.innerModel().withPublicNetworkAccess(publicNetworkAccess);
+ return this;
+ }
+}
diff --git a/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/ManagedHsmsClientImpl.java b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/ManagedHsmsClientImpl.java
new file mode 100644
index 000000000000..07d2d874dd91
--- /dev/null
+++ b/sdk/keyvault/azure-resourcemanager-keyvault-generated/src/main/java/com/azure/resourcemanager/keyvault/generated/implementation/ManagedHsmsClientImpl.java
@@ -0,0 +1,1951 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.keyvault.generated.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.Patch;
+import com.azure.core.annotation.PathParam;
+import com.azure.core.annotation.Post;
+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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.FluxUtil;
+import com.azure.core.util.polling.PollerFlux;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.keyvault.generated.fluent.ManagedHsmsClient;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.CheckMhsmNameAvailabilityResultInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.DeletedManagedHsmInner;
+import com.azure.resourcemanager.keyvault.generated.fluent.models.ManagedHsmInner;
+import com.azure.resourcemanager.keyvault.generated.models.CheckMhsmNameAvailabilityParameters;
+import com.azure.resourcemanager.keyvault.generated.models.DeletedManagedHsmListResult;
+import com.azure.resourcemanager.keyvault.generated.models.ManagedHsmListResult;
+import java.nio.ByteBuffer;
+import reactor.core.publisher.Flux;
+import reactor.core.publisher.Mono;
+
+/**
+ * An instance of this class provides access to all the operations defined in ManagedHsmsClient.
+ */
+public final class ManagedHsmsClientImpl implements ManagedHsmsClient {
+ /**
+ * The proxy service used to perform REST calls.
+ */
+ private final ManagedHsmsService service;
+
+ /**
+ * The service client containing this operation class.
+ */
+ private final AzureStorageResourceManagementApiImpl client;
+
+ /**
+ * Initializes an instance of ManagedHsmsClientImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ ManagedHsmsClientImpl(AzureStorageResourceManagementApiImpl client) {
+ this.service
+ = RestProxy.create(ManagedHsmsService.class, client.getHttpPipeline(), client.getSerializerAdapter());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for AzureStorageResourceManagementApiManagedHsms to be used by the proxy
+ * service to perform REST calls.
+ */
+ @Host("{$host}")
+ @ServiceInterface(name = "AzureStorageResource")
+ public interface ManagedHsmsService {
+ @Headers({ "Content-Type: application/json" })
+ @Post("/subscriptions/{subscriptionId}/providers/Microsoft.KeyVault/checkMhsmNameAvailability")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> checkMhsmNameAvailability(
+ @HostParam("$host") String endpoint, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId,
+ @BodyParam("application/json") CheckMhsmNameAvailabilityParameters body,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.KeyVault/deletedManagedHSMs")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> list(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.KeyVault/locations/{location}/deletedManagedHSMs/{name}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> getDeleted(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("location") String location, @PathParam("name") String name,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Post("/subscriptions/{subscriptionId}/providers/Microsoft.KeyVault/locations/{location}/deletedManagedHSMs/{name}/purge")
+ @ExpectedResponses({ 202 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> purgeDeleted(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("location") String location, @PathParam("name") String name,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.KeyVault/managedHSMs")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listBySubscription(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @QueryParam("$top") Integer top, @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KeyVault/managedHSMs")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByResourceGroup(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("$top") Integer top,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KeyVault/managedHSMs/{name}")
+ @ExpectedResponses({ 200, 204 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> getByResourceGroup(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("name") String name,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KeyVault/managedHSMs/{name}")
+ @ExpectedResponses({ 200, 202 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> createOrUpdate(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("name") String name,
+ @BodyParam("application/json") ManagedHsmInner resource, @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Patch("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KeyVault/managedHSMs/{name}")
+ @ExpectedResponses({ 200, 202 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> update(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("name") String name,
+ @BodyParam("application/json") ManagedHsmInner properties, @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KeyVault/managedHSMs/{name}")
+ @ExpectedResponses({ 200, 202, 204 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> delete(@HostParam("$host") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("name") String name,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listDeletedNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listBySubscriptionNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByResourceGroupNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept, Context context);
+ }
+
+ /**
+ * Checks that the managed hsm name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckMhsmNameAvailability operation response along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ checkMhsmNameAvailabilityWithResponseAsync(CheckMhsmNameAvailabilityParameters body) {
+ 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 (body == null) {
+ return Mono.error(new IllegalArgumentException("Parameter body is required and cannot be null."));
+ } else {
+ body.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.checkMhsmNameAvailability(this.client.getEndpoint(),
+ this.client.getApiVersion(), this.client.getSubscriptionId(), body, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Checks that the managed hsm name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckMhsmNameAvailability operation response along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ checkMhsmNameAvailabilityWithResponseAsync(CheckMhsmNameAvailabilityParameters body, 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 (body == null) {
+ return Mono.error(new IllegalArgumentException("Parameter body is required and cannot be null."));
+ } else {
+ body.validate();
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service.checkMhsmNameAvailability(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), body, accept, context);
+ }
+
+ /**
+ * Checks that the managed hsm name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckMhsmNameAvailability operation response on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono
+ checkMhsmNameAvailabilityAsync(CheckMhsmNameAvailabilityParameters body) {
+ return checkMhsmNameAvailabilityWithResponseAsync(body).flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Checks that the managed hsm name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckMhsmNameAvailability operation response along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response
+ checkMhsmNameAvailabilityWithResponse(CheckMhsmNameAvailabilityParameters body, Context context) {
+ return checkMhsmNameAvailabilityWithResponseAsync(body, context).block();
+ }
+
+ /**
+ * Checks that the managed hsm name is valid and is not already in use.
+ *
+ * @param body The request body.
+ * @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 CheckMhsmNameAvailability operation response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public CheckMhsmNameAvailabilityResultInner checkMhsmNameAvailability(CheckMhsmNameAvailabilityParameters body) {
+ return checkMhsmNameAvailabilityWithResponse(body, Context.NONE).getValue();
+ }
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation along with {@link PagedResponse} on successful
+ * completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSinglePageAsync() {
+ 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."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.list(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), 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()));
+ }
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation along with {@link PagedResponse} on successful
+ * completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSinglePageAsync(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."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .list(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), accept,
+ context)
+ .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
+ res.getValue().value(), res.getValue().nextLink(), null));
+ }
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listAsync() {
+ return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listDeletedNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listAsync(Context context) {
+ return new PagedFlux<>(() -> listSinglePageAsync(context),
+ nextLink -> listDeletedNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable list() {
+ return new PagedIterable<>(listAsync());
+ }
+
+ /**
+ * The List operation gets information about the deleted managed HSMs associated with the subscription.
+ *
+ * @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 response of a DeletedManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable list(Context context) {
+ return new PagedIterable<>(listAsync(context));
+ }
+
+ /**
+ * Gets the specified deleted managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 specified deleted managed HSM along with {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getDeletedWithResponseAsync(String location, String name) {
+ 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 (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
+ }
+ if (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.getDeleted(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), location, name, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Gets the specified deleted managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 specified deleted managed HSM along with {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getDeletedWithResponseAsync(String location, String name,
+ 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 (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
+ }
+ if (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service.getDeleted(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), location, name, accept, context);
+ }
+
+ /**
+ * Gets the specified deleted managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 specified deleted managed HSM on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getDeletedAsync(String location, String name) {
+ return getDeletedWithResponseAsync(location, name).flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Gets the specified deleted managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 specified deleted managed HSM along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getDeletedWithResponse(String location, String name, Context context) {
+ return getDeletedWithResponseAsync(location, name, context).block();
+ }
+
+ /**
+ * Gets the specified deleted managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 specified deleted managed HSM.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public DeletedManagedHsmInner getDeleted(String location, String name) {
+ return getDeletedWithResponse(location, name, Context.NONE).getValue();
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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>> purgeDeletedWithResponseAsync(String location, String name) {
+ 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 (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
+ }
+ if (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.purgeDeleted(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), location, name, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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>> purgeDeletedWithResponseAsync(String location, String name,
+ 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 (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
+ }
+ if (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service.purgeDeleted(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), location, name, accept, context);
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 PollerFlux} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, Void> beginPurgeDeletedAsync(String location, String name) {
+ Mono>> mono = purgeDeletedWithResponseAsync(location, name);
+ return this.client.getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class,
+ this.client.getContext());
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 PollerFlux} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, Void> beginPurgeDeletedAsync(String location, String name, Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono = purgeDeletedWithResponseAsync(location, name, context);
+ return this.client.getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class,
+ context);
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, Void> beginPurgeDeleted(String location, String name) {
+ return this.beginPurgeDeletedAsync(location, name).getSyncPoller();
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 SyncPoller} for polling of long-running operation.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, Void> beginPurgeDeleted(String location, String name, Context context) {
+ return this.beginPurgeDeletedAsync(location, name, context).getSyncPoller();
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 purgeDeletedAsync(String location, String name) {
+ return beginPurgeDeletedAsync(location, name).last().flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 {@link Mono} that completes when a successful response is received.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono purgeDeletedAsync(String location, String name, Context context) {
+ return beginPurgeDeletedAsync(location, name, context).last().flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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 purgeDeleted(String location, String name) {
+ purgeDeletedAsync(location, name).block();
+ }
+
+ /**
+ * Permanently deletes the specified managed HSM.
+ *
+ * @param location The name of the Azure region.
+ * @param name The name of the deleted managed HSM.
+ * @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.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public void purgeDeleted(String location, String name, Context context) {
+ purgeDeletedAsync(location, name, context).block();
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation along with {@link PagedResponse} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listBySubscriptionSinglePageAsync(Integer top) {
+ 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."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.listBySubscription(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), top, 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()));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation along with {@link PagedResponse} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listBySubscriptionSinglePageAsync(Integer top, 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."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .listBySubscription(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
+ top, accept, context)
+ .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
+ res.getValue().value(), res.getValue().nextLink(), null));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listBySubscriptionAsync(Integer top) {
+ return new PagedFlux<>(() -> listBySubscriptionSinglePageAsync(top),
+ nextLink -> listBySubscriptionNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listBySubscriptionAsync() {
+ final Integer top = null;
+ return new PagedFlux<>(() -> listBySubscriptionSinglePageAsync(top),
+ nextLink -> listBySubscriptionNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listBySubscriptionAsync(Integer top, Context context) {
+ return new PagedFlux<>(() -> listBySubscriptionSinglePageAsync(top, context),
+ nextLink -> listBySubscriptionNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listBySubscription() {
+ final Integer top = null;
+ return new PagedIterable<>(listBySubscriptionAsync(top));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription.
+ *
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listBySubscription(Integer top, Context context) {
+ return new PagedIterable<>(listBySubscriptionAsync(top, context));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation along with {@link PagedResponse} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByResourceGroupSinglePageAsync(String resourceGroupName,
+ Integer top) {
+ 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."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.listByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, top, 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()));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation along with {@link PagedResponse} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByResourceGroupSinglePageAsync(String resourceGroupName,
+ Integer top, 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."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .listByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, top, accept, context)
+ .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
+ res.getValue().value(), res.getValue().nextLink(), null));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByResourceGroupAsync(String resourceGroupName, Integer top) {
+ return new PagedFlux<>(() -> listByResourceGroupSinglePageAsync(resourceGroupName, top),
+ nextLink -> listByResourceGroupNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByResourceGroupAsync(String resourceGroupName) {
+ final Integer top = null;
+ return new PagedFlux<>(() -> listByResourceGroupSinglePageAsync(resourceGroupName, top),
+ nextLink -> listByResourceGroupNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByResourceGroupAsync(String resourceGroupName, Integer top,
+ Context context) {
+ return new PagedFlux<>(() -> listByResourceGroupSinglePageAsync(resourceGroupName, top, context),
+ nextLink -> listByResourceGroupNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByResourceGroup(String resourceGroupName) {
+ final Integer top = null;
+ return new PagedIterable<>(listByResourceGroupAsync(resourceGroupName, top));
+ }
+
+ /**
+ * The List operation gets information about the managed HSM Pools associated with the subscription and within the
+ * specified resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param top Maximum number of results to return.
+ * @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 response of a ManagedHsm list operation as paginated response with {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByResourceGroup(String resourceGroupName, Integer top, Context context) {
+ return new PagedIterable<>(listByResourceGroupAsync(resourceGroupName, top, context));
+ }
+
+ /**
+ * Gets the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 specified managed HSM Pool along with {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getByResourceGroupWithResponseAsync(String resourceGroupName, String name) {
+ 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 (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.getByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, name, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Gets the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 specified managed HSM Pool along with {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getByResourceGroupWithResponseAsync(String resourceGroupName, String name,
+ 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 (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service.getByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, name, accept, context);
+ }
+
+ /**
+ * Gets the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 specified managed HSM Pool on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getByResourceGroupAsync(String resourceGroupName, String name) {
+ return getByResourceGroupWithResponseAsync(resourceGroupName, name)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Gets the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 specified managed HSM Pool along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getByResourceGroupWithResponse(String resourceGroupName, String name,
+ Context context) {
+ return getByResourceGroupWithResponseAsync(resourceGroupName, name, context).block();
+ }
+
+ /**
+ * Gets the specified managed HSM Pool.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @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 specified managed HSM Pool.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ManagedHsmInner getByResourceGroup(String resourceGroupName, String name) {
+ return getByResourceGroupWithResponse(resourceGroupName, name, Context.NONE).getValue();
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> createOrUpdateWithResponseAsync(String resourceGroupName, String name,
+ ManagedHsmInner resource) {
+ 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 (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ if (resource == null) {
+ return Mono.error(new IllegalArgumentException("Parameter resource is required and cannot be null."));
+ } else {
+ resource.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, name, resource, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> createOrUpdateWithResponseAsync(String resourceGroupName, String name,
+ ManagedHsmInner resource, 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 (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ if (resource == null) {
+ return Mono.error(new IllegalArgumentException("Parameter resource is required and cannot be null."));
+ } else {
+ resource.validate();
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, name, resource, accept, context);
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 PollerFlux} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ManagedHsmInner> beginCreateOrUpdateAsync(String resourceGroupName,
+ String name, ManagedHsmInner resource) {
+ Mono>> mono = createOrUpdateWithResponseAsync(resourceGroupName, name, resource);
+ return this.client.getLroResult(mono, this.client.getHttpPipeline(),
+ ManagedHsmInner.class, ManagedHsmInner.class, this.client.getContext());
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 PollerFlux} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ManagedHsmInner> beginCreateOrUpdateAsync(String resourceGroupName,
+ String name, ManagedHsmInner resource, Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono
+ = createOrUpdateWithResponseAsync(resourceGroupName, name, resource, context);
+ return this.client.getLroResult(mono, this.client.getHttpPipeline(),
+ ManagedHsmInner.class, ManagedHsmInner.class, context);
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ManagedHsmInner> beginCreateOrUpdate(String resourceGroupName,
+ String name, ManagedHsmInner resource) {
+ return this.beginCreateOrUpdateAsync(resourceGroupName, name, resource).getSyncPoller();
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ManagedHsmInner> beginCreateOrUpdate(String resourceGroupName,
+ String name, ManagedHsmInner resource, Context context) {
+ return this.beginCreateOrUpdateAsync(resourceGroupName, name, resource, context).getSyncPoller();
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createOrUpdateAsync(String resourceGroupName, String name, ManagedHsmInner resource) {
+ return beginCreateOrUpdateAsync(resourceGroupName, name, resource).last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createOrUpdateAsync(String resourceGroupName, String name, ManagedHsmInner resource,
+ Context context) {
+ return beginCreateOrUpdateAsync(resourceGroupName, name, resource, context).last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ManagedHsmInner createOrUpdate(String resourceGroupName, String name, ManagedHsmInner resource) {
+ return createOrUpdateAsync(resourceGroupName, name, resource).block();
+ }
+
+ /**
+ * Create or update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param resource Parameters to create or update the managed HSM Pool.
+ * @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 resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ManagedHsmInner createOrUpdate(String resourceGroupName, String name, ManagedHsmInner resource,
+ Context context) {
+ return createOrUpdateAsync(resourceGroupName, name, resource, context).block();
+ }
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 resource information with extended details along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> updateWithResponseAsync(String resourceGroupName, String name,
+ ManagedHsmInner properties) {
+ 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 (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ if (properties == null) {
+ return Mono.error(new IllegalArgumentException("Parameter properties is required and cannot be null."));
+ } else {
+ properties.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.update(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, name, properties, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 resource information with extended details along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> updateWithResponseAsync(String resourceGroupName, String name,
+ ManagedHsmInner properties, 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 (name == null) {
+ return Mono.error(new IllegalArgumentException("Parameter name is required and cannot be null."));
+ }
+ if (properties == null) {
+ return Mono.error(new IllegalArgumentException("Parameter properties is required and cannot be null."));
+ } else {
+ properties.validate();
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service.update(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
+ resourceGroupName, name, properties, accept, context);
+ }
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 PollerFlux} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ManagedHsmInner> beginUpdateAsync(String resourceGroupName,
+ String name, ManagedHsmInner properties) {
+ Mono>> mono = updateWithResponseAsync(resourceGroupName, name, properties);
+ return this.client.getLroResult(mono, this.client.getHttpPipeline(),
+ ManagedHsmInner.class, ManagedHsmInner.class, this.client.getContext());
+ }
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 PollerFlux} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ManagedHsmInner> beginUpdateAsync(String resourceGroupName,
+ String name, ManagedHsmInner properties, Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono = updateWithResponseAsync(resourceGroupName, name, properties, context);
+ return this.client.getLroResult(mono, this.client.getHttpPipeline(),
+ ManagedHsmInner.class, ManagedHsmInner.class, context);
+ }
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ManagedHsmInner> beginUpdate(String resourceGroupName, String name,
+ ManagedHsmInner properties) {
+ return this.beginUpdateAsync(resourceGroupName, name, properties).getSyncPoller();
+ }
+
+ /**
+ * Update a managed HSM Pool in the specified subscription.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param name The name of the managed HSM Pool.
+ * @param properties Parameters to patch the managed HSM Pool.
+ * @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 SyncPoller} for polling of resource information with extended details.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller