|
18 | 18 |
|
19 | 19 | import com.google.api.MetricDescriptor;
|
20 | 20 | import com.google.api.MonitoredResourceDescriptor;
|
21 |
| -import com.google.api.core.ApiFunction; |
22 | 21 | import com.google.api.core.ApiFuture;
|
23 | 22 | import com.google.api.core.ApiFutures;
|
24 | 23 | import com.google.api.core.BetaApi;
|
@@ -1602,15 +1601,7 @@ public static ApiFuture<ListMonitoredResourceDescriptorsPagedResponse> createAsy
|
1602 | 1601 | .createPageAsync(context, futureResponse);
|
1603 | 1602 | return ApiFutures.transform(
|
1604 | 1603 | futurePage,
|
1605 |
| - new ApiFunction< |
1606 |
| - ListMonitoredResourceDescriptorsPage, |
1607 |
| - ListMonitoredResourceDescriptorsPagedResponse>() { |
1608 |
| - @Override |
1609 |
| - public ListMonitoredResourceDescriptorsPagedResponse apply( |
1610 |
| - ListMonitoredResourceDescriptorsPage input) { |
1611 |
| - return new ListMonitoredResourceDescriptorsPagedResponse(input); |
1612 |
| - } |
1613 |
| - }, |
| 1604 | + input -> new ListMonitoredResourceDescriptorsPagedResponse(input), |
1614 | 1605 | MoreExecutors.directExecutor());
|
1615 | 1606 | }
|
1616 | 1607 |
|
@@ -1704,12 +1695,7 @@ public static ApiFuture<ListMetricDescriptorsPagedResponse> createAsync(
|
1704 | 1695 | ListMetricDescriptorsPage.createEmptyPage().createPageAsync(context, futureResponse);
|
1705 | 1696 | return ApiFutures.transform(
|
1706 | 1697 | futurePage,
|
1707 |
| - new ApiFunction<ListMetricDescriptorsPage, ListMetricDescriptorsPagedResponse>() { |
1708 |
| - @Override |
1709 |
| - public ListMetricDescriptorsPagedResponse apply(ListMetricDescriptorsPage input) { |
1710 |
| - return new ListMetricDescriptorsPagedResponse(input); |
1711 |
| - } |
1712 |
| - }, |
| 1698 | + input -> new ListMetricDescriptorsPagedResponse(input), |
1713 | 1699 | MoreExecutors.directExecutor());
|
1714 | 1700 | }
|
1715 | 1701 |
|
@@ -1792,12 +1778,7 @@ public static ApiFuture<ListTimeSeriesPagedResponse> createAsync(
|
1792 | 1778 | ListTimeSeriesPage.createEmptyPage().createPageAsync(context, futureResponse);
|
1793 | 1779 | return ApiFutures.transform(
|
1794 | 1780 | futurePage,
|
1795 |
| - new ApiFunction<ListTimeSeriesPage, ListTimeSeriesPagedResponse>() { |
1796 |
| - @Override |
1797 |
| - public ListTimeSeriesPagedResponse apply(ListTimeSeriesPage input) { |
1798 |
| - return new ListTimeSeriesPagedResponse(input); |
1799 |
| - } |
1800 |
| - }, |
| 1781 | + input -> new ListTimeSeriesPagedResponse(input), |
1801 | 1782 | MoreExecutors.directExecutor());
|
1802 | 1783 | }
|
1803 | 1784 |
|
|
0 commit comments