Class LibraryKey

java.lang.Object
net.glowstone.util.library.LibraryKey
All Implemented Interfaces:
Comparable<LibraryKey>

public class LibraryKey extends Object implements Comparable<LibraryKey>
Encapsulates the identifying pieces of a library in a Maven repository, its group ID and artifact ID. Can be safely used as a key in a map or within a set.
  • Constructor Details

    • LibraryKey

      public LibraryKey(@NonNls @NonNls String groupId, @NonNls @NonNls String artifactId)
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • compareTo

      public int compareTo(LibraryKey o)
      Specified by:
      compareTo in interface Comparable<LibraryKey>
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getGroupId

      public String getGroupId()
      The group ID of the library in a maven-style repo. Parts of the group ID must be separated by periods.
    • getArtifactId

      public String getArtifactId()
      The artifact ID of the library in a maven-style repo.