[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.webtools] Re: new proj wizard

Why does adding the facets occasionally (not every time) give me a "CoreException: One or more constraints have not been staisfied"?


2007-11-07 17:12:41,791 ERROR [org.eclipse.core.runtime.CoreException: One or more constraints have not been satisfied.]
2007-11-07 17:12:41,791 ERROR [ @ org.eclipse.wst.common.project.facet.core.internal.FacetedProject.modifyInternal(FacetedProject.java:282)]
2007-11-07 17:12:41,791 ERROR [ @ org.eclipse.wst.common.project.facet.core.internal.FacetedProject.access$2(FacetedProject.java:264)]
2007-11-07 17:12:41,791 ERROR [ @ org.eclipse.wst.common.project.facet.core.internal.FacetedProject$1.run(FacetedProject.java:249)]
2007-11-07 17:12:41,791 ERROR [ @ org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1737)]
2007-11-07 17:12:41,791 ERROR [ @ org.eclipse.wst.common.project.facet.core.internal.FacetedProject.modify(FacetedProject.java:259)]
2007-11-07 17:12:41,791 ERROR [ @ org.eclipse.wst.common.project.facet.core.internal.FacetedProject.installProjectFacet(FacetedProject.java:216)]
2007-11-07 17:12:41,791 ERROR [ @ com.jk.applications.sce.ui.wizards.ProjectCreationAction.addEclipseProjectFacets(ProjectCreationAction.java:428)]




Konstantin Komissarchik wrote:

Ok. The api that you want is available in the following package:

org.eclipse.wst.common.project.facet.core.*

A dynamic web project is basically a project with at least "jst.java" and "jst.web" facets installed.

The following class is an entry point to the API with a bunch of static methods:

org.eclipse.wst.common.project.facet.core.ProjectFacetsManager

You will want to call one of the create methods on ProjectFacetsManager to get an IFacetedProject object. That object has methods for setting the runtime, installing facets, etc.

- Konstantin