Class Generated.GitRepoVolumeSource.Builder

  • All Implemented Interfaces:
    com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable, Generated.GitRepoVolumeSourceOrBuilder
    Enclosing class:
    Generated.GitRepoVolumeSource

    public static final class Generated.GitRepoVolumeSource.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<Generated.GitRepoVolumeSource.Builder>
    implements Generated.GitRepoVolumeSourceOrBuilder
     Represents a volume that is populated with the contents of a git repository.
     Git repo volumes do not support ownership management.
     Git repo volumes support SELinux relabeling.
    
     DEPRECATED: GitRepo is deprecated. To provision a container with a git repo, mount an
     EmptyDir into an InitContainer that clones the repo using git, then mount the EmptyDir
     into the Pod's container.
     
    Protobuf type k8s.io.api.core.v1.GitRepoVolumeSource
    • 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<Generated.GitRepoVolumeSource.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<Generated.GitRepoVolumeSource.Builder>
      • getDefaultInstanceForType

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

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

        public Generated.GitRepoVolumeSource buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • isInitialized

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

        public Generated.GitRepoVolumeSource.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<Generated.GitRepoVolumeSource.Builder>
        Throws:
        IOException
      • setRepository

        public Generated.GitRepoVolumeSource.Builder setRepository​(String value)
         repository is the URL
         
        optional string repository = 1;
        Parameters:
        value - The repository to set.
        Returns:
        This builder for chaining.
      • setRepositoryBytes

        public Generated.GitRepoVolumeSource.Builder setRepositoryBytes​(com.google.protobuf.ByteString value)
         repository is the URL
         
        optional string repository = 1;
        Parameters:
        value - The bytes for repository to set.
        Returns:
        This builder for chaining.
      • hasRevision

        public boolean hasRevision()
         revision is the commit hash for the specified revision.
         +optional
         
        optional string revision = 2;
        Specified by:
        hasRevision in interface Generated.GitRepoVolumeSourceOrBuilder
        Returns:
        Whether the revision field is set.
      • getRevisionBytes

        public com.google.protobuf.ByteString getRevisionBytes()
         revision is the commit hash for the specified revision.
         +optional
         
        optional string revision = 2;
        Specified by:
        getRevisionBytes in interface Generated.GitRepoVolumeSourceOrBuilder
        Returns:
        The bytes for revision.
      • setRevision

        public Generated.GitRepoVolumeSource.Builder setRevision​(String value)
         revision is the commit hash for the specified revision.
         +optional
         
        optional string revision = 2;
        Parameters:
        value - The revision to set.
        Returns:
        This builder for chaining.
      • clearRevision

        public Generated.GitRepoVolumeSource.Builder clearRevision()
         revision is the commit hash for the specified revision.
         +optional
         
        optional string revision = 2;
        Returns:
        This builder for chaining.
      • setRevisionBytes

        public Generated.GitRepoVolumeSource.Builder setRevisionBytes​(com.google.protobuf.ByteString value)
         revision is the commit hash for the specified revision.
         +optional
         
        optional string revision = 2;
        Parameters:
        value - The bytes for revision to set.
        Returns:
        This builder for chaining.
      • hasDirectory

        public boolean hasDirectory()
         directory is the target directory name.
         Must not contain or start with '..'.  If '.' is supplied, the volume directory will be the
         git repository.  Otherwise, if specified, the volume will contain the git repository in
         the subdirectory with the given name.
         +optional
         
        optional string directory = 3;
        Specified by:
        hasDirectory in interface Generated.GitRepoVolumeSourceOrBuilder
        Returns:
        Whether the directory field is set.
      • getDirectory

        public String getDirectory()
         directory is the target directory name.
         Must not contain or start with '..'.  If '.' is supplied, the volume directory will be the
         git repository.  Otherwise, if specified, the volume will contain the git repository in
         the subdirectory with the given name.
         +optional
         
        optional string directory = 3;
        Specified by:
        getDirectory in interface Generated.GitRepoVolumeSourceOrBuilder
        Returns:
        The directory.
      • getDirectoryBytes

        public com.google.protobuf.ByteString getDirectoryBytes()
         directory is the target directory name.
         Must not contain or start with '..'.  If '.' is supplied, the volume directory will be the
         git repository.  Otherwise, if specified, the volume will contain the git repository in
         the subdirectory with the given name.
         +optional
         
        optional string directory = 3;
        Specified by:
        getDirectoryBytes in interface Generated.GitRepoVolumeSourceOrBuilder
        Returns:
        The bytes for directory.
      • setDirectory

        public Generated.GitRepoVolumeSource.Builder setDirectory​(String value)
         directory is the target directory name.
         Must not contain or start with '..'.  If '.' is supplied, the volume directory will be the
         git repository.  Otherwise, if specified, the volume will contain the git repository in
         the subdirectory with the given name.
         +optional
         
        optional string directory = 3;
        Parameters:
        value - The directory to set.
        Returns:
        This builder for chaining.
      • clearDirectory

        public Generated.GitRepoVolumeSource.Builder clearDirectory()
         directory is the target directory name.
         Must not contain or start with '..'.  If '.' is supplied, the volume directory will be the
         git repository.  Otherwise, if specified, the volume will contain the git repository in
         the subdirectory with the given name.
         +optional
         
        optional string directory = 3;
        Returns:
        This builder for chaining.
      • setDirectoryBytes

        public Generated.GitRepoVolumeSource.Builder setDirectoryBytes​(com.google.protobuf.ByteString value)
         directory is the target directory name.
         Must not contain or start with '..'.  If '.' is supplied, the volume directory will be the
         git repository.  Otherwise, if specified, the volume will contain the git repository in
         the subdirectory with the given name.
         +optional
         
        optional string directory = 3;
        Parameters:
        value - The bytes for directory to set.
        Returns:
        This builder for chaining.