public final FetchNetworkPolicyExternalAddressesPagedResponse fetchNetworkPolicyExternalAddresses(
      String networkPolicy) {
    FetchNetworkPolicyExternalAddressesRequest request =
        FetchNetworkPolicyExternalAddressesRequest.newBuilder()
            .setNetworkPolicy(networkPolicy)
            .build();
    return fetchNetworkPolicyExternalAddresses(request);
  }
Lists external IP addresses assigned to VMware workload VMs within the scope of the given
network policy.

<p>Sample code:

<pre>{@code
// This snippet has been automatically generated and should be regarded as a code template only.
// It will require modifications to work:
// - It may require correct/in-range values for request initialization.
// - It may require specifying regional endpoints when creating the service client as shown in
// https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
try (VmwareEngineClient vmwareEngineClient = VmwareEngineClient.create()) {
  String networkPolicy =
      NetworkPolicyName.of("[PROJECT]", "[LOCATION]", "[NETWORK_POLICY]").toString();
  for (ExternalAddress element :
      vmwareEngineClient.fetchNetworkPolicyExternalAddresses(networkPolicy).iterateAll()) {
    // doThingsWith(element);
  }
}
}</pre>

@param networkPolicy Required. The resource name of the network policy to query for assigned
    external IP addresses. Resource names are schemeless URIs that follow the conventions in
    https://cloud.google.com/apis/design/resource_names. For example:
    `projects/my-project/locations/us-central1/networkPolicies/my-policy`
@throws com.google.api.gax.rpc.ApiException if the remote call fails
java-vmwareengine/google-cloud-vmwareengine/src/main/java/com/google/cloud/vmwareengine/v1/VmwareEngineClient.java