Class File.Builder

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

    public static final class File.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<File.Builder>
    implements FileOrBuilder
     Files store content that is potentially associated with Packages or Versions.
     
    Protobuf type google.devtools.artifactregistry.v1beta2.File
    • 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<File.Builder>
      • clear

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

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

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

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

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

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

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

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

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

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

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

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

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

        public String getName()
         The name of the file, for example:
         "projects/p1/locations/us-central1/repositories/repo1/files/a%2Fb%2Fc.txt".
         If the file ID part contains slashes, they are escaped.
         
        string name = 1;
        Specified by:
        getName in interface FileOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         The name of the file, for example:
         "projects/p1/locations/us-central1/repositories/repo1/files/a%2Fb%2Fc.txt".
         If the file ID part contains slashes, they are escaped.
         
        string name = 1;
        Specified by:
        getNameBytes in interface FileOrBuilder
        Returns:
        The bytes for name.
      • setName

        public File.Builder setName​(String value)
         The name of the file, for example:
         "projects/p1/locations/us-central1/repositories/repo1/files/a%2Fb%2Fc.txt".
         If the file ID part contains slashes, they are escaped.
         
        string name = 1;
        Parameters:
        value - The name to set.
        Returns:
        This builder for chaining.
      • clearName

        public File.Builder clearName()
         The name of the file, for example:
         "projects/p1/locations/us-central1/repositories/repo1/files/a%2Fb%2Fc.txt".
         If the file ID part contains slashes, they are escaped.
         
        string name = 1;
        Returns:
        This builder for chaining.
      • setNameBytes

        public File.Builder setNameBytes​(com.google.protobuf.ByteString value)
         The name of the file, for example:
         "projects/p1/locations/us-central1/repositories/repo1/files/a%2Fb%2Fc.txt".
         If the file ID part contains slashes, they are escaped.
         
        string name = 1;
        Parameters:
        value - The bytes for name to set.
        Returns:
        This builder for chaining.
      • getSizeBytes

        public long getSizeBytes()
         The size of the File in bytes.
         
        int64 size_bytes = 3;
        Specified by:
        getSizeBytes in interface FileOrBuilder
        Returns:
        The sizeBytes.
      • setSizeBytes

        public File.Builder setSizeBytes​(long value)
         The size of the File in bytes.
         
        int64 size_bytes = 3;
        Parameters:
        value - The sizeBytes to set.
        Returns:
        This builder for chaining.
      • clearSizeBytes

        public File.Builder clearSizeBytes()
         The size of the File in bytes.
         
        int64 size_bytes = 3;
        Returns:
        This builder for chaining.
      • getHashesList

        public List<Hash> getHashesList()
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
        Specified by:
        getHashesList in interface FileOrBuilder
      • getHashesCount

        public int getHashesCount()
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
        Specified by:
        getHashesCount in interface FileOrBuilder
      • getHashes

        public Hash getHashes​(int index)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
        Specified by:
        getHashes in interface FileOrBuilder
      • setHashes

        public File.Builder setHashes​(int index,
                                      Hash value)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • setHashes

        public File.Builder setHashes​(int index,
                                      Hash.Builder builderForValue)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • addHashes

        public File.Builder addHashes​(Hash value)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • addHashes

        public File.Builder addHashes​(int index,
                                      Hash value)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • addHashes

        public File.Builder addHashes​(Hash.Builder builderForValue)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • addHashes

        public File.Builder addHashes​(int index,
                                      Hash.Builder builderForValue)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • addAllHashes

        public File.Builder addAllHashes​(Iterable<? extends Hash> values)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • clearHashes

        public File.Builder clearHashes()
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • removeHashes

        public File.Builder removeHashes​(int index)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • getHashesBuilder

        public Hash.Builder getHashesBuilder​(int index)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • getHashesOrBuilder

        public HashOrBuilder getHashesOrBuilder​(int index)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
        Specified by:
        getHashesOrBuilder in interface FileOrBuilder
      • addHashesBuilder

        public Hash.Builder addHashesBuilder()
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • addHashesBuilder

        public Hash.Builder addHashesBuilder​(int index)
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • getHashesBuilderList

        public List<Hash.Builder> getHashesBuilderList()
         The hashes of the file content.
         
        repeated .google.devtools.artifactregistry.v1beta2.Hash hashes = 4;
      • hasCreateTime

        public boolean hasCreateTime()
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
        Specified by:
        hasCreateTime in interface FileOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
        Specified by:
        getCreateTime in interface FileOrBuilder
        Returns:
        The createTime.
      • setCreateTime

        public File.Builder setCreateTime​(com.google.protobuf.Timestamp value)
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
      • setCreateTime

        public File.Builder setCreateTime​(com.google.protobuf.Timestamp.Builder builderForValue)
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
      • mergeCreateTime

        public File.Builder mergeCreateTime​(com.google.protobuf.Timestamp value)
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
      • clearCreateTime

        public File.Builder clearCreateTime()
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
      • getCreateTimeBuilder

        public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder()
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         The time when the File was created.
         
        .google.protobuf.Timestamp create_time = 5;
        Specified by:
        getCreateTimeOrBuilder in interface FileOrBuilder
      • hasUpdateTime

        public boolean hasUpdateTime()
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
        Specified by:
        hasUpdateTime in interface FileOrBuilder
        Returns:
        Whether the updateTime field is set.
      • getUpdateTime

        public com.google.protobuf.Timestamp getUpdateTime()
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
        Specified by:
        getUpdateTime in interface FileOrBuilder
        Returns:
        The updateTime.
      • setUpdateTime

        public File.Builder setUpdateTime​(com.google.protobuf.Timestamp value)
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
      • setUpdateTime

        public File.Builder setUpdateTime​(com.google.protobuf.Timestamp.Builder builderForValue)
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
      • mergeUpdateTime

        public File.Builder mergeUpdateTime​(com.google.protobuf.Timestamp value)
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
      • clearUpdateTime

        public File.Builder clearUpdateTime()
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
      • getUpdateTimeBuilder

        public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder()
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
      • getUpdateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
         The time when the File was last updated.
         
        .google.protobuf.Timestamp update_time = 6;
        Specified by:
        getUpdateTimeOrBuilder in interface FileOrBuilder
      • getOwner

        public String getOwner()
         The name of the Package or Version that owns this file, if any.
         
        string owner = 7;
        Specified by:
        getOwner in interface FileOrBuilder
        Returns:
        The owner.
      • getOwnerBytes

        public com.google.protobuf.ByteString getOwnerBytes()
         The name of the Package or Version that owns this file, if any.
         
        string owner = 7;
        Specified by:
        getOwnerBytes in interface FileOrBuilder
        Returns:
        The bytes for owner.
      • setOwner

        public File.Builder setOwner​(String value)
         The name of the Package or Version that owns this file, if any.
         
        string owner = 7;
        Parameters:
        value - The owner to set.
        Returns:
        This builder for chaining.
      • clearOwner

        public File.Builder clearOwner()
         The name of the Package or Version that owns this file, if any.
         
        string owner = 7;
        Returns:
        This builder for chaining.
      • setOwnerBytes

        public File.Builder setOwnerBytes​(com.google.protobuf.ByteString value)
         The name of the Package or Version that owns this file, if any.
         
        string owner = 7;
        Parameters:
        value - The bytes for owner to set.
        Returns:
        This builder for chaining.
      • setUnknownFields

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

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