JBoss Tools SVN: r44570 - trunk/build/aggregate.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2012-10-18 01:37:54 -0400 (Thu, 18 Oct 2012)
New Revision: 44570
Modified:
trunk/build/aggregate/pom.xml
Log:
default to using jbosstools-target-site-maximum and targetPlatformGroup-maximum so we use SR1a instead of SR0c bits
Modified: trunk/build/aggregate/pom.xml
===================================================================
--- trunk/build/aggregate/pom.xml 2012-10-18 05:37:47 UTC (rev 44569)
+++ trunk/build/aggregate/pom.xml 2012-10-18 05:37:54 UTC (rev 44570)
@@ -11,6 +11,13 @@
<artifactId>org.jboss.tools.site</artifactId>
<version>0.0.2-SNAPSHOT</version>
<packaging>pom</packaging>
+
+ <properties>
+ <!-- override parent pom to build from latest MAXIMUM TP instead of MINIMUM -->
+ <targetPlatformGroup>${targetPlatformGroup-maximum}</targetPlatformGroup>
+ <jbosstools-target-site>${jbosstools-target-site-maximum}</jbosstools-target-site>
+ </properties>
+
<modules>
<module>site</module>
</modules>
12 years, 2 months
JBoss Tools SVN: r44568 - trunk/build/aggregate.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2012-10-18 01:37:41 -0400 (Thu, 18 Oct 2012)
New Revision: 44568
Modified:
trunk/build/aggregate/pom-all.xml
trunk/build/aggregate/pom.xml
Log:
remove target-platform from the site build; remove ref to obsolete site/sources/pom.xml
Modified: trunk/build/aggregate/pom-all.xml
===================================================================
--- trunk/build/aggregate/pom-all.xml 2012-10-17 22:23:08 UTC (rev 44567)
+++ trunk/build/aggregate/pom-all.xml 2012-10-18 05:37:41 UTC (rev 44568)
@@ -12,22 +12,15 @@
<version>0.0.2-SNAPSHOT</version>
<packaging>pom</packaging>
<modules>
- <module>../target-platform</module>
-
<module>site</module>
<module>soa-site</module>
<module>webtools-site</module>
<module>bottests-site</module>
-
- <module>site/sources</module>
</modules>
<!-- to build an individual site, use this:
-
mvn clean install -f site/pom.xml -Dcollect.zips.skip
mvn clean install -f soa-site/pom.xml -Dcollect.zips.skip
mvn clean install -f webtools-site/pom.xml
mvn clean install -f bottests-site/pom.xml
-
- mvn clean install -f site/sources/pom.xml
-->
</project>
Modified: trunk/build/aggregate/pom.xml
===================================================================
--- trunk/build/aggregate/pom.xml 2012-10-17 22:23:08 UTC (rev 44567)
+++ trunk/build/aggregate/pom.xml 2012-10-18 05:37:41 UTC (rev 44568)
@@ -12,7 +12,6 @@
<version>0.0.2-SNAPSHOT</version>
<packaging>pom</packaging>
<modules>
- <module>../target-platform</module>
<module>site</module>
</modules>
<!-- to build an individual site, use this:
12 years, 2 months
JBoss Tools SVN: r44567 - trunk/build.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2012-10-17 18:23:08 -0400 (Wed, 17 Oct 2012)
New Revision: 44567
Modified:
trunk/build/pom.xml
Log:
removed references to emma from build/pom.xml
Modified: trunk/build/pom.xml
===================================================================
--- trunk/build/pom.xml 2012-10-17 19:20:11 UTC (rev 44566)
+++ trunk/build/pom.xml 2012-10-17 22:23:08 UTC (rev 44567)
@@ -33,19 +33,6 @@
</profile>
<profile>
- <id>emma/lib</id>
- <activation>
- <activeByDefault>true</activeByDefault>
- <property>
- <name>coverage</name>
- </property>
- </activation>
- <modules>
- <module>emma/lib</module>
- </modules>
- </profile>
-
- <profile>
<id>tests</id>
<activation>
<activeByDefault>true</activeByDefault>
@@ -363,9 +350,7 @@
<profile>
<id>cdi-tests</id>
<modules>
- <module>emma/lib</module>
<module>../cdi/tests</module>
- <module>emma/reports</module>
</modules>
</profile>
@@ -619,19 +604,6 @@
<module>../central</module>
</modules>
</profile>
-
- <profile>
- <id>aggregate-coverage</id>
- <activation>
- <activeByDefault>true</activeByDefault>
- <property>
- <name>coverage</name>
- </property>
- </activation>
- <modules>
- <module>emma/reports</module>
- </modules>
- </profile>
</profiles>
</project>
12 years, 2 months
JBoss Tools SVN: r44566 - in trunk/ws: plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation and 3 other directories.
by jbosstools-commits@lists.jboss.org
Author: xcoulon
Date: 2012-10-17 15:20:11 -0400 (Wed, 17 Oct 2012)
New Revision: 44566
Modified:
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsJavaElement.java
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsMetamodel.java
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsWebxmlApplication.java
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/AbstractJaxrsElementValidatorDelegate.java
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsJavaApplicationValidatorDelegate.java
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsMetamodelValidator.java
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/metamodel/IJaxrsElement.java
trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/builder/JavaElementDeltaFilterTestCase.java
trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsApplicationValidatorTestCase.java
trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsHttpMethodValidatorTestCase.java
Log:
Fixed - JBIDE-12885 - JAX-RS validator shouldn't care about binary classes
https://issues.jboss.org/browse/JBIDE-12885
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsJavaElement.java
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsJavaElement.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsJavaElement.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -100,6 +100,14 @@
}
}
+ @Override
+ public boolean isBinary() {
+ if(this.javaElement == null) {
+ return true;
+ }
+ return this.javaElement.isBinary();
+ }
+
public Annotation getAnnotation(String className) {
return annotations.get(className);
}
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsMetamodel.java
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsMetamodel.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsMetamodel.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -120,6 +120,12 @@
}
@Override
+ public boolean isBinary() {
+ // Metamodel is never binary
+ return false;
+ }
+
+ @Override
public EnumElementKind getElementKind() {
return EnumElementKind.METAMODEL;
}
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsWebxmlApplication.java
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsWebxmlApplication.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/domain/JaxrsWebxmlApplication.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -3,6 +3,8 @@
import static org.jboss.tools.ws.jaxrs.core.internal.metamodel.builder.JaxrsElementDelta.F_APPLICATION_PATH_VALUE;
import org.eclipse.core.resources.IResource;
+import org.eclipse.jdt.core.IJavaProject;
+import org.eclipse.jdt.core.IPackageFragmentRoot;
import org.jboss.tools.ws.jaxrs.core.jdt.EnumJaxrsClassname;
import org.jboss.tools.ws.jaxrs.core.metamodel.EnumElementCategory;
import org.jboss.tools.ws.jaxrs.core.metamodel.EnumElementKind;
@@ -28,6 +30,17 @@
this.javaClassName = applicationClassName;
}
+
+ @Override
+ public boolean isBinary() {
+ final IJavaProject javaProject = getMetamodel().getJavaProject();
+ IPackageFragmentRoot fragment = javaProject.getPackageFragmentRoot(webxmlResource);
+ if(fragment != null && fragment.exists() && fragment.isArchive()) {
+ return true;
+ }
+ return false;
+
+ }
/**
* @return true if the applicationClassName given in the constructor matches an existing Java Application in the
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/AbstractJaxrsElementValidatorDelegate.java
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/AbstractJaxrsElementValidatorDelegate.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/AbstractJaxrsElementValidatorDelegate.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -15,6 +15,7 @@
import org.eclipse.core.runtime.CoreException;
import org.jboss.tools.common.validation.TempMarkerManager;
import org.jboss.tools.ws.jaxrs.core.internal.utils.Logger;
+import org.jboss.tools.ws.jaxrs.core.metamodel.IJaxrsElement;
/**
* Abstract validator delegate with bits of generics for better readability in subclasses
@@ -22,7 +23,7 @@
* @author Xavier Coulon
*
*/
-public abstract class AbstractJaxrsElementValidatorDelegate<T extends Object> {
+public abstract class AbstractJaxrsElementValidatorDelegate<T extends IJaxrsElement> {
private final T element;
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsJavaApplicationValidatorDelegate.java
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsJavaApplicationValidatorDelegate.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsJavaApplicationValidatorDelegate.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -42,8 +42,11 @@
public void validate() throws CoreException {
final JaxrsJavaApplication application = getElement();
JaxrsMetamodelValidator.deleteJaxrsMarkers(application);
+ if(application.getJavaElement().isBinary()) {
+ Logger.debug("Skipping validation on binary element {}", getElement());
+ return;
+ }
Logger.debug("Validating element {}", getElement());
-
final Annotation applicationPathAnnotation = application
.getAnnotation(EnumJaxrsClassname.APPLICATION_PATH.qualifiedName);
final IType appJavaElement = application.getJavaElement();
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsMetamodelValidator.java
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsMetamodelValidator.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsMetamodelValidator.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -113,15 +113,13 @@
Logger.debug("*** Validating project {} after files {} changed... ***", project.getName(),
changedFiles.toString());
final JaxrsMetamodel jaxrsMetamodel = JaxrsMetamodelLocator.get(project);
- final Set<IResource> allResources = completeValidationSet(jaxrsMetamodel, changedFiles.toArray(new IFile[changedFiles.size()]));
- for (IResource changedResource : allResources) {
- validate(reporter, changedResource, jaxrsMetamodel);
+ if(jaxrsMetamodel != null) { // prevent failure in case validation would be called at workbench startup, even before metamodel is built.
+ final Set<IResource> allResources = completeValidationSet(jaxrsMetamodel, changedFiles.toArray(new IFile[changedFiles.size()]));
+ for (IResource changedResource : allResources) {
+ validate(reporter, changedResource, jaxrsMetamodel);
+ }
}
}
- // trigger a full validation instead
- else {
- //validateAll(project, validationHelper, context, manager, reporter);
- }
} catch (CoreException e) {
Logger.error("Failed to validate changed files " + changedFiles + " in project " + project, e);
} finally {
@@ -235,6 +233,10 @@
*/
@SuppressWarnings("incomplete-switch")
private void validate(IJaxrsElement element) throws CoreException {
+ // skip validation on binary JAX-RS elements (if metamodel contains any)
+ if(element.isBinary()) {
+ return;
+ }
switch (element.getElementCategory()) {
case METAMODEL:
new JaxrsMetamodelValidatorDelegate(this, (JaxrsMetamodel)element).validate();
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/metamodel/IJaxrsElement.java
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/metamodel/IJaxrsElement.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/metamodel/IJaxrsElement.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -28,6 +28,8 @@
public abstract IResource getResource();
public abstract String getName();
+
+ public abstract boolean isBinary();
}
Modified: trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/builder/JavaElementDeltaFilterTestCase.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/builder/JavaElementDeltaFilterTestCase.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/builder/JavaElementDeltaFilterTestCase.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -125,6 +125,7 @@
when(element.getResource()).thenReturn(resource);
when(element.isArchive()).thenReturn(true);
when(resource.getType()).thenReturn(IResource.FILE);
+ when(resource.getName()).thenReturn("somearchive.jar");
assertFalse("Wrong result", filter.apply(createEvent(element, ADDED, POST_RECONCILE, NO_FLAG)));
assertFalse("Wrong result", filter.apply(createEvent(element, ADDED, POST_CHANGE, NO_FLAG)));
assertFalse("Wrong result", filter.apply(createEvent(element, CHANGED, POST_RECONCILE, NO_FLAG)));
Modified: trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsApplicationValidatorTestCase.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsApplicationValidatorTestCase.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsApplicationValidatorTestCase.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -12,6 +12,13 @@
import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.hasSize;
+import static org.jboss.tools.ws.jaxrs.core.internal.metamodel.validation.MarkerUtils.deleteJaxrsMarkers;
+import static org.jboss.tools.ws.jaxrs.core.internal.metamodel.validation.MarkerUtils.findJaxrsMarkers;
+import static org.jboss.tools.ws.jaxrs.core.internal.metamodel.validation.MarkerUtils.hasPreferenceKey;
+import static org.jboss.tools.ws.jaxrs.core.preferences.JaxrsPreferences.APPLICATION_NO_OCCURRENCE_FOUND;
+import static org.jboss.tools.ws.jaxrs.core.preferences.JaxrsPreferences.APPLICATION_TOO_MANY_OCCURRENCES;
+import static org.jboss.tools.ws.jaxrs.core.preferences.JaxrsPreferences.JAVA_APPLICATION_INVALID_TYPE_HIERARCHY;
+import static org.jboss.tools.ws.jaxrs.core.preferences.JaxrsPreferences.JAVA_APPLICATION_MISSING_APPLICATION_PATH_ANNOTATION;
import static org.junit.Assert.assertThat;
import java.util.List;
@@ -40,11 +47,8 @@
import org.jboss.tools.ws.jaxrs.core.jdt.JdtUtils;
import org.jboss.tools.ws.jaxrs.core.metamodel.EnumElementKind;
import org.jboss.tools.ws.jaxrs.core.metamodel.IJaxrsApplication;
-import static org.jboss.tools.ws.jaxrs.core.preferences.JaxrsPreferences.*;
import org.junit.Test;
-import static org.jboss.tools.ws.jaxrs.core.internal.metamodel.validation.MarkerUtils.*;
-
/**
* @author Xi
*
@@ -88,7 +92,7 @@
final IMarker[] markers = findJaxrsMarkers(project);
assertThat(markers.length, equalTo(0));
}
-
+
@Test
public void shouldNotReportProblemIfOneWebxmlApplicationExists() throws CoreException, ValidationException {
// preconditions
Modified: trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsHttpMethodValidatorTestCase.java
===================================================================
--- trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsHttpMethodValidatorTestCase.java 2012-10-17 19:10:53 UTC (rev 44565)
+++ trunk/ws/tests/org.jboss.tools.ws.jaxrs.core.test/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsHttpMethodValidatorTestCase.java 2012-10-17 19:20:11 UTC (rev 44566)
@@ -42,8 +42,10 @@
import org.jboss.tools.ws.jaxrs.core.WorkbenchUtils;
import org.jboss.tools.ws.jaxrs.core.builder.AbstractMetamodelBuilderTestCase;
import org.jboss.tools.ws.jaxrs.core.internal.metamodel.domain.JaxrsBaseElement;
+import org.jboss.tools.ws.jaxrs.core.internal.metamodel.domain.JaxrsElementFactory;
import org.jboss.tools.ws.jaxrs.core.internal.metamodel.domain.JaxrsHttpMethod;
import org.jboss.tools.ws.jaxrs.core.jdt.Annotation;
+import org.jboss.tools.ws.jaxrs.core.jdt.JdtUtils;
import org.junit.Test;
/**
@@ -79,6 +81,21 @@
}
@Test
+ public void shouldSkipValidationOnBinaryHttpMethod() throws CoreException, ValidationException {
+ // preconditions: create an HttpMethod from the binary annotation, then try to validate
+ final IType getType = WorkbenchUtils.getType("javax.ws.rs.GET", javaProject);
+ final JaxrsHttpMethod httpMethod = new JaxrsElementFactory().createHttpMethod(getType, JdtUtils.parse(getType, null), metamodel);
+ metamodel.add(httpMethod);
+ assertThat(findJaxrsMarkers(httpMethod).length, equalTo(0));
+ deleteJaxrsMarkers(httpMethod);
+ // operation
+ new JaxrsMetamodelValidator().validate(toSet(httpMethod.getResource()), project, validationHelper, context,
+ validatorManager, reporter);
+ // validation
+ assertThat(findJaxrsMarkers(httpMethod).length, equalTo(0));
+ }
+
+ @Test
public void shouldReportProblemWhenHttpMethodVerbIsEmpty() throws CoreException, ValidationException {
// preconditions
final IType fooType = WorkbenchUtils.getType("org.jboss.tools.ws.jaxrs.sample.services.FOO", javaProject);
12 years, 2 months
JBoss Tools SVN: r44565 - trunk/documentation/whatsnew/jst.
by jbosstools-commits@lists.jboss.org
Author: akazakov
Date: 2012-10-17 15:10:53 -0400 (Wed, 17 Oct 2012)
New Revision: 44565
Modified:
trunk/documentation/whatsnew/jst/jst-news-4.0.0.Beta1.html
Log:
https://issues.jboss.org/browse/JBIDE-12874 JST/JSF Components N&N
Modified: trunk/documentation/whatsnew/jst/jst-news-4.0.0.Beta1.html
===================================================================
--- trunk/documentation/whatsnew/jst/jst-news-4.0.0.Beta1.html 2012-10-17 18:05:00 UTC (rev 44564)
+++ trunk/documentation/whatsnew/jst/jst-news-4.0.0.Beta1.html 2012-10-17 19:10:53 UTC (rev 44565)
@@ -39,12 +39,12 @@
</td>
<td align="top">
<p>
-
+ It's now possible to create JSF 2.1 project via New JSF Project Wizard.
</p>
<p><img src="images/4.0.0.Beta1/scrn.png" /></p>
<p>
<small>
- <a href="https://issues.jboss.org/browse/JBIDE-12866">Related Jira</a>
+ <a href="https://issues.jboss.org/browse/JBIDE-12781">Related Jira</a>
</small><br/>
</p>
</td>
12 years, 2 months
JBoss Tools SVN: r44564 - trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-10-17 14:05:00 -0400 (Wed, 17 Oct 2012)
New Revision: 44564
Modified:
trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java
Log:
JBIDE-12866
https://issues.jboss.org/browse/JBIDE-12866
SeamUiImages modified.
Modified: trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java 2012-10-17 17:53:54 UTC (rev 44563)
+++ trunk/seam/plugins/org.jboss.tools.seam.ui/src/org/jboss/tools/seam/ui/SeamUiImages.java 2012-10-17 18:05:00 UTC (rev 44564)
@@ -16,11 +16,11 @@
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jface.resource.ImageRegistry;
import org.eclipse.swt.graphics.Image;
-import org.jboss.tools.seam.core.SeamCoreMessages;
+import org.jboss.tools.common.ui.CommonUIImages;
-public class SeamUiImages {
-
+public class SeamUiImages extends CommonUIImages {
private static SeamUiImages INSTANCE;
static {
@@ -44,55 +44,30 @@
public static Image getImage(String key) {
- return INSTANCE.createImageDescriptor(key).createImage();
+ return INSTANCE.getOrCreateImage(key);
}
public static ImageDescriptor getImageDescriptor(String key) {
- return INSTANCE.createImageDescriptor(key);
+ return INSTANCE.getOrCreateImageDescriptor(key);
}
public static void setImageDescriptors(IAction action, String iconName) {
- action.setImageDescriptor(INSTANCE.createImageDescriptor(iconName));
+ action.setImageDescriptor(INSTANCE.getOrCreateImageDescriptor(iconName));
}
public static SeamUiImages getInstance() {
return INSTANCE;
}
- private URL baseUrl;
- private SeamUiImages parentRegistry;
-
protected SeamUiImages(URL registryUrl, SeamUiImages parent){
-
- if(registryUrl == null) throw new IllegalArgumentException(SeamCoreMessages.SEAM_UI_IMAGESBASE_URL_FOR_IMAGE_REGISTRY_CANNOT_BE_NULL);
- baseUrl = registryUrl;
- parentRegistry = parent;
+ super(registryUrl, parent);
}
protected SeamUiImages(URL url){
this(url,null);
}
- public Image getImageByFileName(String key) {
- return createImageDescriptor(key).createImage();
+ protected ImageRegistry getImageRegistry() {
+ return SeamGuiPlugin.getDefault().getImageRegistry();
}
-
- public ImageDescriptor createImageDescriptor(String key) {
- try {
- return ImageDescriptor.createFromURL(makeIconFileURL(key));
- } catch (MalformedURLException e) {
- if(parentRegistry == null) {
- return ImageDescriptor.getMissingImageDescriptor();
- } else {
- return parentRegistry.createImageDescriptor(key);
- }
-
- }
- }
-
- private URL makeIconFileURL(String name) throws MalformedURLException {
- if (name == null) throw new MalformedURLException(SeamCoreMessages.SEAM_UI_IMAGESIMAGE_NAME_CANNOT_BE_NULL);
- return new URL(baseUrl, name);
- }
-
}
12 years, 2 months
JBoss Tools SVN: r44563 - in trunk/cdi/plugins/org.jboss.tools.cdi.core: src/org/jboss/tools/cdi/core and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-10-17 13:53:54 -0400 (Wed, 17 Oct 2012)
New Revision: 44563
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/CDIImages.java
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/CDIProject.java
Log:
JBIDE-12866
https://issues.jboss.org/browse/JBIDE-12866
CDIImages modified.
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF 2012-10-17 17:52:07 UTC (rev 44562)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/META-INF/MANIFEST.MF 2012-10-17 17:53:54 UTC (rev 44563)
@@ -29,7 +29,7 @@
org.jboss.tools.common.validation,
org.jboss.tools.cdi.xml;visibility:=reexport,
org.eclipse.ui.ide;bundle-version="3.7.0",
- org.jboss.tools.common.ui
+ org.jboss.tools.common.ui;visibility:=reexport
Bundle-ActivationPolicy: lazy
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-Vendor: JBoss by Red Hat
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/CDIImages.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/CDIImages.java 2012-10-17 17:52:07 UTC (rev 44562)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/core/CDIImages.java 2012-10-17 17:53:54 UTC (rev 44563)
@@ -15,12 +15,13 @@
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jface.resource.ImageRegistry;
import org.eclipse.swt.graphics.Image;
import org.jboss.tools.cdi.internal.core.impl.EventBean;
import org.jboss.tools.cdi.xml.CDIXMLImages;
-import org.jboss.tools.common.ui.CommonUIPlugin;
+import org.jboss.tools.common.ui.CommonUIImages;
-public class CDIImages {
+public class CDIImages extends CommonUIImages {
private static CDIImages INSTANCE;
@@ -54,16 +55,12 @@
public static final String CDI_CLASS_IMAGE = "wizard/CDIClassWizBan.png"; //$NON-NLS-1$
public static final String CDI_ANNOTATION_IMAGE = "wizard/CDIAnnotationWizBan.png"; //$NON-NLS-1$
- public static Image getImage(ImageDescriptor descriptor) {
- return CommonUIPlugin.getImageDescriptorRegistry().get(descriptor);
- }
-
public static Image getImage(String key) {
- return INSTANCE.createImageDescriptor(key).createImage();
+ return getImageDescriptor(key).createImage();
}
public static ImageDescriptor getImageDescriptor(String key) {
- return INSTANCE.createImageDescriptor(key);
+ return getInstance().getOrCreateImageDescriptor(key);
}
public static void setImageDescriptors(IAction action, String iconName) {
@@ -74,40 +71,18 @@
return INSTANCE;
}
- private URL baseUrl;
- private CDIImages parentRegistry;
-
protected CDIImages(URL registryUrl, CDIImages parent){
- if(registryUrl == null) throw new IllegalArgumentException(CDICoreMessages.CDI_IMAGESBASE_URL_FOR_IMAGE_REGISTRY_CANNOT_BE_NULL);
- baseUrl = registryUrl;
- parentRegistry = parent;
+ super(registryUrl, parent);
}
protected CDIImages(URL url){
this(url,null);
}
- public Image getImageByFileName(String key) {
- return createImageDescriptor(key).createImage();
+ protected ImageRegistry getImageRegistry() {
+ return CDICorePlugin.getDefault().getImageRegistry();
}
- public ImageDescriptor createImageDescriptor(String key) {
- try {
- return ImageDescriptor.createFromURL(makeIconFileURL(key));
- } catch (MalformedURLException e) {
- if(parentRegistry == null) {
- return ImageDescriptor.getMissingImageDescriptor();
- } else {
- return parentRegistry.createImageDescriptor(key);
- }
- }
- }
-
- private URL makeIconFileURL(String name) throws MalformedURLException {
- if (name == null) throw new MalformedURLException(CDICoreMessages.CDI_IMAGESIMAGE_NAME_CANNOT_BE_NULL);
- return new URL(baseUrl, name);
- }
-
public static Image getImageByElement(ICDIElement element) {
return getImage(getImageDescriptorByElement(element));
}
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/CDIProject.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/CDIProject.java 2012-10-17 17:52:07 UTC (rev 44562)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/impl/CDIProject.java 2012-10-17 17:53:54 UTC (rev 44563)
@@ -92,7 +92,7 @@
BeansXMLData projectBeansXMLData = new BeansXMLData();
public CDIProject() {
- dbCache = CDICorePlugin.getDefault().getDBCache();
+// dbCache = CDICorePlugin.getDefault().getDBCache();
}
public CDIProject getModifiedCopy(IFile file, Collection<IBean> beans) {
12 years, 2 months
JBoss Tools SVN: r44562 - trunk/jsf/plugins/org.jboss.tools.jsf.ui/src/org/jboss/tools/jsf/ui.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-10-17 13:52:07 -0400 (Wed, 17 Oct 2012)
New Revision: 44562
Modified:
trunk/jsf/plugins/org.jboss.tools.jsf.ui/src/org/jboss/tools/jsf/ui/JsfUiImages.java
Log:
JBIDE-12866
https://issues.jboss.org/browse/JBIDE-12866
ModelUIImages modified.
Modified: trunk/jsf/plugins/org.jboss.tools.jsf.ui/src/org/jboss/tools/jsf/ui/JsfUiImages.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf.ui/src/org/jboss/tools/jsf/ui/JsfUiImages.java 2012-10-17 17:37:52 UTC (rev 44561)
+++ trunk/jsf/plugins/org.jboss.tools.jsf.ui/src/org/jboss/tools/jsf/ui/JsfUiImages.java 2012-10-17 17:52:07 UTC (rev 44562)
@@ -41,10 +41,7 @@
}
public static ImageDescriptor getImageDescriptor(String key) {
- if(JsfUiPlugin.isDebugEnabled()) {
- JsfUiPlugin.getPluginLog().logInfo("Create imageDescriptor for key '" + key + "'."); //$NON-NLS-1$ //$NON-NLS-2$
- }
- return INSTANCE.createImageDescriptor(key);
+ return INSTANCE.getOrCreateImageDescriptor(key);
}
/**
12 years, 2 months
JBoss Tools SVN: r44561 - in trunk/common/plugins/org.jboss.tools.common.model.ui: src/org/jboss/tools/common/model/ui and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2012-10-17 13:37:52 -0400 (Wed, 17 Oct 2012)
New Revision: 44561
Modified:
trunk/common/plugins/org.jboss.tools.common.model.ui/META-INF/MANIFEST.MF
trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java
Log:
JBIDE-12866
https://issues.jboss.org/browse/JBIDE-12866
ModelUIImages modified.
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/META-INF/MANIFEST.MF
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/META-INF/MANIFEST.MF 2012-10-17 17:26:08 UTC (rev 44560)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/META-INF/MANIFEST.MF 2012-10-17 17:37:52 UTC (rev 44561)
@@ -90,7 +90,7 @@
org.eclipse.wst.html.core;bundle-version="1.1.500",
org.eclipse.pde.ui;bundle-version="3.6.100",
org.eclipse.core.expressions;bundle-version="3.4.200",
- org.jboss.tools.common.ui,
+ org.jboss.tools.common.ui;visibility:=reexport,
org.eclipse.jst.standard.schemas;bundle-version="1.2.0",
org.eclipse.wst.standard.schemas;bundle-version="1.0.300"
Bundle-Version: 3.4.0.qualifier
Modified: trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java 2012-10-17 17:26:08 UTC (rev 44560)
+++ trunk/common/plugins/org.jboss.tools.common.model.ui/src/org/jboss/tools/common/model/ui/ModelUIImages.java 2012-10-17 17:37:52 UTC (rev 44561)
@@ -17,13 +17,9 @@
import org.eclipse.jface.resource.ImageDescriptor;
import org.eclipse.jface.resource.ImageRegistry;
import org.eclipse.swt.graphics.Image;
+import org.jboss.tools.common.ui.CommonUIImages;
-public class ModelUIImages {
-// private URL imageBaseURL = null;
-// private static String PREFIX_ICON_ENABLED = "";
-// private static String PREFIX_ICON_DISABLED = "d";
-// private static String PREFIX_ICON_HOVER = "h";
-
+public class ModelUIImages extends CommonUIImages {
private static String ACTIONS_PATH = "wizards/"; //$NON-NLS-1$
public static String ACT_CREATE_PROJECT = ACTIONS_PATH + "new_project.gif"; //$NON-NLS-1$
@@ -44,7 +40,6 @@
public static String TAGLIB_ATTRIBUTE = "editors/taglibs_attribute.gif"; //$NON-NLS-1$
- // this blok staye witout changes for compatibility
private static ModelUIImages INSTANCE;
static {
@@ -57,76 +52,30 @@
}
public static Image getImage(String key) {
- getImageDescriptor(key); // provide image in the registry
- ImageRegistry registry = ModelUIPlugin.getDefault().getImageRegistry();
- synchronized(registry) {
- return registry.get(key);
- }
+ return getInstance().getOrCreateImage(key);
}
public static ImageDescriptor getImageDescriptor(String key) {
- ImageDescriptor result = null;
- ImageRegistry registry = ModelUIPlugin.getDefault().getImageRegistry();
- synchronized(registry) {
- result = registry.getDescriptor(key);
- }
- if(result == null) {
- result = INSTANCE.createImageDescriptor(key);
- if(result != null) {
- synchronized (registry) {
- registry.remove(key);
- registry.put(key, result);
- }
- }
- }
- return result;
+ return getInstance().getOrCreateImageDescriptor(key);
}
public static void setImageDescriptors(IAction action, String iconName) {
- action.setImageDescriptor(INSTANCE.createImageDescriptor(iconName));
+ action.setImageDescriptor(getImageDescriptor(iconName));
}
public static ModelUIImages getInstance() {
return INSTANCE;
}
- // for reusable purposes
-
- private URL baseUrl;
- private ModelUIImages parentRegistry;
-
protected ModelUIImages(URL registryUrl, ModelUIImages parent){
- if(ModelUIPlugin.isDebugEnabled()) {
- ModelUIPlugin.getPluginLog().logInfo("Create ModelUIImages class."); //$NON-NLS-1$
- ModelUIPlugin.getPluginLog().logInfo("RegistryUrl = " + registryUrl); //$NON-NLS-1$
- ModelUIPlugin.getPluginLog().logInfo("parent = " + (parent==null?"null":parent.getClass().getName())); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- if(registryUrl == null) throw new IllegalArgumentException("Base url for image registry cannot be null."); //$NON-NLS-1$
- baseUrl = registryUrl;
- parentRegistry = parent;
+ super(registryUrl, parent);
}
protected ModelUIImages(URL url){
this(url,null);
}
- public ImageDescriptor createImageDescriptor(String key) {
- try {
- return ImageDescriptor.createFromURL(makeIconFileURL(key));
- } catch (MalformedURLException e) {
- if(parentRegistry == null) {
- return ImageDescriptor.getMissingImageDescriptor();
- } else {
- return parentRegistry.createImageDescriptor(key);
- }
-
- }
+ protected ImageRegistry getImageRegistry() {
+ return ModelUIPlugin.getDefault().getImageRegistry();
}
-
- private URL makeIconFileURL(String name) throws MalformedURLException {
- if (name == null) throw new MalformedURLException("Image name cannot be null.");
- return new URL(baseUrl, name);
- }
-
}
12 years, 2 months