@@ -650,6 +650,100 @@ public final UnaryCallable<GetBackendBucketRequest, BackendBucket> getCallable()
650
650
return stub .getCallable ();
651
651
}
652
652
653
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
654
+ /**
655
+ * Gets the access control policy for a resource. May be empty if no such policy or resource
656
+ * exists.
657
+ *
658
+ * <p>Sample code:
659
+ *
660
+ * <pre>{@code
661
+ * // This snippet has been automatically generated and should be regarded as a code template only.
662
+ * // It will require modifications to work:
663
+ * // - It may require correct/in-range values for request initialization.
664
+ * // - It may require specifying regional endpoints when creating the service client as shown in
665
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
666
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
667
+ * String project = "project-309310695";
668
+ * String resource = "resource-341064690";
669
+ * Policy response = backendBucketsClient.getIamPolicy(project, resource);
670
+ * }
671
+ * }</pre>
672
+ *
673
+ * @param project Project ID for this request.
674
+ * @param resource Name or id of the resource for this request.
675
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
676
+ */
677
+ public final Policy getIamPolicy (String project , String resource ) {
678
+ GetIamPolicyBackendBucketRequest request =
679
+ GetIamPolicyBackendBucketRequest .newBuilder ()
680
+ .setProject (project )
681
+ .setResource (resource )
682
+ .build ();
683
+ return getIamPolicy (request );
684
+ }
685
+
686
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
687
+ /**
688
+ * Gets the access control policy for a resource. May be empty if no such policy or resource
689
+ * exists.
690
+ *
691
+ * <p>Sample code:
692
+ *
693
+ * <pre>{@code
694
+ * // This snippet has been automatically generated and should be regarded as a code template only.
695
+ * // It will require modifications to work:
696
+ * // - It may require correct/in-range values for request initialization.
697
+ * // - It may require specifying regional endpoints when creating the service client as shown in
698
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
699
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
700
+ * GetIamPolicyBackendBucketRequest request =
701
+ * GetIamPolicyBackendBucketRequest.newBuilder()
702
+ * .setOptionsRequestedPolicyVersion(-574521795)
703
+ * .setProject("project-309310695")
704
+ * .setResource("resource-341064690")
705
+ * .build();
706
+ * Policy response = backendBucketsClient.getIamPolicy(request);
707
+ * }
708
+ * }</pre>
709
+ *
710
+ * @param request The request object containing all of the parameters for the API call.
711
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
712
+ */
713
+ public final Policy getIamPolicy (GetIamPolicyBackendBucketRequest request ) {
714
+ return getIamPolicyCallable ().call (request );
715
+ }
716
+
717
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
718
+ /**
719
+ * Gets the access control policy for a resource. May be empty if no such policy or resource
720
+ * exists.
721
+ *
722
+ * <p>Sample code:
723
+ *
724
+ * <pre>{@code
725
+ * // This snippet has been automatically generated and should be regarded as a code template only.
726
+ * // It will require modifications to work:
727
+ * // - It may require correct/in-range values for request initialization.
728
+ * // - It may require specifying regional endpoints when creating the service client as shown in
729
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
730
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
731
+ * GetIamPolicyBackendBucketRequest request =
732
+ * GetIamPolicyBackendBucketRequest.newBuilder()
733
+ * .setOptionsRequestedPolicyVersion(-574521795)
734
+ * .setProject("project-309310695")
735
+ * .setResource("resource-341064690")
736
+ * .build();
737
+ * ApiFuture<Policy> future = backendBucketsClient.getIamPolicyCallable().futureCall(request);
738
+ * // Do something.
739
+ * Policy response = future.get();
740
+ * }
741
+ * }</pre>
742
+ */
743
+ public final UnaryCallable <GetIamPolicyBackendBucketRequest , Policy > getIamPolicyCallable () {
744
+ return stub .getIamPolicyCallable ();
745
+ }
746
+
653
747
// AUTO-GENERATED DOCUMENTATION AND METHOD.
654
748
/**
655
749
* Creates a BackendBucket resource in the specified project using the data included in the
@@ -1197,6 +1291,204 @@ public final OperationFuture<Operation, Operation> setEdgeSecurityPolicyAsync(
1197
1291
return stub .setEdgeSecurityPolicyCallable ();
1198
1292
}
1199
1293
1294
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1295
+ /**
1296
+ * Sets the access control policy on the specified resource. Replaces any existing policy.
1297
+ *
1298
+ * <p>Sample code:
1299
+ *
1300
+ * <pre>{@code
1301
+ * // This snippet has been automatically generated and should be regarded as a code template only.
1302
+ * // It will require modifications to work:
1303
+ * // - It may require correct/in-range values for request initialization.
1304
+ * // - It may require specifying regional endpoints when creating the service client as shown in
1305
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1306
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
1307
+ * String project = "project-309310695";
1308
+ * String resource = "resource-341064690";
1309
+ * GlobalSetPolicyRequest globalSetPolicyRequestResource =
1310
+ * GlobalSetPolicyRequest.newBuilder().build();
1311
+ * Policy response =
1312
+ * backendBucketsClient.setIamPolicy(project, resource, globalSetPolicyRequestResource);
1313
+ * }
1314
+ * }</pre>
1315
+ *
1316
+ * @param project Project ID for this request.
1317
+ * @param resource Name or id of the resource for this request.
1318
+ * @param globalSetPolicyRequestResource The body resource for this request
1319
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1320
+ */
1321
+ public final Policy setIamPolicy (
1322
+ String project , String resource , GlobalSetPolicyRequest globalSetPolicyRequestResource ) {
1323
+ SetIamPolicyBackendBucketRequest request =
1324
+ SetIamPolicyBackendBucketRequest .newBuilder ()
1325
+ .setProject (project )
1326
+ .setResource (resource )
1327
+ .setGlobalSetPolicyRequestResource (globalSetPolicyRequestResource )
1328
+ .build ();
1329
+ return setIamPolicy (request );
1330
+ }
1331
+
1332
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1333
+ /**
1334
+ * Sets the access control policy on the specified resource. Replaces any existing policy.
1335
+ *
1336
+ * <p>Sample code:
1337
+ *
1338
+ * <pre>{@code
1339
+ * // This snippet has been automatically generated and should be regarded as a code template only.
1340
+ * // It will require modifications to work:
1341
+ * // - It may require correct/in-range values for request initialization.
1342
+ * // - It may require specifying regional endpoints when creating the service client as shown in
1343
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1344
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
1345
+ * SetIamPolicyBackendBucketRequest request =
1346
+ * SetIamPolicyBackendBucketRequest.newBuilder()
1347
+ * .setGlobalSetPolicyRequestResource(GlobalSetPolicyRequest.newBuilder().build())
1348
+ * .setProject("project-309310695")
1349
+ * .setResource("resource-341064690")
1350
+ * .build();
1351
+ * Policy response = backendBucketsClient.setIamPolicy(request);
1352
+ * }
1353
+ * }</pre>
1354
+ *
1355
+ * @param request The request object containing all of the parameters for the API call.
1356
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1357
+ */
1358
+ public final Policy setIamPolicy (SetIamPolicyBackendBucketRequest request ) {
1359
+ return setIamPolicyCallable ().call (request );
1360
+ }
1361
+
1362
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1363
+ /**
1364
+ * Sets the access control policy on the specified resource. Replaces any existing policy.
1365
+ *
1366
+ * <p>Sample code:
1367
+ *
1368
+ * <pre>{@code
1369
+ * // This snippet has been automatically generated and should be regarded as a code template only.
1370
+ * // It will require modifications to work:
1371
+ * // - It may require correct/in-range values for request initialization.
1372
+ * // - It may require specifying regional endpoints when creating the service client as shown in
1373
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1374
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
1375
+ * SetIamPolicyBackendBucketRequest request =
1376
+ * SetIamPolicyBackendBucketRequest.newBuilder()
1377
+ * .setGlobalSetPolicyRequestResource(GlobalSetPolicyRequest.newBuilder().build())
1378
+ * .setProject("project-309310695")
1379
+ * .setResource("resource-341064690")
1380
+ * .build();
1381
+ * ApiFuture<Policy> future = backendBucketsClient.setIamPolicyCallable().futureCall(request);
1382
+ * // Do something.
1383
+ * Policy response = future.get();
1384
+ * }
1385
+ * }</pre>
1386
+ */
1387
+ public final UnaryCallable <SetIamPolicyBackendBucketRequest , Policy > setIamPolicyCallable () {
1388
+ return stub .setIamPolicyCallable ();
1389
+ }
1390
+
1391
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1392
+ /**
1393
+ * Returns permissions that a caller has on the specified resource.
1394
+ *
1395
+ * <p>Sample code:
1396
+ *
1397
+ * <pre>{@code
1398
+ * // This snippet has been automatically generated and should be regarded as a code template only.
1399
+ * // It will require modifications to work:
1400
+ * // - It may require correct/in-range values for request initialization.
1401
+ * // - It may require specifying regional endpoints when creating the service client as shown in
1402
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1403
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
1404
+ * String project = "project-309310695";
1405
+ * String resource = "resource-341064690";
1406
+ * TestPermissionsRequest testPermissionsRequestResource =
1407
+ * TestPermissionsRequest.newBuilder().build();
1408
+ * TestPermissionsResponse response =
1409
+ * backendBucketsClient.testIamPermissions(
1410
+ * project, resource, testPermissionsRequestResource);
1411
+ * }
1412
+ * }</pre>
1413
+ *
1414
+ * @param project Project ID for this request.
1415
+ * @param resource Name or id of the resource for this request.
1416
+ * @param testPermissionsRequestResource The body resource for this request
1417
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1418
+ */
1419
+ public final TestPermissionsResponse testIamPermissions (
1420
+ String project , String resource , TestPermissionsRequest testPermissionsRequestResource ) {
1421
+ TestIamPermissionsBackendBucketRequest request =
1422
+ TestIamPermissionsBackendBucketRequest .newBuilder ()
1423
+ .setProject (project )
1424
+ .setResource (resource )
1425
+ .setTestPermissionsRequestResource (testPermissionsRequestResource )
1426
+ .build ();
1427
+ return testIamPermissions (request );
1428
+ }
1429
+
1430
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1431
+ /**
1432
+ * Returns permissions that a caller has on the specified resource.
1433
+ *
1434
+ * <p>Sample code:
1435
+ *
1436
+ * <pre>{@code
1437
+ * // This snippet has been automatically generated and should be regarded as a code template only.
1438
+ * // It will require modifications to work:
1439
+ * // - It may require correct/in-range values for request initialization.
1440
+ * // - It may require specifying regional endpoints when creating the service client as shown in
1441
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1442
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
1443
+ * TestIamPermissionsBackendBucketRequest request =
1444
+ * TestIamPermissionsBackendBucketRequest.newBuilder()
1445
+ * .setProject("project-309310695")
1446
+ * .setResource("resource-341064690")
1447
+ * .setTestPermissionsRequestResource(TestPermissionsRequest.newBuilder().build())
1448
+ * .build();
1449
+ * TestPermissionsResponse response = backendBucketsClient.testIamPermissions(request);
1450
+ * }
1451
+ * }</pre>
1452
+ *
1453
+ * @param request The request object containing all of the parameters for the API call.
1454
+ * @throws com.google.api.gax.rpc.ApiException if the remote call fails
1455
+ */
1456
+ public final TestPermissionsResponse testIamPermissions (
1457
+ TestIamPermissionsBackendBucketRequest request ) {
1458
+ return testIamPermissionsCallable ().call (request );
1459
+ }
1460
+
1461
+ // AUTO-GENERATED DOCUMENTATION AND METHOD.
1462
+ /**
1463
+ * Returns permissions that a caller has on the specified resource.
1464
+ *
1465
+ * <p>Sample code:
1466
+ *
1467
+ * <pre>{@code
1468
+ * // This snippet has been automatically generated and should be regarded as a code template only.
1469
+ * // It will require modifications to work:
1470
+ * // - It may require correct/in-range values for request initialization.
1471
+ * // - It may require specifying regional endpoints when creating the service client as shown in
1472
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
1473
+ * try (BackendBucketsClient backendBucketsClient = BackendBucketsClient.create()) {
1474
+ * TestIamPermissionsBackendBucketRequest request =
1475
+ * TestIamPermissionsBackendBucketRequest.newBuilder()
1476
+ * .setProject("project-309310695")
1477
+ * .setResource("resource-341064690")
1478
+ * .setTestPermissionsRequestResource(TestPermissionsRequest.newBuilder().build())
1479
+ * .build();
1480
+ * ApiFuture<TestPermissionsResponse> future =
1481
+ * backendBucketsClient.testIamPermissionsCallable().futureCall(request);
1482
+ * // Do something.
1483
+ * TestPermissionsResponse response = future.get();
1484
+ * }
1485
+ * }</pre>
1486
+ */
1487
+ public final UnaryCallable <TestIamPermissionsBackendBucketRequest , TestPermissionsResponse >
1488
+ testIamPermissionsCallable () {
1489
+ return stub .testIamPermissionsCallable ();
1490
+ }
1491
+
1200
1492
// AUTO-GENERATED DOCUMENTATION AND METHOD.
1201
1493
/**
1202
1494
* Updates the specified BackendBucket resource with the data included in the request.
0 commit comments