Class AnnotatedDataset.Builder

  • All Implemented Interfaces:
    AnnotatedDatasetOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
    Enclosing class:
    AnnotatedDataset

    public static final class AnnotatedDataset.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
    implements AnnotatedDatasetOrBuilder
     AnnotatedDataset is a set holding annotations for data in a Dataset. Each
     labeling task will generate an AnnotatedDataset under the Dataset that the
     task is requested for.
     
    Protobuf type google.cloud.datalabeling.v1beta1.AnnotatedDataset
    • Method Detail

      • getDescriptor

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

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • clear

        public AnnotatedDataset.Builder clear()
        Specified by:
        clear in interface com.google.protobuf.Message.Builder
        Specified by:
        clear in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clear in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • getDefaultInstanceForType

        public AnnotatedDataset getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public AnnotatedDataset build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public AnnotatedDataset buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • clone

        public AnnotatedDataset.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • setField

        public AnnotatedDataset.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                 Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • clearField

        public AnnotatedDataset.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • clearOneof

        public AnnotatedDataset.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • setRepeatedField

        public AnnotatedDataset.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                         int index,
                                                         Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • addRepeatedField

        public AnnotatedDataset.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                         Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • mergeFrom

        public AnnotatedDataset.Builder mergeFrom​(com.google.protobuf.Message other)
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<AnnotatedDataset.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • mergeFrom

        public AnnotatedDataset.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                  com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                           throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<AnnotatedDataset.Builder>
        Throws:
        IOException
      • getName

        public String getName()
         Output only. AnnotatedDataset resource name in format of:
         projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/
         {annotated_dataset_id}
         
        string name = 1;
        Specified by:
        getName in interface AnnotatedDatasetOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         Output only. AnnotatedDataset resource name in format of:
         projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/
         {annotated_dataset_id}
         
        string name = 1;
        Specified by:
        getNameBytes in interface AnnotatedDatasetOrBuilder
        Returns:
        The bytes for name.
      • setName

        public AnnotatedDataset.Builder setName​(String value)
         Output only. AnnotatedDataset resource name in format of:
         projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/
         {annotated_dataset_id}
         
        string name = 1;
        Parameters:
        value - The name to set.
        Returns:
        This builder for chaining.
      • clearName

        public AnnotatedDataset.Builder clearName()
         Output only. AnnotatedDataset resource name in format of:
         projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/
         {annotated_dataset_id}
         
        string name = 1;
        Returns:
        This builder for chaining.
      • setNameBytes

        public AnnotatedDataset.Builder setNameBytes​(com.google.protobuf.ByteString value)
         Output only. AnnotatedDataset resource name in format of:
         projects/{project_id}/datasets/{dataset_id}/annotatedDatasets/
         {annotated_dataset_id}
         
        string name = 1;
        Parameters:
        value - The bytes for name to set.
        Returns:
        This builder for chaining.
      • getDisplayName

        public String getDisplayName()
         Output only. The display name of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 64
         characters.
         
        string display_name = 2;
        Specified by:
        getDisplayName in interface AnnotatedDatasetOrBuilder
        Returns:
        The displayName.
      • getDisplayNameBytes

        public com.google.protobuf.ByteString getDisplayNameBytes()
         Output only. The display name of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 64
         characters.
         
        string display_name = 2;
        Specified by:
        getDisplayNameBytes in interface AnnotatedDatasetOrBuilder
        Returns:
        The bytes for displayName.
      • setDisplayName

        public AnnotatedDataset.Builder setDisplayName​(String value)
         Output only. The display name of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 64
         characters.
         
        string display_name = 2;
        Parameters:
        value - The displayName to set.
        Returns:
        This builder for chaining.
      • clearDisplayName

        public AnnotatedDataset.Builder clearDisplayName()
         Output only. The display name of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 64
         characters.
         
        string display_name = 2;
        Returns:
        This builder for chaining.
      • setDisplayNameBytes

        public AnnotatedDataset.Builder setDisplayNameBytes​(com.google.protobuf.ByteString value)
         Output only. The display name of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 64
         characters.
         
        string display_name = 2;
        Parameters:
        value - The bytes for displayName to set.
        Returns:
        This builder for chaining.
      • getDescription

        public String getDescription()
         Output only. The description of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 10000
         characters.
         
        string description = 9;
        Specified by:
        getDescription in interface AnnotatedDatasetOrBuilder
        Returns:
        The description.
      • getDescriptionBytes

        public com.google.protobuf.ByteString getDescriptionBytes()
         Output only. The description of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 10000
         characters.
         
        string description = 9;
        Specified by:
        getDescriptionBytes in interface AnnotatedDatasetOrBuilder
        Returns:
        The bytes for description.
      • setDescription

        public AnnotatedDataset.Builder setDescription​(String value)
         Output only. The description of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 10000
         characters.
         
        string description = 9;
        Parameters:
        value - The description to set.
        Returns:
        This builder for chaining.
      • clearDescription

        public AnnotatedDataset.Builder clearDescription()
         Output only. The description of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 10000
         characters.
         
        string description = 9;
        Returns:
        This builder for chaining.
      • setDescriptionBytes

        public AnnotatedDataset.Builder setDescriptionBytes​(com.google.protobuf.ByteString value)
         Output only. The description of the AnnotatedDataset. It is specified in
         HumanAnnotationConfig when user starts a labeling task. Maximum of 10000
         characters.
         
        string description = 9;
        Parameters:
        value - The bytes for description to set.
        Returns:
        This builder for chaining.
      • getAnnotationSourceValue

        public int getAnnotationSourceValue()
         Output only. Source of the annotation.
         
        .google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 3;
        Specified by:
        getAnnotationSourceValue in interface AnnotatedDatasetOrBuilder
        Returns:
        The enum numeric value on the wire for annotationSource.
      • setAnnotationSourceValue

        public AnnotatedDataset.Builder setAnnotationSourceValue​(int value)
         Output only. Source of the annotation.
         
        .google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 3;
        Parameters:
        value - The enum numeric value on the wire for annotationSource to set.
        Returns:
        This builder for chaining.
      • setAnnotationSource

        public AnnotatedDataset.Builder setAnnotationSource​(AnnotationSource value)
         Output only. Source of the annotation.
         
        .google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 3;
        Parameters:
        value - The annotationSource to set.
        Returns:
        This builder for chaining.
      • clearAnnotationSource

        public AnnotatedDataset.Builder clearAnnotationSource()
         Output only. Source of the annotation.
         
        .google.cloud.datalabeling.v1beta1.AnnotationSource annotation_source = 3;
        Returns:
        This builder for chaining.
      • getAnnotationTypeValue

        public int getAnnotationTypeValue()
         Output only. Type of the annotation. It is specified when starting labeling
         task.
         
        .google.cloud.datalabeling.v1beta1.AnnotationType annotation_type = 8;
        Specified by:
        getAnnotationTypeValue in interface AnnotatedDatasetOrBuilder
        Returns:
        The enum numeric value on the wire for annotationType.
      • setAnnotationTypeValue

        public AnnotatedDataset.Builder setAnnotationTypeValue​(int value)
         Output only. Type of the annotation. It is specified when starting labeling
         task.
         
        .google.cloud.datalabeling.v1beta1.AnnotationType annotation_type = 8;
        Parameters:
        value - The enum numeric value on the wire for annotationType to set.
        Returns:
        This builder for chaining.
      • getAnnotationType

        public AnnotationType getAnnotationType()
         Output only. Type of the annotation. It is specified when starting labeling
         task.
         
        .google.cloud.datalabeling.v1beta1.AnnotationType annotation_type = 8;
        Specified by:
        getAnnotationType in interface AnnotatedDatasetOrBuilder
        Returns:
        The annotationType.
      • setAnnotationType

        public AnnotatedDataset.Builder setAnnotationType​(AnnotationType value)
         Output only. Type of the annotation. It is specified when starting labeling
         task.
         
        .google.cloud.datalabeling.v1beta1.AnnotationType annotation_type = 8;
        Parameters:
        value - The annotationType to set.
        Returns:
        This builder for chaining.
      • clearAnnotationType

        public AnnotatedDataset.Builder clearAnnotationType()
         Output only. Type of the annotation. It is specified when starting labeling
         task.
         
        .google.cloud.datalabeling.v1beta1.AnnotationType annotation_type = 8;
        Returns:
        This builder for chaining.
      • getExampleCount

        public long getExampleCount()
         Output only. Number of examples in the annotated dataset.
         
        int64 example_count = 4;
        Specified by:
        getExampleCount in interface AnnotatedDatasetOrBuilder
        Returns:
        The exampleCount.
      • setExampleCount

        public AnnotatedDataset.Builder setExampleCount​(long value)
         Output only. Number of examples in the annotated dataset.
         
        int64 example_count = 4;
        Parameters:
        value - The exampleCount to set.
        Returns:
        This builder for chaining.
      • clearExampleCount

        public AnnotatedDataset.Builder clearExampleCount()
         Output only. Number of examples in the annotated dataset.
         
        int64 example_count = 4;
        Returns:
        This builder for chaining.
      • getCompletedExampleCount

        public long getCompletedExampleCount()
         Output only. Number of examples that have annotation in the annotated
         dataset.
         
        int64 completed_example_count = 5;
        Specified by:
        getCompletedExampleCount in interface AnnotatedDatasetOrBuilder
        Returns:
        The completedExampleCount.
      • setCompletedExampleCount

        public AnnotatedDataset.Builder setCompletedExampleCount​(long value)
         Output only. Number of examples that have annotation in the annotated
         dataset.
         
        int64 completed_example_count = 5;
        Parameters:
        value - The completedExampleCount to set.
        Returns:
        This builder for chaining.
      • clearCompletedExampleCount

        public AnnotatedDataset.Builder clearCompletedExampleCount()
         Output only. Number of examples that have annotation in the annotated
         dataset.
         
        int64 completed_example_count = 5;
        Returns:
        This builder for chaining.
      • hasLabelStats

        public boolean hasLabelStats()
         Output only. Per label statistics.
         
        .google.cloud.datalabeling.v1beta1.LabelStats label_stats = 6;
        Specified by:
        hasLabelStats in interface AnnotatedDatasetOrBuilder
        Returns:
        Whether the labelStats field is set.
      • getLabelStats

        public LabelStats getLabelStats()
         Output only. Per label statistics.
         
        .google.cloud.datalabeling.v1beta1.LabelStats label_stats = 6;
        Specified by:
        getLabelStats in interface AnnotatedDatasetOrBuilder
        Returns:
        The labelStats.
      • setLabelStats

        public AnnotatedDataset.Builder setLabelStats​(LabelStats value)
         Output only. Per label statistics.
         
        .google.cloud.datalabeling.v1beta1.LabelStats label_stats = 6;
      • mergeLabelStats

        public AnnotatedDataset.Builder mergeLabelStats​(LabelStats value)
         Output only. Per label statistics.
         
        .google.cloud.datalabeling.v1beta1.LabelStats label_stats = 6;
      • clearLabelStats

        public AnnotatedDataset.Builder clearLabelStats()
         Output only. Per label statistics.
         
        .google.cloud.datalabeling.v1beta1.LabelStats label_stats = 6;
      • getLabelStatsBuilder

        public LabelStats.Builder getLabelStatsBuilder()
         Output only. Per label statistics.
         
        .google.cloud.datalabeling.v1beta1.LabelStats label_stats = 6;
      • hasCreateTime

        public boolean hasCreateTime()
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
        Specified by:
        hasCreateTime in interface AnnotatedDatasetOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
        Specified by:
        getCreateTime in interface AnnotatedDatasetOrBuilder
        Returns:
        The createTime.
      • setCreateTime

        public AnnotatedDataset.Builder setCreateTime​(com.google.protobuf.Timestamp value)
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
      • setCreateTime

        public AnnotatedDataset.Builder setCreateTime​(com.google.protobuf.Timestamp.Builder builderForValue)
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
      • mergeCreateTime

        public AnnotatedDataset.Builder mergeCreateTime​(com.google.protobuf.Timestamp value)
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
      • clearCreateTime

        public AnnotatedDataset.Builder clearCreateTime()
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
      • getCreateTimeBuilder

        public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder()
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         Output only. Time the AnnotatedDataset was created.
         
        .google.protobuf.Timestamp create_time = 7;
        Specified by:
        getCreateTimeOrBuilder in interface AnnotatedDatasetOrBuilder
      • hasMetadata

        public boolean hasMetadata()
         Output only. Additional information about AnnotatedDataset.
         
        .google.cloud.datalabeling.v1beta1.AnnotatedDatasetMetadata metadata = 10;
        Specified by:
        hasMetadata in interface AnnotatedDatasetOrBuilder
        Returns:
        Whether the metadata field is set.
      • clearMetadata

        public AnnotatedDataset.Builder clearMetadata()
         Output only. Additional information about AnnotatedDataset.
         
        .google.cloud.datalabeling.v1beta1.AnnotatedDatasetMetadata metadata = 10;
      • getMetadataBuilder

        public AnnotatedDatasetMetadata.Builder getMetadataBuilder()
         Output only. Additional information about AnnotatedDataset.
         
        .google.cloud.datalabeling.v1beta1.AnnotatedDatasetMetadata metadata = 10;
      • getBlockingResourcesList

        public com.google.protobuf.ProtocolStringList getBlockingResourcesList()
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Specified by:
        getBlockingResourcesList in interface AnnotatedDatasetOrBuilder
        Returns:
        A list containing the blockingResources.
      • getBlockingResourcesCount

        public int getBlockingResourcesCount()
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Specified by:
        getBlockingResourcesCount in interface AnnotatedDatasetOrBuilder
        Returns:
        The count of blockingResources.
      • getBlockingResources

        public String getBlockingResources​(int index)
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Specified by:
        getBlockingResources in interface AnnotatedDatasetOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The blockingResources at the given index.
      • getBlockingResourcesBytes

        public com.google.protobuf.ByteString getBlockingResourcesBytes​(int index)
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Specified by:
        getBlockingResourcesBytes in interface AnnotatedDatasetOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the blockingResources at the given index.
      • setBlockingResources

        public AnnotatedDataset.Builder setBlockingResources​(int index,
                                                             String value)
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Parameters:
        index - The index to set the value at.
        value - The blockingResources to set.
        Returns:
        This builder for chaining.
      • addBlockingResources

        public AnnotatedDataset.Builder addBlockingResources​(String value)
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Parameters:
        value - The blockingResources to add.
        Returns:
        This builder for chaining.
      • addAllBlockingResources

        public AnnotatedDataset.Builder addAllBlockingResources​(Iterable<String> values)
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Parameters:
        values - The blockingResources to add.
        Returns:
        This builder for chaining.
      • clearBlockingResources

        public AnnotatedDataset.Builder clearBlockingResources()
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Returns:
        This builder for chaining.
      • addBlockingResourcesBytes

        public AnnotatedDataset.Builder addBlockingResourcesBytes​(com.google.protobuf.ByteString value)
         Output only. The names of any related resources that are blocking changes
         to the annotated dataset.
         
        repeated string blocking_resources = 11;
        Parameters:
        value - The bytes of the blockingResources to add.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final AnnotatedDataset.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>
      • mergeUnknownFields

        public final AnnotatedDataset.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<AnnotatedDataset.Builder>