Class AyoyArtifact


  • public class AyoyArtifact
    extends Object
    Represents a found artifact, including license information.
    • Constructor Detail

      • AyoyArtifact

        public AyoyArtifact​(org.apache.maven.artifact.Artifact artifact,
                            AyoyArtifact parent)
        Initialize the instance.
        Parameters:
        artifact - the maven artifact found.
        parent - the parent artifact.
    • Method Detail

      • addLicenses

        public void addLicenses​(List<org.apache.maven.model.License> licenses)
        Add licenses to the artifact.
        Parameters:
        licenses - the licenses to add.
      • getLicenses

        public List<org.apache.maven.model.License> getLicenses()
      • getArtifact

        public org.apache.maven.artifact.Artifact getArtifact()
      • getChainString

        public String getChainString()
        Creates a string representing the dependency chain to this artifact.
        Returns:
        a string representing the dependency chain to this artifact.
      • addLicenseInfo

        public void addLicenseInfo​(LicenseInfo info)
        Adds a license info about the licenses for the artifact.
        Parameters:
        info - the license information.
      • isLicenseValid

        public boolean isLicenseValid​(boolean requireAllValid)
        Check if licenses are valid.
        Parameters:
        requireAllValid - if all licenses are required to be valid
        Returns:
        true if valid.
      • getParentString

        public String getParentString()
        Create a string representation as if we're the parent.
        Returns:
        a string representation.