Class ArtifactGroup

  • All Implemented Interfaces:
    java.lang.Comparable<ArtifactGroup>, java.lang.Iterable<Artifact>

    public class ArtifactGroup
    extends ItemList<Artifact>
    implements java.lang.Comparable<ArtifactGroup>
    A artifact group holds a set of artifacts. A valid start level is positive, start level 0 means the default OSGi start level.
    • Constructor Detail

      • ArtifactGroup

        public ArtifactGroup​(int startLevel)
        Create a new artifact group with the level.
        Parameters:
        startLevel - The start level.
    • Method Detail

      • add

        public void add​(Artifact item)
        Description copied from class: ItemList
        Add a new item
        Overrides:
        add in class ItemList<Artifact>
        Parameters:
        item - The new item
      • getStartLevel

        public int getStartLevel()
        Get the start level.
        Returns:
        The start level.
      • search

        public Artifact search​(Artifact template)
        Search an artifact with the same groupId, artifactId, type and classifier. Version is not considered.
        Parameters:
        template - A template artifact
        Returns:
        The artifact or null.
      • compareTo

        public int compareTo​(ArtifactGroup o)
        Specified by:
        compareTo in interface java.lang.Comparable<ArtifactGroup>