Skip to content

Commit 34d247e

Browse files
committed
Fix BigQuery parameter names
1 parent 0e61bd3 commit 34d247e

3 files changed

Lines changed: 25 additions & 25 deletions

File tree

google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/BigQuery.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -454,7 +454,7 @@ public static QueryResultsOption maxWaitTime(long maxWaitTime) {
454454
*
455455
* @throws BigQueryException upon failure
456456
*/
457-
Dataset create(DatasetInfo dataset, DatasetOption... options);
457+
Dataset create(DatasetInfo datasetInfo, DatasetOption... options);
458458

459459
/**
460460
* Creates a new table.
@@ -476,7 +476,7 @@ public static QueryResultsOption maxWaitTime(long maxWaitTime) {
476476
*
477477
* @throws BigQueryException upon failure
478478
*/
479-
Table create(TableInfo table, TableOption... options);
479+
Table create(TableInfo tableInfo, TableOption... options);
480480

481481
/**
482482
* Creates a new job.
@@ -496,7 +496,7 @@ public static QueryResultsOption maxWaitTime(long maxWaitTime) {
496496
*
497497
* @throws BigQueryException upon failure
498498
*/
499-
Job create(JobInfo job, JobOption... options);
499+
Job create(JobInfo jobInfo, JobOption... options);
500500

501501
/**
502502
* Returns the requested dataset or {@code null} if not found.
@@ -665,7 +665,7 @@ public static QueryResultsOption maxWaitTime(long maxWaitTime) {
665665
*
666666
* @throws BigQueryException upon failure
667667
*/
668-
Dataset update(DatasetInfo dataset, DatasetOption... options);
668+
Dataset update(DatasetInfo datasetInfo, DatasetOption... options);
669669

670670
/**
671671
* Updates table information.
@@ -682,7 +682,7 @@ public static QueryResultsOption maxWaitTime(long maxWaitTime) {
682682
*
683683
* @throws BigQueryException upon failure
684684
*/
685-
Table update(TableInfo table, TableOption... options);
685+
Table update(TableInfo tableInfo, TableOption... options);
686686

687687
/**
688688
* Returns the requested table or {@code null} if not found.
@@ -924,7 +924,7 @@ Page<List<FieldValue>> listTableData(String datasetId, String tableId,
924924
* found
925925
* @throws BigQueryException upon failure
926926
*/
927-
boolean cancel(JobId tableId);
927+
boolean cancel(JobId jobId);
928928

929929
/**
930930
* Runs the query associated with the request.
@@ -980,7 +980,7 @@ Page<List<FieldValue>> listTableData(String datasetId, String tableId,
980980
*
981981
* @throws BigQueryException upon failure
982982
*/
983-
QueryResponse getQueryResults(JobId job, QueryResultsOption... options);
983+
QueryResponse getQueryResults(JobId jobId, QueryResultsOption... options);
984984

985985
/**
986986
* Returns a channel to write data to be inserted into a BigQuery table. Data format and other

google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/BigQueryImpl.java

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -155,9 +155,9 @@ public QueryResult nextPage() {
155155
}
156156

157157
@Override
158-
public Dataset create(DatasetInfo dataset, DatasetOption... options) {
158+
public Dataset create(DatasetInfo datasetInfo, DatasetOption... options) {
159159
final com.google.api.services.bigquery.model.Dataset datasetPb =
160-
dataset.setProjectId(options().projectId()).toPb();
160+
datasetInfo.setProjectId(options().projectId()).toPb();
161161
final Map<BigQueryRpc.Option, ?> optionsMap = optionMap(options);
162162
try {
163163
return Dataset.fromPb(this,
@@ -173,9 +173,9 @@ public com.google.api.services.bigquery.model.Dataset call() {
173173
}
174174

175175
@Override
176-
public Table create(TableInfo table, TableOption... options) {
176+
public Table create(TableInfo tableInfo, TableOption... options) {
177177
final com.google.api.services.bigquery.model.Table tablePb =
178-
table.setProjectId(options().projectId()).toPb();
178+
tableInfo.setProjectId(options().projectId()).toPb();
179179
final Map<BigQueryRpc.Option, ?> optionsMap = optionMap(options);
180180
try {
181181
return Table.fromPb(this,
@@ -191,9 +191,9 @@ public com.google.api.services.bigquery.model.Table call() {
191191
}
192192

193193
@Override
194-
public Job create(JobInfo job, JobOption... options) {
194+
public Job create(JobInfo jobInfo, JobOption... options) {
195195
final com.google.api.services.bigquery.model.Job jobPb =
196-
job.setProjectId(options().projectId()).toPb();
196+
jobInfo.setProjectId(options().projectId()).toPb();
197197
final Map<BigQueryRpc.Option, ?> optionsMap = optionMap(options);
198198
try {
199199
return Job.fromPb(this,
@@ -312,9 +312,9 @@ public Boolean call() {
312312
}
313313

314314
@Override
315-
public Dataset update(DatasetInfo dataset, DatasetOption... options) {
315+
public Dataset update(DatasetInfo datasetInfo, DatasetOption... options) {
316316
final com.google.api.services.bigquery.model.Dataset datasetPb =
317-
dataset.setProjectId(options().projectId()).toPb();
317+
datasetInfo.setProjectId(options().projectId()).toPb();
318318
final Map<BigQueryRpc.Option, ?> optionsMap = optionMap(options);
319319
try {
320320
return Dataset.fromPb(this,
@@ -330,9 +330,9 @@ public com.google.api.services.bigquery.model.Dataset call() {
330330
}
331331

332332
@Override
333-
public Table update(TableInfo table, TableOption... options) {
333+
public Table update(TableInfo tableInfo, TableOption... options) {
334334
final com.google.api.services.bigquery.model.Table tablePb =
335-
table.setProjectId(options().projectId()).toPb();
335+
tableInfo.setProjectId(options().projectId()).toPb();
336336
final Map<BigQueryRpc.Option, ?> optionsMap = optionMap(options);
337337
try {
338338
return Table.fromPb(this,
@@ -582,9 +582,9 @@ public com.google.api.services.bigquery.model.QueryResponse call() {
582582
}
583583

584584
@Override
585-
public QueryResponse getQueryResults(JobId job, QueryResultsOption... options) {
585+
public QueryResponse getQueryResults(JobId jobId, QueryResultsOption... options) {
586586
Map<BigQueryRpc.Option, ?> optionsMap = optionMap(options);
587-
return getQueryResults(job, options(), optionsMap);
587+
return getQueryResults(jobId, options(), optionsMap);
588588
}
589589

590590
private static QueryResponse getQueryResults(JobId jobId,

google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/Dataset.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -251,12 +251,12 @@ public Page<Table> list(TableListOption... options) {
251251
* Table table = dataset.get(tableName);
252252
* }</pre>
253253
*
254-
* @param table user-defined id of the requested table
254+
* @param tableId user-defined id of the requested table
255255
* @param options table options
256256
* @throws BigQueryException upon failure
257257
*/
258-
public Table get(String table, TableOption... options) {
259-
return bigquery.getTable(TableId.of(datasetId().dataset(), table), options);
258+
public Table get(String tableId, TableOption... options) {
259+
return bigquery.getTable(TableId.of(datasetId().dataset(), tableId), options);
260260
}
261261

262262
/**
@@ -274,14 +274,14 @@ public Table get(String table, TableOption... options) {
274274
* Table table = dataset.create(tableName, definition);
275275
* }</pre>
276276
*
277-
* @param table the table's user-defined id
277+
* @param tableId the table's user-defined id
278278
* @param definition the table's definition
279279
* @param options options for table creation
280280
* @return a {@code Table} object for the created table
281281
* @throws BigQueryException upon failure
282282
*/
283-
public Table create(String table, TableDefinition definition, TableOption... options) {
284-
TableInfo tableInfo = TableInfo.of(TableId.of(datasetId().dataset(), table), definition);
283+
public Table create(String tableId, TableDefinition definition, TableOption... options) {
284+
TableInfo tableInfo = TableInfo.of(TableId.of(datasetId().dataset(), tableId), definition);
285285
return bigquery.create(tableInfo, options);
286286
}
287287

0 commit comments

Comments
 (0)