Skip to content

Commit 2f5d941

Browse files
authored
Regenerate google-cloud-java with PageResponseWrapprs removed, add speech v1p1beta1 (googleapis#2927)
1 parent 45a9978 commit 2f5d941

File tree

156 files changed

+5416
-3662
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

156 files changed

+5416
-3662
lines changed

google-cloud-bigquerydatatransfer/src/main/java/com/google/cloud/bigquery/datatransfer/v1/DataTransferServiceClient.java

Lines changed: 314 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,20 +15,23 @@
1515
*/
1616
package com.google.cloud.bigquery.datatransfer.v1;
1717

18-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListDataSourcesPagedResponse;
19-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListTransferConfigsPagedResponse;
20-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListTransferLogsPagedResponse;
21-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListTransferRunsPagedResponse;
22-
18+
import com.google.api.core.ApiFunction;
19+
import com.google.api.core.ApiFuture;
20+
import com.google.api.core.ApiFutures;
2321
import com.google.api.core.BetaApi;
2422
import com.google.api.gax.core.BackgroundResource;
23+
import com.google.api.gax.paging.AbstractFixedSizeCollection;
24+
import com.google.api.gax.paging.AbstractPage;
25+
import com.google.api.gax.paging.AbstractPagedListResponse;
26+
import com.google.api.gax.rpc.PageContext;
2527
import com.google.api.gax.rpc.UnaryCallable;
2628
import com.google.cloud.bigquery.datatransfer.v1.stub.DataTransferServiceStub;
2729
import com.google.cloud.bigquery.datatransfer.v1.stub.DataTransferServiceStubSettings;
2830
import com.google.protobuf.Empty;
2931
import com.google.protobuf.FieldMask;
3032
import com.google.protobuf.Timestamp;
3133
import java.io.IOException;
34+
import java.util.List;
3235
import java.util.concurrent.TimeUnit;
3336
import javax.annotation.Generated;
3437

@@ -1293,4 +1296,310 @@ public void shutdownNow() {
12931296
public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException {
12941297
return stub.awaitTermination(duration, unit);
12951298
}
1299+
1300+
public static class ListDataSourcesPagedResponse
1301+
extends AbstractPagedListResponse<
1302+
ListDataSourcesRequest, ListDataSourcesResponse, DataSource, ListDataSourcesPage,
1303+
ListDataSourcesFixedSizeCollection> {
1304+
1305+
public static ApiFuture<ListDataSourcesPagedResponse> createAsync(
1306+
PageContext<ListDataSourcesRequest, ListDataSourcesResponse, DataSource> context,
1307+
ApiFuture<ListDataSourcesResponse> futureResponse) {
1308+
ApiFuture<ListDataSourcesPage> futurePage =
1309+
ListDataSourcesPage.createEmptyPage().createPageAsync(context, futureResponse);
1310+
return ApiFutures.transform(
1311+
futurePage,
1312+
new ApiFunction<ListDataSourcesPage, ListDataSourcesPagedResponse>() {
1313+
@Override
1314+
public ListDataSourcesPagedResponse apply(ListDataSourcesPage input) {
1315+
return new ListDataSourcesPagedResponse(input);
1316+
}
1317+
});
1318+
}
1319+
1320+
private ListDataSourcesPagedResponse(ListDataSourcesPage page) {
1321+
super(page, ListDataSourcesFixedSizeCollection.createEmptyCollection());
1322+
}
1323+
}
1324+
1325+
public static class ListDataSourcesPage
1326+
extends AbstractPage<
1327+
ListDataSourcesRequest, ListDataSourcesResponse, DataSource, ListDataSourcesPage> {
1328+
1329+
private ListDataSourcesPage(
1330+
PageContext<ListDataSourcesRequest, ListDataSourcesResponse, DataSource> context,
1331+
ListDataSourcesResponse response) {
1332+
super(context, response);
1333+
}
1334+
1335+
private static ListDataSourcesPage createEmptyPage() {
1336+
return new ListDataSourcesPage(null, null);
1337+
}
1338+
1339+
@Override
1340+
protected ListDataSourcesPage createPage(
1341+
PageContext<ListDataSourcesRequest, ListDataSourcesResponse, DataSource> context,
1342+
ListDataSourcesResponse response) {
1343+
return new ListDataSourcesPage(context, response);
1344+
}
1345+
1346+
@Override
1347+
public ApiFuture<ListDataSourcesPage> createPageAsync(
1348+
PageContext<ListDataSourcesRequest, ListDataSourcesResponse, DataSource> context,
1349+
ApiFuture<ListDataSourcesResponse> futureResponse) {
1350+
return super.createPageAsync(context, futureResponse);
1351+
}
1352+
}
1353+
1354+
public static class ListDataSourcesFixedSizeCollection
1355+
extends AbstractFixedSizeCollection<
1356+
ListDataSourcesRequest, ListDataSourcesResponse, DataSource, ListDataSourcesPage,
1357+
ListDataSourcesFixedSizeCollection> {
1358+
1359+
private ListDataSourcesFixedSizeCollection(
1360+
List<ListDataSourcesPage> pages, int collectionSize) {
1361+
super(pages, collectionSize);
1362+
}
1363+
1364+
private static ListDataSourcesFixedSizeCollection createEmptyCollection() {
1365+
return new ListDataSourcesFixedSizeCollection(null, 0);
1366+
}
1367+
1368+
@Override
1369+
protected ListDataSourcesFixedSizeCollection createCollection(
1370+
List<ListDataSourcesPage> pages, int collectionSize) {
1371+
return new ListDataSourcesFixedSizeCollection(pages, collectionSize);
1372+
}
1373+
}
1374+
1375+
public static class ListTransferConfigsPagedResponse
1376+
extends AbstractPagedListResponse<
1377+
ListTransferConfigsRequest, ListTransferConfigsResponse, TransferConfig,
1378+
ListTransferConfigsPage, ListTransferConfigsFixedSizeCollection> {
1379+
1380+
public static ApiFuture<ListTransferConfigsPagedResponse> createAsync(
1381+
PageContext<ListTransferConfigsRequest, ListTransferConfigsResponse, TransferConfig>
1382+
context,
1383+
ApiFuture<ListTransferConfigsResponse> futureResponse) {
1384+
ApiFuture<ListTransferConfigsPage> futurePage =
1385+
ListTransferConfigsPage.createEmptyPage().createPageAsync(context, futureResponse);
1386+
return ApiFutures.transform(
1387+
futurePage,
1388+
new ApiFunction<ListTransferConfigsPage, ListTransferConfigsPagedResponse>() {
1389+
@Override
1390+
public ListTransferConfigsPagedResponse apply(ListTransferConfigsPage input) {
1391+
return new ListTransferConfigsPagedResponse(input);
1392+
}
1393+
});
1394+
}
1395+
1396+
private ListTransferConfigsPagedResponse(ListTransferConfigsPage page) {
1397+
super(page, ListTransferConfigsFixedSizeCollection.createEmptyCollection());
1398+
}
1399+
}
1400+
1401+
public static class ListTransferConfigsPage
1402+
extends AbstractPage<
1403+
ListTransferConfigsRequest, ListTransferConfigsResponse, TransferConfig,
1404+
ListTransferConfigsPage> {
1405+
1406+
private ListTransferConfigsPage(
1407+
PageContext<ListTransferConfigsRequest, ListTransferConfigsResponse, TransferConfig>
1408+
context,
1409+
ListTransferConfigsResponse response) {
1410+
super(context, response);
1411+
}
1412+
1413+
private static ListTransferConfigsPage createEmptyPage() {
1414+
return new ListTransferConfigsPage(null, null);
1415+
}
1416+
1417+
@Override
1418+
protected ListTransferConfigsPage createPage(
1419+
PageContext<ListTransferConfigsRequest, ListTransferConfigsResponse, TransferConfig>
1420+
context,
1421+
ListTransferConfigsResponse response) {
1422+
return new ListTransferConfigsPage(context, response);
1423+
}
1424+
1425+
@Override
1426+
public ApiFuture<ListTransferConfigsPage> createPageAsync(
1427+
PageContext<ListTransferConfigsRequest, ListTransferConfigsResponse, TransferConfig>
1428+
context,
1429+
ApiFuture<ListTransferConfigsResponse> futureResponse) {
1430+
return super.createPageAsync(context, futureResponse);
1431+
}
1432+
}
1433+
1434+
public static class ListTransferConfigsFixedSizeCollection
1435+
extends AbstractFixedSizeCollection<
1436+
ListTransferConfigsRequest, ListTransferConfigsResponse, TransferConfig,
1437+
ListTransferConfigsPage, ListTransferConfigsFixedSizeCollection> {
1438+
1439+
private ListTransferConfigsFixedSizeCollection(
1440+
List<ListTransferConfigsPage> pages, int collectionSize) {
1441+
super(pages, collectionSize);
1442+
}
1443+
1444+
private static ListTransferConfigsFixedSizeCollection createEmptyCollection() {
1445+
return new ListTransferConfigsFixedSizeCollection(null, 0);
1446+
}
1447+
1448+
@Override
1449+
protected ListTransferConfigsFixedSizeCollection createCollection(
1450+
List<ListTransferConfigsPage> pages, int collectionSize) {
1451+
return new ListTransferConfigsFixedSizeCollection(pages, collectionSize);
1452+
}
1453+
}
1454+
1455+
public static class ListTransferRunsPagedResponse
1456+
extends AbstractPagedListResponse<
1457+
ListTransferRunsRequest, ListTransferRunsResponse, TransferRun, ListTransferRunsPage,
1458+
ListTransferRunsFixedSizeCollection> {
1459+
1460+
public static ApiFuture<ListTransferRunsPagedResponse> createAsync(
1461+
PageContext<ListTransferRunsRequest, ListTransferRunsResponse, TransferRun> context,
1462+
ApiFuture<ListTransferRunsResponse> futureResponse) {
1463+
ApiFuture<ListTransferRunsPage> futurePage =
1464+
ListTransferRunsPage.createEmptyPage().createPageAsync(context, futureResponse);
1465+
return ApiFutures.transform(
1466+
futurePage,
1467+
new ApiFunction<ListTransferRunsPage, ListTransferRunsPagedResponse>() {
1468+
@Override
1469+
public ListTransferRunsPagedResponse apply(ListTransferRunsPage input) {
1470+
return new ListTransferRunsPagedResponse(input);
1471+
}
1472+
});
1473+
}
1474+
1475+
private ListTransferRunsPagedResponse(ListTransferRunsPage page) {
1476+
super(page, ListTransferRunsFixedSizeCollection.createEmptyCollection());
1477+
}
1478+
}
1479+
1480+
public static class ListTransferRunsPage
1481+
extends AbstractPage<
1482+
ListTransferRunsRequest, ListTransferRunsResponse, TransferRun, ListTransferRunsPage> {
1483+
1484+
private ListTransferRunsPage(
1485+
PageContext<ListTransferRunsRequest, ListTransferRunsResponse, TransferRun> context,
1486+
ListTransferRunsResponse response) {
1487+
super(context, response);
1488+
}
1489+
1490+
private static ListTransferRunsPage createEmptyPage() {
1491+
return new ListTransferRunsPage(null, null);
1492+
}
1493+
1494+
@Override
1495+
protected ListTransferRunsPage createPage(
1496+
PageContext<ListTransferRunsRequest, ListTransferRunsResponse, TransferRun> context,
1497+
ListTransferRunsResponse response) {
1498+
return new ListTransferRunsPage(context, response);
1499+
}
1500+
1501+
@Override
1502+
public ApiFuture<ListTransferRunsPage> createPageAsync(
1503+
PageContext<ListTransferRunsRequest, ListTransferRunsResponse, TransferRun> context,
1504+
ApiFuture<ListTransferRunsResponse> futureResponse) {
1505+
return super.createPageAsync(context, futureResponse);
1506+
}
1507+
}
1508+
1509+
public static class ListTransferRunsFixedSizeCollection
1510+
extends AbstractFixedSizeCollection<
1511+
ListTransferRunsRequest, ListTransferRunsResponse, TransferRun, ListTransferRunsPage,
1512+
ListTransferRunsFixedSizeCollection> {
1513+
1514+
private ListTransferRunsFixedSizeCollection(
1515+
List<ListTransferRunsPage> pages, int collectionSize) {
1516+
super(pages, collectionSize);
1517+
}
1518+
1519+
private static ListTransferRunsFixedSizeCollection createEmptyCollection() {
1520+
return new ListTransferRunsFixedSizeCollection(null, 0);
1521+
}
1522+
1523+
@Override
1524+
protected ListTransferRunsFixedSizeCollection createCollection(
1525+
List<ListTransferRunsPage> pages, int collectionSize) {
1526+
return new ListTransferRunsFixedSizeCollection(pages, collectionSize);
1527+
}
1528+
}
1529+
1530+
public static class ListTransferLogsPagedResponse
1531+
extends AbstractPagedListResponse<
1532+
ListTransferLogsRequest, ListTransferLogsResponse, TransferMessage, ListTransferLogsPage,
1533+
ListTransferLogsFixedSizeCollection> {
1534+
1535+
public static ApiFuture<ListTransferLogsPagedResponse> createAsync(
1536+
PageContext<ListTransferLogsRequest, ListTransferLogsResponse, TransferMessage> context,
1537+
ApiFuture<ListTransferLogsResponse> futureResponse) {
1538+
ApiFuture<ListTransferLogsPage> futurePage =
1539+
ListTransferLogsPage.createEmptyPage().createPageAsync(context, futureResponse);
1540+
return ApiFutures.transform(
1541+
futurePage,
1542+
new ApiFunction<ListTransferLogsPage, ListTransferLogsPagedResponse>() {
1543+
@Override
1544+
public ListTransferLogsPagedResponse apply(ListTransferLogsPage input) {
1545+
return new ListTransferLogsPagedResponse(input);
1546+
}
1547+
});
1548+
}
1549+
1550+
private ListTransferLogsPagedResponse(ListTransferLogsPage page) {
1551+
super(page, ListTransferLogsFixedSizeCollection.createEmptyCollection());
1552+
}
1553+
}
1554+
1555+
public static class ListTransferLogsPage
1556+
extends AbstractPage<
1557+
ListTransferLogsRequest, ListTransferLogsResponse, TransferMessage,
1558+
ListTransferLogsPage> {
1559+
1560+
private ListTransferLogsPage(
1561+
PageContext<ListTransferLogsRequest, ListTransferLogsResponse, TransferMessage> context,
1562+
ListTransferLogsResponse response) {
1563+
super(context, response);
1564+
}
1565+
1566+
private static ListTransferLogsPage createEmptyPage() {
1567+
return new ListTransferLogsPage(null, null);
1568+
}
1569+
1570+
@Override
1571+
protected ListTransferLogsPage createPage(
1572+
PageContext<ListTransferLogsRequest, ListTransferLogsResponse, TransferMessage> context,
1573+
ListTransferLogsResponse response) {
1574+
return new ListTransferLogsPage(context, response);
1575+
}
1576+
1577+
@Override
1578+
public ApiFuture<ListTransferLogsPage> createPageAsync(
1579+
PageContext<ListTransferLogsRequest, ListTransferLogsResponse, TransferMessage> context,
1580+
ApiFuture<ListTransferLogsResponse> futureResponse) {
1581+
return super.createPageAsync(context, futureResponse);
1582+
}
1583+
}
1584+
1585+
public static class ListTransferLogsFixedSizeCollection
1586+
extends AbstractFixedSizeCollection<
1587+
ListTransferLogsRequest, ListTransferLogsResponse, TransferMessage, ListTransferLogsPage,
1588+
ListTransferLogsFixedSizeCollection> {
1589+
1590+
private ListTransferLogsFixedSizeCollection(
1591+
List<ListTransferLogsPage> pages, int collectionSize) {
1592+
super(pages, collectionSize);
1593+
}
1594+
1595+
private static ListTransferLogsFixedSizeCollection createEmptyCollection() {
1596+
return new ListTransferLogsFixedSizeCollection(null, 0);
1597+
}
1598+
1599+
@Override
1600+
protected ListTransferLogsFixedSizeCollection createCollection(
1601+
List<ListTransferLogsPage> pages, int collectionSize) {
1602+
return new ListTransferLogsFixedSizeCollection(pages, collectionSize);
1603+
}
1604+
}
12961605
}

google-cloud-bigquerydatatransfer/src/main/java/com/google/cloud/bigquery/datatransfer/v1/DataTransferServiceSettings.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@
1515
*/
1616
package com.google.cloud.bigquery.datatransfer.v1;
1717

18-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListDataSourcesPagedResponse;
19-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListTransferConfigsPagedResponse;
20-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListTransferLogsPagedResponse;
21-
import static com.google.cloud.bigquery.datatransfer.v1.PagedResponseWrappers.ListTransferRunsPagedResponse;
18+
import static com.google.cloud.bigquery.datatransfer.v1.DataTransferServiceClient.ListDataSourcesPagedResponse;
19+
import static com.google.cloud.bigquery.datatransfer.v1.DataTransferServiceClient.ListTransferConfigsPagedResponse;
20+
import static com.google.cloud.bigquery.datatransfer.v1.DataTransferServiceClient.ListTransferLogsPagedResponse;
21+
import static com.google.cloud.bigquery.datatransfer.v1.DataTransferServiceClient.ListTransferRunsPagedResponse;
2222

2323
import com.google.api.core.ApiFunction;
2424
import com.google.api.core.BetaApi;

0 commit comments

Comments
 (0)