|
16 | 16 |
|
17 | 17 | package com.google.cloud.dlp.v2; |
18 | 18 |
|
19 | | -import com.google.api.core.ApiFunction; |
20 | 19 | import com.google.api.core.ApiFuture; |
21 | 20 | import com.google.api.core.ApiFutures; |
22 | 21 | import com.google.api.core.BetaApi; |
@@ -5251,12 +5250,7 @@ public static ApiFuture<ListInspectTemplatesPagedResponse> createAsync( |
5251 | 5250 | ListInspectTemplatesPage.createEmptyPage().createPageAsync(context, futureResponse); |
5252 | 5251 | return ApiFutures.transform( |
5253 | 5252 | futurePage, |
5254 | | - new ApiFunction<ListInspectTemplatesPage, ListInspectTemplatesPagedResponse>() { |
5255 | | - @Override |
5256 | | - public ListInspectTemplatesPagedResponse apply(ListInspectTemplatesPage input) { |
5257 | | - return new ListInspectTemplatesPagedResponse(input); |
5258 | | - } |
5259 | | - }, |
| 5253 | + input -> new ListInspectTemplatesPagedResponse(input), |
5260 | 5254 | MoreExecutors.directExecutor()); |
5261 | 5255 | } |
5262 | 5256 |
|
@@ -5341,12 +5335,7 @@ public static ApiFuture<ListDeidentifyTemplatesPagedResponse> createAsync( |
5341 | 5335 | ListDeidentifyTemplatesPage.createEmptyPage().createPageAsync(context, futureResponse); |
5342 | 5336 | return ApiFutures.transform( |
5343 | 5337 | futurePage, |
5344 | | - new ApiFunction<ListDeidentifyTemplatesPage, ListDeidentifyTemplatesPagedResponse>() { |
5345 | | - @Override |
5346 | | - public ListDeidentifyTemplatesPagedResponse apply(ListDeidentifyTemplatesPage input) { |
5347 | | - return new ListDeidentifyTemplatesPagedResponse(input); |
5348 | | - } |
5349 | | - }, |
| 5338 | + input -> new ListDeidentifyTemplatesPagedResponse(input), |
5350 | 5339 | MoreExecutors.directExecutor()); |
5351 | 5340 | } |
5352 | 5341 |
|
@@ -5432,12 +5421,7 @@ public static ApiFuture<ListJobTriggersPagedResponse> createAsync( |
5432 | 5421 | ListJobTriggersPage.createEmptyPage().createPageAsync(context, futureResponse); |
5433 | 5422 | return ApiFutures.transform( |
5434 | 5423 | futurePage, |
5435 | | - new ApiFunction<ListJobTriggersPage, ListJobTriggersPagedResponse>() { |
5436 | | - @Override |
5437 | | - public ListJobTriggersPagedResponse apply(ListJobTriggersPage input) { |
5438 | | - return new ListJobTriggersPagedResponse(input); |
5439 | | - } |
5440 | | - }, |
| 5424 | + input -> new ListJobTriggersPagedResponse(input), |
5441 | 5425 | MoreExecutors.directExecutor()); |
5442 | 5426 | } |
5443 | 5427 |
|
@@ -5513,14 +5497,7 @@ public static ApiFuture<ListDlpJobsPagedResponse> createAsync( |
5513 | 5497 | ApiFuture<ListDlpJobsPage> futurePage = |
5514 | 5498 | ListDlpJobsPage.createEmptyPage().createPageAsync(context, futureResponse); |
5515 | 5499 | return ApiFutures.transform( |
5516 | | - futurePage, |
5517 | | - new ApiFunction<ListDlpJobsPage, ListDlpJobsPagedResponse>() { |
5518 | | - @Override |
5519 | | - public ListDlpJobsPagedResponse apply(ListDlpJobsPage input) { |
5520 | | - return new ListDlpJobsPagedResponse(input); |
5521 | | - } |
5522 | | - }, |
5523 | | - MoreExecutors.directExecutor()); |
| 5500 | + futurePage, input -> new ListDlpJobsPagedResponse(input), MoreExecutors.directExecutor()); |
5524 | 5501 | } |
5525 | 5502 |
|
5526 | 5503 | private ListDlpJobsPagedResponse(ListDlpJobsPage page) { |
@@ -5595,12 +5572,7 @@ public static ApiFuture<ListStoredInfoTypesPagedResponse> createAsync( |
5595 | 5572 | ListStoredInfoTypesPage.createEmptyPage().createPageAsync(context, futureResponse); |
5596 | 5573 | return ApiFutures.transform( |
5597 | 5574 | futurePage, |
5598 | | - new ApiFunction<ListStoredInfoTypesPage, ListStoredInfoTypesPagedResponse>() { |
5599 | | - @Override |
5600 | | - public ListStoredInfoTypesPagedResponse apply(ListStoredInfoTypesPage input) { |
5601 | | - return new ListStoredInfoTypesPagedResponse(input); |
5602 | | - } |
5603 | | - }, |
| 5575 | + input -> new ListStoredInfoTypesPagedResponse(input), |
5604 | 5576 | MoreExecutors.directExecutor()); |
5605 | 5577 | } |
5606 | 5578 |
|
|
0 commit comments