public Observable<ServiceResponse<Page<VirtualNetworkGatewayConnectionListEntityInner>>> listConnectionsWithServiceResponseAsync(final String resourceGroupName, final String virtualNetworkGatewayName) {
        return listConnectionsSinglePageAsync(resourceGroupName, virtualNetworkGatewayName)
            .concatMap(new Func1<ServiceResponse<Page<VirtualNetworkGatewayConnectionListEntityInner>>, Observable<ServiceResponse<Page<VirtualNetworkGatewayConnectionListEntityInner>>>>() {
                @Override
                public Observable<ServiceResponse<Page<VirtualNetworkGatewayConnectionListEntityInner>>> call(ServiceResponse<Page<VirtualNetworkGatewayConnectionListEntityInner>> page) {
                    String nextPageLink = page.body().nextPageLink();
                    if (nextPageLink == null) {
                        return Observable.just(page);
                    }
                    return Observable.just(page).concatWith(listConnectionsNextWithServiceResponseAsync(nextPageLink));
                }
            });
    }
public Observable < ServiceResponse < Page < VirtualNetworkGatewayConnectionListEntityInner > > > listConnectionsWithServiceResponseAsync ( final String resourceGroupName , final String virtualNetworkGatewayName ) { return listConnectionsSinglePageAsync ( resourceGroupName , virtualNetworkGatewayName ) . concatMap ( new Func1 < ServiceResponse < Page < VirtualNetworkGatewayConnectionListEntityInner > > , Observable < ServiceResponse < Page < VirtualNetworkGatewayConnectionListEntityInner > > > > ( ) { @ Override public Observable < ServiceResponse < Page < VirtualNetworkGatewayConnectionListEntityInner > > > call ( ServiceResponse < Page < VirtualNetworkGatewayConnectionListEntityInner > > page ) { String nextPageLink = page . body ( ) . nextPageLink ( ) ; if ( nextPageLink == null ) { return Observable . just ( page ) ; } return Observable . just ( page ) . concatWith ( listConnectionsNextWithServiceResponseAsync ( nextPageLink ) ) ; } } ) ; }
Gets all the connections in a virtual network gateway.

@param resourceGroupName The name of the resource group.
@param virtualNetworkGatewayName The name of the virtual network gateway.
@throws IllegalArgumentException thrown if parameters fail the validation
@return the observable to the PagedList&lt;VirtualNetworkGatewayConnectionListEntityInner&gt; object