diff --git a/sdk/peering/azure-resourcemanager-peering/CHANGELOG.md b/sdk/peering/azure-resourcemanager-peering/CHANGELOG.md
index f85a9a1a1873..ef54f1d5c213 100644
--- a/sdk/peering/azure-resourcemanager-peering/CHANGELOG.md
+++ b/sdk/peering/azure-resourcemanager-peering/CHANGELOG.md
@@ -1,7 +1,8 @@
# Release History
-## 1.0.0-beta.2 (Unreleased)
+## 1.0.0-beta.1 (2021-04-25)
+- Azure Resource Manager Peering client library for Java. This package contains Microsoft Azure SDK for Peering Management SDK. Peering Client. Package tag package-2019-08-01-preview. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## 1.0.0-beta.1 (2021-04-19)
diff --git a/sdk/peering/azure-resourcemanager-peering/README.md b/sdk/peering/azure-resourcemanager-peering/README.md
index 00d3a5d8a383..f11e9bd69ed8 100644
--- a/sdk/peering/azure-resourcemanager-peering/README.md
+++ b/sdk/peering/azure-resourcemanager-peering/README.md
@@ -2,7 +2,7 @@
Azure Resource Manager Peering client library for Java.
-This package contains Microsoft Azure SDK for Peering Management SDK. Peering Client. Package tag package-2021-01-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
+This package contains Microsoft Azure SDK for Peering Management SDK. Peering Client. Package tag package-2019-08-01-preview. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## We'd love to hear your feedback
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
com.azure.resourcemanager
azure-resourcemanager-peering
- 1.0.0-beta.1
+ 1.0.0-beta.2
```
[//]: # ({x-version-update-end})
diff --git a/sdk/peering/azure-resourcemanager-peering/pom.xml b/sdk/peering/azure-resourcemanager-peering/pom.xml
index 46bc8ca72d24..6f556f03961c 100644
--- a/sdk/peering/azure-resourcemanager-peering/pom.xml
+++ b/sdk/peering/azure-resourcemanager-peering/pom.xml
@@ -13,7 +13,7 @@
jar
Microsoft Azure SDK for Peering Management
- This package contains Microsoft Azure SDK for Peering Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Peering Client. Package tag package-2021-01-01.
+ This package contains Microsoft Azure SDK for Peering Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Peering Client. Package tag package-2019-08-01-preview.
https://github.com/Azure/azure-sdk-for-java
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/PeeringManager.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/PeeringManager.java
index f06d8a6805ce..cb5af573c129 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/PeeringManager.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/PeeringManager.java
@@ -21,36 +21,28 @@
import com.azure.core.util.Configuration;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.peering.fluent.PeeringManagementClient;
-import com.azure.resourcemanager.peering.implementation.CdnPeeringPrefixesImpl;
import com.azure.resourcemanager.peering.implementation.LegacyPeeringsImpl;
import com.azure.resourcemanager.peering.implementation.OperationsImpl;
import com.azure.resourcemanager.peering.implementation.PeerAsnsImpl;
import com.azure.resourcemanager.peering.implementation.PeeringLocationsImpl;
import com.azure.resourcemanager.peering.implementation.PeeringManagementClientBuilder;
-import com.azure.resourcemanager.peering.implementation.PeeringServiceCountriesImpl;
import com.azure.resourcemanager.peering.implementation.PeeringServiceLocationsImpl;
+import com.azure.resourcemanager.peering.implementation.PeeringServicePrefixesImpl;
import com.azure.resourcemanager.peering.implementation.PeeringServiceProvidersImpl;
import com.azure.resourcemanager.peering.implementation.PeeringServicesImpl;
import com.azure.resourcemanager.peering.implementation.PeeringsImpl;
import com.azure.resourcemanager.peering.implementation.PrefixesImpl;
-import com.azure.resourcemanager.peering.implementation.ReceivedRoutesImpl;
-import com.azure.resourcemanager.peering.implementation.RegisteredAsnsImpl;
-import com.azure.resourcemanager.peering.implementation.RegisteredPrefixesImpl;
import com.azure.resourcemanager.peering.implementation.ResourceProvidersImpl;
-import com.azure.resourcemanager.peering.models.CdnPeeringPrefixes;
import com.azure.resourcemanager.peering.models.LegacyPeerings;
import com.azure.resourcemanager.peering.models.Operations;
import com.azure.resourcemanager.peering.models.PeerAsns;
import com.azure.resourcemanager.peering.models.PeeringLocations;
-import com.azure.resourcemanager.peering.models.PeeringServiceCountries;
import com.azure.resourcemanager.peering.models.PeeringServiceLocations;
+import com.azure.resourcemanager.peering.models.PeeringServicePrefixes;
import com.azure.resourcemanager.peering.models.PeeringServiceProviders;
import com.azure.resourcemanager.peering.models.PeeringServices;
import com.azure.resourcemanager.peering.models.Peerings;
import com.azure.resourcemanager.peering.models.Prefixes;
-import com.azure.resourcemanager.peering.models.ReceivedRoutes;
-import com.azure.resourcemanager.peering.models.RegisteredAsns;
-import com.azure.resourcemanager.peering.models.RegisteredPrefixes;
import com.azure.resourcemanager.peering.models.ResourceProviders;
import java.time.Duration;
import java.time.temporal.ChronoUnit;
@@ -60,8 +52,6 @@
/** Entry point to PeeringManager. Peering Client. */
public final class PeeringManager {
- private CdnPeeringPrefixes cdnPeeringPrefixes;
-
private ResourceProviders resourceProviders;
private LegacyPeerings legacyPeerings;
@@ -72,18 +62,12 @@ public final class PeeringManager {
private PeeringLocations peeringLocations;
- private RegisteredAsns registeredAsns;
-
- private RegisteredPrefixes registeredPrefixes;
-
private Peerings peerings;
- private ReceivedRoutes receivedRoutes;
-
- private PeeringServiceCountries peeringServiceCountries;
-
private PeeringServiceLocations peeringServiceLocations;
+ private PeeringServicePrefixes peeringServicePrefixes;
+
private Prefixes prefixes;
private PeeringServiceProviders peeringServiceProviders;
@@ -253,14 +237,6 @@ public PeeringManager authenticate(TokenCredential credential, AzureProfile prof
}
}
- /** @return Resource collection API of CdnPeeringPrefixes. */
- public CdnPeeringPrefixes cdnPeeringPrefixes() {
- if (this.cdnPeeringPrefixes == null) {
- this.cdnPeeringPrefixes = new CdnPeeringPrefixesImpl(clientObject.getCdnPeeringPrefixes(), this);
- }
- return cdnPeeringPrefixes;
- }
-
/** @return Resource collection API of ResourceProviders. */
public ResourceProviders resourceProviders() {
if (this.resourceProviders == null) {
@@ -301,22 +277,6 @@ public PeeringLocations peeringLocations() {
return peeringLocations;
}
- /** @return Resource collection API of RegisteredAsns. */
- public RegisteredAsns registeredAsns() {
- if (this.registeredAsns == null) {
- this.registeredAsns = new RegisteredAsnsImpl(clientObject.getRegisteredAsns(), this);
- }
- return registeredAsns;
- }
-
- /** @return Resource collection API of RegisteredPrefixes. */
- public RegisteredPrefixes registeredPrefixes() {
- if (this.registeredPrefixes == null) {
- this.registeredPrefixes = new RegisteredPrefixesImpl(clientObject.getRegisteredPrefixes(), this);
- }
- return registeredPrefixes;
- }
-
/** @return Resource collection API of Peerings. */
public Peerings peerings() {
if (this.peerings == null) {
@@ -325,23 +285,6 @@ public Peerings peerings() {
return peerings;
}
- /** @return Resource collection API of ReceivedRoutes. */
- public ReceivedRoutes receivedRoutes() {
- if (this.receivedRoutes == null) {
- this.receivedRoutes = new ReceivedRoutesImpl(clientObject.getReceivedRoutes(), this);
- }
- return receivedRoutes;
- }
-
- /** @return Resource collection API of PeeringServiceCountries. */
- public PeeringServiceCountries peeringServiceCountries() {
- if (this.peeringServiceCountries == null) {
- this.peeringServiceCountries =
- new PeeringServiceCountriesImpl(clientObject.getPeeringServiceCountries(), this);
- }
- return peeringServiceCountries;
- }
-
/** @return Resource collection API of PeeringServiceLocations. */
public PeeringServiceLocations peeringServiceLocations() {
if (this.peeringServiceLocations == null) {
@@ -351,6 +294,15 @@ public PeeringServiceLocations peeringServiceLocations() {
return peeringServiceLocations;
}
+ /** @return Resource collection API of PeeringServicePrefixes. */
+ public PeeringServicePrefixes peeringServicePrefixes() {
+ if (this.peeringServicePrefixes == null) {
+ this.peeringServicePrefixes =
+ new PeeringServicePrefixesImpl(clientObject.getPeeringServicePrefixes(), this);
+ }
+ return peeringServicePrefixes;
+ }
+
/** @return Resource collection API of Prefixes. */
public Prefixes prefixes() {
if (this.prefixes == null) {
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/CdnPeeringPrefixesClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/CdnPeeringPrefixesClient.java
deleted file mode 100644
index 50ed5b9c39aa..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/CdnPeeringPrefixesClient.java
+++ /dev/null
@@ -1,39 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.peering.fluent.models.CdnPeeringPrefixInner;
-
-/** An instance of this class provides access to all the operations defined in CdnPeeringPrefixesClient. */
-public interface CdnPeeringPrefixesClient {
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String peeringLocation);
-
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String peeringLocation, Context context);
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/LegacyPeeringsClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/LegacyPeeringsClient.java
index c8cba0bec65e..44bc1b9315e3 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/LegacyPeeringsClient.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/LegacyPeeringsClient.java
@@ -31,7 +31,6 @@ public interface LegacyPeeringsClient {
*
* @param peeringLocation The location of the peering.
* @param kind The kind of the peering.
- * @param asn The ASN number associated with a legacy peering.
* @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.
@@ -39,5 +38,5 @@ public interface LegacyPeeringsClient {
* @return the paginated list of peerings.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String peeringLocation, LegacyPeeringsKind kind, Integer asn, Context context);
+ PagedIterable list(String peeringLocation, LegacyPeeringsKind kind, Context context);
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringManagementClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringManagementClient.java
index 70c527cbb0ea..91da6d848e04 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringManagementClient.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringManagementClient.java
@@ -44,13 +44,6 @@ public interface PeeringManagementClient {
*/
Duration getDefaultPollInterval();
- /**
- * Gets the CdnPeeringPrefixesClient object to access its operations.
- *
- * @return the CdnPeeringPrefixesClient object.
- */
- CdnPeeringPrefixesClient getCdnPeeringPrefixes();
-
/**
* Gets the ResourceProvidersClient object to access its operations.
*
@@ -86,20 +79,6 @@ public interface PeeringManagementClient {
*/
PeeringLocationsClient getPeeringLocations();
- /**
- * Gets the RegisteredAsnsClient object to access its operations.
- *
- * @return the RegisteredAsnsClient object.
- */
- RegisteredAsnsClient getRegisteredAsns();
-
- /**
- * Gets the RegisteredPrefixesClient object to access its operations.
- *
- * @return the RegisteredPrefixesClient object.
- */
- RegisteredPrefixesClient getRegisteredPrefixes();
-
/**
* Gets the PeeringsClient object to access its operations.
*
@@ -108,25 +87,18 @@ public interface PeeringManagementClient {
PeeringsClient getPeerings();
/**
- * Gets the ReceivedRoutesClient object to access its operations.
- *
- * @return the ReceivedRoutesClient object.
- */
- ReceivedRoutesClient getReceivedRoutes();
-
- /**
- * Gets the PeeringServiceCountriesClient object to access its operations.
+ * Gets the PeeringServiceLocationsClient object to access its operations.
*
- * @return the PeeringServiceCountriesClient object.
+ * @return the PeeringServiceLocationsClient object.
*/
- PeeringServiceCountriesClient getPeeringServiceCountries();
+ PeeringServiceLocationsClient getPeeringServiceLocations();
/**
- * Gets the PeeringServiceLocationsClient object to access its operations.
+ * Gets the PeeringServicePrefixesClient object to access its operations.
*
- * @return the PeeringServiceLocationsClient object.
+ * @return the PeeringServicePrefixesClient object.
*/
- PeeringServiceLocationsClient getPeeringServiceLocations();
+ PeeringServicePrefixesClient getPeeringServicePrefixes();
/**
* Gets the PrefixesClient object to access its operations.
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServiceCountriesClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServiceCountriesClient.java
deleted file mode 100644
index 83b9d54e207f..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServiceCountriesClient.java
+++ /dev/null
@@ -1,36 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.peering.fluent.models.PeeringServiceCountryInner;
-
-/** An instance of this class provides access to all the operations defined in PeeringServiceCountriesClient. */
-public interface PeeringServiceCountriesClient {
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list();
-
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(Context context);
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServiceLocationsClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServiceLocationsClient.java
index 69f837fdd14c..4eb5a2609ab9 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServiceLocationsClient.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServiceLocationsClient.java
@@ -13,7 +13,7 @@
/** An instance of this class provides access to all the operations defined in PeeringServiceLocationsClient. */
public interface PeeringServiceLocationsClient {
/**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
* @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.
@@ -23,9 +23,8 @@ public interface PeeringServiceLocationsClient {
PagedIterable list();
/**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
- * @param country The country of interest, in which the locations are to be present.
* @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.
@@ -33,5 +32,5 @@ public interface PeeringServiceLocationsClient {
* @return the paginated list of peering service locations.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String country, Context context);
+ PagedIterable list(Context context);
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServicePrefixesClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServicePrefixesClient.java
new file mode 100644
index 000000000000..ea07d29052ab
--- /dev/null
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PeeringServicePrefixesClient.java
@@ -0,0 +1,113 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.peering.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.peering.fluent.models.PeeringServicePrefixInner;
+
+/** An instance of this class provides access to all the operations defined in PeeringServicePrefixesClient. */
+public interface PeeringServicePrefixesClient {
+ /**
+ * Gets the peering service prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peering service prefix.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PeeringServicePrefixInner get(String resourceGroupName, String peeringServiceName, String prefixName);
+
+ /**
+ * Gets the peering service prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peering service prefix.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context);
+
+ /**
+ * Creates or updates the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param peeringServicePrefix The IP prefix for an peering.
+ * @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 peering service prefix class.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PeeringServicePrefixInner createOrUpdate(
+ String resourceGroupName,
+ String peeringServiceName,
+ String prefixName,
+ PeeringServicePrefixInner peeringServicePrefix);
+
+ /**
+ * Creates or updates the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param peeringServicePrefix The IP prefix for an peering.
+ * @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 peering service prefix class.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response createOrUpdateWithResponse(
+ String resourceGroupName,
+ String peeringServiceName,
+ String prefixName,
+ PeeringServicePrefixInner peeringServicePrefix,
+ Context context);
+
+ /**
+ * removes the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peeringServiceName, String prefixName);
+
+ /**
+ * removes the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response deleteWithResponse(
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context);
+}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PrefixesClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PrefixesClient.java
index ab6755d21576..0722cb0ff5b4 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PrefixesClient.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/PrefixesClient.java
@@ -7,142 +7,36 @@
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.peering.fluent.models.PeeringServicePrefixInner;
/** An instance of this class provides access to all the operations defined in PrefixesClient. */
public interface PrefixesClient {
/**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- PeeringServicePrefixInner get(String resourceGroupName, String peeringServiceName, String prefixName);
-
- /**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param expand The properties to be expanded.
- * @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(
- String resourceGroupName, String peeringServiceName, String prefixName, String expand, Context context);
-
- /**
- * Creates a new prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param peeringServicePrefix The properties needed to create a prefix.
- * @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 peering service prefix class.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- PeeringServicePrefixInner createOrUpdate(
- String resourceGroupName,
- String peeringServiceName,
- String prefixName,
- PeeringServicePrefixInner peeringServicePrefix);
-
- /**
- * Creates a new prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param peeringServicePrefix The properties needed to create a prefix.
- * @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 peering service prefix class.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(
- String resourceGroupName,
- String peeringServiceName,
- String prefixName,
- PeeringServicePrefixInner peeringServicePrefix,
- Context context);
-
- /**
- * Deletes an existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @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 peeringServiceName, String prefixName);
-
- /**
- * Deletes an existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the response.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(
- String resourceGroupName, String peeringServiceName, String prefixName, Context context);
-
- /**
- * Lists all prefixes under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable listByPeeringService(String resourceGroupName, String peeringServiceName);
/**
- * Lists all prefixes under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param expand The properties to be expanded.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable listByPeeringService(
- String resourceGroupName, String peeringServiceName, String expand, Context context);
+ String resourceGroupName, String peeringServiceName, Context context);
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/ReceivedRoutesClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/ReceivedRoutesClient.java
deleted file mode 100644
index 028c632042c3..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/ReceivedRoutesClient.java
+++ /dev/null
@@ -1,54 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.peering.fluent.models.PeeringReceivedRouteInner;
-
-/** An instance of this class provides access to all the operations defined in ReceivedRoutesClient. */
-public interface ReceivedRoutesClient {
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByPeering(String resourceGroupName, String peeringName);
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param prefix The optional prefix that can be used to filter the routes.
- * @param asPath The optional AS path that can be used to filter the routes.
- * @param originAsValidationState The optional origin AS validation state that can be used to filter the routes.
- * @param rpkiValidationState The optional RPKI validation state that can be used to filter the routes.
- * @param skipToken The optional page continuation token that is used in the event of paginated result.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByPeering(
- String resourceGroupName,
- String peeringName,
- String prefix,
- String asPath,
- String originAsValidationState,
- String rpkiValidationState,
- String skipToken,
- Context context);
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/RegisteredAsnsClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/RegisteredAsnsClient.java
deleted file mode 100644
index 36c7448d7392..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/RegisteredAsnsClient.java
+++ /dev/null
@@ -1,146 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.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.peering.fluent.models.PeeringRegisteredAsnInner;
-
-/** An instance of this class provides access to all the operations defined in RegisteredAsnsClient. */
-public interface RegisteredAsnsClient {
- /**
- * Gets an existing registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- PeeringRegisteredAsnInner get(String resourceGroupName, String peeringName, String registeredAsnName);
-
- /**
- * Gets an existing registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context);
-
- /**
- * Creates a new registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the ASN.
- * @param registeredAsn The properties needed to create a registered ASN.
- * @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 customer's ASN that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- PeeringRegisteredAsnInner createOrUpdate(
- String resourceGroupName,
- String peeringName,
- String registeredAsnName,
- PeeringRegisteredAsnInner registeredAsn);
-
- /**
- * Creates a new registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the ASN.
- * @param registeredAsn The properties needed to create a registered ASN.
- * @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 customer's ASN that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(
- String resourceGroupName,
- String peeringName,
- String registeredAsnName,
- PeeringRegisteredAsnInner registeredAsn,
- Context context);
-
- /**
- * Deletes an existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 peeringName, String registeredAsnName);
-
- /**
- * Deletes an existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the response.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context);
-
- /**
- * Lists all registered ASNs under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of peering registered ASNs.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByPeering(String resourceGroupName, String peeringName);
-
- /**
- * Lists all registered ASNs under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of peering registered ASNs.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByPeering(
- String resourceGroupName, String peeringName, Context context);
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/RegisteredPrefixesClient.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/RegisteredPrefixesClient.java
deleted file mode 100644
index fb587e31173e..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/RegisteredPrefixesClient.java
+++ /dev/null
@@ -1,148 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.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.peering.fluent.models.PeeringRegisteredPrefixInner;
-
-/** An instance of this class provides access to all the operations defined in RegisteredPrefixesClient. */
-public interface RegisteredPrefixesClient {
- /**
- * Gets an existing registered prefix with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredPrefixName The name of the registered prefix.
- * @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 existing registered prefix with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- PeeringRegisteredPrefixInner get(String resourceGroupName, String peeringName, String registeredPrefixName);
-
- /**
- * Gets an existing registered prefix with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredPrefixName The name of the registered prefix.
- * @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 existing registered prefix with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(
- String resourceGroupName, String peeringName, String registeredPrefixName, Context context);
-
- /**
- * Creates a new registered prefix with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredPrefixName The name of the registered prefix.
- * @param registeredPrefix The properties needed to create a registered prefix.
- * @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 customer's prefix that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- PeeringRegisteredPrefixInner createOrUpdate(
- String resourceGroupName,
- String peeringName,
- String registeredPrefixName,
- PeeringRegisteredPrefixInner registeredPrefix);
-
- /**
- * Creates a new registered prefix with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredPrefixName The name of the registered prefix.
- * @param registeredPrefix The properties needed to create a registered prefix.
- * @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 customer's prefix that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(
- String resourceGroupName,
- String peeringName,
- String registeredPrefixName,
- PeeringRegisteredPrefixInner registeredPrefix,
- Context context);
-
- /**
- * Deletes an existing registered prefix with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredPrefixName The name of the registered prefix.
- * @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 peeringName, String registeredPrefixName);
-
- /**
- * Deletes an existing registered prefix with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredPrefixName The name of the registered prefix.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the response.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(
- String resourceGroupName, String peeringName, String registeredPrefixName, Context context);
-
- /**
- * Lists all registered prefixes under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of peering registered prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByPeering(String resourceGroupName, String peeringName);
-
- /**
- * Lists all registered prefixes under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of peering registered prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByPeering(
- String resourceGroupName, String peeringName, Context context);
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/CdnPeeringPrefixInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/CdnPeeringPrefixInner.java
deleted file mode 100644
index aae2b0bb7dc9..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/CdnPeeringPrefixInner.java
+++ /dev/null
@@ -1,102 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent.models;
-
-import com.azure.core.annotation.Immutable;
-import com.azure.core.annotation.JsonFlatten;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The CDN peering prefix. */
-@JsonFlatten
-@Immutable
-public class CdnPeeringPrefixInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(CdnPeeringPrefixInner.class);
-
- /*
- * The prefix.
- */
- @JsonProperty(value = "properties.prefix", access = JsonProperty.Access.WRITE_ONLY)
- private String prefix;
-
- /*
- * The Azure region.
- */
- @JsonProperty(value = "properties.azureRegion", access = JsonProperty.Access.WRITE_ONLY)
- private String azureRegion;
-
- /*
- * The Azure service.
- */
- @JsonProperty(value = "properties.azureService", access = JsonProperty.Access.WRITE_ONLY)
- private String azureService;
-
- /*
- * The flag that indicates whether or not this is the primary region.
- */
- @JsonProperty(value = "properties.isPrimaryRegion", access = JsonProperty.Access.WRITE_ONLY)
- private Boolean isPrimaryRegion;
-
- /*
- * The BGP Community
- */
- @JsonProperty(value = "properties.bgpCommunity", access = JsonProperty.Access.WRITE_ONLY)
- private String bgpCommunity;
-
- /**
- * Get the prefix property: The prefix.
- *
- * @return the prefix value.
- */
- public String prefix() {
- return this.prefix;
- }
-
- /**
- * Get the azureRegion property: The Azure region.
- *
- * @return the azureRegion value.
- */
- public String azureRegion() {
- return this.azureRegion;
- }
-
- /**
- * Get the azureService property: The Azure service.
- *
- * @return the azureService value.
- */
- public String azureService() {
- return this.azureService;
- }
-
- /**
- * Get the isPrimaryRegion property: The flag that indicates whether or not this is the primary region.
- *
- * @return the isPrimaryRegion value.
- */
- public Boolean isPrimaryRegion() {
- return this.isPrimaryRegion;
- }
-
- /**
- * Get the bgpCommunity property: The BGP Community.
- *
- * @return the bgpCommunity value.
- */
- public String bgpCommunity() {
- return this.bgpCommunity;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeerAsnInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeerAsnInner.java
index 562bcd708fd0..a0875ff82e1f 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeerAsnInner.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeerAsnInner.java
@@ -8,11 +8,10 @@
import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.models.ContactDetail;
+import com.azure.resourcemanager.peering.models.ContactInfo;
import com.azure.resourcemanager.peering.models.ValidationState;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
/** The essential information related to the peer's ASN. */
@JsonFlatten
@@ -27,10 +26,10 @@ public class PeerAsnInner extends ProxyResource {
private Integer peerAsn;
/*
- * The contact details of the peer.
+ * The contact information of the peer.
*/
- @JsonProperty(value = "properties.peerContactDetail")
- private List peerContactDetail;
+ @JsonProperty(value = "properties.peerContactInfo")
+ private ContactInfo peerContactInfo;
/*
* The name of the peer.
@@ -44,12 +43,6 @@ public class PeerAsnInner extends ProxyResource {
@JsonProperty(value = "properties.validationState")
private ValidationState validationState;
- /*
- * The error message for the validation state
- */
- @JsonProperty(value = "properties.errorMessage", access = JsonProperty.Access.WRITE_ONLY)
- private String errorMessage;
-
/**
* Get the peerAsn property: The Autonomous System Number (ASN) of the peer.
*
@@ -71,22 +64,22 @@ public PeerAsnInner withPeerAsn(Integer peerAsn) {
}
/**
- * Get the peerContactDetail property: The contact details of the peer.
+ * Get the peerContactInfo property: The contact information of the peer.
*
- * @return the peerContactDetail value.
+ * @return the peerContactInfo value.
*/
- public List peerContactDetail() {
- return this.peerContactDetail;
+ public ContactInfo peerContactInfo() {
+ return this.peerContactInfo;
}
/**
- * Set the peerContactDetail property: The contact details of the peer.
+ * Set the peerContactInfo property: The contact information of the peer.
*
- * @param peerContactDetail the peerContactDetail value to set.
+ * @param peerContactInfo the peerContactInfo value to set.
* @return the PeerAsnInner object itself.
*/
- public PeerAsnInner withPeerContactDetail(List peerContactDetail) {
- this.peerContactDetail = peerContactDetail;
+ public PeerAsnInner withPeerContactInfo(ContactInfo peerContactInfo) {
+ this.peerContactInfo = peerContactInfo;
return this;
}
@@ -130,23 +123,14 @@ public PeerAsnInner withValidationState(ValidationState validationState) {
return this;
}
- /**
- * Get the errorMessage property: The error message for the validation state.
- *
- * @return the errorMessage value.
- */
- public String errorMessage() {
- return this.errorMessage;
- }
-
/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (peerContactDetail() != null) {
- peerContactDetail().forEach(e -> e.validate());
+ if (peerContactInfo() != null) {
+ peerContactInfo().validate();
}
}
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringReceivedRouteInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringReceivedRouteInner.java
deleted file mode 100644
index ce5d8d729f52..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringReceivedRouteInner.java
+++ /dev/null
@@ -1,133 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent.models;
-
-import com.azure.core.annotation.Immutable;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The properties that define a received route. */
-@Immutable
-public final class PeeringReceivedRouteInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringReceivedRouteInner.class);
-
- /*
- * The prefix.
- */
- @JsonProperty(value = "prefix", access = JsonProperty.Access.WRITE_ONLY)
- private String prefix;
-
- /*
- * The next hop for the prefix.
- */
- @JsonProperty(value = "nextHop", access = JsonProperty.Access.WRITE_ONLY)
- private String nextHop;
-
- /*
- * The AS path for the prefix.
- */
- @JsonProperty(value = "asPath", access = JsonProperty.Access.WRITE_ONLY)
- private String asPath;
-
- /*
- * The origin AS change information for the prefix.
- */
- @JsonProperty(value = "originAsValidationState", access = JsonProperty.Access.WRITE_ONLY)
- private String originAsValidationState;
-
- /*
- * The RPKI validation state for the prefix and origin AS that's listed in
- * the AS path.
- */
- @JsonProperty(value = "rpkiValidationState", access = JsonProperty.Access.WRITE_ONLY)
- private String rpkiValidationState;
-
- /*
- * The authority which holds the Route Origin Authorization record for the
- * prefix, if any.
- */
- @JsonProperty(value = "trustAnchor", access = JsonProperty.Access.WRITE_ONLY)
- private String trustAnchor;
-
- /*
- * The received timestamp associated with the prefix.
- */
- @JsonProperty(value = "receivedTimestamp", access = JsonProperty.Access.WRITE_ONLY)
- private String receivedTimestamp;
-
- /**
- * Get the prefix property: The prefix.
- *
- * @return the prefix value.
- */
- public String prefix() {
- return this.prefix;
- }
-
- /**
- * Get the nextHop property: The next hop for the prefix.
- *
- * @return the nextHop value.
- */
- public String nextHop() {
- return this.nextHop;
- }
-
- /**
- * Get the asPath property: The AS path for the prefix.
- *
- * @return the asPath value.
- */
- public String asPath() {
- return this.asPath;
- }
-
- /**
- * Get the originAsValidationState property: The origin AS change information for the prefix.
- *
- * @return the originAsValidationState value.
- */
- public String originAsValidationState() {
- return this.originAsValidationState;
- }
-
- /**
- * Get the rpkiValidationState property: The RPKI validation state for the prefix and origin AS that's listed in the
- * AS path.
- *
- * @return the rpkiValidationState value.
- */
- public String rpkiValidationState() {
- return this.rpkiValidationState;
- }
-
- /**
- * Get the trustAnchor property: The authority which holds the Route Origin Authorization record for the prefix, if
- * any.
- *
- * @return the trustAnchor value.
- */
- public String trustAnchor() {
- return this.trustAnchor;
- }
-
- /**
- * Get the receivedTimestamp property: The received timestamp associated with the prefix.
- *
- * @return the receivedTimestamp value.
- */
- public String receivedTimestamp() {
- return this.receivedTimestamp;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringRegisteredAsnInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringRegisteredAsnInner.java
deleted file mode 100644
index 5c842bd1c148..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringRegisteredAsnInner.java
+++ /dev/null
@@ -1,84 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The customer's ASN that is registered by the peering service provider. */
-@JsonFlatten
-@Fluent
-public class PeeringRegisteredAsnInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringRegisteredAsnInner.class);
-
- /*
- * The customer's ASN from which traffic originates.
- */
- @JsonProperty(value = "properties.asn")
- private Integer asn;
-
- /*
- * The peering service prefix key that is to be shared with the customer.
- */
- @JsonProperty(value = "properties.peeringServicePrefixKey", access = JsonProperty.Access.WRITE_ONLY)
- private String peeringServicePrefixKey;
-
- /*
- * The provisioning state of the resource.
- */
- @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
- private ProvisioningState provisioningState;
-
- /**
- * Get the asn property: The customer's ASN from which traffic originates.
- *
- * @return the asn value.
- */
- public Integer asn() {
- return this.asn;
- }
-
- /**
- * Set the asn property: The customer's ASN from which traffic originates.
- *
- * @param asn the asn value to set.
- * @return the PeeringRegisteredAsnInner object itself.
- */
- public PeeringRegisteredAsnInner withAsn(Integer asn) {
- this.asn = asn;
- return this;
- }
-
- /**
- * Get the peeringServicePrefixKey property: The peering service prefix key that is to be shared with the customer.
- *
- * @return the peeringServicePrefixKey value.
- */
- public String peeringServicePrefixKey() {
- return this.peeringServicePrefixKey;
- }
-
- /**
- * Get the provisioningState property: The provisioning state of the resource.
- *
- * @return the provisioningState value.
- */
- public ProvisioningState provisioningState() {
- return this.provisioningState;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringRegisteredPrefixInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringRegisteredPrefixInner.java
deleted file mode 100644
index 0be2d0ffa58c..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringRegisteredPrefixInner.java
+++ /dev/null
@@ -1,115 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.models.PrefixValidationState;
-import com.azure.resourcemanager.peering.models.ProvisioningState;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The customer's prefix that is registered by the peering service provider. */
-@JsonFlatten
-@Fluent
-public class PeeringRegisteredPrefixInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringRegisteredPrefixInner.class);
-
- /*
- * The customer's prefix from which traffic originates.
- */
- @JsonProperty(value = "properties.prefix")
- private String prefix;
-
- /*
- * The prefix validation state.
- */
- @JsonProperty(value = "properties.prefixValidationState", access = JsonProperty.Access.WRITE_ONLY)
- private PrefixValidationState prefixValidationState;
-
- /*
- * The peering service prefix key that is to be shared with the customer.
- */
- @JsonProperty(value = "properties.peeringServicePrefixKey", access = JsonProperty.Access.WRITE_ONLY)
- private String peeringServicePrefixKey;
-
- /*
- * The error message associated with the validation state, if any.
- */
- @JsonProperty(value = "properties.errorMessage", access = JsonProperty.Access.WRITE_ONLY)
- private String errorMessage;
-
- /*
- * The provisioning state of the resource.
- */
- @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
- private ProvisioningState provisioningState;
-
- /**
- * Get the prefix property: The customer's prefix from which traffic originates.
- *
- * @return the prefix value.
- */
- public String prefix() {
- return this.prefix;
- }
-
- /**
- * Set the prefix property: The customer's prefix from which traffic originates.
- *
- * @param prefix the prefix value to set.
- * @return the PeeringRegisteredPrefixInner object itself.
- */
- public PeeringRegisteredPrefixInner withPrefix(String prefix) {
- this.prefix = prefix;
- return this;
- }
-
- /**
- * Get the prefixValidationState property: The prefix validation state.
- *
- * @return the prefixValidationState value.
- */
- public PrefixValidationState prefixValidationState() {
- return this.prefixValidationState;
- }
-
- /**
- * Get the peeringServicePrefixKey property: The peering service prefix key that is to be shared with the customer.
- *
- * @return the peeringServicePrefixKey value.
- */
- public String peeringServicePrefixKey() {
- return this.peeringServicePrefixKey;
- }
-
- /**
- * Get the errorMessage property: The error message associated with the validation state, if any.
- *
- * @return the errorMessage value.
- */
- public String errorMessage() {
- return this.errorMessage;
- }
-
- /**
- * Get the provisioningState property: The provisioning state of the resource.
- *
- * @return the provisioningState value.
- */
- public ProvisioningState provisioningState() {
- return this.provisioningState;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceCountryInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceCountryInner.java
deleted file mode 100644
index 8770e2db5098..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceCountryInner.java
+++ /dev/null
@@ -1,24 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.fluent.models;
-
-import com.azure.core.annotation.Immutable;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-
-/** The peering service country. */
-@Immutable
-public final class PeeringServiceCountryInner extends ProxyResource {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringServiceCountryInner.class);
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceInner.java
index 749f22d16f86..60579c680d8a 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceInner.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceInner.java
@@ -8,7 +8,6 @@
import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.ProxyResource;
import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.models.PeeringServiceSku;
import com.azure.resourcemanager.peering.models.ProvisioningState;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
@@ -20,12 +19,6 @@
public class PeeringServiceInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringServiceInner.class);
- /*
- * The SKU that defines the type of the peering service.
- */
- @JsonProperty(value = "sku")
- private PeeringServiceSku sku;
-
/*
* The location of the resource.
*/
@@ -39,13 +32,13 @@ public class PeeringServiceInner extends ProxyResource {
private Map tags;
/*
- * The location (state/province) of the customer.
+ * The PeeringServiceLocation of the Customer.
*/
@JsonProperty(value = "properties.peeringServiceLocation")
private String peeringServiceLocation;
/*
- * The name of the service provider.
+ * The MAPS Provider Name.
*/
@JsonProperty(value = "properties.peeringServiceProvider")
private String peeringServiceProvider;
@@ -56,40 +49,6 @@ public class PeeringServiceInner extends ProxyResource {
@JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
private ProvisioningState provisioningState;
- /*
- * The primary peering (Microsoft/service provider) location to be used for
- * customer traffic.
- */
- @JsonProperty(value = "properties.providerPrimaryPeeringLocation")
- private String providerPrimaryPeeringLocation;
-
- /*
- * The backup peering (Microsoft/service provider) location to be used for
- * customer traffic.
- */
- @JsonProperty(value = "properties.providerBackupPeeringLocation")
- private String providerBackupPeeringLocation;
-
- /**
- * Get the sku property: The SKU that defines the type of the peering service.
- *
- * @return the sku value.
- */
- public PeeringServiceSku sku() {
- return this.sku;
- }
-
- /**
- * Set the sku property: The SKU that defines the type of the peering service.
- *
- * @param sku the sku value to set.
- * @return the PeeringServiceInner object itself.
- */
- public PeeringServiceInner withSku(PeeringServiceSku sku) {
- this.sku = sku;
- return this;
- }
-
/**
* Get the location property: The location of the resource.
*
@@ -131,7 +90,7 @@ public PeeringServiceInner withTags(Map tags) {
}
/**
- * Get the peeringServiceLocation property: The location (state/province) of the customer.
+ * Get the peeringServiceLocation property: The PeeringServiceLocation of the Customer.
*
* @return the peeringServiceLocation value.
*/
@@ -140,7 +99,7 @@ public String peeringServiceLocation() {
}
/**
- * Set the peeringServiceLocation property: The location (state/province) of the customer.
+ * Set the peeringServiceLocation property: The PeeringServiceLocation of the Customer.
*
* @param peeringServiceLocation the peeringServiceLocation value to set.
* @return the PeeringServiceInner object itself.
@@ -151,7 +110,7 @@ public PeeringServiceInner withPeeringServiceLocation(String peeringServiceLocat
}
/**
- * Get the peeringServiceProvider property: The name of the service provider.
+ * Get the peeringServiceProvider property: The MAPS Provider Name.
*
* @return the peeringServiceProvider value.
*/
@@ -160,7 +119,7 @@ public String peeringServiceProvider() {
}
/**
- * Set the peeringServiceProvider property: The name of the service provider.
+ * Set the peeringServiceProvider property: The MAPS Provider Name.
*
* @param peeringServiceProvider the peeringServiceProvider value to set.
* @return the PeeringServiceInner object itself.
@@ -179,59 +138,12 @@ public ProvisioningState provisioningState() {
return this.provisioningState;
}
- /**
- * Get the providerPrimaryPeeringLocation property: The primary peering (Microsoft/service provider) location to be
- * used for customer traffic.
- *
- * @return the providerPrimaryPeeringLocation value.
- */
- public String providerPrimaryPeeringLocation() {
- return this.providerPrimaryPeeringLocation;
- }
-
- /**
- * Set the providerPrimaryPeeringLocation property: The primary peering (Microsoft/service provider) location to be
- * used for customer traffic.
- *
- * @param providerPrimaryPeeringLocation the providerPrimaryPeeringLocation value to set.
- * @return the PeeringServiceInner object itself.
- */
- public PeeringServiceInner withProviderPrimaryPeeringLocation(String providerPrimaryPeeringLocation) {
- this.providerPrimaryPeeringLocation = providerPrimaryPeeringLocation;
- return this;
- }
-
- /**
- * Get the providerBackupPeeringLocation property: The backup peering (Microsoft/service provider) location to be
- * used for customer traffic.
- *
- * @return the providerBackupPeeringLocation value.
- */
- public String providerBackupPeeringLocation() {
- return this.providerBackupPeeringLocation;
- }
-
- /**
- * Set the providerBackupPeeringLocation property: The backup peering (Microsoft/service provider) location to be
- * used for customer traffic.
- *
- * @param providerBackupPeeringLocation the providerBackupPeeringLocation value to set.
- * @return the PeeringServiceInner object itself.
- */
- public PeeringServiceInner withProviderBackupPeeringLocation(String providerBackupPeeringLocation) {
- this.providerBackupPeeringLocation = providerBackupPeeringLocation;
- return this;
- }
-
/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (sku() != null) {
- sku().validate();
- }
if (location() == null) {
throw logger
.logExceptionAsError(
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceLocationInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceLocationInner.java
index f8a70650d7e3..01cb8ab58267 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceLocationInner.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceLocationInner.java
@@ -11,7 +11,7 @@
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
-/** The peering service location. */
+/** PeeringService location. */
@JsonFlatten
@Fluent
public class PeeringServiceLocationInner extends ProxyResource {
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServicePrefixInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServicePrefixInner.java
index 841e9636f4db..383aa3a0b103 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServicePrefixInner.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServicePrefixInner.java
@@ -9,12 +9,10 @@
import com.azure.core.management.ProxyResource;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.peering.models.LearnedType;
-import com.azure.resourcemanager.peering.models.PeeringServicePrefixEvent;
import com.azure.resourcemanager.peering.models.PrefixValidationState;
import com.azure.resourcemanager.peering.models.ProvisioningState;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
/** The peering service prefix class. */
@JsonFlatten
@@ -23,7 +21,7 @@ public class PeeringServicePrefixInner extends ProxyResource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringServicePrefixInner.class);
/*
- * The prefix from which your traffic originates.
+ * Valid route prefix
*/
@JsonProperty(value = "properties.prefix")
private String prefix;
@@ -31,33 +29,15 @@ public class PeeringServicePrefixInner extends ProxyResource {
/*
* The prefix validation state
*/
- @JsonProperty(value = "properties.prefixValidationState", access = JsonProperty.Access.WRITE_ONLY)
+ @JsonProperty(value = "properties.prefixValidationState")
private PrefixValidationState prefixValidationState;
/*
* The prefix learned type
*/
- @JsonProperty(value = "properties.learnedType", access = JsonProperty.Access.WRITE_ONLY)
+ @JsonProperty(value = "properties.learnedType")
private LearnedType learnedType;
- /*
- * The error message for validation state
- */
- @JsonProperty(value = "properties.errorMessage", access = JsonProperty.Access.WRITE_ONLY)
- private String errorMessage;
-
- /*
- * The list of events for peering service prefix
- */
- @JsonProperty(value = "properties.events", access = JsonProperty.Access.WRITE_ONLY)
- private List events;
-
- /*
- * The peering service prefix key
- */
- @JsonProperty(value = "properties.peeringServicePrefixKey")
- private String peeringServicePrefixKey;
-
/*
* The provisioning state of the resource.
*/
@@ -65,7 +45,7 @@ public class PeeringServicePrefixInner extends ProxyResource {
private ProvisioningState provisioningState;
/**
- * Get the prefix property: The prefix from which your traffic originates.
+ * Get the prefix property: Valid route prefix.
*
* @return the prefix value.
*/
@@ -74,7 +54,7 @@ public String prefix() {
}
/**
- * Set the prefix property: The prefix from which your traffic originates.
+ * Set the prefix property: Valid route prefix.
*
* @param prefix the prefix value to set.
* @return the PeeringServicePrefixInner object itself.
@@ -94,49 +74,33 @@ public PrefixValidationState prefixValidationState() {
}
/**
- * Get the learnedType property: The prefix learned type.
+ * Set the prefixValidationState property: The prefix validation state.
*
- * @return the learnedType value.
- */
- public LearnedType learnedType() {
- return this.learnedType;
- }
-
- /**
- * Get the errorMessage property: The error message for validation state.
- *
- * @return the errorMessage value.
- */
- public String errorMessage() {
- return this.errorMessage;
- }
-
- /**
- * Get the events property: The list of events for peering service prefix.
- *
- * @return the events value.
+ * @param prefixValidationState the prefixValidationState value to set.
+ * @return the PeeringServicePrefixInner object itself.
*/
- public List events() {
- return this.events;
+ public PeeringServicePrefixInner withPrefixValidationState(PrefixValidationState prefixValidationState) {
+ this.prefixValidationState = prefixValidationState;
+ return this;
}
/**
- * Get the peeringServicePrefixKey property: The peering service prefix key.
+ * Get the learnedType property: The prefix learned type.
*
- * @return the peeringServicePrefixKey value.
+ * @return the learnedType value.
*/
- public String peeringServicePrefixKey() {
- return this.peeringServicePrefixKey;
+ public LearnedType learnedType() {
+ return this.learnedType;
}
/**
- * Set the peeringServicePrefixKey property: The peering service prefix key.
+ * Set the learnedType property: The prefix learned type.
*
- * @param peeringServicePrefixKey the peeringServicePrefixKey value to set.
+ * @param learnedType the learnedType value to set.
* @return the PeeringServicePrefixInner object itself.
*/
- public PeeringServicePrefixInner withPeeringServicePrefixKey(String peeringServicePrefixKey) {
- this.peeringServicePrefixKey = peeringServicePrefixKey;
+ public PeeringServicePrefixInner withLearnedType(LearnedType learnedType) {
+ this.learnedType = learnedType;
return this;
}
@@ -155,8 +119,5 @@ public ProvisioningState provisioningState() {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (events() != null) {
- events().forEach(e -> e.validate());
- }
}
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceProviderInner.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceProviderInner.java
index da060a5aa1da..850b738ff1e7 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceProviderInner.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/fluent/models/PeeringServiceProviderInner.java
@@ -10,7 +10,6 @@
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
/** PeeringService provider. */
@JsonFlatten
@@ -24,13 +23,6 @@ public class PeeringServiceProviderInner extends ProxyResource {
@JsonProperty(value = "properties.serviceProviderName")
private String serviceProviderName;
- /*
- * The list of locations at which the service provider peers with
- * Microsoft.
- */
- @JsonProperty(value = "properties.peeringLocations")
- private List peeringLocations;
-
/**
* Get the serviceProviderName property: The name of the service provider.
*
@@ -51,26 +43,6 @@ public PeeringServiceProviderInner withServiceProviderName(String serviceProvide
return this;
}
- /**
- * Get the peeringLocations property: The list of locations at which the service provider peers with Microsoft.
- *
- * @return the peeringLocations value.
- */
- public List peeringLocations() {
- return this.peeringLocations;
- }
-
- /**
- * Set the peeringLocations property: The list of locations at which the service provider peers with Microsoft.
- *
- * @param peeringLocations the peeringLocations value to set.
- * @return the PeeringServiceProviderInner object itself.
- */
- public PeeringServiceProviderInner withPeeringLocations(List peeringLocations) {
- this.peeringLocations = peeringLocations;
- return this;
- }
-
/**
* Validates the instance.
*
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixImpl.java
deleted file mode 100644
index eef26890de86..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixImpl.java
+++ /dev/null
@@ -1,60 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.resourcemanager.peering.fluent.models.CdnPeeringPrefixInner;
-import com.azure.resourcemanager.peering.models.CdnPeeringPrefix;
-
-public final class CdnPeeringPrefixImpl implements CdnPeeringPrefix {
- private CdnPeeringPrefixInner innerObject;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- CdnPeeringPrefixImpl(
- CdnPeeringPrefixInner innerObject, com.azure.resourcemanager.peering.PeeringManager 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 String prefix() {
- return this.innerModel().prefix();
- }
-
- public String azureRegion() {
- return this.innerModel().azureRegion();
- }
-
- public String azureService() {
- return this.innerModel().azureService();
- }
-
- public Boolean isPrimaryRegion() {
- return this.innerModel().isPrimaryRegion();
- }
-
- public String bgpCommunity() {
- return this.innerModel().bgpCommunity();
- }
-
- public CdnPeeringPrefixInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixesClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixesClientImpl.java
deleted file mode 100644
index d8e93e1c95e6..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixesClientImpl.java
+++ /dev/null
@@ -1,316 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.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.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.peering.fluent.CdnPeeringPrefixesClient;
-import com.azure.resourcemanager.peering.fluent.models.CdnPeeringPrefixInner;
-import com.azure.resourcemanager.peering.models.CdnPeeringPrefixListResult;
-import reactor.core.publisher.Mono;
-
-/** An instance of this class provides access to all the operations defined in CdnPeeringPrefixesClient. */
-public final class CdnPeeringPrefixesClientImpl implements CdnPeeringPrefixesClient {
- private final ClientLogger logger = new ClientLogger(CdnPeeringPrefixesClientImpl.class);
-
- /** The proxy service used to perform REST calls. */
- private final CdnPeeringPrefixesService service;
-
- /** The service client containing this operation class. */
- private final PeeringManagementClientImpl client;
-
- /**
- * Initializes an instance of CdnPeeringPrefixesClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- CdnPeeringPrefixesClientImpl(PeeringManagementClientImpl client) {
- this.service =
- RestProxy.create(CdnPeeringPrefixesService.class, client.getHttpPipeline(), client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for PeeringManagementClientCdnPeeringPrefixes to be used by the proxy
- * service to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "PeeringManagementCli")
- private interface CdnPeeringPrefixesService {
- @Headers({"Content-Type: application/json"})
- @Get("/subscriptions/{subscriptionId}/providers/Microsoft.Peering/cdnPeeringPrefixes")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(
- @HostParam("$host") String endpoint,
- @QueryParam("peeringLocation") String peeringLocation,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @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);
- }
-
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String peeringLocation) {
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (peeringLocation == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringLocation 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(),
- peeringLocation,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- 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()));
- }
-
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String peeringLocation, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (peeringLocation == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringLocation is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(
- this.client.getEndpoint(),
- peeringLocation,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
- }
-
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String peeringLocation) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(peeringLocation), nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String peeringLocation, Context context) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(peeringLocation, context),
- nextLink -> listNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String peeringLocation) {
- return new PagedIterable<>(listAsync(peeringLocation));
- }
-
- /**
- * Lists all of the advertised prefixes for the specified peering location.
- *
- * @param peeringLocation The peering location.
- * @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 paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String peeringLocation, Context context) {
- return new PagedIterable<>(listAsync(peeringLocation, context));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The nextLink parameter.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the paginated list of CDN peering prefixes.
- */
- @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 nextLink parameter.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the paginated list of CDN peering prefixes.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink, Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .listNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixesImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixesImpl.java
deleted file mode 100644
index 4594b349f43b..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/CdnPeeringPrefixesImpl.java
+++ /dev/null
@@ -1,46 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.util.Context;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.fluent.CdnPeeringPrefixesClient;
-import com.azure.resourcemanager.peering.fluent.models.CdnPeeringPrefixInner;
-import com.azure.resourcemanager.peering.models.CdnPeeringPrefix;
-import com.azure.resourcemanager.peering.models.CdnPeeringPrefixes;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-
-public final class CdnPeeringPrefixesImpl implements CdnPeeringPrefixes {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(CdnPeeringPrefixesImpl.class);
-
- private final CdnPeeringPrefixesClient innerClient;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- public CdnPeeringPrefixesImpl(
- CdnPeeringPrefixesClient innerClient, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerClient = innerClient;
- this.serviceManager = serviceManager;
- }
-
- public PagedIterable list(String peeringLocation) {
- PagedIterable inner = this.serviceClient().list(peeringLocation);
- return Utils.mapPage(inner, inner1 -> new CdnPeeringPrefixImpl(inner1, this.manager()));
- }
-
- public PagedIterable list(String peeringLocation, Context context) {
- PagedIterable inner = this.serviceClient().list(peeringLocation, context);
- return Utils.mapPage(inner, inner1 -> new CdnPeeringPrefixImpl(inner1, this.manager()));
- }
-
- private CdnPeeringPrefixesClient serviceClient() {
- return this.innerClient;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsClientImpl.java
index 544847e55a06..39c706e451f2 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsClientImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsClientImpl.java
@@ -68,7 +68,6 @@ Mono> list(
@HostParam("$host") String endpoint,
@QueryParam("peeringLocation") String peeringLocation,
@QueryParam("kind") LegacyPeeringsKind kind,
- @QueryParam("asn") Integer asn,
@PathParam("subscriptionId") String subscriptionId,
@QueryParam("api-version") String apiVersion,
@HeaderParam("Accept") String accept,
@@ -90,15 +89,13 @@ Mono> listNext(
*
* @param peeringLocation The location of the peering.
* @param kind The kind of the peering.
- * @param asn The ASN number associated with a legacy peering.
* @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 paginated list of peerings.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(
- String peeringLocation, LegacyPeeringsKind kind, Integer asn) {
+ private Mono> listSinglePageAsync(String peeringLocation, LegacyPeeringsKind kind) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -127,7 +124,6 @@ private Mono> listSinglePageAsync(
this.client.getEndpoint(),
peeringLocation,
kind,
- asn,
this.client.getSubscriptionId(),
this.client.getApiVersion(),
accept,
@@ -149,7 +145,6 @@ private Mono> listSinglePageAsync(
*
* @param peeringLocation The location of the peering.
* @param kind The kind of the peering.
- * @param asn The ASN number associated with a legacy peering.
* @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.
@@ -158,7 +153,7 @@ private Mono> listSinglePageAsync(
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> listSinglePageAsync(
- String peeringLocation, LegacyPeeringsKind kind, Integer asn, Context context) {
+ String peeringLocation, LegacyPeeringsKind kind, Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -185,7 +180,6 @@ private Mono> listSinglePageAsync(
this.client.getEndpoint(),
peeringLocation,
kind,
- asn,
this.client.getSubscriptionId(),
this.client.getApiVersion(),
accept,
@@ -201,23 +195,6 @@ private Mono> listSinglePageAsync(
null));
}
- /**
- * Lists all of the legacy peerings under the given subscription matching the specified kind and location.
- *
- * @param peeringLocation The location of the peering.
- * @param kind The kind of the peering.
- * @param asn The ASN number associated with a legacy peering.
- * @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 paginated list of peerings.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String peeringLocation, LegacyPeeringsKind kind, Integer asn) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(peeringLocation, kind, asn), nextLink -> listNextSinglePageAsync(nextLink));
- }
-
/**
* Lists all of the legacy peerings under the given subscription matching the specified kind and location.
*
@@ -230,9 +207,8 @@ private PagedFlux listAsync(String peeringLocation, LegacyPeerings
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
private PagedFlux listAsync(String peeringLocation, LegacyPeeringsKind kind) {
- final Integer asn = null;
return new PagedFlux<>(
- () -> listSinglePageAsync(peeringLocation, kind, asn), nextLink -> listNextSinglePageAsync(nextLink));
+ () -> listSinglePageAsync(peeringLocation, kind), nextLink -> listNextSinglePageAsync(nextLink));
}
/**
@@ -240,7 +216,6 @@ private PagedFlux listAsync(String peeringLocation, LegacyPeerings
*
* @param peeringLocation The location of the peering.
* @param kind The kind of the peering.
- * @param asn The ASN number associated with a legacy peering.
* @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.
@@ -248,10 +223,9 @@ private PagedFlux listAsync(String peeringLocation, LegacyPeerings
* @return the paginated list of peerings.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(
- String peeringLocation, LegacyPeeringsKind kind, Integer asn, Context context) {
+ private PagedFlux listAsync(String peeringLocation, LegacyPeeringsKind kind, Context context) {
return new PagedFlux<>(
- () -> listSinglePageAsync(peeringLocation, kind, asn, context),
+ () -> listSinglePageAsync(peeringLocation, kind, context),
nextLink -> listNextSinglePageAsync(nextLink, context));
}
@@ -267,8 +241,7 @@ private PagedFlux listAsync(
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
public PagedIterable list(String peeringLocation, LegacyPeeringsKind kind) {
- final Integer asn = null;
- return new PagedIterable<>(listAsync(peeringLocation, kind, asn));
+ return new PagedIterable<>(listAsync(peeringLocation, kind));
}
/**
@@ -276,7 +249,6 @@ public PagedIterable list(String peeringLocation, LegacyPeeringsKi
*
* @param peeringLocation The location of the peering.
* @param kind The kind of the peering.
- * @param asn The ASN number associated with a legacy peering.
* @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.
@@ -284,9 +256,8 @@ public PagedIterable list(String peeringLocation, LegacyPeeringsKi
* @return the paginated list of peerings.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(
- String peeringLocation, LegacyPeeringsKind kind, Integer asn, Context context) {
- return new PagedIterable<>(listAsync(peeringLocation, kind, asn, context));
+ public PagedIterable list(String peeringLocation, LegacyPeeringsKind kind, Context context) {
+ return new PagedIterable<>(listAsync(peeringLocation, kind, context));
}
/**
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsImpl.java
index 9633dbf063a9..7911f4419542 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/LegacyPeeringsImpl.java
@@ -32,8 +32,8 @@ public PagedIterable list(String peeringLocation, LegacyPeeringsKind ki
return Utils.mapPage(inner, inner1 -> new PeeringImpl(inner1, this.manager()));
}
- public PagedIterable list(String peeringLocation, LegacyPeeringsKind kind, Integer asn, Context context) {
- PagedIterable inner = this.serviceClient().list(peeringLocation, kind, asn, context);
+ public PagedIterable list(String peeringLocation, LegacyPeeringsKind kind, Context context) {
+ PagedIterable inner = this.serviceClient().list(peeringLocation, kind, context);
return Utils.mapPage(inner, inner1 -> new PeeringImpl(inner1, this.manager()));
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeerAsnImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeerAsnImpl.java
index 8c01d2524817..dadf641455a7 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeerAsnImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeerAsnImpl.java
@@ -6,11 +6,9 @@
import com.azure.core.util.Context;
import com.azure.resourcemanager.peering.fluent.models.PeerAsnInner;
-import com.azure.resourcemanager.peering.models.ContactDetail;
+import com.azure.resourcemanager.peering.models.ContactInfo;
import com.azure.resourcemanager.peering.models.PeerAsn;
import com.azure.resourcemanager.peering.models.ValidationState;
-import java.util.Collections;
-import java.util.List;
public final class PeerAsnImpl implements PeerAsn, PeerAsn.Definition, PeerAsn.Update {
private PeerAsnInner innerObject;
@@ -33,13 +31,8 @@ public Integer peerAsn() {
return this.innerModel().peerAsn();
}
- public List peerContactDetail() {
- List inner = this.innerModel().peerContactDetail();
- if (inner != null) {
- return Collections.unmodifiableList(inner);
- } else {
- return Collections.emptyList();
- }
+ public ContactInfo peerContactInfo() {
+ return this.innerModel().peerContactInfo();
}
public String peerName() {
@@ -50,10 +43,6 @@ public ValidationState validationState() {
return this.innerModel().validationState();
}
- public String errorMessage() {
- return this.innerModel().errorMessage();
- }
-
public PeerAsnInner innerModel() {
return this.innerObject;
}
@@ -137,8 +126,8 @@ public PeerAsnImpl withPeerAsn(Integer peerAsn) {
return this;
}
- public PeerAsnImpl withPeerContactDetail(List peerContactDetail) {
- this.innerModel().withPeerContactDetail(peerContactDetail);
+ public PeerAsnImpl withPeerContactInfo(ContactInfo peerContactInfo) {
+ this.innerModel().withPeerContactInfo(peerContactInfo);
return this;
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringManagementClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringManagementClientImpl.java
index 1f10890a52f1..e7b8b9e33be0 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringManagementClientImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringManagementClientImpl.java
@@ -21,21 +21,17 @@
import com.azure.core.util.polling.PollerFlux;
import com.azure.core.util.serializer.SerializerAdapter;
import com.azure.core.util.serializer.SerializerEncoding;
-import com.azure.resourcemanager.peering.fluent.CdnPeeringPrefixesClient;
import com.azure.resourcemanager.peering.fluent.LegacyPeeringsClient;
import com.azure.resourcemanager.peering.fluent.OperationsClient;
import com.azure.resourcemanager.peering.fluent.PeerAsnsClient;
import com.azure.resourcemanager.peering.fluent.PeeringLocationsClient;
import com.azure.resourcemanager.peering.fluent.PeeringManagementClient;
-import com.azure.resourcemanager.peering.fluent.PeeringServiceCountriesClient;
import com.azure.resourcemanager.peering.fluent.PeeringServiceLocationsClient;
+import com.azure.resourcemanager.peering.fluent.PeeringServicePrefixesClient;
import com.azure.resourcemanager.peering.fluent.PeeringServiceProvidersClient;
import com.azure.resourcemanager.peering.fluent.PeeringServicesClient;
import com.azure.resourcemanager.peering.fluent.PeeringsClient;
import com.azure.resourcemanager.peering.fluent.PrefixesClient;
-import com.azure.resourcemanager.peering.fluent.ReceivedRoutesClient;
-import com.azure.resourcemanager.peering.fluent.RegisteredAsnsClient;
-import com.azure.resourcemanager.peering.fluent.RegisteredPrefixesClient;
import com.azure.resourcemanager.peering.fluent.ResourceProvidersClient;
import java.io.IOException;
import java.lang.reflect.Type;
@@ -124,18 +120,6 @@ public Duration getDefaultPollInterval() {
return this.defaultPollInterval;
}
- /** The CdnPeeringPrefixesClient object to access its operations. */
- private final CdnPeeringPrefixesClient cdnPeeringPrefixes;
-
- /**
- * Gets the CdnPeeringPrefixesClient object to access its operations.
- *
- * @return the CdnPeeringPrefixesClient object.
- */
- public CdnPeeringPrefixesClient getCdnPeeringPrefixes() {
- return this.cdnPeeringPrefixes;
- }
-
/** The ResourceProvidersClient object to access its operations. */
private final ResourceProvidersClient resourceProviders;
@@ -196,30 +180,6 @@ public PeeringLocationsClient getPeeringLocations() {
return this.peeringLocations;
}
- /** The RegisteredAsnsClient object to access its operations. */
- private final RegisteredAsnsClient registeredAsns;
-
- /**
- * Gets the RegisteredAsnsClient object to access its operations.
- *
- * @return the RegisteredAsnsClient object.
- */
- public RegisteredAsnsClient getRegisteredAsns() {
- return this.registeredAsns;
- }
-
- /** The RegisteredPrefixesClient object to access its operations. */
- private final RegisteredPrefixesClient registeredPrefixes;
-
- /**
- * Gets the RegisteredPrefixesClient object to access its operations.
- *
- * @return the RegisteredPrefixesClient object.
- */
- public RegisteredPrefixesClient getRegisteredPrefixes() {
- return this.registeredPrefixes;
- }
-
/** The PeeringsClient object to access its operations. */
private final PeeringsClient peerings;
@@ -232,30 +192,6 @@ public PeeringsClient getPeerings() {
return this.peerings;
}
- /** The ReceivedRoutesClient object to access its operations. */
- private final ReceivedRoutesClient receivedRoutes;
-
- /**
- * Gets the ReceivedRoutesClient object to access its operations.
- *
- * @return the ReceivedRoutesClient object.
- */
- public ReceivedRoutesClient getReceivedRoutes() {
- return this.receivedRoutes;
- }
-
- /** The PeeringServiceCountriesClient object to access its operations. */
- private final PeeringServiceCountriesClient peeringServiceCountries;
-
- /**
- * Gets the PeeringServiceCountriesClient object to access its operations.
- *
- * @return the PeeringServiceCountriesClient object.
- */
- public PeeringServiceCountriesClient getPeeringServiceCountries() {
- return this.peeringServiceCountries;
- }
-
/** The PeeringServiceLocationsClient object to access its operations. */
private final PeeringServiceLocationsClient peeringServiceLocations;
@@ -268,6 +204,18 @@ public PeeringServiceLocationsClient getPeeringServiceLocations() {
return this.peeringServiceLocations;
}
+ /** The PeeringServicePrefixesClient object to access its operations. */
+ private final PeeringServicePrefixesClient peeringServicePrefixes;
+
+ /**
+ * Gets the PeeringServicePrefixesClient object to access its operations.
+ *
+ * @return the PeeringServicePrefixesClient object.
+ */
+ public PeeringServicePrefixesClient getPeeringServicePrefixes() {
+ return this.peeringServicePrefixes;
+ }
+
/** The PrefixesClient object to access its operations. */
private final PrefixesClient prefixes;
@@ -326,19 +274,15 @@ public PeeringServicesClient getPeeringServices() {
this.defaultPollInterval = defaultPollInterval;
this.subscriptionId = subscriptionId;
this.endpoint = endpoint;
- this.apiVersion = "2021-01-01";
- this.cdnPeeringPrefixes = new CdnPeeringPrefixesClientImpl(this);
+ this.apiVersion = "2019-08-01-preview";
this.resourceProviders = new ResourceProvidersClientImpl(this);
this.legacyPeerings = new LegacyPeeringsClientImpl(this);
this.operations = new OperationsClientImpl(this);
this.peerAsns = new PeerAsnsClientImpl(this);
this.peeringLocations = new PeeringLocationsClientImpl(this);
- this.registeredAsns = new RegisteredAsnsClientImpl(this);
- this.registeredPrefixes = new RegisteredPrefixesClientImpl(this);
this.peerings = new PeeringsClientImpl(this);
- this.receivedRoutes = new ReceivedRoutesClientImpl(this);
- this.peeringServiceCountries = new PeeringServiceCountriesClientImpl(this);
this.peeringServiceLocations = new PeeringServiceLocationsClientImpl(this);
+ this.peeringServicePrefixes = new PeeringServicePrefixesClientImpl(this);
this.prefixes = new PrefixesClientImpl(this);
this.peeringServiceProviders = new PeeringServiceProvidersClientImpl(this);
this.peeringServices = new PeeringServicesClientImpl(this);
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringReceivedRouteImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringReceivedRouteImpl.java
deleted file mode 100644
index 2efef6b118d5..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringReceivedRouteImpl.java
+++ /dev/null
@@ -1,56 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.resourcemanager.peering.fluent.models.PeeringReceivedRouteInner;
-import com.azure.resourcemanager.peering.models.PeeringReceivedRoute;
-
-public final class PeeringReceivedRouteImpl implements PeeringReceivedRoute {
- private PeeringReceivedRouteInner innerObject;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- PeeringReceivedRouteImpl(
- PeeringReceivedRouteInner innerObject, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- }
-
- public String prefix() {
- return this.innerModel().prefix();
- }
-
- public String nextHop() {
- return this.innerModel().nextHop();
- }
-
- public String asPath() {
- return this.innerModel().asPath();
- }
-
- public String originAsValidationState() {
- return this.innerModel().originAsValidationState();
- }
-
- public String rpkiValidationState() {
- return this.innerModel().rpkiValidationState();
- }
-
- public String trustAnchor() {
- return this.innerModel().trustAnchor();
- }
-
- public String receivedTimestamp() {
- return this.innerModel().receivedTimestamp();
- }
-
- public PeeringReceivedRouteInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringRegisteredAsnImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringRegisteredAsnImpl.java
deleted file mode 100644
index dd30bedb8aeb..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringRegisteredAsnImpl.java
+++ /dev/null
@@ -1,149 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.peering.fluent.models.PeeringRegisteredAsnInner;
-import com.azure.resourcemanager.peering.models.PeeringRegisteredAsn;
-import com.azure.resourcemanager.peering.models.ProvisioningState;
-
-public final class PeeringRegisteredAsnImpl
- implements PeeringRegisteredAsn, PeeringRegisteredAsn.Definition, PeeringRegisteredAsn.Update {
- private PeeringRegisteredAsnInner innerObject;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- public String id() {
- return this.innerModel().id();
- }
-
- public String name() {
- return this.innerModel().name();
- }
-
- public String type() {
- return this.innerModel().type();
- }
-
- public Integer asn() {
- return this.innerModel().asn();
- }
-
- public String peeringServicePrefixKey() {
- return this.innerModel().peeringServicePrefixKey();
- }
-
- public ProvisioningState provisioningState() {
- return this.innerModel().provisioningState();
- }
-
- public PeeringRegisteredAsnInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-
- private String resourceGroupName;
-
- private String peeringName;
-
- private String registeredAsnName;
-
- public PeeringRegisteredAsnImpl withExistingPeering(String resourceGroupName, String peeringName) {
- this.resourceGroupName = resourceGroupName;
- this.peeringName = peeringName;
- return this;
- }
-
- public PeeringRegisteredAsn create() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredAsns()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredAsnName, this.innerModel(), Context.NONE)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredAsn create(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredAsns()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredAsnName, this.innerModel(), context)
- .getValue();
- return this;
- }
-
- PeeringRegisteredAsnImpl(String name, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerObject = new PeeringRegisteredAsnInner();
- this.serviceManager = serviceManager;
- this.registeredAsnName = name;
- }
-
- public PeeringRegisteredAsnImpl update() {
- return this;
- }
-
- public PeeringRegisteredAsn apply() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredAsns()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredAsnName, this.innerModel(), Context.NONE)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredAsn apply(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredAsns()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredAsnName, this.innerModel(), context)
- .getValue();
- return this;
- }
-
- PeeringRegisteredAsnImpl(
- PeeringRegisteredAsnInner innerObject, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.peeringName = Utils.getValueFromIdByName(innerObject.id(), "peerings");
- this.registeredAsnName = Utils.getValueFromIdByName(innerObject.id(), "registeredAsns");
- }
-
- public PeeringRegisteredAsn refresh() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredAsns()
- .getWithResponse(resourceGroupName, peeringName, registeredAsnName, Context.NONE)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredAsn refresh(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredAsns()
- .getWithResponse(resourceGroupName, peeringName, registeredAsnName, context)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredAsnImpl withAsn(Integer asn) {
- this.innerModel().withAsn(asn);
- return this;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringRegisteredPrefixImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringRegisteredPrefixImpl.java
deleted file mode 100644
index 2c35c1ac2b34..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringRegisteredPrefixImpl.java
+++ /dev/null
@@ -1,158 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.peering.fluent.models.PeeringRegisteredPrefixInner;
-import com.azure.resourcemanager.peering.models.PeeringRegisteredPrefix;
-import com.azure.resourcemanager.peering.models.PrefixValidationState;
-import com.azure.resourcemanager.peering.models.ProvisioningState;
-
-public final class PeeringRegisteredPrefixImpl
- implements PeeringRegisteredPrefix, PeeringRegisteredPrefix.Definition, PeeringRegisteredPrefix.Update {
- private PeeringRegisteredPrefixInner innerObject;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- public String id() {
- return this.innerModel().id();
- }
-
- public String name() {
- return this.innerModel().name();
- }
-
- public String type() {
- return this.innerModel().type();
- }
-
- public String prefix() {
- return this.innerModel().prefix();
- }
-
- public PrefixValidationState prefixValidationState() {
- return this.innerModel().prefixValidationState();
- }
-
- public String peeringServicePrefixKey() {
- return this.innerModel().peeringServicePrefixKey();
- }
-
- public String errorMessage() {
- return this.innerModel().errorMessage();
- }
-
- public ProvisioningState provisioningState() {
- return this.innerModel().provisioningState();
- }
-
- public PeeringRegisteredPrefixInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-
- private String resourceGroupName;
-
- private String peeringName;
-
- private String registeredPrefixName;
-
- public PeeringRegisteredPrefixImpl withExistingPeering(String resourceGroupName, String peeringName) {
- this.resourceGroupName = resourceGroupName;
- this.peeringName = peeringName;
- return this;
- }
-
- public PeeringRegisteredPrefix create() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredPrefixes()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredPrefixName, this.innerModel(), Context.NONE)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredPrefix create(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredPrefixes()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredPrefixName, this.innerModel(), context)
- .getValue();
- return this;
- }
-
- PeeringRegisteredPrefixImpl(String name, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerObject = new PeeringRegisteredPrefixInner();
- this.serviceManager = serviceManager;
- this.registeredPrefixName = name;
- }
-
- public PeeringRegisteredPrefixImpl update() {
- return this;
- }
-
- public PeeringRegisteredPrefix apply() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredPrefixes()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredPrefixName, this.innerModel(), Context.NONE)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredPrefix apply(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredPrefixes()
- .createOrUpdateWithResponse(
- resourceGroupName, peeringName, registeredPrefixName, this.innerModel(), context)
- .getValue();
- return this;
- }
-
- PeeringRegisteredPrefixImpl(
- PeeringRegisteredPrefixInner innerObject, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.peeringName = Utils.getValueFromIdByName(innerObject.id(), "peerings");
- this.registeredPrefixName = Utils.getValueFromIdByName(innerObject.id(), "registeredPrefixes");
- }
-
- public PeeringRegisteredPrefix refresh() {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredPrefixes()
- .getWithResponse(resourceGroupName, peeringName, registeredPrefixName, Context.NONE)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredPrefix refresh(Context context) {
- this.innerObject =
- serviceManager
- .serviceClient()
- .getRegisteredPrefixes()
- .getWithResponse(resourceGroupName, peeringName, registeredPrefixName, context)
- .getValue();
- return this;
- }
-
- public PeeringRegisteredPrefixImpl withPrefix(String prefix) {
- this.innerModel().withPrefix(prefix);
- return this;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountriesClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountriesClientImpl.java
deleted file mode 100644
index f608089da9e3..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountriesClientImpl.java
+++ /dev/null
@@ -1,295 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.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.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.peering.fluent.PeeringServiceCountriesClient;
-import com.azure.resourcemanager.peering.fluent.models.PeeringServiceCountryInner;
-import com.azure.resourcemanager.peering.models.PeeringServiceCountryListResult;
-import reactor.core.publisher.Mono;
-
-/** An instance of this class provides access to all the operations defined in PeeringServiceCountriesClient. */
-public final class PeeringServiceCountriesClientImpl implements PeeringServiceCountriesClient {
- private final ClientLogger logger = new ClientLogger(PeeringServiceCountriesClientImpl.class);
-
- /** The proxy service used to perform REST calls. */
- private final PeeringServiceCountriesService service;
-
- /** The service client containing this operation class. */
- private final PeeringManagementClientImpl client;
-
- /**
- * Initializes an instance of PeeringServiceCountriesClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- PeeringServiceCountriesClientImpl(PeeringManagementClientImpl client) {
- this.service =
- RestProxy
- .create(PeeringServiceCountriesService.class, client.getHttpPipeline(), client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for PeeringManagementClientPeeringServiceCountries to be used by the
- * proxy service to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "PeeringManagementCli")
- private interface PeeringServiceCountriesService {
- @Headers({"Content-Type: application/json"})
- @Get("/subscriptions/{subscriptionId}/providers/Microsoft.Peering/peeringServiceCountries")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(
- @HostParam("$host") String endpoint,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @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);
- }
-
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @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.getSubscriptionId(),
- this.client.getApiVersion(),
- 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()));
- }
-
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(
- this.client.getEndpoint(),
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
- }
-
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync() {
- return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(Context context) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(context), nextLink -> listNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list() {
- return new PagedIterable<>(listAsync());
- }
-
- /**
- * Lists all of the available countries for peering service.
- *
- * @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 paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(Context context) {
- return new PagedIterable<>(listAsync(context));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The nextLink parameter.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the paginated list of peering service countries.
- */
- @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 nextLink parameter.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the paginated list of peering service countries.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink, Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .listNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountriesImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountriesImpl.java
deleted file mode 100644
index 1ee72e2e2bae..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountriesImpl.java
+++ /dev/null
@@ -1,46 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.util.Context;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.fluent.PeeringServiceCountriesClient;
-import com.azure.resourcemanager.peering.fluent.models.PeeringServiceCountryInner;
-import com.azure.resourcemanager.peering.models.PeeringServiceCountries;
-import com.azure.resourcemanager.peering.models.PeeringServiceCountry;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-
-public final class PeeringServiceCountriesImpl implements PeeringServiceCountries {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringServiceCountriesImpl.class);
-
- private final PeeringServiceCountriesClient innerClient;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- public PeeringServiceCountriesImpl(
- PeeringServiceCountriesClient innerClient, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerClient = innerClient;
- this.serviceManager = serviceManager;
- }
-
- public PagedIterable list() {
- PagedIterable inner = this.serviceClient().list();
- return Utils.mapPage(inner, inner1 -> new PeeringServiceCountryImpl(inner1, this.manager()));
- }
-
- public PagedIterable list(Context context) {
- PagedIterable inner = this.serviceClient().list(context);
- return Utils.mapPage(inner, inner1 -> new PeeringServiceCountryImpl(inner1, this.manager()));
- }
-
- private PeeringServiceCountriesClient serviceClient() {
- return this.innerClient;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountryImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountryImpl.java
deleted file mode 100644
index c7e0fda49b47..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceCountryImpl.java
+++ /dev/null
@@ -1,40 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.resourcemanager.peering.fluent.models.PeeringServiceCountryInner;
-import com.azure.resourcemanager.peering.models.PeeringServiceCountry;
-
-public final class PeeringServiceCountryImpl implements PeeringServiceCountry {
- private PeeringServiceCountryInner innerObject;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- PeeringServiceCountryImpl(
- PeeringServiceCountryInner innerObject, com.azure.resourcemanager.peering.PeeringManager 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 PeeringServiceCountryInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceImpl.java
index 1aa0c5de92de..b5eb5d342e56 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceImpl.java
@@ -8,7 +8,6 @@
import com.azure.core.util.Context;
import com.azure.resourcemanager.peering.fluent.models.PeeringServiceInner;
import com.azure.resourcemanager.peering.models.PeeringService;
-import com.azure.resourcemanager.peering.models.PeeringServiceSku;
import com.azure.resourcemanager.peering.models.ProvisioningState;
import com.azure.resourcemanager.peering.models.ResourceTags;
import java.util.Collections;
@@ -31,10 +30,6 @@ public String type() {
return this.innerModel().type();
}
- public PeeringServiceSku sku() {
- return this.innerModel().sku();
- }
-
public String location() {
return this.innerModel().location();
}
@@ -60,14 +55,6 @@ public ProvisioningState provisioningState() {
return this.innerModel().provisioningState();
}
- public String providerPrimaryPeeringLocation() {
- return this.innerModel().providerPrimaryPeeringLocation();
- }
-
- public String providerBackupPeeringLocation() {
- return this.innerModel().providerBackupPeeringLocation();
- }
-
public Region region() {
return Region.fromName(this.regionName());
}
@@ -194,11 +181,6 @@ public PeeringServiceImpl withTags(Map tags) {
}
}
- public PeeringServiceImpl withSku(PeeringServiceSku sku) {
- this.innerModel().withSku(sku);
- return this;
- }
-
public PeeringServiceImpl withPeeringServiceLocation(String peeringServiceLocation) {
this.innerModel().withPeeringServiceLocation(peeringServiceLocation);
return this;
@@ -209,16 +191,6 @@ public PeeringServiceImpl withPeeringServiceProvider(String peeringServiceProvid
return this;
}
- public PeeringServiceImpl withProviderPrimaryPeeringLocation(String providerPrimaryPeeringLocation) {
- this.innerModel().withProviderPrimaryPeeringLocation(providerPrimaryPeeringLocation);
- return this;
- }
-
- public PeeringServiceImpl withProviderBackupPeeringLocation(String providerBackupPeeringLocation) {
- this.innerModel().withProviderBackupPeeringLocation(providerBackupPeeringLocation);
- return this;
- }
-
private boolean isInCreateMode() {
return this.innerModel().id() == null;
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsClientImpl.java
index 1d7d178816c1..61e1d3aa00e8 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsClientImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsClientImpl.java
@@ -66,7 +66,6 @@ private interface PeeringServiceLocationsService {
@UnexpectedResponseExceptionType(ManagementException.class)
Mono> list(
@HostParam("$host") String endpoint,
- @QueryParam("country") String country,
@PathParam("subscriptionId") String subscriptionId,
@QueryParam("api-version") String apiVersion,
@HeaderParam("Accept") String accept,
@@ -84,16 +83,14 @@ Mono> listNext(
}
/**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
- * @param country The country of interest, in which the locations are to be present.
- * @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 paginated list of peering service locations.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String country) {
+ private Mono> listSinglePageAsync() {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -113,7 +110,6 @@ private Mono> listSinglePageAsync(Str
service
.list(
this.client.getEndpoint(),
- country,
this.client.getSubscriptionId(),
this.client.getApiVersion(),
accept,
@@ -131,9 +127,8 @@ private Mono> listSinglePageAsync(Str
}
/**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
- * @param country The country of interest, in which the locations are to be present.
* @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.
@@ -141,7 +136,7 @@ private Mono> listSinglePageAsync(Str
* @return the paginated list of peering service locations.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String country, Context context) {
+ private Mono> listSinglePageAsync(Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -159,7 +154,6 @@ private Mono> listSinglePageAsync(Str
return service
.list(
this.client.getEndpoint(),
- country,
this.client.getSubscriptionId(),
this.client.getApiVersion(),
accept,
@@ -176,21 +170,7 @@ private Mono> listSinglePageAsync(Str
}
/**
- * Lists all of the available locations for peering service.
- *
- * @param country The country of interest, in which the locations are to be present.
- * @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 paginated list of peering service locations.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String country) {
- return new PagedFlux<>(() -> listSinglePageAsync(country), nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
@@ -198,14 +178,12 @@ private PagedFlux listAsync(String country) {
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
private PagedFlux listAsync() {
- final String country = null;
- return new PagedFlux<>(() -> listSinglePageAsync(country), nextLink -> listNextSinglePageAsync(nextLink));
+ return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listNextSinglePageAsync(nextLink));
}
/**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
- * @param country The country of interest, in which the locations are to be present.
* @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.
@@ -213,13 +191,13 @@ private PagedFlux listAsync() {
* @return the paginated list of peering service locations.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String country, Context context) {
+ private PagedFlux listAsync(Context context) {
return new PagedFlux<>(
- () -> listSinglePageAsync(country, context), nextLink -> listNextSinglePageAsync(nextLink, context));
+ () -> listSinglePageAsync(context), nextLink -> listNextSinglePageAsync(nextLink, context));
}
/**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
@@ -227,14 +205,12 @@ private PagedFlux listAsync(String country, Context
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
public PagedIterable list() {
- final String country = null;
- return new PagedIterable<>(listAsync(country));
+ return new PagedIterable<>(listAsync());
}
/**
- * Lists all of the available locations for peering service.
+ * Lists all of the available peering service locations for the specified kind of peering.
*
- * @param country The country of interest, in which the locations are to be present.
* @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.
@@ -242,8 +218,8 @@ public PagedIterable list() {
* @return the paginated list of peering service locations.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String country, Context context) {
- return new PagedIterable<>(listAsync(country, context));
+ public PagedIterable list(Context context) {
+ return new PagedIterable<>(listAsync(context));
}
/**
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsImpl.java
index 810cb5a2713e..4156a11b36e0 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceLocationsImpl.java
@@ -31,8 +31,8 @@ public PagedIterable list() {
return Utils.mapPage(inner, inner1 -> new PeeringServiceLocationImpl(inner1, this.manager()));
}
- public PagedIterable list(String country, Context context) {
- PagedIterable inner = this.serviceClient().list(country, context);
+ public PagedIterable list(Context context) {
+ PagedIterable inner = this.serviceClient().list(context);
return Utils.mapPage(inner, inner1 -> new PeeringServiceLocationImpl(inner1, this.manager()));
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixImpl.java
index a5ad8dc4665e..3cd6540144c6 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixImpl.java
@@ -8,11 +8,8 @@
import com.azure.resourcemanager.peering.fluent.models.PeeringServicePrefixInner;
import com.azure.resourcemanager.peering.models.LearnedType;
import com.azure.resourcemanager.peering.models.PeeringServicePrefix;
-import com.azure.resourcemanager.peering.models.PeeringServicePrefixEvent;
import com.azure.resourcemanager.peering.models.PrefixValidationState;
import com.azure.resourcemanager.peering.models.ProvisioningState;
-import java.util.Collections;
-import java.util.List;
public final class PeeringServicePrefixImpl
implements PeeringServicePrefix, PeeringServicePrefix.Definition, PeeringServicePrefix.Update {
@@ -44,23 +41,6 @@ public LearnedType learnedType() {
return this.innerModel().learnedType();
}
- public String errorMessage() {
- return this.innerModel().errorMessage();
- }
-
- public List events() {
- List inner = this.innerModel().events();
- if (inner != null) {
- return Collections.unmodifiableList(inner);
- } else {
- return Collections.emptyList();
- }
- }
-
- public String peeringServicePrefixKey() {
- return this.innerModel().peeringServicePrefixKey();
- }
-
public ProvisioningState provisioningState() {
return this.innerModel().provisioningState();
}
@@ -89,7 +69,7 @@ public PeeringServicePrefix create() {
this.innerObject =
serviceManager
.serviceClient()
- .getPrefixes()
+ .getPeeringServicePrefixes()
.createOrUpdateWithResponse(
resourceGroupName, peeringServiceName, prefixName, this.innerModel(), Context.NONE)
.getValue();
@@ -100,7 +80,7 @@ public PeeringServicePrefix create(Context context) {
this.innerObject =
serviceManager
.serviceClient()
- .getPrefixes()
+ .getPeeringServicePrefixes()
.createOrUpdateWithResponse(
resourceGroupName, peeringServiceName, prefixName, this.innerModel(), context)
.getValue();
@@ -121,7 +101,7 @@ public PeeringServicePrefix apply() {
this.innerObject =
serviceManager
.serviceClient()
- .getPrefixes()
+ .getPeeringServicePrefixes()
.createOrUpdateWithResponse(
resourceGroupName, peeringServiceName, prefixName, this.innerModel(), Context.NONE)
.getValue();
@@ -132,7 +112,7 @@ public PeeringServicePrefix apply(Context context) {
this.innerObject =
serviceManager
.serviceClient()
- .getPrefixes()
+ .getPeeringServicePrefixes()
.createOrUpdateWithResponse(
resourceGroupName, peeringServiceName, prefixName, this.innerModel(), context)
.getValue();
@@ -149,23 +129,21 @@ public PeeringServicePrefix apply(Context context) {
}
public PeeringServicePrefix refresh() {
- String localExpand = null;
this.innerObject =
serviceManager
.serviceClient()
- .getPrefixes()
- .getWithResponse(resourceGroupName, peeringServiceName, prefixName, localExpand, Context.NONE)
+ .getPeeringServicePrefixes()
+ .getWithResponse(resourceGroupName, peeringServiceName, prefixName, Context.NONE)
.getValue();
return this;
}
public PeeringServicePrefix refresh(Context context) {
- String localExpand = null;
this.innerObject =
serviceManager
.serviceClient()
- .getPrefixes()
- .getWithResponse(resourceGroupName, peeringServiceName, prefixName, localExpand, context)
+ .getPeeringServicePrefixes()
+ .getWithResponse(resourceGroupName, peeringServiceName, prefixName, context)
.getValue();
return this;
}
@@ -175,8 +153,13 @@ public PeeringServicePrefixImpl withPrefix(String prefix) {
return this;
}
- public PeeringServicePrefixImpl withPeeringServicePrefixKey(String peeringServicePrefixKey) {
- this.innerModel().withPeeringServicePrefixKey(peeringServicePrefixKey);
+ public PeeringServicePrefixImpl withPrefixValidationState(PrefixValidationState prefixValidationState) {
+ this.innerModel().withPrefixValidationState(prefixValidationState);
+ return this;
+ }
+
+ public PeeringServicePrefixImpl withLearnedType(LearnedType learnedType) {
+ this.innerModel().withLearnedType(learnedType);
return this;
}
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixesClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixesClientImpl.java
new file mode 100644
index 000000000000..f20e802151a9
--- /dev/null
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixesClientImpl.java
@@ -0,0 +1,635 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.peering.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.util.Context;
+import com.azure.core.util.FluxUtil;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.peering.fluent.PeeringServicePrefixesClient;
+import com.azure.resourcemanager.peering.fluent.models.PeeringServicePrefixInner;
+import reactor.core.publisher.Mono;
+
+/** An instance of this class provides access to all the operations defined in PeeringServicePrefixesClient. */
+public final class PeeringServicePrefixesClientImpl implements PeeringServicePrefixesClient {
+ private final ClientLogger logger = new ClientLogger(PeeringServicePrefixesClientImpl.class);
+
+ /** The proxy service used to perform REST calls. */
+ private final PeeringServicePrefixesService service;
+
+ /** The service client containing this operation class. */
+ private final PeeringManagementClientImpl client;
+
+ /**
+ * Initializes an instance of PeeringServicePrefixesClientImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ PeeringServicePrefixesClientImpl(PeeringManagementClientImpl client) {
+ this.service =
+ RestProxy
+ .create(PeeringServicePrefixesService.class, client.getHttpPipeline(), client.getSerializerAdapter());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for PeeringManagementClientPeeringServicePrefixes to be used by the proxy
+ * service to perform REST calls.
+ */
+ @Host("{$host}")
+ @ServiceInterface(name = "PeeringManagementCli")
+ private interface PeeringServicePrefixesService {
+ @Headers({"Content-Type: application/json"})
+ @Get(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering"
+ + "/peeringServices/{peeringServiceName}/prefixes/{prefixName}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> get(
+ @HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("peeringServiceName") String peeringServiceName,
+ @PathParam("prefixName") String prefixName,
+ @PathParam("subscriptionId") String subscriptionId,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Put(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering"
+ + "/peeringServices/{peeringServiceName}/prefixes/{prefixName}")
+ @ExpectedResponses({200, 201})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> createOrUpdate(
+ @HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("peeringServiceName") String peeringServiceName,
+ @PathParam("prefixName") String prefixName,
+ @PathParam("subscriptionId") String subscriptionId,
+ @QueryParam("api-version") String apiVersion,
+ @BodyParam("application/json") PeeringServicePrefixInner peeringServicePrefix,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Delete(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering"
+ + "/peeringServices/{peeringServiceName}/prefixes/{prefixName}")
+ @ExpectedResponses({200, 204})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> delete(
+ @HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("peeringServiceName") String peeringServiceName,
+ @PathParam("prefixName") String prefixName,
+ @PathParam("subscriptionId") String subscriptionId,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+ }
+
+ /**
+ * Gets the peering service prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peering service prefix.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(
+ String resourceGroupName, String peeringServiceName, String prefixName) {
+ 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 (peeringServiceName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
+ }
+ if (prefixName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter prefixName 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
+ .get(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ peeringServiceName,
+ prefixName,
+ this.client.getSubscriptionId(),
+ this.client.getApiVersion(),
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Gets the peering service prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peering service prefix.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
+ 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 (peeringServiceName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
+ }
+ if (prefixName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter prefixName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .get(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ peeringServiceName,
+ prefixName,
+ this.client.getSubscriptionId(),
+ this.client.getApiVersion(),
+ accept,
+ context);
+ }
+
+ /**
+ * Gets the peering service prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peering service prefix.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getAsync(
+ String resourceGroupName, String peeringServiceName, String prefixName) {
+ return getWithResponseAsync(resourceGroupName, peeringServiceName, prefixName)
+ .flatMap(
+ (Response res) -> {
+ if (res.getValue() != null) {
+ return Mono.just(res.getValue());
+ } else {
+ return Mono.empty();
+ }
+ });
+ }
+
+ /**
+ * Gets the peering service prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peering service prefix.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PeeringServicePrefixInner get(String resourceGroupName, String peeringServiceName, String prefixName) {
+ return getAsync(resourceGroupName, peeringServiceName, prefixName).block();
+ }
+
+ /**
+ * Gets the peering service prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peering service prefix.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getWithResponse(
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
+ return getWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, context).block();
+ }
+
+ /**
+ * Creates or updates the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param peeringServicePrefix The IP prefix for an peering.
+ * @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 peering service prefix class.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> createOrUpdateWithResponseAsync(
+ String resourceGroupName,
+ String peeringServiceName,
+ String prefixName,
+ PeeringServicePrefixInner peeringServicePrefix) {
+ 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 (peeringServiceName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
+ }
+ if (prefixName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter prefixName 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 (peeringServicePrefix == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServicePrefix is required and cannot be null."));
+ } else {
+ peeringServicePrefix.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .createOrUpdate(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ peeringServiceName,
+ prefixName,
+ this.client.getSubscriptionId(),
+ this.client.getApiVersion(),
+ peeringServicePrefix,
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Creates or updates the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param peeringServicePrefix The IP prefix for an peering.
+ * @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 peering service prefix class.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> createOrUpdateWithResponseAsync(
+ String resourceGroupName,
+ String peeringServiceName,
+ String prefixName,
+ PeeringServicePrefixInner peeringServicePrefix,
+ Context context) {
+ 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 (peeringServiceName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
+ }
+ if (prefixName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter prefixName 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 (peeringServicePrefix == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServicePrefix is required and cannot be null."));
+ } else {
+ peeringServicePrefix.validate();
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .createOrUpdate(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ peeringServiceName,
+ prefixName,
+ this.client.getSubscriptionId(),
+ this.client.getApiVersion(),
+ peeringServicePrefix,
+ accept,
+ context);
+ }
+
+ /**
+ * Creates or updates the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param peeringServicePrefix The IP prefix for an peering.
+ * @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 peering service prefix class.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createOrUpdateAsync(
+ String resourceGroupName,
+ String peeringServiceName,
+ String prefixName,
+ PeeringServicePrefixInner peeringServicePrefix) {
+ return createOrUpdateWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, peeringServicePrefix)
+ .flatMap(
+ (Response res) -> {
+ if (res.getValue() != null) {
+ return Mono.just(res.getValue());
+ } else {
+ return Mono.empty();
+ }
+ });
+ }
+
+ /**
+ * Creates or updates the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param peeringServicePrefix The IP prefix for an peering.
+ * @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 peering service prefix class.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public PeeringServicePrefixInner createOrUpdate(
+ String resourceGroupName,
+ String peeringServiceName,
+ String prefixName,
+ PeeringServicePrefixInner peeringServicePrefix) {
+ return createOrUpdateAsync(resourceGroupName, peeringServiceName, prefixName, peeringServicePrefix).block();
+ }
+
+ /**
+ * Creates or updates the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param peeringServicePrefix The IP prefix for an peering.
+ * @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 peering service prefix class.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response createOrUpdateWithResponse(
+ String resourceGroupName,
+ String peeringServiceName,
+ String prefixName,
+ PeeringServicePrefixInner peeringServicePrefix,
+ Context context) {
+ return createOrUpdateWithResponseAsync(
+ resourceGroupName, peeringServiceName, prefixName, peeringServicePrefix, context)
+ .block();
+ }
+
+ /**
+ * removes the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> deleteWithResponseAsync(
+ String resourceGroupName, String peeringServiceName, String prefixName) {
+ 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 (peeringServiceName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
+ }
+ if (prefixName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter prefixName 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
+ .delete(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ peeringServiceName,
+ prefixName,
+ this.client.getSubscriptionId(),
+ this.client.getApiVersion(),
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * removes the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> deleteWithResponseAsync(
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
+ 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 (peeringServiceName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
+ }
+ if (prefixName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter prefixName is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .delete(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ peeringServiceName,
+ prefixName,
+ this.client.getSubscriptionId(),
+ this.client.getApiVersion(),
+ accept,
+ context);
+ }
+
+ /**
+ * removes the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono deleteAsync(String resourceGroupName, String peeringServiceName, String prefixName) {
+ return deleteWithResponseAsync(resourceGroupName, peeringServiceName, prefixName)
+ .flatMap((Response res) -> Mono.empty());
+ }
+
+ /**
+ * removes the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @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 peeringServiceName, String prefixName) {
+ deleteAsync(resourceGroupName, peeringServiceName, prefixName).block();
+ }
+
+ /**
+ * removes the peering prefix.
+ *
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
+ * @param prefixName The prefix name.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return the response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response deleteWithResponse(
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
+ return deleteWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, context).block();
+ }
+}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/RegisteredAsnsImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixesImpl.java
similarity index 52%
rename from sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/RegisteredAsnsImpl.java
rename to sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixesImpl.java
index bc2139090745..1d759b0acf33 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/RegisteredAsnsImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServicePrefixesImpl.java
@@ -4,77 +4,63 @@
package com.azure.resourcemanager.peering.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.peering.fluent.RegisteredAsnsClient;
-import com.azure.resourcemanager.peering.fluent.models.PeeringRegisteredAsnInner;
-import com.azure.resourcemanager.peering.models.PeeringRegisteredAsn;
-import com.azure.resourcemanager.peering.models.RegisteredAsns;
+import com.azure.resourcemanager.peering.fluent.PeeringServicePrefixesClient;
+import com.azure.resourcemanager.peering.fluent.models.PeeringServicePrefixInner;
+import com.azure.resourcemanager.peering.models.PeeringServicePrefix;
+import com.azure.resourcemanager.peering.models.PeeringServicePrefixes;
import com.fasterxml.jackson.annotation.JsonIgnore;
-public final class RegisteredAsnsImpl implements RegisteredAsns {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(RegisteredAsnsImpl.class);
+public final class PeeringServicePrefixesImpl implements PeeringServicePrefixes {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(PeeringServicePrefixesImpl.class);
- private final RegisteredAsnsClient innerClient;
+ private final PeeringServicePrefixesClient innerClient;
private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
- public RegisteredAsnsImpl(
- RegisteredAsnsClient innerClient, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
+ public PeeringServicePrefixesImpl(
+ PeeringServicePrefixesClient innerClient, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
this.innerClient = innerClient;
this.serviceManager = serviceManager;
}
- public PeeringRegisteredAsn get(String resourceGroupName, String peeringName, String registeredAsnName) {
- PeeringRegisteredAsnInner inner = this.serviceClient().get(resourceGroupName, peeringName, registeredAsnName);
+ public PeeringServicePrefix get(String resourceGroupName, String peeringServiceName, String prefixName) {
+ PeeringServicePrefixInner inner = this.serviceClient().get(resourceGroupName, peeringServiceName, prefixName);
if (inner != null) {
- return new PeeringRegisteredAsnImpl(inner, this.manager());
+ return new PeeringServicePrefixImpl(inner, this.manager());
} else {
return null;
}
}
- public Response getWithResponse(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context) {
- Response inner =
- this.serviceClient().getWithResponse(resourceGroupName, peeringName, registeredAsnName, context);
+ public Response getWithResponse(
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
+ Response inner =
+ this.serviceClient().getWithResponse(resourceGroupName, peeringServiceName, prefixName, context);
if (inner != null) {
return new SimpleResponse<>(
inner.getRequest(),
inner.getStatusCode(),
inner.getHeaders(),
- new PeeringRegisteredAsnImpl(inner.getValue(), this.manager()));
+ new PeeringServicePrefixImpl(inner.getValue(), this.manager()));
} else {
return null;
}
}
- public void delete(String resourceGroupName, String peeringName, String registeredAsnName) {
- this.serviceClient().delete(resourceGroupName, peeringName, registeredAsnName);
+ public void delete(String resourceGroupName, String peeringServiceName, String prefixName) {
+ this.serviceClient().delete(resourceGroupName, peeringServiceName, prefixName);
}
public Response deleteWithResponse(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context) {
- return this.serviceClient().deleteWithResponse(resourceGroupName, peeringName, registeredAsnName, context);
+ String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
+ return this.serviceClient().deleteWithResponse(resourceGroupName, peeringServiceName, prefixName, context);
}
- public PagedIterable listByPeering(String resourceGroupName, String peeringName) {
- PagedIterable inner =
- this.serviceClient().listByPeering(resourceGroupName, peeringName);
- return Utils.mapPage(inner, inner1 -> new PeeringRegisteredAsnImpl(inner1, this.manager()));
- }
-
- public PagedIterable listByPeering(
- String resourceGroupName, String peeringName, Context context) {
- PagedIterable inner =
- this.serviceClient().listByPeering(resourceGroupName, peeringName, context);
- return Utils.mapPage(inner, inner1 -> new PeeringRegisteredAsnImpl(inner1, this.manager()));
- }
-
- public PeeringRegisteredAsn getById(String id) {
+ public PeeringServicePrefix getById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw logger
@@ -83,25 +69,25 @@ public PeeringRegisteredAsn getById(String id) {
String
.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String peeringName = Utils.getValueFromIdByName(id, "peerings");
- if (peeringName == null) {
+ String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
+ if (peeringServiceName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'peerings'.", id)));
+ String
+ .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
}
- String registeredAsnName = Utils.getValueFromIdByName(id, "registeredAsns");
- if (registeredAsnName == null) {
+ String prefixName = Utils.getValueFromIdByName(id, "prefixes");
+ if (prefixName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'registeredAsns'.", id)));
+ String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
}
- return this.getWithResponse(resourceGroupName, peeringName, registeredAsnName, Context.NONE).getValue();
+ return this.getWithResponse(resourceGroupName, peeringServiceName, prefixName, Context.NONE).getValue();
}
- public Response getByIdWithResponse(String id, Context context) {
+ public Response getByIdWithResponse(String id, Context context) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
throw logger
@@ -110,22 +96,22 @@ public Response getByIdWithResponse(String id, Context con
String
.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String peeringName = Utils.getValueFromIdByName(id, "peerings");
- if (peeringName == null) {
+ String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
+ if (peeringServiceName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'peerings'.", id)));
+ String
+ .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
}
- String registeredAsnName = Utils.getValueFromIdByName(id, "registeredAsns");
- if (registeredAsnName == null) {
+ String prefixName = Utils.getValueFromIdByName(id, "prefixes");
+ if (prefixName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'registeredAsns'.", id)));
+ String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
}
- return this.getWithResponse(resourceGroupName, peeringName, registeredAsnName, context);
+ return this.getWithResponse(resourceGroupName, peeringServiceName, prefixName, context);
}
public void deleteById(String id) {
@@ -137,22 +123,22 @@ public void deleteById(String id) {
String
.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String peeringName = Utils.getValueFromIdByName(id, "peerings");
- if (peeringName == null) {
+ String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
+ if (peeringServiceName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'peerings'.", id)));
+ String
+ .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
}
- String registeredAsnName = Utils.getValueFromIdByName(id, "registeredAsns");
- if (registeredAsnName == null) {
+ String prefixName = Utils.getValueFromIdByName(id, "prefixes");
+ if (prefixName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'registeredAsns'.", id)));
+ String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
}
- this.deleteWithResponse(resourceGroupName, peeringName, registeredAsnName, Context.NONE).getValue();
+ this.deleteWithResponse(resourceGroupName, peeringServiceName, prefixName, Context.NONE).getValue();
}
public Response deleteByIdWithResponse(String id, Context context) {
@@ -164,25 +150,25 @@ public Response deleteByIdWithResponse(String id, Context context) {
String
.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
}
- String peeringName = Utils.getValueFromIdByName(id, "peerings");
- if (peeringName == null) {
+ String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
+ if (peeringServiceName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'peerings'.", id)));
+ String
+ .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
}
- String registeredAsnName = Utils.getValueFromIdByName(id, "registeredAsns");
- if (registeredAsnName == null) {
+ String prefixName = Utils.getValueFromIdByName(id, "prefixes");
+ if (prefixName == null) {
throw logger
.logExceptionAsError(
new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'registeredAsns'.", id)));
+ String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
}
- return this.deleteWithResponse(resourceGroupName, peeringName, registeredAsnName, context);
+ return this.deleteWithResponse(resourceGroupName, peeringServiceName, prefixName, context);
}
- private RegisteredAsnsClient serviceClient() {
+ private PeeringServicePrefixesClient serviceClient() {
return this.innerClient;
}
@@ -190,7 +176,7 @@ private com.azure.resourcemanager.peering.PeeringManager manager() {
return this.serviceManager;
}
- public PeeringRegisteredAsnImpl define(String name) {
- return new PeeringRegisteredAsnImpl(name, this.manager());
+ public PeeringServicePrefixImpl define(String name) {
+ return new PeeringServicePrefixImpl(name, this.manager());
}
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceProviderImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceProviderImpl.java
index bdcdc77d7458..3aee4cc5491c 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceProviderImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PeeringServiceProviderImpl.java
@@ -6,8 +6,6 @@
import com.azure.resourcemanager.peering.fluent.models.PeeringServiceProviderInner;
import com.azure.resourcemanager.peering.models.PeeringServiceProvider;
-import java.util.Collections;
-import java.util.List;
public final class PeeringServiceProviderImpl implements PeeringServiceProvider {
private PeeringServiceProviderInner innerObject;
@@ -36,15 +34,6 @@ public String serviceProviderName() {
return this.innerModel().serviceProviderName();
}
- public List peeringLocations() {
- List inner = this.innerModel().peeringLocations();
- if (inner != null) {
- return Collections.unmodifiableList(inner);
- } else {
- return Collections.emptyList();
- }
- }
-
public PeeringServiceProviderInner innerModel() {
return this.innerObject;
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesClientImpl.java
index df6c887e50a1..0b463b820f91 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesClientImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesClientImpl.java
@@ -4,8 +4,6 @@
package com.azure.resourcemanager.peering.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;
@@ -13,7 +11,6 @@
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;
@@ -61,56 +58,6 @@ public final class PrefixesClientImpl implements PrefixesClient {
@Host("{$host}")
@ServiceInterface(name = "PeeringManagementCli")
private interface PrefixesService {
- @Headers({"Content-Type: application/json"})
- @Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering"
- + "/peeringServices/{peeringServiceName}/prefixes/{prefixName}")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringServiceName") String peeringServiceName,
- @PathParam("prefixName") String prefixName,
- @QueryParam("$expand") String expand,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Put(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering"
- + "/peeringServices/{peeringServiceName}/prefixes/{prefixName}")
- @ExpectedResponses({200, 201})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> createOrUpdate(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringServiceName") String peeringServiceName,
- @PathParam("prefixName") String prefixName,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") PeeringServicePrefixInner peeringServicePrefix,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Delete(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering"
- + "/peeringServices/{peeringServiceName}/prefixes/{prefixName}")
- @ExpectedResponses({200, 204})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> delete(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringServiceName") String peeringServiceName,
- @PathParam("prefixName") String prefixName,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @HeaderParam("Accept") String accept,
- Context context);
-
@Headers({"Content-Type: application/json"})
@Get(
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering"
@@ -121,7 +68,6 @@ Mono> listByPeeringService(
@HostParam("$host") String endpoint,
@PathParam("resourceGroupName") String resourceGroupName,
@PathParam("peeringServiceName") String peeringServiceName,
- @QueryParam("$expand") String expand,
@PathParam("subscriptionId") String subscriptionId,
@QueryParam("api-version") String apiVersion,
@HeaderParam("Accept") String accept,
@@ -139,588 +85,18 @@ Mono> listByPeeringServiceNext(
}
/**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param expand The properties to be expanded.
- * @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(
- String resourceGroupName, String peeringServiceName, String prefixName, String expand) {
- 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 (peeringServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
- }
- if (prefixName == null) {
- return Mono.error(new IllegalArgumentException("Parameter prefixName 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
- .get(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringServiceName,
- prefixName,
- expand,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param expand The properties to be expanded.
- * @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(
- String resourceGroupName, String peeringServiceName, String prefixName, String expand, Context context) {
- 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 (peeringServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
- }
- if (prefixName == null) {
- return Mono.error(new IllegalArgumentException("Parameter prefixName is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .get(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringServiceName,
- prefixName,
- expand,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context);
- }
-
- /**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param expand The properties to be expanded.
- * @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(
- String resourceGroupName, String peeringServiceName, String prefixName, String expand) {
- return getWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, expand)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
- }
-
- /**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(
- String resourceGroupName, String peeringServiceName, String prefixName) {
- final String expand = null;
- return getWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, expand)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
- }
-
- /**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public PeeringServicePrefixInner get(String resourceGroupName, String peeringServiceName, String prefixName) {
- final String expand = null;
- return getAsync(resourceGroupName, peeringServiceName, prefixName, expand).block();
- }
-
- /**
- * Gets an existing prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param expand The properties to be expanded.
- * @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 existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(
- String resourceGroupName, String peeringServiceName, String prefixName, String expand, Context context) {
- return getWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, expand, context).block();
- }
-
- /**
- * Creates a new prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param peeringServicePrefix The properties needed to create a prefix.
- * @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 peering service prefix class.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(
- String resourceGroupName,
- String peeringServiceName,
- String prefixName,
- PeeringServicePrefixInner peeringServicePrefix) {
- 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 (peeringServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
- }
- if (prefixName == null) {
- return Mono.error(new IllegalArgumentException("Parameter prefixName 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 (peeringServicePrefix == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServicePrefix is required and cannot be null."));
- } else {
- peeringServicePrefix.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(
- context ->
- service
- .createOrUpdate(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringServiceName,
- prefixName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- peeringServicePrefix,
- accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Creates a new prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param peeringServicePrefix The properties needed to create a prefix.
- * @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 peering service prefix class.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(
- String resourceGroupName,
- String peeringServiceName,
- String prefixName,
- PeeringServicePrefixInner peeringServicePrefix,
- Context context) {
- 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 (peeringServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
- }
- if (prefixName == null) {
- return Mono.error(new IllegalArgumentException("Parameter prefixName 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 (peeringServicePrefix == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServicePrefix is required and cannot be null."));
- } else {
- peeringServicePrefix.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .createOrUpdate(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringServiceName,
- prefixName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- peeringServicePrefix,
- accept,
- context);
- }
-
- /**
- * Creates a new prefix with the specified name under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param peeringServicePrefix The properties needed to create a prefix.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 peering service prefix class.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(
- String resourceGroupName,
- String peeringServiceName,
- String prefixName,
- PeeringServicePrefixInner peeringServicePrefix) {
- return createOrUpdateWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, peeringServicePrefix)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
- }
-
- /**
- * Creates a new prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param peeringServicePrefix The properties needed to create a prefix.
- * @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 peering service prefix class.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public PeeringServicePrefixInner createOrUpdate(
- String resourceGroupName,
- String peeringServiceName,
- String prefixName,
- PeeringServicePrefixInner peeringServicePrefix) {
- return createOrUpdateAsync(resourceGroupName, peeringServiceName, prefixName, peeringServicePrefix).block();
- }
-
- /**
- * Creates a new prefix with the specified name under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param peeringServicePrefix The properties needed to create a prefix.
- * @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 peering service prefix class.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response createOrUpdateWithResponse(
- String resourceGroupName,
- String peeringServiceName,
- String prefixName,
- PeeringServicePrefixInner peeringServicePrefix,
- Context context) {
- return createOrUpdateWithResponseAsync(
- resourceGroupName, peeringServiceName, prefixName, peeringServicePrefix, context)
- .block();
- }
-
- /**
- * Deletes an existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @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 completion.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(
- String resourceGroupName, String peeringServiceName, String prefixName) {
- 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 (peeringServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
- }
- if (prefixName == null) {
- return Mono.error(new IllegalArgumentException("Parameter prefixName 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
- .delete(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringServiceName,
- prefixName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Deletes an existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @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 completion.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(
- String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
- 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 (peeringServiceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter peeringServiceName is required and cannot be null."));
- }
- if (prefixName == null) {
- return Mono.error(new IllegalArgumentException("Parameter prefixName is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .delete(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringServiceName,
- prefixName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context);
- }
-
- /**
- * Deletes an existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @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 completion.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono deleteAsync(String resourceGroupName, String peeringServiceName, String prefixName) {
- return deleteWithResponseAsync(resourceGroupName, peeringServiceName, prefixName)
- .flatMap((Response res) -> Mono.empty());
- }
-
- /**
- * Deletes an existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @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 peeringServiceName, String prefixName) {
- deleteAsync(resourceGroupName, peeringServiceName, prefixName).block();
- }
-
- /**
- * Deletes an existing prefix with the specified name under the given subscription, resource group and peering
- * service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param prefixName The name of the prefix.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the response.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response deleteWithResponse(
- String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
- return deleteWithResponseAsync(resourceGroupName, peeringServiceName, prefixName, context).block();
- }
-
- /**
- * Lists all prefixes under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param expand The properties to be expanded.
- * @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> listByPeeringServiceSinglePageAsync(
- String resourceGroupName, String peeringServiceName, String expand) {
+ String resourceGroupName, String peeringServiceName) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -750,7 +126,6 @@ private Mono> listByPeeringServiceSingl
this.client.getEndpoint(),
resourceGroupName,
peeringServiceName,
- expand,
this.client.getSubscriptionId(),
this.client.getApiVersion(),
accept,
@@ -768,20 +143,19 @@ private Mono> listByPeeringServiceSingl
}
/**
- * Lists all prefixes under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param expand The properties to be expanded.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> listByPeeringServiceSinglePageAsync(
- String resourceGroupName, String peeringServiceName, String expand, Context context) {
+ String resourceGroupName, String peeringServiceName, Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -809,7 +183,6 @@ private Mono> listByPeeringServiceSingl
this.client.getEndpoint(),
resourceGroupName,
peeringServiceName,
- expand,
this.client.getSubscriptionId(),
this.client.getApiVersion(),
accept,
@@ -826,96 +199,73 @@ private Mono> listByPeeringServiceSingl
}
/**
- * Lists all prefixes under the given subscription, resource group and peering service.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param expand The properties to be expanded.
- * @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 paginated list of peering service prefixes.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByPeeringServiceAsync(
- String resourceGroupName, String peeringServiceName, String expand) {
- return new PagedFlux<>(
- () -> listByPeeringServiceSinglePageAsync(resourceGroupName, peeringServiceName, expand),
- nextLink -> listByPeeringServiceNextSinglePageAsync(nextLink));
- }
-
- /**
- * Lists all prefixes under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
private PagedFlux listByPeeringServiceAsync(
String resourceGroupName, String peeringServiceName) {
- final String expand = null;
return new PagedFlux<>(
- () -> listByPeeringServiceSinglePageAsync(resourceGroupName, peeringServiceName, expand),
+ () -> listByPeeringServiceSinglePageAsync(resourceGroupName, peeringServiceName),
nextLink -> listByPeeringServiceNextSinglePageAsync(nextLink));
}
/**
- * Lists all prefixes under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param expand The properties to be expanded.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
private PagedFlux listByPeeringServiceAsync(
- String resourceGroupName, String peeringServiceName, String expand, Context context) {
+ String resourceGroupName, String peeringServiceName, Context context) {
return new PagedFlux<>(
- () -> listByPeeringServiceSinglePageAsync(resourceGroupName, peeringServiceName, expand, context),
+ () -> listByPeeringServiceSinglePageAsync(resourceGroupName, peeringServiceName, context),
nextLink -> listByPeeringServiceNextSinglePageAsync(nextLink, context));
}
/**
- * Lists all prefixes under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
public PagedIterable listByPeeringService(
String resourceGroupName, String peeringServiceName) {
- final String expand = null;
- return new PagedIterable<>(listByPeeringServiceAsync(resourceGroupName, peeringServiceName, expand));
+ return new PagedIterable<>(listByPeeringServiceAsync(resourceGroupName, peeringServiceName));
}
/**
- * Lists all prefixes under the given subscription, resource group and peering service.
+ * Lists the peerings prefix in the resource group.
*
- * @param resourceGroupName The name of the resource group.
- * @param peeringServiceName The name of the peering service.
- * @param expand The properties to be expanded.
+ * @param resourceGroupName The resource group name.
+ * @param peeringServiceName The peering service name.
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
public PagedIterable listByPeeringService(
- String resourceGroupName, String peeringServiceName, String expand, Context context) {
- return new PagedIterable<>(listByPeeringServiceAsync(resourceGroupName, peeringServiceName, expand, context));
+ String resourceGroupName, String peeringServiceName, Context context) {
+ return new PagedIterable<>(listByPeeringServiceAsync(resourceGroupName, peeringServiceName, context));
}
/**
@@ -925,7 +275,7 @@ public PagedIterable listByPeeringService(
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> listByPeeringServiceNextSinglePageAsync(String nextLink) {
@@ -962,7 +312,7 @@ private Mono> listByPeeringServiceNextS
* @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 paginated list of peering service prefixes.
+ * @return the paginated list of [T].
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> listByPeeringServiceNextSinglePageAsync(
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesImpl.java
index 7b6c5a890d2c..e357579b4533 100644
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesImpl.java
+++ b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/PrefixesImpl.java
@@ -5,8 +5,6 @@
package com.azure.resourcemanager.peering.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.peering.fluent.PrefixesClient;
@@ -27,39 +25,6 @@ public PrefixesImpl(PrefixesClient innerClient, com.azure.resourcemanager.peerin
this.serviceManager = serviceManager;
}
- public PeeringServicePrefix get(String resourceGroupName, String peeringServiceName, String prefixName) {
- PeeringServicePrefixInner inner = this.serviceClient().get(resourceGroupName, peeringServiceName, prefixName);
- if (inner != null) {
- return new PeeringServicePrefixImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
- public Response getWithResponse(
- String resourceGroupName, String peeringServiceName, String prefixName, String expand, Context context) {
- Response inner =
- this.serviceClient().getWithResponse(resourceGroupName, peeringServiceName, prefixName, expand, context);
- if (inner != null) {
- return new SimpleResponse<>(
- inner.getRequest(),
- inner.getStatusCode(),
- inner.getHeaders(),
- new PeeringServicePrefixImpl(inner.getValue(), this.manager()));
- } else {
- return null;
- }
- }
-
- public void delete(String resourceGroupName, String peeringServiceName, String prefixName) {
- this.serviceClient().delete(resourceGroupName, peeringServiceName, prefixName);
- }
-
- public Response deleteWithResponse(
- String resourceGroupName, String peeringServiceName, String prefixName, Context context) {
- return this.serviceClient().deleteWithResponse(resourceGroupName, peeringServiceName, prefixName, context);
- }
-
public PagedIterable listByPeeringService(
String resourceGroupName, String peeringServiceName) {
PagedIterable inner =
@@ -68,123 +33,12 @@ public PagedIterable listByPeeringService(
}
public PagedIterable listByPeeringService(
- String resourceGroupName, String peeringServiceName, String expand, Context context) {
+ String resourceGroupName, String peeringServiceName, Context context) {
PagedIterable inner =
- this.serviceClient().listByPeeringService(resourceGroupName, peeringServiceName, expand, context);
+ this.serviceClient().listByPeeringService(resourceGroupName, peeringServiceName, context);
return Utils.mapPage(inner, inner1 -> new PeeringServicePrefixImpl(inner1, this.manager()));
}
- public PeeringServicePrefix getById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
- if (peeringServiceName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
- }
- String prefixName = Utils.getValueFromIdByName(id, "prefixes");
- if (prefixName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
- }
- String localExpand = null;
- return this
- .getWithResponse(resourceGroupName, peeringServiceName, prefixName, localExpand, Context.NONE)
- .getValue();
- }
-
- public Response getByIdWithResponse(String id, String expand, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
- if (peeringServiceName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
- }
- String prefixName = Utils.getValueFromIdByName(id, "prefixes");
- if (prefixName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
- }
- return this.getWithResponse(resourceGroupName, peeringServiceName, prefixName, expand, context);
- }
-
- public void deleteById(String id) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
- if (peeringServiceName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
- }
- String prefixName = Utils.getValueFromIdByName(id, "prefixes");
- if (prefixName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
- }
- this.deleteWithResponse(resourceGroupName, peeringServiceName, prefixName, Context.NONE).getValue();
- }
-
- public Response deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String peeringServiceName = Utils.getValueFromIdByName(id, "peeringServices");
- if (peeringServiceName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String
- .format("The resource ID '%s' is not valid. Missing path segment 'peeringServices'.", id)));
- }
- String prefixName = Utils.getValueFromIdByName(id, "prefixes");
- if (prefixName == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'prefixes'.", id)));
- }
- return this.deleteWithResponse(resourceGroupName, peeringServiceName, prefixName, context);
- }
-
private PrefixesClient serviceClient() {
return this.innerClient;
}
@@ -192,8 +46,4 @@ private PrefixesClient serviceClient() {
private com.azure.resourcemanager.peering.PeeringManager manager() {
return this.serviceManager;
}
-
- public PeeringServicePrefixImpl define(String name) {
- return new PeeringServicePrefixImpl(name, this.manager());
- }
}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/ReceivedRoutesClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/ReceivedRoutesClientImpl.java
deleted file mode 100644
index c966fd5a4fa6..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/ReceivedRoutesClientImpl.java
+++ /dev/null
@@ -1,482 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.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.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.peering.fluent.ReceivedRoutesClient;
-import com.azure.resourcemanager.peering.fluent.models.PeeringReceivedRouteInner;
-import com.azure.resourcemanager.peering.models.PeeringReceivedRouteListResult;
-import reactor.core.publisher.Mono;
-
-/** An instance of this class provides access to all the operations defined in ReceivedRoutesClient. */
-public final class ReceivedRoutesClientImpl implements ReceivedRoutesClient {
- private final ClientLogger logger = new ClientLogger(ReceivedRoutesClientImpl.class);
-
- /** The proxy service used to perform REST calls. */
- private final ReceivedRoutesService service;
-
- /** The service client containing this operation class. */
- private final PeeringManagementClientImpl client;
-
- /**
- * Initializes an instance of ReceivedRoutesClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- ReceivedRoutesClientImpl(PeeringManagementClientImpl client) {
- this.service =
- RestProxy.create(ReceivedRoutesService.class, client.getHttpPipeline(), client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for PeeringManagementClientReceivedRoutes to be used by the proxy service
- * to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "PeeringManagementCli")
- private interface ReceivedRoutesService {
- @Headers({"Content-Type: application/json"})
- @Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering/peerings"
- + "/{peeringName}/receivedRoutes")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByPeering(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringName") String peeringName,
- @QueryParam("prefix") String prefix,
- @QueryParam("asPath") String asPath,
- @QueryParam("originAsValidationState") String originAsValidationState,
- @QueryParam("rpkiValidationState") String rpkiValidationState,
- @QueryParam("$skipToken") String skipToken,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Get("{nextLink}")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByPeeringNext(
- @PathParam(value = "nextLink", encoded = true) String nextLink,
- @HostParam("$host") String endpoint,
- @HeaderParam("Accept") String accept,
- Context context);
- }
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param prefix The optional prefix that can be used to filter the routes.
- * @param asPath The optional AS path that can be used to filter the routes.
- * @param originAsValidationState The optional origin AS validation state that can be used to filter the routes.
- * @param rpkiValidationState The optional RPKI validation state that can be used to filter the routes.
- * @param skipToken The optional page continuation token that is used in the event of paginated result.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByPeeringSinglePageAsync(
- String resourceGroupName,
- String peeringName,
- String prefix,
- String asPath,
- String originAsValidationState,
- String rpkiValidationState,
- String skipToken) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName 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
- .listByPeering(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- 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()));
- }
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param prefix The optional prefix that can be used to filter the routes.
- * @param asPath The optional AS path that can be used to filter the routes.
- * @param originAsValidationState The optional origin AS validation state that can be used to filter the routes.
- * @param rpkiValidationState The optional RPKI validation state that can be used to filter the routes.
- * @param skipToken The optional page continuation token that is used in the event of paginated result.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByPeeringSinglePageAsync(
- String resourceGroupName,
- String peeringName,
- String prefix,
- String asPath,
- String originAsValidationState,
- String rpkiValidationState,
- String skipToken,
- Context context) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .listByPeering(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
- }
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param prefix The optional prefix that can be used to filter the routes.
- * @param asPath The optional AS path that can be used to filter the routes.
- * @param originAsValidationState The optional origin AS validation state that can be used to filter the routes.
- * @param rpkiValidationState The optional RPKI validation state that can be used to filter the routes.
- * @param skipToken The optional page continuation token that is used in the event of paginated result.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByPeeringAsync(
- String resourceGroupName,
- String peeringName,
- String prefix,
- String asPath,
- String originAsValidationState,
- String rpkiValidationState,
- String skipToken) {
- return new PagedFlux<>(
- () ->
- listByPeeringSinglePageAsync(
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken),
- nextLink -> listByPeeringNextSinglePageAsync(nextLink));
- }
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByPeeringAsync(String resourceGroupName, String peeringName) {
- final String prefix = null;
- final String asPath = null;
- final String originAsValidationState = null;
- final String rpkiValidationState = null;
- final String skipToken = null;
- return new PagedFlux<>(
- () ->
- listByPeeringSinglePageAsync(
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken),
- nextLink -> listByPeeringNextSinglePageAsync(nextLink));
- }
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param prefix The optional prefix that can be used to filter the routes.
- * @param asPath The optional AS path that can be used to filter the routes.
- * @param originAsValidationState The optional origin AS validation state that can be used to filter the routes.
- * @param rpkiValidationState The optional RPKI validation state that can be used to filter the routes.
- * @param skipToken The optional page continuation token that is used in the event of paginated result.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByPeeringAsync(
- String resourceGroupName,
- String peeringName,
- String prefix,
- String asPath,
- String originAsValidationState,
- String rpkiValidationState,
- String skipToken,
- Context context) {
- return new PagedFlux<>(
- () ->
- listByPeeringSinglePageAsync(
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken,
- context),
- nextLink -> listByPeeringNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByPeering(String resourceGroupName, String peeringName) {
- final String prefix = null;
- final String asPath = null;
- final String originAsValidationState = null;
- final String rpkiValidationState = null;
- final String skipToken = null;
- return new PagedIterable<>(
- listByPeeringAsync(
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken));
- }
-
- /**
- * Lists the prefixes received over the specified peering under the given subscription and resource group.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param prefix The optional prefix that can be used to filter the routes.
- * @param asPath The optional AS path that can be used to filter the routes.
- * @param originAsValidationState The optional origin AS validation state that can be used to filter the routes.
- * @param rpkiValidationState The optional RPKI validation state that can be used to filter the routes.
- * @param skipToken The optional page continuation token that is used in the event of paginated result.
- * @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 paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByPeering(
- String resourceGroupName,
- String peeringName,
- String prefix,
- String asPath,
- String originAsValidationState,
- String rpkiValidationState,
- String skipToken,
- Context context) {
- return new PagedIterable<>(
- listByPeeringAsync(
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken,
- context));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The nextLink parameter.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByPeeringNextSinglePageAsync(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.listByPeeringNext(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 nextLink parameter.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the paginated list of received routes for the peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByPeeringNextSinglePageAsync(
- String nextLink, Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .listByPeeringNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/ReceivedRoutesImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/ReceivedRoutesImpl.java
deleted file mode 100644
index 0c2ad7795e25..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/ReceivedRoutesImpl.java
+++ /dev/null
@@ -1,66 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.util.Context;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.fluent.ReceivedRoutesClient;
-import com.azure.resourcemanager.peering.fluent.models.PeeringReceivedRouteInner;
-import com.azure.resourcemanager.peering.models.PeeringReceivedRoute;
-import com.azure.resourcemanager.peering.models.ReceivedRoutes;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-
-public final class ReceivedRoutesImpl implements ReceivedRoutes {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ReceivedRoutesImpl.class);
-
- private final ReceivedRoutesClient innerClient;
-
- private final com.azure.resourcemanager.peering.PeeringManager serviceManager;
-
- public ReceivedRoutesImpl(
- ReceivedRoutesClient innerClient, com.azure.resourcemanager.peering.PeeringManager serviceManager) {
- this.innerClient = innerClient;
- this.serviceManager = serviceManager;
- }
-
- public PagedIterable listByPeering(String resourceGroupName, String peeringName) {
- PagedIterable inner =
- this.serviceClient().listByPeering(resourceGroupName, peeringName);
- return Utils.mapPage(inner, inner1 -> new PeeringReceivedRouteImpl(inner1, this.manager()));
- }
-
- public PagedIterable listByPeering(
- String resourceGroupName,
- String peeringName,
- String prefix,
- String asPath,
- String originAsValidationState,
- String rpkiValidationState,
- String skipToken,
- Context context) {
- PagedIterable inner =
- this
- .serviceClient()
- .listByPeering(
- resourceGroupName,
- peeringName,
- prefix,
- asPath,
- originAsValidationState,
- rpkiValidationState,
- skipToken,
- context);
- return Utils.mapPage(inner, inner1 -> new PeeringReceivedRouteImpl(inner1, this.manager()));
- }
-
- private ReceivedRoutesClient serviceClient() {
- return this.innerClient;
- }
-
- private com.azure.resourcemanager.peering.PeeringManager manager() {
- return this.serviceManager;
- }
-}
diff --git a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/RegisteredAsnsClientImpl.java b/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/RegisteredAsnsClientImpl.java
deleted file mode 100644
index cf90b31f394b..000000000000
--- a/sdk/peering/azure-resourcemanager-peering/src/main/java/com/azure/resourcemanager/peering/implementation/RegisteredAsnsClientImpl.java
+++ /dev/null
@@ -1,924 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.peering.implementation;
-
-import com.azure.core.annotation.BodyParam;
-import com.azure.core.annotation.Delete;
-import com.azure.core.annotation.ExpectedResponses;
-import com.azure.core.annotation.Get;
-import com.azure.core.annotation.HeaderParam;
-import com.azure.core.annotation.Headers;
-import com.azure.core.annotation.Host;
-import com.azure.core.annotation.HostParam;
-import com.azure.core.annotation.PathParam;
-import com.azure.core.annotation.Put;
-import com.azure.core.annotation.QueryParam;
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceInterface;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.annotation.UnexpectedResponseExceptionType;
-import com.azure.core.http.rest.PagedFlux;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.PagedResponse;
-import com.azure.core.http.rest.PagedResponseBase;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.RestProxy;
-import com.azure.core.management.exception.ManagementException;
-import com.azure.core.util.Context;
-import com.azure.core.util.FluxUtil;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.peering.fluent.RegisteredAsnsClient;
-import com.azure.resourcemanager.peering.fluent.models.PeeringRegisteredAsnInner;
-import com.azure.resourcemanager.peering.models.PeeringRegisteredAsnListResult;
-import reactor.core.publisher.Mono;
-
-/** An instance of this class provides access to all the operations defined in RegisteredAsnsClient. */
-public final class RegisteredAsnsClientImpl implements RegisteredAsnsClient {
- private final ClientLogger logger = new ClientLogger(RegisteredAsnsClientImpl.class);
-
- /** The proxy service used to perform REST calls. */
- private final RegisteredAsnsService service;
-
- /** The service client containing this operation class. */
- private final PeeringManagementClientImpl client;
-
- /**
- * Initializes an instance of RegisteredAsnsClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- RegisteredAsnsClientImpl(PeeringManagementClientImpl client) {
- this.service =
- RestProxy.create(RegisteredAsnsService.class, client.getHttpPipeline(), client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for PeeringManagementClientRegisteredAsns to be used by the proxy service
- * to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "PeeringManagementCli")
- private interface RegisteredAsnsService {
- @Headers({"Content-Type: application/json"})
- @Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering/peerings"
- + "/{peeringName}/registeredAsns/{registeredAsnName}")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringName") String peeringName,
- @PathParam("registeredAsnName") String registeredAsnName,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Put(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering/peerings"
- + "/{peeringName}/registeredAsns/{registeredAsnName}")
- @ExpectedResponses({200, 201})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> createOrUpdate(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringName") String peeringName,
- @PathParam("registeredAsnName") String registeredAsnName,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") PeeringRegisteredAsnInner registeredAsn,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Delete(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering/peerings"
- + "/{peeringName}/registeredAsns/{registeredAsnName}")
- @ExpectedResponses({200, 204})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> delete(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringName") String peeringName,
- @PathParam("registeredAsnName") String registeredAsnName,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Get(
- "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Peering/peerings"
- + "/{peeringName}/registeredAsns")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByPeering(
- @HostParam("$host") String endpoint,
- @PathParam("resourceGroupName") String resourceGroupName,
- @PathParam("peeringName") String peeringName,
- @PathParam("subscriptionId") String subscriptionId,
- @QueryParam("api-version") String apiVersion,
- @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({"Content-Type: application/json"})
- @Get("{nextLink}")
- @ExpectedResponses({200})
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByPeeringNext(
- @PathParam(value = "nextLink", encoded = true) String nextLink,
- @HostParam("$host") String endpoint,
- @HeaderParam("Accept") String accept,
- Context context);
- }
-
- /**
- * Gets an existing registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(
- String resourceGroupName, String peeringName, String registeredAsnName) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (registeredAsnName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter registeredAsnName 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
- .get(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- registeredAsnName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Gets an existing registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (registeredAsnName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter registeredAsnName is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .get(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- registeredAsnName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context);
- }
-
- /**
- * Gets an existing registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(
- String resourceGroupName, String peeringName, String registeredAsnName) {
- return getWithResponseAsync(resourceGroupName, peeringName, registeredAsnName)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
- }
-
- /**
- * Gets an existing registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public PeeringRegisteredAsnInner get(String resourceGroupName, String peeringName, String registeredAsnName) {
- return getAsync(resourceGroupName, peeringName, registeredAsnName).block();
- }
-
- /**
- * Gets an existing registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context) {
- return getWithResponseAsync(resourceGroupName, peeringName, registeredAsnName, context).block();
- }
-
- /**
- * Creates a new registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the ASN.
- * @param registeredAsn The properties needed to create a registered ASN.
- * @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 customer's ASN that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(
- String resourceGroupName,
- String peeringName,
- String registeredAsnName,
- PeeringRegisteredAsnInner registeredAsn) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (registeredAsnName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter registeredAsnName 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 (registeredAsn == null) {
- return Mono.error(new IllegalArgumentException("Parameter registeredAsn is required and cannot be null."));
- } else {
- registeredAsn.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(
- context ->
- service
- .createOrUpdate(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- registeredAsnName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- registeredAsn,
- accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Creates a new registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the ASN.
- * @param registeredAsn The properties needed to create a registered ASN.
- * @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 customer's ASN that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(
- String resourceGroupName,
- String peeringName,
- String registeredAsnName,
- PeeringRegisteredAsnInner registeredAsn,
- Context context) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (registeredAsnName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter registeredAsnName 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 (registeredAsn == null) {
- return Mono.error(new IllegalArgumentException("Parameter registeredAsn is required and cannot be null."));
- } else {
- registeredAsn.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .createOrUpdate(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- registeredAsnName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- registeredAsn,
- accept,
- context);
- }
-
- /**
- * Creates a new registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the ASN.
- * @param registeredAsn The properties needed to create a registered ASN.
- * @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 customer's ASN that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(
- String resourceGroupName,
- String peeringName,
- String registeredAsnName,
- PeeringRegisteredAsnInner registeredAsn) {
- return createOrUpdateWithResponseAsync(resourceGroupName, peeringName, registeredAsnName, registeredAsn)
- .flatMap(
- (Response res) -> {
- if (res.getValue() != null) {
- return Mono.just(res.getValue());
- } else {
- return Mono.empty();
- }
- });
- }
-
- /**
- * Creates a new registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the ASN.
- * @param registeredAsn The properties needed to create a registered ASN.
- * @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 customer's ASN that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public PeeringRegisteredAsnInner createOrUpdate(
- String resourceGroupName,
- String peeringName,
- String registeredAsnName,
- PeeringRegisteredAsnInner registeredAsn) {
- return createOrUpdateAsync(resourceGroupName, peeringName, registeredAsnName, registeredAsn).block();
- }
-
- /**
- * Creates a new registered ASN with the specified name under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the ASN.
- * @param registeredAsn The properties needed to create a registered ASN.
- * @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 customer's ASN that is registered by the peering service provider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response createOrUpdateWithResponse(
- String resourceGroupName,
- String peeringName,
- String registeredAsnName,
- PeeringRegisteredAsnInner registeredAsn,
- Context context) {
- return createOrUpdateWithResponseAsync(
- resourceGroupName, peeringName, registeredAsnName, registeredAsn, context)
- .block();
- }
-
- /**
- * Deletes an existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 completion.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(
- String resourceGroupName, String peeringName, String registeredAsnName) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (registeredAsnName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter registeredAsnName 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
- .delete(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- registeredAsnName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Deletes an existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 completion.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (registeredAsnName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter registeredAsnName is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .delete(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- registeredAsnName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context);
- }
-
- /**
- * Deletes an existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 completion.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono deleteAsync(String resourceGroupName, String peeringName, String registeredAsnName) {
- return deleteWithResponseAsync(resourceGroupName, peeringName, registeredAsnName)
- .flatMap((Response res) -> Mono.empty());
- }
-
- /**
- * Deletes an existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @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 peeringName, String registeredAsnName) {
- deleteAsync(resourceGroupName, peeringName, registeredAsnName).block();
- }
-
- /**
- * Deletes an existing registered ASN with the specified name under the given subscription, resource group and
- * peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @param registeredAsnName The name of the registered ASN.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the response.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response deleteWithResponse(
- String resourceGroupName, String peeringName, String registeredAsnName, Context context) {
- return deleteWithResponseAsync(resourceGroupName, peeringName, registeredAsnName, context).block();
- }
-
- /**
- * Lists all registered ASNs under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of peering registered ASNs.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByPeeringSinglePageAsync(
- String resourceGroupName, String peeringName) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName 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
- .listByPeering(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- 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()));
- }
-
- /**
- * Lists all registered ASNs under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of peering registered ASNs.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByPeeringSinglePageAsync(
- String resourceGroupName, String peeringName, Context context) {
- 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 (peeringName == null) {
- return Mono.error(new IllegalArgumentException("Parameter peeringName is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono
- .error(
- new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .listByPeering(
- this.client.getEndpoint(),
- resourceGroupName,
- peeringName,
- this.client.getSubscriptionId(),
- this.client.getApiVersion(),
- accept,
- context)
- .map(
- res ->
- new PagedResponseBase<>(
- res.getRequest(),
- res.getStatusCode(),
- res.getHeaders(),
- res.getValue().value(),
- res.getValue().nextLink(),
- null));
- }
-
- /**
- * Lists all registered ASNs under the given subscription, resource group and peering.
- *
- * @param resourceGroupName The name of the resource group.
- * @param peeringName The name of the peering.
- * @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 paginated list of peering registered ASNs.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux