Interface CapabilityResolutionDetails


  • public interface CapabilityResolutionDetails
    Gives access to the resolution details of a single capability conflict. This class may be used to resolve a capability conflict by either selecting explicitly one of the candidates, or selecting the one with the highest version of the capability.
    Since:
    5.6
    • Method Detail

      • getCapability

        Capability getCapability()
        Returns the capability in conflict
      • getCandidates

        java.util.List<ComponentVariantIdentifier> getCandidates()
        Returns the list of components which are in conflict on this capability
      • select

        CapabilityResolutionDetails select​(java.lang.Object notation)
        Selects a particular candidate to solve the conflict. It is recommended to provide a human-readable explanation to the choice by calling the because(String) method
        Parameters:
        notation - the selected candidate
        Returns:
        this details instance
      • selectHighestVersion

        CapabilityResolutionDetails selectHighestVersion()
        Automatically selects the candidate module which has the highest version of the capability. A reason is automatically added so calling because(String) would override the automatic selection description.
        Returns:
        this details instance
      • because

        CapabilityResolutionDetails because​(java.lang.String reason)
        Describes why a particular candidate is selected.
        Parameters:
        reason - the reason why a candidate is selected.
        Returns:
        this details instance