Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
*/
public interface VpnConnection extends HasInner<VpnConnectionInner>, Indexable, Refreshable<VpnConnection>, Updatable<VpnConnection.Update>, HasManager<NetworkManager> {
/**
* @return the connectionBandwidthInMbps value.
* @return the connectionBandwidth value.
*/
Integer connectionBandwidthInMbps();
Integer connectionBandwidth();

/**
* @return the connectionStatus value.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,12 @@ public interface VpnConnections extends SupportsCreating<VpnConnection.Definitio
/**
* Retrieves all vpn connections for a particular virtual wan vpn gateway.
*
* @param resourceGroupName The resource group name of the VpnGateway.
* @param gatewayName The name of the gateway.
* @throws IllegalArgumentException thrown if parameters fail the validation
* @return the observable for the request
*/
Observable<VpnConnection> listByVpnGatewayAsync(final String gatewayName);
Observable<VpnConnection> listByVpnGatewayAsync(final String resourceGroupName, final String gatewayName);

/**
* Deletes a vpn connection.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ public boolean isInCreateMode() {


@Override
public Integer connectionBandwidthInMbps() {
return this.inner().connectionBandwidthInMbps();
public Integer connectionBandwidth() {
return this.inner().connectionBandwidth();
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ public class VpnConnectionInner extends Resource {
/**
* Expected bandwidth in MBPS.
*/
@JsonProperty(value = "properties.connectionBandwidthInMbps", access = JsonProperty.Access.WRITE_ONLY)
private Integer connectionBandwidthInMbps;
@JsonProperty(value = "properties.connectionBandwidth", access = JsonProperty.Access.WRITE_ONLY)
private Integer connectionBandwidth;

/**
* SharedKey for the vpn connection.
Expand Down Expand Up @@ -180,10 +180,10 @@ public Long egressBytesTransferred() {
/**
* Get expected bandwidth in MBPS.
*
* @return the connectionBandwidthInMbps value
* @return the connectionBandwidth value
*/
public Integer connectionBandwidthInMbps() {
return this.connectionBandwidthInMbps;
public Integer connectionBandwidth() {
return this.connectionBandwidth;
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ private VpnConnectionImpl wrapModel(String name) {
}

@Override
public Observable<VpnConnection> listByVpnGatewayAsync(final String gatewayName) {
public Observable<VpnConnection> listByVpnGatewayAsync(final String resourceGroupName, final String gatewayName) {
VpnConnectionsInner client = this.inner();
return client.listByVpnGatewayAsync(gatewayName)
return client.listByVpnGatewayAsync(resourceGroupName, gatewayName)
.flatMapIterable(new Func1<Page<VpnConnectionInner>, Iterable<VpnConnectionInner>>() {
@Override
public Iterable<VpnConnectionInner> call(Page<VpnConnectionInner> page) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ interface VpnConnectionsService {
Observable<Response<ResponseBody>> beginDelete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("gatewayName") String gatewayName, @Path("connectionName") String connectionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent);

@Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.network.v2018_04_01.VpnConnections listByVpnGateway" })
@GET("subscriptions/{subscriptionId}/providers/Microsoft.Network/vpnGateways/{gatewayName}/vpnConnections")
Observable<Response<ResponseBody>> listByVpnGateway(@Path("subscriptionId") String subscriptionId, @Path("gatewayName") String gatewayName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent);
@GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/vpnGateways/{gatewayName}/vpnConnections")
Observable<Response<ResponseBody>> listByVpnGateway(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("gatewayName") String gatewayName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent);

@Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.network.v2018_04_01.VpnConnections listByVpnGatewayNext" })
@GET
Expand Down Expand Up @@ -532,14 +532,15 @@ private ServiceResponse<Void> beginDeleteDelegate(Response<ResponseBody> respons
/**
* Retrieves all vpn connections for a particular virtual wan vpn gateway.
*
* @param resourceGroupName The resource group name of the VpnGateway.
* @param gatewayName The name of the gateway.
* @throws IllegalArgumentException thrown if parameters fail the validation
* @throws ErrorException thrown if the request is rejected by server
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent
* @return the PagedList&lt;VpnConnectionInner&gt; object if successful.
*/
public PagedList<VpnConnectionInner> listByVpnGateway(final String gatewayName) {
ServiceResponse<Page<VpnConnectionInner>> response = listByVpnGatewaySinglePageAsync(gatewayName).toBlocking().single();
public PagedList<VpnConnectionInner> listByVpnGateway(final String resourceGroupName, final String gatewayName) {
ServiceResponse<Page<VpnConnectionInner>> response = listByVpnGatewaySinglePageAsync(resourceGroupName, gatewayName).toBlocking().single();
return new PagedList<VpnConnectionInner>(response.body()) {
@Override
public Page<VpnConnectionInner> nextPage(String nextPageLink) {
Expand All @@ -551,14 +552,15 @@ public Page<VpnConnectionInner> nextPage(String nextPageLink) {
/**
* Retrieves all vpn connections for a particular virtual wan vpn gateway.
*
* @param resourceGroupName The resource group name of the VpnGateway.
* @param gatewayName The name of the gateway.
* @param serviceCallback the async ServiceCallback to handle successful and failed responses.
* @throws IllegalArgumentException thrown if parameters fail the validation
* @return the {@link ServiceFuture} object
*/
public ServiceFuture<List<VpnConnectionInner>> listByVpnGatewayAsync(final String gatewayName, final ListOperationCallback<VpnConnectionInner> serviceCallback) {
public ServiceFuture<List<VpnConnectionInner>> listByVpnGatewayAsync(final String resourceGroupName, final String gatewayName, final ListOperationCallback<VpnConnectionInner> serviceCallback) {
return AzureServiceFuture.fromPageResponse(
listByVpnGatewaySinglePageAsync(gatewayName),
listByVpnGatewaySinglePageAsync(resourceGroupName, gatewayName),
new Func1<String, Observable<ServiceResponse<Page<VpnConnectionInner>>>>() {
@Override
public Observable<ServiceResponse<Page<VpnConnectionInner>>> call(String nextPageLink) {
Expand All @@ -571,12 +573,13 @@ public Observable<ServiceResponse<Page<VpnConnectionInner>>> call(String nextPag
/**
* Retrieves all vpn connections for a particular virtual wan vpn gateway.
*
* @param resourceGroupName The resource group name of the VpnGateway.
* @param gatewayName The name of the gateway.
* @throws IllegalArgumentException thrown if parameters fail the validation
* @return the observable to the PagedList&lt;VpnConnectionInner&gt; object
*/
public Observable<Page<VpnConnectionInner>> listByVpnGatewayAsync(final String gatewayName) {
return listByVpnGatewayWithServiceResponseAsync(gatewayName)
public Observable<Page<VpnConnectionInner>> listByVpnGatewayAsync(final String resourceGroupName, final String gatewayName) {
return listByVpnGatewayWithServiceResponseAsync(resourceGroupName, gatewayName)
.map(new Func1<ServiceResponse<Page<VpnConnectionInner>>, Page<VpnConnectionInner>>() {
@Override
public Page<VpnConnectionInner> call(ServiceResponse<Page<VpnConnectionInner>> response) {
Expand All @@ -588,12 +591,13 @@ public Page<VpnConnectionInner> call(ServiceResponse<Page<VpnConnectionInner>> r
/**
* Retrieves all vpn connections for a particular virtual wan vpn gateway.
*
* @param resourceGroupName The resource group name of the VpnGateway.
* @param gatewayName The name of the gateway.
* @throws IllegalArgumentException thrown if parameters fail the validation
* @return the observable to the PagedList&lt;VpnConnectionInner&gt; object
*/
public Observable<ServiceResponse<Page<VpnConnectionInner>>> listByVpnGatewayWithServiceResponseAsync(final String gatewayName) {
return listByVpnGatewaySinglePageAsync(gatewayName)
public Observable<ServiceResponse<Page<VpnConnectionInner>>> listByVpnGatewayWithServiceResponseAsync(final String resourceGroupName, final String gatewayName) {
return listByVpnGatewaySinglePageAsync(resourceGroupName, gatewayName)
.concatMap(new Func1<ServiceResponse<Page<VpnConnectionInner>>, Observable<ServiceResponse<Page<VpnConnectionInner>>>>() {
@Override
public Observable<ServiceResponse<Page<VpnConnectionInner>>> call(ServiceResponse<Page<VpnConnectionInner>> page) {
Expand All @@ -609,19 +613,23 @@ public Observable<ServiceResponse<Page<VpnConnectionInner>>> call(ServiceRespons
/**
* Retrieves all vpn connections for a particular virtual wan vpn gateway.
*
ServiceResponse<PageImpl<VpnConnectionInner>> * @param resourceGroupName The resource group name of the VpnGateway.
ServiceResponse<PageImpl<VpnConnectionInner>> * @param gatewayName The name of the gateway.
* @throws IllegalArgumentException thrown if parameters fail the validation
* @return the PagedList&lt;VpnConnectionInner&gt; object wrapped in {@link ServiceResponse} if successful.
*/
public Observable<ServiceResponse<Page<VpnConnectionInner>>> listByVpnGatewaySinglePageAsync(final String gatewayName) {
public Observable<ServiceResponse<Page<VpnConnectionInner>>> listByVpnGatewaySinglePageAsync(final String resourceGroupName, final String gatewayName) {
if (this.client.subscriptionId() == null) {
throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null.");
}
if (resourceGroupName == null) {
throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.");
}
if (gatewayName == null) {
throw new IllegalArgumentException("Parameter gatewayName is required and cannot be null.");
}
final String apiVersion = "2018-04-01";
return service.listByVpnGateway(this.client.subscriptionId(), gatewayName, apiVersion, this.client.acceptLanguage(), this.client.userAgent())
return service.listByVpnGateway(this.client.subscriptionId(), resourceGroupName, gatewayName, apiVersion, this.client.acceptLanguage(), this.client.userAgent())
.flatMap(new Func1<Response<ResponseBody>, Observable<ServiceResponse<Page<VpnConnectionInner>>>>() {
@Override
public Observable<ServiceResponse<Page<VpnConnectionInner>>> call(Response<ResponseBody> response) {
Expand Down
133 changes: 133 additions & 0 deletions network/resource-manager/v2018_06_01/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
<!--
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.microsoft.azure.network.v2018_06_01</groupId>
<parent>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-arm-parent</artifactId>
<version>0.0.2-beta</version>
<relativePath>../../../pom.xml</relativePath>
</parent>
<artifactId>azure-mgmt-network</artifactId>
<version>1.0.0-beta</version>
<packaging>jar</packaging>
<name>Microsoft Azure SDK for Network Management</name>
<description>This package contains Microsoft Network Management SDK.</description>
<url>https://github.com/Azure/azure-libraries-for-java</url>
<licenses>
<license>
<name>The MIT License (MIT)</name>
<url>http://opensource.org/licenses/MIT</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<url>scm:git:https://github.com/Azure/azure-libraries-for-java</url>
<connection>scm:git:[email protected]:Azure/azure-libraries-for-java.git</connection>
<tag>HEAD</tag>
</scm>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<legal><![CDATA[[INFO] Any downloads listed may be third party software. Microsoft grants you no rights for third party software.]]></legal>
</properties>
<developers>
<developer>
<id>microsoft</id>
<name>Microsoft</name>
</developer>
</developers>
<dependencies>
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-client-runtime</artifactId>
</dependency>
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-arm-client-runtime</artifactId>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-client-authentication</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-mgmt-resources</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.microsoft.azure</groupId>
<artifactId>azure-arm-client-runtime</artifactId>
<type>test-jar</type>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
<addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
<annotationProcessors>
<annotationProcessor>
com.microsoft.azure.management.apigeneration.LangDefinitionProcessor
</annotationProcessor>
</annotationProcessors>
<debug>true</debug>
<optimize>true</optimize>
<compilerArguments>
<AaddGeneratedAnnotation>true</AaddGeneratedAnnotation>
<Adebug>true</Adebug>
</compilerArguments>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.8</version>
<configuration>
<excludePackageNames>*.implementation.*;*.utils.*;com.microsoft.schemas._2003._10.serialization;*.blob.core.search</excludePackageNames>
<bottom>
<![CDATA[<code>
/**
<br />* Copyright (c) Microsoft Corporation. All rights reserved.
<br />* Licensed under the MIT License. See License.txt in the project root for
<br />* license information.
<br />*/
</code>]]>
</bottom>
</configuration>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/**
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
*/

package com.microsoft.azure.management.network.v2018_06_01;

import java.util.Collection;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.microsoft.rest.ExpandableStringEnum;

/**
* Defines values for Access.
*/
public final class Access extends ExpandableStringEnum<Access> {
/** Static value Allow for Access. */
public static final Access ALLOW = fromString("Allow");

/** Static value Deny for Access. */
public static final Access DENY = fromString("Deny");

/**
* Creates or finds a Access from its string representation.
* @param name a name to look for
* @return the corresponding Access
*/
@JsonCreator
public static Access fromString(String name) {
return fromString(name, Access.class);
}

/**
* @return known Access values
*/
public static Collection<Access> values() {
return values(Access.class);
}
}
Loading