Class FilteredProjectDependencyGraph

    • Constructor Detail

      • FilteredProjectDependencyGraph

        FilteredProjectDependencyGraph​(ProjectDependencyGraph projectDependencyGraph,
                                       java.util.Collection<? extends MavenProject> whiteList)
        Creates a new project dependency graph from the specified graph.
        Parameters:
        projectDependencyGraph - The project dependency graph to create a sub view from, must not be null.
        whiteList - The projects on which the dependency view should focus, must not be null.
    • Method Detail

      • getSortedProjects

        public java.util.List<MavenProject> getSortedProjects()
        Description copied from interface: ProjectDependencyGraph
        Gets all projects in their intended build order, i.e. after topologically sorting the projects according to their inter-dependencies.
        Specified by:
        getSortedProjects in interface ProjectDependencyGraph
        Returns:
        The projects in the build order, never null.
      • getDownstreamProjects

        public java.util.List<MavenProject> getDownstreamProjects​(MavenProject project,
                                                                  boolean transitive)
        Description copied from interface: ProjectDependencyGraph
        Gets the downstream projects of the specified project. A downstream project is a project that directly or indirectly depends on the given project.
        Specified by:
        getDownstreamProjects in interface ProjectDependencyGraph
        Parameters:
        project - The project whose downstream projects should be retrieved, must not be null.
        transitive - A flag whether to retrieve all direct and indirect downstream projects or just the immediate downstream projects.
        Returns:
        The downstream projects in the build order, never null.
      • getUpstreamProjects

        public java.util.List<MavenProject> getUpstreamProjects​(MavenProject project,
                                                                boolean transitive)
        Description copied from interface: ProjectDependencyGraph
        Gets the upstream projects of the specified project. An upstream project is a project that directly or indirectly is a prerequisite of the given project.
        Specified by:
        getUpstreamProjects in interface ProjectDependencyGraph
        Parameters:
        project - The project whose upstream projects should be retrieved, must not be null.
        transitive - A flag whether to retrieve all direct and indirect upstream projects or just the immediate upstream projects.
        Returns:
        The upstream projects in the build order, never null.
      • applyFilter

        private java.util.List<MavenProject> applyFilter​(java.util.Collection<? extends MavenProject> projects)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object