Skip to content
Browse files

Fixed compilation error

  • Loading branch information...
1 parent ef4a107 commit d8af5722b733b5377254ca6da2ffb5585a1777ce @gastaldi gastaldi committed Apr 10, 2013
View
14 maven/impl-projects/src/main/java/org/jboss/forge/maven/projects/MavenPluginFacetImpl.java
@@ -20,8 +20,10 @@
import org.apache.maven.model.PluginManagement;
import org.apache.maven.model.Repository;
import org.jboss.forge.container.exception.ContainerException;
+import org.jboss.forge.dependencies.Coordinate;
import org.jboss.forge.dependencies.Dependency;
import org.jboss.forge.dependencies.DependencyRepository;
+import org.jboss.forge.dependencies.builder.CoordinateBuilder;
import org.jboss.forge.dependencies.builder.DependencyBuilder;
import org.jboss.forge.dependencies.util.Dependencies;
import org.jboss.forge.facets.AbstractFacet;
@@ -83,8 +85,8 @@ public boolean isInstalled()
MavenPluginAdapter adapter = new MavenPluginAdapter(plugin);
MavenPluginBuilder pluginBuilder = MavenPluginBuilder
.create()
- .setDependency(
- DependencyBuilder.create().setGroupId(plugin.getGroupId())
+ .setCoordinate(
+ CoordinateBuilder.create().setGroupId(plugin.getGroupId())
.setArtifactId(plugin.getArtifactId()).setVersion(plugin.getVersion()))
.setConfiguration(adapter.getConfig());
@@ -129,8 +131,8 @@ private MavenPlugin getPlugin(final Dependency dependency, boolean managedPlugin
for (MavenPlugin mavenPlugin : listConfiguredPlugins(managedPlugin))
{
- Dependency temp = mavenPlugin.getDependency();
- if (Dependencies.areEquivalent(temp, DependencyBuilder.create(dependency).setGroupId(groupId)))
+ Coordinate temp = mavenPlugin.getCoordinate();
+ if (temp.equals(CoordinateBuilder.create(temp).setGroupId(groupId)))
{
return mavenPlugin;
}
@@ -181,10 +183,10 @@ private void updatePlugin(final MavenPlugin plugin, boolean managedPlugin)
List<org.apache.maven.model.Plugin> pomPlugins = getPluginsPOM(build, managedPlugin);
for (org.apache.maven.model.Plugin pomPlugin : pomPlugins)
{
- Dependency pluginDep = DependencyBuilder.create().setGroupId(pomPlugin.getGroupId())
+ Coordinate pluginCoord = CoordinateBuilder.create().setGroupId(pomPlugin.getGroupId())
.setArtifactId(pomPlugin.getArtifactId());
- if (Dependencies.areEquivalent(pluginDep, plugin.getDependency()))
+ if (pluginCoord.equals(plugin.getCoordinate()))
{
MavenPluginAdapter adapter = new MavenPluginAdapter(plugin);
pomPlugin.setConfiguration(adapter.getConfiguration());

0 comments on commit d8af572

Please sign in to comment.
Something went wrong with that request. Please try again.