XmlTag (String group, String artifact, String version, PsiFile pom) { MavenDomProjectModel model = MavenDomUtil.getMavenDomModel(pom, MavenDomProjectModel.class); for (MavenDomDependency dependency : model.getDependencies().getDependencies()) { if (dependency.getGroupId().getStringValue().equals(group) && dependency.getArtifactId().getStringValue().equals(artifact) && dependency.getVersion().getStringValue().equals(version)) { return dependency.getXmlTag(); } } return null; }