Class DependencyFilesetsTask

  • All Implemented Interfaces:
    java.lang.Cloneable

    public class DependencyFilesetsTask
    extends org.apache.tools.ant.Task
    Ant task which create a fileset for each dependency in a Maven project, and a fileset containing all selected dependencies.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private DependencyFilesetsConfiguration configuration  
      private java.lang.String mavenProjectId
      The project ref Id of the project being used.
      • Fields inherited from class org.apache.tools.ant.Task

        target, taskName, taskType, wrapper
      • Fields inherited from class org.apache.tools.ant.ProjectComponent

        description, location, project
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void execute()
      java.util.Set<org.apache.maven.artifact.Artifact> filterArtifacts​(java.util.Set<org.apache.maven.artifact.Artifact> artifacts)
      Filter a set of artifacts using the scopes and type filters.
      java.lang.String getMavenProjectId()  
      java.lang.String getPrefix()  
      java.lang.String getProjectDependenciesId()  
      java.lang.String getScopes()  
      java.lang.String getTypes()  
      void setMavenProjectId​(java.lang.String mavenProjectId)  
      void setPrefix​(java.lang.String prefix)
      Prefix to be added to each of the dependency filesets.
      void setProjectDependenciesId​(java.lang.String projectDependenciesId)  
      void setScopes​(java.lang.String scopes)  
      void setTypes​(java.lang.String types)  
      • Methods inherited from class org.apache.tools.ant.Task

        bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
      • Methods inherited from class org.apache.tools.ant.ProjectComponent

        clone, getDescription, getLocation, getProject, setDescription, setLocation, setProject
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • mavenProjectId

        private java.lang.String mavenProjectId
        The project ref Id of the project being used.
    • Constructor Detail

      • DependencyFilesetsTask

        public DependencyFilesetsTask()
    • Method Detail

      • execute

        public void execute()
        Overrides:
        execute in class org.apache.tools.ant.Task
      • getMavenProjectId

        public java.lang.String getMavenProjectId()
        Returns:
        mavenProjectId
      • setMavenProjectId

        public void setMavenProjectId​(java.lang.String mavenProjectId)
        Parameters:
        mavenProjectId - mavenProjectId
      • getPrefix

        public java.lang.String getPrefix()
        Returns:
        prefix Prefix to be added to each of the dependency filesets
      • setPrefix

        public void setPrefix​(java.lang.String prefix)
        Prefix to be added to each of the dependency filesets. Default is empty string.
        Parameters:
        prefix - String to prepend to all fileset IDs.
      • getTypes

        public java.lang.String getTypes()
        Returns:
        types Comma separated list of artifact types to include.
      • setTypes

        public void setTypes​(java.lang.String types)
        Parameters:
        types - Comma separated list of artifact types to include.
      • getScopes

        public java.lang.String getScopes()
        Returns:
        scopes Comma separated list of artifact scopes to include.
      • setScopes

        public void setScopes​(java.lang.String scopes)
        Parameters:
        scopes - Comma separated list of artifact scopes to include.
      • getProjectDependenciesId

        public java.lang.String getProjectDependenciesId()
        Returns:
        RefId for the fileset containing all project dependencies - default maven.project.dependencies
      • setProjectDependenciesId

        public void setProjectDependenciesId​(java.lang.String projectDependenciesId)
        Parameters:
        projectDependenciesId - RefId for the fileset containing all project dependencies
      • filterArtifacts

        public java.util.Set<org.apache.maven.artifact.Artifact> filterArtifacts​(java.util.Set<org.apache.maven.artifact.Artifact> artifacts)
        Filter a set of artifacts using the scopes and type filters.
        Parameters:
        artifacts - Artifact set.
        Returns:
        The set of filtered artifacts.