Class DocumentSchema.Builder

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

    public static final class DocumentSchema.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<DocumentSchema.Builder>
    implements DocumentSchemaOrBuilder
     A document schema used to define document structure.
     
    Protobuf type google.cloud.contentwarehouse.v1.DocumentSchema
    • 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<DocumentSchema.Builder>
      • clear

        public DocumentSchema.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<DocumentSchema.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<DocumentSchema.Builder>
      • getDefaultInstanceForType

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

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

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

        public DocumentSchema.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<DocumentSchema.Builder>
      • setField

        public DocumentSchema.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<DocumentSchema.Builder>
      • clearField

        public DocumentSchema.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<DocumentSchema.Builder>
      • clearOneof

        public DocumentSchema.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<DocumentSchema.Builder>
      • setRepeatedField

        public DocumentSchema.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<DocumentSchema.Builder>
      • addRepeatedField

        public DocumentSchema.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<DocumentSchema.Builder>
      • mergeFrom

        public DocumentSchema.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<DocumentSchema.Builder>
      • isInitialized

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

        public DocumentSchema.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<DocumentSchema.Builder>
        Throws:
        IOException
      • getName

        public String getName()
         The resource name of the document schema.
         Format:
         projects/{project_number}/locations/{location}/documentSchemas/{document_schema_id}.
        
         The name is ignored when creating a document schema.
         
        string name = 1;
        Specified by:
        getName in interface DocumentSchemaOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         The resource name of the document schema.
         Format:
         projects/{project_number}/locations/{location}/documentSchemas/{document_schema_id}.
        
         The name is ignored when creating a document schema.
         
        string name = 1;
        Specified by:
        getNameBytes in interface DocumentSchemaOrBuilder
        Returns:
        The bytes for name.
      • setName

        public DocumentSchema.Builder setName​(String value)
         The resource name of the document schema.
         Format:
         projects/{project_number}/locations/{location}/documentSchemas/{document_schema_id}.
        
         The name is ignored when creating a document schema.
         
        string name = 1;
        Parameters:
        value - The name to set.
        Returns:
        This builder for chaining.
      • clearName

        public DocumentSchema.Builder clearName()
         The resource name of the document schema.
         Format:
         projects/{project_number}/locations/{location}/documentSchemas/{document_schema_id}.
        
         The name is ignored when creating a document schema.
         
        string name = 1;
        Returns:
        This builder for chaining.
      • setNameBytes

        public DocumentSchema.Builder setNameBytes​(com.google.protobuf.ByteString value)
         The resource name of the document schema.
         Format:
         projects/{project_number}/locations/{location}/documentSchemas/{document_schema_id}.
        
         The name is ignored when creating a document schema.
         
        string name = 1;
        Parameters:
        value - The bytes for name to set.
        Returns:
        This builder for chaining.
      • getDisplayName

        public String getDisplayName()
         Required. Name of the schema given by the user. Must be unique per project.
         
        string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getDisplayName in interface DocumentSchemaOrBuilder
        Returns:
        The displayName.
      • getDisplayNameBytes

        public com.google.protobuf.ByteString getDisplayNameBytes()
         Required. Name of the schema given by the user. Must be unique per project.
         
        string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getDisplayNameBytes in interface DocumentSchemaOrBuilder
        Returns:
        The bytes for displayName.
      • setDisplayName

        public DocumentSchema.Builder setDisplayName​(String value)
         Required. Name of the schema given by the user. Must be unique per project.
         
        string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The displayName to set.
        Returns:
        This builder for chaining.
      • clearDisplayName

        public DocumentSchema.Builder clearDisplayName()
         Required. Name of the schema given by the user. Must be unique per project.
         
        string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
        Returns:
        This builder for chaining.
      • setDisplayNameBytes

        public DocumentSchema.Builder setDisplayNameBytes​(com.google.protobuf.ByteString value)
         Required. Name of the schema given by the user. Must be unique per project.
         
        string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
        Parameters:
        value - The bytes for displayName to set.
        Returns:
        This builder for chaining.
      • getPropertyDefinitionsCount

        public int getPropertyDefinitionsCount()
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
        Specified by:
        getPropertyDefinitionsCount in interface DocumentSchemaOrBuilder
      • setPropertyDefinitions

        public DocumentSchema.Builder setPropertyDefinitions​(int index,
                                                             PropertyDefinition value)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • setPropertyDefinitions

        public DocumentSchema.Builder setPropertyDefinitions​(int index,
                                                             PropertyDefinition.Builder builderForValue)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • addPropertyDefinitions

        public DocumentSchema.Builder addPropertyDefinitions​(PropertyDefinition value)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • addPropertyDefinitions

        public DocumentSchema.Builder addPropertyDefinitions​(int index,
                                                             PropertyDefinition value)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • addPropertyDefinitions

        public DocumentSchema.Builder addPropertyDefinitions​(int index,
                                                             PropertyDefinition.Builder builderForValue)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • addAllPropertyDefinitions

        public DocumentSchema.Builder addAllPropertyDefinitions​(Iterable<? extends PropertyDefinition> values)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • clearPropertyDefinitions

        public DocumentSchema.Builder clearPropertyDefinitions()
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • removePropertyDefinitions

        public DocumentSchema.Builder removePropertyDefinitions​(int index)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • getPropertyDefinitionsBuilder

        public PropertyDefinition.Builder getPropertyDefinitionsBuilder​(int index)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • addPropertyDefinitionsBuilder

        public PropertyDefinition.Builder addPropertyDefinitionsBuilder()
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • addPropertyDefinitionsBuilder

        public PropertyDefinition.Builder addPropertyDefinitionsBuilder​(int index)
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • getPropertyDefinitionsBuilderList

        public List<PropertyDefinition.Builder> getPropertyDefinitionsBuilderList()
         Document details.
         
        repeated .google.cloud.contentwarehouse.v1.PropertyDefinition property_definitions = 3;
      • getDocumentIsFolder

        public boolean getDocumentIsFolder()
         Document Type, true refers the document is a folder, otherwise it is
         a typical document.
         
        bool document_is_folder = 4;
        Specified by:
        getDocumentIsFolder in interface DocumentSchemaOrBuilder
        Returns:
        The documentIsFolder.
      • setDocumentIsFolder

        public DocumentSchema.Builder setDocumentIsFolder​(boolean value)
         Document Type, true refers the document is a folder, otherwise it is
         a typical document.
         
        bool document_is_folder = 4;
        Parameters:
        value - The documentIsFolder to set.
        Returns:
        This builder for chaining.
      • clearDocumentIsFolder

        public DocumentSchema.Builder clearDocumentIsFolder()
         Document Type, true refers the document is a folder, otherwise it is
         a typical document.
         
        bool document_is_folder = 4;
        Returns:
        This builder for chaining.
      • hasUpdateTime

        public boolean hasUpdateTime()
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasUpdateTime in interface DocumentSchemaOrBuilder
        Returns:
        Whether the updateTime field is set.
      • getUpdateTime

        public com.google.protobuf.Timestamp getUpdateTime()
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTime in interface DocumentSchemaOrBuilder
        Returns:
        The updateTime.
      • setUpdateTime

        public DocumentSchema.Builder setUpdateTime​(com.google.protobuf.Timestamp value)
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • setUpdateTime

        public DocumentSchema.Builder setUpdateTime​(com.google.protobuf.Timestamp.Builder builderForValue)
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • mergeUpdateTime

        public DocumentSchema.Builder mergeUpdateTime​(com.google.protobuf.Timestamp value)
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • clearUpdateTime

        public DocumentSchema.Builder clearUpdateTime()
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • getUpdateTimeBuilder

        public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder()
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • getUpdateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
         Output only. The time when the document schema is last updated.
         
        .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTimeOrBuilder in interface DocumentSchemaOrBuilder
      • hasCreateTime

        public boolean hasCreateTime()
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasCreateTime in interface DocumentSchemaOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTime in interface DocumentSchemaOrBuilder
        Returns:
        The createTime.
      • setCreateTime

        public DocumentSchema.Builder setCreateTime​(com.google.protobuf.Timestamp value)
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • setCreateTime

        public DocumentSchema.Builder setCreateTime​(com.google.protobuf.Timestamp.Builder builderForValue)
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • mergeCreateTime

        public DocumentSchema.Builder mergeCreateTime​(com.google.protobuf.Timestamp value)
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • clearCreateTime

        public DocumentSchema.Builder clearCreateTime()
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • getCreateTimeBuilder

        public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder()
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         Output only. The time when the document schema is created.
         
        .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTimeOrBuilder in interface DocumentSchemaOrBuilder
      • getDescriptionBytes

        public com.google.protobuf.ByteString getDescriptionBytes()
         Schema description.
         
        string description = 7;
        Specified by:
        getDescriptionBytes in interface DocumentSchemaOrBuilder
        Returns:
        The bytes for description.
      • setDescription

        public DocumentSchema.Builder setDescription​(String value)
         Schema description.
         
        string description = 7;
        Parameters:
        value - The description to set.
        Returns:
        This builder for chaining.
      • clearDescription

        public DocumentSchema.Builder clearDescription()
         Schema description.
         
        string description = 7;
        Returns:
        This builder for chaining.
      • setDescriptionBytes

        public DocumentSchema.Builder setDescriptionBytes​(com.google.protobuf.ByteString value)
         Schema description.
         
        string description = 7;
        Parameters:
        value - The bytes for description to set.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final DocumentSchema.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<DocumentSchema.Builder>
      • mergeUnknownFields

        public final DocumentSchema.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<DocumentSchema.Builder>