Class Build.FilesetEntry.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<Build.FilesetEntry.Builder>
com.google.devtools.build.lib.query2.proto.proto2api.Build.FilesetEntry.Builder
All Implemented Interfaces:
Build.FilesetEntryOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
Build.FilesetEntry

public static final class Build.FilesetEntry.Builder extends com.google.protobuf.GeneratedMessage.Builder<Build.FilesetEntry.Builder> implements Build.FilesetEntryOrBuilder
 Represents an entry attribute of a Fileset rule in a build file.
 
Protobuf type blaze_query.FilesetEntry
  • Method Details

    • getDescriptor

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

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<Build.FilesetEntry.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.GeneratedMessage.Builder<Build.FilesetEntry.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.GeneratedMessage.Builder<Build.FilesetEntry.Builder>
    • getDefaultInstanceForType

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

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

      public Build.FilesetEntry buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

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

    • isInitialized

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

      public Build.FilesetEntry.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<Build.FilesetEntry.Builder>
      Throws:
      IOException
    • hasSource

      public boolean hasSource()
       The label pointing to the source target where files are copied from.
       
      required string source = 1;
      Specified by:
      hasSource in interface Build.FilesetEntryOrBuilder
      Returns:
      Whether the source field is set.
    • getSource

      public String getSource()
       The label pointing to the source target where files are copied from.
       
      required string source = 1;
      Specified by:
      getSource in interface Build.FilesetEntryOrBuilder
      Returns:
      The source.
    • getSourceBytes

      public com.google.protobuf.ByteString getSourceBytes()
       The label pointing to the source target where files are copied from.
       
      required string source = 1;
      Specified by:
      getSourceBytes in interface Build.FilesetEntryOrBuilder
      Returns:
      The bytes for source.
    • setSource

      public Build.FilesetEntry.Builder setSource(String value)
       The label pointing to the source target where files are copied from.
       
      required string source = 1;
      Parameters:
      value - The source to set.
      Returns:
      This builder for chaining.
    • clearSource

      public Build.FilesetEntry.Builder clearSource()
       The label pointing to the source target where files are copied from.
       
      required string source = 1;
      Returns:
      This builder for chaining.
    • setSourceBytes

      public Build.FilesetEntry.Builder setSourceBytes(com.google.protobuf.ByteString value)
       The label pointing to the source target where files are copied from.
       
      required string source = 1;
      Parameters:
      value - The bytes for source to set.
      Returns:
      This builder for chaining.
    • hasDestinationDirectory

      public boolean hasDestinationDirectory()
       The relative path within the fileset rule where files will be mapped.
       
      required string destination_directory = 2;
      Specified by:
      hasDestinationDirectory in interface Build.FilesetEntryOrBuilder
      Returns:
      Whether the destinationDirectory field is set.
    • getDestinationDirectory

      public String getDestinationDirectory()
       The relative path within the fileset rule where files will be mapped.
       
      required string destination_directory = 2;
      Specified by:
      getDestinationDirectory in interface Build.FilesetEntryOrBuilder
      Returns:
      The destinationDirectory.
    • getDestinationDirectoryBytes

      public com.google.protobuf.ByteString getDestinationDirectoryBytes()
       The relative path within the fileset rule where files will be mapped.
       
      required string destination_directory = 2;
      Specified by:
      getDestinationDirectoryBytes in interface Build.FilesetEntryOrBuilder
      Returns:
      The bytes for destinationDirectory.
    • setDestinationDirectory

      public Build.FilesetEntry.Builder setDestinationDirectory(String value)
       The relative path within the fileset rule where files will be mapped.
       
      required string destination_directory = 2;
      Parameters:
      value - The destinationDirectory to set.
      Returns:
      This builder for chaining.
    • clearDestinationDirectory

      public Build.FilesetEntry.Builder clearDestinationDirectory()
       The relative path within the fileset rule where files will be mapped.
       
      required string destination_directory = 2;
      Returns:
      This builder for chaining.
    • setDestinationDirectoryBytes

      public Build.FilesetEntry.Builder setDestinationDirectoryBytes(com.google.protobuf.ByteString value)
       The relative path within the fileset rule where files will be mapped.
       
      required string destination_directory = 2;
      Parameters:
      value - The bytes for destinationDirectory to set.
      Returns:
      This builder for chaining.
    • hasFilesPresent

      public boolean hasFilesPresent()
       Whether the files= attribute was specified. This is necessary because
       no files= attribute and files=[] mean different things.
       
      optional bool files_present = 7;
      Specified by:
      hasFilesPresent in interface Build.FilesetEntryOrBuilder
      Returns:
      Whether the filesPresent field is set.
    • getFilesPresent

      public boolean getFilesPresent()
       Whether the files= attribute was specified. This is necessary because
       no files= attribute and files=[] mean different things.
       
      optional bool files_present = 7;
      Specified by:
      getFilesPresent in interface Build.FilesetEntryOrBuilder
      Returns:
      The filesPresent.
    • setFilesPresent

      public Build.FilesetEntry.Builder setFilesPresent(boolean value)
       Whether the files= attribute was specified. This is necessary because
       no files= attribute and files=[] mean different things.
       
      optional bool files_present = 7;
      Parameters:
      value - The filesPresent to set.
      Returns:
      This builder for chaining.
    • clearFilesPresent

      public Build.FilesetEntry.Builder clearFilesPresent()
       Whether the files= attribute was specified. This is necessary because
       no files= attribute and files=[] mean different things.
       
      optional bool files_present = 7;
      Returns:
      This builder for chaining.
    • getFileList

      public com.google.protobuf.ProtocolStringList getFileList()
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Specified by:
      getFileList in interface Build.FilesetEntryOrBuilder
      Returns:
      A list containing the file.
    • getFileCount

      public int getFileCount()
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Specified by:
      getFileCount in interface Build.FilesetEntryOrBuilder
      Returns:
      The count of file.
    • getFile

      public String getFile(int index)
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Specified by:
      getFile in interface Build.FilesetEntryOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The file at the given index.
    • getFileBytes

      public com.google.protobuf.ByteString getFileBytes(int index)
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Specified by:
      getFileBytes in interface Build.FilesetEntryOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the file at the given index.
    • setFile

      public Build.FilesetEntry.Builder setFile(int index, String value)
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Parameters:
      index - The index to set the value at.
      value - The file to set.
      Returns:
      This builder for chaining.
    • addFile

      public Build.FilesetEntry.Builder addFile(String value)
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Parameters:
      value - The file to add.
      Returns:
      This builder for chaining.
    • addAllFile

      public Build.FilesetEntry.Builder addAllFile(Iterable<String> values)
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Parameters:
      values - The file to add.
      Returns:
      This builder for chaining.
    • clearFile

      public Build.FilesetEntry.Builder clearFile()
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Returns:
      This builder for chaining.
    • addFileBytes

      public Build.FilesetEntry.Builder addFileBytes(com.google.protobuf.ByteString value)
       A list of file labels to include from the source directory.
       
      repeated string file = 3;
      Parameters:
      value - The bytes of the file to add.
      Returns:
      This builder for chaining.
    • getExcludeList

      public com.google.protobuf.ProtocolStringList getExcludeList()
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Specified by:
      getExcludeList in interface Build.FilesetEntryOrBuilder
      Returns:
      A list containing the exclude.
    • getExcludeCount

      public int getExcludeCount()
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Specified by:
      getExcludeCount in interface Build.FilesetEntryOrBuilder
      Returns:
      The count of exclude.
    • getExclude

      public String getExclude(int index)
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Specified by:
      getExclude in interface Build.FilesetEntryOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The exclude at the given index.
    • getExcludeBytes

      public com.google.protobuf.ByteString getExcludeBytes(int index)
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Specified by:
      getExcludeBytes in interface Build.FilesetEntryOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the exclude at the given index.
    • setExclude

      public Build.FilesetEntry.Builder setExclude(int index, String value)
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Parameters:
      index - The index to set the value at.
      value - The exclude to set.
      Returns:
      This builder for chaining.
    • addExclude

      public Build.FilesetEntry.Builder addExclude(String value)
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Parameters:
      value - The exclude to add.
      Returns:
      This builder for chaining.
    • addAllExclude

      public Build.FilesetEntry.Builder addAllExclude(Iterable<String> values)
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Parameters:
      values - The exclude to add.
      Returns:
      This builder for chaining.
    • clearExclude

      public Build.FilesetEntry.Builder clearExclude()
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Returns:
      This builder for chaining.
    • addExcludeBytes

      public Build.FilesetEntry.Builder addExcludeBytes(com.google.protobuf.ByteString value)
       If this is a fileset entry representing files within the rule
       package, this lists relative paths to files that should be excluded from
       the set.  This cannot contain values if 'file' also has values.
       
      repeated string exclude = 4;
      Parameters:
      value - The bytes of the exclude to add.
      Returns:
      This builder for chaining.
    • hasSymlinkBehavior

      public boolean hasSymlinkBehavior()
       This field is optional because there will be some time when the new
       PB is used by tools depending on blaze query, but the new blaze version
       is not yet released.
       TODO(bazel-team): Make this field required once a version of Blaze is
       released that outputs this field.
       
      optional .blaze_query.FilesetEntry.SymlinkBehavior symlink_behavior = 5 [default = COPY];
      Specified by:
      hasSymlinkBehavior in interface Build.FilesetEntryOrBuilder
      Returns:
      Whether the symlinkBehavior field is set.
    • getSymlinkBehavior

      public Build.FilesetEntry.SymlinkBehavior getSymlinkBehavior()
       This field is optional because there will be some time when the new
       PB is used by tools depending on blaze query, but the new blaze version
       is not yet released.
       TODO(bazel-team): Make this field required once a version of Blaze is
       released that outputs this field.
       
      optional .blaze_query.FilesetEntry.SymlinkBehavior symlink_behavior = 5 [default = COPY];
      Specified by:
      getSymlinkBehavior in interface Build.FilesetEntryOrBuilder
      Returns:
      The symlinkBehavior.
    • setSymlinkBehavior

       This field is optional because there will be some time when the new
       PB is used by tools depending on blaze query, but the new blaze version
       is not yet released.
       TODO(bazel-team): Make this field required once a version of Blaze is
       released that outputs this field.
       
      optional .blaze_query.FilesetEntry.SymlinkBehavior symlink_behavior = 5 [default = COPY];
      Parameters:
      value - The symlinkBehavior to set.
      Returns:
      This builder for chaining.
    • clearSymlinkBehavior

      public Build.FilesetEntry.Builder clearSymlinkBehavior()
       This field is optional because there will be some time when the new
       PB is used by tools depending on blaze query, but the new blaze version
       is not yet released.
       TODO(bazel-team): Make this field required once a version of Blaze is
       released that outputs this field.
       
      optional .blaze_query.FilesetEntry.SymlinkBehavior symlink_behavior = 5 [default = COPY];
      Returns:
      This builder for chaining.
    • hasStripPrefix

      public boolean hasStripPrefix()
       The prefix to strip from the path of the files in this FilesetEntry. Note
       that no value and the empty string as the value mean different things here.
       
      optional string strip_prefix = 6;
      Specified by:
      hasStripPrefix in interface Build.FilesetEntryOrBuilder
      Returns:
      Whether the stripPrefix field is set.
    • getStripPrefix

      public String getStripPrefix()
       The prefix to strip from the path of the files in this FilesetEntry. Note
       that no value and the empty string as the value mean different things here.
       
      optional string strip_prefix = 6;
      Specified by:
      getStripPrefix in interface Build.FilesetEntryOrBuilder
      Returns:
      The stripPrefix.
    • getStripPrefixBytes

      public com.google.protobuf.ByteString getStripPrefixBytes()
       The prefix to strip from the path of the files in this FilesetEntry. Note
       that no value and the empty string as the value mean different things here.
       
      optional string strip_prefix = 6;
      Specified by:
      getStripPrefixBytes in interface Build.FilesetEntryOrBuilder
      Returns:
      The bytes for stripPrefix.
    • setStripPrefix

      public Build.FilesetEntry.Builder setStripPrefix(String value)
       The prefix to strip from the path of the files in this FilesetEntry. Note
       that no value and the empty string as the value mean different things here.
       
      optional string strip_prefix = 6;
      Parameters:
      value - The stripPrefix to set.
      Returns:
      This builder for chaining.
    • clearStripPrefix

      public Build.FilesetEntry.Builder clearStripPrefix()
       The prefix to strip from the path of the files in this FilesetEntry. Note
       that no value and the empty string as the value mean different things here.
       
      optional string strip_prefix = 6;
      Returns:
      This builder for chaining.
    • setStripPrefixBytes

      public Build.FilesetEntry.Builder setStripPrefixBytes(com.google.protobuf.ByteString value)
       The prefix to strip from the path of the files in this FilesetEntry. Note
       that no value and the empty string as the value mean different things here.
       
      optional string strip_prefix = 6;
      Parameters:
      value - The bytes for stripPrefix to set.
      Returns:
      This builder for chaining.