JBoss Tools SVN: r31752 - trunk/modeshape/plugins/org.jboss.tools.modeshape.rest.
by jbosstools-commits@lists.jboss.org
Author: elvisisking
Date: 2011-06-01 17:14:23 -0400 (Wed, 01 Jun 2011)
New Revision: 31752
Modified:
trunk/modeshape/plugins/org.jboss.tools.modeshape.rest/feature.png
Log:
JBIDE-9056 ModeShape Tools About Image Should Be Updated To Current ModeShape Brand Image. Updated the about image.
Modified: trunk/modeshape/plugins/org.jboss.tools.modeshape.rest/feature.png
===================================================================
(Binary files differ)
13 years, 6 months
JBoss Tools SVN: r31751 - in trunk/jst/plugins/org.jboss.tools.jst.web.kb: src/org/jboss/tools/jst/web/kb/internal/validation and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-06-01 16:51:12 -0400 (Wed, 01 Jun 2011)
New Revision: 31751
Modified:
trunk/jst/plugins/org.jboss.tools.jst.web.kb/plugin.xml
trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/internal/validation/ValidatorManager.java
Log:
JBIDE-9028
https://issues.jboss.org/browse/JBIDE-9028
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.kb/plugin.xml
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.kb/plugin.xml 2011-06-01 20:50:27 UTC (rev 31750)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.kb/plugin.xml 2011-06-01 20:51:12 UTC (rev 31751)
@@ -140,7 +140,7 @@
</super>
<persistent value="true">
</persistent>
- <attribute name="validator">
+ <attribute name="builder">
</attribute>
</extension>
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/internal/validation/ValidatorManager.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/internal/validation/ValidatorManager.java 2011-06-01 20:50:27 UTC (rev 31750)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/internal/validation/ValidatorManager.java 2011-06-01 20:51:12 UTC (rev 31751)
@@ -112,7 +112,7 @@
}
public static final String ORDER_PROBLEM_MARKER_TYPE = "org.jboss.tools.jst.web.kb.builderOrderProblem"; //$NON-NLS-1$
- private static String ATTR_VALIDATOR = "validator"; //$NON-NLS-1$
+ private static String ATTR_BUILDER = "builder"; //$NON-NLS-1$
/**
* Helper method to be called by IValidator implementations.
@@ -132,7 +132,7 @@
public static boolean validateBuilderOrder(IProject project, String builderId, String validatorId, SeverityPreferences preferences) throws CoreException {
int severity = getSeverity(preferences.getBuilderOrderPreference(project));
boolean isCorrect = isCorrectOrder(project, builderId);
- IMarker marker = findBuilderOrderMarker(project, validatorId);
+ IMarker marker = findBuilderOrderMarker(project, builderId);
if(isCorrect || severity <= IMarker.SEVERITY_INFO) {
if(marker != null) {
ResourcesPlugin.getWorkspace().deleteMarkers(new IMarker[]{marker});
@@ -144,7 +144,7 @@
}
} else {
marker = project.createMarker(ORDER_PROBLEM_MARKER_TYPE);
- marker.setAttribute(ATTR_VALIDATOR, validatorId);
+ marker.setAttribute(ATTR_BUILDER, builderId);
marker.setAttribute(IMarker.SEVERITY, severity);
String message = NLS.bind(KbMessages.WRONG_BUILDER_ORDER, project.getName(), findBuilderName(builderId));
marker.setAttribute(IMarker.MESSAGE, message);
@@ -167,11 +167,11 @@
return true;
}
- private static IMarker findBuilderOrderMarker(IProject project, String validator) throws CoreException {
+ private static IMarker findBuilderOrderMarker(IProject project, String builderId) throws CoreException {
IMarker result = null;
IMarker[] ms = project.findMarkers(ORDER_PROBLEM_MARKER_TYPE, false, IResource.DEPTH_ZERO);
for (IMarker m: ms) {
- if(validator.equals(m.getAttribute(ATTR_VALIDATOR, null))) {
+ if(builderId.equals(m.getAttribute(ATTR_BUILDER, null))) {
result = m;
}
}
13 years, 6 months
JBoss Tools SVN: r31750 - trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-06-01 16:50:27 -0400 (Wed, 01 Jun 2011)
New Revision: 31750
Modified:
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java
Log:
JBIDE-9028
https://issues.jboss.org/browse/JBIDE-9028
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java 2011-06-01 20:46:27 UTC (rev 31749)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java 2011-06-01 20:50:27 UTC (rev 31750)
@@ -14,12 +14,12 @@
import org.eclipse.core.runtime.CoreException;
import org.jboss.tools.jst.web.kb.internal.validation.ELValidator;
import org.jboss.tools.jst.web.kb.internal.validation.ValidatorManager;
+import org.jboss.tools.jst.web.kb.preferences.ELSeverityPreferences;
import org.jboss.tools.jst.web.kb.validation.IELValidationDelegate;
import org.jboss.tools.jst.web.kb.validation.IValidatingProjectTree;
import org.jboss.tools.seam.core.ISeamProject;
import org.jboss.tools.seam.core.SeamCoreBuilder;
import org.jboss.tools.seam.core.SeamCorePlugin;
-import org.jboss.tools.seam.core.SeamPreferences;
/**
* @author Alexey Kazakov
@@ -49,7 +49,8 @@
}
private boolean validateBuilderOrder(IProject project) throws CoreException {
- return ValidatorManager.validateBuilderOrder(project, getBuilderId(), ELValidator.ID + "-Seam", SeamPreferences.getInstance());
+ //It's EL, hence EL preferences, not Seam preferences.
+ return ValidatorManager.validateBuilderOrder(project, getBuilderId(), ELValidator.ID + "-Seam", ELSeverityPreferences.getInstance());
}
public String getBuilderId() {
13 years, 6 months
JBoss Tools SVN: r31749 - trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-06-01 16:46:27 -0400 (Wed, 01 Jun 2011)
New Revision: 31749
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java
Log:
JBIDE-9028
https://issues.jboss.org/browse/JBIDE-9028
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java 2011-06-01 20:28:09 UTC (rev 31748)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java 2011-06-01 20:46:27 UTC (rev 31749)
@@ -15,9 +15,9 @@
import org.jboss.tools.cdi.core.CDICoreBuilder;
import org.jboss.tools.cdi.core.CDICoreNature;
import org.jboss.tools.cdi.core.CDICorePlugin;
-import org.jboss.tools.cdi.core.preferences.CDIPreferences;
import org.jboss.tools.jst.web.kb.internal.validation.ELValidator;
import org.jboss.tools.jst.web.kb.internal.validation.ValidatorManager;
+import org.jboss.tools.jst.web.kb.preferences.ELSeverityPreferences;
import org.jboss.tools.jst.web.kb.validation.IELValidationDelegate;
import org.jboss.tools.jst.web.kb.validation.IValidatingProjectTree;
@@ -49,7 +49,8 @@
}
private boolean validateBuilderOrder(IProject project) throws CoreException {
- return ValidatorManager.validateBuilderOrder(project, getBuilderId(), ELValidator.ID + "-CDI", CDIPreferences.getInstance());
+ //It's EL, hence EL preferences, not CDI preferences.
+ return ValidatorManager.validateBuilderOrder(project, getBuilderId(), ELValidator.ID + "-CDI", ELSeverityPreferences.getInstance());
}
public String getBuilderId() {
13 years, 6 months
JBoss Tools SVN: r31748 - trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-06-01 16:28:09 -0400 (Wed, 01 Jun 2011)
New Revision: 31748
Modified:
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java
Log:
JBIDE-9028
https://issues.jboss.org/browse/JBIDE-9028
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java 2011-06-01 20:27:51 UTC (rev 31747)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamELValidationDelegate.java 2011-06-01 20:28:09 UTC (rev 31748)
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2010 Red Hat, Inc.
+ * Copyright (c) 2010-2011 Red Hat, Inc.
* Distributed under license by Red Hat, Inc. All rights reserved.
* This program is made available under the terms of the
* Eclipse Public License v1.0 which accompanies this distribution,
@@ -12,10 +12,14 @@
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.CoreException;
+import org.jboss.tools.jst.web.kb.internal.validation.ELValidator;
+import org.jboss.tools.jst.web.kb.internal.validation.ValidatorManager;
import org.jboss.tools.jst.web.kb.validation.IELValidationDelegate;
import org.jboss.tools.jst.web.kb.validation.IValidatingProjectTree;
import org.jboss.tools.seam.core.ISeamProject;
+import org.jboss.tools.seam.core.SeamCoreBuilder;
import org.jboss.tools.seam.core.SeamCorePlugin;
+import org.jboss.tools.seam.core.SeamPreferences;
/**
* @author Alexey Kazakov
@@ -34,10 +38,22 @@
*/
public boolean shouldValidate(IProject project) {
try {
- return project!=null && project.isAccessible() && project.hasNature(ISeamProject.NATURE_ID);
+ return project != null
+ && project.isAccessible()
+ && project.hasNature(ISeamProject.NATURE_ID)
+ && validateBuilderOrder(project);
} catch (CoreException e) {
SeamCorePlugin.getDefault().logError(e);
}
return false;
}
+
+ private boolean validateBuilderOrder(IProject project) throws CoreException {
+ return ValidatorManager.validateBuilderOrder(project, getBuilderId(), ELValidator.ID + "-Seam", SeamPreferences.getInstance());
+ }
+
+ public String getBuilderId() {
+ return SeamCoreBuilder.BUILDER_ID;
+ }
+
}
\ No newline at end of file
13 years, 6 months
JBoss Tools SVN: r31747 - trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2011-06-01 16:27:51 -0400 (Wed, 01 Jun 2011)
New Revision: 31747
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java
Log:
JBIDE-9028
https://issues.jboss.org/browse/JBIDE-9028
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java 2011-06-01 20:06:28 UTC (rev 31746)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDIELValidationDelegate.java 2011-06-01 20:27:51 UTC (rev 31747)
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2010 Red Hat, Inc.
+ * Copyright (c) 2010-2011 Red Hat, Inc.
* Distributed under license by Red Hat, Inc. All rights reserved.
* This program is made available under the terms of the
* Eclipse Public License v1.0 which accompanies this distribution,
@@ -12,8 +12,12 @@
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.CoreException;
+import org.jboss.tools.cdi.core.CDICoreBuilder;
import org.jboss.tools.cdi.core.CDICoreNature;
import org.jboss.tools.cdi.core.CDICorePlugin;
+import org.jboss.tools.cdi.core.preferences.CDIPreferences;
+import org.jboss.tools.jst.web.kb.internal.validation.ELValidator;
+import org.jboss.tools.jst.web.kb.internal.validation.ValidatorManager;
import org.jboss.tools.jst.web.kb.validation.IELValidationDelegate;
import org.jboss.tools.jst.web.kb.validation.IValidatingProjectTree;
@@ -34,10 +38,22 @@
*/
public boolean shouldValidate(IProject project) {
try {
- return project != null && project.isAccessible() && project.hasNature(CDICoreNature.NATURE_ID);
+ return project != null
+ && project.isAccessible()
+ && project.hasNature(CDICoreNature.NATURE_ID)
+ && validateBuilderOrder(project);
} catch (CoreException e) {
CDICorePlugin.getDefault().logError(e);
}
return false;
}
+
+ private boolean validateBuilderOrder(IProject project) throws CoreException {
+ return ValidatorManager.validateBuilderOrder(project, getBuilderId(), ELValidator.ID + "-CDI", CDIPreferences.getInstance());
+ }
+
+ public String getBuilderId() {
+ return CDICoreBuilder.BUILDER_ID;
+ }
+
}
\ No newline at end of file
13 years, 6 months
JBoss Tools SVN: r31746 - trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2011-06-01 16:06:28 -0400 (Wed, 01 Jun 2011)
New Revision: 31746
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DeployableServerBehavior.java
Log:
[JBIDE-9054] changed the statements (no functional change!) so that the variable that is checked is always to the left -> far better readability
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DeployableServerBehavior.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DeployableServerBehavior.java 2011-06-01 19:52:23 UTC (rev 31745)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/DeployableServerBehavior.java 2011-06-01 20:06:28 UTC (rev 31746)
@@ -102,13 +102,17 @@
}
public int getPublishType(int kind, int deltaKind, int modulePublishState) {
- if( ServerBehaviourDelegate.ADDED == deltaKind )
+ if( deltaKind == ServerBehaviourDelegate.ADDED )
return IJBossServerPublisher.FULL_PUBLISH;
- if (ServerBehaviourDelegate.REMOVED == deltaKind) {
+ else if (deltaKind == ServerBehaviourDelegate.REMOVED) {
return IJBossServerPublisher.REMOVE_PUBLISH;
- } else if (kind == IServer.PUBLISH_FULL || modulePublishState == IServer.PUBLISH_STATE_FULL || kind == IServer.PUBLISH_CLEAN ) {
+ } else if (kind == IServer.PUBLISH_FULL
+ || modulePublishState == IServer.PUBLISH_STATE_FULL
+ || kind == IServer.PUBLISH_CLEAN ) {
return IJBossServerPublisher.FULL_PUBLISH;
- } else if (kind == IServer.PUBLISH_INCREMENTAL || modulePublishState == IServer.PUBLISH_STATE_INCREMENTAL || kind == IServer.PUBLISH_AUTO) {
+ } else if (kind == IServer.PUBLISH_INCREMENTAL
+ || modulePublishState == IServer.PUBLISH_STATE_INCREMENTAL
+ || kind == IServer.PUBLISH_AUTO) {
if( ServerBehaviourDelegate.CHANGED == deltaKind )
return IJBossServerPublisher.INCREMENTAL_PUBLISH;
}
13 years, 6 months
JBoss Tools SVN: r31745 - trunk/download.jboss.org/jbosstools/examples.
by jbosstools-commits@lists.jboss.org
Author: bfitzpat
Date: 2011-06-01 15:52:23 -0400 (Wed, 01 Jun 2011)
New Revision: 31745
Modified:
trunk/download.jboss.org/jbosstools/examples/project-examples-community-3...
Log:
JBDS-1670 - Fixing SOA-P 5 ESB examples to also run on AS 5.1
Modified: trunk/download.jboss.org/jbosstools/examples/project-examples-community-3...
===================================================================
--- trunk/download.jboss.org/jbosstools/examples/project-examples-community-3... 2011-06-01 19:38:22 UTC (rev 31744)
+++ trunk/download.jboss.org/jbosstools/examples/project-examples-community-3... 2011-06-01 19:52:23 UTC (rev 31745)
@@ -573,7 +573,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">helloworld,helloworld_testclient</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -596,7 +596,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">helloworld_action</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -621,7 +621,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">helloworld_mail</property>
<property name="required-components">esb</property>
<property name="description">This project example requires a JBoss SOA-P 5.0 runtime named "jboss-soa-p.5.0 Runtime"</property>
@@ -644,7 +644,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">helloworld_file_action</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -668,7 +668,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">webservice_consumer1</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -691,7 +691,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">webservice_producer</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -716,7 +716,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">transform_CSV2XML</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -739,7 +739,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">transform_XML2POJO</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -769,7 +769,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">transform_XML2XML_date_manipulation</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
@@ -792,7 +792,7 @@
</url>
<fixes>
<fix type="wtpruntime">
- <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50</property>
+ <property name="allowed-types">org.jboss.ide.eclipse.as.runtime.eap.50, org.jboss.ide.eclipse.as.runtime.51</property>
<property name="eclipse-projects">transform_XML2XML_simple</property>
<property name="required-components">esb</property>
<property name="description">This project example requires the JBoss SOA-P 5.0 and the runtime name should be "jboss-soa-p.5.0 Runtime"</property>
13 years, 6 months
JBoss Tools SVN: r31744 - trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2011-06-01 15:38:22 -0400 (Wed, 01 Jun 2011)
New Revision: 31744
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/DeploymentMarkerUtils.java
Log:
[JBIDE-8920] added javadoc
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/DeploymentMarkerUtils.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/DeploymentMarkerUtils.java 2011-06-01 19:35:42 UTC (rev 31743)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/DeploymentMarkerUtils.java 2011-06-01 19:38:22 UTC (rev 31744)
@@ -7,7 +7,7 @@
*
* Contributors:
* Red Hat, Inc. - initial API and implementation
- ******************************************************************************/
+ ******************************************************************************/
package org.jboss.ide.eclipse.as.core.server.internal.v7;
import java.io.File;
@@ -36,7 +36,8 @@
/**
*
* @author André Dietisheim
- *
+ * @author Rob Stryker
+ *
*/
public class DeploymentMarkerUtils {
@@ -49,89 +50,173 @@
public static final String SKIP_DEPLOY = ".skipdeploy";//$NON-NLS-1$
public static final String PENDING = ".pending";//$NON-NLS-1$
- public static IStatus addDeployMarker(IJBossServerPublishMethod method,IDeployableServer server,
- IModule[] moduleTree, IProgressMonitor monitor ) throws CoreException {
+ /**
+ * Adds a marker to the given deployment artifact (in form of a module tree) that
+ * instructs the server to deploy it. (.dodeploy)
+ *
+ * @param method the method to use to add the marker
+ * @param server the server that the marker shall be added to
+ * @param moduleTree the deployment(-tree)
+ * @param monitor the monitor to use to give progress feedback
+ * @return the result of the marker addition operation
+ * @throws CoreException
+ */
+ public static IStatus addDeployMarker(IJBossServerPublishMethod method, IDeployableServer server,
+ IModule[] moduleTree, IProgressMonitor monitor) throws CoreException {
IPath depPath = PublishUtil.getDeployPath(method, moduleTree, server);
return addDeployMarker(method, server.getServer(), depPath, monitor);
}
- public static IStatus addDeployMarker(IJBossServerPublishMethod method,IServer server,
- IPath depPath, IProgressMonitor monitor ) throws CoreException {
+ /**
+ * Adds a marker to the given deployment (in form of a path) that
+ * instructs the server to deploy the given artifact. (.dodeploy)
+ *
+ * @param method the method to use to add the marker
+ * @param server the server that the marker shall be added to
+ * @param depPath the path of the deployment artifact
+ * @param monitor the monitor to use to give progress feedback
+ * @return the result of the marker addition operation
+ * @throws CoreException
+ */
+ public static IStatus addDeployMarker(IJBossServerPublishMethod method, IServer server,
+ IPath depPath, IProgressMonitor monitor) throws CoreException {
IPath folder = depPath.removeLastSegments(1);
IPublishCopyCallbackHandler callback = method.getCallbackHandler(folder, server);
callback.copyFile(createBlankModule(), new Path(depPath.lastSegment() + DO_DEPLOY), monitor);
return Status.OK_STATUS;
}
-
+
private static IModuleFile createBlankModule() {
- return new ModuleFile(getBlankFile(), "", new Path("/")); //$NON-NLS-1$ //$NON-NLS-2$
+ return new ModuleFile(getOrCreateBlankFile(), "", new Path("/")); //$NON-NLS-1$ //$NON-NLS-2$
}
-
- private static File getBlankFile() {
+
+ private static File getOrCreateBlankFile() {
IPath p = JBossServerCorePlugin.getDefault().getStateLocation().append("BLANK_FILE"); //$NON-NLS-1$
- if( !p.toFile().exists()) {
+ if (!p.toFile().exists()) {
try {
OutputStream out = new FileOutputStream(p.toFile());
if (out != null) {
out.close();
}
- } catch(IOException ioe) {}
+ } catch (IOException ioe) {
+ // TODO: implement error handling
+ }
}
return p.toFile();
}
-
+
public static IStatus removeDeployFailedMarker(IServer server, IPath depPath, IJBossServerPublishMethod method,
IProgressMonitor monitor) throws CoreException {
return removeFile(FAILED_DEPLOY, server, depPath, method, monitor);
}
- private static IStatus removeFile(String suffix,IServer server, IPath depPath,IJBossServerPublishMethod method,
- IProgressMonitor monitor) throws CoreException {
- IPath folder = depPath.removeLastSegments(1);
- IPublishCopyCallbackHandler callback = method.getCallbackHandler(folder, server);
- IPath file = new Path(depPath.lastSegment()+suffix);
- callback.deleteResource(file, monitor);
- return Status.OK_STATUS;
- }
-
- public static IStatus removeDeployedMarkerIfExists(IJBossServerPublishMethod method, IServer server, IModule[] module, IProgressMonitor monitor)
- throws CoreException {
+ /**
+ * Removes the marker that indicates that the given deployment (in form of a module tree)
+ * was deployed (.deployed). Does nothing if the marker does not exist.
+ *
+ * @param method the method to use to manipulate the files on the server
+ * @param server the server to manipulate
+ * @param moduleTree the deployment (in form of a module tree)
+ * @param monitor the monitor to use when giving progress feedback
+ * @return the result of the removal operation
+ * @throws CoreException
+ */
+ public static IStatus removeDeployedMarkerIfExists(IJBossServerPublishMethod method, IServer server,
+ IModule[] module, IProgressMonitor monitor) throws CoreException {
IDeployableServer deployableServer = ServerConverter.getDeployableServer(server);
IPath deployPath = PublishUtil.getDeployPath(method, module, deployableServer);
return removeDeployedMarkerIfExists(server, deployPath, method, monitor);
}
- public static IStatus removeDeployedMarkerIfExists(IJBossServerPublishMethod method, IDeployableServer jbServer, IModule[] module, IProgressMonitor monitor)
+ /**
+ * Removes the marker that indicates that the given deployment (in form of a module tree)
+ * was deployed (.deployed). Does nothing if the marker does not exist.
+ *
+ * @param method the method to use to manipulate the files on the server
+ * @param jbServer the server to manipulate
+ * @param moduleTree the deployment (in form of a module tree)
+ * @param monitor the monitor to use when giving progress feedback
+ * @return the result of the removal operation
+ * @throws CoreException
+ */
+ public static IStatus removeDeployedMarkerIfExists(IJBossServerPublishMethod method, IDeployableServer jbServer,
+ IModule[] moduleTree, IProgressMonitor monitor)
throws CoreException {
- IPath deployPath = PublishUtil.getDeployPath(method, module, jbServer);
+ IPath deployPath = PublishUtil.getDeployPath(method, moduleTree, jbServer);
return removeDeployedMarkerIfExists(jbServer.getServer(), deployPath, method, monitor);
}
- public static IStatus removeDeployFailedMarkerIfExists(IJBossServerPublishMethod method, IServer server, IModule[] module,
+ /**
+ * Removes the marker that indicates that the given deployment (in form of a artifact path)
+ * was deployed (.deployed). Does nothing if the marker does not exist.
+ *
+ * @param server the server to remove the marker from
+ * @param method the method to use to manipulate the marker on the server
+ * @param depPath the path of the artifact to remove the marker of
+ * @param monitor the monitor to use when giving progress feedback
+ * @return the result of the removal operation
+ * @throws CoreException
+ */
+ public static IStatus removeDeployedMarkerIfExists(IServer server, IPath depPath, IJBossServerPublishMethod method,
IProgressMonitor monitor) throws CoreException {
+ try {
+ return removeFile(DEPLOYED, server, depPath, method, monitor);
+ } catch (Exception e) {
+ return Status.OK_STATUS;
+ }
+ }
+
+ /**
+ * Removes the marker that indicates that the given deployment (in form of a module tree)
+ * could not be deployed (.failed). Does nothing if the marker does not exist.
+ *
+ * @param method the method to use to manipulate the files on the server
+ * @param server the server to manipulate
+ * @param moduleTree the deployment (in form of a module tree)
+ * @param monitor the monitor to use when giving progress feedback
+ * @return the result of the removal operation
+ * @throws CoreException
+ */
+ public static IStatus removeDeployFailedMarkerIfExists(IJBossServerPublishMethod method, IServer server,
+ IModule[] module, IProgressMonitor monitor) throws CoreException {
IDeployableServer deployableServer = ServerConverter.getDeployableServer(server);
return removeDeployedMarkerIfExists(method, deployableServer, module, monitor);
- }
+ }
- public static IStatus removeDeployFailedMarkerIfExists(IJBossServerPublishMethod method, IDeployableServer jbServer, IModule[] module,
- IProgressMonitor monitor) throws CoreException {
+ /**
+ * Removes the marker that indicates that the given deployment (in form of a module tree)
+ * could not be deployed (.failed). Does nothing if the marker does not exist.
+ *
+ * @param method the method to use to manipulate the files on the server
+ * @param jbServer the server to manipulate
+ * @param moduleTree the deployment (in form of a module tree)
+ * @param monitor the monitor to use when giving progress feedback
+ * @return the result of the removal operation
+ * @throws CoreException
+ */
+ public static IStatus removeDeployFailedMarkerIfExists(IJBossServerPublishMethod method,
+ IDeployableServer jbServer, IModule[] module, IProgressMonitor monitor) throws CoreException {
IPath depPath = PublishUtil.getDeployPath(method, module, jbServer);
return removeDeployedMarkerIfExists(jbServer.getServer(), depPath, method, monitor);
}
- public static IStatus removeDeployedMarkerIfExists(IServer server, IPath depPath, IJBossServerPublishMethod method, IProgressMonitor monitor)
- throws CoreException {
- try {
- return removeFile(DEPLOYED, server, depPath, method, monitor);
- } catch(Exception e) {
- return Status.OK_STATUS;
- }
- }
-
+ /**
+ * Returns <code>true</code> if the given server supports the marker deployment method introduced in JBoss AS7.
+ *
+ * @param the server to query
+ * @return <code>true</code> if the server supports this deployment method
+ */
public static boolean supportsJBoss7MarkerDeployment(IServer server) {
- boolean retval = (server.loadAdapter(IJBoss7Deployment.class, new NullProgressMonitor()) != null);
- return retval;
+ return server.loadAdapter(IJBoss7Deployment.class, new NullProgressMonitor()) != null;
}
+ private static IStatus removeFile(String suffix, IServer server, IPath depPath, IJBossServerPublishMethod method,
+ IProgressMonitor monitor) throws CoreException {
+ IPath folder = depPath.removeLastSegments(1);
+ IPublishCopyCallbackHandler callback = method.getCallbackHandler(folder, server);
+ IPath file = new Path(depPath.lastSegment() + suffix);
+ callback.deleteResource(file, monitor);
+ return Status.OK_STATUS;
+ }
}
13 years, 6 months
JBoss Tools SVN: r31743 - trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink.
by jbosstools-commits@lists.jboss.org
Author: dazarov
Date: 2011-06-01 15:35:42 -0400 (Wed, 01 Jun 2011)
New Revision: 31743
Modified:
trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagNameHyperlinkDetector.java
Log:
https://issues.jboss.org/browse/JBIDE-9045
Modified: trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagNameHyperlinkDetector.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagNameHyperlinkDetector.java 2011-06-01 18:51:38 UTC (rev 31742)
+++ trunk/jsf/plugins/org.jboss.tools.jsf.text.ext/src/org/jboss/tools/jsf/text/ext/hyperlink/JsfJSPTagNameHyperlinkDetector.java 2011-06-01 19:35:42 UTC (rev 31743)
@@ -11,6 +11,8 @@
package org.jboss.tools.jsf.text.ext.hyperlink;
import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
import org.eclipse.core.resources.IFile;
import org.eclipse.jface.text.IDocument;
@@ -36,10 +38,10 @@
import org.jboss.tools.jst.web.kb.PageProcessor;
import org.jboss.tools.jst.web.kb.internal.taglib.AbstractAttribute;
import org.jboss.tools.jst.web.kb.internal.taglib.AbstractComponent;
-import org.jboss.tools.jst.web.kb.internal.taglib.FaceletTag;
import org.jboss.tools.jst.web.kb.internal.taglib.TLDTag;
import org.jboss.tools.jst.web.kb.taglib.IAttribute;
import org.jboss.tools.jst.web.kb.taglib.IComponent;
+import org.jboss.tools.jst.web.kb.taglib.INameSpace;
import org.w3c.dom.Attr;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
@@ -77,7 +79,10 @@
int i = tagName.indexOf(":");
KbQuery query = new KbQuery();
query.setType(KbQuery.Type.TAG_NAME);
+
if(i > 0) query.setPrefix(tagName.substring(0, i));
+ else query.setPrefix("");
+
query.setOffset(reg.getOffset());
query.setValue(tagName);
query.setUri(getURI(region, textViewer.getDocument()));
@@ -89,7 +94,7 @@
IComponent[] components = PageProcessor.getInstance().getComponents(query, (IPageContext)context);
ArrayList<IHyperlink> hyperlinks = new ArrayList<IHyperlink>();
for(IComponent component : components){
- if(validateComponent(component)){
+ if(validateComponent(component, ((IPageContext)context).getNameSpaces(reg.getOffset()), query.getPrefix())){
TLDTagHyperlink link = new TLDTagHyperlink((AbstractComponent)component, reg);
link.setDocument(textViewer.getDocument());
hyperlinks.add(link);
@@ -104,7 +109,10 @@
int i = tagName.indexOf(":");
KbQuery query = new KbQuery();
query.setType(KbQuery.Type.ATTRIBUTE_NAME);
+
if(i > 0) query.setPrefix(tagName.substring(0, i));
+ else query.setPrefix("");
+
query.setUri(getURI(region, textViewer.getDocument()));
query.setParentTags(new String[]{tagName});
query.setParent(tagName);
@@ -118,7 +126,7 @@
IAttribute[] components = PageProcessor.getInstance().getAttributes(query, (IPageContext)context);
ArrayList<IHyperlink> hyperlinks = new ArrayList<IHyperlink>();
for(IAttribute attribute : components){
- if(validateComponent(attribute.getComponent())){
+ if(validateComponent(attribute.getComponent(), ((IPageContext)context).getNameSpaces(reg.getOffset()), query.getPrefix())){
TLDAttributeHyperlink link = new TLDAttributeHyperlink((AbstractAttribute)attribute, reg);
link.setDocument(textViewer.getDocument());
hyperlinks.add(link);
@@ -133,8 +141,11 @@
return parse(textViewer.getDocument(), xmlDocument, region);
}
- private boolean validateComponent(IComponent component){
- if(component instanceof TLDTag || component instanceof FaceletTag){
+ private boolean validateComponent(IComponent component, Map<String, List<INameSpace>> nameSpaces, String prefix){
+ if(!validateNameSpace(component, nameSpaces, prefix))
+ return false;
+
+ if(component instanceof AbstractComponent){
IFile file = TLDTagHyperlink.getFile((AbstractComponent)component);
if(file != null && file.getFullPath() != null && file.getFullPath().toString().endsWith(".jar")) {
@@ -148,6 +159,18 @@
return false;
}
+ private boolean validateNameSpace(IComponent component, Map<String, List<INameSpace>> nameSpaces, String prefix){
+ String uri = component.getTagLib().getURI();
+ List<INameSpace> list = nameSpaces.get(uri);
+ if(list != null){
+ for(INameSpace nameSpace : list){
+ if(nameSpace.getPrefix().equals(prefix))
+ return true;
+ }
+ }
+ return false;
+ }
+
private void sortHyperlinks(ArrayList<IHyperlink> hyperlinks){
for(IHyperlink link : hyperlinks){
if(link instanceof TLDTagHyperlink){
13 years, 6 months