Skip to content

Commit

Permalink
CodeGen from PR 19681 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge ee5fdd3adaee5c66873df117d0dad1fc93394595 into 9d85adf7eb1bf9877be1e7a7991b7f1e2252a0e2
  • Loading branch information
SDKAuto committed Jul 6, 2022
1 parent 8378aee commit 64cf03a
Show file tree
Hide file tree
Showing 199 changed files with 6,877 additions and 2,690 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Release History

## 1.0.0-beta.3 (Unreleased)
## 1.0.0-beta.1 (2022-07-06)

- Azure Resource Manager MobileNetwork client library for Java. This package contains Microsoft Azure SDK for MobileNetwork Management SDK. The resources in this swagger specification will be used to manage attached data network resources in mobile network attached to a particular packet core instance. Package tag package-2022-04-01-preview. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

### Features Added

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Azure Resource Manager MobileNetwork client library for Java.

This package contains Microsoft Azure SDK for MobileNetwork Management SDK. The resources in this swagger specification will be used to manage attached data network resources in mobile network attached to a particular packet core instance. Package tag package-2022-03-01-preview. 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 MobileNetwork Management SDK. The resources in this swagger specification will be used to manage attached data network resources in mobile network attached to a particular packet core instance. Package tag package-2022-04-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

Expand Down Expand Up @@ -32,7 +32,7 @@ Various documentation is available to help you get started
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-mobilenetwork</artifactId>
<version>1.0.0-beta.2</version>
<version>1.0.0-beta.3</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down
499 changes: 321 additions & 178 deletions sdk/mobilenetwork/azure-resourcemanager-mobilenetwork/SAMPLE.md

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<packaging>jar</packaging>

<name>Microsoft Azure SDK for MobileNetwork Management</name>
<description>This package contains Microsoft Azure SDK for MobileNetwork Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. The resources in this swagger specification will be used to manage attached data network resources in mobile network attached to a particular packet core instance. Package tag package-2022-03-01-preview.</description>
<description>This package contains Microsoft Azure SDK for MobileNetwork Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. The resources in this swagger specification will be used to manage attached data network resources in mobile network attached to a particular packet core instance. Package tag package-2022-04-01-preview.</description>
<url>https://github.com/Azure/azure-sdk-for-java</url>

<licenses>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@
import com.azure.core.http.HttpPipelineBuilder;
import com.azure.core.http.HttpPipelinePosition;
import com.azure.core.http.policy.AddDatePolicy;
import com.azure.core.http.policy.AddHeadersFromContextPolicy;
import com.azure.core.http.policy.HttpLogOptions;
import com.azure.core.http.policy.HttpLoggingPolicy;
import com.azure.core.http.policy.HttpPipelinePolicy;
import com.azure.core.http.policy.HttpPolicyProviders;
import com.azure.core.http.policy.RequestIdPolicy;
import com.azure.core.http.policy.RetryOptions;
import com.azure.core.http.policy.RetryPolicy;
import com.azure.core.http.policy.UserAgentPolicy;
import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy;
Expand All @@ -30,6 +32,7 @@
import com.azure.resourcemanager.mobilenetwork.implementation.PacketCoreControlPlanesImpl;
import com.azure.resourcemanager.mobilenetwork.implementation.PacketCoreDataPlanesImpl;
import com.azure.resourcemanager.mobilenetwork.implementation.ServicesImpl;
import com.azure.resourcemanager.mobilenetwork.implementation.SimGroupsImpl;
import com.azure.resourcemanager.mobilenetwork.implementation.SimPoliciesImpl;
import com.azure.resourcemanager.mobilenetwork.implementation.SimsImpl;
import com.azure.resourcemanager.mobilenetwork.implementation.SitesImpl;
Expand All @@ -41,6 +44,7 @@
import com.azure.resourcemanager.mobilenetwork.models.PacketCoreControlPlanes;
import com.azure.resourcemanager.mobilenetwork.models.PacketCoreDataPlanes;
import com.azure.resourcemanager.mobilenetwork.models.Services;
import com.azure.resourcemanager.mobilenetwork.models.SimGroups;
import com.azure.resourcemanager.mobilenetwork.models.SimPolicies;
import com.azure.resourcemanager.mobilenetwork.models.Sims;
import com.azure.resourcemanager.mobilenetwork.models.Sites;
Expand All @@ -65,6 +69,8 @@ public final class MobileNetworkManager {

private Sites sites;

private SimGroups simGroups;

private Sims sims;

private Operations operations;
Expand Down Expand Up @@ -106,6 +112,19 @@ public static MobileNetworkManager authenticate(TokenCredential credential, Azur
return configure().authenticate(credential, profile);
}

/**
* Creates an instance of MobileNetwork service API entry point.
*
* @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential.
* @param profile the Azure profile for client.
* @return the MobileNetwork service API instance.
*/
public static MobileNetworkManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) {
Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
Objects.requireNonNull(profile, "'profile' cannot be null.");
return new MobileNetworkManager(httpPipeline, profile, null);
}

/**
* Gets a Configurable instance that can be used to create MobileNetworkManager with optional configuration.
*
Expand All @@ -124,6 +143,7 @@ public static final class Configurable {
private final List<HttpPipelinePolicy> policies = new ArrayList<>();
private final List<String> scopes = new ArrayList<>();
private RetryPolicy retryPolicy;
private RetryOptions retryOptions;
private Duration defaultPollInterval;

private Configurable() {
Expand Down Expand Up @@ -184,6 +204,19 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) {
return this;
}

/**
* Sets the retry options for the HTTP pipeline retry policy.
*
* <p>This setting has no effect, if retry policy is set via {@link #withRetryPolicy(RetryPolicy)}.
*
* @param retryOptions the retry options for the HTTP pipeline retry policy.
* @return the configurable object itself.
*/
public Configurable withRetryOptions(RetryOptions retryOptions) {
this.retryOptions = Objects.requireNonNull(retryOptions, "'retryOptions' cannot be null.");
return this;
}

/**
* Sets the default poll interval, used when service does not provide "Retry-After" header.
*
Expand Down Expand Up @@ -217,7 +250,7 @@ public MobileNetworkManager authenticate(TokenCredential credential, AzureProfil
.append("-")
.append("com.azure.resourcemanager.mobilenetwork")
.append("/")
.append("1.0.0-beta.2");
.append("1.0.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder
.append(" (")
Expand All @@ -235,10 +268,15 @@ public MobileNetworkManager authenticate(TokenCredential credential, AzureProfil
scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default");
}
if (retryPolicy == null) {
retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS);
if (retryOptions != null) {
retryPolicy = new RetryPolicy(retryOptions);
} else {
retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS);
}
}
List<HttpPipelinePolicy> policies = new ArrayList<>();
policies.add(new UserAgentPolicy(userAgentBuilder.toString()));
policies.add(new AddHeadersFromContextPolicy());
policies.add(new RequestIdPolicy());
policies
.addAll(
Expand Down Expand Up @@ -269,55 +307,95 @@ public MobileNetworkManager authenticate(TokenCredential credential, AzureProfil
}
}

/** @return Resource collection API of AttachedDataNetworks. */
/**
* Gets the resource collection API of AttachedDataNetworks. It manages AttachedDataNetwork.
*
* @return Resource collection API of AttachedDataNetworks.
*/
public AttachedDataNetworks attachedDataNetworks() {
if (this.attachedDataNetworks == null) {
this.attachedDataNetworks = new AttachedDataNetworksImpl(clientObject.getAttachedDataNetworks(), this);
}
return attachedDataNetworks;
}

/** @return Resource collection API of DataNetworks. */
/**
* Gets the resource collection API of DataNetworks. It manages DataNetwork.
*
* @return Resource collection API of DataNetworks.
*/
public DataNetworks dataNetworks() {
if (this.dataNetworks == null) {
this.dataNetworks = new DataNetworksImpl(clientObject.getDataNetworks(), this);
}
return dataNetworks;
}

/** @return Resource collection API of MobileNetworks. */
/**
* Gets the resource collection API of MobileNetworks. It manages MobileNetwork.
*
* @return Resource collection API of MobileNetworks.
*/
public MobileNetworks mobileNetworks() {
if (this.mobileNetworks == null) {
this.mobileNetworks = new MobileNetworksImpl(clientObject.getMobileNetworks(), this);
}
return mobileNetworks;
}

/** @return Resource collection API of Sites. */
/**
* Gets the resource collection API of Sites. It manages Site.
*
* @return Resource collection API of Sites.
*/
public Sites sites() {
if (this.sites == null) {
this.sites = new SitesImpl(clientObject.getSites(), this);
}
return sites;
}

/** @return Resource collection API of Sims. */
/**
* Gets the resource collection API of SimGroups. It manages SimGroup.
*
* @return Resource collection API of SimGroups.
*/
public SimGroups simGroups() {
if (this.simGroups == null) {
this.simGroups = new SimGroupsImpl(clientObject.getSimGroups(), this);
}
return simGroups;
}

/**
* Gets the resource collection API of Sims. It manages Sim.
*
* @return Resource collection API of Sims.
*/
public Sims sims() {
if (this.sims == null) {
this.sims = new SimsImpl(clientObject.getSims(), this);
}
return sims;
}

/** @return Resource collection API of Operations. */
/**
* Gets the resource collection API of Operations.
*
* @return Resource collection API of Operations.
*/
public Operations operations() {
if (this.operations == null) {
this.operations = new OperationsImpl(clientObject.getOperations(), this);
}
return operations;
}

/** @return Resource collection API of PacketCoreControlPlanes. */
/**
* Gets the resource collection API of PacketCoreControlPlanes. It manages PacketCoreControlPlane.
*
* @return Resource collection API of PacketCoreControlPlanes.
*/
public PacketCoreControlPlanes packetCoreControlPlanes() {
if (this.packetCoreControlPlanes == null) {
this.packetCoreControlPlanes =
Expand All @@ -326,31 +404,47 @@ public PacketCoreControlPlanes packetCoreControlPlanes() {
return packetCoreControlPlanes;
}

/** @return Resource collection API of PacketCoreDataPlanes. */
/**
* Gets the resource collection API of PacketCoreDataPlanes. It manages PacketCoreDataPlane.
*
* @return Resource collection API of PacketCoreDataPlanes.
*/
public PacketCoreDataPlanes packetCoreDataPlanes() {
if (this.packetCoreDataPlanes == null) {
this.packetCoreDataPlanes = new PacketCoreDataPlanesImpl(clientObject.getPacketCoreDataPlanes(), this);
}
return packetCoreDataPlanes;
}

/** @return Resource collection API of Services. */
/**
* Gets the resource collection API of Services. It manages Service.
*
* @return Resource collection API of Services.
*/
public Services services() {
if (this.services == null) {
this.services = new ServicesImpl(clientObject.getServices(), this);
}
return services;
}

/** @return Resource collection API of SimPolicies. */
/**
* Gets the resource collection API of SimPolicies. It manages SimPolicy.
*
* @return Resource collection API of SimPolicies.
*/
public SimPolicies simPolicies() {
if (this.simPolicies == null) {
this.simPolicies = new SimPoliciesImpl(clientObject.getSimPolicies(), this);
}
return simPolicies;
}

/** @return Resource collection API of Slices. */
/**
* Gets the resource collection API of Slices. It manages Slice.
*
* @return Resource collection API of Slices.
*/
public Slices slices() {
if (this.slices == null) {
this.slices = new SlicesImpl(clientObject.getSlices(), this);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ AttachedDataNetworkInner createOrUpdate(
Context context);

/**
* Updates an attached data network update tags.
* Updates an attached data network tags.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param packetCoreControlPlaneName The name of the packet core control plane.
Expand All @@ -244,7 +244,7 @@ AttachedDataNetworkInner updateTags(
TagsObject parameters);

/**
* Updates an attached data network update tags.
* Updates an attached data network tags.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param packetCoreControlPlaneName The name of the packet core control plane.
Expand All @@ -267,23 +267,23 @@ Response<AttachedDataNetworkInner> updateTagsWithResponse(
Context context);

/**
* Gets all the data networks associated with a packet core data plane.
* Gets all the attached data networks associated with a packet core data plane.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param packetCoreControlPlaneName The name of the packet core control plane.
* @param packetCoreDataPlaneName The name of the packet core data plane.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return all the data networks associated with a packet core data plane as paginated response with {@link
* @return all the attached data networks associated with a packet core data plane as paginated response with {@link
* PagedIterable}.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
PagedIterable<AttachedDataNetworkInner> listByPacketCoreDataPlane(
String resourceGroupName, String packetCoreControlPlaneName, String packetCoreDataPlaneName);

/**
* Gets all the data networks associated with a packet core data plane.
* Gets all the attached data networks associated with a packet core data plane.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param packetCoreControlPlaneName The name of the packet core control plane.
Expand All @@ -292,7 +292,7 @@ PagedIterable<AttachedDataNetworkInner> listByPacketCoreDataPlane(
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return all the data networks associated with a packet core data plane as paginated response with {@link
* @return all the attached data networks associated with a packet core data plane as paginated response with {@link
* PagedIterable}.
*/
@ServiceMethod(returns = ReturnType.COLLECTION)
Expand Down
Loading

0 comments on commit 64cf03a

Please sign in to comment.