Skip to content

Commit 559c159

Browse files
committed
---
yaml --- r: 2415 b: refs/heads/update-datastore c: e91f47b h: refs/heads/master i: 2413: bb2274d 2411: 56e9c99 2407: 2b55de7 2399: c80e8fe
1 parent abf110f commit 559c159

18 files changed

Lines changed: 95 additions & 58 deletions

File tree

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/gh-pages: 4e0561bb4504bf647db669a14417b2b2c87ba45d
55
refs/heads/bigquery: 762fa5830e6c398c0396177e3e7fd243bd62cfc3
66
refs/heads/pubsub-alpha: 1a0e970f265af871e02274085b9662b3fe29058b
77
refs/heads/resource-manager: ebf4adc5ee835cd2086c4ac5b4e78d01a5a005a7
8-
refs/heads/update-datastore: 814264ae988bc13cdff311871f575494090b88b2
8+
refs/heads/update-datastore: e91f47b893db5a07b11c6d21299ae9a87165af7e
99
refs/tags/0.0.9: 22f1839238f66c39e67ed4dfdcd273b1ae2e8444
1010
refs/tags/v0.0.10: 207ebd2a3472fddee69fe1298eb90429e3306efd
1111
refs/tags/v0.0.11: ffbfba48a6426ff63c08ff2117e58681f251fbf2

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/Acl.java

Lines changed: 19 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,12 @@ public enum Role {
4848
* Can read, query, copy or export tables in the dataset.
4949
*/
5050
READER,
51+
5152
/**
5253
* Same as {@link #READER} plus can edit or append data in the dataset.
5354
*/
5455
WRITER,
56+
5557
/**
5658
* Same as {@link #WRITER} plus can update and delete the dataset.
5759
*/
@@ -61,7 +63,7 @@ public enum Role {
6163
/**
6264
* Base class for BigQuery entities that can be grant access to the dataset.
6365
*/
64-
public static abstract class Entity implements Serializable {
66+
public abstract static class Entity implements Serializable {
6567

6668
private static final long serialVersionUID = 8111776788607959944L;
6769

@@ -132,14 +134,14 @@ public String domain() {
132134
}
133135

134136
@Override
135-
public boolean equals(Object o) {
136-
if (this == o) {
137+
public boolean equals(Object obj) {
138+
if (this == obj) {
137139
return true;
138140
}
139-
if (o == null || getClass() != o.getClass()) {
141+
if (obj == null || getClass() != obj.getClass()) {
140142
return false;
141143
}
142-
Domain domainEntity = (Domain) o;
144+
Domain domainEntity = (Domain) obj;
143145
return Objects.equals(type(), domainEntity.type())
144146
&& Objects.equals(domain, domainEntity.domain());
145147
}
@@ -196,14 +198,14 @@ public String identifier() {
196198
}
197199

198200
@Override
199-
public boolean equals(Object o) {
200-
if (this == o) {
201+
public boolean equals(Object obj) {
202+
if (this == obj) {
201203
return true;
202204
}
203-
if (o == null || getClass() != o.getClass()) {
205+
if (obj == null || getClass() != obj.getClass()) {
204206
return false;
205207
}
206-
Group group = (Group) o;
208+
Group group = (Group) obj;
207209
return Objects.equals(type(), group.type()) && Objects.equals(identifier, group.identifier);
208210
}
209211

@@ -288,14 +290,14 @@ public String email() {
288290
}
289291

290292
@Override
291-
public boolean equals(Object o) {
292-
if (this == o) {
293+
public boolean equals(Object obj) {
294+
if (this == obj) {
293295
return true;
294296
}
295-
if (o == null || getClass() != o.getClass()) {
297+
if (obj == null || getClass() != obj.getClass()) {
296298
return false;
297299
}
298-
User user = (User) o;
300+
User user = (User) obj;
299301
return Objects.equals(type(), user.type()) && Objects.equals(email, user.email);
300302
}
301303

@@ -341,14 +343,14 @@ public TableId id() {
341343
}
342344

343345
@Override
344-
public boolean equals(Object o) {
345-
if (this == o) {
346+
public boolean equals(Object obj) {
347+
if (this == obj) {
346348
return true;
347349
}
348-
if (o == null || getClass() != o.getClass()) {
350+
if (obj == null || getClass() != obj.getClass()) {
349351
return false;
350352
}
351-
View view = (View) o;
353+
View view = (View) obj;
352354
return Objects.equals(type(), view.type()) && Objects.equals(id, view.id);
353355
}
354356

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/BaseTableInfo.java

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
import com.google.api.services.bigquery.model.Table;
2525
import com.google.common.base.Function;
2626
import com.google.common.base.MoreObjects;
27+
import com.google.common.base.MoreObjects.ToStringHelper;
2728

2829
import java.io.Serializable;
2930
import java.math.BigInteger;
@@ -63,12 +64,14 @@ public enum Type {
6364
* A normal BigQuery table.
6465
*/
6566
TABLE,
67+
6668
/**
6769
* A virtual table defined by a SQL query.
6870
*
6971
* @see <a href="https://cloud.google.com/bigquery/querying-data#views">Views</a>
7072
*/
7173
VIEW,
74+
7275
/**
7376
* A BigQuery table backed by external data.
7477
*
@@ -137,7 +140,7 @@ public boolean equals(Object obj) {
137140
&& Objects.equals(toPb(), ((StreamingBuffer) obj).toPb());
138141
}
139142

140-
public Streamingbuffer toPb() {
143+
Streamingbuffer toPb() {
141144
return new Streamingbuffer()
142145
.setEstimatedBytes(BigInteger.valueOf(estimatedBytes))
143146
.setEstimatedRows(BigInteger.valueOf(estimatedRows))
@@ -165,7 +168,7 @@ static StreamingBuffer fromPb(Streamingbuffer streamingBufferPb) {
165168
private final Long expirationTime;
166169
private final Long lastModifiedTime;
167170

168-
public static abstract class Builder<T extends BaseTableInfo, B extends Builder<T, B>> {
171+
public abstract static class Builder<T extends BaseTableInfo, B extends Builder<T, B>> {
169172

170173
private String etag;
171174
private String id;
@@ -429,7 +432,7 @@ public Long lastModifiedTime() {
429432
*/
430433
public abstract Builder toBuilder();
431434

432-
protected MoreObjects.ToStringHelper toStringHelper() {
435+
ToStringHelper toStringHelper() {
433436
return MoreObjects.toStringHelper(this)
434437
.add("tableId", tableId)
435438
.add("type", type)

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/CsvOptions.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,9 @@ public Integer skipLeadingRows() {
190190
return skipLeadingRows;
191191
}
192192

193+
/**
194+
* Returns a builder for the {@code CsvOptions} object.
195+
*/
193196
public Builder toBuilder() {
194197
return new Builder()
195198
.allowJaggedRows(allowJaggedRows)

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/DatasetId.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ public class DatasetId implements Serializable {
3434
private final String dataset;
3535

3636
/**
37-
* Returns project's user-defined id
37+
* Returns project's user-defined id.
3838
*/
3939
public String project() {
4040
return project;
@@ -81,11 +81,11 @@ public String toString() {
8181
return toPb().toString();
8282
}
8383

84-
public DatasetReference toPb() {
84+
DatasetReference toPb() {
8585
return new DatasetReference().setProjectId(project).setDatasetId(dataset);
8686
}
8787

88-
public static DatasetId fromPb(DatasetReference datasetRef) {
88+
static DatasetId fromPb(DatasetReference datasetRef) {
8989
return new DatasetId(
9090
datasetRef.getProjectId(),
9191
datasetRef.getDatasetId());

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/DatasetInfo.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -384,8 +384,8 @@ static DatasetInfo fromPb(Dataset datasetPb) {
384384
builder.acl(Lists.transform(datasetPb.getAccess(),
385385
new Function<Dataset.Access, Acl>() {
386386
@Override
387-
public Acl apply(Dataset.Access f) {
388-
return Acl.fromPb(f);
387+
public Acl apply(Dataset.Access accessPb) {
388+
return Acl.fromPb(accessPb);
389389
}
390390
}));
391391
}

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/ExternalTableInfo.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
import static com.google.common.base.Preconditions.checkNotNull;
2020

2121
import com.google.api.services.bigquery.model.Table;
22-
import com.google.common.base.MoreObjects;
22+
import com.google.common.base.MoreObjects.ToStringHelper;
2323

2424
/**
2525
* Google BigQuery External Table information. BigQuery's external tables are tables whose data
@@ -100,7 +100,7 @@ private ExternalTableInfo(Builder builder) {
100100
*/
101101
public ExternalDataConfiguration configuration() {
102102
return configuration;
103-
};
103+
}
104104

105105
/**
106106
* Returns information on the table's streaming buffer if any exists. Returns {@code null} if no
@@ -119,7 +119,7 @@ public Builder toBuilder() {
119119
}
120120

121121
@Override
122-
protected MoreObjects.ToStringHelper toStringHelper() {
122+
ToStringHelper toStringHelper() {
123123
return super.toStringHelper()
124124
.add("configuration", configuration)
125125
.add("streamingBuffer", streamingBuffer);

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/Field.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,10 @@
3232
import java.util.Objects;
3333

3434
/**
35-
* Google BigQuery Table field. A table field has a name, a value, a mode and possibly a description.
36-
* Supported types are: {@link Type#integer()}, {@link Type#bool()}, {@link Type#string()},
37-
* {@link Type#floatingPoint()}, {@link Type#timestamp()} and {@link Type#record(Field...)}. One or
38-
* more fields form a table's schema.
35+
* Google BigQuery Table field. A table field has a name, a value, a mode and possibly a
36+
* description. Supported types are: {@link Type#integer()}, {@link Type#bool()},
37+
* {@link Type#string()}, {@link Type#floatingPoint()}, {@link Type#timestamp()} and
38+
* {@link Type#record(Field...)}. One or more fields form a table's schema.
3939
*/
4040
public class Field implements Serializable {
4141

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/JobId.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,9 @@ public String job() {
4747
return job;
4848
}
4949

50-
private JobId(String project, String dataset) {
50+
private JobId(String project, String job) {
5151
this.project = project;
52-
this.job = dataset;
52+
this.job = job;
5353
}
5454

5555
/**

branches/update-datastore/gcloud-java-bigquery/src/main/java/com/google/gcloud/bigquery/JobInfo.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ public String userEmail() {
241241

242242
ToStringHelper toStringHelper() {
243243
return MoreObjects.toStringHelper(this)
244-
.add("jobId", jobId)
244+
.add("job", jobId)
245245
.add("status", status)
246246
.add("statistics", statistics)
247247
.add("userEmail", userEmail)

0 commit comments

Comments
 (0)