code: public static boolean artifactsAreMatchingTypes(Artifact first, Artifact second) {
          return first.getGroupId().equals(second.getGroupId()) &&
                  first.getArtifactId().equals(second.getArtifactId()) &&
                  first.getExtension().equals(second.getExtension()) &&
                  first.getClassifier().equals(second.getClassifier());
      }
docs: Checks to see if two artifacts are of the same type (but not necessarily the same version)
  
  @param first  An Artifact
  @param second A comparison Artifact
  @return true if the Artifacts match, false if they don't