/** * Add all the required maven dependencies to execute a specific version of Tomcat set by the property <code>tomcatVersion</code> to the list of * dependencies of the Tomcat Maven Plugin. * * @param tomcatPluginDependencies current list of dependencies of the Tomcat Maven Plugin */ private void addTomcatDependencies(List<Dependency> tomcatPluginDependencies) { for(Pair<String, String> tomcatDependency : TOMCAT_DEPENDENCIES) { tomcatPluginDependencies.add(dependency(tomcatDependency.getFirst(),tomcatDependency.getSecond(),tomcatVersion)); } }
protected Plugin getAspectJPlugin() { return plugin( "org.codehaus.mojo", "aspectj-maven-plugin", "1.4", dependencies( dependency("org.aspectj", "aspectjtools", aspectJVersion) ) ); }
/** * Method used to add the vert.x dependencies typically the vert.x core * * @param model - the {@code {@link Model}} */ private void addVertxDependencies(Model model) { String groupId = VERTX_GROUP_ID; String artifactId = "vertx-core"; if (model.getDependencies() != null) { if (!MojoUtils.hasDependency(project, groupId, artifactId)) { model.getDependencies().add( dependency(groupId, artifactId, null)); } } else { model.setDependencies(new ArrayList<>()); model.getDependencies().add(dependency(groupId, artifactId, null)); } }
dependency("org.codehaus.plexus", "plexus-archiver", "2.3")); dependency("javax.servlet", "javax.servlet-api", "3.0.1")); for (TomcatDependency tomcatDep : tomcatDependencies) { tomcatPluginDependencies.add( dependency(tomcatDep.getGroupId(), tomcatDep.getArtifactId(), tomcatDep.getVersion())); tomcatPluginDependencies.add( dependency("com.h2database", "h2", "1.4.190")); tomcatPluginDependencies.add( dependency("mysql", "mysql-connector-java", "5.1.32")); } else if (enablePostgreSQL) { tomcatPluginDependencies.add( dependency("org.postgresql", "postgresql", "9.4-1201-jdbc41"));
/** * Method used to add the vert.x "vertx-stack-depchain" BOM * * @param model - the {@code {@link Model}} */ private void addVertxBom(Model model) { Dependency vertxBom = dependency(VERTX_GROUP_ID, "vertx-stack-depchain", "${vertx.version}"); vertxBom.setType("pom"); vertxBom.setScope("import"); if (model.getDependencyManagement() != null) { if (!MojoUtils.hasDependency(project, VERTX_GROUP_ID, "vertx-stack-depchain")) { model.getDependencyManagement().addDependency(vertxBom); } } else { DependencyManagement dm = new DependencyManagement(); dm.addDependency(vertxBom); model.setDependencyManagement(dm); } }