Skip to content

Commit 2470206

Browse files
committed
adding documentation
1 parent 5ce7a2b commit 2470206

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

google-cloud-spanner/src/main/java/com/google/cloud/spanner/Backup.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ static Backup fromProto(
177177
checkArgument(!proto.getDatabase().isEmpty(), "Missing expected 'database' field");
178178
return new Backup.Builder(client, BackupId.of(proto.getName()))
179179
.setState(fromProtoState(proto.getState()))
180-
.setSize(proto.getSizeBytes())
180+
.setSize(proto.getSiprotected abstract Builder setMaxExpireTime(Timestamp maxExpireTime);zeBytes())
181181
.setExpireTime(Timestamp.fromProto(proto.getExpireTime()))
182182
.setVersionTime(Timestamp.fromProto(proto.getVersionTime()))
183183
.setDatabase(DatabaseId.of(proto.getDatabase()))

google-cloud-spanner/src/main/java/com/google/cloud/spanner/BackupInfo.java

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,20 @@ public abstract static class Builder {
8787
/** Builds the backup from this builder. */
8888
public abstract Backup build();
8989

90+
/**
91+
* Output Only.
92+
*
93+
* <p>Returns the max allowed expiration time of the backup, with
94+
* microseconds granularity.
95+
*/
9096
protected abstract Builder setMaxExpireTime(Timestamp maxExpireTime);
97+
98+
/**
99+
* Output Only.
100+
*
101+
* <p>Returns the names of the destination backups being created by copying
102+
* this source backup.
103+
*/
91104
protected abstract Builder setReferencingBackup(ProtocolStringList referencingBackup);
92105
}
93106

@@ -279,10 +292,13 @@ public DatabaseId getDatabase() {
279292
return proto;
280293
}
281294

295+
/** Returns the max expire time of this {@link Backup}. */
282296
public Timestamp getMaxExpireTime() {
283297
return maxExpireTime;
284298
}
285299

300+
/** Returns the names of the destination backups being created by copying
301+
* this source backup {@link Backup}. */
286302
public ProtocolStringList getReferencingBackup() {
287303
return referencingBackup;
288304
}

0 commit comments

Comments
 (0)