public static final class Database.Builder extends GeneratedMessageV3.Builder<Database.Builder> implements DatabaseOrBuilder
A Cloud Spanner database.
Protobuf type google.spanner.admin.database.v1.Database
Inheritance
Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessageV3.Builder > Database.BuilderImplements
DatabaseOrBuilderMethods
addAllEncryptionInfo(Iterable<? extends EncryptionInfo> values)
public Database.Builder addAllEncryptionInfo(Iterable<? extends EncryptionInfo> values)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
values | Iterable<? extends com.google.spanner.admin.database.v1.EncryptionInfo> |
Type | Description |
Database.Builder |
addEncryptionInfo(EncryptionInfo value)
public Database.Builder addEncryptionInfo(EncryptionInfo value)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | EncryptionInfo |
Type | Description |
Database.Builder |
addEncryptionInfo(EncryptionInfo.Builder builderForValue)
public Database.Builder addEncryptionInfo(EncryptionInfo.Builder builderForValue)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
builderForValue | EncryptionInfo.Builder |
Type | Description |
Database.Builder |
addEncryptionInfo(int index, EncryptionInfo value)
public Database.Builder addEncryptionInfo(int index, EncryptionInfo value)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
value | EncryptionInfo |
Type | Description |
Database.Builder |
addEncryptionInfo(int index, EncryptionInfo.Builder builderForValue)
public Database.Builder addEncryptionInfo(int index, EncryptionInfo.Builder builderForValue)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
builderForValue | EncryptionInfo.Builder |
Type | Description |
Database.Builder |
addEncryptionInfoBuilder()
public EncryptionInfo.Builder addEncryptionInfoBuilder()
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
EncryptionInfo.Builder |
addEncryptionInfoBuilder(int index)
public EncryptionInfo.Builder addEncryptionInfoBuilder(int index)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
Type | Description |
EncryptionInfo.Builder |
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public Database.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Name | Description |
field | FieldDescriptor |
value | Object |
Type | Description |
Database.Builder |
build()
public Database build()
Type | Description |
Database |
buildPartial()
public Database buildPartial()
Type | Description |
Database |
clear()
public Database.Builder clear()
Type | Description |
Database.Builder |
clearCreateTime()
public Database.Builder clearCreateTime()
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder |
clearDefaultLeader()
public Database.Builder clearDefaultLeader()
Output only. The read-write region which contains the database's leader replicas. This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty.
string default_leader = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder | This builder for chaining. |
clearEarliestVersionTime()
public Database.Builder clearEarliestVersionTime()
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder |
clearEncryptionConfig()
public Database.Builder clearEncryptionConfig()
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder |
clearEncryptionInfo()
public Database.Builder clearEncryptionInfo()
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder |
clearField(Descriptors.FieldDescriptor field)
public Database.Builder clearField(Descriptors.FieldDescriptor field)
Name | Description |
field | FieldDescriptor |
Type | Description |
Database.Builder |
clearName()
public Database.Builder clearName()
Required. The name of the database. Values are of the form
projects/<project>/instances/<instance>/databases/<database>
,
where <database>
is as specified in the CREATE DATABASE
statement. This name can be passed to other API methods to
identify the database.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Type | Description |
Database.Builder | This builder for chaining. |
clearOneof(Descriptors.OneofDescriptor oneof)
public Database.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Name | Description |
oneof | OneofDescriptor |
Type | Description |
Database.Builder |
clearRestoreInfo()
public Database.Builder clearRestoreInfo()
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder |
clearState()
public Database.Builder clearState()
Output only. The current database state.
.google.spanner.admin.database.v1.Database.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder | This builder for chaining. |
clearVersionRetentionPeriod()
public Database.Builder clearVersionRetentionPeriod()
Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using UpdateDatabaseDdl. Defaults to 1 hour, if not set.
string version_retention_period = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.Builder | This builder for chaining. |
clone()
public Database.Builder clone()
Type | Description |
Database.Builder |
getCreateTime()
public Timestamp getCreateTime()
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Timestamp | The createTime. |
getCreateTimeBuilder()
public Timestamp.Builder getCreateTimeBuilder()
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Builder |
getCreateTimeOrBuilder()
public TimestampOrBuilder getCreateTimeOrBuilder()
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
TimestampOrBuilder |
getDefaultInstanceForType()
public Database getDefaultInstanceForType()
Type | Description |
Database |
getDefaultLeader()
public String getDefaultLeader()
Output only. The read-write region which contains the database's leader replicas. This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty.
string default_leader = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
String | The defaultLeader. |
getDefaultLeaderBytes()
public ByteString getDefaultLeaderBytes()
Output only. The read-write region which contains the database's leader replicas. This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty.
string default_leader = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
ByteString | The bytes for defaultLeader. |
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Type | Description |
Descriptor |
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Type | Description |
Descriptor |
getEarliestVersionTime()
public Timestamp getEarliestVersionTime()
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Timestamp | The earliestVersionTime. |
getEarliestVersionTimeBuilder()
public Timestamp.Builder getEarliestVersionTimeBuilder()
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Builder |
getEarliestVersionTimeOrBuilder()
public TimestampOrBuilder getEarliestVersionTimeOrBuilder()
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
TimestampOrBuilder |
getEncryptionConfig()
public EncryptionConfig getEncryptionConfig()
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
EncryptionConfig | The encryptionConfig. |
getEncryptionConfigBuilder()
public EncryptionConfig.Builder getEncryptionConfigBuilder()
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
EncryptionConfig.Builder |
getEncryptionConfigOrBuilder()
public EncryptionConfigOrBuilder getEncryptionConfigOrBuilder()
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
EncryptionConfigOrBuilder |
getEncryptionInfo(int index)
public EncryptionInfo getEncryptionInfo(int index)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
Type | Description |
EncryptionInfo |
getEncryptionInfoBuilder(int index)
public EncryptionInfo.Builder getEncryptionInfoBuilder(int index)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
Type | Description |
EncryptionInfo.Builder |
getEncryptionInfoBuilderList()
public List<EncryptionInfo.Builder> getEncryptionInfoBuilderList()
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
List<Builder> |
getEncryptionInfoCount()
public int getEncryptionInfoCount()
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
int |
getEncryptionInfoList()
public List<EncryptionInfo> getEncryptionInfoList()
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
List<EncryptionInfo> |
getEncryptionInfoOrBuilder(int index)
public EncryptionInfoOrBuilder getEncryptionInfoOrBuilder(int index)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
Type | Description |
EncryptionInfoOrBuilder |
getEncryptionInfoOrBuilderList()
public List<? extends EncryptionInfoOrBuilder> getEncryptionInfoOrBuilderList()
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
List<? extends com.google.spanner.admin.database.v1.EncryptionInfoOrBuilder> |
getName()
public String getName()
Required. The name of the database. Values are of the form
projects/<project>/instances/<instance>/databases/<database>
,
where <database>
is as specified in the CREATE DATABASE
statement. This name can be passed to other API methods to
identify the database.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Type | Description |
String | The name. |
getNameBytes()
public ByteString getNameBytes()
Required. The name of the database. Values are of the form
projects/<project>/instances/<instance>/databases/<database>
,
where <database>
is as specified in the CREATE DATABASE
statement. This name can be passed to other API methods to
identify the database.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Type | Description |
ByteString | The bytes for name. |
getRestoreInfo()
public RestoreInfo getRestoreInfo()
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
RestoreInfo | The restoreInfo. |
getRestoreInfoBuilder()
public RestoreInfo.Builder getRestoreInfoBuilder()
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
RestoreInfo.Builder |
getRestoreInfoOrBuilder()
public RestoreInfoOrBuilder getRestoreInfoOrBuilder()
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
RestoreInfoOrBuilder |
getState()
public Database.State getState()
Output only. The current database state.
.google.spanner.admin.database.v1.Database.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
Database.State | The state. |
getStateValue()
public int getStateValue()
Output only. The current database state.
.google.spanner.admin.database.v1.Database.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
int | The enum numeric value on the wire for state. |
getVersionRetentionPeriod()
public String getVersionRetentionPeriod()
Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using UpdateDatabaseDdl. Defaults to 1 hour, if not set.
string version_retention_period = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
String | The versionRetentionPeriod. |
getVersionRetentionPeriodBytes()
public ByteString getVersionRetentionPeriodBytes()
Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using UpdateDatabaseDdl. Defaults to 1 hour, if not set.
string version_retention_period = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
ByteString | The bytes for versionRetentionPeriod. |
hasCreateTime()
public boolean hasCreateTime()
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
boolean | Whether the createTime field is set. |
hasEarliestVersionTime()
public boolean hasEarliestVersionTime()
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
boolean | Whether the earliestVersionTime field is set. |
hasEncryptionConfig()
public boolean hasEncryptionConfig()
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
boolean | Whether the encryptionConfig field is set. |
hasRestoreInfo()
public boolean hasRestoreInfo()
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Type | Description |
boolean | Whether the restoreInfo field is set. |
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Type | Description |
FieldAccessorTable |
isInitialized()
public final boolean isInitialized()
Type | Description |
boolean |
mergeCreateTime(Timestamp value)
public Database.Builder mergeCreateTime(Timestamp value)
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | Timestamp |
Type | Description |
Database.Builder |
mergeEarliestVersionTime(Timestamp value)
public Database.Builder mergeEarliestVersionTime(Timestamp value)
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | Timestamp |
Type | Description |
Database.Builder |
mergeEncryptionConfig(EncryptionConfig value)
public Database.Builder mergeEncryptionConfig(EncryptionConfig value)
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | EncryptionConfig |
Type | Description |
Database.Builder |
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public Database.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Name | Description |
input | CodedInputStream |
extensionRegistry | ExtensionRegistryLite |
Type | Description |
Database.Builder |
Type | Description |
IOException |
mergeFrom(Message other)
public Database.Builder mergeFrom(Message other)
Name | Description |
other | Message |
Type | Description |
Database.Builder |
mergeFrom(Database other)
public Database.Builder mergeFrom(Database other)
Name | Description |
other | Database |
Type | Description |
Database.Builder |
mergeRestoreInfo(RestoreInfo value)
public Database.Builder mergeRestoreInfo(RestoreInfo value)
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | RestoreInfo |
Type | Description |
Database.Builder |
mergeUnknownFields(UnknownFieldSet unknownFields)
public final Database.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Name | Description |
unknownFields | UnknownFieldSet |
Type | Description |
Database.Builder |
removeEncryptionInfo(int index)
public Database.Builder removeEncryptionInfo(int index)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
Type | Description |
Database.Builder |
setCreateTime(Timestamp value)
public Database.Builder setCreateTime(Timestamp value)
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | Timestamp |
Type | Description |
Database.Builder |
setCreateTime(Timestamp.Builder builderForValue)
public Database.Builder setCreateTime(Timestamp.Builder builderForValue)
Output only. If exists, the time at which the database creation started.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
builderForValue | Builder |
Type | Description |
Database.Builder |
setDefaultLeader(String value)
public Database.Builder setDefaultLeader(String value)
Output only. The read-write region which contains the database's leader replicas. This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty.
string default_leader = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | String The defaultLeader to set. |
Type | Description |
Database.Builder | This builder for chaining. |
setDefaultLeaderBytes(ByteString value)
public Database.Builder setDefaultLeaderBytes(ByteString value)
Output only. The read-write region which contains the database's leader replicas. This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty.
string default_leader = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | ByteString The bytes for defaultLeader to set. |
Type | Description |
Database.Builder | This builder for chaining. |
setEarliestVersionTime(Timestamp value)
public Database.Builder setEarliestVersionTime(Timestamp value)
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | Timestamp |
Type | Description |
Database.Builder |
setEarliestVersionTime(Timestamp.Builder builderForValue)
public Database.Builder setEarliestVersionTime(Timestamp.Builder builderForValue)
Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.
.google.protobuf.Timestamp earliest_version_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
builderForValue | Builder |
Type | Description |
Database.Builder |
setEncryptionConfig(EncryptionConfig value)
public Database.Builder setEncryptionConfig(EncryptionConfig value)
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | EncryptionConfig |
Type | Description |
Database.Builder |
setEncryptionConfig(EncryptionConfig.Builder builderForValue)
public Database.Builder setEncryptionConfig(EncryptionConfig.Builder builderForValue)
Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.
.google.spanner.admin.database.v1.EncryptionConfig encryption_config = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
builderForValue | EncryptionConfig.Builder |
Type | Description |
Database.Builder |
setEncryptionInfo(int index, EncryptionInfo value)
public Database.Builder setEncryptionInfo(int index, EncryptionInfo value)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
value | EncryptionInfo |
Type | Description |
Database.Builder |
setEncryptionInfo(int index, EncryptionInfo.Builder builderForValue)
public Database.Builder setEncryptionInfo(int index, EncryptionInfo.Builder builderForValue)
Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use. For databases that are using Google default or other types of encryption, this field is empty. This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.
repeated .google.spanner.admin.database.v1.EncryptionInfo encryption_info = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
index | int |
builderForValue | EncryptionInfo.Builder |
Type | Description |
Database.Builder |
setField(Descriptors.FieldDescriptor field, Object value)
public Database.Builder setField(Descriptors.FieldDescriptor field, Object value)
Name | Description |
field | FieldDescriptor |
value | Object |
Type | Description |
Database.Builder |
setName(String value)
public Database.Builder setName(String value)
Required. The name of the database. Values are of the form
projects/<project>/instances/<instance>/databases/<database>
,
where <database>
is as specified in the CREATE DATABASE
statement. This name can be passed to other API methods to
identify the database.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Name | Description |
value | String The name to set. |
Type | Description |
Database.Builder | This builder for chaining. |
setNameBytes(ByteString value)
public Database.Builder setNameBytes(ByteString value)
Required. The name of the database. Values are of the form
projects/<project>/instances/<instance>/databases/<database>
,
where <database>
is as specified in the CREATE DATABASE
statement. This name can be passed to other API methods to
identify the database.
string name = 1 [(.google.api.field_behavior) = REQUIRED];
Name | Description |
value | ByteString The bytes for name to set. |
Type | Description |
Database.Builder | This builder for chaining. |
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public Database.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Name | Description |
field | FieldDescriptor |
index | int |
value | Object |
Type | Description |
Database.Builder |
setRestoreInfo(RestoreInfo value)
public Database.Builder setRestoreInfo(RestoreInfo value)
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | RestoreInfo |
Type | Description |
Database.Builder |
setRestoreInfo(RestoreInfo.Builder builderForValue)
public Database.Builder setRestoreInfo(RestoreInfo.Builder builderForValue)
Output only. Applicable only for restored databases. Contains information about the restore source.
.google.spanner.admin.database.v1.RestoreInfo restore_info = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
builderForValue | RestoreInfo.Builder |
Type | Description |
Database.Builder |
setState(Database.State value)
public Database.Builder setState(Database.State value)
Output only. The current database state.
.google.spanner.admin.database.v1.Database.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | Database.State The state to set. |
Type | Description |
Database.Builder | This builder for chaining. |
setStateValue(int value)
public Database.Builder setStateValue(int value)
Output only. The current database state.
.google.spanner.admin.database.v1.Database.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | int The enum numeric value on the wire for state to set. |
Type | Description |
Database.Builder | This builder for chaining. |
setUnknownFields(UnknownFieldSet unknownFields)
public final Database.Builder setUnknownFields(UnknownFieldSet unknownFields)
Name | Description |
unknownFields | UnknownFieldSet |
Type | Description |
Database.Builder |
setVersionRetentionPeriod(String value)
public Database.Builder setVersionRetentionPeriod(String value)
Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using UpdateDatabaseDdl. Defaults to 1 hour, if not set.
string version_retention_period = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | String The versionRetentionPeriod to set. |
Type | Description |
Database.Builder | This builder for chaining. |
setVersionRetentionPeriodBytes(ByteString value)
public Database.Builder setVersionRetentionPeriodBytes(ByteString value)
Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using UpdateDatabaseDdl. Defaults to 1 hour, if not set.
string version_retention_period = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
Name | Description |
value | ByteString The bytes for versionRetentionPeriod to set. |
Type | Description |
Database.Builder | This builder for chaining. |