Skip to content
This repository has been archived by the owner on Sep 16, 2023. It is now read-only.

Commit

Permalink
Browse files Browse the repository at this point in the history
chore: update gapic-generator-java to 0.0.20 (#300)
This PR was generated using Autosynth. 🌈

Synth log will be available here:
https://source.cloud.google.com/results/invocations/96c62e92-13ae-4f3c-9727-c854ec8b7488/targets

- [ ] To automatically regenerate this PR, check this box.

PiperOrigin-RevId: 357800868
Source-Link: googleapis/googleapis@e8bc447
PiperOrigin-RevId: 356341083
Source-Link: googleapis/googleapis@8d8c008
PiperOrigin-RevId: 355768415
Source-Link: googleapis/googleapis@bc89fd9
PiperOrigin-RevId: 355768365
Source-Link: googleapis/googleapis@bb17e41

build: change package name to correct name 
docs: generate sample code in the Java microgenerator
  • Loading branch information
yoshi-automation committed Feb 19, 2021
1 parent 8c273ea commit 399530b
Show file tree
Hide file tree
Showing 15 changed files with 2,206 additions and 42 deletions.
Expand Up @@ -32,6 +32,19 @@
* <p>This class provides the ability to make remote calls to the backing service through method
* calls that map to API methods. Sample code to get started:
*
* <pre>{@code
* try (LookupServiceClient lookupServiceClient = LookupServiceClient.create()) {
* ResolveServiceRequest request =
* ResolveServiceRequest.newBuilder()
* .setName(
* ServiceName.of("[PROJECT]", "[LOCATION]", "[NAMESPACE]", "[SERVICE]").toString())
* .setMaxEndpoints(2074789987)
* .setEndpointFilter("endpointFilter-1834249875")
* .build();
* ResolveServiceResponse response = lookupServiceClient.resolveService(request);
* }
* }</pre>
*
* <p>Note: close() needs to be called on the LookupServiceClient object to clean up resources such
* as threads. In the example above, try-with-resources is used, which automatically calls close().
*
Expand Down Expand Up @@ -136,6 +149,21 @@ public LookupServiceStub getStub() {
* Returns a [service][google.cloud.servicedirectory.v1.Service] and its associated endpoints.
* Resolving a service is not considered an active developer method.
*
* <p>Sample code:
*
* <pre>{@code
* try (LookupServiceClient lookupServiceClient = LookupServiceClient.create()) {
* ResolveServiceRequest request =
* ResolveServiceRequest.newBuilder()
* .setName(
* ServiceName.of("[PROJECT]", "[LOCATION]", "[NAMESPACE]", "[SERVICE]").toString())
* .setMaxEndpoints(2074789987)
* .setEndpointFilter("endpointFilter-1834249875")
* .build();
* ResolveServiceResponse response = lookupServiceClient.resolveService(request);
* }
* }</pre>
*
* @param request The request object containing all of the parameters for the API call.
* @throws com.google.api.gax.rpc.ApiException if the remote call fails
*/
Expand All @@ -149,6 +177,22 @@ public final ResolveServiceResponse resolveService(ResolveServiceRequest request
* Resolving a service is not considered an active developer method.
*
* <p>Sample code:
*
* <pre>{@code
* try (LookupServiceClient lookupServiceClient = LookupServiceClient.create()) {
* ResolveServiceRequest request =
* ResolveServiceRequest.newBuilder()
* .setName(
* ServiceName.of("[PROJECT]", "[LOCATION]", "[NAMESPACE]", "[SERVICE]").toString())
* .setMaxEndpoints(2074789987)
* .setEndpointFilter("endpointFilter-1834249875")
* .build();
* ApiFuture<ResolveServiceResponse> future =
* lookupServiceClient.resolveServiceCallable().futureCall(request);
* // Do something.
* ResolveServiceResponse response = future.get();
* }
* }</pre>
*/
public final UnaryCallable<ResolveServiceRequest, ResolveServiceResponse>
resolveServiceCallable() {
Expand Down

0 comments on commit 399530b

Please sign in to comment.