Class SelectorResolver.Resolution

java.lang.Object
org.junit.platform.engine.support.discovery.SelectorResolver.Resolution
Enclosing interface:
SelectorResolver

@API(status=STABLE, since="1.10") public static class SelectorResolver.Resolution extends Object
The result of an attempt to resolve a DiscoverySelector.

A resolution is either unresolved, contains a match or multiple matches, or a set of selectors.

Since:
1.5
See Also:
  • Method Details

    • unresolved

      public static SelectorResolver.Resolution unresolved()
      Factory for creating unresolved resolutions.
      Returns:
      an unresolved resolution; never null
    • match

      Factory for creating a resolution that contains the supplied Match.
      Parameters:
      match - the resolved Match; never null
      Returns:
      an resolution that contains the supplied Match; never null
    • matches

      public static SelectorResolver.Resolution matches(Set<SelectorResolver.Match> matches)
      Factory for creating a resolution that contains the supplied Matches.
      Parameters:
      matches - the resolved Matches; never null or empty
      Returns:
      an resolution that contains the supplied Matches; never null
    • selectors

      public static SelectorResolver.Resolution selectors(Set<? extends DiscoverySelector> selectors)
      Factory for creating a resolution that contains the supplied DiscoverySelectors.
      Parameters:
      selectors - the resolved DiscoverySelectors; never null or empty
      Returns:
      an resolution that contains the supplied DiscoverySelectors; never null
    • isResolved

      public boolean isResolved()
      Whether this resolution contains matches or selectors.
      Returns:
      true if this resolution contains matches or selectors
    • getMatches

      public Set<SelectorResolver.Match> getMatches()
      Returns the matches contained by this resolution.
      Returns:
      the set of matches; never null but potentially empty
    • getSelectors

      public Set<? extends DiscoverySelector> getSelectors()
      Returns the selectors contained by this resolution.
      Returns:
      the set of selectors; never null but potentially empty