public static final class Secret.Builder extends GeneratedMessageV3.Builder<Secret.Builder> implements SecretOrBuilder
A Secret is a logical secret whose value and versions can
be accessed.
A Secret is made up of zero or more SecretVersions that
represent the secret data.
Protobuf type google.cloud.secrets.v1beta1.Secret
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public Secret.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
Returns
buildPartial()
public Secret buildPartial()
Returns
clear()
public Secret.Builder clear()
Returns
Overrides
clearCreateTime()
public Secret.Builder clearCreateTime()
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
clearField(Descriptors.FieldDescriptor field)
public Secret.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearLabels()
public Secret.Builder clearLabels()
Returns
clearName()
public Secret.Builder clearName()
Output only. The resource name of the Secret in the format projects/*/secrets/*
.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public Secret.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearReplication()
public Secret.Builder clearReplication()
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Returns
clone()
public Secret.Builder clone()
Returns
Overrides
containsLabels(String key)
public boolean containsLabels(String key)
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Parameter
Returns
getCreateTime()
public Timestamp getCreateTime()
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getCreateTimeBuilder()
public Timestamp.Builder getCreateTimeBuilder()
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getCreateTimeOrBuilder()
public TimestampOrBuilder getCreateTimeOrBuilder()
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getDefaultInstanceForType()
public Secret getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getLabels()
public Map<String,String> getLabels()
Returns
getLabelsCount()
public int getLabelsCount()
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Returns
getLabelsMap()
public Map<String,String> getLabelsMap()
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Returns
getLabelsOrDefault(String key, String defaultValue)
public String getLabelsOrDefault(String key, String defaultValue)
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Parameters
Returns
getLabelsOrThrow(String key)
public String getLabelsOrThrow(String key)
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Parameter
Returns
getMutableLabels()
public Map<String,String> getMutableLabels()
Use alternate mutation accessors instead.
Returns
getName()
Output only. The resource name of the Secret in the format projects/*/secrets/*
.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
Type | Description |
String | The name.
|
getNameBytes()
public ByteString getNameBytes()
Output only. The resource name of the Secret in the format projects/*/secrets/*
.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getReplication()
public Replication getReplication()
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Returns
getReplicationBuilder()
public Replication.Builder getReplicationBuilder()
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Returns
getReplicationOrBuilder()
public ReplicationOrBuilder getReplicationOrBuilder()
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Returns
hasCreateTime()
public boolean hasCreateTime()
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
Type | Description |
boolean | Whether the createTime field is set.
|
hasReplication()
public boolean hasReplication()
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Returns
Type | Description |
boolean | Whether the replication field is set.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter
Returns
Overrides
internalGetMutableMapField(int number)
protected MapField internalGetMutableMapField(int number)
Parameter
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeCreateTime(Timestamp value)
public Secret.Builder mergeCreateTime(Timestamp value)
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Returns
mergeFrom(Secret other)
public Secret.Builder mergeFrom(Secret other)
Parameter
Returns
public Secret.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public Secret.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeReplication(Replication value)
public Secret.Builder mergeReplication(Replication value)
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Parameter
Returns
mergeUnknownFields(UnknownFieldSet unknownFields)
public final Secret.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
putAllLabels(Map<String,String> values)
public Secret.Builder putAllLabels(Map<String,String> values)
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Parameter
Returns
putLabels(String key, String value)
public Secret.Builder putLabels(String key, String value)
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Parameters
Returns
removeLabels(String key)
public Secret.Builder removeLabels(String key)
The labels assigned to this Secret.
Label keys must be between 1 and 63 characters long, have a UTF-8 encoding
of maximum 128 bytes, and must conform to the following PCRE regular
expression: \p{Ll}\p{Lo}{0,62}
Label values must be between 0 and 63 characters long, have a UTF-8
encoding of maximum 128 bytes, and must conform to the following PCRE
regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63}
No more than 64 labels can be assigned to a given resource.
map<string, string> labels = 4;
Parameter
Returns
setCreateTime(Timestamp value)
public Secret.Builder setCreateTime(Timestamp value)
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Returns
setCreateTime(Timestamp.Builder builderForValue)
public Secret.Builder setCreateTime(Timestamp.Builder builderForValue)
Output only. The time at which the Secret was created.
.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Name | Description |
builderForValue | Builder
|
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public Secret.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setName(String value)
public Secret.Builder setName(String value)
Output only. The resource name of the Secret in the format projects/*/secrets/*
.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Name | Description |
value | String
The name to set.
|
Returns
setNameBytes(ByteString value)
public Secret.Builder setNameBytes(ByteString value)
Output only. The resource name of the Secret in the format projects/*/secrets/*
.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Name | Description |
value | ByteString
The bytes for name to set.
|
Returns
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public Secret.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setReplication(Replication value)
public Secret.Builder setReplication(Replication value)
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Parameter
Returns
setReplication(Replication.Builder builderForValue)
public Secret.Builder setReplication(Replication.Builder builderForValue)
Required. Immutable. The replication policy of the secret data attached to the Secret.
The replication policy cannot be changed after the Secret has been created.
.google.cloud.secrets.v1beta1.Replication replication = 2 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED];
Parameter
Returns
setUnknownFields(UnknownFieldSet unknownFields)
public final Secret.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides