Interface SubprojectProvider


public interface SubprojectProvider
Optional ability of projects which may have a list of "subprojects". The exact interpretation of this term is at the discretion of the project, but typically subprojects would be "built" as part of this project or somehow used in it as dependencies; or they may just be contained or agglomerated in it somehow. Note:Since 1.56, there are a more specifically defined variants DependencyProjectProvider and ProjectContainerProvider that if defined in project provide a list of projects the current project depends on or contains. In some project types ( currently maven support) that is the preferred and supported way of getting project's dependency projects and maven modules.
See Also:
  • Method Details

    • getSubprojects

      Set<? extends Project> getSubprojects()
      Get a set of projects which this project can be considered to depend upon somehow. This information is likely to be used only for UI purposes. Only direct subprojects need be listed, not all recursive subprojects. There may be no direct or indirect cycles in the project dependency graph but it may be a DAG, i.e. two projects may both depend on the same subproject.
      Returns:
      an immutable and unchanging set of Projects
      See Also:
    • addChangeListener

      void addChangeListener(ChangeListener listener)
      Add a listener to changes in the set of subprojects.
      Parameters:
      listener - a listener to add
    • removeChangeListener

      void removeChangeListener(ChangeListener listener)
      Remove a listener to changes in the set of subprojects.
      Parameters:
      listener - a listener to remove