[jbosstools-commits] JBoss Tools SVN: r44108 - in trunk: cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation and 28 other directories.
jbosstools-commits at lists.jboss.org
jbosstools-commits at lists.jboss.org
Thu Sep 27 20:35:27 EDT 2012
Author: dazarov
Date: 2012-09-27 20:35:24 -0400 (Thu, 27 Sep 2012)
New Revision: 44108
Modified:
trunk/cdi/plugins/org.jboss.tools.cdi.core/plugin.xml
trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java
trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/CDIAnnotationTest.java
trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/DisableCDISupportTest.java
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIMarkerResolutionTest.java
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIQuickFixTest.java
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeCDIAndELValidatorsMassagesProcessingTest.java
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaSupressWarningsTest.java
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaValidationTest.java
trunk/common/plugins/org.jboss.tools.common.validation/schema/validator.exsd
trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/IValidator.java
trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/PreferenceInfoManager.java
trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/TempMarkerManager.java
trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationContext.java
trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationErrorManager.java
trunk/common/tests/org.jboss.tools.common.validation.test/plugin.xml
trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestSynchronizationValidator.java
trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestValidator.java
trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBCoreValidator.java
trunk/jsf/plugins/org.jboss.tools.jsf/plugin.xml
trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/FacesConfigValidator.java
trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/composite/CompositeComponentValidator.java
trunk/jsf/tests/org.jboss.tools.jsf.test/src/org/jboss/tools/jsf/test/validation/ELValidatorTest.java
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/ELValidator.java
trunk/jst/plugins/org.jboss.tools.jst.web/plugin.xml
trunk/jst/plugins/org.jboss.tools.jst.web/src/org/jboss/tools/jst/web/validation/WebXMLCoreValidator.java
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/plugin.xml
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/validation/TestValidator.java
trunk/jst/tests/org.jboss.tools.jst.web.test/src/org/jboss/tools/jst/web/test/WebXMLValidationTest.java
trunk/seam/plugins/org.jboss.tools.seam.core/plugin.xml
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamProjectPropertyValidator.java
trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/validation/SeamProjectPropertyValidatorWrapper.java
trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/marker/SeamMarkerResolutionTest.java
trunk/struts/plugins/org.jboss.tools.struts/plugin.xml
trunk/struts/plugins/org.jboss.tools.struts/src/org/jboss/tools/struts/validation/StrutsCoreValidator.java
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/plugin.xml
trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsMetamodelValidator.java
Log:
Configure Problem Severity should open project settings if they are enabled for the project https://issues.jboss.org/browse/JBIDE-12538
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/plugin.xml
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -157,8 +157,9 @@
point="org.jboss.tools.common.validation.validator">
<validator
class="org.jboss.tools.cdi.internal.core.validation.CDICoreValidator"
- name="%CDICoreValidator"
- id="org.jboss.tools.cdi.core.CoreValidator">
+ name="%CDICoreValidator"
+ id="org.jboss.tools.cdi.core.CoreValidator"
+ problemType="org.jboss.tools.cdi.core.cdiproblem">
</validator>
</extension>
Modified: trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java
===================================================================
--- trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/plugins/org.jboss.tools.cdi.core/src/org/jboss/tools/cdi/internal/core/validation/CDICoreValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -125,7 +125,6 @@
*/
public class CDICoreValidator extends CDIValidationErrorManager implements IJavaElementValidator, IStringValidator {
public static final String ID = "org.jboss.tools.cdi.core.CoreValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.cdi.core.cdiproblem"; //$NON-NLS-1$
public static final String PREFERENCE_PAGE_ID = "org.jboss.tools.cdi.ui.preferences.CDIValidatorPreferencePage"; //$NON-NLS-1$
public static final String PROPERTY_PAGE_ID = "org.jboss.tools.cdi.ui.propertyPages.CDIValidatorPreferencePage"; //$NON-NLS-1$
@@ -215,15 +214,6 @@
/*
* (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- @Override
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
- /*
- * (non-Javadoc)
*
* @see org.jboss.tools.jst.web.kb.validation.IValidator#getId()
*/
@@ -515,7 +505,7 @@
rootCdiProject = new CDIProjectAsYouType(rootCdiProject, file);
validateResource(file);
if(reporter instanceof ITypedReporter) {
- ((ITypedReporter)reporter).addTypeForFile(getMarkerType());
+ ((ITypedReporter)reporter).addTypeForFile(getProblemType());
}
disableProblemAnnotations(new ITextSourceReference() {
@Override
@@ -2726,10 +2716,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new CDIPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new CDIPreferenceInfo());
}
class CDIPreferenceInfo implements IPreferenceInfo{
Modified: trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/CDIAnnotationTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/CDIAnnotationTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/CDIAnnotationTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -10,16 +10,15 @@
******************************************************************************/
package org.jboss.tools.cdi.core.test.tck.validation;
-import org.jboss.tools.cdi.internal.core.validation.CDICoreValidator;
import org.jboss.tools.common.base.test.validation.AbstractAnnotationTest;
/**
* @author Alexey Kazakov
*/
public class CDIAnnotationTest extends AbstractAnnotationTest {
-
+ public static final String PROBLEM_TYPE = "org.jboss.tools.cdi.core.cdiproblem"; //$NON-NLS-1$
@Override
protected String getMarkerType() {
- return CDICoreValidator.PROBLEM_TYPE;
+ return PROBLEM_TYPE;
}
}
\ No newline at end of file
Modified: trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/DisableCDISupportTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/DisableCDISupportTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/tests/org.jboss.tools.cdi.core.test/src/org/jboss/tools/cdi/core/test/tck/validation/DisableCDISupportTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -15,7 +15,6 @@
import org.eclipse.core.resources.IResource;
import org.jboss.tools.cdi.core.CDIUtil;
import org.jboss.tools.cdi.core.test.tck.TCKTest;
-import org.jboss.tools.cdi.internal.core.validation.CDICoreValidator;
import org.jboss.tools.test.util.JobUtils;
import org.jboss.tools.test.util.ResourcesUtils;
@@ -23,7 +22,8 @@
* @author Alexey Kazakov
*/
public class DisableCDISupportTest extends ValidationTest {
-
+ private static final String CDI_CORE_VALIDATOR_PROBLEM_TYPE = "org.jboss.tools.cdi.core.cdiproblem";
+
protected IProject tckProject;
/*
@@ -52,10 +52,10 @@
* @throws Exception
*/
public void testRemovingProblemMarkers() throws Exception {
- IMarker[] markers = tckProject.findMarkers(CDICoreValidator.PROBLEM_TYPE, true, IResource.DEPTH_INFINITE);
+ IMarker[] markers = tckProject.findMarkers(CDI_CORE_VALIDATOR_PROBLEM_TYPE, true, IResource.DEPTH_INFINITE);
assertFalse(markers.length==0);
CDIUtil.disableCDI(tckProject);
- markers = tckProject.findMarkers(CDICoreValidator.PROBLEM_TYPE, true, IResource.DEPTH_INFINITE);
+ markers = tckProject.findMarkers(CDI_CORE_VALIDATOR_PROBLEM_TYPE, true, IResource.DEPTH_INFINITE);
assertEquals(0, markers.length);
}
}
\ No newline at end of file
Modified: trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIMarkerResolutionTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIMarkerResolutionTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIMarkerResolutionTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -12,7 +12,6 @@
import org.eclipse.core.runtime.CoreException;
import org.jboss.tools.cdi.core.test.tck.TCKTest;
-import org.jboss.tools.cdi.internal.core.validation.CDICoreValidator;
import org.jboss.tools.cdi.internal.core.validation.CDIValidationErrorManager;
import org.jboss.tools.cdi.ui.marker.AddAnnotationMarkerResolution;
import org.jboss.tools.cdi.ui.marker.AddLocalBeanMarkerResolution;
@@ -38,7 +37,8 @@
*
*/
public class CDIMarkerResolutionTest extends TCKTest {
-
+ public static final String PROBLEM_TYPE = "org.jboss.tools.cdi.core.cdiproblem"; //$NON-NLS-1$
+
public void testMakeProducerFieldStaticResolution() throws CoreException {
MarkerResolutionTestUtil.checkResolution(tckProject,
new String[]{
@@ -47,7 +47,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NonStaticProducerOfSessionBeanBroken.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_PRODUCER_FIELD_IN_SESSION_BEAN_ID,
MakeFieldStaticMarkerResolution.class);
@@ -64,7 +64,7 @@
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/FooProducer1.qfxresult",
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/FooProducerLocal.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_PRODUCER_METHOD_IN_SESSION_BEAN_ID,
MakeMethodBusinessMarkerResolution.class);
@@ -79,7 +79,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/FooProducer2.qfxresult",
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_PRODUCER_METHOD_IN_SESSION_BEAN_ID,
AddLocalBeanMarkerResolution.class);
@@ -93,7 +93,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/FooProducerNoInterface.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_PRODUCER_METHOD_IN_SESSION_BEAN_ID,
MakeMethodPublicMarkerResolution.class);
@@ -109,7 +109,7 @@
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TibetanTerrier_Broken1.qfxresult",
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/Terrier.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_OBSERVER_IN_SESSION_BEAN_ID,
MakeMethodBusinessMarkerResolution.class);
@@ -123,7 +123,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TibetanTerrier_Broken2.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_OBSERVER_IN_SESSION_BEAN_ID,
AddLocalBeanMarkerResolution.class);
@@ -137,7 +137,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TibetanTerrier_BrokenNoInterface.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_OBSERVER_IN_SESSION_BEAN_ID,
MakeMethodPublicMarkerResolution.class);
@@ -153,7 +153,7 @@
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NotBusinessMethod_Broken1.qfxresult",
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/LocalInt.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_DISPOSER_IN_SESSION_BEAN_ID,
MakeMethodBusinessMarkerResolution.class);
@@ -167,7 +167,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NotBusinessMethod_Broken2.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_DISPOSER_IN_SESSION_BEAN_ID,
AddLocalBeanMarkerResolution.class);
@@ -181,7 +181,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NotBusinessMethod_BrokenNoInterface.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_DISPOSER_IN_SESSION_BEAN_ID,
MakeMethodPublicMarkerResolution.class);
@@ -195,7 +195,7 @@
// new String[]{
// "JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TimestampLogger_Broken.qfxresult"
// },
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MULTIPLE_DISPOSERS_FOR_PRODUCER_ID,
DeleteAllDisposerDuplicantMarkerResolution.class);
@@ -209,7 +209,7 @@
// new String[]{
// "JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/Goose_Broken.qfxresult"
// },
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MULTIPLE_INJECTION_CONSTRUCTORS_ID,
DeleteAllInjectedConstructorsMarkerResolution.class);
@@ -223,7 +223,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/Hamina_Broken.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.NOT_PASSIVATION_CAPABLE_BEAN_ID,
AddSerializableInterfaceMarkerResolution.class);
@@ -237,7 +237,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/SecondBean.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.NOT_PASSIVATION_CAPABLE_BEAN_ID,
AddSerializableInterfaceMarkerResolution.class);
@@ -251,7 +251,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestQualifier1.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_QUALIFIER_TYPE_ID,
AddRetentionAnnotationMarkerResolution.class);
@@ -265,7 +265,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestQualifier2.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_QUALIFIER_TYPE_ID,
ChangeAnnotationMarkerResolution.class);
@@ -279,7 +279,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestScope1.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_SCOPE_TYPE_ID,
AddRetentionAnnotationMarkerResolution.class);
@@ -293,7 +293,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestScope2.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_SCOPE_TYPE_ID,
ChangeAnnotationMarkerResolution.class);
@@ -307,7 +307,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestStereotype1.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_STEREOTYPE_TYPE_ID,
AddRetentionAnnotationMarkerResolution.class);
@@ -321,7 +321,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestStereotype2.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_STEREOTYPE_TYPE_ID,
ChangeAnnotationMarkerResolution.class);
@@ -332,7 +332,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestStereotype3.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_TARGET_ANNOTATION_IN_STEREOTYPE_TYPE_ID,
AddTargetAnnotationMarkerResolution.class);
@@ -343,7 +343,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestStereotype4.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_TARGET_ANNOTATION_IN_STEREOTYPE_TYPE_ID,
ChangeAnnotationMarkerResolution.class);
@@ -354,7 +354,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestQualifier3.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_TARGET_ANNOTATION_IN_QUALIFIER_TYPE_ID,
AddTargetAnnotationMarkerResolution.class);
@@ -365,7 +365,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestQualifier4.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_TARGET_ANNOTATION_IN_QUALIFIER_TYPE_ID,
ChangeAnnotationMarkerResolution.class);
@@ -379,7 +379,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestScope3.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_TARGET_ANNOTATION_IN_SCOPE_TYPE_ID,
AddTargetAnnotationMarkerResolution.class);
@@ -393,7 +393,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestScope4.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_TARGET_ANNOTATION_IN_SCOPE_TYPE_ID,
ChangeAnnotationMarkerResolution.class);
@@ -407,7 +407,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestQualifier5.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_NONBINDING_FOR_ANNOTATION_VALUE_IN_QUALIFIER_TYPE_MEMBER_ID,
AddAnnotationMarkerResolution.class);
@@ -421,7 +421,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestQualifier6.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_NONBINDING_FOR_ARRAY_VALUE_IN_QUALIFIER_TYPE_MEMBER_ID,
AddAnnotationMarkerResolution.class);
@@ -435,7 +435,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInterceptor1.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_NONBINDING_FOR_ANNOTATION_VALUE_IN_INTERCEPTOR_BINDING_TYPE_MEMBER_ID,
AddAnnotationMarkerResolution.class);
@@ -449,7 +449,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInterceptor2.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MISSING_NONBINDING_FOR_ARRAY_VALUE_IN_INTERCEPTOR_BINDING_TYPE_MEMBER_ID,
AddAnnotationMarkerResolution.class);
@@ -460,7 +460,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInjectProducerField.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.PRODUCER_ANNOTATED_INJECT_ID,
DeleteAnnotationMarkerResolution.class);
@@ -471,7 +471,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInjectProducerMethod.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.PRODUCER_ANNOTATED_INJECT_ID,
DeleteAnnotationMarkerResolution.class);
@@ -482,7 +482,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInjectObserverMethod.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.OBSERVER_ANNOTATED_INJECT_ID,
DeleteAnnotationMarkerResolution.class);
@@ -493,7 +493,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInjectDisposerMethod.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.DISPOSER_ANNOTATED_INJECT_ID,
DeleteAnnotationMarkerResolution.class);
@@ -507,7 +507,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestDisposerConstructor.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.CONSTRUCTOR_PARAMETER_ANNOTATED_DISPOSES_ID,
DeleteAnnotationMarkerResolution.class);
@@ -521,7 +521,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestObserverConstructor.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.CONSTRUCTOR_PARAMETER_ANNOTATED_OBSERVES_ID,
DeleteAnnotationMarkerResolution.class);
@@ -535,7 +535,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInterceptor3.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.DISPOSER_IN_INTERCEPTOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -549,7 +549,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestDecorator.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.DISPOSER_IN_DECORATOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -563,7 +563,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInterceptor4.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.PRODUCER_IN_INTERCEPTOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -577,7 +577,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestDecorator2.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.PRODUCER_IN_DECORATOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -588,7 +588,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestStereotype5.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.STEREOTYPE_DECLARES_NON_EMPTY_NAME_ID,
DeleteAnnotationMarkerResolution.class);
@@ -599,7 +599,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestStereotype5.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.STEREOTYPE_DECLARES_NON_EMPTY_NAME_ID,
ChangeAnnotationMarkerResolution.class);
@@ -613,7 +613,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInterceptor5.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.INTERCEPTOR_HAS_NAME_ID,
DeleteAnnotationMarkerResolution.class);
@@ -625,7 +625,7 @@
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NamedStereotypedInterceptorBroken.java",
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NamedStereotype.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.INTERCEPTOR_HAS_NAME_ID,
DeleteAnnotationMarkerResolution.class);
@@ -639,7 +639,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestDecorator3.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.DECORATOR_HAS_NAME_ID,
DeleteAnnotationMarkerResolution.class);
@@ -651,7 +651,7 @@
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NamedStereotypedDecoratorBroken.java",
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NamedStereotype.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.DECORATOR_HAS_NAME_ID,
DeleteAnnotationMarkerResolution.class);
@@ -662,7 +662,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TD.java",
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.DECORATOR_HAS_NAME_ID,
DeleteAnnotationMarkerResolution.class);
@@ -676,7 +676,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestStereotype6.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.STEREOTYPE_IS_ANNOTATED_TYPED_ID,
DeleteAnnotationMarkerResolution.class);
@@ -690,7 +690,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestDecorator4.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.DECORATOR_ANNOTATED_SPECIALIZES_ID,
DeleteAnnotationMarkerResolution.class);
@@ -704,7 +704,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestInterceptor6.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.INTERCEPTOR_ANNOTATED_SPECIALIZES_ID,
DeleteAnnotationMarkerResolution.class);
@@ -715,7 +715,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestDisposerProducerMethod.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.PRODUCER_PARAMETER_ILLEGALLY_ANNOTATED_DISPOSES_ID,
DeleteAnnotationMarkerResolution.class);
@@ -726,7 +726,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/TestObserverProducerMethod.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.PRODUCER_PARAMETER_ILLEGALLY_ANNOTATED_OBSERVES_ID,
DeleteAnnotationMarkerResolution.class);
@@ -737,7 +737,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/DisposerInObserver.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.OBSERVER_PARAMETER_ILLEGALLY_ANNOTATED_ID,
DeleteAnnotationMarkerResolution.class);
@@ -751,7 +751,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/ObserverInDecorator.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.OBSERVER_IN_DECORATOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -765,7 +765,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/ObserverInInterceptor.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.OBSERVER_IN_INTERCEPTOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -779,7 +779,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/SessionBeanAnnotatedDecoratorBroken.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.SESSION_BEAN_ANNOTATED_DECORATOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -793,7 +793,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/SessionBeanAnnotatedInterceptorBroken.qfxresult"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.SESSION_BEAN_ANNOTATED_INTERCEPTOR_ID,
DeleteAnnotationMarkerResolution.class);
@@ -805,7 +805,7 @@
//"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/beans.xml"
"WebContent/WEB-INF/beans.xml"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.UNKNOWN_ALTERNATIVE_BEAN_CLASS_NAME_ID,
CreateCDIElementMarkerResolution.class);
@@ -817,7 +817,7 @@
//"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/beans.xml"
"WebContent/WEB-INF/beans.xml"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.UNKNOWN_ALTERNATIVE_ANNOTATION_NAME_ID,
CreateCDIElementMarkerResolution.class);
@@ -829,7 +829,7 @@
//"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/beans.xml"
"WebContent/WEB-INF/beans.xml"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.UNKNOWN_INTERCEPTOR_CLASS_NAME_ID,
CreateCDIElementMarkerResolution.class);
@@ -840,7 +840,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/NamedInjectionBroken.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.PARAM_INJECTION_DECLARES_EMPTY_NAME_ID,
AddNameMarkerResolution.class);
@@ -851,7 +851,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/MultipleDisposers.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MULTIPLE_DISPOSING_PARAMETERS_ID,
DeleteAllOtherAnnotationsFromParametersMarkerResolution.class);
@@ -862,7 +862,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/MultipleObservers.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.MULTIPLE_OBSERVING_PARAMETERS_ID,
DeleteAllOtherAnnotationsFromParametersMarkerResolution.class);
@@ -873,7 +873,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/Leopard_Broken.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_SCOPE_FOR_MANAGED_BEAN_WITH_PUBLIC_FIELD_ID,
MakeFieldProtectedMarkerResolution.class);
@@ -884,7 +884,7 @@
new String[]{
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/Leopard_Broken.java"
},
- CDICoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
CDIValidationErrorManager.MESSAGE_ID_ATTRIBUTE_NAME,
CDIValidationErrorManager.ILLEGAL_SCOPE_FOR_MANAGED_BEAN_WITH_PUBLIC_FIELD_ID,
MakeBeanScopedDependentMarkerResolution.class);
Modified: trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIQuickFixTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIQuickFixTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/marker/CDIQuickFixTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -2,7 +2,6 @@
import org.eclipse.core.runtime.CoreException;
import org.jboss.tools.cdi.core.test.tck.TCKTest;
-import org.jboss.tools.cdi.internal.core.validation.CDICoreValidator;
import org.jboss.tools.cdi.internal.core.validation.CDIValidationErrorManager;
import org.jboss.tools.cdi.ui.marker.AddAnnotationMarkerResolution;
import org.jboss.tools.cdi.ui.marker.AddLocalBeanMarkerResolution;
@@ -17,16 +16,9 @@
import org.jboss.tools.common.base.test.QuickFixTestUtil;
public class CDIQuickFixTest extends TCKTest {
+ public static final String PROBLEM_TYPE = "org.jboss.tools.cdi.core.cdiproblem"; //$NON-NLS-1$
private QuickFixTestUtil util = new QuickFixTestUtil();
- public void setUp() throws Exception {
- super.setUp();
-
- // register Preference Info
- new CDICoreValidator();
- }
-
-
public void testMakeFieldStatic() throws CoreException {
util.checkProposal(tckProject,
"JavaSource/org/jboss/jsr299/tck/tests/jbt/quickfixes/MakeFieldStatic.java",
@@ -35,7 +27,7 @@
CDIValidationErrorManager.ILLEGAL_PRODUCER_FIELD_IN_SESSION_BEAN_ID,
MakeFieldStaticMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testAddLocalBeanResolution() throws CoreException {
@@ -46,7 +38,7 @@
CDIValidationErrorManager.ILLEGAL_PRODUCER_METHOD_IN_SESSION_BEAN_ID,
AddLocalBeanMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
@@ -58,7 +50,7 @@
CDIValidationErrorManager.ILLEGAL_PRODUCER_METHOD_IN_SESSION_BEAN_ID,
MakeMethodPublicMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
@@ -70,7 +62,7 @@
CDIValidationErrorManager.NOT_PASSIVATION_CAPABLE_BEAN_ID,
AddSerializableInterfaceMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testAddRetentionToQualifierResolution() throws CoreException{
@@ -81,7 +73,7 @@
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_QUALIFIER_TYPE_ID,
AddRetentionAnnotationMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testChangeRetentionToQualifierResolution() throws CoreException{
@@ -92,7 +84,7 @@
CDIValidationErrorManager.MISSING_RETENTION_ANNOTATION_IN_QUALIFIER_TYPE_ID,
ChangeAnnotationMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testAddTargetToScopeResolution() throws CoreException{
@@ -103,7 +95,7 @@
CDIValidationErrorManager.MISSING_TARGET_ANNOTATION_IN_SCOPE_TYPE_ID,
AddTargetAnnotationMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testAddNonbindingToAnnotationMemberOfQualifierResolution() throws CoreException{
@@ -114,7 +106,7 @@
CDIValidationErrorManager.MISSING_NONBINDING_FOR_ANNOTATION_VALUE_IN_QUALIFIER_TYPE_MEMBER_ID,
AddAnnotationMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testDeleteDisposesAnnotationFromParameterResolution() throws CoreException{
@@ -125,7 +117,7 @@
CDIValidationErrorManager.CONSTRUCTOR_PARAMETER_ANNOTATED_DISPOSES_ID,
DeleteAnnotationMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testCreateBeanClassResolution() throws CoreException{
@@ -136,7 +128,7 @@
CDIValidationErrorManager.UNKNOWN_ALTERNATIVE_BEAN_CLASS_NAME_ID,
CreateCDIElementMarkerResolution.class,
true,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testCreateStereotypeResolution() throws CoreException{
@@ -147,7 +139,7 @@
CDIValidationErrorManager.UNKNOWN_ALTERNATIVE_ANNOTATION_NAME_ID,
CreateCDIElementMarkerResolution.class,
false,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testCreateDecoratorResolution() throws CoreException{
@@ -158,7 +150,7 @@
CDIValidationErrorManager.UNKNOWN_DECORATOR_BEAN_CLASS_NAME_ID,
CreateCDIElementMarkerResolution.class,
false,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
public void testCreateInterceptorResolution() throws CoreException{
@@ -169,6 +161,6 @@
CDIValidationErrorManager.UNKNOWN_INTERCEPTOR_CLASS_NAME_ID,
CreateCDIElementMarkerResolution.class,
false,
- CDICoreValidator.PROBLEM_TYPE);
+ PROBLEM_TYPE);
}
}
Modified: trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeCDIAndELValidatorsMassagesProcessingTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeCDIAndELValidatorsMassagesProcessingTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeCDIAndELValidatorsMassagesProcessingTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -17,7 +17,6 @@
import org.jboss.tools.cdi.core.test.tck.TCKTest;
import org.jboss.tools.common.base.test.validation.AbstractAsYouTypeValidationTest;
import org.jboss.tools.common.base.test.validation.java.BaseAsYouTypeInJavaValidationTest;
-import org.jboss.tools.jst.web.kb.internal.validation.ELValidator;
/**
*
@@ -26,6 +25,7 @@
*/
public class CDIAsYouTypeCDIAndELValidatorsMassagesProcessingTest extends TCKTest {
private static final String PAGE_NAME = "JavaSource/org/jboss/jsr299/tck/tests/jbt/validation/Bean_Broken.java";
+ private static final String EL_VALIDATOR_PROBLEM_TYPE = "org.jboss.tools.jst.web.kb.elproblem";
private BaseAsYouTypeInJavaValidationTest baseTest = null;
protected IProject project;
@@ -44,7 +44,7 @@
project = TCKTest.findTestProject();
if (baseTest == null) {
// Since the test is about EL errors we're using ELValidator.PROBLEM_TYPE type of problem
- baseTest = new BaseAsYouTypeInJavaValidationTest(project, ELValidator.PROBLEM_TYPE);
+ baseTest = new BaseAsYouTypeInJavaValidationTest(project, EL_VALIDATOR_PROBLEM_TYPE);
}
}
Modified: trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaSupressWarningsTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaSupressWarningsTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaSupressWarningsTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -15,7 +15,6 @@
import org.eclipse.jface.text.BadLocationException;
import org.eclipse.jface.text.source.Annotation;
import org.jboss.tools.cdi.core.test.tck.TCKTest;
-import org.jboss.tools.cdi.internal.core.validation.CDICoreValidator;
import org.jboss.tools.cdi.internal.core.validation.CDIValidationMessages;
import org.jboss.tools.common.base.test.validation.AbstractAsYouTypeValidationTest;
import org.jboss.tools.common.base.test.validation.java.BaseAsYouTypeInJavaValidationTest;
@@ -27,6 +26,7 @@
*/
public class CDIAsYouTypeInJavaSupressWarningsTest extends TCKTest {
private static final String PAGE_NAME = "JavaSource/org/jboss/jsr299/tck/tests/jbt/validation/TestNamed.java";
+ private static final String CDI_CORE_VALIDATOR_PROBLEM_TYPE = "org.jboss.tools.cdi.core.cdiproblem";
private BaseAsYouTypeInJavaValidationTest baseTest = null;
protected IProject project;
@@ -39,7 +39,7 @@
public void setUp() throws Exception {
project = TCKTest.findTestProject();
if (baseTest == null) {
- baseTest = new BaseAsYouTypeInJavaValidationTest(project, CDICoreValidator.PROBLEM_TYPE);
+ baseTest = new BaseAsYouTypeInJavaValidationTest(project, CDI_CORE_VALIDATOR_PROBLEM_TYPE);
}
}
Modified: trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaValidationTest.java
===================================================================
--- trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaValidationTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/validation/java/CDIAsYouTypeInJavaValidationTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -15,7 +15,6 @@
import org.eclipse.jface.text.BadLocationException;
import org.eclipse.jface.text.source.Annotation;
import org.jboss.tools.cdi.core.test.tck.TCKTest;
-import org.jboss.tools.cdi.internal.core.validation.CDICoreValidator;
import org.jboss.tools.cdi.internal.core.validation.CDIValidationMessages;
import org.jboss.tools.common.base.test.validation.AbstractAsYouTypeValidationTest;
import org.jboss.tools.common.base.test.validation.java.BaseAsYouTypeInJavaValidationTest;
@@ -27,6 +26,7 @@
*/
public class CDIAsYouTypeInJavaValidationTest extends TCKTest {
private static final String PAGE_NAME = "JavaSource/org/jboss/jsr299/tck/tests/jbt/validation/NPEValidation.java";
+ private static final String CDI_CORE_VALIDATOR_PROBLEM_TYPE = "org.jboss.tools.cdi.core.cdiproblem";
private BaseAsYouTypeInJavaValidationTest baseTest = null;
protected IProject project;
@@ -41,7 +41,7 @@
public void setUp() throws Exception {
project = TCKTest.findTestProject();
if (baseTest == null) {
- baseTest = new BaseAsYouTypeInJavaValidationTest(project, CDICoreValidator.PROBLEM_TYPE);
+ baseTest = new BaseAsYouTypeInJavaValidationTest(project, CDI_CORE_VALIDATOR_PROBLEM_TYPE);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.validation/schema/validator.exsd
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.validation/schema/validator.exsd 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/plugins/org.jboss.tools.common.validation/schema/validator.exsd 2012-09-28 00:35:24 UTC (rev 44108)
@@ -80,6 +80,13 @@
</documentation>
</annotation>
</attribute>
+ <attribute name="problemType" type="string" use="required">
+ <annotation>
+ <documentation>
+
+ </documentation>
+ </annotation>
+ </attribute>
</complexType>
</element>
Modified: trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/IValidator.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/IValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/IValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -70,4 +70,18 @@
* @return
*/
boolean isEnabled(IProject project);
+
+ /**
+ * Sets type of problem for problem markers and problem annotations
+ * @param problemType
+ */
+ void setProblemType(String problemType);
+
+ /*
+ * register IPreferenceInfo in PreferenceInfoManager
+ * validator is supposed to have own implementation of IPreferenceInfo
+ * and register it in PreferenceInfoManager
+ * see CDICoreValidator.registerPreferenceInfo() as an example
+ */
+ void registerPreferenceInfo();
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/PreferenceInfoManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/PreferenceInfoManager.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/PreferenceInfoManager.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -35,6 +35,11 @@
* returns IPreferenceInfo for problemType
*/
public static IPreferenceInfo getPreferenceInfo(String problemType){
- return infos.get(problemType);
+ IPreferenceInfo info = infos.get(problemType);
+ if(info == null){
+ ValidationContext.loadValidatorByProblemType(problemType);
+ info = infos.get(problemType);
+ }
+ return info;
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/TempMarkerManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/TempMarkerManager.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/TempMarkerManager.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -189,7 +189,7 @@
if(preferenceKey != null){
message.setAttribute(PREFERENCE_KEY_ATTRIBUTE_NAME, preferenceKey);
}
- String type = getMarkerType();
+ String type = getProblemType();
if(type!=null) {
message.setAttribute(MESSAGE_TYPE_ATTRIBUTE_NAME, type);
}
@@ -284,7 +284,7 @@
IMarker marker = annotation.getMarker();
try {
String type = marker.getType();
- if(getMarkerType().equals(type)) {
+ if(getProblemType().equals(type)) {
int offset = marker.getAttribute(IMarker.CHAR_START, 0);
int originalMarkerEnd = marker.getAttribute(IMarker.CHAR_END, -1);
String markerMessage = marker.getAttribute(IMarker.MESSAGE, "");
@@ -316,7 +316,7 @@
Position p = anModel.getPosition(annotation);
for (Object object : messageArray) {
IMessage message = (IMessage)object;
- if(getMarkerType().equals(annotation.getProblemType()) && message.getOffset() == p.getOffset() && annotation.getText().equals(message.getText())) {
+ if(getProblemType().equals(annotation.getProblemType()) && message.getOffset() == p.getOffset() && annotation.getText().equals(message.getText())) {
annotationsToRemove.add(annotation);
Annotation markerAnnotation = annotation.getOverlaidAnnotation();
markerAnnotation.markDeleted(true);
Modified: trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationContext.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationContext.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationContext.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -61,6 +61,33 @@
}
}
}
+
+ public static void loadValidatorByProblemType(String problemType){
+ inintConfigurationElements();
+
+ for (IConfigurationElement element : ALL_VALIDATORS) {
+ String pt = element.getAttribute("problemType"); //$NON-NLS-1$
+ if(problemType.equals(pt)){
+ createValidator(element, problemType);
+ }
+ }
+ }
+
+ private static IValidator createValidator(IConfigurationElement element, String problemType){
+ if(problemType == null){
+ CommonPlugin.getDefault().logError("problem type must be not null");
+ return null;
+ }
+ try {
+ IValidator validator = (IValidator)element.createExecutableExtension("class"); //$NON-NLS-1$
+ validator.setProblemType(problemType);
+ validator.registerPreferenceInfo();
+ return validator;
+ } catch (CoreException e) {
+ CommonPlugin.getDefault().logError(e);
+ }
+ return null;
+ }
protected List<IValidator> getAllValidators(IProject project) {
projectTree.clear();
@@ -72,16 +99,14 @@
List<IValidator> dependentValidators = new ArrayList<IValidator>();
List<IValidator> allValidators = new ArrayList<IValidator>();
for (IConfigurationElement element : ALL_VALIDATORS) {
- try {
- IValidator validator = (IValidator)element.createExecutableExtension("class"); //$NON-NLS-1$
+ IValidator validator = createValidator(element, element.getAttribute("problemType"));
+ if(validator != null){
String dependent = element.getAttribute("dependent"); //$NON-NLS-1$
if(Boolean.parseBoolean(dependent)) {
dependentValidators.add(validator);
} else {
allValidators.add(validator);
}
- } catch (CoreException e) {
- CommonPlugin.getDefault().logError(e);
}
}
// We should add all the dependent validators (e.g. EL validator) to the very end of the list.
Modified: trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationErrorManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationErrorManager.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/plugins/org.jboss.tools.common.validation/src/org/jboss/tools/common/validation/ValidationErrorManager.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -70,7 +70,6 @@
* Constructor
*/
public ValidationErrorManager() {
- registerPreferenceInfo();
}
// /**
@@ -492,14 +491,12 @@
CommonPlugin.getDefault().logError("Wrong offset [" + offset + "] of the problem marker [" + MessageFormat.format(message, messageArguments) + "] for resource: " + target.getFullPath().toOSString(), e); //$NON-NLS-1$ //$NON-NLS-2$//$NON-NLS-3$
}
}
- MarkerManager.getDefault().getMarkers().add(getMarkerType()); // We need to register the marker type in WST since this type is not equaled to ValidatorManager's type. WST need this type to remove markers when the validator is disabled. See https://issues.jboss.org/browse/JBIDE-12595
- return addError(message, severity, messageArguments, lineNumber, length, offset, target, documentProvider, markerId, markerOwner, getMaxNumberOfMarkersPerFile(target.getProject()), getMarkerType());
+ MarkerManager.getDefault().getMarkers().add(getProblemType()); // We need to register the marker type in WST since this type is not equaled to ValidatorManager's type. WST need this type to remove markers when the validator is disabled. See https://issues.jboss.org/browse/JBIDE-12595
+ return addError(message, severity, messageArguments, lineNumber, length, offset, target, documentProvider, markerId, markerOwner, getMaxNumberOfMarkersPerFile(target.getProject()), getProblemType());
}
abstract public int getMaxNumberOfMarkersPerFile(IProject project);
- public abstract String getMarkerType();
-
private static IMarker addTask(String pluginId, IResource resource, int location,
String message, int severityEnumValue, String targetObjectName,
String groupName, int offset, int length, int maxNumberOfMarkersPerFile, String markerType) throws CoreException {
@@ -615,4 +612,21 @@
* see CDICoreValidator.registerPreferenceInfo() as an example
*/
protected abstract void registerPreferenceInfo();
+
+ protected String problemType = null;
+
+ /**
+ * Sets type of problem for problem markers and problem annotations
+ * @param problemType
+ */
+ public void setProblemType(String problemType){
+ this.problemType = problemType;
+ }
+
+ /**
+ * @return type of problem for problem markers and problem annotations
+ */
+ public String getProblemType(){
+ return problemType;
+ }
}
\ No newline at end of file
Modified: trunk/common/tests/org.jboss.tools.common.validation.test/plugin.xml
===================================================================
--- trunk/common/tests/org.jboss.tools.common.validation.test/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/tests/org.jboss.tools.common.validation.test/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -7,12 +7,14 @@
<validator
class="org.jboss.tools.common.validation.test.TestValidator"
name="TestValidator"
- id="org.jboss.common.validation.test.TestValidator">
+ id="org.jboss.common.validation.test.TestValidator"
+ problemType="org.eclipse.wst.validation.problemmarker">
</validator>
<validator
class="org.jboss.tools.common.validation.test.TestSynchronizationValidator"
name="TestSynchronizationValidator"
- id="org.jboss.common.validation.test.TestSynchronizationValidator">
+ id="org.jboss.common.validation.test.TestSynchronizationValidator"
+ problemType="org.eclipse.wst.validation.problemmarker">
</validator>
</extension>
</plugin>
\ No newline at end of file
Modified: trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestSynchronizationValidator.java
===================================================================
--- trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestSynchronizationValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestSynchronizationValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -188,4 +188,16 @@
public boolean isEnabled(IProject project) {
return shouldValidate(project);
}
+
+ @Override
+ public void setProblemType(String problemType) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public void registerPreferenceInfo() {
+ // TODO Auto-generated method stub
+
+ }
}
\ No newline at end of file
Modified: trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestValidator.java
===================================================================
--- trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/common/tests/org.jboss.tools.common.validation.test/src/org/jboss/tools/common/validation/test/TestValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -97,12 +97,7 @@
}
@Override
- public String getMarkerType() {
- return ValidationErrorManager.DEFAULT_VALIDATION_MARKER;
- }
-
- @Override
- protected void registerPreferenceInfo() {
+ public void registerPreferenceInfo() {
// TODO Auto-generated method stub
}
Modified: trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -18,7 +18,8 @@
<validator
class="org.jboss.tools.esb.validator.ESBCoreValidator"
name="%ESBCoreValidator"
- id="org.jboss.tools.esb.validator.ESBCoreValidator">
+ id="org.jboss.tools.esb.validator.ESBCoreValidator"
+ problemType="org.jboss.tools.esb.validator.esbproblem">
</validator>
</extension>
Modified: trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBCoreValidator.java
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBCoreValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBCoreValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -49,7 +49,6 @@
public class ESBCoreValidator extends ESBValidationErrorManager implements IValidator {
public static final String ID = "org.jboss.tools.esb.validator.ESBCoreValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.esb.validator.esbproblem"; //$NON-NLS-1$
public static final String PREFERENCE_PAGE_ID = "org.jboss.tools.esb.validator.ui.ESBValidatorPreferencePage"; //$NON-NLS-1$
public static final String PROPERTY_PAGE_ID = "org.jboss.tools.esb.validator.ui.propertyPages.ESBValidatorPreferencePage"; //$NON-NLS-1$
@@ -60,15 +59,6 @@
String projectName;
Map<IProject, IProjectValidationContext> contexts = new HashMap<IProject, IProjectValidationContext>();
- /*
- * (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- @Override
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
public String getId() {
return ID;
}
@@ -424,10 +414,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new ESBPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new ESBPreferenceInfo());
}
class ESBPreferenceInfo implements IPreferenceInfo{
@@ -446,7 +434,6 @@
public String getPluginId() {
return ESBCorePlugin.PLUGIN_ID;
}
-
}
}
Modified: trunk/jsf/plugins/org.jboss.tools.jsf/plugin.xml
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jsf/plugins/org.jboss.tools.jsf/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -517,7 +517,8 @@
<validator
class="org.jboss.tools.jsf.web.validation.composite.CompositeComponentValidator"
name="%ComponentCompositeValidator"
- id="org.jboss.tools.jsf.CompositeComponentValidator">
+ id="org.jboss.tools.jsf.CompositeComponentValidator"
+ problemType="org.jboss.tools.jsf.compositeproblem">
</validator>
</extension>
@@ -526,7 +527,8 @@
<validator
class="org.jboss.tools.jsf.web.validation.FacesConfigValidator"
name="%FacesConfigValidator"
- id="org.jboss.tools.jsf.web.validation.FacesConfigValidator">
+ id="org.jboss.tools.jsf.web.validation.FacesConfigValidator"
+ problemType="org.jboss.tools.jsf.facesconfigproblem">
</validator>
</extension>
Modified: trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/FacesConfigValidator.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/FacesConfigValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/FacesConfigValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -74,7 +74,6 @@
*/
public class FacesConfigValidator extends ValidationErrorManager implements IValidator, JSFConstants {
public static final String ID = "org.jboss.tools.esb.validator.ESBCoreValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.jsf.facesconfigproblem"; //$NON-NLS-1$
public static final String PREFERENCE_PAGE_ID = CompositeComponentValidator.PREFERENCE_PAGE_ID;
public static final String PROPERTY_PAGE_ID = CompositeComponentValidator.PROPERTY_PAGE_ID;
@@ -180,15 +179,6 @@
addCheck(new JSFCheckToViewId(this), new String[]{ENT_NAVIGATION_CASE, ENT_NAVIGATION_CASE_20, ENT_NAVIGATION_RULE, ENT_NAVIGATION_RULE_20});
}
- /*
- * (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- @Override
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
public String getId() {
return ID;
}
@@ -432,10 +422,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new JSFPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new JSFPreferenceInfo());
}
class JSFPreferenceInfo implements IPreferenceInfo{
Modified: trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/composite/CompositeComponentValidator.java
===================================================================
--- trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/composite/CompositeComponentValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/web/validation/composite/CompositeComponentValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -66,7 +66,6 @@
public class CompositeComponentValidator extends WebValidator {
public static final String ID = "org.jboss.tools.jsf.CompositeComponentValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.jsf.compositeproblem"; //$NON-NLS-1$
public static final String SHORT_ID = "jboss.jsf.core"; //$NON-NLS-1$
public static final String PREFERENCE_PAGE_ID = "org.jboss.tools.jsf.ui.preferences.JSFValidationPreferencePage"; //$NON-NLS-1$
public static final String PROPERTY_PAGE_ID = "org.jboss.tools.jsf.ui.propertyPages.JSFValidationPreferencePage"; //$NON-NLS-1$
@@ -351,14 +350,6 @@
return JSFSeverityPreferences.getMaxNumberOfProblemMarkersPerFile(project);
}
- /*
- * (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
public IMarker addError(String message, String preferenceKey,
String[] messageArguments, int length, int offset, IResource target, int messageId) {
IMarker marker = addError(message, preferenceKey, messageArguments, length, offset, target);
@@ -392,10 +383,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new CompositeComponentPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new CompositeComponentPreferenceInfo());
}
class CompositeComponentPreferenceInfo implements IPreferenceInfo{
Modified: trunk/jsf/tests/org.jboss.tools.jsf.test/src/org/jboss/tools/jsf/test/validation/ELValidatorTest.java
===================================================================
--- trunk/jsf/tests/org.jboss.tools.jsf.test/src/org/jboss/tools/jsf/test/validation/ELValidatorTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jsf/tests/org.jboss.tools.jsf.test/src/org/jboss/tools/jsf/test/validation/ELValidatorTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -34,6 +34,7 @@
public class ELValidatorTest extends AbstractResourceMarkerTest{
public static final String MARKER_TYPE = "org.eclipse.wst.validation.problemmarker";
+ public static final String EL_VALIDATOR_MARKER_TYPE = "org.jboss.tools.jst.web.kb.elproblem";
protected void setUp() throws Exception {
// JobUtils.waitForIdle();
@@ -100,7 +101,7 @@
14);
IFile file = project.getFile("WebContent/testElRevalidation.xhtml");
- file.deleteMarkers(ELValidator.PROBLEM_TYPE, true, IResource.DEPTH_ZERO);
+ file.deleteMarkers(EL_VALIDATOR_MARKER_TYPE, true, IResource.DEPTH_ZERO);
assertMarkerIsNotCreatedForLine(
"WebContent/testElRevalidation.xhtml",
@@ -211,7 +212,7 @@
for (int i = 8; i < 108; i++) {
lines[i-8]=i;
}
- assertMarkerIsCreated(file, ELValidator.PROBLEM_TYPE, messagePattern, lines);
+ assertMarkerIsCreated(file, EL_VALIDATOR_MARKER_TYPE, messagePattern, lines);
time = validateFile("WebContent/pages/lineNumbers.xhtml", 100);
System.out.println("Validation time: " + time);
} finally {
Modified: trunk/jst/plugins/org.jboss.tools.jst.web/plugin.xml
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jst/plugins/org.jboss.tools.jst.web/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -339,7 +339,8 @@
<validator
class="org.jboss.tools.jst.web.validation.WebXMLCoreValidator"
name="%WebXMLCoreValidator"
- id="org.jboss.tools.jst.web.validation.WebXMLCoreValidator">
+ id="org.jboss.tools.jst.web.validation.WebXMLCoreValidator"
+ problemType="org.jboss.tools.jst.web.webxmlproblem">
</validator>
</extension>
Modified: trunk/jst/plugins/org.jboss.tools.jst.web/src/org/jboss/tools/jst/web/validation/WebXMLCoreValidator.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web/src/org/jboss/tools/jst/web/validation/WebXMLCoreValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jst/plugins/org.jboss.tools.jst.web/src/org/jboss/tools/jst/web/validation/WebXMLCoreValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -52,7 +52,6 @@
*/
public class WebXMLCoreValidator extends ValidationErrorManager implements IValidator {
public static final String ID = "org.jboss.tools.esb.validator.ESBCoreValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.jst.web.webxmlproblem"; //$NON-NLS-1$
public static final String PREFERENCE_PAGE_ID = "org.jboss.tools.jst.web.ui.WebXMLValidatorPreferencePage"; //$NON-NLS-1$
public static final String PROPERTY_PAGE_ID = "org.jboss.tools.jst.web.ui.propertyPages.WebXMLValidatorPreferencePage"; //$NON-NLS-1$
@@ -141,15 +140,6 @@
"WebAppRunAs", "WebAppRoleName");
}
- /*
- * (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- @Override
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
public String getId() {
return ID;
}
@@ -289,10 +279,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new WebXMLPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new WebXMLPreferenceInfo());
}
class WebXMLPreferenceInfo implements IPreferenceInfo{
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.kb/plugin.xml
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.kb/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.kb/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -183,7 +183,8 @@
class="org.jboss.tools.jst.web.kb.internal.validation.ELValidator"
id="org.jboss.tools.jst.web.kb.ELValidator"
name="%ELValidator"
- dependent="true">
+ dependent="true"
+ problemType="org.jboss.tools.jst.web.kb.elproblem">
</validator>
</extension>
Modified: trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/internal/validation/ELValidator.java
===================================================================
--- trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/internal/validation/ELValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jst/plugins/org.jboss.tools.jst.web.kb/src/org/jboss/tools/jst/web/kb/internal/validation/ELValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -82,7 +82,6 @@
public class ELValidator extends WebValidator implements IStringValidator {
public static final String ID = "org.jboss.tools.jst.web.kb.ELValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.jst.web.kb.elproblem"; //$NON-NLS-1$
public static final String PREFERENCE_PAGE_ID = "org.jboss.tools.jst.web.ui.preferences.ELValidatorPreferencePage"; //$NON-NLS-1$
public static final String PROPERTY_PAGE_ID = "org.jboss.tools.jst.web.ui.properties.ELValidatorPreferencePage"; //$NON-NLS-1$
@@ -123,15 +122,6 @@
/*
* (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- @Override
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
- /*
- * (non-Javadoc)
* @see org.jboss.tools.jst.web.kb.validation.IValidator#isEnabled(org.eclipse.core.resources.IProject)
*/
public boolean isEnabled(IProject project) {
@@ -273,7 +263,7 @@
validateEL(elReference, true, elContext);
}
if(reporter instanceof ITypedReporter) {
- ((ITypedReporter)reporter).addTypeForRegion(getMarkerType());
+ ((ITypedReporter)reporter).addTypeForRegion(getProblemType());
}
}
@@ -672,10 +662,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new ELPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new ELPreferenceInfo());
}
class ELPreferenceInfo implements IPreferenceInfo{
Modified: trunk/jst/tests/org.jboss.tools.jst.web.kb.test/plugin.xml
===================================================================
--- trunk/jst/tests/org.jboss.tools.jst.web.kb.test/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jst/tests/org.jboss.tools.jst.web.kb.test/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -8,7 +8,8 @@
class="org.jboss.tools.jst.web.kb.test.validation.TestValidator"
id="org.jboss.tools.jst.web.kb.test.TestValidator"
name="Test Validator"
- dependent="true">
+ dependent="true"
+ problemType="org.eclipse.wst.validation.problemmarker">
</validator>
</extension>
Modified: trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/validation/TestValidator.java
===================================================================
--- trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/validation/TestValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/validation/TestValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -106,4 +106,16 @@
validated = true;
return OK_STATUS;
}
+
+ @Override
+ public void setProblemType(String problemType) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public void registerPreferenceInfo() {
+ // TODO Auto-generated method stub
+
+ }
}
\ No newline at end of file
Modified: trunk/jst/tests/org.jboss.tools.jst.web.test/src/org/jboss/tools/jst/web/test/WebXMLValidationTest.java
===================================================================
--- trunk/jst/tests/org.jboss.tools.jst.web.test/src/org/jboss/tools/jst/web/test/WebXMLValidationTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/jst/tests/org.jboss.tools.jst.web.test/src/org/jboss/tools/jst/web/test/WebXMLValidationTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -22,7 +22,6 @@
import org.eclipse.osgi.util.NLS;
import org.jboss.tools.common.base.test.validation.TestUtil;
import org.jboss.tools.common.validation.ValidatorManager;
-import org.jboss.tools.jst.web.validation.WebXMLCoreValidator;
import org.jboss.tools.jst.web.validation.WebXMLValidatorMessages;
import org.jboss.tools.jst.web.webapp.model.WebAppConstants;
import org.jboss.tools.test.util.JobUtils;
@@ -34,7 +33,7 @@
* @author Alexey Kazakov
*/
public class WebXMLValidationTest extends TestCase {
-
+ public static final String PROBLEM_TYPE = "org.jboss.tools.jst.web.webxmlproblem";
private IProject project;
/* (non-Javadoc)
@@ -65,7 +64,7 @@
String path0 = "WebContent/WEB-INF/web.xml";
IFile webxml = project.getFile(path0);
assertTrue(webxml.exists());
- IMarker[] markers = webxml.findMarkers(WebXMLCoreValidator.PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
+ IMarker[] markers = webxml.findMarkers(PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
assertTrue(markers.length > 0);
//Now we will copy that original web.xml to different folders and check incremental validation.
@@ -74,7 +73,7 @@
String path1 = "aFolder/WEB-INF/web.xml";
IFile webxml1 = project.getFile(path1);
replaceFile(project, path0, path1);
- markers = webxml1.findMarkers(WebXMLCoreValidator.PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
+ markers = webxml1.findMarkers(PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
assertTrue(markers.length > 0);
for (IMarker m: markers) {
System.out.println(m.getAttribute(IMarker.MESSAGE));
@@ -84,7 +83,7 @@
String path2 = "target/m2e-wtp/web-resources/WEB-INF/web.xml";
IFile webxml2 = project.getFile(path2);
replaceFile(project, path0, path2);
- markers = webxml2.findMarkers(WebXMLCoreValidator.PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
+ markers = webxml2.findMarkers(PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
assertTrue(markers.length == 0);
}
@@ -99,13 +98,13 @@
String path1 = "WebContent/WEB-INF/web.xml.loginconfigtest1";
replaceFile(project, path1, path0);
- IMarker[] markers = webxml.findMarkers(WebXMLCoreValidator.PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
+ IMarker[] markers = webxml.findMarkers(PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
assertFalse(hasMarkerOnLine(markers, 18));
assertTrue(hasMarkerOnLine(markers, 19));
String path2 = "WebContent/WEB-INF/web.xml.loginconfigtest2";
replaceFile(project, path2, path0);
- markers = webxml.findMarkers(WebXMLCoreValidator.PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
+ markers = webxml.findMarkers(PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
assertTrue(hasMarkerOnLine(markers, 18));
assertFalse(hasMarkerOnLine(markers, 19));
@@ -129,7 +128,7 @@
public void testServletMapping() throws CoreException {
IFile webxml = project.getFile("WebContent/WEB-INF/webJAXFX.xml");
- IMarker[] markers = webxml.findMarkers(WebXMLCoreValidator.PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
+ IMarker[] markers = webxml.findMarkers(PROBLEM_TYPE, false, IResource.DEPTH_ZERO);
//1. If servlet-mapping/servlet-name=javax.ws.rs.core.Application, it is ok.
assertFalse(hasMarkerOnLine(markers, 6));
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/plugin.xml
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -590,7 +590,8 @@
<validator
class="org.jboss.tools.seam.internal.core.validation.SeamCoreValidator"
name="%SeamCoreValidator"
- id="org.jboss.tools.seam.core.CoreValidator">
+ id="org.jboss.tools.seam.core.CoreValidator"
+ problemType="org.jboss.tools.seam.core.seamproblem">
</validator>
</extension>
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamCoreValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -89,7 +89,6 @@
*/
public class SeamCoreValidator extends SeamValidationErrorManager implements IValidator {
public static final String ID = "org.jboss.tools.seam.core.CoreValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.seam.core.seamproblem"; //$NON-NLS-1$
public static final int NONUNIQUE_COMPONENT_NAME_MESSAGE_ID = 1;
public static final int DUPLICATE_REMOVE_MESSAGE_ID = 2;
@@ -112,15 +111,6 @@
/*
* (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- @Override
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
- /*
- * (non-Javadoc)
* @see org.jboss.tools.jst.web.kb.validation.IValidator#getId()
*/
public String getId() {
@@ -1117,10 +1107,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new SeamPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new SeamPreferenceInfo());
}
class SeamPreferenceInfo implements IPreferenceInfo{
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamProjectPropertyValidator.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamProjectPropertyValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/validation/SeamProjectPropertyValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -115,11 +115,6 @@
}
@Override
- public String getMarkerType() {
- return ValidationErrorManager.DEFAULT_VALIDATION_MARKER;
- }
-
- @Override
protected void registerPreferenceInfo() {
// TODO Auto-generated method stub
Modified: trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/validation/SeamProjectPropertyValidatorWrapper.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/validation/SeamProjectPropertyValidatorWrapper.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/seam/tests/org.jboss.tools.seam.core.test/src/org/jboss/tools/seam/core/test/validation/SeamProjectPropertyValidatorWrapper.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -92,11 +92,6 @@
}
@Override
- public String getMarkerType() {
- return ValidationErrorManager.DEFAULT_VALIDATION_MARKER;
- }
-
- @Override
protected void registerPreferenceInfo() {
// TODO Auto-generated method stub
@@ -221,4 +216,16 @@
IReporter reporter, boolean asYouTypeValidation) {
this.init(project, validationHelper, validationContext, manager, reporter, false);
}
+
+ @Override
+ public void setProblemType(String problemType) {
+ // TODO Auto-generated method stub
+
+ }
+
+ @Override
+ public void registerPreferenceInfo() {
+ // TODO Auto-generated method stub
+
+ }
}
\ No newline at end of file
Modified: trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/marker/SeamMarkerResolutionTest.java
===================================================================
--- trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/marker/SeamMarkerResolutionTest.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/seam/tests/org.jboss.tools.seam.ui.test/src/org/jboss/tools/seam/ui/test/marker/SeamMarkerResolutionTest.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -37,7 +37,7 @@
*
*/
public class SeamMarkerResolutionTest extends TestCase {
-
+ public static final String PROBLEM_TYPE = "org.jboss.tools.seam.core.seamproblem";
private IProject project;
@Override
@@ -80,7 +80,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatefulDuplicateRemoveComponent.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.DUPLICATE_REMOVE_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -91,7 +91,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatefulDuplicateDestroyComponent.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.DUPLICATE_DESTROY_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -102,7 +102,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatelessClass.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.DUPLICATE_DESTROY_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -113,7 +113,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatefulDuplicateCreateComponent.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.DUPLICATE_CREATE_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -124,7 +124,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatefulDuplicateUnwrapComponent.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.DUPLICATE_UNWRAP_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -135,7 +135,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/NonComponentWithCreateMethod.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.CREATE_DOESNT_BELONG_TO_COMPONENT_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -146,7 +146,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/NonComponentWithCreateMethod.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.CREATE_DOESNT_BELONG_TO_COMPONENT_MESSAGE_ID,
AddAnnotationMarkerResolution.class);
@@ -157,7 +157,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/NonComponentWithUnwrapMethod.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.UNWRAP_DOESNT_BELONG_TO_COMPONENT_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -168,7 +168,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/NonComponentWithUnwrapMethod.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.UNWRAP_DOESNT_BELONG_TO_COMPONENT_MESSAGE_ID,
AddAnnotationMarkerResolution.class);
@@ -179,7 +179,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/NonComponentWithObserverMethod.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.OBSERVER_DOESNT_BELONG_TO_COMPONENT_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -190,7 +190,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/NonComponentWithObserverMethod.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.OBSERVER_DOESNT_BELONG_TO_COMPONENT_MESSAGE_ID,
AddAnnotationMarkerResolution.class);
@@ -201,7 +201,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/DuplicateComponent1.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.NONUNIQUE_COMPONENT_NAME_MESSAGE_ID,
DeleteAnnotationMarkerResolution.class);
@@ -212,7 +212,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/DuplicateComponent1.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.NONUNIQUE_COMPONENT_NAME_MESSAGE_ID,
RenameAnnotationMarkerResolution.class);
@@ -223,7 +223,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatefulComponentWithoutRemove.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.STATEFUL_COMPONENT_DOES_NOT_CONTAIN_REMOVE_ID,
AddAnnotatedMethodMarkerResolution.class);
@@ -234,7 +234,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatefulComponentWithoutDestroy.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.STATEFUL_COMPONENT_DOES_NOT_CONTAIN_DESTROY_ID,
AddAnnotatedMethodMarkerResolution.class);
@@ -245,7 +245,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/session/StatefulComponentWithWrongScope.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.STATEFUL_COMPONENT_WRONG_SCOPE_ID,
ChangeScopeMarkerResolution.class);
@@ -256,7 +256,7 @@
new String[]{
"src/action/org/domain/SeamWebWarTestProject/entity/EntityComponentWithWrongScope.java"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.ENTITY_COMPONENT_WRONG_SCOPE_ID,
ChangeScopeMarkerResolution.class);
@@ -267,7 +267,7 @@
new String[]{
"WebContent/WEB-INF/components.xml"
},
- SeamCoreValidator.PROBLEM_TYPE,
+ PROBLEM_TYPE,
SeamCoreValidator.MESSAGE_ID_ATTRIBUTE_NAME,
SeamCoreValidator.UNKNOWN_COMPONENT_PROPERTY_ID,
AddSetterMarkerResolution.class);
Modified: trunk/struts/plugins/org.jboss.tools.struts/plugin.xml
===================================================================
--- trunk/struts/plugins/org.jboss.tools.struts/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/struts/plugins/org.jboss.tools.struts/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -425,7 +425,8 @@
<validator
class="org.jboss.tools.struts.validation.StrutsCoreValidator"
name="%StrutsCoreValidator"
- id="org.jboss.tools.struts.validation.StrutsCoreValidator">
+ id="org.jboss.tools.struts.validation.StrutsCoreValidator"
+ problemType="org.jboss.tools.struts.strutsproblem">
</validator>
</extension>
Modified: trunk/struts/plugins/org.jboss.tools.struts/src/org/jboss/tools/struts/validation/StrutsCoreValidator.java
===================================================================
--- trunk/struts/plugins/org.jboss.tools.struts/src/org/jboss/tools/struts/validation/StrutsCoreValidator.java 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/struts/plugins/org.jboss.tools.struts/src/org/jboss/tools/struts/validation/StrutsCoreValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -53,7 +53,6 @@
*/
public class StrutsCoreValidator extends ValidationErrorManager implements IValidator, StrutsConstants {
public static final String ID = "org.jboss.tools.struts.validation.StrutsCoreValidator"; //$NON-NLS-1$
- public static final String PROBLEM_TYPE = "org.jboss.tools.struts.strutsproblem"; //$NON-NLS-1$
public static final String PREFERENCE_PAGE_ID = "org.jboss.tools.struts.ui.StrutsValidatorPreferencePage"; //$NON-NLS-1$
public static final String PROPERTY_PAGE_ID = "org.jboss.tools.struts.ui.propertyPages.StrutsValidatorPreferencePage"; //$NON-NLS-1$
@@ -121,15 +120,6 @@
ENT_STRUTSCONFIG + VER_SUFFIX_10, ENT_STRUTSCONFIG + VER_SUFFIX_11, ENT_STRUTSCONFIG + VER_SUFFIX_12);
}
- /*
- * (non-Javadoc)
- * @see org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getMarkerType()
- */
- @Override
- public String getMarkerType() {
- return PROBLEM_TYPE;
- }
-
public String getId() {
return ID;
}
@@ -274,10 +264,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(PROBLEM_TYPE, new StrutsPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new StrutsPreferenceInfo());
}
class StrutsPreferenceInfo implements IPreferenceInfo{
Modified: trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/plugin.xml
===================================================================
--- trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/plugin.xml 2012-09-28 00:13:40 UTC (rev 44107)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/plugin.xml 2012-09-28 00:35:24 UTC (rev 44108)
@@ -94,7 +94,8 @@
<validator
class="org.jboss.tools.ws.jaxrs.core.internal.metamodel.validation.JaxrsMetamodelValidator"
id="org.jboss.tools.ws.jaxrs.JaxrsMetamodelValidator"
- name="%VALIDATOR_NAME">
+ name="%VALIDATOR_NAME"
+ problemType="org.jboss.tools.ws.jaxrs.metamodelMarker">
</validator>
</extension>
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-09-28 00:13:40 UTC (rev 44107)
+++ trunk/ws/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsMetamodelValidator.java 2012-09-28 00:35:24 UTC (rev 44108)
@@ -277,11 +277,6 @@
}
@Override
- public String getMarkerType() {
- return JAXRS_PROBLEM_TYPE;
- }
-
- @Override
public String getId() {
return ID;
}
@@ -297,10 +292,8 @@
}
@Override
- protected void registerPreferenceInfo() {
- if(PreferenceInfoManager.getPreferenceInfo(JAXRS_PROBLEM_TYPE) == null){
- PreferenceInfoManager.register(JAXRS_PROBLEM_TYPE, new JaxrsPreferenceInfo());
- }
+ public void registerPreferenceInfo() {
+ PreferenceInfoManager.register(getProblemType(), new JaxrsPreferenceInfo());
}
class JaxrsPreferenceInfo implements IPreferenceInfo{
More information about the jbosstools-commits
mailing list