• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright 2022 Google LLC
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      https://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package com.google.cloud.compute.v1;
18 
19 import com.google.api.core.ApiFuture;
20 import com.google.api.core.ApiFutures;
21 import com.google.api.core.BetaApi;
22 import com.google.api.gax.core.BackgroundResource;
23 import com.google.api.gax.longrunning.OperationFuture;
24 import com.google.api.gax.paging.AbstractFixedSizeCollection;
25 import com.google.api.gax.paging.AbstractPage;
26 import com.google.api.gax.paging.AbstractPagedListResponse;
27 import com.google.api.gax.rpc.OperationCallable;
28 import com.google.api.gax.rpc.PageContext;
29 import com.google.api.gax.rpc.UnaryCallable;
30 import com.google.cloud.compute.v1.stub.TargetHttpsProxiesStub;
31 import com.google.cloud.compute.v1.stub.TargetHttpsProxiesStubSettings;
32 import com.google.common.util.concurrent.MoreExecutors;
33 import java.io.IOException;
34 import java.util.List;
35 import java.util.Map;
36 import java.util.concurrent.TimeUnit;
37 import javax.annotation.Generated;
38 
39 // AUTO-GENERATED DOCUMENTATION AND CLASS.
40 /**
41  * Service Description: The TargetHttpsProxies API.
42  *
43  * <p>This class provides the ability to make remote calls to the backing service through method
44  * calls that map to API methods. Sample code to get started:
45  *
46  * <pre>{@code
47  * // This snippet has been automatically generated and should be regarded as a code template only.
48  * // It will require modifications to work:
49  * // - It may require correct/in-range values for request initialization.
50  * // - It may require specifying regional endpoints when creating the service client as shown in
51  * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
52  * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
53  *   String project = "project-309310695";
54  *   String targetHttpsProxy = "targetHttpsProxy833943732";
55  *   TargetHttpsProxy response = targetHttpsProxiesClient.get(project, targetHttpsProxy);
56  * }
57  * }</pre>
58  *
59  * <p>Note: close() needs to be called on the TargetHttpsProxiesClient object to clean up resources
60  * such as threads. In the example above, try-with-resources is used, which automatically calls
61  * close().
62  *
63  * <p>The surface of this class includes several types of Java methods for each of the API's
64  * methods:
65  *
66  * <ol>
67  *   <li>A "flattened" method. With this type of method, the fields of the request type have been
68  *       converted into function parameters. It may be the case that not all fields are available as
69  *       parameters, and not every API method will have a flattened method entry point.
70  *   <li>A "request object" method. This type of method only takes one parameter, a request object,
71  *       which must be constructed before the call. Not every API method will have a request object
72  *       method.
73  *   <li>A "callable" method. This type of method takes no parameters and returns an immutable API
74  *       callable object, which can be used to initiate calls to the service.
75  * </ol>
76  *
77  * <p>See the individual methods for example code.
78  *
79  * <p>Many parameters require resource names to be formatted in a particular way. To assist with
80  * these names, this class includes a format method for each type of name, and additionally a parse
81  * method to extract the individual identifiers contained within names that are returned.
82  *
83  * <p>This class can be customized by passing in a custom instance of TargetHttpsProxiesSettings to
84  * create(). For example:
85  *
86  * <p>To customize credentials:
87  *
88  * <pre>{@code
89  * // This snippet has been automatically generated and should be regarded as a code template only.
90  * // It will require modifications to work:
91  * // - It may require correct/in-range values for request initialization.
92  * // - It may require specifying regional endpoints when creating the service client as shown in
93  * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
94  * TargetHttpsProxiesSettings targetHttpsProxiesSettings =
95  *     TargetHttpsProxiesSettings.newBuilder()
96  *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
97  *         .build();
98  * TargetHttpsProxiesClient targetHttpsProxiesClient =
99  *     TargetHttpsProxiesClient.create(targetHttpsProxiesSettings);
100  * }</pre>
101  *
102  * <p>To customize the endpoint:
103  *
104  * <pre>{@code
105  * // This snippet has been automatically generated and should be regarded as a code template only.
106  * // It will require modifications to work:
107  * // - It may require correct/in-range values for request initialization.
108  * // - It may require specifying regional endpoints when creating the service client as shown in
109  * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
110  * TargetHttpsProxiesSettings targetHttpsProxiesSettings =
111  *     TargetHttpsProxiesSettings.newBuilder().setEndpoint(myEndpoint).build();
112  * TargetHttpsProxiesClient targetHttpsProxiesClient =
113  *     TargetHttpsProxiesClient.create(targetHttpsProxiesSettings);
114  * }</pre>
115  *
116  * <p>Please refer to the GitHub repository's samples for more quickstart code snippets.
117  */
118 @Generated("by gapic-generator-java")
119 public class TargetHttpsProxiesClient implements BackgroundResource {
120   private final TargetHttpsProxiesSettings settings;
121   private final TargetHttpsProxiesStub stub;
122 
123   /** Constructs an instance of TargetHttpsProxiesClient with default settings. */
create()124   public static final TargetHttpsProxiesClient create() throws IOException {
125     return create(TargetHttpsProxiesSettings.newBuilder().build());
126   }
127 
128   /**
129    * Constructs an instance of TargetHttpsProxiesClient, using the given settings. The channels are
130    * created based on the settings passed in, or defaults for any settings that are not set.
131    */
create(TargetHttpsProxiesSettings settings)132   public static final TargetHttpsProxiesClient create(TargetHttpsProxiesSettings settings)
133       throws IOException {
134     return new TargetHttpsProxiesClient(settings);
135   }
136 
137   /**
138    * Constructs an instance of TargetHttpsProxiesClient, using the given stub for making calls. This
139    * is for advanced usage - prefer using create(TargetHttpsProxiesSettings).
140    */
create(TargetHttpsProxiesStub stub)141   public static final TargetHttpsProxiesClient create(TargetHttpsProxiesStub stub) {
142     return new TargetHttpsProxiesClient(stub);
143   }
144 
145   /**
146    * Constructs an instance of TargetHttpsProxiesClient, using the given settings. This is protected
147    * so that it is easy to make a subclass, but otherwise, the static factory methods should be
148    * preferred.
149    */
TargetHttpsProxiesClient(TargetHttpsProxiesSettings settings)150   protected TargetHttpsProxiesClient(TargetHttpsProxiesSettings settings) throws IOException {
151     this.settings = settings;
152     this.stub = ((TargetHttpsProxiesStubSettings) settings.getStubSettings()).createStub();
153   }
154 
TargetHttpsProxiesClient(TargetHttpsProxiesStub stub)155   protected TargetHttpsProxiesClient(TargetHttpsProxiesStub stub) {
156     this.settings = null;
157     this.stub = stub;
158   }
159 
getSettings()160   public final TargetHttpsProxiesSettings getSettings() {
161     return settings;
162   }
163 
getStub()164   public TargetHttpsProxiesStub getStub() {
165     return stub;
166   }
167 
168   // AUTO-GENERATED DOCUMENTATION AND METHOD.
169   /**
170    * Retrieves the list of all TargetHttpsProxy resources, regional and global, available to the
171    * specified project.
172    *
173    * <p>Sample code:
174    *
175    * <pre>{@code
176    * // This snippet has been automatically generated and should be regarded as a code template only.
177    * // It will require modifications to work:
178    * // - It may require correct/in-range values for request initialization.
179    * // - It may require specifying regional endpoints when creating the service client as shown in
180    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
181    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
182    *   String project = "project-309310695";
183    *   for (Map.Entry<String, TargetHttpsProxiesScopedList> element :
184    *       targetHttpsProxiesClient.aggregatedList(project).iterateAll()) {
185    *     // doThingsWith(element);
186    *   }
187    * }
188    * }</pre>
189    *
190    * @param project Name of the project scoping this request.
191    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
192    */
aggregatedList(String project)193   public final AggregatedListPagedResponse aggregatedList(String project) {
194     AggregatedListTargetHttpsProxiesRequest request =
195         AggregatedListTargetHttpsProxiesRequest.newBuilder().setProject(project).build();
196     return aggregatedList(request);
197   }
198 
199   // AUTO-GENERATED DOCUMENTATION AND METHOD.
200   /**
201    * Retrieves the list of all TargetHttpsProxy resources, regional and global, available to the
202    * specified project.
203    *
204    * <p>Sample code:
205    *
206    * <pre>{@code
207    * // This snippet has been automatically generated and should be regarded as a code template only.
208    * // It will require modifications to work:
209    * // - It may require correct/in-range values for request initialization.
210    * // - It may require specifying regional endpoints when creating the service client as shown in
211    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
212    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
213    *   AggregatedListTargetHttpsProxiesRequest request =
214    *       AggregatedListTargetHttpsProxiesRequest.newBuilder()
215    *           .setFilter("filter-1274492040")
216    *           .setIncludeAllScopes(true)
217    *           .setMaxResults(1128457243)
218    *           .setOrderBy("orderBy-1207110587")
219    *           .setPageToken("pageToken873572522")
220    *           .setProject("project-309310695")
221    *           .setReturnPartialSuccess(true)
222    *           .build();
223    *   for (Map.Entry<String, TargetHttpsProxiesScopedList> element :
224    *       targetHttpsProxiesClient.aggregatedList(request).iterateAll()) {
225    *     // doThingsWith(element);
226    *   }
227    * }
228    * }</pre>
229    *
230    * @param request The request object containing all of the parameters for the API call.
231    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
232    */
aggregatedList( AggregatedListTargetHttpsProxiesRequest request)233   public final AggregatedListPagedResponse aggregatedList(
234       AggregatedListTargetHttpsProxiesRequest request) {
235     return aggregatedListPagedCallable().call(request);
236   }
237 
238   // AUTO-GENERATED DOCUMENTATION AND METHOD.
239   /**
240    * Retrieves the list of all TargetHttpsProxy resources, regional and global, available to the
241    * specified project.
242    *
243    * <p>Sample code:
244    *
245    * <pre>{@code
246    * // This snippet has been automatically generated and should be regarded as a code template only.
247    * // It will require modifications to work:
248    * // - It may require correct/in-range values for request initialization.
249    * // - It may require specifying regional endpoints when creating the service client as shown in
250    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
251    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
252    *   AggregatedListTargetHttpsProxiesRequest request =
253    *       AggregatedListTargetHttpsProxiesRequest.newBuilder()
254    *           .setFilter("filter-1274492040")
255    *           .setIncludeAllScopes(true)
256    *           .setMaxResults(1128457243)
257    *           .setOrderBy("orderBy-1207110587")
258    *           .setPageToken("pageToken873572522")
259    *           .setProject("project-309310695")
260    *           .setReturnPartialSuccess(true)
261    *           .build();
262    *   ApiFuture<Map.Entry<String, TargetHttpsProxiesScopedList>> future =
263    *       targetHttpsProxiesClient.aggregatedListPagedCallable().futureCall(request);
264    *   // Do something.
265    *   for (Map.Entry<String, TargetHttpsProxiesScopedList> element : future.get().iterateAll()) {
266    *     // doThingsWith(element);
267    *   }
268    * }
269    * }</pre>
270    */
271   public final UnaryCallable<AggregatedListTargetHttpsProxiesRequest, AggregatedListPagedResponse>
aggregatedListPagedCallable()272       aggregatedListPagedCallable() {
273     return stub.aggregatedListPagedCallable();
274   }
275 
276   // AUTO-GENERATED DOCUMENTATION AND METHOD.
277   /**
278    * Retrieves the list of all TargetHttpsProxy resources, regional and global, available to the
279    * specified project.
280    *
281    * <p>Sample code:
282    *
283    * <pre>{@code
284    * // This snippet has been automatically generated and should be regarded as a code template only.
285    * // It will require modifications to work:
286    * // - It may require correct/in-range values for request initialization.
287    * // - It may require specifying regional endpoints when creating the service client as shown in
288    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
289    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
290    *   AggregatedListTargetHttpsProxiesRequest request =
291    *       AggregatedListTargetHttpsProxiesRequest.newBuilder()
292    *           .setFilter("filter-1274492040")
293    *           .setIncludeAllScopes(true)
294    *           .setMaxResults(1128457243)
295    *           .setOrderBy("orderBy-1207110587")
296    *           .setPageToken("pageToken873572522")
297    *           .setProject("project-309310695")
298    *           .setReturnPartialSuccess(true)
299    *           .build();
300    *   while (true) {
301    *     TargetHttpsProxyAggregatedList response =
302    *         targetHttpsProxiesClient.aggregatedListCallable().call(request);
303    *     for (Map.Entry<String, TargetHttpsProxiesScopedList> element : response.getItemsList()) {
304    *       // doThingsWith(element);
305    *     }
306    *     String nextPageToken = response.getNextPageToken();
307    *     if (!Strings.isNullOrEmpty(nextPageToken)) {
308    *       request = request.toBuilder().setPageToken(nextPageToken).build();
309    *     } else {
310    *       break;
311    *     }
312    *   }
313    * }
314    * }</pre>
315    */
316   public final UnaryCallable<
317           AggregatedListTargetHttpsProxiesRequest, TargetHttpsProxyAggregatedList>
aggregatedListCallable()318       aggregatedListCallable() {
319     return stub.aggregatedListCallable();
320   }
321 
322   // AUTO-GENERATED DOCUMENTATION AND METHOD.
323   /**
324    * Deletes the specified TargetHttpsProxy resource.
325    *
326    * <p>Sample code:
327    *
328    * <pre>{@code
329    * // This snippet has been automatically generated and should be regarded as a code template only.
330    * // It will require modifications to work:
331    * // - It may require correct/in-range values for request initialization.
332    * // - It may require specifying regional endpoints when creating the service client as shown in
333    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
334    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
335    *   String project = "project-309310695";
336    *   String targetHttpsProxy = "targetHttpsProxy833943732";
337    *   Operation response = targetHttpsProxiesClient.deleteAsync(project, targetHttpsProxy).get();
338    * }
339    * }</pre>
340    *
341    * @param project Project ID for this request.
342    * @param targetHttpsProxy Name of the TargetHttpsProxy resource to delete.
343    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
344    */
deleteAsync( String project, String targetHttpsProxy)345   public final OperationFuture<Operation, Operation> deleteAsync(
346       String project, String targetHttpsProxy) {
347     DeleteTargetHttpsProxyRequest request =
348         DeleteTargetHttpsProxyRequest.newBuilder()
349             .setProject(project)
350             .setTargetHttpsProxy(targetHttpsProxy)
351             .build();
352     return deleteAsync(request);
353   }
354 
355   // AUTO-GENERATED DOCUMENTATION AND METHOD.
356   /**
357    * Deletes the specified TargetHttpsProxy resource.
358    *
359    * <p>Sample code:
360    *
361    * <pre>{@code
362    * // This snippet has been automatically generated and should be regarded as a code template only.
363    * // It will require modifications to work:
364    * // - It may require correct/in-range values for request initialization.
365    * // - It may require specifying regional endpoints when creating the service client as shown in
366    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
367    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
368    *   DeleteTargetHttpsProxyRequest request =
369    *       DeleteTargetHttpsProxyRequest.newBuilder()
370    *           .setProject("project-309310695")
371    *           .setRequestId("requestId693933066")
372    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
373    *           .build();
374    *   Operation response = targetHttpsProxiesClient.deleteAsync(request).get();
375    * }
376    * }</pre>
377    *
378    * @param request The request object containing all of the parameters for the API call.
379    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
380    */
381   @BetaApi(
382       "The surface for long-running operations is not stable yet and may change in the future.")
deleteAsync( DeleteTargetHttpsProxyRequest request)383   public final OperationFuture<Operation, Operation> deleteAsync(
384       DeleteTargetHttpsProxyRequest request) {
385     return deleteOperationCallable().futureCall(request);
386   }
387 
388   // AUTO-GENERATED DOCUMENTATION AND METHOD.
389   /**
390    * Deletes the specified TargetHttpsProxy resource.
391    *
392    * <p>Sample code:
393    *
394    * <pre>{@code
395    * // This snippet has been automatically generated and should be regarded as a code template only.
396    * // It will require modifications to work:
397    * // - It may require correct/in-range values for request initialization.
398    * // - It may require specifying regional endpoints when creating the service client as shown in
399    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
400    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
401    *   DeleteTargetHttpsProxyRequest request =
402    *       DeleteTargetHttpsProxyRequest.newBuilder()
403    *           .setProject("project-309310695")
404    *           .setRequestId("requestId693933066")
405    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
406    *           .build();
407    *   OperationFuture<Operation, Operation> future =
408    *       targetHttpsProxiesClient.deleteOperationCallable().futureCall(request);
409    *   // Do something.
410    *   Operation response = future.get();
411    * }
412    * }</pre>
413    */
414   public final OperationCallable<DeleteTargetHttpsProxyRequest, Operation, Operation>
deleteOperationCallable()415       deleteOperationCallable() {
416     return stub.deleteOperationCallable();
417   }
418 
419   // AUTO-GENERATED DOCUMENTATION AND METHOD.
420   /**
421    * Deletes the specified TargetHttpsProxy resource.
422    *
423    * <p>Sample code:
424    *
425    * <pre>{@code
426    * // This snippet has been automatically generated and should be regarded as a code template only.
427    * // It will require modifications to work:
428    * // - It may require correct/in-range values for request initialization.
429    * // - It may require specifying regional endpoints when creating the service client as shown in
430    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
431    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
432    *   DeleteTargetHttpsProxyRequest request =
433    *       DeleteTargetHttpsProxyRequest.newBuilder()
434    *           .setProject("project-309310695")
435    *           .setRequestId("requestId693933066")
436    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
437    *           .build();
438    *   ApiFuture<Operation> future = targetHttpsProxiesClient.deleteCallable().futureCall(request);
439    *   // Do something.
440    *   Operation response = future.get();
441    * }
442    * }</pre>
443    */
deleteCallable()444   public final UnaryCallable<DeleteTargetHttpsProxyRequest, Operation> deleteCallable() {
445     return stub.deleteCallable();
446   }
447 
448   // AUTO-GENERATED DOCUMENTATION AND METHOD.
449   /**
450    * Returns the specified TargetHttpsProxy resource.
451    *
452    * <p>Sample code:
453    *
454    * <pre>{@code
455    * // This snippet has been automatically generated and should be regarded as a code template only.
456    * // It will require modifications to work:
457    * // - It may require correct/in-range values for request initialization.
458    * // - It may require specifying regional endpoints when creating the service client as shown in
459    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
460    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
461    *   String project = "project-309310695";
462    *   String targetHttpsProxy = "targetHttpsProxy833943732";
463    *   TargetHttpsProxy response = targetHttpsProxiesClient.get(project, targetHttpsProxy);
464    * }
465    * }</pre>
466    *
467    * @param project Project ID for this request.
468    * @param targetHttpsProxy Name of the TargetHttpsProxy resource to return.
469    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
470    */
get(String project, String targetHttpsProxy)471   public final TargetHttpsProxy get(String project, String targetHttpsProxy) {
472     GetTargetHttpsProxyRequest request =
473         GetTargetHttpsProxyRequest.newBuilder()
474             .setProject(project)
475             .setTargetHttpsProxy(targetHttpsProxy)
476             .build();
477     return get(request);
478   }
479 
480   // AUTO-GENERATED DOCUMENTATION AND METHOD.
481   /**
482    * Returns the specified TargetHttpsProxy resource.
483    *
484    * <p>Sample code:
485    *
486    * <pre>{@code
487    * // This snippet has been automatically generated and should be regarded as a code template only.
488    * // It will require modifications to work:
489    * // - It may require correct/in-range values for request initialization.
490    * // - It may require specifying regional endpoints when creating the service client as shown in
491    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
492    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
493    *   GetTargetHttpsProxyRequest request =
494    *       GetTargetHttpsProxyRequest.newBuilder()
495    *           .setProject("project-309310695")
496    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
497    *           .build();
498    *   TargetHttpsProxy response = targetHttpsProxiesClient.get(request);
499    * }
500    * }</pre>
501    *
502    * @param request The request object containing all of the parameters for the API call.
503    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
504    */
get(GetTargetHttpsProxyRequest request)505   public final TargetHttpsProxy get(GetTargetHttpsProxyRequest request) {
506     return getCallable().call(request);
507   }
508 
509   // AUTO-GENERATED DOCUMENTATION AND METHOD.
510   /**
511    * Returns the specified TargetHttpsProxy resource.
512    *
513    * <p>Sample code:
514    *
515    * <pre>{@code
516    * // This snippet has been automatically generated and should be regarded as a code template only.
517    * // It will require modifications to work:
518    * // - It may require correct/in-range values for request initialization.
519    * // - It may require specifying regional endpoints when creating the service client as shown in
520    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
521    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
522    *   GetTargetHttpsProxyRequest request =
523    *       GetTargetHttpsProxyRequest.newBuilder()
524    *           .setProject("project-309310695")
525    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
526    *           .build();
527    *   ApiFuture<TargetHttpsProxy> future =
528    *       targetHttpsProxiesClient.getCallable().futureCall(request);
529    *   // Do something.
530    *   TargetHttpsProxy response = future.get();
531    * }
532    * }</pre>
533    */
getCallable()534   public final UnaryCallable<GetTargetHttpsProxyRequest, TargetHttpsProxy> getCallable() {
535     return stub.getCallable();
536   }
537 
538   // AUTO-GENERATED DOCUMENTATION AND METHOD.
539   /**
540    * Creates a TargetHttpsProxy resource in the specified project using the data included in the
541    * request.
542    *
543    * <p>Sample code:
544    *
545    * <pre>{@code
546    * // This snippet has been automatically generated and should be regarded as a code template only.
547    * // It will require modifications to work:
548    * // - It may require correct/in-range values for request initialization.
549    * // - It may require specifying regional endpoints when creating the service client as shown in
550    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
551    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
552    *   String project = "project-309310695";
553    *   TargetHttpsProxy targetHttpsProxyResource = TargetHttpsProxy.newBuilder().build();
554    *   Operation response =
555    *       targetHttpsProxiesClient.insertAsync(project, targetHttpsProxyResource).get();
556    * }
557    * }</pre>
558    *
559    * @param project Project ID for this request.
560    * @param targetHttpsProxyResource The body resource for this request
561    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
562    */
insertAsync( String project, TargetHttpsProxy targetHttpsProxyResource)563   public final OperationFuture<Operation, Operation> insertAsync(
564       String project, TargetHttpsProxy targetHttpsProxyResource) {
565     InsertTargetHttpsProxyRequest request =
566         InsertTargetHttpsProxyRequest.newBuilder()
567             .setProject(project)
568             .setTargetHttpsProxyResource(targetHttpsProxyResource)
569             .build();
570     return insertAsync(request);
571   }
572 
573   // AUTO-GENERATED DOCUMENTATION AND METHOD.
574   /**
575    * Creates a TargetHttpsProxy resource in the specified project using the data included in the
576    * request.
577    *
578    * <p>Sample code:
579    *
580    * <pre>{@code
581    * // This snippet has been automatically generated and should be regarded as a code template only.
582    * // It will require modifications to work:
583    * // - It may require correct/in-range values for request initialization.
584    * // - It may require specifying regional endpoints when creating the service client as shown in
585    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
586    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
587    *   InsertTargetHttpsProxyRequest request =
588    *       InsertTargetHttpsProxyRequest.newBuilder()
589    *           .setProject("project-309310695")
590    *           .setRequestId("requestId693933066")
591    *           .setTargetHttpsProxyResource(TargetHttpsProxy.newBuilder().build())
592    *           .build();
593    *   Operation response = targetHttpsProxiesClient.insertAsync(request).get();
594    * }
595    * }</pre>
596    *
597    * @param request The request object containing all of the parameters for the API call.
598    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
599    */
600   @BetaApi(
601       "The surface for long-running operations is not stable yet and may change in the future.")
insertAsync( InsertTargetHttpsProxyRequest request)602   public final OperationFuture<Operation, Operation> insertAsync(
603       InsertTargetHttpsProxyRequest request) {
604     return insertOperationCallable().futureCall(request);
605   }
606 
607   // AUTO-GENERATED DOCUMENTATION AND METHOD.
608   /**
609    * Creates a TargetHttpsProxy resource in the specified project using the data included in the
610    * request.
611    *
612    * <p>Sample code:
613    *
614    * <pre>{@code
615    * // This snippet has been automatically generated and should be regarded as a code template only.
616    * // It will require modifications to work:
617    * // - It may require correct/in-range values for request initialization.
618    * // - It may require specifying regional endpoints when creating the service client as shown in
619    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
620    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
621    *   InsertTargetHttpsProxyRequest request =
622    *       InsertTargetHttpsProxyRequest.newBuilder()
623    *           .setProject("project-309310695")
624    *           .setRequestId("requestId693933066")
625    *           .setTargetHttpsProxyResource(TargetHttpsProxy.newBuilder().build())
626    *           .build();
627    *   OperationFuture<Operation, Operation> future =
628    *       targetHttpsProxiesClient.insertOperationCallable().futureCall(request);
629    *   // Do something.
630    *   Operation response = future.get();
631    * }
632    * }</pre>
633    */
634   public final OperationCallable<InsertTargetHttpsProxyRequest, Operation, Operation>
insertOperationCallable()635       insertOperationCallable() {
636     return stub.insertOperationCallable();
637   }
638 
639   // AUTO-GENERATED DOCUMENTATION AND METHOD.
640   /**
641    * Creates a TargetHttpsProxy resource in the specified project using the data included in the
642    * request.
643    *
644    * <p>Sample code:
645    *
646    * <pre>{@code
647    * // This snippet has been automatically generated and should be regarded as a code template only.
648    * // It will require modifications to work:
649    * // - It may require correct/in-range values for request initialization.
650    * // - It may require specifying regional endpoints when creating the service client as shown in
651    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
652    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
653    *   InsertTargetHttpsProxyRequest request =
654    *       InsertTargetHttpsProxyRequest.newBuilder()
655    *           .setProject("project-309310695")
656    *           .setRequestId("requestId693933066")
657    *           .setTargetHttpsProxyResource(TargetHttpsProxy.newBuilder().build())
658    *           .build();
659    *   ApiFuture<Operation> future = targetHttpsProxiesClient.insertCallable().futureCall(request);
660    *   // Do something.
661    *   Operation response = future.get();
662    * }
663    * }</pre>
664    */
insertCallable()665   public final UnaryCallable<InsertTargetHttpsProxyRequest, Operation> insertCallable() {
666     return stub.insertCallable();
667   }
668 
669   // AUTO-GENERATED DOCUMENTATION AND METHOD.
670   /**
671    * Retrieves the list of TargetHttpsProxy resources available to the specified project.
672    *
673    * <p>Sample code:
674    *
675    * <pre>{@code
676    * // This snippet has been automatically generated and should be regarded as a code template only.
677    * // It will require modifications to work:
678    * // - It may require correct/in-range values for request initialization.
679    * // - It may require specifying regional endpoints when creating the service client as shown in
680    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
681    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
682    *   String project = "project-309310695";
683    *   for (TargetHttpsProxy element : targetHttpsProxiesClient.list(project).iterateAll()) {
684    *     // doThingsWith(element);
685    *   }
686    * }
687    * }</pre>
688    *
689    * @param project Project ID for this request.
690    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
691    */
list(String project)692   public final ListPagedResponse list(String project) {
693     ListTargetHttpsProxiesRequest request =
694         ListTargetHttpsProxiesRequest.newBuilder().setProject(project).build();
695     return list(request);
696   }
697 
698   // AUTO-GENERATED DOCUMENTATION AND METHOD.
699   /**
700    * Retrieves the list of TargetHttpsProxy resources available to the specified project.
701    *
702    * <p>Sample code:
703    *
704    * <pre>{@code
705    * // This snippet has been automatically generated and should be regarded as a code template only.
706    * // It will require modifications to work:
707    * // - It may require correct/in-range values for request initialization.
708    * // - It may require specifying regional endpoints when creating the service client as shown in
709    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
710    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
711    *   ListTargetHttpsProxiesRequest request =
712    *       ListTargetHttpsProxiesRequest.newBuilder()
713    *           .setFilter("filter-1274492040")
714    *           .setMaxResults(1128457243)
715    *           .setOrderBy("orderBy-1207110587")
716    *           .setPageToken("pageToken873572522")
717    *           .setProject("project-309310695")
718    *           .setReturnPartialSuccess(true)
719    *           .build();
720    *   for (TargetHttpsProxy element : targetHttpsProxiesClient.list(request).iterateAll()) {
721    *     // doThingsWith(element);
722    *   }
723    * }
724    * }</pre>
725    *
726    * @param request The request object containing all of the parameters for the API call.
727    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
728    */
list(ListTargetHttpsProxiesRequest request)729   public final ListPagedResponse list(ListTargetHttpsProxiesRequest request) {
730     return listPagedCallable().call(request);
731   }
732 
733   // AUTO-GENERATED DOCUMENTATION AND METHOD.
734   /**
735    * Retrieves the list of TargetHttpsProxy resources available to the specified project.
736    *
737    * <p>Sample code:
738    *
739    * <pre>{@code
740    * // This snippet has been automatically generated and should be regarded as a code template only.
741    * // It will require modifications to work:
742    * // - It may require correct/in-range values for request initialization.
743    * // - It may require specifying regional endpoints when creating the service client as shown in
744    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
745    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
746    *   ListTargetHttpsProxiesRequest request =
747    *       ListTargetHttpsProxiesRequest.newBuilder()
748    *           .setFilter("filter-1274492040")
749    *           .setMaxResults(1128457243)
750    *           .setOrderBy("orderBy-1207110587")
751    *           .setPageToken("pageToken873572522")
752    *           .setProject("project-309310695")
753    *           .setReturnPartialSuccess(true)
754    *           .build();
755    *   ApiFuture<TargetHttpsProxy> future =
756    *       targetHttpsProxiesClient.listPagedCallable().futureCall(request);
757    *   // Do something.
758    *   for (TargetHttpsProxy element : future.get().iterateAll()) {
759    *     // doThingsWith(element);
760    *   }
761    * }
762    * }</pre>
763    */
listPagedCallable()764   public final UnaryCallable<ListTargetHttpsProxiesRequest, ListPagedResponse> listPagedCallable() {
765     return stub.listPagedCallable();
766   }
767 
768   // AUTO-GENERATED DOCUMENTATION AND METHOD.
769   /**
770    * Retrieves the list of TargetHttpsProxy resources available to the specified project.
771    *
772    * <p>Sample code:
773    *
774    * <pre>{@code
775    * // This snippet has been automatically generated and should be regarded as a code template only.
776    * // It will require modifications to work:
777    * // - It may require correct/in-range values for request initialization.
778    * // - It may require specifying regional endpoints when creating the service client as shown in
779    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
780    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
781    *   ListTargetHttpsProxiesRequest request =
782    *       ListTargetHttpsProxiesRequest.newBuilder()
783    *           .setFilter("filter-1274492040")
784    *           .setMaxResults(1128457243)
785    *           .setOrderBy("orderBy-1207110587")
786    *           .setPageToken("pageToken873572522")
787    *           .setProject("project-309310695")
788    *           .setReturnPartialSuccess(true)
789    *           .build();
790    *   while (true) {
791    *     TargetHttpsProxyList response = targetHttpsProxiesClient.listCallable().call(request);
792    *     for (TargetHttpsProxy element : response.getItemsList()) {
793    *       // doThingsWith(element);
794    *     }
795    *     String nextPageToken = response.getNextPageToken();
796    *     if (!Strings.isNullOrEmpty(nextPageToken)) {
797    *       request = request.toBuilder().setPageToken(nextPageToken).build();
798    *     } else {
799    *       break;
800    *     }
801    *   }
802    * }
803    * }</pre>
804    */
listCallable()805   public final UnaryCallable<ListTargetHttpsProxiesRequest, TargetHttpsProxyList> listCallable() {
806     return stub.listCallable();
807   }
808 
809   // AUTO-GENERATED DOCUMENTATION AND METHOD.
810   /**
811    * Patches the specified TargetHttpsProxy resource with the data included in the request. This
812    * method supports PATCH semantics and uses JSON merge patch format and processing rules.
813    *
814    * <p>Sample code:
815    *
816    * <pre>{@code
817    * // This snippet has been automatically generated and should be regarded as a code template only.
818    * // It will require modifications to work:
819    * // - It may require correct/in-range values for request initialization.
820    * // - It may require specifying regional endpoints when creating the service client as shown in
821    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
822    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
823    *   String project = "project-309310695";
824    *   String targetHttpsProxy = "targetHttpsProxy833943732";
825    *   TargetHttpsProxy targetHttpsProxyResource = TargetHttpsProxy.newBuilder().build();
826    *   Operation response =
827    *       targetHttpsProxiesClient
828    *           .patchAsync(project, targetHttpsProxy, targetHttpsProxyResource)
829    *           .get();
830    * }
831    * }</pre>
832    *
833    * @param project Project ID for this request.
834    * @param targetHttpsProxy Name of the TargetHttpsProxy resource to patch.
835    * @param targetHttpsProxyResource The body resource for this request
836    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
837    */
patchAsync( String project, String targetHttpsProxy, TargetHttpsProxy targetHttpsProxyResource)838   public final OperationFuture<Operation, Operation> patchAsync(
839       String project, String targetHttpsProxy, TargetHttpsProxy targetHttpsProxyResource) {
840     PatchTargetHttpsProxyRequest request =
841         PatchTargetHttpsProxyRequest.newBuilder()
842             .setProject(project)
843             .setTargetHttpsProxy(targetHttpsProxy)
844             .setTargetHttpsProxyResource(targetHttpsProxyResource)
845             .build();
846     return patchAsync(request);
847   }
848 
849   // AUTO-GENERATED DOCUMENTATION AND METHOD.
850   /**
851    * Patches the specified TargetHttpsProxy resource with the data included in the request. This
852    * method supports PATCH semantics and uses JSON merge patch format and processing rules.
853    *
854    * <p>Sample code:
855    *
856    * <pre>{@code
857    * // This snippet has been automatically generated and should be regarded as a code template only.
858    * // It will require modifications to work:
859    * // - It may require correct/in-range values for request initialization.
860    * // - It may require specifying regional endpoints when creating the service client as shown in
861    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
862    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
863    *   PatchTargetHttpsProxyRequest request =
864    *       PatchTargetHttpsProxyRequest.newBuilder()
865    *           .setProject("project-309310695")
866    *           .setRequestId("requestId693933066")
867    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
868    *           .setTargetHttpsProxyResource(TargetHttpsProxy.newBuilder().build())
869    *           .build();
870    *   Operation response = targetHttpsProxiesClient.patchAsync(request).get();
871    * }
872    * }</pre>
873    *
874    * @param request The request object containing all of the parameters for the API call.
875    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
876    */
877   @BetaApi(
878       "The surface for long-running operations is not stable yet and may change in the future.")
patchAsync( PatchTargetHttpsProxyRequest request)879   public final OperationFuture<Operation, Operation> patchAsync(
880       PatchTargetHttpsProxyRequest request) {
881     return patchOperationCallable().futureCall(request);
882   }
883 
884   // AUTO-GENERATED DOCUMENTATION AND METHOD.
885   /**
886    * Patches the specified TargetHttpsProxy resource with the data included in the request. This
887    * method supports PATCH semantics and uses JSON merge patch format and processing rules.
888    *
889    * <p>Sample code:
890    *
891    * <pre>{@code
892    * // This snippet has been automatically generated and should be regarded as a code template only.
893    * // It will require modifications to work:
894    * // - It may require correct/in-range values for request initialization.
895    * // - It may require specifying regional endpoints when creating the service client as shown in
896    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
897    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
898    *   PatchTargetHttpsProxyRequest request =
899    *       PatchTargetHttpsProxyRequest.newBuilder()
900    *           .setProject("project-309310695")
901    *           .setRequestId("requestId693933066")
902    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
903    *           .setTargetHttpsProxyResource(TargetHttpsProxy.newBuilder().build())
904    *           .build();
905    *   OperationFuture<Operation, Operation> future =
906    *       targetHttpsProxiesClient.patchOperationCallable().futureCall(request);
907    *   // Do something.
908    *   Operation response = future.get();
909    * }
910    * }</pre>
911    */
912   public final OperationCallable<PatchTargetHttpsProxyRequest, Operation, Operation>
patchOperationCallable()913       patchOperationCallable() {
914     return stub.patchOperationCallable();
915   }
916 
917   // AUTO-GENERATED DOCUMENTATION AND METHOD.
918   /**
919    * Patches the specified TargetHttpsProxy resource with the data included in the request. This
920    * method supports PATCH semantics and uses JSON merge patch format and processing rules.
921    *
922    * <p>Sample code:
923    *
924    * <pre>{@code
925    * // This snippet has been automatically generated and should be regarded as a code template only.
926    * // It will require modifications to work:
927    * // - It may require correct/in-range values for request initialization.
928    * // - It may require specifying regional endpoints when creating the service client as shown in
929    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
930    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
931    *   PatchTargetHttpsProxyRequest request =
932    *       PatchTargetHttpsProxyRequest.newBuilder()
933    *           .setProject("project-309310695")
934    *           .setRequestId("requestId693933066")
935    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
936    *           .setTargetHttpsProxyResource(TargetHttpsProxy.newBuilder().build())
937    *           .build();
938    *   ApiFuture<Operation> future = targetHttpsProxiesClient.patchCallable().futureCall(request);
939    *   // Do something.
940    *   Operation response = future.get();
941    * }
942    * }</pre>
943    */
patchCallable()944   public final UnaryCallable<PatchTargetHttpsProxyRequest, Operation> patchCallable() {
945     return stub.patchCallable();
946   }
947 
948   // AUTO-GENERATED DOCUMENTATION AND METHOD.
949   /**
950    * Changes the Certificate Map for TargetHttpsProxy.
951    *
952    * <p>Sample code:
953    *
954    * <pre>{@code
955    * // This snippet has been automatically generated and should be regarded as a code template only.
956    * // It will require modifications to work:
957    * // - It may require correct/in-range values for request initialization.
958    * // - It may require specifying regional endpoints when creating the service client as shown in
959    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
960    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
961    *   String project = "project-309310695";
962    *   String targetHttpsProxy = "targetHttpsProxy833943732";
963    *   TargetHttpsProxiesSetCertificateMapRequest
964    *       targetHttpsProxiesSetCertificateMapRequestResource =
965    *           TargetHttpsProxiesSetCertificateMapRequest.newBuilder().build();
966    *   Operation response =
967    *       targetHttpsProxiesClient
968    *           .setCertificateMapAsync(
969    *               project, targetHttpsProxy, targetHttpsProxiesSetCertificateMapRequestResource)
970    *           .get();
971    * }
972    * }</pre>
973    *
974    * @param project Project ID for this request.
975    * @param targetHttpsProxy Name of the TargetHttpsProxy resource whose CertificateMap is to be
976    *     set. The name must be 1-63 characters long, and comply with RFC1035.
977    * @param targetHttpsProxiesSetCertificateMapRequestResource The body resource for this request
978    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
979    */
setCertificateMapAsync( String project, String targetHttpsProxy, TargetHttpsProxiesSetCertificateMapRequest targetHttpsProxiesSetCertificateMapRequestResource)980   public final OperationFuture<Operation, Operation> setCertificateMapAsync(
981       String project,
982       String targetHttpsProxy,
983       TargetHttpsProxiesSetCertificateMapRequest
984           targetHttpsProxiesSetCertificateMapRequestResource) {
985     SetCertificateMapTargetHttpsProxyRequest request =
986         SetCertificateMapTargetHttpsProxyRequest.newBuilder()
987             .setProject(project)
988             .setTargetHttpsProxy(targetHttpsProxy)
989             .setTargetHttpsProxiesSetCertificateMapRequestResource(
990                 targetHttpsProxiesSetCertificateMapRequestResource)
991             .build();
992     return setCertificateMapAsync(request);
993   }
994 
995   // AUTO-GENERATED DOCUMENTATION AND METHOD.
996   /**
997    * Changes the Certificate Map for TargetHttpsProxy.
998    *
999    * <p>Sample code:
1000    *
1001    * <pre>{@code
1002    * // This snippet has been automatically generated and should be regarded as a code template only.
1003    * // It will require modifications to work:
1004    * // - It may require correct/in-range values for request initialization.
1005    * // - It may require specifying regional endpoints when creating the service client as shown in
1006    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1007    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1008    *   SetCertificateMapTargetHttpsProxyRequest request =
1009    *       SetCertificateMapTargetHttpsProxyRequest.newBuilder()
1010    *           .setProject("project-309310695")
1011    *           .setRequestId("requestId693933066")
1012    *           .setTargetHttpsProxiesSetCertificateMapRequestResource(
1013    *               TargetHttpsProxiesSetCertificateMapRequest.newBuilder().build())
1014    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1015    *           .build();
1016    *   Operation response = targetHttpsProxiesClient.setCertificateMapAsync(request).get();
1017    * }
1018    * }</pre>
1019    *
1020    * @param request The request object containing all of the parameters for the API call.
1021    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1022    */
1023   @BetaApi(
1024       "The surface for long-running operations is not stable yet and may change in the future.")
setCertificateMapAsync( SetCertificateMapTargetHttpsProxyRequest request)1025   public final OperationFuture<Operation, Operation> setCertificateMapAsync(
1026       SetCertificateMapTargetHttpsProxyRequest request) {
1027     return setCertificateMapOperationCallable().futureCall(request);
1028   }
1029 
1030   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1031   /**
1032    * Changes the Certificate Map for TargetHttpsProxy.
1033    *
1034    * <p>Sample code:
1035    *
1036    * <pre>{@code
1037    * // This snippet has been automatically generated and should be regarded as a code template only.
1038    * // It will require modifications to work:
1039    * // - It may require correct/in-range values for request initialization.
1040    * // - It may require specifying regional endpoints when creating the service client as shown in
1041    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1042    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1043    *   SetCertificateMapTargetHttpsProxyRequest request =
1044    *       SetCertificateMapTargetHttpsProxyRequest.newBuilder()
1045    *           .setProject("project-309310695")
1046    *           .setRequestId("requestId693933066")
1047    *           .setTargetHttpsProxiesSetCertificateMapRequestResource(
1048    *               TargetHttpsProxiesSetCertificateMapRequest.newBuilder().build())
1049    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1050    *           .build();
1051    *   OperationFuture<Operation, Operation> future =
1052    *       targetHttpsProxiesClient.setCertificateMapOperationCallable().futureCall(request);
1053    *   // Do something.
1054    *   Operation response = future.get();
1055    * }
1056    * }</pre>
1057    */
1058   public final OperationCallable<SetCertificateMapTargetHttpsProxyRequest, Operation, Operation>
setCertificateMapOperationCallable()1059       setCertificateMapOperationCallable() {
1060     return stub.setCertificateMapOperationCallable();
1061   }
1062 
1063   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1064   /**
1065    * Changes the Certificate Map for TargetHttpsProxy.
1066    *
1067    * <p>Sample code:
1068    *
1069    * <pre>{@code
1070    * // This snippet has been automatically generated and should be regarded as a code template only.
1071    * // It will require modifications to work:
1072    * // - It may require correct/in-range values for request initialization.
1073    * // - It may require specifying regional endpoints when creating the service client as shown in
1074    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1075    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1076    *   SetCertificateMapTargetHttpsProxyRequest request =
1077    *       SetCertificateMapTargetHttpsProxyRequest.newBuilder()
1078    *           .setProject("project-309310695")
1079    *           .setRequestId("requestId693933066")
1080    *           .setTargetHttpsProxiesSetCertificateMapRequestResource(
1081    *               TargetHttpsProxiesSetCertificateMapRequest.newBuilder().build())
1082    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1083    *           .build();
1084    *   ApiFuture<Operation> future =
1085    *       targetHttpsProxiesClient.setCertificateMapCallable().futureCall(request);
1086    *   // Do something.
1087    *   Operation response = future.get();
1088    * }
1089    * }</pre>
1090    */
1091   public final UnaryCallable<SetCertificateMapTargetHttpsProxyRequest, Operation>
setCertificateMapCallable()1092       setCertificateMapCallable() {
1093     return stub.setCertificateMapCallable();
1094   }
1095 
1096   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1097   /**
1098    * Sets the QUIC override policy for TargetHttpsProxy.
1099    *
1100    * <p>Sample code:
1101    *
1102    * <pre>{@code
1103    * // This snippet has been automatically generated and should be regarded as a code template only.
1104    * // It will require modifications to work:
1105    * // - It may require correct/in-range values for request initialization.
1106    * // - It may require specifying regional endpoints when creating the service client as shown in
1107    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1108    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1109    *   String project = "project-309310695";
1110    *   String targetHttpsProxy = "targetHttpsProxy833943732";
1111    *   TargetHttpsProxiesSetQuicOverrideRequest targetHttpsProxiesSetQuicOverrideRequestResource =
1112    *       TargetHttpsProxiesSetQuicOverrideRequest.newBuilder().build();
1113    *   Operation response =
1114    *       targetHttpsProxiesClient
1115    *           .setQuicOverrideAsync(
1116    *               project, targetHttpsProxy, targetHttpsProxiesSetQuicOverrideRequestResource)
1117    *           .get();
1118    * }
1119    * }</pre>
1120    *
1121    * @param project Project ID for this request.
1122    * @param targetHttpsProxy Name of the TargetHttpsProxy resource to set the QUIC override policy
1123    *     for. The name should conform to RFC1035.
1124    * @param targetHttpsProxiesSetQuicOverrideRequestResource The body resource for this request
1125    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1126    */
setQuicOverrideAsync( String project, String targetHttpsProxy, TargetHttpsProxiesSetQuicOverrideRequest targetHttpsProxiesSetQuicOverrideRequestResource)1127   public final OperationFuture<Operation, Operation> setQuicOverrideAsync(
1128       String project,
1129       String targetHttpsProxy,
1130       TargetHttpsProxiesSetQuicOverrideRequest targetHttpsProxiesSetQuicOverrideRequestResource) {
1131     SetQuicOverrideTargetHttpsProxyRequest request =
1132         SetQuicOverrideTargetHttpsProxyRequest.newBuilder()
1133             .setProject(project)
1134             .setTargetHttpsProxy(targetHttpsProxy)
1135             .setTargetHttpsProxiesSetQuicOverrideRequestResource(
1136                 targetHttpsProxiesSetQuicOverrideRequestResource)
1137             .build();
1138     return setQuicOverrideAsync(request);
1139   }
1140 
1141   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1142   /**
1143    * Sets the QUIC override policy for TargetHttpsProxy.
1144    *
1145    * <p>Sample code:
1146    *
1147    * <pre>{@code
1148    * // This snippet has been automatically generated and should be regarded as a code template only.
1149    * // It will require modifications to work:
1150    * // - It may require correct/in-range values for request initialization.
1151    * // - It may require specifying regional endpoints when creating the service client as shown in
1152    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1153    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1154    *   SetQuicOverrideTargetHttpsProxyRequest request =
1155    *       SetQuicOverrideTargetHttpsProxyRequest.newBuilder()
1156    *           .setProject("project-309310695")
1157    *           .setRequestId("requestId693933066")
1158    *           .setTargetHttpsProxiesSetQuicOverrideRequestResource(
1159    *               TargetHttpsProxiesSetQuicOverrideRequest.newBuilder().build())
1160    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1161    *           .build();
1162    *   Operation response = targetHttpsProxiesClient.setQuicOverrideAsync(request).get();
1163    * }
1164    * }</pre>
1165    *
1166    * @param request The request object containing all of the parameters for the API call.
1167    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1168    */
1169   @BetaApi(
1170       "The surface for long-running operations is not stable yet and may change in the future.")
setQuicOverrideAsync( SetQuicOverrideTargetHttpsProxyRequest request)1171   public final OperationFuture<Operation, Operation> setQuicOverrideAsync(
1172       SetQuicOverrideTargetHttpsProxyRequest request) {
1173     return setQuicOverrideOperationCallable().futureCall(request);
1174   }
1175 
1176   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1177   /**
1178    * Sets the QUIC override policy for TargetHttpsProxy.
1179    *
1180    * <p>Sample code:
1181    *
1182    * <pre>{@code
1183    * // This snippet has been automatically generated and should be regarded as a code template only.
1184    * // It will require modifications to work:
1185    * // - It may require correct/in-range values for request initialization.
1186    * // - It may require specifying regional endpoints when creating the service client as shown in
1187    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1188    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1189    *   SetQuicOverrideTargetHttpsProxyRequest request =
1190    *       SetQuicOverrideTargetHttpsProxyRequest.newBuilder()
1191    *           .setProject("project-309310695")
1192    *           .setRequestId("requestId693933066")
1193    *           .setTargetHttpsProxiesSetQuicOverrideRequestResource(
1194    *               TargetHttpsProxiesSetQuicOverrideRequest.newBuilder().build())
1195    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1196    *           .build();
1197    *   OperationFuture<Operation, Operation> future =
1198    *       targetHttpsProxiesClient.setQuicOverrideOperationCallable().futureCall(request);
1199    *   // Do something.
1200    *   Operation response = future.get();
1201    * }
1202    * }</pre>
1203    */
1204   public final OperationCallable<SetQuicOverrideTargetHttpsProxyRequest, Operation, Operation>
setQuicOverrideOperationCallable()1205       setQuicOverrideOperationCallable() {
1206     return stub.setQuicOverrideOperationCallable();
1207   }
1208 
1209   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1210   /**
1211    * Sets the QUIC override policy for TargetHttpsProxy.
1212    *
1213    * <p>Sample code:
1214    *
1215    * <pre>{@code
1216    * // This snippet has been automatically generated and should be regarded as a code template only.
1217    * // It will require modifications to work:
1218    * // - It may require correct/in-range values for request initialization.
1219    * // - It may require specifying regional endpoints when creating the service client as shown in
1220    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1221    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1222    *   SetQuicOverrideTargetHttpsProxyRequest request =
1223    *       SetQuicOverrideTargetHttpsProxyRequest.newBuilder()
1224    *           .setProject("project-309310695")
1225    *           .setRequestId("requestId693933066")
1226    *           .setTargetHttpsProxiesSetQuicOverrideRequestResource(
1227    *               TargetHttpsProxiesSetQuicOverrideRequest.newBuilder().build())
1228    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1229    *           .build();
1230    *   ApiFuture<Operation> future =
1231    *       targetHttpsProxiesClient.setQuicOverrideCallable().futureCall(request);
1232    *   // Do something.
1233    *   Operation response = future.get();
1234    * }
1235    * }</pre>
1236    */
1237   public final UnaryCallable<SetQuicOverrideTargetHttpsProxyRequest, Operation>
setQuicOverrideCallable()1238       setQuicOverrideCallable() {
1239     return stub.setQuicOverrideCallable();
1240   }
1241 
1242   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1243   /**
1244    * Replaces SslCertificates for TargetHttpsProxy.
1245    *
1246    * <p>Sample code:
1247    *
1248    * <pre>{@code
1249    * // This snippet has been automatically generated and should be regarded as a code template only.
1250    * // It will require modifications to work:
1251    * // - It may require correct/in-range values for request initialization.
1252    * // - It may require specifying regional endpoints when creating the service client as shown in
1253    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1254    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1255    *   String project = "project-309310695";
1256    *   String targetHttpsProxy = "targetHttpsProxy833943732";
1257    *   TargetHttpsProxiesSetSslCertificatesRequest
1258    *       targetHttpsProxiesSetSslCertificatesRequestResource =
1259    *           TargetHttpsProxiesSetSslCertificatesRequest.newBuilder().build();
1260    *   Operation response =
1261    *       targetHttpsProxiesClient
1262    *           .setSslCertificatesAsync(
1263    *               project, targetHttpsProxy, targetHttpsProxiesSetSslCertificatesRequestResource)
1264    *           .get();
1265    * }
1266    * }</pre>
1267    *
1268    * @param project Project ID for this request.
1269    * @param targetHttpsProxy Name of the TargetHttpsProxy resource to set an SslCertificates
1270    *     resource for.
1271    * @param targetHttpsProxiesSetSslCertificatesRequestResource The body resource for this request
1272    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1273    */
setSslCertificatesAsync( String project, String targetHttpsProxy, TargetHttpsProxiesSetSslCertificatesRequest targetHttpsProxiesSetSslCertificatesRequestResource)1274   public final OperationFuture<Operation, Operation> setSslCertificatesAsync(
1275       String project,
1276       String targetHttpsProxy,
1277       TargetHttpsProxiesSetSslCertificatesRequest
1278           targetHttpsProxiesSetSslCertificatesRequestResource) {
1279     SetSslCertificatesTargetHttpsProxyRequest request =
1280         SetSslCertificatesTargetHttpsProxyRequest.newBuilder()
1281             .setProject(project)
1282             .setTargetHttpsProxy(targetHttpsProxy)
1283             .setTargetHttpsProxiesSetSslCertificatesRequestResource(
1284                 targetHttpsProxiesSetSslCertificatesRequestResource)
1285             .build();
1286     return setSslCertificatesAsync(request);
1287   }
1288 
1289   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1290   /**
1291    * Replaces SslCertificates for TargetHttpsProxy.
1292    *
1293    * <p>Sample code:
1294    *
1295    * <pre>{@code
1296    * // This snippet has been automatically generated and should be regarded as a code template only.
1297    * // It will require modifications to work:
1298    * // - It may require correct/in-range values for request initialization.
1299    * // - It may require specifying regional endpoints when creating the service client as shown in
1300    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1301    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1302    *   SetSslCertificatesTargetHttpsProxyRequest request =
1303    *       SetSslCertificatesTargetHttpsProxyRequest.newBuilder()
1304    *           .setProject("project-309310695")
1305    *           .setRequestId("requestId693933066")
1306    *           .setTargetHttpsProxiesSetSslCertificatesRequestResource(
1307    *               TargetHttpsProxiesSetSslCertificatesRequest.newBuilder().build())
1308    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1309    *           .build();
1310    *   Operation response = targetHttpsProxiesClient.setSslCertificatesAsync(request).get();
1311    * }
1312    * }</pre>
1313    *
1314    * @param request The request object containing all of the parameters for the API call.
1315    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1316    */
1317   @BetaApi(
1318       "The surface for long-running operations is not stable yet and may change in the future.")
setSslCertificatesAsync( SetSslCertificatesTargetHttpsProxyRequest request)1319   public final OperationFuture<Operation, Operation> setSslCertificatesAsync(
1320       SetSslCertificatesTargetHttpsProxyRequest request) {
1321     return setSslCertificatesOperationCallable().futureCall(request);
1322   }
1323 
1324   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1325   /**
1326    * Replaces SslCertificates for TargetHttpsProxy.
1327    *
1328    * <p>Sample code:
1329    *
1330    * <pre>{@code
1331    * // This snippet has been automatically generated and should be regarded as a code template only.
1332    * // It will require modifications to work:
1333    * // - It may require correct/in-range values for request initialization.
1334    * // - It may require specifying regional endpoints when creating the service client as shown in
1335    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1336    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1337    *   SetSslCertificatesTargetHttpsProxyRequest request =
1338    *       SetSslCertificatesTargetHttpsProxyRequest.newBuilder()
1339    *           .setProject("project-309310695")
1340    *           .setRequestId("requestId693933066")
1341    *           .setTargetHttpsProxiesSetSslCertificatesRequestResource(
1342    *               TargetHttpsProxiesSetSslCertificatesRequest.newBuilder().build())
1343    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1344    *           .build();
1345    *   OperationFuture<Operation, Operation> future =
1346    *       targetHttpsProxiesClient.setSslCertificatesOperationCallable().futureCall(request);
1347    *   // Do something.
1348    *   Operation response = future.get();
1349    * }
1350    * }</pre>
1351    */
1352   public final OperationCallable<SetSslCertificatesTargetHttpsProxyRequest, Operation, Operation>
setSslCertificatesOperationCallable()1353       setSslCertificatesOperationCallable() {
1354     return stub.setSslCertificatesOperationCallable();
1355   }
1356 
1357   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1358   /**
1359    * Replaces SslCertificates for TargetHttpsProxy.
1360    *
1361    * <p>Sample code:
1362    *
1363    * <pre>{@code
1364    * // This snippet has been automatically generated and should be regarded as a code template only.
1365    * // It will require modifications to work:
1366    * // - It may require correct/in-range values for request initialization.
1367    * // - It may require specifying regional endpoints when creating the service client as shown in
1368    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1369    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1370    *   SetSslCertificatesTargetHttpsProxyRequest request =
1371    *       SetSslCertificatesTargetHttpsProxyRequest.newBuilder()
1372    *           .setProject("project-309310695")
1373    *           .setRequestId("requestId693933066")
1374    *           .setTargetHttpsProxiesSetSslCertificatesRequestResource(
1375    *               TargetHttpsProxiesSetSslCertificatesRequest.newBuilder().build())
1376    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1377    *           .build();
1378    *   ApiFuture<Operation> future =
1379    *       targetHttpsProxiesClient.setSslCertificatesCallable().futureCall(request);
1380    *   // Do something.
1381    *   Operation response = future.get();
1382    * }
1383    * }</pre>
1384    */
1385   public final UnaryCallable<SetSslCertificatesTargetHttpsProxyRequest, Operation>
setSslCertificatesCallable()1386       setSslCertificatesCallable() {
1387     return stub.setSslCertificatesCallable();
1388   }
1389 
1390   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1391   /**
1392    * Sets the SSL policy for TargetHttpsProxy. The SSL policy specifies the server-side support for
1393    * SSL features. This affects connections between clients and the HTTPS proxy load balancer. They
1394    * do not affect the connection between the load balancer and the backends.
1395    *
1396    * <p>Sample code:
1397    *
1398    * <pre>{@code
1399    * // This snippet has been automatically generated and should be regarded as a code template only.
1400    * // It will require modifications to work:
1401    * // - It may require correct/in-range values for request initialization.
1402    * // - It may require specifying regional endpoints when creating the service client as shown in
1403    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1404    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1405    *   String project = "project-309310695";
1406    *   String targetHttpsProxy = "targetHttpsProxy833943732";
1407    *   SslPolicyReference sslPolicyReferenceResource = SslPolicyReference.newBuilder().build();
1408    *   Operation response =
1409    *       targetHttpsProxiesClient
1410    *           .setSslPolicyAsync(project, targetHttpsProxy, sslPolicyReferenceResource)
1411    *           .get();
1412    * }
1413    * }</pre>
1414    *
1415    * @param project Project ID for this request.
1416    * @param targetHttpsProxy Name of the TargetHttpsProxy resource whose SSL policy is to be set.
1417    *     The name must be 1-63 characters long, and comply with RFC1035.
1418    * @param sslPolicyReferenceResource The body resource for this request
1419    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1420    */
setSslPolicyAsync( String project, String targetHttpsProxy, SslPolicyReference sslPolicyReferenceResource)1421   public final OperationFuture<Operation, Operation> setSslPolicyAsync(
1422       String project, String targetHttpsProxy, SslPolicyReference sslPolicyReferenceResource) {
1423     SetSslPolicyTargetHttpsProxyRequest request =
1424         SetSslPolicyTargetHttpsProxyRequest.newBuilder()
1425             .setProject(project)
1426             .setTargetHttpsProxy(targetHttpsProxy)
1427             .setSslPolicyReferenceResource(sslPolicyReferenceResource)
1428             .build();
1429     return setSslPolicyAsync(request);
1430   }
1431 
1432   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1433   /**
1434    * Sets the SSL policy for TargetHttpsProxy. The SSL policy specifies the server-side support for
1435    * SSL features. This affects connections between clients and the HTTPS proxy load balancer. They
1436    * do not affect the connection between the load balancer and the backends.
1437    *
1438    * <p>Sample code:
1439    *
1440    * <pre>{@code
1441    * // This snippet has been automatically generated and should be regarded as a code template only.
1442    * // It will require modifications to work:
1443    * // - It may require correct/in-range values for request initialization.
1444    * // - It may require specifying regional endpoints when creating the service client as shown in
1445    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1446    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1447    *   SetSslPolicyTargetHttpsProxyRequest request =
1448    *       SetSslPolicyTargetHttpsProxyRequest.newBuilder()
1449    *           .setProject("project-309310695")
1450    *           .setRequestId("requestId693933066")
1451    *           .setSslPolicyReferenceResource(SslPolicyReference.newBuilder().build())
1452    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1453    *           .build();
1454    *   Operation response = targetHttpsProxiesClient.setSslPolicyAsync(request).get();
1455    * }
1456    * }</pre>
1457    *
1458    * @param request The request object containing all of the parameters for the API call.
1459    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1460    */
1461   @BetaApi(
1462       "The surface for long-running operations is not stable yet and may change in the future.")
setSslPolicyAsync( SetSslPolicyTargetHttpsProxyRequest request)1463   public final OperationFuture<Operation, Operation> setSslPolicyAsync(
1464       SetSslPolicyTargetHttpsProxyRequest request) {
1465     return setSslPolicyOperationCallable().futureCall(request);
1466   }
1467 
1468   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1469   /**
1470    * Sets the SSL policy for TargetHttpsProxy. The SSL policy specifies the server-side support for
1471    * SSL features. This affects connections between clients and the HTTPS proxy load balancer. They
1472    * do not affect the connection between the load balancer and the backends.
1473    *
1474    * <p>Sample code:
1475    *
1476    * <pre>{@code
1477    * // This snippet has been automatically generated and should be regarded as a code template only.
1478    * // It will require modifications to work:
1479    * // - It may require correct/in-range values for request initialization.
1480    * // - It may require specifying regional endpoints when creating the service client as shown in
1481    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1482    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1483    *   SetSslPolicyTargetHttpsProxyRequest request =
1484    *       SetSslPolicyTargetHttpsProxyRequest.newBuilder()
1485    *           .setProject("project-309310695")
1486    *           .setRequestId("requestId693933066")
1487    *           .setSslPolicyReferenceResource(SslPolicyReference.newBuilder().build())
1488    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1489    *           .build();
1490    *   OperationFuture<Operation, Operation> future =
1491    *       targetHttpsProxiesClient.setSslPolicyOperationCallable().futureCall(request);
1492    *   // Do something.
1493    *   Operation response = future.get();
1494    * }
1495    * }</pre>
1496    */
1497   public final OperationCallable<SetSslPolicyTargetHttpsProxyRequest, Operation, Operation>
setSslPolicyOperationCallable()1498       setSslPolicyOperationCallable() {
1499     return stub.setSslPolicyOperationCallable();
1500   }
1501 
1502   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1503   /**
1504    * Sets the SSL policy for TargetHttpsProxy. The SSL policy specifies the server-side support for
1505    * SSL features. This affects connections between clients and the HTTPS proxy load balancer. They
1506    * do not affect the connection between the load balancer and the backends.
1507    *
1508    * <p>Sample code:
1509    *
1510    * <pre>{@code
1511    * // This snippet has been automatically generated and should be regarded as a code template only.
1512    * // It will require modifications to work:
1513    * // - It may require correct/in-range values for request initialization.
1514    * // - It may require specifying regional endpoints when creating the service client as shown in
1515    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1516    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1517    *   SetSslPolicyTargetHttpsProxyRequest request =
1518    *       SetSslPolicyTargetHttpsProxyRequest.newBuilder()
1519    *           .setProject("project-309310695")
1520    *           .setRequestId("requestId693933066")
1521    *           .setSslPolicyReferenceResource(SslPolicyReference.newBuilder().build())
1522    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1523    *           .build();
1524    *   ApiFuture<Operation> future =
1525    *       targetHttpsProxiesClient.setSslPolicyCallable().futureCall(request);
1526    *   // Do something.
1527    *   Operation response = future.get();
1528    * }
1529    * }</pre>
1530    */
1531   public final UnaryCallable<SetSslPolicyTargetHttpsProxyRequest, Operation>
setSslPolicyCallable()1532       setSslPolicyCallable() {
1533     return stub.setSslPolicyCallable();
1534   }
1535 
1536   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1537   /**
1538    * Changes the URL map for TargetHttpsProxy.
1539    *
1540    * <p>Sample code:
1541    *
1542    * <pre>{@code
1543    * // This snippet has been automatically generated and should be regarded as a code template only.
1544    * // It will require modifications to work:
1545    * // - It may require correct/in-range values for request initialization.
1546    * // - It may require specifying regional endpoints when creating the service client as shown in
1547    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1548    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1549    *   String project = "project-309310695";
1550    *   String targetHttpsProxy = "targetHttpsProxy833943732";
1551    *   UrlMapReference urlMapReferenceResource = UrlMapReference.newBuilder().build();
1552    *   Operation response =
1553    *       targetHttpsProxiesClient
1554    *           .setUrlMapAsync(project, targetHttpsProxy, urlMapReferenceResource)
1555    *           .get();
1556    * }
1557    * }</pre>
1558    *
1559    * @param project Project ID for this request.
1560    * @param targetHttpsProxy Name of the TargetHttpsProxy resource whose URL map is to be set.
1561    * @param urlMapReferenceResource The body resource for this request
1562    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1563    */
setUrlMapAsync( String project, String targetHttpsProxy, UrlMapReference urlMapReferenceResource)1564   public final OperationFuture<Operation, Operation> setUrlMapAsync(
1565       String project, String targetHttpsProxy, UrlMapReference urlMapReferenceResource) {
1566     SetUrlMapTargetHttpsProxyRequest request =
1567         SetUrlMapTargetHttpsProxyRequest.newBuilder()
1568             .setProject(project)
1569             .setTargetHttpsProxy(targetHttpsProxy)
1570             .setUrlMapReferenceResource(urlMapReferenceResource)
1571             .build();
1572     return setUrlMapAsync(request);
1573   }
1574 
1575   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1576   /**
1577    * Changes the URL map for TargetHttpsProxy.
1578    *
1579    * <p>Sample code:
1580    *
1581    * <pre>{@code
1582    * // This snippet has been automatically generated and should be regarded as a code template only.
1583    * // It will require modifications to work:
1584    * // - It may require correct/in-range values for request initialization.
1585    * // - It may require specifying regional endpoints when creating the service client as shown in
1586    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1587    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1588    *   SetUrlMapTargetHttpsProxyRequest request =
1589    *       SetUrlMapTargetHttpsProxyRequest.newBuilder()
1590    *           .setProject("project-309310695")
1591    *           .setRequestId("requestId693933066")
1592    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1593    *           .setUrlMapReferenceResource(UrlMapReference.newBuilder().build())
1594    *           .build();
1595    *   Operation response = targetHttpsProxiesClient.setUrlMapAsync(request).get();
1596    * }
1597    * }</pre>
1598    *
1599    * @param request The request object containing all of the parameters for the API call.
1600    * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1601    */
1602   @BetaApi(
1603       "The surface for long-running operations is not stable yet and may change in the future.")
setUrlMapAsync( SetUrlMapTargetHttpsProxyRequest request)1604   public final OperationFuture<Operation, Operation> setUrlMapAsync(
1605       SetUrlMapTargetHttpsProxyRequest request) {
1606     return setUrlMapOperationCallable().futureCall(request);
1607   }
1608 
1609   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1610   /**
1611    * Changes the URL map for TargetHttpsProxy.
1612    *
1613    * <p>Sample code:
1614    *
1615    * <pre>{@code
1616    * // This snippet has been automatically generated and should be regarded as a code template only.
1617    * // It will require modifications to work:
1618    * // - It may require correct/in-range values for request initialization.
1619    * // - It may require specifying regional endpoints when creating the service client as shown in
1620    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1621    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1622    *   SetUrlMapTargetHttpsProxyRequest request =
1623    *       SetUrlMapTargetHttpsProxyRequest.newBuilder()
1624    *           .setProject("project-309310695")
1625    *           .setRequestId("requestId693933066")
1626    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1627    *           .setUrlMapReferenceResource(UrlMapReference.newBuilder().build())
1628    *           .build();
1629    *   OperationFuture<Operation, Operation> future =
1630    *       targetHttpsProxiesClient.setUrlMapOperationCallable().futureCall(request);
1631    *   // Do something.
1632    *   Operation response = future.get();
1633    * }
1634    * }</pre>
1635    */
1636   public final OperationCallable<SetUrlMapTargetHttpsProxyRequest, Operation, Operation>
setUrlMapOperationCallable()1637       setUrlMapOperationCallable() {
1638     return stub.setUrlMapOperationCallable();
1639   }
1640 
1641   // AUTO-GENERATED DOCUMENTATION AND METHOD.
1642   /**
1643    * Changes the URL map for TargetHttpsProxy.
1644    *
1645    * <p>Sample code:
1646    *
1647    * <pre>{@code
1648    * // This snippet has been automatically generated and should be regarded as a code template only.
1649    * // It will require modifications to work:
1650    * // - It may require correct/in-range values for request initialization.
1651    * // - It may require specifying regional endpoints when creating the service client as shown in
1652    * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1653    * try (TargetHttpsProxiesClient targetHttpsProxiesClient = TargetHttpsProxiesClient.create()) {
1654    *   SetUrlMapTargetHttpsProxyRequest request =
1655    *       SetUrlMapTargetHttpsProxyRequest.newBuilder()
1656    *           .setProject("project-309310695")
1657    *           .setRequestId("requestId693933066")
1658    *           .setTargetHttpsProxy("targetHttpsProxy833943732")
1659    *           .setUrlMapReferenceResource(UrlMapReference.newBuilder().build())
1660    *           .build();
1661    *   ApiFuture<Operation> future =
1662    *       targetHttpsProxiesClient.setUrlMapCallable().futureCall(request);
1663    *   // Do something.
1664    *   Operation response = future.get();
1665    * }
1666    * }</pre>
1667    */
setUrlMapCallable()1668   public final UnaryCallable<SetUrlMapTargetHttpsProxyRequest, Operation> setUrlMapCallable() {
1669     return stub.setUrlMapCallable();
1670   }
1671 
1672   @Override
close()1673   public final void close() {
1674     stub.close();
1675   }
1676 
1677   @Override
shutdown()1678   public void shutdown() {
1679     stub.shutdown();
1680   }
1681 
1682   @Override
isShutdown()1683   public boolean isShutdown() {
1684     return stub.isShutdown();
1685   }
1686 
1687   @Override
isTerminated()1688   public boolean isTerminated() {
1689     return stub.isTerminated();
1690   }
1691 
1692   @Override
shutdownNow()1693   public void shutdownNow() {
1694     stub.shutdownNow();
1695   }
1696 
1697   @Override
awaitTermination(long duration, TimeUnit unit)1698   public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException {
1699     return stub.awaitTermination(duration, unit);
1700   }
1701 
1702   public static class AggregatedListPagedResponse
1703       extends AbstractPagedListResponse<
1704           AggregatedListTargetHttpsProxiesRequest,
1705           TargetHttpsProxyAggregatedList,
1706           Map.Entry<String, TargetHttpsProxiesScopedList>,
1707           AggregatedListPage,
1708           AggregatedListFixedSizeCollection> {
1709 
createAsync( PageContext< AggregatedListTargetHttpsProxiesRequest, TargetHttpsProxyAggregatedList, Map.Entry<String, TargetHttpsProxiesScopedList>> context, ApiFuture<TargetHttpsProxyAggregatedList> futureResponse)1710     public static ApiFuture<AggregatedListPagedResponse> createAsync(
1711         PageContext<
1712                 AggregatedListTargetHttpsProxiesRequest,
1713                 TargetHttpsProxyAggregatedList,
1714                 Map.Entry<String, TargetHttpsProxiesScopedList>>
1715             context,
1716         ApiFuture<TargetHttpsProxyAggregatedList> futureResponse) {
1717       ApiFuture<AggregatedListPage> futurePage =
1718           AggregatedListPage.createEmptyPage().createPageAsync(context, futureResponse);
1719       return ApiFutures.transform(
1720           futurePage,
1721           input -> new AggregatedListPagedResponse(input),
1722           MoreExecutors.directExecutor());
1723     }
1724 
AggregatedListPagedResponse(AggregatedListPage page)1725     private AggregatedListPagedResponse(AggregatedListPage page) {
1726       super(page, AggregatedListFixedSizeCollection.createEmptyCollection());
1727     }
1728   }
1729 
1730   public static class AggregatedListPage
1731       extends AbstractPage<
1732           AggregatedListTargetHttpsProxiesRequest,
1733           TargetHttpsProxyAggregatedList,
1734           Map.Entry<String, TargetHttpsProxiesScopedList>,
1735           AggregatedListPage> {
1736 
AggregatedListPage( PageContext< AggregatedListTargetHttpsProxiesRequest, TargetHttpsProxyAggregatedList, Map.Entry<String, TargetHttpsProxiesScopedList>> context, TargetHttpsProxyAggregatedList response)1737     private AggregatedListPage(
1738         PageContext<
1739                 AggregatedListTargetHttpsProxiesRequest,
1740                 TargetHttpsProxyAggregatedList,
1741                 Map.Entry<String, TargetHttpsProxiesScopedList>>
1742             context,
1743         TargetHttpsProxyAggregatedList response) {
1744       super(context, response);
1745     }
1746 
createEmptyPage()1747     private static AggregatedListPage createEmptyPage() {
1748       return new AggregatedListPage(null, null);
1749     }
1750 
1751     @Override
createPage( PageContext< AggregatedListTargetHttpsProxiesRequest, TargetHttpsProxyAggregatedList, Map.Entry<String, TargetHttpsProxiesScopedList>> context, TargetHttpsProxyAggregatedList response)1752     protected AggregatedListPage createPage(
1753         PageContext<
1754                 AggregatedListTargetHttpsProxiesRequest,
1755                 TargetHttpsProxyAggregatedList,
1756                 Map.Entry<String, TargetHttpsProxiesScopedList>>
1757             context,
1758         TargetHttpsProxyAggregatedList response) {
1759       return new AggregatedListPage(context, response);
1760     }
1761 
1762     @Override
createPageAsync( PageContext< AggregatedListTargetHttpsProxiesRequest, TargetHttpsProxyAggregatedList, Map.Entry<String, TargetHttpsProxiesScopedList>> context, ApiFuture<TargetHttpsProxyAggregatedList> futureResponse)1763     public ApiFuture<AggregatedListPage> createPageAsync(
1764         PageContext<
1765                 AggregatedListTargetHttpsProxiesRequest,
1766                 TargetHttpsProxyAggregatedList,
1767                 Map.Entry<String, TargetHttpsProxiesScopedList>>
1768             context,
1769         ApiFuture<TargetHttpsProxyAggregatedList> futureResponse) {
1770       return super.createPageAsync(context, futureResponse);
1771     }
1772   }
1773 
1774   public static class AggregatedListFixedSizeCollection
1775       extends AbstractFixedSizeCollection<
1776           AggregatedListTargetHttpsProxiesRequest,
1777           TargetHttpsProxyAggregatedList,
1778           Map.Entry<String, TargetHttpsProxiesScopedList>,
1779           AggregatedListPage,
1780           AggregatedListFixedSizeCollection> {
1781 
AggregatedListFixedSizeCollection(List<AggregatedListPage> pages, int collectionSize)1782     private AggregatedListFixedSizeCollection(List<AggregatedListPage> pages, int collectionSize) {
1783       super(pages, collectionSize);
1784     }
1785 
createEmptyCollection()1786     private static AggregatedListFixedSizeCollection createEmptyCollection() {
1787       return new AggregatedListFixedSizeCollection(null, 0);
1788     }
1789 
1790     @Override
createCollection( List<AggregatedListPage> pages, int collectionSize)1791     protected AggregatedListFixedSizeCollection createCollection(
1792         List<AggregatedListPage> pages, int collectionSize) {
1793       return new AggregatedListFixedSizeCollection(pages, collectionSize);
1794     }
1795   }
1796 
1797   public static class ListPagedResponse
1798       extends AbstractPagedListResponse<
1799           ListTargetHttpsProxiesRequest,
1800           TargetHttpsProxyList,
1801           TargetHttpsProxy,
1802           ListPage,
1803           ListFixedSizeCollection> {
1804 
createAsync( PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context, ApiFuture<TargetHttpsProxyList> futureResponse)1805     public static ApiFuture<ListPagedResponse> createAsync(
1806         PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context,
1807         ApiFuture<TargetHttpsProxyList> futureResponse) {
1808       ApiFuture<ListPage> futurePage =
1809           ListPage.createEmptyPage().createPageAsync(context, futureResponse);
1810       return ApiFutures.transform(
1811           futurePage, input -> new ListPagedResponse(input), MoreExecutors.directExecutor());
1812     }
1813 
ListPagedResponse(ListPage page)1814     private ListPagedResponse(ListPage page) {
1815       super(page, ListFixedSizeCollection.createEmptyCollection());
1816     }
1817   }
1818 
1819   public static class ListPage
1820       extends AbstractPage<
1821           ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy, ListPage> {
1822 
ListPage( PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context, TargetHttpsProxyList response)1823     private ListPage(
1824         PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context,
1825         TargetHttpsProxyList response) {
1826       super(context, response);
1827     }
1828 
createEmptyPage()1829     private static ListPage createEmptyPage() {
1830       return new ListPage(null, null);
1831     }
1832 
1833     @Override
createPage( PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context, TargetHttpsProxyList response)1834     protected ListPage createPage(
1835         PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context,
1836         TargetHttpsProxyList response) {
1837       return new ListPage(context, response);
1838     }
1839 
1840     @Override
createPageAsync( PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context, ApiFuture<TargetHttpsProxyList> futureResponse)1841     public ApiFuture<ListPage> createPageAsync(
1842         PageContext<ListTargetHttpsProxiesRequest, TargetHttpsProxyList, TargetHttpsProxy> context,
1843         ApiFuture<TargetHttpsProxyList> futureResponse) {
1844       return super.createPageAsync(context, futureResponse);
1845     }
1846   }
1847 
1848   public static class ListFixedSizeCollection
1849       extends AbstractFixedSizeCollection<
1850           ListTargetHttpsProxiesRequest,
1851           TargetHttpsProxyList,
1852           TargetHttpsProxy,
1853           ListPage,
1854           ListFixedSizeCollection> {
1855 
ListFixedSizeCollection(List<ListPage> pages, int collectionSize)1856     private ListFixedSizeCollection(List<ListPage> pages, int collectionSize) {
1857       super(pages, collectionSize);
1858     }
1859 
createEmptyCollection()1860     private static ListFixedSizeCollection createEmptyCollection() {
1861       return new ListFixedSizeCollection(null, 0);
1862     }
1863 
1864     @Override
createCollection(List<ListPage> pages, int collectionSize)1865     protected ListFixedSizeCollection createCollection(List<ListPage> pages, int collectionSize) {
1866       return new ListFixedSizeCollection(pages, collectionSize);
1867     }
1868   }
1869 }
1870