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 PrivateLinkScopes service API entry point.
+ *
+ * @param credential the credential to use.
+ * @param profile the Azure profile for client.
+ * @return the PrivateLinkScopes service API instance.
+ */
+ public PrivateLinkScopesManager 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.kubernetesconfigurationprivateli")
+ .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 PrivateLinkScopesManager(httpPipeline, profile, defaultPollInterval);
+ }
+ }
+
+ /**
+ * Gets the resource collection API of PrivateLinkScopes. It manages KubernetesConfigurationPrivateLinkScope.
+ *
+ * @return Resource collection API of PrivateLinkScopes.
+ */
+ public PrivateLinkScopes privateLinkScopes() {
+ if (this.privateLinkScopes == null) {
+ this.privateLinkScopes = new PrivateLinkScopesImpl(clientObject.getPrivateLinkScopes(), this);
+ }
+ return privateLinkScopes;
+ }
+
+ /**
+ * 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 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 wrapped service client PrivateLinkScopesManagementClient providing direct access to the underlying
+ * auto-generated API implementation, based on Azure REST API.
+ *
+ * @return Wrapped service client PrivateLinkScopesManagementClient.
+ */
+ public PrivateLinkScopesManagementClient serviceClient() {
+ return this.clientObject;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateEndpointConnectionsClient.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateEndpointConnectionsClient.java
new file mode 100644
index 000000000000..e731e5e3232d
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateEndpointConnectionsClient.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.kubernetesconfigurationprivateli.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+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.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionListResultInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in PrivateEndpointConnectionsClient.
+ */
+public interface PrivateEndpointConnectionsClient {
+ /**
+ * Gets a private endpoint connection.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a private endpoint connection along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, Context context);
+
+ /**
+ * Gets a private endpoint connection.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a private endpoint connection.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner get(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName);
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 the Private Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, PrivateEndpointConnectionInner> beginCreateOrUpdate(
+ String resourceGroupName, String scopeName, String privateEndpointConnectionName,
+ PrivateEndpointConnectionInner properties);
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 the Private Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, PrivateEndpointConnectionInner> beginCreateOrUpdate(
+ String resourceGroupName, String scopeName, String privateEndpointConnectionName,
+ PrivateEndpointConnectionInner properties, Context context);
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner createOrUpdate(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner properties);
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionInner createOrUpdate(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner properties, Context context);
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response deleteWithResponse(String resourceGroupName, String scopeName, String privateEndpointConnectionName,
+ Context context);
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String scopeName, String privateEndpointConnectionName);
+
+ /**
+ * Gets all private endpoint connections on a private link scope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return all private endpoint connections on a private link scope along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response listByPrivateLinkScopeWithResponse(String resourceGroupName,
+ String scopeName, Context context);
+
+ /**
+ * Gets all private endpoint connections on a private link scope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return all private endpoint connections on a private link scope.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateEndpointConnectionListResultInner listByPrivateLinkScope(String resourceGroupName, String scopeName);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkResourcesClient.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkResourcesClient.java
new file mode 100644
index 000000000000..8a58f18676a7
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkResourcesClient.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.kubernetesconfigurationprivateli.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.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.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 that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope along with
+ * {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response listByPrivateLinkScopeWithResponse(String resourceGroupName,
+ String scopeName, Context context);
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateLinkResourceListResultInner listByPrivateLinkScope(String resourceGroupName, String scopeName);
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param groupName The name of the private link resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope along with
+ * {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String resourceGroupName, String scopeName, String groupName,
+ Context context);
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param groupName The name of the private link resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PrivateLinkResourceInner get(String resourceGroupName, String scopeName, String groupName);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkScopesClient.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkScopesClient.java
new file mode 100644
index 000000000000..0fd33c8d69ed
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkScopesClient.java
@@ -0,0 +1,190 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.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.kubernetesconfigurationprivateli.fluent.models.KubernetesConfigurationPrivateLinkScopeInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.TagsResource;
+
+/**
+ * An instance of this class provides access to all the operations defined in PrivateLinkScopesClient.
+ */
+public interface PrivateLinkScopesClient {
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within 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 a list of all Azure Arc PrivateLinkScopes within a subscription as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list();
+
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within 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 a list of all Azure Arc PrivateLinkScopes within a subscription as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(Context context);
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a 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 a list of Azure Arc PrivateLinkScopes within a resource group as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName);
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 Azure Arc PrivateLinkScopes within a resource group as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName,
+ Context context);
+
+ /**
+ * Deletes a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response deleteWithResponse(String resourceGroupName, String scopeName, Context context);
+
+ /**
+ * Deletes a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String scopeName);
+
+ /**
+ * Returns a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an Azure Arc PrivateLinkScope definition along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getByResourceGroupWithResponse(String resourceGroupName,
+ String scopeName, Context context);
+
+ /**
+ * Returns a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an Azure Arc PrivateLinkScope definition.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ KubernetesConfigurationPrivateLinkScopeInner getByResourceGroup(String resourceGroupName, String scopeName);
+
+ /**
+ * Creates (or updates) a Azure Arc PrivateLinkScope. Note: You cannot specify a different value for
+ * InstrumentationKey nor AppId in the Put operation.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param parameters Properties that need to be specified to create or update a Azure Arc for Servers and Clusters
+ * PrivateLinkScope.
+ * @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 an Azure Arc PrivateLinkScope definition along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response createOrUpdateWithResponse(String resourceGroupName,
+ String scopeName, KubernetesConfigurationPrivateLinkScopeInner parameters, Context context);
+
+ /**
+ * Creates (or updates) a Azure Arc PrivateLinkScope. Note: You cannot specify a different value for
+ * InstrumentationKey nor AppId in the Put operation.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param parameters Properties that need to be specified to create or update a Azure Arc for Servers and Clusters
+ * PrivateLinkScope.
+ * @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 an Azure Arc PrivateLinkScope definition.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ KubernetesConfigurationPrivateLinkScopeInner createOrUpdate(String resourceGroupName, String scopeName,
+ KubernetesConfigurationPrivateLinkScopeInner parameters);
+
+ /**
+ * Updates an existing PrivateLinkScope's tags. To update other fields use the CreateOrUpdate method.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateLinkScopeTags Updated tag information to set into the PrivateLinkScope instance.
+ * @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 an Azure Arc PrivateLinkScope definition along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response updateTagsWithResponse(String resourceGroupName,
+ String scopeName, TagsResource privateLinkScopeTags, Context context);
+
+ /**
+ * Updates an existing PrivateLinkScope's tags. To update other fields use the CreateOrUpdate method.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateLinkScopeTags Updated tag information to set into the PrivateLinkScope instance.
+ * @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 an Azure Arc PrivateLinkScope definition.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ KubernetesConfigurationPrivateLinkScopeInner updateTags(String resourceGroupName, String scopeName,
+ TagsResource privateLinkScopeTags);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkScopesManagementClient.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkScopesManagementClient.java
new file mode 100644
index 000000000000..f75ae72369a1
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/PrivateLinkScopesManagementClient.java
@@ -0,0 +1,69 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent;
+
+import com.azure.core.http.HttpPipeline;
+import java.time.Duration;
+
+/**
+ * The interface for PrivateLinkScopesManagementClient class.
+ */
+public interface PrivateLinkScopesManagementClient {
+ /**
+ * Gets The ID of the target subscription.
+ *
+ * @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 PrivateLinkScopesClient object to access its operations.
+ *
+ * @return the PrivateLinkScopesClient object.
+ */
+ PrivateLinkScopesClient getPrivateLinkScopes();
+
+ /**
+ * Gets the PrivateLinkResourcesClient object to access its operations.
+ *
+ * @return the PrivateLinkResourcesClient object.
+ */
+ PrivateLinkResourcesClient getPrivateLinkResources();
+
+ /**
+ * Gets the PrivateEndpointConnectionsClient object to access its operations.
+ *
+ * @return the PrivateEndpointConnectionsClient object.
+ */
+ PrivateEndpointConnectionsClient getPrivateEndpointConnections();
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/KubernetesConfigurationPrivateLinkScopeInner.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/KubernetesConfigurationPrivateLinkScopeInner.java
new file mode 100644
index 000000000000..5309fa9bfe53
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/KubernetesConfigurationPrivateLinkScopeInner.java
@@ -0,0 +1,195 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.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.kubernetesconfigurationprivateli.models.KubernetesConfigurationPrivateLinkScopeProperties;
+import java.io.IOException;
+import java.util.Map;
+
+/**
+ * An Azure Arc PrivateLinkScope definition.
+ */
+@Fluent
+public final class KubernetesConfigurationPrivateLinkScopeInner extends Resource {
+ /*
+ * Properties that define a Azure Arc PrivateLinkScope resource.
+ */
+ private KubernetesConfigurationPrivateLinkScopeProperties properties;
+
+ /*
+ * 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 KubernetesConfigurationPrivateLinkScopeInner class.
+ */
+ public KubernetesConfigurationPrivateLinkScopeInner() {
+ }
+
+ /**
+ * Get the properties property: Properties that define a Azure Arc PrivateLinkScope resource.
+ *
+ * @return the properties value.
+ */
+ public KubernetesConfigurationPrivateLinkScopeProperties properties() {
+ return this.properties;
+ }
+
+ /**
+ * Set the properties property: Properties that define a Azure Arc PrivateLinkScope resource.
+ *
+ * @param properties the properties value to set.
+ * @return the KubernetesConfigurationPrivateLinkScopeInner object itself.
+ */
+ public KubernetesConfigurationPrivateLinkScopeInner
+ withProperties(KubernetesConfigurationPrivateLinkScopeProperties properties) {
+ this.properties = properties;
+ 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 KubernetesConfigurationPrivateLinkScopeInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public KubernetesConfigurationPrivateLinkScopeInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (properties() != null) {
+ properties().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.properties);
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of KubernetesConfigurationPrivateLinkScopeInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of KubernetesConfigurationPrivateLinkScopeInner 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 KubernetesConfigurationPrivateLinkScopeInner.
+ */
+ public static KubernetesConfigurationPrivateLinkScopeInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ KubernetesConfigurationPrivateLinkScopeInner deserializedKubernetesConfigurationPrivateLinkScopeInner
+ = new KubernetesConfigurationPrivateLinkScopeInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedKubernetesConfigurationPrivateLinkScopeInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedKubernetesConfigurationPrivateLinkScopeInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedKubernetesConfigurationPrivateLinkScopeInner.type = reader.getString();
+ } else if ("location".equals(fieldName)) {
+ deserializedKubernetesConfigurationPrivateLinkScopeInner.withLocation(reader.getString());
+ } else if ("tags".equals(fieldName)) {
+ Map tags = reader.readMap(reader1 -> reader1.getString());
+ deserializedKubernetesConfigurationPrivateLinkScopeInner.withTags(tags);
+ } else if ("properties".equals(fieldName)) {
+ deserializedKubernetesConfigurationPrivateLinkScopeInner.properties
+ = KubernetesConfigurationPrivateLinkScopeProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedKubernetesConfigurationPrivateLinkScopeInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedKubernetesConfigurationPrivateLinkScopeInner;
+ });
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionInner.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionInner.java
new file mode 100644
index 000000000000..d5f129c1ca7f
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionInner.java
@@ -0,0 +1,217 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+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 com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpoint;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkServiceConnectionState;
+import java.io.IOException;
+
+/**
+ * The Private Endpoint Connection resource.
+ */
+@Fluent
+public final class PrivateEndpointConnectionInner extends ProxyResource {
+ /*
+ * Resource properties.
+ */
+ private PrivateEndpointConnectionProperties 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 PrivateEndpointConnectionInner class.
+ */
+ public PrivateEndpointConnectionInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private PrivateEndpointConnectionProperties 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 privateEndpoint property: The resource of private end point.
+ *
+ * @return the privateEndpoint value.
+ */
+ public PrivateEndpoint privateEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateEndpoint();
+ }
+
+ /**
+ * Set the privateEndpoint property: The resource of private end point.
+ *
+ * @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: A collection of information about the state of the connection
+ * between service consumer and provider.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.innerProperties() == null ? null : this.innerProperties().privateLinkServiceConnectionState();
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: A collection of information about the state of the connection
+ * between service consumer and provider.
+ *
+ * @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: The provisioning state of the private endpoint connection resource.
+ *
+ * @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.writeJsonField("properties", this.innerProperties);
+ 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 ("properties".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.innerProperties
+ = PrivateEndpointConnectionProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateEndpointConnectionInner;
+ });
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionListResultInner.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionListResultInner.java
new file mode 100644
index 000000000000..8f05491e5110
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionListResultInner.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.kubernetesconfigurationprivateli.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;
+
+/**
+ * List of private endpoint connection associated with the specified storage account.
+ */
+@Fluent
+public final class PrivateEndpointConnectionListResultInner
+ implements JsonSerializable {
+ /*
+ * Array of private endpoint connections
+ */
+ private List value;
+
+ /**
+ * Creates an instance of PrivateEndpointConnectionListResultInner class.
+ */
+ public PrivateEndpointConnectionListResultInner() {
+ }
+
+ /**
+ * Get the value property: Array of private endpoint connections.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Set the value property: Array of private endpoint connections.
+ *
+ * @param value the value value to set.
+ * @return the PrivateEndpointConnectionListResultInner object itself.
+ */
+ public PrivateEndpointConnectionListResultInner 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 PrivateEndpointConnectionListResultInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of PrivateEndpointConnectionListResultInner 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 PrivateEndpointConnectionListResultInner.
+ */
+ public static PrivateEndpointConnectionListResultInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ PrivateEndpointConnectionListResultInner deserializedPrivateEndpointConnectionListResultInner
+ = new PrivateEndpointConnectionListResultInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("value".equals(fieldName)) {
+ List value
+ = reader.readArray(reader1 -> PrivateEndpointConnectionInner.fromJson(reader1));
+ deserializedPrivateEndpointConnectionListResultInner.value = value;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateEndpointConnectionListResultInner;
+ });
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionProperties.java
new file mode 100644
index 000000000000..75804c0b8702
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateEndpointConnectionProperties.java
@@ -0,0 +1,161 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.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.kubernetesconfigurationprivateli.models.PrivateEndpoint;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkServiceConnectionState;
+import java.io.IOException;
+
+/**
+ * Properties of the PrivateEndpointConnectProperties.
+ */
+@Fluent
+public final class PrivateEndpointConnectionProperties
+ implements JsonSerializable {
+ /*
+ * The resource of private end point.
+ */
+ private PrivateEndpoint privateEndpoint;
+
+ /*
+ * A collection of information about the state of the connection between service consumer and provider.
+ */
+ private PrivateLinkServiceConnectionState privateLinkServiceConnectionState;
+
+ /*
+ * The provisioning state of the private endpoint connection resource.
+ */
+ private PrivateEndpointConnectionProvisioningState provisioningState;
+
+ /**
+ * Creates an instance of PrivateEndpointConnectionProperties class.
+ */
+ public PrivateEndpointConnectionProperties() {
+ }
+
+ /**
+ * Get the privateEndpoint property: The resource of private end point.
+ *
+ * @return the privateEndpoint value.
+ */
+ public PrivateEndpoint privateEndpoint() {
+ return this.privateEndpoint;
+ }
+
+ /**
+ * Set the privateEndpoint property: The resource of private end point.
+ *
+ * @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: A collection of information about the state of the connection
+ * between service consumer and provider.
+ *
+ * @return the privateLinkServiceConnectionState value.
+ */
+ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.privateLinkServiceConnectionState;
+ }
+
+ /**
+ * Set the privateLinkServiceConnectionState property: A collection of information about the state of the connection
+ * between service consumer and provider.
+ *
+ * @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: The provisioning state of the private endpoint connection resource.
+ *
+ * @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) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Missing required property privateLinkServiceConnectionState in model PrivateEndpointConnectionProperties"));
+ } else {
+ privateLinkServiceConnectionState().validate();
+ }
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateEndpointConnectionProperties.class);
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeJsonField("privateLinkServiceConnectionState", this.privateLinkServiceConnectionState);
+ jsonWriter.writeJsonField("privateEndpoint", this.privateEndpoint);
+ 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 IllegalStateException If the deserialized JSON object was missing any required properties.
+ * @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 ("privateLinkServiceConnectionState".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionProperties.privateLinkServiceConnectionState
+ = PrivateLinkServiceConnectionState.fromJson(reader);
+ } else if ("privateEndpoint".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionProperties.privateEndpoint = PrivateEndpoint.fromJson(reader);
+ } else if ("provisioningState".equals(fieldName)) {
+ deserializedPrivateEndpointConnectionProperties.provisioningState
+ = PrivateEndpointConnectionProvisioningState.fromString(reader.getString());
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateEndpointConnectionProperties;
+ });
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceInner.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceInner.java
new file mode 100644
index 000000000000..5f1fa2d9665d
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceInner.java
@@ -0,0 +1,197 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+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.util.List;
+
+/**
+ * A private link resource.
+ */
+@Fluent
+public final class PrivateLinkResourceInner extends ProxyResource {
+ /*
+ * Resource properties.
+ */
+ private PrivateLinkResourceProperties 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 PrivateLinkResourceInner class.
+ */
+ public PrivateLinkResourceInner() {
+ }
+
+ /**
+ * Get the innerProperties property: Resource properties.
+ *
+ * @return the innerProperties value.
+ */
+ private PrivateLinkResourceProperties 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 groupId property: The private link resource group id.
+ *
+ * @return the groupId value.
+ */
+ public String groupId() {
+ return this.innerProperties() == null ? null : this.innerProperties().groupId();
+ }
+
+ /**
+ * Get the requiredMembers property: The private link resource required member names.
+ *
+ * @return the requiredMembers value.
+ */
+ public List requiredMembers() {
+ return this.innerProperties() == null ? null : this.innerProperties().requiredMembers();
+ }
+
+ /**
+ * Get the requiredZoneNames property: The private link resource Private link DNS zone name.
+ *
+ * @return the requiredZoneNames value.
+ */
+ public List requiredZoneNames() {
+ return this.innerProperties() == null ? null : this.innerProperties().requiredZoneNames();
+ }
+
+ /**
+ * Set the requiredZoneNames property: The private link resource Private link DNS zone name.
+ *
+ * @param requiredZoneNames the requiredZoneNames value to set.
+ * @return the PrivateLinkResourceInner object itself.
+ */
+ public PrivateLinkResourceInner withRequiredZoneNames(List requiredZoneNames) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new PrivateLinkResourceProperties();
+ }
+ this.innerProperties().withRequiredZoneNames(requiredZoneNames);
+ return this;
+ }
+
+ /**
+ * 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 PrivateLinkResourceInner from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of PrivateLinkResourceInner 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 PrivateLinkResourceInner.
+ */
+ public static PrivateLinkResourceInner fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ PrivateLinkResourceInner deserializedPrivateLinkResourceInner = new PrivateLinkResourceInner();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("id".equals(fieldName)) {
+ deserializedPrivateLinkResourceInner.id = reader.getString();
+ } else if ("name".equals(fieldName)) {
+ deserializedPrivateLinkResourceInner.name = reader.getString();
+ } else if ("type".equals(fieldName)) {
+ deserializedPrivateLinkResourceInner.type = reader.getString();
+ } else if ("properties".equals(fieldName)) {
+ deserializedPrivateLinkResourceInner.innerProperties
+ = PrivateLinkResourceProperties.fromJson(reader);
+ } else if ("systemData".equals(fieldName)) {
+ deserializedPrivateLinkResourceInner.systemData = SystemData.fromJson(reader);
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateLinkResourceInner;
+ });
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceListResultInner.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceListResultInner.java
new file mode 100644
index 000000000000..b97ae3786dc6
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceListResultInner.java
@@ -0,0 +1,100 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.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;
+
+/**
+ * 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 -> PrivateLinkResourceInner.fromJson(reader1));
+ deserializedPrivateLinkResourceListResultInner.value = value;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPrivateLinkResourceListResultInner;
+ });
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceProperties.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/PrivateLinkResourceProperties.java
new file mode 100644
index 000000000000..f0306fb41d36
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/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.kubernetesconfigurationprivateli.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 {
+ /*
+ * The private link resource group id.
+ */
+ private String groupId;
+
+ /*
+ * The private link resource required member names.
+ */
+ private List requiredMembers;
+
+ /*
+ * The private link resource Private link DNS zone name.
+ */
+ private List requiredZoneNames;
+
+ /**
+ * Creates an instance of PrivateLinkResourceProperties class.
+ */
+ public PrivateLinkResourceProperties() {
+ }
+
+ /**
+ * Get the groupId property: The private link resource group id.
+ *
+ * @return the groupId value.
+ */
+ public String groupId() {
+ return this.groupId;
+ }
+
+ /**
+ * Get the requiredMembers property: The private link resource required member names.
+ *
+ * @return the requiredMembers value.
+ */
+ public List requiredMembers() {
+ return this.requiredMembers;
+ }
+
+ /**
+ * Get the requiredZoneNames property: The private link resource Private link DNS zone name.
+ *
+ * @return the requiredZoneNames value.
+ */
+ public List requiredZoneNames() {
+ return this.requiredZoneNames;
+ }
+
+ /**
+ * Set the requiredZoneNames property: The private link resource Private link DNS zone name.
+ *
+ * @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/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/package-info.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/models/package-info.java
new file mode 100644
index 000000000000..83b63672e618
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/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 PrivateLinkScopesManagementClient.
+ * PrivateLinkScopes Client.
+ */
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models;
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/package-info.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/fluent/package-info.java
new file mode 100644
index 000000000000..a20fa2556217
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/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 PrivateLinkScopesManagementClient.
+ * PrivateLinkScopes Client.
+ */
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent;
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/KubernetesConfigurationPrivateLinkScopeImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/KubernetesConfigurationPrivateLinkScopeImpl.java
new file mode 100644
index 000000000000..89aed6ddeb27
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/KubernetesConfigurationPrivateLinkScopeImpl.java
@@ -0,0 +1,184 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.management.Region;
+import com.azure.core.management.SystemData;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.KubernetesConfigurationPrivateLinkScopeInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.KubernetesConfigurationPrivateLinkScope;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.KubernetesConfigurationPrivateLinkScopeProperties;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.TagsResource;
+import java.util.Collections;
+import java.util.Map;
+
+public final class KubernetesConfigurationPrivateLinkScopeImpl implements KubernetesConfigurationPrivateLinkScope,
+ KubernetesConfigurationPrivateLinkScope.Definition, KubernetesConfigurationPrivateLinkScope.Update {
+ private KubernetesConfigurationPrivateLinkScopeInner innerObject;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager 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 KubernetesConfigurationPrivateLinkScopeProperties properties() {
+ return this.innerModel().properties();
+ }
+
+ public SystemData systemData() {
+ return this.innerModel().systemData();
+ }
+
+ public Region region() {
+ return Region.fromName(this.regionName());
+ }
+
+ public String regionName() {
+ return this.location();
+ }
+
+ public String resourceGroupName() {
+ return resourceGroupName;
+ }
+
+ public KubernetesConfigurationPrivateLinkScopeInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+
+ private String resourceGroupName;
+
+ private String scopeName;
+
+ private TagsResource updatePrivateLinkScopeTags;
+
+ public KubernetesConfigurationPrivateLinkScopeImpl withExistingResourceGroup(String resourceGroupName) {
+ this.resourceGroupName = resourceGroupName;
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScope create() {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateLinkScopes()
+ .createOrUpdateWithResponse(resourceGroupName, scopeName, this.innerModel(), Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScope create(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateLinkScopes()
+ .createOrUpdateWithResponse(resourceGroupName, scopeName, this.innerModel(), context)
+ .getValue();
+ return this;
+ }
+
+ KubernetesConfigurationPrivateLinkScopeImpl(String name,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerObject = new KubernetesConfigurationPrivateLinkScopeInner();
+ this.serviceManager = serviceManager;
+ this.scopeName = name;
+ }
+
+ public KubernetesConfigurationPrivateLinkScopeImpl update() {
+ this.updatePrivateLinkScopeTags = new TagsResource();
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScope apply() {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateLinkScopes()
+ .updateTagsWithResponse(resourceGroupName, scopeName, updatePrivateLinkScopeTags, Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScope apply(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateLinkScopes()
+ .updateTagsWithResponse(resourceGroupName, scopeName, updatePrivateLinkScopeTags, context)
+ .getValue();
+ return this;
+ }
+
+ KubernetesConfigurationPrivateLinkScopeImpl(KubernetesConfigurationPrivateLinkScopeInner innerObject,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.scopeName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "privateLinkScopes");
+ }
+
+ public KubernetesConfigurationPrivateLinkScope refresh() {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateLinkScopes()
+ .getByResourceGroupWithResponse(resourceGroupName, scopeName, Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScope refresh(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateLinkScopes()
+ .getByResourceGroupWithResponse(resourceGroupName, scopeName, context)
+ .getValue();
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScopeImpl withRegion(Region location) {
+ this.innerModel().withLocation(location.toString());
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScopeImpl withRegion(String location) {
+ this.innerModel().withLocation(location);
+ return this;
+ }
+
+ public KubernetesConfigurationPrivateLinkScopeImpl withTags(Map tags) {
+ if (isInCreateMode()) {
+ this.innerModel().withTags(tags);
+ return this;
+ } else {
+ this.updatePrivateLinkScopeTags.withTags(tags);
+ return this;
+ }
+ }
+
+ public KubernetesConfigurationPrivateLinkScopeImpl
+ withProperties(KubernetesConfigurationPrivateLinkScopeProperties properties) {
+ this.innerModel().withProperties(properties);
+ return this;
+ }
+
+ private boolean isInCreateMode() {
+ return this.innerModel().id() == null;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionImpl.java
new file mode 100644
index 000000000000..1e4827e0f8c4
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionImpl.java
@@ -0,0 +1,150 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.management.SystemData;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpoint;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnection;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnectionProvisioningState;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkServiceConnectionState;
+
+public final class PrivateEndpointConnectionImpl
+ implements PrivateEndpointConnection, PrivateEndpointConnection.Definition, PrivateEndpointConnection.Update {
+ private PrivateEndpointConnectionInner innerObject;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager 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 PrivateEndpoint privateEndpoint() {
+ return this.innerModel().privateEndpoint();
+ }
+
+ public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() {
+ return this.innerModel().privateLinkServiceConnectionState();
+ }
+
+ public PrivateEndpointConnectionProvisioningState provisioningState() {
+ return this.innerModel().provisioningState();
+ }
+
+ public String resourceGroupName() {
+ return resourceGroupName;
+ }
+
+ public PrivateEndpointConnectionInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+
+ private String resourceGroupName;
+
+ private String scopeName;
+
+ private String privateEndpointConnectionName;
+
+ public PrivateEndpointConnectionImpl withExistingPrivateLinkScope(String resourceGroupName, String scopeName) {
+ this.resourceGroupName = resourceGroupName;
+ this.scopeName = scopeName;
+ return this;
+ }
+
+ public PrivateEndpointConnection create() {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateEndpointConnections()
+ .createOrUpdate(resourceGroupName, scopeName, privateEndpointConnectionName, this.innerModel(),
+ Context.NONE);
+ return this;
+ }
+
+ public PrivateEndpointConnection create(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateEndpointConnections()
+ .createOrUpdate(resourceGroupName, scopeName, privateEndpointConnectionName, this.innerModel(), context);
+ return this;
+ }
+
+ PrivateEndpointConnectionImpl(String name,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerObject = new PrivateEndpointConnectionInner();
+ this.serviceManager = serviceManager;
+ this.privateEndpointConnectionName = name;
+ }
+
+ public PrivateEndpointConnectionImpl update() {
+ return this;
+ }
+
+ public PrivateEndpointConnection apply() {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateEndpointConnections()
+ .createOrUpdate(resourceGroupName, scopeName, privateEndpointConnectionName, this.innerModel(),
+ Context.NONE);
+ return this;
+ }
+
+ public PrivateEndpointConnection apply(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateEndpointConnections()
+ .createOrUpdate(resourceGroupName, scopeName, privateEndpointConnectionName, this.innerModel(), context);
+ return this;
+ }
+
+ PrivateEndpointConnectionImpl(PrivateEndpointConnectionInner innerObject,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.scopeName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "privateLinkScopes");
+ this.privateEndpointConnectionName
+ = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "privateEndpointConnections");
+ }
+
+ public PrivateEndpointConnection refresh() {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateEndpointConnections()
+ .getWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public PrivateEndpointConnection refresh(Context context) {
+ this.innerObject = serviceManager.serviceClient()
+ .getPrivateEndpointConnections()
+ .getWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, context)
+ .getValue();
+ return this;
+ }
+
+ public PrivateEndpointConnectionImpl withPrivateEndpoint(PrivateEndpoint privateEndpoint) {
+ this.innerModel().withPrivateEndpoint(privateEndpoint);
+ return this;
+ }
+
+ public PrivateEndpointConnectionImpl
+ withPrivateLinkServiceConnectionState(PrivateLinkServiceConnectionState privateLinkServiceConnectionState) {
+ this.innerModel().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState);
+ return this;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionListResultImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionListResultImpl.java
new file mode 100644
index 000000000000..80b67897e7f4
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionListResultImpl.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.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionListResultInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnection;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnectionListResult;
+import java.util.Collections;
+import java.util.List;
+import java.util.stream.Collectors;
+
+public final class PrivateEndpointConnectionListResultImpl implements PrivateEndpointConnectionListResult {
+ private PrivateEndpointConnectionListResultInner innerObject;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager;
+
+ PrivateEndpointConnectionListResultImpl(PrivateEndpointConnectionListResultInner innerObject,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ }
+
+ public List value() {
+ List inner = this.innerModel().value();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner.stream()
+ .map(inner1 -> new PrivateEndpointConnectionImpl(inner1, this.manager()))
+ .collect(Collectors.toList()));
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public PrivateEndpointConnectionListResultInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionsClientImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionsClientImpl.java
new file mode 100644
index 000000000000..7b6d371d5845
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionsClientImpl.java
@@ -0,0 +1,790 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.annotation.BodyParam;
+import com.azure.core.annotation.Delete;
+import com.azure.core.annotation.ExpectedResponses;
+import com.azure.core.annotation.Get;
+import com.azure.core.annotation.HeaderParam;
+import com.azure.core.annotation.Headers;
+import com.azure.core.annotation.Host;
+import com.azure.core.annotation.HostParam;
+import com.azure.core.annotation.PathParam;
+import com.azure.core.annotation.Put;
+import com.azure.core.annotation.QueryParam;
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceInterface;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.annotation.UnexpectedResponseExceptionType;
+import com.azure.core.http.rest.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.BinaryData;
+import com.azure.core.util.Context;
+import com.azure.core.util.FluxUtil;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.core.util.polling.PollerFlux;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateEndpointConnectionsClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionListResultInner;
+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 PrivateEndpointConnectionsClient.
+ */
+public final class PrivateEndpointConnectionsClientImpl implements PrivateEndpointConnectionsClient {
+ /**
+ * The proxy service used to perform REST calls.
+ */
+ private final PrivateEndpointConnectionsService service;
+
+ /**
+ * The service client containing this operation class.
+ */
+ private final PrivateLinkScopesManagementClientImpl client;
+
+ /**
+ * Initializes an instance of PrivateEndpointConnectionsClientImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ PrivateEndpointConnectionsClientImpl(PrivateLinkScopesManagementClientImpl client) {
+ this.service = RestProxy.create(PrivateEndpointConnectionsService.class, client.getHttpPipeline(),
+ client.getSerializerAdapter());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for PrivateLinkScopesManagementClientPrivateEndpointConnections to be
+ * used by the proxy service to perform REST calls.
+ */
+ @Host("{$host}")
+ @ServiceInterface(name = "PrivateLinkScopesMan")
+ public interface PrivateEndpointConnectionsService {
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections/{privateEndpointConnectionName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> get(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName,
+ @PathParam("privateEndpointConnectionName") String privateEndpointConnectionName,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections/{privateEndpointConnectionName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response getSync(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName,
+ @PathParam("privateEndpointConnectionName") String privateEndpointConnectionName,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections/{privateEndpointConnectionName}")
+ @ExpectedResponses({ 200, 202 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> createOrUpdate(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName,
+ @PathParam("privateEndpointConnectionName") String privateEndpointConnectionName,
+ @BodyParam("application/json") PrivateEndpointConnectionInner properties,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections/{privateEndpointConnectionName}")
+ @ExpectedResponses({ 200, 202 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response createOrUpdateSync(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName,
+ @PathParam("privateEndpointConnectionName") String privateEndpointConnectionName,
+ @BodyParam("application/json") PrivateEndpointConnectionInner properties,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections/{privateEndpointConnectionName}")
+ @ExpectedResponses({ 200, 204 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> delete(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName,
+ @PathParam("privateEndpointConnectionName") String privateEndpointConnectionName,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections/{privateEndpointConnectionName}")
+ @ExpectedResponses({ 200, 204 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response deleteSync(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName,
+ @PathParam("privateEndpointConnectionName") String privateEndpointConnectionName,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByPrivateLinkScope(
+ @HostParam("$host") String endpoint, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName, @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateEndpointConnections")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listByPrivateLinkScopeSync(
+ @HostParam("$host") String endpoint, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName, @HeaderParam("Accept") String accept, Context context);
+ }
+
+ /**
+ * Gets a private endpoint connection.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a private endpoint connection along with {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(String resourceGroupName,
+ String scopeName, String privateEndpointConnectionName) {
+ 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateEndpointConnectionName == null) {
+ return Mono.error(new IllegalArgumentException(
+ "Parameter privateEndpointConnectionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context -> service.get(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
+ this.client.getApiVersion(), scopeName, privateEndpointConnectionName, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Gets a private endpoint connection.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a private endpoint connection on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getAsync(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName) {
+ return getWithResponseAsync(resourceGroupName, scopeName, privateEndpointConnectionName)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Gets a private endpoint connection.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a private endpoint connection along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getWithResponse(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter privateEndpointConnectionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return service.getSync(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
+ this.client.getApiVersion(), scopeName, privateEndpointConnectionName, accept, context);
+ }
+
+ /**
+ * Gets a private endpoint connection.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a private endpoint connection.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PrivateEndpointConnectionInner get(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName) {
+ return getWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, Context.NONE).getValue();
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Private Endpoint Connection resource along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> createOrUpdateWithResponseAsync(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateEndpointConnectionName == null) {
+ return Mono.error(new IllegalArgumentException(
+ "Parameter privateEndpointConnectionName 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.createOrUpdate(this.client.getEndpoint(), this.client.getSubscriptionId(),
+ resourceGroupName, this.client.getApiVersion(), scopeName, privateEndpointConnectionName, properties,
+ accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Private Endpoint Connection resource along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Response createOrUpdateWithResponse(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner properties) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter privateEndpointConnectionName is required and cannot be null."));
+ }
+ if (properties == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter properties is required and cannot be null."));
+ } else {
+ properties.validate();
+ }
+ final String accept = "application/json";
+ return service.createOrUpdateSync(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
+ this.client.getApiVersion(), scopeName, privateEndpointConnectionName, properties, accept, Context.NONE);
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Private Endpoint Connection resource along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Response createOrUpdateWithResponse(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner properties, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter privateEndpointConnectionName is required and cannot be null."));
+ }
+ if (properties == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter properties is required and cannot be null."));
+ } else {
+ properties.validate();
+ }
+ final String accept = "application/json";
+ return service.createOrUpdateSync(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
+ this.client.getApiVersion(), scopeName, privateEndpointConnectionName, properties, accept, context);
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 the Private Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, PrivateEndpointConnectionInner>
+ beginCreateOrUpdateAsync(String resourceGroupName, String scopeName, String privateEndpointConnectionName,
+ PrivateEndpointConnectionInner properties) {
+ Mono>> mono
+ = createOrUpdateWithResponseAsync(resourceGroupName, scopeName, privateEndpointConnectionName, properties);
+ return this.client.getLroResult(mono,
+ this.client.getHttpPipeline(), PrivateEndpointConnectionInner.class, PrivateEndpointConnectionInner.class,
+ this.client.getContext());
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 the Private Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, PrivateEndpointConnectionInner> beginCreateOrUpdate(
+ String resourceGroupName, String scopeName, String privateEndpointConnectionName,
+ PrivateEndpointConnectionInner properties) {
+ Response response
+ = createOrUpdateWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, properties);
+ return this.client.getLroResult(response,
+ PrivateEndpointConnectionInner.class, PrivateEndpointConnectionInner.class, Context.NONE);
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 the Private Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, PrivateEndpointConnectionInner> beginCreateOrUpdate(
+ String resourceGroupName, String scopeName, String privateEndpointConnectionName,
+ PrivateEndpointConnectionInner properties, Context context) {
+ Response response = createOrUpdateWithResponse(resourceGroupName, scopeName,
+ privateEndpointConnectionName, properties, context);
+ return this.client.getLroResult(response,
+ PrivateEndpointConnectionInner.class, PrivateEndpointConnectionInner.class, context);
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Private Endpoint Connection resource on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createOrUpdateAsync(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner properties) {
+ return beginCreateOrUpdateAsync(resourceGroupName, scopeName, privateEndpointConnectionName, properties).last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Private Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PrivateEndpointConnectionInner createOrUpdate(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner properties) {
+ return beginCreateOrUpdate(resourceGroupName, scopeName, privateEndpointConnectionName, properties)
+ .getFinalResult();
+ }
+
+ /**
+ * Approve or reject a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param properties The private endpoint connection properties.
+ * @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 Private Endpoint Connection resource.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PrivateEndpointConnectionInner createOrUpdate(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, PrivateEndpointConnectionInner properties, Context context) {
+ return beginCreateOrUpdate(resourceGroupName, scopeName, privateEndpointConnectionName, properties, context)
+ .getFinalResult();
+ }
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> deleteWithResponseAsync(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName) {
+ 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateEndpointConnectionName == null) {
+ return Mono.error(new IllegalArgumentException(
+ "Parameter privateEndpointConnectionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context -> service.delete(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
+ this.client.getApiVersion(), scopeName, privateEndpointConnectionName, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return A {@link Mono} that completes when a successful response is received.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono deleteAsync(String resourceGroupName, String scopeName, String privateEndpointConnectionName) {
+ return deleteWithResponseAsync(resourceGroupName, scopeName, privateEndpointConnectionName)
+ .flatMap(ignored -> Mono.empty());
+ }
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response deleteWithResponse(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter privateEndpointConnectionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return service.deleteSync(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
+ this.client.getApiVersion(), scopeName, privateEndpointConnectionName, accept, context);
+ }
+
+ /**
+ * Deletes a private endpoint connection with a given name.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure
+ * resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public void delete(String resourceGroupName, String scopeName, String privateEndpointConnectionName) {
+ deleteWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, Context.NONE);
+ }
+
+ /**
+ * Gets all private endpoint connections on a private link scope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return all private endpoint connections on a private link scope along with {@link Response} on successful
+ * completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listByPrivateLinkScopeWithResponseAsync(String resourceGroupName, String scopeName) {
+ 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context -> service.listByPrivateLinkScope(this.client.getEndpoint(), this.client.getSubscriptionId(),
+ resourceGroupName, this.client.getApiVersion(), scopeName, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Gets all private endpoint connections on a private link scope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return all private endpoint connections on a private link scope on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono listByPrivateLinkScopeAsync(String resourceGroupName,
+ String scopeName) {
+ return listByPrivateLinkScopeWithResponseAsync(resourceGroupName, scopeName)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Gets all private endpoint connections on a private link scope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return all private endpoint connections on a private link scope along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response
+ listByPrivateLinkScopeWithResponse(String resourceGroupName, String scopeName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return service.listByPrivateLinkScopeSync(this.client.getEndpoint(), this.client.getSubscriptionId(),
+ resourceGroupName, this.client.getApiVersion(), scopeName, accept, context);
+ }
+
+ /**
+ * Gets all private endpoint connections on a private link scope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return all private endpoint connections on a private link scope.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PrivateEndpointConnectionListResultInner listByPrivateLinkScope(String resourceGroupName, String scopeName) {
+ return listByPrivateLinkScopeWithResponse(resourceGroupName, scopeName, Context.NONE).getValue();
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateEndpointConnectionsClientImpl.class);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionsImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionsImpl.java
new file mode 100644
index 000000000000..f7c08f52f7f2
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateEndpointConnectionsImpl.java
@@ -0,0 +1,178 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.http.rest.Response;
+import com.azure.core.http.rest.SimpleResponse;
+import com.azure.core.util.Context;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateEndpointConnectionsClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateEndpointConnectionListResultInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnection;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnectionListResult;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateEndpointConnections;
+
+public final class PrivateEndpointConnectionsImpl implements PrivateEndpointConnections {
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateEndpointConnectionsImpl.class);
+
+ private final PrivateEndpointConnectionsClient innerClient;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager;
+
+ public PrivateEndpointConnectionsImpl(PrivateEndpointConnectionsClient innerClient,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerClient = innerClient;
+ this.serviceManager = serviceManager;
+ }
+
+ public Response getWithResponse(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, Context context) {
+ Response inner = this.serviceClient()
+ .getWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, context);
+ if (inner != null) {
+ return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
+ new PrivateEndpointConnectionImpl(inner.getValue(), this.manager()));
+ } else {
+ return null;
+ }
+ }
+
+ public PrivateEndpointConnection get(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName) {
+ PrivateEndpointConnectionInner inner
+ = this.serviceClient().get(resourceGroupName, scopeName, privateEndpointConnectionName);
+ if (inner != null) {
+ return new PrivateEndpointConnectionImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
+ public Response deleteWithResponse(String resourceGroupName, String scopeName,
+ String privateEndpointConnectionName, Context context) {
+ return this.serviceClient()
+ .deleteWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, context);
+ }
+
+ public void delete(String resourceGroupName, String scopeName, String privateEndpointConnectionName) {
+ this.serviceClient().delete(resourceGroupName, scopeName, privateEndpointConnectionName);
+ }
+
+ public Response listByPrivateLinkScopeWithResponse(String resourceGroupName,
+ String scopeName, Context context) {
+ Response inner
+ = this.serviceClient().listByPrivateLinkScopeWithResponse(resourceGroupName, scopeName, context);
+ if (inner != null) {
+ return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
+ new PrivateEndpointConnectionListResultImpl(inner.getValue(), this.manager()));
+ } else {
+ return null;
+ }
+ }
+
+ public PrivateEndpointConnectionListResult listByPrivateLinkScope(String resourceGroupName, String scopeName) {
+ PrivateEndpointConnectionListResultInner inner
+ = this.serviceClient().listByPrivateLinkScope(resourceGroupName, scopeName);
+ if (inner != null) {
+ return new PrivateEndpointConnectionListResultImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
+ public PrivateEndpointConnection getById(String id) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ String privateEndpointConnectionName
+ = ResourceManagerUtils.getValueFromIdByName(id, "privateEndpointConnections");
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
+ .format("The resource ID '%s' is not valid. Missing path segment 'privateEndpointConnections'.", id)));
+ }
+ return this.getWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, Context.NONE)
+ .getValue();
+ }
+
+ public Response getByIdWithResponse(String id, Context context) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ String privateEndpointConnectionName
+ = ResourceManagerUtils.getValueFromIdByName(id, "privateEndpointConnections");
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
+ .format("The resource ID '%s' is not valid. Missing path segment 'privateEndpointConnections'.", id)));
+ }
+ return this.getWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, context);
+ }
+
+ public void deleteById(String id) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ String privateEndpointConnectionName
+ = ResourceManagerUtils.getValueFromIdByName(id, "privateEndpointConnections");
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
+ .format("The resource ID '%s' is not valid. Missing path segment 'privateEndpointConnections'.", id)));
+ }
+ this.deleteWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, Context.NONE);
+ }
+
+ public Response deleteByIdWithResponse(String id, Context context) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ String privateEndpointConnectionName
+ = ResourceManagerUtils.getValueFromIdByName(id, "privateEndpointConnections");
+ if (privateEndpointConnectionName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(String
+ .format("The resource ID '%s' is not valid. Missing path segment 'privateEndpointConnections'.", id)));
+ }
+ return this.deleteWithResponse(resourceGroupName, scopeName, privateEndpointConnectionName, context);
+ }
+
+ private PrivateEndpointConnectionsClient serviceClient() {
+ return this.innerClient;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+
+ public PrivateEndpointConnectionImpl define(String name) {
+ return new PrivateEndpointConnectionImpl(name, this.manager());
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourceImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourceImpl.java
new file mode 100644
index 000000000000..57e27bad9a00
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourceImpl.java
@@ -0,0 +1,69 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.management.SystemData;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkResource;
+import java.util.Collections;
+import java.util.List;
+
+public final class PrivateLinkResourceImpl implements PrivateLinkResource {
+ private PrivateLinkResourceInner innerObject;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager;
+
+ PrivateLinkResourceImpl(PrivateLinkResourceInner innerObject,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager 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 groupId() {
+ return this.innerModel().groupId();
+ }
+
+ public List requiredMembers() {
+ List inner = this.innerModel().requiredMembers();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public List requiredZoneNames() {
+ List inner = this.innerModel().requiredZoneNames();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public PrivateLinkResourceInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourceListResultImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourceListResultImpl.java
new file mode 100644
index 000000000000..3ed4a27551d0
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourceListResultImpl.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.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceListResultInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkResource;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkResourceListResult;
+import java.util.Collections;
+import java.util.List;
+import java.util.stream.Collectors;
+
+public final class PrivateLinkResourceListResultImpl implements PrivateLinkResourceListResult {
+ private PrivateLinkResourceListResultInner innerObject;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager;
+
+ PrivateLinkResourceListResultImpl(PrivateLinkResourceListResultInner innerObject,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ }
+
+ public List value() {
+ List inner = this.innerModel().value();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner.stream()
+ .map(inner1 -> new PrivateLinkResourceImpl(inner1, this.manager()))
+ .collect(Collectors.toList()));
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public PrivateLinkResourceListResultInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourcesClientImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourcesClientImpl.java
new file mode 100644
index 000000000000..0801a4a74548
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourcesClientImpl.java
@@ -0,0 +1,327 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.annotation.ExpectedResponses;
+import com.azure.core.annotation.Get;
+import com.azure.core.annotation.HeaderParam;
+import com.azure.core.annotation.Headers;
+import com.azure.core.annotation.Host;
+import com.azure.core.annotation.HostParam;
+import com.azure.core.annotation.PathParam;
+import com.azure.core.annotation.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.Response;
+import com.azure.core.http.rest.RestProxy;
+import com.azure.core.management.exception.ManagementException;
+import com.azure.core.util.Context;
+import com.azure.core.util.FluxUtil;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateLinkResourcesClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceListResultInner;
+import reactor.core.publisher.Mono;
+
+/**
+ * An instance of this class provides access to all the operations defined in PrivateLinkResourcesClient.
+ */
+public final class PrivateLinkResourcesClientImpl implements PrivateLinkResourcesClient {
+ /**
+ * The proxy service used to perform REST calls.
+ */
+ private final PrivateLinkResourcesService service;
+
+ /**
+ * The service client containing this operation class.
+ */
+ private final PrivateLinkScopesManagementClientImpl client;
+
+ /**
+ * Initializes an instance of PrivateLinkResourcesClientImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ PrivateLinkResourcesClientImpl(PrivateLinkScopesManagementClientImpl client) {
+ this.service = RestProxy.create(PrivateLinkResourcesService.class, client.getHttpPipeline(),
+ client.getSerializerAdapter());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for PrivateLinkScopesManagementClientPrivateLinkResources to be used by
+ * the proxy service to perform REST calls.
+ */
+ @Host("{$host}")
+ @ServiceInterface(name = "PrivateLinkScopesMan")
+ public interface PrivateLinkResourcesService {
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateLinkResources")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByPrivateLinkScope(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName, @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateLinkResources")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listByPrivateLinkScopeSync(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName, @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateLinkResources/{groupName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> get(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName, @PathParam("groupName") String groupName,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}/privateLinkResources/{groupName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response getSync(@HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("scopeName") String scopeName, @PathParam("groupName") String groupName,
+ @HeaderParam("Accept") String accept, Context context);
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope along with
+ * {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listByPrivateLinkScopeWithResponseAsync(String resourceGroupName, String scopeName) {
+ 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context -> service.listByPrivateLinkScope(this.client.getEndpoint(), this.client.getSubscriptionId(),
+ resourceGroupName, this.client.getApiVersion(), scopeName, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope on successful
+ * completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono listByPrivateLinkScopeAsync(String resourceGroupName,
+ String scopeName) {
+ return listByPrivateLinkScopeWithResponseAsync(resourceGroupName, scopeName)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope along with
+ * {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response listByPrivateLinkScopeWithResponse(String resourceGroupName,
+ String scopeName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return service.listByPrivateLinkScopeSync(this.client.getEndpoint(), this.client.getSubscriptionId(),
+ resourceGroupName, this.client.getApiVersion(), scopeName, accept, context);
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PrivateLinkResourceListResultInner listByPrivateLinkScope(String resourceGroupName, String scopeName) {
+ return listByPrivateLinkScopeWithResponse(resourceGroupName, scopeName, Context.NONE).getValue();
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param groupName The name of the private link resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope along with
+ * {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(String resourceGroupName, String scopeName,
+ String groupName) {
+ 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (groupName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter groupName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.get(this.client.getEndpoint(), this.client.getSubscriptionId(),
+ resourceGroupName, this.client.getApiVersion(), scopeName, groupName, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param groupName The name of the private link resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope on successful
+ * completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getAsync(String resourceGroupName, String scopeName, String groupName) {
+ return getWithResponseAsync(resourceGroupName, scopeName, groupName)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param groupName The name of the private link resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope along with
+ * {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getWithResponse(String resourceGroupName, String scopeName,
+ String groupName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (groupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter groupName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return service.getSync(this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName,
+ this.client.getApiVersion(), scopeName, groupName, accept, context);
+ }
+
+ /**
+ * Gets the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param groupName The name of the private link resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the private link resources that need to be created for a Azure Monitor PrivateLinkScope.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PrivateLinkResourceInner get(String resourceGroupName, String scopeName, String groupName) {
+ return getWithResponse(resourceGroupName, scopeName, groupName, Context.NONE).getValue();
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateLinkResourcesClientImpl.class);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourcesImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourcesImpl.java
new file mode 100644
index 000000000000..16a4d9410bfe
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkResourcesImpl.java
@@ -0,0 +1,81 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.http.rest.Response;
+import com.azure.core.http.rest.SimpleResponse;
+import com.azure.core.util.Context;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateLinkResourcesClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.PrivateLinkResourceListResultInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkResource;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkResourceListResult;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkResources;
+
+public final class PrivateLinkResourcesImpl implements PrivateLinkResources {
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateLinkResourcesImpl.class);
+
+ private final PrivateLinkResourcesClient innerClient;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager;
+
+ public PrivateLinkResourcesImpl(PrivateLinkResourcesClient innerClient,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerClient = innerClient;
+ this.serviceManager = serviceManager;
+ }
+
+ public Response listByPrivateLinkScopeWithResponse(String resourceGroupName,
+ String scopeName, Context context) {
+ Response inner
+ = this.serviceClient().listByPrivateLinkScopeWithResponse(resourceGroupName, scopeName, context);
+ if (inner != null) {
+ return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
+ new PrivateLinkResourceListResultImpl(inner.getValue(), this.manager()));
+ } else {
+ return null;
+ }
+ }
+
+ public PrivateLinkResourceListResult listByPrivateLinkScope(String resourceGroupName, String scopeName) {
+ PrivateLinkResourceListResultInner inner
+ = this.serviceClient().listByPrivateLinkScope(resourceGroupName, scopeName);
+ if (inner != null) {
+ return new PrivateLinkResourceListResultImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
+ public Response getWithResponse(String resourceGroupName, String scopeName, String groupName,
+ Context context) {
+ Response inner
+ = this.serviceClient().getWithResponse(resourceGroupName, scopeName, groupName, context);
+ if (inner != null) {
+ return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
+ new PrivateLinkResourceImpl(inner.getValue(), this.manager()));
+ } else {
+ return null;
+ }
+ }
+
+ public PrivateLinkResource get(String resourceGroupName, String scopeName, String groupName) {
+ PrivateLinkResourceInner inner = this.serviceClient().get(resourceGroupName, scopeName, groupName);
+ if (inner != null) {
+ return new PrivateLinkResourceImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
+ private PrivateLinkResourcesClient serviceClient() {
+ return this.innerClient;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesClientImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesClientImpl.java
new file mode 100644
index 000000000000..e52b8ac8196c
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesClientImpl.java
@@ -0,0 +1,1118 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.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.Put;
+import com.azure.core.annotation.QueryParam;
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceInterface;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.annotation.UnexpectedResponseExceptionType;
+import com.azure.core.http.rest.PagedFlux;
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.http.rest.PagedResponse;
+import com.azure.core.http.rest.PagedResponseBase;
+import com.azure.core.http.rest.Response;
+import com.azure.core.http.rest.RestProxy;
+import com.azure.core.management.exception.ManagementException;
+import com.azure.core.util.Context;
+import com.azure.core.util.FluxUtil;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateLinkScopesClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.KubernetesConfigurationPrivateLinkScopeInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.KubernetesConfigurationPrivateLinkScopeListResult;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.TagsResource;
+import reactor.core.publisher.Mono;
+
+/**
+ * An instance of this class provides access to all the operations defined in PrivateLinkScopesClient.
+ */
+public final class PrivateLinkScopesClientImpl implements PrivateLinkScopesClient {
+ /**
+ * The proxy service used to perform REST calls.
+ */
+ private final PrivateLinkScopesService service;
+
+ /**
+ * The service client containing this operation class.
+ */
+ private final PrivateLinkScopesManagementClientImpl client;
+
+ /**
+ * Initializes an instance of PrivateLinkScopesClientImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ PrivateLinkScopesClientImpl(PrivateLinkScopesManagementClientImpl client) {
+ this.service
+ = RestProxy.create(PrivateLinkScopesService.class, client.getHttpPipeline(), client.getSerializerAdapter());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for PrivateLinkScopesManagementClientPrivateLinkScopes to be used by the
+ * proxy service to perform REST calls.
+ */
+ @Host("{$host}")
+ @ServiceInterface(name = "PrivateLinkScopesMan")
+ public interface PrivateLinkScopesService {
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes")
+ @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.KubernetesConfiguration/privateLinkScopes")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listSync(@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}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByResourceGroup(
+ @HostParam("$host") String endpoint, @PathParam("resourceGroupName") String resourceGroupName,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listByResourceGroupSync(
+ @HostParam("$host") String endpoint, @PathParam("resourceGroupName") String resourceGroupName,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200, 204 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> delete(@HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId, @PathParam("scopeName") String scopeName,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200, 204 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response deleteSync(@HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId, @PathParam("scopeName") String scopeName,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> getByResourceGroup(
+ @HostParam("$host") String endpoint, @PathParam("resourceGroupName") String resourceGroupName,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("scopeName") String scopeName, @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response getByResourceGroupSync(
+ @HostParam("$host") String endpoint, @PathParam("resourceGroupName") String resourceGroupName,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("scopeName") String scopeName, @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200, 201 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> createOrUpdate(@HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId, @PathParam("scopeName") String scopeName,
+ @BodyParam("application/json") KubernetesConfigurationPrivateLinkScopeInner parameters,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200, 201 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response createOrUpdateSync(@HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId, @PathParam("scopeName") String scopeName,
+ @BodyParam("application/json") KubernetesConfigurationPrivateLinkScopeInner parameters,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Patch("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> updateTags(@HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId, @PathParam("scopeName") String scopeName,
+ @BodyParam("application/json") TagsResource privateLinkScopeTags, @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Patch("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.KubernetesConfiguration/privateLinkScopes/{scopeName}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response updateTagsSync(@HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId, @PathParam("scopeName") String scopeName,
+ @BodyParam("application/json") TagsResource privateLinkScopeTags, @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listNextSync(
+ @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);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listByResourceGroupNextSync(
+ @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept, Context context);
+ }
+
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within a 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 a list of all Azure Arc PrivateLinkScopes within a subscription 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()));
+ }
+
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within a 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 a list of all Azure Arc PrivateLinkScopes within a subscription as paginated response with
+ * {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listAsync() {
+ return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within a 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 a list of all Azure Arc PrivateLinkScopes within a subscription along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse listSinglePage() {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res = service.listSync(this.client.getEndpoint(),
+ this.client.getApiVersion(), this.client.getSubscriptionId(), accept, Context.NONE);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within a 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 a list of all Azure Arc PrivateLinkScopes within a subscription along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse listSinglePage(Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res = service.listSync(this.client.getEndpoint(),
+ this.client.getApiVersion(), this.client.getSubscriptionId(), accept, context);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within a 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 a list of all Azure Arc PrivateLinkScopes within a subscription as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable list() {
+ return new PagedIterable<>(() -> listSinglePage(), nextLink -> listNextSinglePage(nextLink));
+ }
+
+ /**
+ * Gets a list of all Azure Arc PrivateLinkScopes within a 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 a list of all Azure Arc PrivateLinkScopes within a subscription as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable list(Context context) {
+ return new PagedIterable<>(() -> listSinglePage(context), nextLink -> listNextSinglePage(nextLink, context));
+ }
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a 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 a list of Azure Arc PrivateLinkScopes within a resource group along with {@link PagedResponse} on
+ * successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listByResourceGroupSinglePageAsync(String resourceGroupName) {
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceGroupName 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.listByResourceGroup(this.client.getEndpoint(), resourceGroupName,
+ 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()));
+ }
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a 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 a list of Azure Arc PrivateLinkScopes within a resource group as paginated response with
+ * {@link PagedFlux}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByResourceGroupAsync(String resourceGroupName) {
+ return new PagedFlux<>(() -> listByResourceGroupSinglePageAsync(resourceGroupName),
+ nextLink -> listByResourceGroupNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a 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 a list of Azure Arc PrivateLinkScopes within a resource group along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse
+ listByResourceGroupSinglePage(String resourceGroupName) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res
+ = service.listByResourceGroupSync(this.client.getEndpoint(), resourceGroupName, this.client.getApiVersion(),
+ this.client.getSubscriptionId(), accept, Context.NONE);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 list of Azure Arc PrivateLinkScopes within a resource group along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse
+ listByResourceGroupSinglePage(String resourceGroupName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res
+ = service.listByResourceGroupSync(this.client.getEndpoint(), resourceGroupName, this.client.getApiVersion(),
+ this.client.getSubscriptionId(), accept, context);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a 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 a list of Azure Arc PrivateLinkScopes within a resource group as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByResourceGroup(String resourceGroupName) {
+ return new PagedIterable<>(() -> listByResourceGroupSinglePage(resourceGroupName),
+ nextLink -> listByResourceGroupNextSinglePage(nextLink));
+ }
+
+ /**
+ * Gets a list of Azure Arc PrivateLinkScopes within a resource group.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 list of Azure Arc PrivateLinkScopes within a resource group as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByResourceGroup(String resourceGroupName,
+ Context context) {
+ return new PagedIterable<>(() -> listByResourceGroupSinglePage(resourceGroupName, context),
+ nextLink -> listByResourceGroupNextSinglePage(nextLink, context));
+ }
+
+ /**
+ * Deletes a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response} on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> deleteWithResponseAsync(String resourceGroupName, String scopeName) {
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceGroupName 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.delete(this.client.getEndpoint(), resourceGroupName,
+ this.client.getApiVersion(), this.client.getSubscriptionId(), scopeName, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Deletes a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return A {@link Mono} that completes when a successful response is received.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono deleteAsync(String resourceGroupName, String scopeName) {
+ return deleteWithResponseAsync(resourceGroupName, scopeName).flatMap(ignored -> Mono.empty());
+ }
+
+ /**
+ * Deletes a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response deleteWithResponse(String resourceGroupName, String scopeName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return service.deleteSync(this.client.getEndpoint(), resourceGroupName, this.client.getApiVersion(),
+ this.client.getSubscriptionId(), scopeName, accept, context);
+ }
+
+ /**
+ * Deletes a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public void delete(String resourceGroupName, String scopeName) {
+ deleteWithResponse(resourceGroupName, scopeName, Context.NONE);
+ }
+
+ /**
+ * Returns a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an Azure Arc PrivateLinkScope definition along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ getByResourceGroupWithResponseAsync(String resourceGroupName, String scopeName) {
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceGroupName 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.getByResourceGroup(this.client.getEndpoint(), resourceGroupName,
+ this.client.getApiVersion(), this.client.getSubscriptionId(), scopeName, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Returns a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an Azure Arc PrivateLinkScope definition on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getByResourceGroupAsync(String resourceGroupName,
+ String scopeName) {
+ return getByResourceGroupWithResponseAsync(resourceGroupName, scopeName)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Returns a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an Azure Arc PrivateLinkScope definition along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response
+ getByResourceGroupWithResponse(String resourceGroupName, String scopeName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return service.getByResourceGroupSync(this.client.getEndpoint(), resourceGroupName, this.client.getApiVersion(),
+ this.client.getSubscriptionId(), scopeName, accept, context);
+ }
+
+ /**
+ * Returns a Azure Arc PrivateLinkScope.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an Azure Arc PrivateLinkScope definition.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public KubernetesConfigurationPrivateLinkScopeInner getByResourceGroup(String resourceGroupName, String scopeName) {
+ return getByResourceGroupWithResponse(resourceGroupName, scopeName, Context.NONE).getValue();
+ }
+
+ /**
+ * Creates (or updates) a Azure Arc PrivateLinkScope. Note: You cannot specify a different value for
+ * InstrumentationKey nor AppId in the Put operation.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param parameters Properties that need to be specified to create or update a Azure Arc for Servers and Clusters
+ * PrivateLinkScope.
+ * @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 an Azure Arc PrivateLinkScope definition along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> createOrUpdateWithResponseAsync(
+ String resourceGroupName, String scopeName, KubernetesConfigurationPrivateLinkScopeInner parameters) {
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceGroupName 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (parameters == null) {
+ return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
+ } else {
+ parameters.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), resourceGroupName,
+ this.client.getApiVersion(), this.client.getSubscriptionId(), scopeName, parameters, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Creates (or updates) a Azure Arc PrivateLinkScope. Note: You cannot specify a different value for
+ * InstrumentationKey nor AppId in the Put operation.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param parameters Properties that need to be specified to create or update a Azure Arc for Servers and Clusters
+ * PrivateLinkScope.
+ * @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 an Azure Arc PrivateLinkScope definition on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createOrUpdateAsync(String resourceGroupName,
+ String scopeName, KubernetesConfigurationPrivateLinkScopeInner parameters) {
+ return createOrUpdateWithResponseAsync(resourceGroupName, scopeName, parameters)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Creates (or updates) a Azure Arc PrivateLinkScope. Note: You cannot specify a different value for
+ * InstrumentationKey nor AppId in the Put operation.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param parameters Properties that need to be specified to create or update a Azure Arc for Servers and Clusters
+ * PrivateLinkScope.
+ * @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 an Azure Arc PrivateLinkScope definition along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response createOrUpdateWithResponse(String resourceGroupName,
+ String scopeName, KubernetesConfigurationPrivateLinkScopeInner parameters, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (parameters == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
+ } else {
+ parameters.validate();
+ }
+ final String accept = "application/json";
+ return service.createOrUpdateSync(this.client.getEndpoint(), resourceGroupName, this.client.getApiVersion(),
+ this.client.getSubscriptionId(), scopeName, parameters, accept, context);
+ }
+
+ /**
+ * Creates (or updates) a Azure Arc PrivateLinkScope. Note: You cannot specify a different value for
+ * InstrumentationKey nor AppId in the Put operation.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param parameters Properties that need to be specified to create or update a Azure Arc for Servers and Clusters
+ * PrivateLinkScope.
+ * @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 an Azure Arc PrivateLinkScope definition.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public KubernetesConfigurationPrivateLinkScopeInner createOrUpdate(String resourceGroupName, String scopeName,
+ KubernetesConfigurationPrivateLinkScopeInner parameters) {
+ return createOrUpdateWithResponse(resourceGroupName, scopeName, parameters, Context.NONE).getValue();
+ }
+
+ /**
+ * Updates an existing PrivateLinkScope's tags. To update other fields use the CreateOrUpdate method.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateLinkScopeTags Updated tag information to set into the PrivateLinkScope instance.
+ * @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 an Azure Arc PrivateLinkScope definition along with {@link Response} on successful completion of
+ * {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ updateTagsWithResponseAsync(String resourceGroupName, String scopeName, TagsResource privateLinkScopeTags) {
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceGroupName 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 (scopeName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateLinkScopeTags == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter privateLinkScopeTags is required and cannot be null."));
+ } else {
+ privateLinkScopeTags.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context -> service.updateTags(this.client.getEndpoint(), resourceGroupName, this.client.getApiVersion(),
+ this.client.getSubscriptionId(), scopeName, privateLinkScopeTags, accept, context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Updates an existing PrivateLinkScope's tags. To update other fields use the CreateOrUpdate method.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateLinkScopeTags Updated tag information to set into the PrivateLinkScope instance.
+ * @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 an Azure Arc PrivateLinkScope definition on successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono updateTagsAsync(String resourceGroupName,
+ String scopeName, TagsResource privateLinkScopeTags) {
+ return updateTagsWithResponseAsync(resourceGroupName, scopeName, privateLinkScopeTags)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ }
+
+ /**
+ * Updates an existing PrivateLinkScope's tags. To update other fields use the CreateOrUpdate method.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateLinkScopeTags Updated tag information to set into the PrivateLinkScope instance.
+ * @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 an Azure Arc PrivateLinkScope definition along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response updateTagsWithResponse(String resourceGroupName,
+ String scopeName, TagsResource privateLinkScopeTags, Context context) {
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (scopeName == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter scopeName is required and cannot be null."));
+ }
+ if (privateLinkScopeTags == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter privateLinkScopeTags is required and cannot be null."));
+ } else {
+ privateLinkScopeTags.validate();
+ }
+ final String accept = "application/json";
+ return service.updateTagsSync(this.client.getEndpoint(), resourceGroupName, this.client.getApiVersion(),
+ this.client.getSubscriptionId(), scopeName, privateLinkScopeTags, accept, context);
+ }
+
+ /**
+ * Updates an existing PrivateLinkScope's tags. To update other fields use the CreateOrUpdate method.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param scopeName The name of the Azure Arc PrivateLinkScope resource.
+ * @param privateLinkScopeTags Updated tag information to set into the PrivateLinkScope instance.
+ * @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 an Azure Arc PrivateLinkScope definition.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public KubernetesConfigurationPrivateLinkScopeInner updateTags(String resourceGroupName, String scopeName,
+ TagsResource privateLinkScopeTags) {
+ return updateTagsWithResponse(resourceGroupName, scopeName, privateLinkScopeTags, Context.NONE).getValue();
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The URL to get the next list of items.
+ * @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 describes the list of Azure Arc PrivateLinkScope resources along with {@link PagedResponse} on successful
+ * completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listNextSinglePageAsync(String nextLink) {
+ if (nextLink == null) {
+ return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
+ }
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil.withContext(context -> service.listNext(nextLink, this.client.getEndpoint(), accept, context))
+ .>map(
+ res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
+ res.getValue().value(), res.getValue().nextLink(), null))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The URL to get the next list of items.
+ * @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 describes the list of Azure Arc PrivateLinkScope resources along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse listNextSinglePage(String nextLink) {
+ if (nextLink == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
+ }
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res
+ = service.listNextSync(nextLink, this.client.getEndpoint(), accept, Context.NONE);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The URL to get the next list of items.
+ * @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 describes the list of Azure Arc PrivateLinkScope resources along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse listNextSinglePage(String nextLink,
+ Context context) {
+ if (nextLink == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
+ }
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res
+ = service.listNextSync(nextLink, this.client.getEndpoint(), accept, context);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The URL to get the next list of items.
+ * @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 describes the list of Azure Arc PrivateLinkScope resources along with {@link PagedResponse} on successful
+ * completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listByResourceGroupNextSinglePageAsync(String nextLink) {
+ if (nextLink == null) {
+ return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
+ }
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context -> service.listByResourceGroupNext(nextLink, this.client.getEndpoint(), accept, context))
+ .>map(
+ res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
+ res.getValue().value(), res.getValue().nextLink(), null))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The URL to get the next list of items.
+ * @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 describes the list of Azure Arc PrivateLinkScope resources along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse
+ listByResourceGroupNextSinglePage(String nextLink) {
+ if (nextLink == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
+ }
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res
+ = service.listByResourceGroupNextSync(nextLink, this.client.getEndpoint(), accept, Context.NONE);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The URL to get the next list of items.
+ * @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 describes the list of Azure Arc PrivateLinkScope resources along with {@link PagedResponse}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private PagedResponse
+ listByResourceGroupNextSinglePage(String nextLink, Context context) {
+ if (nextLink == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
+ }
+ if (this.client.getEndpoint() == null) {
+ throw LOGGER.atError()
+ .log(new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ Response res
+ = service.listByResourceGroupNextSync(nextLink, this.client.getEndpoint(), accept, context);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
+ }
+
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateLinkScopesClientImpl.class);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesImpl.java
new file mode 100644
index 000000000000..c487029055bd
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesImpl.java
@@ -0,0 +1,155 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.http.rest.Response;
+import com.azure.core.http.rest.SimpleResponse;
+import com.azure.core.util.Context;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateLinkScopesClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.KubernetesConfigurationPrivateLinkScopeInner;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.KubernetesConfigurationPrivateLinkScope;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.models.PrivateLinkScopes;
+
+public final class PrivateLinkScopesImpl implements PrivateLinkScopes {
+ private static final ClientLogger LOGGER = new ClientLogger(PrivateLinkScopesImpl.class);
+
+ private final PrivateLinkScopesClient innerClient;
+
+ private final com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager;
+
+ public PrivateLinkScopesImpl(PrivateLinkScopesClient innerClient,
+ com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager serviceManager) {
+ this.innerClient = innerClient;
+ this.serviceManager = serviceManager;
+ }
+
+ public PagedIterable list() {
+ PagedIterable inner = this.serviceClient().list();
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new KubernetesConfigurationPrivateLinkScopeImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable list(Context context) {
+ PagedIterable inner = this.serviceClient().list(context);
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new KubernetesConfigurationPrivateLinkScopeImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listByResourceGroup(String resourceGroupName) {
+ PagedIterable inner
+ = this.serviceClient().listByResourceGroup(resourceGroupName);
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new KubernetesConfigurationPrivateLinkScopeImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listByResourceGroup(String resourceGroupName,
+ Context context) {
+ PagedIterable inner
+ = this.serviceClient().listByResourceGroup(resourceGroupName, context);
+ return ResourceManagerUtils.mapPage(inner,
+ inner1 -> new KubernetesConfigurationPrivateLinkScopeImpl(inner1, this.manager()));
+ }
+
+ public Response deleteByResourceGroupWithResponse(String resourceGroupName, String scopeName,
+ Context context) {
+ return this.serviceClient().deleteWithResponse(resourceGroupName, scopeName, context);
+ }
+
+ public void deleteByResourceGroup(String resourceGroupName, String scopeName) {
+ this.serviceClient().delete(resourceGroupName, scopeName);
+ }
+
+ public Response getByResourceGroupWithResponse(String resourceGroupName,
+ String scopeName, Context context) {
+ Response inner
+ = this.serviceClient().getByResourceGroupWithResponse(resourceGroupName, scopeName, context);
+ if (inner != null) {
+ return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
+ new KubernetesConfigurationPrivateLinkScopeImpl(inner.getValue(), this.manager()));
+ } else {
+ return null;
+ }
+ }
+
+ public KubernetesConfigurationPrivateLinkScope getByResourceGroup(String resourceGroupName, String scopeName) {
+ KubernetesConfigurationPrivateLinkScopeInner inner
+ = this.serviceClient().getByResourceGroup(resourceGroupName, scopeName);
+ if (inner != null) {
+ return new KubernetesConfigurationPrivateLinkScopeImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
+ public KubernetesConfigurationPrivateLinkScope getById(String id) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ return this.getByResourceGroupWithResponse(resourceGroupName, scopeName, Context.NONE).getValue();
+ }
+
+ public Response getByIdWithResponse(String id, Context context) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ return this.getByResourceGroupWithResponse(resourceGroupName, scopeName, context);
+ }
+
+ public void deleteById(String id) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ this.deleteByResourceGroupWithResponse(resourceGroupName, scopeName, Context.NONE);
+ }
+
+ public Response deleteByIdWithResponse(String id, Context context) {
+ String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
+ if (resourceGroupName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
+ }
+ String scopeName = ResourceManagerUtils.getValueFromIdByName(id, "privateLinkScopes");
+ if (scopeName == null) {
+ throw LOGGER.logExceptionAsError(new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'privateLinkScopes'.", id)));
+ }
+ return this.deleteByResourceGroupWithResponse(resourceGroupName, scopeName, context);
+ }
+
+ private PrivateLinkScopesClient serviceClient() {
+ return this.innerClient;
+ }
+
+ private com.azure.resourcemanager.kubernetesconfigurationprivateli.PrivateLinkScopesManager manager() {
+ return this.serviceManager;
+ }
+
+ public KubernetesConfigurationPrivateLinkScopeImpl define(String name) {
+ return new KubernetesConfigurationPrivateLinkScopeImpl(name, this.manager());
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesManagementClientBuilder.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesManagementClientBuilder.java
new file mode 100644
index 000000000000..aadd71c17819
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesManagementClientBuilder.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.kubernetesconfigurationprivateli.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 PrivateLinkScopesManagementClientImpl type.
+ */
+@ServiceClientBuilder(serviceClients = { PrivateLinkScopesManagementClientImpl.class })
+public final class PrivateLinkScopesManagementClientBuilder {
+ /*
+ * The ID of the target subscription.
+ */
+ private String subscriptionId;
+
+ /**
+ * Sets The ID of the target subscription.
+ *
+ * @param subscriptionId the subscriptionId value.
+ * @return the PrivateLinkScopesManagementClientBuilder.
+ */
+ public PrivateLinkScopesManagementClientBuilder subscriptionId(String subscriptionId) {
+ this.subscriptionId = subscriptionId;
+ return this;
+ }
+
+ /*
+ * server parameter
+ */
+ private String endpoint;
+
+ /**
+ * Sets server parameter.
+ *
+ * @param endpoint the endpoint value.
+ * @return the PrivateLinkScopesManagementClientBuilder.
+ */
+ public PrivateLinkScopesManagementClientBuilder 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 PrivateLinkScopesManagementClientBuilder.
+ */
+ public PrivateLinkScopesManagementClientBuilder 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 PrivateLinkScopesManagementClientBuilder.
+ */
+ public PrivateLinkScopesManagementClientBuilder 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 PrivateLinkScopesManagementClientBuilder.
+ */
+ public PrivateLinkScopesManagementClientBuilder 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 PrivateLinkScopesManagementClientBuilder.
+ */
+ public PrivateLinkScopesManagementClientBuilder serializerAdapter(SerializerAdapter serializerAdapter) {
+ this.serializerAdapter = serializerAdapter;
+ return this;
+ }
+
+ /**
+ * Builds an instance of PrivateLinkScopesManagementClientImpl with the provided parameters.
+ *
+ * @return an instance of PrivateLinkScopesManagementClientImpl.
+ */
+ public PrivateLinkScopesManagementClientImpl 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();
+ PrivateLinkScopesManagementClientImpl client = new PrivateLinkScopesManagementClientImpl(localPipeline,
+ localSerializerAdapter, localDefaultPollInterval, localEnvironment, this.subscriptionId, localEndpoint);
+ return client;
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesManagementClientImpl.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesManagementClientImpl.java
new file mode 100644
index 000000000000..3970a6190a12
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/PrivateLinkScopesManagementClientImpl.java
@@ -0,0 +1,340 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.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.management.polling.SyncPollerFactory;
+import com.azure.core.util.BinaryData;
+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.polling.SyncPoller;
+import com.azure.core.util.serializer.SerializerAdapter;
+import com.azure.core.util.serializer.SerializerEncoding;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateEndpointConnectionsClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateLinkResourcesClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateLinkScopesClient;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.PrivateLinkScopesManagementClient;
+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 PrivateLinkScopesManagementClientImpl type.
+ */
+@ServiceClient(builder = PrivateLinkScopesManagementClientBuilder.class)
+public final class PrivateLinkScopesManagementClientImpl implements PrivateLinkScopesManagementClient {
+ /**
+ * The ID of the target subscription.
+ */
+ private final String subscriptionId;
+
+ /**
+ * Gets The ID of the target subscription.
+ *
+ * @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 PrivateLinkScopesClient object to access its operations.
+ */
+ private final PrivateLinkScopesClient privateLinkScopes;
+
+ /**
+ * Gets the PrivateLinkScopesClient object to access its operations.
+ *
+ * @return the PrivateLinkScopesClient object.
+ */
+ public PrivateLinkScopesClient getPrivateLinkScopes() {
+ return this.privateLinkScopes;
+ }
+
+ /**
+ * 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 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;
+ }
+
+ /**
+ * Initializes an instance of PrivateLinkScopesManagementClient 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.
+ * @param endpoint server parameter.
+ */
+ PrivateLinkScopesManagementClientImpl(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-preview";
+ this.privateLinkScopes = new PrivateLinkScopesClientImpl(this);
+ this.privateLinkResources = new PrivateLinkResourcesClientImpl(this);
+ this.privateEndpointConnections = new PrivateEndpointConnectionsClientImpl(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 long running operation result.
+ *
+ * @param activationResponse the response of activation operation.
+ * @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 SyncPoller for poll result and final result.
+ */
+ public SyncPoller, U> getLroResult(Response activationResponse,
+ Type pollResultType, Type finalResultType, Context context) {
+ return SyncPollerFactory.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(PrivateLinkScopesManagementClientImpl.class);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/ResourceManagerUtils.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/ResourceManagerUtils.java
new file mode 100644
index 000000000000..35b231a30b19
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/ResourceManagerUtils.java
@@ -0,0 +1,195 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
+
+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.util.CoreUtils;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import java.util.function.Function;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
+import reactor.core.publisher.Flux;
+
+final class ResourceManagerUtils {
+ private ResourceManagerUtils() {
+ }
+
+ static String getValueFromIdByName(String id, String name) {
+ if (id == null) {
+ return null;
+ }
+ Iterator itr = Arrays.stream(id.split("/")).iterator();
+ while (itr.hasNext()) {
+ String part = itr.next();
+ if (part != null && !part.trim().isEmpty()) {
+ if (part.equalsIgnoreCase(name)) {
+ if (itr.hasNext()) {
+ return itr.next();
+ } else {
+ return null;
+ }
+ }
+ }
+ }
+ return null;
+ }
+
+ static String getValueFromIdByParameterName(String id, String pathTemplate, String parameterName) {
+ if (id == null || pathTemplate == null) {
+ return null;
+ }
+ String parameterNameParentheses = "{" + parameterName + "}";
+ List idSegmentsReverted = Arrays.asList(id.split("/"));
+ List pathSegments = Arrays.asList(pathTemplate.split("/"));
+ Collections.reverse(idSegmentsReverted);
+ Iterator idItrReverted = idSegmentsReverted.iterator();
+ int pathIndex = pathSegments.size();
+ while (idItrReverted.hasNext() && pathIndex > 0) {
+ String idSegment = idItrReverted.next();
+ String pathSegment = pathSegments.get(--pathIndex);
+ if (!CoreUtils.isNullOrEmpty(idSegment) && !CoreUtils.isNullOrEmpty(pathSegment)) {
+ if (pathSegment.equalsIgnoreCase(parameterNameParentheses)) {
+ if (pathIndex == 0 || (pathIndex == 1 && pathSegments.get(0).isEmpty())) {
+ List segments = new ArrayList<>();
+ segments.add(idSegment);
+ idItrReverted.forEachRemaining(segments::add);
+ Collections.reverse(segments);
+ if (!segments.isEmpty() && segments.get(0).isEmpty()) {
+ segments.remove(0);
+ }
+ return String.join("/", segments);
+ } else {
+ return idSegment;
+ }
+ }
+ }
+ }
+ return null;
+ }
+
+ static PagedIterable mapPage(PagedIterable pageIterable, Function mapper) {
+ return new PagedIterableImpl<>(pageIterable, mapper);
+ }
+
+ private static final class PagedIterableImpl extends PagedIterable {
+
+ private final PagedIterable pagedIterable;
+ private final Function mapper;
+ private final Function, PagedResponse> pageMapper;
+
+ private PagedIterableImpl(PagedIterable pagedIterable, Function mapper) {
+ super(PagedFlux.create(() -> (continuationToken, pageSize) -> Flux
+ .fromStream(pagedIterable.streamByPage().map(getPageMapper(mapper)))));
+ this.pagedIterable = pagedIterable;
+ this.mapper = mapper;
+ this.pageMapper = getPageMapper(mapper);
+ }
+
+ private static Function, PagedResponse> getPageMapper(Function mapper) {
+ return page -> new PagedResponseBase(page.getRequest(), page.getStatusCode(), page.getHeaders(),
+ page.getElements().stream().map(mapper).collect(Collectors.toList()), page.getContinuationToken(),
+ null);
+ }
+
+ @Override
+ public Stream stream() {
+ return pagedIterable.stream().map(mapper);
+ }
+
+ @Override
+ public Stream> streamByPage() {
+ return pagedIterable.streamByPage().map(pageMapper);
+ }
+
+ @Override
+ public Stream> streamByPage(String continuationToken) {
+ return pagedIterable.streamByPage(continuationToken).map(pageMapper);
+ }
+
+ @Override
+ public Stream> streamByPage(int preferredPageSize) {
+ return pagedIterable.streamByPage(preferredPageSize).map(pageMapper);
+ }
+
+ @Override
+ public Stream> streamByPage(String continuationToken, int preferredPageSize) {
+ return pagedIterable.streamByPage(continuationToken, preferredPageSize).map(pageMapper);
+ }
+
+ @Override
+ public Iterator iterator() {
+ return new IteratorImpl<>(pagedIterable.iterator(), mapper);
+ }
+
+ @Override
+ public Iterable> iterableByPage() {
+ return new IterableImpl<>(pagedIterable.iterableByPage(), pageMapper);
+ }
+
+ @Override
+ public Iterable> iterableByPage(String continuationToken) {
+ return new IterableImpl<>(pagedIterable.iterableByPage(continuationToken), pageMapper);
+ }
+
+ @Override
+ public Iterable> iterableByPage(int preferredPageSize) {
+ return new IterableImpl<>(pagedIterable.iterableByPage(preferredPageSize), pageMapper);
+ }
+
+ @Override
+ public Iterable> iterableByPage(String continuationToken, int preferredPageSize) {
+ return new IterableImpl<>(pagedIterable.iterableByPage(continuationToken, preferredPageSize), pageMapper);
+ }
+ }
+
+ private static final class IteratorImpl implements Iterator {
+
+ private final Iterator iterator;
+ private final Function mapper;
+
+ private IteratorImpl(Iterator iterator, Function mapper) {
+ this.iterator = iterator;
+ this.mapper = mapper;
+ }
+
+ @Override
+ public boolean hasNext() {
+ return iterator.hasNext();
+ }
+
+ @Override
+ public S next() {
+ return mapper.apply(iterator.next());
+ }
+
+ @Override
+ public void remove() {
+ iterator.remove();
+ }
+ }
+
+ private static final class IterableImpl implements Iterable {
+
+ private final Iterable iterable;
+ private final Function mapper;
+
+ private IterableImpl(Iterable iterable, Function mapper) {
+ this.iterable = iterable;
+ this.mapper = mapper;
+ }
+
+ @Override
+ public Iterator iterator() {
+ return new IteratorImpl<>(iterable.iterator(), mapper);
+ }
+ }
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/package-info.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/package-info.java
new file mode 100644
index 000000000000..9a28e18409b8
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/implementation/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 implementations for PrivateLinkScopesManagementClient.
+ * PrivateLinkScopes Client.
+ */
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.implementation;
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/models/KubernetesConfigurationPrivateLinkScope.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/models/KubernetesConfigurationPrivateLinkScope.java
new file mode 100644
index 000000000000..d21e05e159a0
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/models/KubernetesConfigurationPrivateLinkScope.java
@@ -0,0 +1,254 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.models;
+
+import com.azure.core.management.Region;
+import com.azure.core.management.SystemData;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.KubernetesConfigurationPrivateLinkScopeInner;
+import java.util.Map;
+
+/**
+ * An immutable client-side representation of KubernetesConfigurationPrivateLinkScope.
+ */
+public interface KubernetesConfigurationPrivateLinkScope {
+ /**
+ * Gets the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ String id();
+
+ /**
+ * Gets the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ String name();
+
+ /**
+ * Gets the type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ String type();
+
+ /**
+ * Gets the location property: The geo-location where the resource lives.
+ *
+ * @return the location value.
+ */
+ String location();
+
+ /**
+ * Gets the tags property: Resource tags.
+ *
+ * @return the tags value.
+ */
+ Map tags();
+
+ /**
+ * Gets the properties property: Properties that define a Azure Arc PrivateLinkScope resource.
+ *
+ * @return the properties value.
+ */
+ KubernetesConfigurationPrivateLinkScopeProperties properties();
+
+ /**
+ * Gets the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
+ *
+ * @return the systemData value.
+ */
+ SystemData systemData();
+
+ /**
+ * Gets the region of the resource.
+ *
+ * @return the region of the resource.
+ */
+ Region region();
+
+ /**
+ * Gets the name of the resource region.
+ *
+ * @return the name of the resource region.
+ */
+ String regionName();
+
+ /**
+ * Gets the name of the resource group.
+ *
+ * @return the name of the resource group.
+ */
+ String resourceGroupName();
+
+ /**
+ * Gets the inner
+ * com.azure.resourcemanager.kubernetesconfigurationprivateli.fluent.models.KubernetesConfigurationPrivateLinkScopeInner
+ * object.
+ *
+ * @return the inner object.
+ */
+ KubernetesConfigurationPrivateLinkScopeInner innerModel();
+
+ /**
+ * The entirety of the KubernetesConfigurationPrivateLinkScope definition.
+ */
+ interface Definition extends DefinitionStages.Blank, DefinitionStages.WithLocation,
+ DefinitionStages.WithResourceGroup, DefinitionStages.WithCreate {
+ }
+
+ /**
+ * The KubernetesConfigurationPrivateLinkScope definition stages.
+ */
+ interface DefinitionStages {
+ /**
+ * The first stage of the KubernetesConfigurationPrivateLinkScope definition.
+ */
+ interface Blank extends WithLocation {
+ }
+
+ /**
+ * The stage of the KubernetesConfigurationPrivateLinkScope definition allowing to specify location.
+ */
+ interface WithLocation {
+ /**
+ * Specifies the region for the resource.
+ *
+ * @param location The geo-location where the resource lives.
+ * @return the next definition stage.
+ */
+ WithResourceGroup withRegion(Region location);
+
+ /**
+ * Specifies the region for the resource.
+ *
+ * @param location The geo-location where the resource lives.
+ * @return the next definition stage.
+ */
+ WithResourceGroup withRegion(String location);
+ }
+
+ /**
+ * The stage of the KubernetesConfigurationPrivateLinkScope definition allowing to specify parent resource.
+ */
+ interface WithResourceGroup {
+ /**
+ * Specifies resourceGroupName.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @return the next definition stage.
+ */
+ WithCreate withExistingResourceGroup(String resourceGroupName);
+ }
+
+ /**
+ * The stage of the KubernetesConfigurationPrivateLinkScope definition which contains all the minimum required
+ * properties for the resource to be created, but also allows for any other optional properties to be specified.
+ */
+ interface WithCreate extends DefinitionStages.WithTags, DefinitionStages.WithProperties {
+ /**
+ * Executes the create request.
+ *
+ * @return the created resource.
+ */
+ KubernetesConfigurationPrivateLinkScope create();
+
+ /**
+ * Executes the create request.
+ *
+ * @param context The context to associate with this operation.
+ * @return the created resource.
+ */
+ KubernetesConfigurationPrivateLinkScope create(Context context);
+ }
+
+ /**
+ * The stage of the KubernetesConfigurationPrivateLinkScope definition allowing to specify tags.
+ */
+ interface WithTags {
+ /**
+ * Specifies the tags property: Resource tags..
+ *
+ * @param tags Resource tags.
+ * @return the next definition stage.
+ */
+ WithCreate withTags(Map tags);
+ }
+
+ /**
+ * The stage of the KubernetesConfigurationPrivateLinkScope definition allowing to specify properties.
+ */
+ interface WithProperties {
+ /**
+ * Specifies the properties property: Properties that define a Azure Arc PrivateLinkScope resource..
+ *
+ * @param properties Properties that define a Azure Arc PrivateLinkScope resource.
+ * @return the next definition stage.
+ */
+ WithCreate withProperties(KubernetesConfigurationPrivateLinkScopeProperties properties);
+ }
+ }
+
+ /**
+ * Begins update for the KubernetesConfigurationPrivateLinkScope resource.
+ *
+ * @return the stage of resource update.
+ */
+ KubernetesConfigurationPrivateLinkScope.Update update();
+
+ /**
+ * The template for KubernetesConfigurationPrivateLinkScope update.
+ */
+ interface Update extends UpdateStages.WithTags {
+ /**
+ * Executes the update request.
+ *
+ * @return the updated resource.
+ */
+ KubernetesConfigurationPrivateLinkScope apply();
+
+ /**
+ * Executes the update request.
+ *
+ * @param context The context to associate with this operation.
+ * @return the updated resource.
+ */
+ KubernetesConfigurationPrivateLinkScope apply(Context context);
+ }
+
+ /**
+ * The KubernetesConfigurationPrivateLinkScope update stages.
+ */
+ interface UpdateStages {
+ /**
+ * The stage of the KubernetesConfigurationPrivateLinkScope update allowing to specify tags.
+ */
+ interface WithTags {
+ /**
+ * Specifies the tags property: Resource tags.
+ *
+ * @param tags Resource tags.
+ * @return the next definition stage.
+ */
+ Update withTags(Map tags);
+ }
+ }
+
+ /**
+ * Refreshes the resource to sync with Azure.
+ *
+ * @return the refreshed resource.
+ */
+ KubernetesConfigurationPrivateLinkScope refresh();
+
+ /**
+ * Refreshes the resource to sync with Azure.
+ *
+ * @param context The context to associate with this operation.
+ * @return the refreshed resource.
+ */
+ KubernetesConfigurationPrivateLinkScope refresh(Context context);
+}
diff --git a/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/models/KubernetesConfigurationPrivateLinkScopeListResult.java b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/models/KubernetesConfigurationPrivateLinkScopeListResult.java
new file mode 100644
index 000000000000..8e7aa84e4a78
--- /dev/null
+++ b/sdk/kubernetesconfigurationprivateli/azure-resourcemanager-kubernetesconfigurationprivateli/src/main/java/com/azure/resourcemanager/kubernetesconfigurationprivateli/models/KubernetesConfigurationPrivateLinkScopeListResult.java
@@ -0,0 +1,143 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.kubernetesconfigurationprivateli.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.kubernetesconfigurationprivateli.fluent.models.KubernetesConfigurationPrivateLinkScopeInner;
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * Describes the list of Azure Arc PrivateLinkScope resources.
+ */
+@Fluent
+public final class KubernetesConfigurationPrivateLinkScopeListResult
+ implements JsonSerializable {
+ /*
+ * List of Azure Arc PrivateLinkScope definitions.
+ */
+ private List value;
+
+ /*
+ * The URI to get the next set of Azure Arc PrivateLinkScope definitions if too many PrivateLinkScopes where
+ * returned in the result set.
+ */
+ private String nextLink;
+
+ /**
+ * Creates an instance of KubernetesConfigurationPrivateLinkScopeListResult class.
+ */
+ public KubernetesConfigurationPrivateLinkScopeListResult() {
+ }
+
+ /**
+ * Get the value property: List of Azure Arc PrivateLinkScope definitions.
+ *
+ * @return the value value.
+ */
+ public List