public final class Service extends com.google.protobuf.GeneratedMessageV3 implements ServiceOrBuilder
An individual service. A service contains a name and optional metadata. A service must exist before [endpoints][google.cloud.servicedirectory.v1beta1.Endpoint] can be added to it.Protobuf type
google.cloud.servicedirectory.v1beta1.Service| Modifier and Type | Class and Description |
|---|---|
static class |
Service.Builder
An individual service.
|
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter| Modifier and Type | Field and Description |
|---|---|
static int |
CREATE_TIME_FIELD_NUMBER |
static int |
ENDPOINTS_FIELD_NUMBER |
static int |
METADATA_FIELD_NUMBER |
static int |
NAME_FIELD_NUMBER |
static int |
UPDATE_TIME_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
containsMetadata(String key)
Optional.
|
boolean |
equals(Object obj) |
com.google.protobuf.Timestamp |
getCreateTime()
Output only.
|
com.google.protobuf.TimestampOrBuilder |
getCreateTimeOrBuilder()
Output only.
|
static Service |
getDefaultInstance() |
Service |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
Endpoint |
getEndpoints(int index)
Output only.
|
int |
getEndpointsCount()
Output only.
|
List<Endpoint> |
getEndpointsList()
Output only.
|
EndpointOrBuilder |
getEndpointsOrBuilder(int index)
Output only.
|
List<? extends EndpointOrBuilder> |
getEndpointsOrBuilderList()
Output only.
|
Map<String,String> |
getMetadata()
Deprecated.
|
int |
getMetadataCount()
Optional.
|
Map<String,String> |
getMetadataMap()
Optional.
|
String |
getMetadataOrDefault(String key,
String defaultValue)
Optional.
|
String |
getMetadataOrThrow(String key)
Optional.
|
String |
getName()
Immutable.
|
com.google.protobuf.ByteString |
getNameBytes()
Immutable.
|
com.google.protobuf.Parser<Service> |
getParserForType() |
int |
getSerializedSize() |
com.google.protobuf.UnknownFieldSet |
getUnknownFields() |
com.google.protobuf.Timestamp |
getUpdateTime()
Output only.
|
com.google.protobuf.TimestampOrBuilder |
getUpdateTimeOrBuilder()
Output only.
|
boolean |
hasCreateTime()
Output only.
|
int |
hashCode() |
boolean |
hasUpdateTime()
Output only.
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
protected com.google.protobuf.MapField |
internalGetMapField(int number) |
boolean |
isInitialized() |
static Service.Builder |
newBuilder() |
static Service.Builder |
newBuilder(Service prototype) |
Service.Builder |
newBuilderForType() |
protected Service.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
protected Object |
newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) |
static Service |
parseDelimitedFrom(InputStream input) |
static Service |
parseDelimitedFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Service |
parseFrom(byte[] data) |
static Service |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Service |
parseFrom(ByteBuffer data) |
static Service |
parseFrom(ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Service |
parseFrom(com.google.protobuf.ByteString data) |
static Service |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Service |
parseFrom(com.google.protobuf.CodedInputStream input) |
static Service |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static Service |
parseFrom(InputStream input) |
static Service |
parseFrom(InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<Service> |
parser() |
Service.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, isStringEmpty, makeExtensionsImmutable, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int NAME_FIELD_NUMBER
public static final int METADATA_FIELD_NUMBER
public static final int ENDPOINTS_FIELD_NUMBER
public static final int CREATE_TIME_FIELD_NUMBER
public static final int UPDATE_TIME_FIELD_NUMBER
protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
newInstance in class com.google.protobuf.GeneratedMessageV3public final com.google.protobuf.UnknownFieldSet getUnknownFields()
getUnknownFields in interface com.google.protobuf.MessageOrBuildergetUnknownFields in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.MapField internalGetMapField(int number)
internalGetMapField in class com.google.protobuf.GeneratedMessageV3protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public String getName()
Immutable. The resource name for the service in the format `projects/*/locations/*/namespaces/*/services/*`.
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];getName in interface ServiceOrBuilderpublic com.google.protobuf.ByteString getNameBytes()
Immutable. The resource name for the service in the format `projects/*/locations/*/namespaces/*/services/*`.
string name = 1 [(.google.api.field_behavior) = IMMUTABLE];getNameBytes in interface ServiceOrBuilderpublic int getMetadataCount()
ServiceOrBuilder
Optional. Metadata for the service. This data can be consumed by service
clients.
Restrictions:
* The entire metadata dictionary may contain up to 2000 characters,
spread accoss all key-value pairs. Metadata that goes beyond this
limit are rejected
* Valid metadata keys have two segments: an optional prefix and name,
separated by a slash (/). The name segment is required and must be 63
characters or less, beginning and ending with an alphanumeric character
([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and
alphanumerics between. The prefix is optional. If specified, the prefix
must be a DNS subdomain: a series of DNS labels separated by dots (.),
not longer than 253 characters in total, followed by a slash (/).
Metadata that fails to meet these requirements are rejected
* The `(*.)google.com/` and `(*.)googleapis.com/` prefixes are reserved
for system metadata managed by Service Directory. If the user tries
to write to these keyspaces, those entries are silently ignored by
the system
Note: This field is equivalent to the `annotations` field in the v1 API.
They have the same syntax and read/write to the same location in Service
Directory.
map<string, string> metadata = 2 [(.google.api.field_behavior) = OPTIONAL];getMetadataCount in interface ServiceOrBuilderpublic boolean containsMetadata(String key)
Optional. Metadata for the service. This data can be consumed by service
clients.
Restrictions:
* The entire metadata dictionary may contain up to 2000 characters,
spread accoss all key-value pairs. Metadata that goes beyond this
limit are rejected
* Valid metadata keys have two segments: an optional prefix and name,
separated by a slash (/). The name segment is required and must be 63
characters or less, beginning and ending with an alphanumeric character
([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and
alphanumerics between. The prefix is optional. If specified, the prefix
must be a DNS subdomain: a series of DNS labels separated by dots (.),
not longer than 253 characters in total, followed by a slash (/).
Metadata that fails to meet these requirements are rejected
* The `(*.)google.com/` and `(*.)googleapis.com/` prefixes are reserved
for system metadata managed by Service Directory. If the user tries
to write to these keyspaces, those entries are silently ignored by
the system
Note: This field is equivalent to the `annotations` field in the v1 API.
They have the same syntax and read/write to the same location in Service
Directory.
map<string, string> metadata = 2 [(.google.api.field_behavior) = OPTIONAL];containsMetadata in interface ServiceOrBuilder@Deprecated public Map<String,String> getMetadata()
getMetadataMap() instead.getMetadata in interface ServiceOrBuilderpublic Map<String,String> getMetadataMap()
Optional. Metadata for the service. This data can be consumed by service
clients.
Restrictions:
* The entire metadata dictionary may contain up to 2000 characters,
spread accoss all key-value pairs. Metadata that goes beyond this
limit are rejected
* Valid metadata keys have two segments: an optional prefix and name,
separated by a slash (/). The name segment is required and must be 63
characters or less, beginning and ending with an alphanumeric character
([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and
alphanumerics between. The prefix is optional. If specified, the prefix
must be a DNS subdomain: a series of DNS labels separated by dots (.),
not longer than 253 characters in total, followed by a slash (/).
Metadata that fails to meet these requirements are rejected
* The `(*.)google.com/` and `(*.)googleapis.com/` prefixes are reserved
for system metadata managed by Service Directory. If the user tries
to write to these keyspaces, those entries are silently ignored by
the system
Note: This field is equivalent to the `annotations` field in the v1 API.
They have the same syntax and read/write to the same location in Service
Directory.
map<string, string> metadata = 2 [(.google.api.field_behavior) = OPTIONAL];getMetadataMap in interface ServiceOrBuilderpublic String getMetadataOrDefault(String key, String defaultValue)
Optional. Metadata for the service. This data can be consumed by service
clients.
Restrictions:
* The entire metadata dictionary may contain up to 2000 characters,
spread accoss all key-value pairs. Metadata that goes beyond this
limit are rejected
* Valid metadata keys have two segments: an optional prefix and name,
separated by a slash (/). The name segment is required and must be 63
characters or less, beginning and ending with an alphanumeric character
([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and
alphanumerics between. The prefix is optional. If specified, the prefix
must be a DNS subdomain: a series of DNS labels separated by dots (.),
not longer than 253 characters in total, followed by a slash (/).
Metadata that fails to meet these requirements are rejected
* The `(*.)google.com/` and `(*.)googleapis.com/` prefixes are reserved
for system metadata managed by Service Directory. If the user tries
to write to these keyspaces, those entries are silently ignored by
the system
Note: This field is equivalent to the `annotations` field in the v1 API.
They have the same syntax and read/write to the same location in Service
Directory.
map<string, string> metadata = 2 [(.google.api.field_behavior) = OPTIONAL];getMetadataOrDefault in interface ServiceOrBuilderpublic String getMetadataOrThrow(String key)
Optional. Metadata for the service. This data can be consumed by service
clients.
Restrictions:
* The entire metadata dictionary may contain up to 2000 characters,
spread accoss all key-value pairs. Metadata that goes beyond this
limit are rejected
* Valid metadata keys have two segments: an optional prefix and name,
separated by a slash (/). The name segment is required and must be 63
characters or less, beginning and ending with an alphanumeric character
([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and
alphanumerics between. The prefix is optional. If specified, the prefix
must be a DNS subdomain: a series of DNS labels separated by dots (.),
not longer than 253 characters in total, followed by a slash (/).
Metadata that fails to meet these requirements are rejected
* The `(*.)google.com/` and `(*.)googleapis.com/` prefixes are reserved
for system metadata managed by Service Directory. If the user tries
to write to these keyspaces, those entries are silently ignored by
the system
Note: This field is equivalent to the `annotations` field in the v1 API.
They have the same syntax and read/write to the same location in Service
Directory.
map<string, string> metadata = 2 [(.google.api.field_behavior) = OPTIONAL];getMetadataOrThrow in interface ServiceOrBuilderpublic List<Endpoint> getEndpointsList()
Output only. Endpoints associated with this service. Returned on [LookupService.ResolveService][google.cloud.servicedirectory.v1beta1.LookupService.ResolveService]. Control plane clients should use [RegistrationService.ListEndpoints][google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints].
repeated .google.cloud.servicedirectory.v1beta1.Endpoint endpoints = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
getEndpointsList in interface ServiceOrBuilderpublic List<? extends EndpointOrBuilder> getEndpointsOrBuilderList()
Output only. Endpoints associated with this service. Returned on [LookupService.ResolveService][google.cloud.servicedirectory.v1beta1.LookupService.ResolveService]. Control plane clients should use [RegistrationService.ListEndpoints][google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints].
repeated .google.cloud.servicedirectory.v1beta1.Endpoint endpoints = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
getEndpointsOrBuilderList in interface ServiceOrBuilderpublic int getEndpointsCount()
Output only. Endpoints associated with this service. Returned on [LookupService.ResolveService][google.cloud.servicedirectory.v1beta1.LookupService.ResolveService]. Control plane clients should use [RegistrationService.ListEndpoints][google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints].
repeated .google.cloud.servicedirectory.v1beta1.Endpoint endpoints = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
getEndpointsCount in interface ServiceOrBuilderpublic Endpoint getEndpoints(int index)
Output only. Endpoints associated with this service. Returned on [LookupService.ResolveService][google.cloud.servicedirectory.v1beta1.LookupService.ResolveService]. Control plane clients should use [RegistrationService.ListEndpoints][google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints].
repeated .google.cloud.servicedirectory.v1beta1.Endpoint endpoints = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
getEndpoints in interface ServiceOrBuilderpublic EndpointOrBuilder getEndpointsOrBuilder(int index)
Output only. Endpoints associated with this service. Returned on [LookupService.ResolveService][google.cloud.servicedirectory.v1beta1.LookupService.ResolveService]. Control plane clients should use [RegistrationService.ListEndpoints][google.cloud.servicedirectory.v1beta1.RegistrationService.ListEndpoints].
repeated .google.cloud.servicedirectory.v1beta1.Endpoint endpoints = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
getEndpointsOrBuilder in interface ServiceOrBuilderpublic boolean hasCreateTime()
Output only. The timestamp when the service was created.
.google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
hasCreateTime in interface ServiceOrBuilderpublic com.google.protobuf.Timestamp getCreateTime()
Output only. The timestamp when the service was created.
.google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
getCreateTime in interface ServiceOrBuilderpublic com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
Output only. The timestamp when the service was created.
.google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
getCreateTimeOrBuilder in interface ServiceOrBuilderpublic boolean hasUpdateTime()
Output only. The timestamp when the service was last updated. Note: endpoints being created/deleted/updated within the service are not considered service updates for the purpose of this timestamp.
.google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
hasUpdateTime in interface ServiceOrBuilderpublic com.google.protobuf.Timestamp getUpdateTime()
Output only. The timestamp when the service was last updated. Note: endpoints being created/deleted/updated within the service are not considered service updates for the purpose of this timestamp.
.google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
getUpdateTime in interface ServiceOrBuilderpublic com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
Output only. The timestamp when the service was last updated. Note: endpoints being created/deleted/updated within the service are not considered service updates for the purpose of this timestamp.
.google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
getUpdateTimeOrBuilder in interface ServiceOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static Service parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Service parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Service parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Service parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Service parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Service parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static Service parseFrom(InputStream input) throws IOException
IOExceptionpublic static Service parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static Service parseDelimitedFrom(InputStream input) throws IOException
IOExceptionpublic static Service parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic static Service parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
IOExceptionpublic static Service parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
IOExceptionpublic Service.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static Service.Builder newBuilder()
public static Service.Builder newBuilder(Service prototype)
public Service.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected Service.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static Service getDefaultInstance()
public static com.google.protobuf.Parser<Service> parser()
public com.google.protobuf.Parser<Service> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public Service getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderCopyright © 2022 Google LLC. All rights reserved.