code: public PagedList<HubVirtualNetworkConnectionInner> list(final String resourceGroupName, final String virtualHubName) {
          ServiceResponse<Page<HubVirtualNetworkConnectionInner>> response = listSinglePageAsync(resourceGroupName, virtualHubName).toBlocking().single();
          return new PagedList<HubVirtualNetworkConnectionInner>(response.body()) {
              @Override
              public Page<HubVirtualNetworkConnectionInner> nextPage(String nextPageLink) {
                  return listNextSinglePageAsync(nextPageLink).toBlocking().single().body();
              }
          };
      }
docs: Retrieves the details of all HubVirtualNetworkConnections.
  
  @param resourceGroupName The resource group name of the VirtualHub.
  @param virtualHubName The name of the VirtualHub.
  @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;HubVirtualNetworkConnectionInner&gt; object if successful.