public static final class Namespace.Builder extends GeneratedMessageV3.Builder<Namespace.Builder> implements NamespaceOrBuilder
A container for services.
Namespaces allow administrators to group services together and define
permissions for a collection of services.
Protobuf type google.cloud.servicedirectory.v1beta1.Namespace
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public Namespace.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
Returns
buildPartial()
public Namespace buildPartial()
Returns
clear()
public Namespace.Builder clear()
Returns
Overrides
clearCreateTime()
public Namespace.Builder clearCreateTime()
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
clearField(Descriptors.FieldDescriptor field)
public Namespace.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearLabels()
public Namespace.Builder clearLabels()
Returns
clearName()
public Namespace.Builder clearName()
Immutable. The resource name for the namespace in the format
projects/*/locations/*/namespaces/*
.
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public Namespace.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearUpdateTime()
public Namespace.Builder clearUpdateTime()
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
clone()
public Namespace.Builder clone()
Returns
Overrides
containsLabels(String key)
public boolean containsLabels(String key)
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Parameter
Returns
getCreateTime()
public Timestamp getCreateTime()
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getCreateTimeBuilder()
public Timestamp.Builder getCreateTimeBuilder()
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getCreateTimeOrBuilder()
public TimestampOrBuilder getCreateTimeOrBuilder()
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getDefaultInstanceForType()
public Namespace getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getLabels()
public Map<String,String> getLabels()
Returns
getLabelsCount()
public int getLabelsCount()
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Returns
getLabelsMap()
public Map<String,String> getLabelsMap()
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Returns
getLabelsOrDefault(String key, String defaultValue)
public String getLabelsOrDefault(String key, String defaultValue)
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Parameters
Returns
getLabelsOrThrow(String key)
public String getLabelsOrThrow(String key)
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Parameter
Returns
getMutableLabels()
public Map<String,String> getMutableLabels()
Use alternate mutation accessors instead.
Returns
getName()
Immutable. The resource name for the namespace in the format
projects/*/locations/*/namespaces/*
.
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];
Returns
Type | Description |
String | The name.
|
getNameBytes()
public ByteString getNameBytes()
Immutable. The resource name for the namespace in the format
projects/*/locations/*/namespaces/*
.
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];
Returns
getUpdateTime()
public Timestamp getUpdateTime()
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getUpdateTimeBuilder()
public Timestamp.Builder getUpdateTimeBuilder()
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
getUpdateTimeOrBuilder()
public TimestampOrBuilder getUpdateTimeOrBuilder()
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
hasCreateTime()
public boolean hasCreateTime()
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
Type | Description |
boolean | Whether the createTime field is set.
|
hasUpdateTime()
public boolean hasUpdateTime()
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns
Type | Description |
boolean | Whether the updateTime 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 Namespace.Builder mergeCreateTime(Timestamp value)
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Returns
mergeFrom(Namespace other)
public Namespace.Builder mergeFrom(Namespace other)
Parameter
Returns
public Namespace.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public Namespace.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final Namespace.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
mergeUpdateTime(Timestamp value)
public Namespace.Builder mergeUpdateTime(Timestamp value)
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Returns
putAllLabels(Map<String,String> values)
public Namespace.Builder putAllLabels(Map<String,String> values)
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Parameter
Returns
putLabels(String key, String value)
public Namespace.Builder putLabels(String key, String value)
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Parameters
Returns
removeLabels(String key)
public Namespace.Builder removeLabels(String key)
Optional. Resource labels associated with this namespace.
No more than 64 user labels can be associated with a given resource. Label
keys and values can be no longer than 63 characters.
map<string, string> labels = 2 [(.google.api.field_behavior) = OPTIONAL];
Parameter
Returns
setCreateTime(Timestamp value)
public Namespace.Builder setCreateTime(Timestamp value)
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Returns
setCreateTime(Timestamp.Builder builderForValue)
public Namespace.Builder setCreateTime(Timestamp.Builder builderForValue)
Output only. The timestamp when the namespace was created.
.google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Name | Description |
builderForValue | Builder
|
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public Namespace.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setName(String value)
public Namespace.Builder setName(String value)
Immutable. The resource name for the namespace in the format
projects/*/locations/*/namespaces/*
.
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];
Parameter
Name | Description |
value | String
The name to set.
|
Returns
setNameBytes(ByteString value)
public Namespace.Builder setNameBytes(ByteString value)
Immutable. The resource name for the namespace in the format
projects/*/locations/*/namespaces/*
.
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];
Parameter
Name | Description |
value | ByteString
The bytes for name to set.
|
Returns
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public Namespace.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final Namespace.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
setUpdateTime(Timestamp value)
public Namespace.Builder setUpdateTime(Timestamp value)
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Returns
setUpdateTime(Timestamp.Builder builderForValue)
public Namespace.Builder setUpdateTime(Timestamp.Builder builderForValue)
Output only. The timestamp when the namespace was last updated.
.google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter
Name | Description |
builderForValue | Builder
|
Returns