Skip to content

Commit

Permalink
AbstractJavaEEFacet now extends JavaEEFacet
Browse files Browse the repository at this point in the history
  • Loading branch information
gastaldi committed Jun 17, 2015
1 parent 8478c3b commit d61be24
Showing 1 changed file with 7 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,9 @@
import org.jboss.forge.addon.dependencies.Dependency;
import org.jboss.forge.addon.dependencies.builder.DependencyBuilder;
import org.jboss.forge.addon.facets.AbstractFacet;
import org.jboss.forge.addon.facets.Facet;
import org.jboss.forge.addon.projects.Project;
import org.jboss.forge.addon.projects.ProjectFacet;
import org.jboss.forge.addon.projects.dependencies.DependencyInstaller;
import org.jboss.forge.addon.projects.facets.DependencyFacet;
import org.jboss.forge.furnace.versions.Version;

/**
* A base facet implementation for Facets which require Java EE library APIs to be installed.
Expand All @@ -30,7 +27,7 @@
* @author <a href="mailto:ggastald@redhat.com">George Gastaldi</a>
*
*/
public abstract class AbstractJavaEEFacet extends AbstractFacet<Project> implements ProjectFacet
public abstract class AbstractJavaEEFacet extends AbstractFacet<Project> implements JavaEEFacet
{
// Version is statically set
protected static final Dependency JAVAEE6 =
Expand All @@ -49,11 +46,6 @@ public AbstractJavaEEFacet(final DependencyInstaller installer)
this.installer = installer;
}

/**
* Return the version of the relevant specification handled by this {@link Facet}.
*/
abstract public Version getSpecVersion();

/**
* Return a {@link Map} where KEY represents a {@link Dependency} to be installed if none of the VALUE
* {@link Dependency} are installed.
Expand Down Expand Up @@ -129,4 +121,10 @@ protected DependencyInstaller getInstaller()
return installer;
}

@Override
public String toString()
{
return String.format("%s %s", getSpecName(), getSpecVersion());
}

}

0 comments on commit d61be24

Please sign in to comment.