Class AbstractArtifactFeatureFilter

    • Constructor Detail

      • AbstractArtifactFeatureFilter

        public AbstractArtifactFeatureFilter​(String include,
                                             String exclude)

        Constructor for AbstractArtifactFeatureFilter.

        Parameters:
        include - comma separated list with includes.
        exclude - comma separated list with excludes.
    • Method Detail

      • filter

        public Set<Artifact> filter​(Set<Artifact> artifacts)

        filter.

        This function determines if filtering needs to be performed. Includes are processed before Excludes.
        Parameters:
        artifacts - Artifact
        Returns:
        Set of artifacts.
      • getArtifactFeature

        protected abstract String getArtifactFeature​(Artifact artifact)
        Should return the type or classifier of the given artifact, so that we can filter it
        Parameters:
        artifact - artifact to return type or classifier of
        Returns:
        type or classifier
      • setExcludes

        public void setExcludes​(String excludeString)

        Setter for the field excludes.

        Parameters:
        excludeString - comma separated list with excludes.
      • setIncludes

        public void setIncludes​(String includeString)

        Setter for the field includes.

        Parameters:
        includeString - comma separated list with includes.
      • getExcludes

        public List<String> getExcludes()

        Getter for the field excludes.

        Returns:
        Returns the excludes.
      • getIncludes

        public List<String> getIncludes()

        Getter for the field includes.

        Returns:
        Returns the includes.
      • compareFeatures

        protected boolean compareFeatures​(String lhs,
                                          String rhs)
        Allows Feature comparison to be customized
        Parameters:
        lhs - String artifact's feature
        rhs - String feature from exclude or include list
        Returns:
        boolean true if features match