Class Context

  • All Implemented Interfaces:
    ContextOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class Context
    extends com.google.protobuf.GeneratedMessageV3
    implements ContextOrBuilder
     Instance of a general context.
     
    Protobuf type google.cloud.aiplatform.v1.Context
    See Also:
    Serialized Form
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetMapField

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • getName

        public String getName()
         Immutable. The resource name of the Context.
         
        string name = 1 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getName in interface ContextOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         Immutable. The resource name of the Context.
         
        string name = 1 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getNameBytes in interface ContextOrBuilder
        Returns:
        The bytes for name.
      • getDisplayName

        public String getDisplayName()
         User provided display name of the Context.
         May be up to 128 Unicode characters.
         
        string display_name = 2;
        Specified by:
        getDisplayName in interface ContextOrBuilder
        Returns:
        The displayName.
      • getDisplayNameBytes

        public com.google.protobuf.ByteString getDisplayNameBytes()
         User provided display name of the Context.
         May be up to 128 Unicode characters.
         
        string display_name = 2;
        Specified by:
        getDisplayNameBytes in interface ContextOrBuilder
        Returns:
        The bytes for displayName.
      • getEtag

        public String getEtag()
         An eTag used to perform consistent read-modify-write updates. If not set, a
         blind "overwrite" update happens.
         
        string etag = 8;
        Specified by:
        getEtag in interface ContextOrBuilder
        Returns:
        The etag.
      • getEtagBytes

        public com.google.protobuf.ByteString getEtagBytes()
         An eTag used to perform consistent read-modify-write updates. If not set, a
         blind "overwrite" update happens.
         
        string etag = 8;
        Specified by:
        getEtagBytes in interface ContextOrBuilder
        Returns:
        The bytes for etag.
      • getLabelsCount

        public int getLabelsCount()
        Description copied from interface: ContextOrBuilder
         The labels with user-defined metadata to organize your Contexts.
        
         Label keys and values can be no longer than 64 characters
         (Unicode codepoints), can only contain lowercase letters, numeric
         characters, underscores and dashes. International characters are allowed.
         No more than 64 user labels can be associated with one Context (System
         labels are excluded).
         
        map<string, string> labels = 9;
        Specified by:
        getLabelsCount in interface ContextOrBuilder
      • containsLabels

        public boolean containsLabels​(String key)
         The labels with user-defined metadata to organize your Contexts.
        
         Label keys and values can be no longer than 64 characters
         (Unicode codepoints), can only contain lowercase letters, numeric
         characters, underscores and dashes. International characters are allowed.
         No more than 64 user labels can be associated with one Context (System
         labels are excluded).
         
        map<string, string> labels = 9;
        Specified by:
        containsLabels in interface ContextOrBuilder
      • getLabelsMap

        public Map<String,​String> getLabelsMap()
         The labels with user-defined metadata to organize your Contexts.
        
         Label keys and values can be no longer than 64 characters
         (Unicode codepoints), can only contain lowercase letters, numeric
         characters, underscores and dashes. International characters are allowed.
         No more than 64 user labels can be associated with one Context (System
         labels are excluded).
         
        map<string, string> labels = 9;
        Specified by:
        getLabelsMap in interface ContextOrBuilder
      • getLabelsOrDefault

        public String getLabelsOrDefault​(String key,
                                         String defaultValue)
         The labels with user-defined metadata to organize your Contexts.
        
         Label keys and values can be no longer than 64 characters
         (Unicode codepoints), can only contain lowercase letters, numeric
         characters, underscores and dashes. International characters are allowed.
         No more than 64 user labels can be associated with one Context (System
         labels are excluded).
         
        map<string, string> labels = 9;
        Specified by:
        getLabelsOrDefault in interface ContextOrBuilder
      • getLabelsOrThrow

        public String getLabelsOrThrow​(String key)
         The labels with user-defined metadata to organize your Contexts.
        
         Label keys and values can be no longer than 64 characters
         (Unicode codepoints), can only contain lowercase letters, numeric
         characters, underscores and dashes. International characters are allowed.
         No more than 64 user labels can be associated with one Context (System
         labels are excluded).
         
        map<string, string> labels = 9;
        Specified by:
        getLabelsOrThrow in interface ContextOrBuilder
      • hasCreateTime

        public boolean hasCreateTime()
         Output only. Timestamp when this Context was created.
         
        .google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasCreateTime in interface ContextOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         Output only. Timestamp when this Context was created.
         
        .google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTime in interface ContextOrBuilder
        Returns:
        The createTime.
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         Output only. Timestamp when this Context was created.
         
        .google.protobuf.Timestamp create_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTimeOrBuilder in interface ContextOrBuilder
      • hasUpdateTime

        public boolean hasUpdateTime()
         Output only. Timestamp when this Context was last updated.
         
        .google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasUpdateTime in interface ContextOrBuilder
        Returns:
        Whether the updateTime field is set.
      • getUpdateTime

        public com.google.protobuf.Timestamp getUpdateTime()
         Output only. Timestamp when this Context was last updated.
         
        .google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTime in interface ContextOrBuilder
        Returns:
        The updateTime.
      • getUpdateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
         Output only. Timestamp when this Context was last updated.
         
        .google.protobuf.Timestamp update_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTimeOrBuilder in interface ContextOrBuilder
      • getParentContextsList

        public com.google.protobuf.ProtocolStringList getParentContextsList()
         Output only. A list of resource names of Contexts that are parents of this
         Context. A Context may have at most 10 parent_contexts.
         
        repeated string parent_contexts = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
        Specified by:
        getParentContextsList in interface ContextOrBuilder
        Returns:
        A list containing the parentContexts.
      • getParentContextsCount

        public int getParentContextsCount()
         Output only. A list of resource names of Contexts that are parents of this
         Context. A Context may have at most 10 parent_contexts.
         
        repeated string parent_contexts = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
        Specified by:
        getParentContextsCount in interface ContextOrBuilder
        Returns:
        The count of parentContexts.
      • getParentContexts

        public String getParentContexts​(int index)
         Output only. A list of resource names of Contexts that are parents of this
         Context. A Context may have at most 10 parent_contexts.
         
        repeated string parent_contexts = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
        Specified by:
        getParentContexts in interface ContextOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The parentContexts at the given index.
      • getParentContextsBytes

        public com.google.protobuf.ByteString getParentContextsBytes​(int index)
         Output only. A list of resource names of Contexts that are parents of this
         Context. A Context may have at most 10 parent_contexts.
         
        repeated string parent_contexts = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
        Specified by:
        getParentContextsBytes in interface ContextOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the parentContexts at the given index.
      • getSchemaTitle

        public String getSchemaTitle()
         The title of the schema describing the metadata.
        
         Schema title and version is expected to be registered in earlier Create
         Schema calls. And both are used together as unique identifiers to identify
         schemas within the local metadata store.
         
        string schema_title = 13;
        Specified by:
        getSchemaTitle in interface ContextOrBuilder
        Returns:
        The schemaTitle.
      • getSchemaTitleBytes

        public com.google.protobuf.ByteString getSchemaTitleBytes()
         The title of the schema describing the metadata.
        
         Schema title and version is expected to be registered in earlier Create
         Schema calls. And both are used together as unique identifiers to identify
         schemas within the local metadata store.
         
        string schema_title = 13;
        Specified by:
        getSchemaTitleBytes in interface ContextOrBuilder
        Returns:
        The bytes for schemaTitle.
      • getSchemaVersion

        public String getSchemaVersion()
         The version of the schema in schema_name to use.
        
         Schema title and version is expected to be registered in earlier Create
         Schema calls. And both are used together as unique identifiers to identify
         schemas within the local metadata store.
         
        string schema_version = 14;
        Specified by:
        getSchemaVersion in interface ContextOrBuilder
        Returns:
        The schemaVersion.
      • getSchemaVersionBytes

        public com.google.protobuf.ByteString getSchemaVersionBytes()
         The version of the schema in schema_name to use.
        
         Schema title and version is expected to be registered in earlier Create
         Schema calls. And both are used together as unique identifiers to identify
         schemas within the local metadata store.
         
        string schema_version = 14;
        Specified by:
        getSchemaVersionBytes in interface ContextOrBuilder
        Returns:
        The bytes for schemaVersion.
      • hasMetadata

        public boolean hasMetadata()
         Properties of the Context.
         Top level metadata keys' heading and trailing spaces will be trimmed.
         The size of this field should not exceed 200KB.
         
        .google.protobuf.Struct metadata = 15;
        Specified by:
        hasMetadata in interface ContextOrBuilder
        Returns:
        Whether the metadata field is set.
      • getMetadata

        public com.google.protobuf.Struct getMetadata()
         Properties of the Context.
         Top level metadata keys' heading and trailing spaces will be trimmed.
         The size of this field should not exceed 200KB.
         
        .google.protobuf.Struct metadata = 15;
        Specified by:
        getMetadata in interface ContextOrBuilder
        Returns:
        The metadata.
      • getMetadataOrBuilder

        public com.google.protobuf.StructOrBuilder getMetadataOrBuilder()
         Properties of the Context.
         Top level metadata keys' heading and trailing spaces will be trimmed.
         The size of this field should not exceed 200KB.
         
        .google.protobuf.Struct metadata = 15;
        Specified by:
        getMetadataOrBuilder in interface ContextOrBuilder
      • getDescription

        public String getDescription()
         Description of the Context
         
        string description = 16;
        Specified by:
        getDescription in interface ContextOrBuilder
        Returns:
        The description.
      • getDescriptionBytes

        public com.google.protobuf.ByteString getDescriptionBytes()
         Description of the Context
         
        string description = 16;
        Specified by:
        getDescriptionBytes in interface ContextOrBuilder
        Returns:
        The bytes for description.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static Context parseFrom​(ByteBuffer data)
                                 throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Context parseFrom​(ByteBuffer data,
                                        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                 throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Context parseFrom​(com.google.protobuf.ByteString data)
                                 throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Context parseFrom​(com.google.protobuf.ByteString data,
                                        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                 throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Context parseFrom​(byte[] data)
                                 throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Context parseFrom​(byte[] data,
                                        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                 throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Context parseFrom​(com.google.protobuf.CodedInputStream input,
                                        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                 throws IOException
        Throws:
        IOException
      • newBuilderForType

        public Context.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public Context.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected Context.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstance

        public static Context getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<Context> parser()
      • getParserForType

        public com.google.protobuf.Parser<Context> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public Context getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder