Author: scabanovich
Date: 2010-04-23 08:42:17 -0400 (Fri, 23 Apr 2010)
New Revision: 21632
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/.classpath
trunk/esb/plugins/org.jboss.tools.esb.validator/.cvsignore
trunk/esb/plugins/org.jboss.tools.esb.validator/.options.template
trunk/esb/plugins/org.jboss.tools.esb.validator/.project
trunk/esb/plugins/org.jboss.tools.esb.validator/.settings/
trunk/esb/plugins/org.jboss.tools.esb.validator/META-INF/
trunk/esb/plugins/org.jboss.tools.esb.validator/META-INF/MANIFEST.MF
trunk/esb/plugins/org.jboss.tools.esb.validator/about.html
trunk/esb/plugins/org.jboss.tools.esb.validator/build.properties
trunk/esb/plugins/org.jboss.tools.esb.validator/images/
trunk/esb/plugins/org.jboss.tools.esb.validator/images/esb/
trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.properties
trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml
trunk/esb/plugins/org.jboss.tools.esb.validator/plugin_ja.properties
trunk/esb/plugins/org.jboss.tools.esb.validator/resources/
trunk/esb/plugins/org.jboss.tools.esb.validator/src/
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/
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/ESBPreferenceInitializer.java
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferences.java
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidationErrorManager.java
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorMessages.java
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorPlugin.java
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages.properties
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages_ja.properties
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBConfigurationBlock.java
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.java
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.properties
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBValidatorPreferencePage.java
Log:
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/.classpath
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/.classpath
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/.classpath 2010-04-23 12:42:17 UTC
(rev 21632)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con"
path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
+ <classpathentry kind="con"
path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="src" path="src/"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/.classpath
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/.cvsignore
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/.cvsignore
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/.cvsignore 2010-04-23 12:42:17 UTC
(rev 21632)
@@ -0,0 +1,4 @@
+bin
+meta
+yguard.log
+.options
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/.cvsignore
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/.options.template
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/.options.template
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/.options.template 2010-04-23 12:42:17
UTC (rev 21632)
@@ -0,0 +1 @@
+org.jboss.tools.seam.xml/debug=true
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/.project
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/.project (rev
0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/.project 2010-04-23 12:42:17 UTC (rev
21632)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+ <name>org.jboss.tools.esb.validator</name>
+ <comment></comment>
+ <projects>
+ </projects>
+ <buildSpec>
+ <buildCommand>
+ <name>org.eclipse.jdt.core.javabuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.ManifestBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ <buildCommand>
+ <name>org.eclipse.pde.SchemaBuilder</name>
+ <arguments>
+ </arguments>
+ </buildCommand>
+ </buildSpec>
+ <natures>
+ <nature>org.eclipse.jdt.core.javanature</nature>
+ <nature>org.eclipse.pde.PluginNature</nature>
+ </natures>
+</projectDescription>
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/.project
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/META-INF/MANIFEST.MF
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/META-INF/MANIFEST.MF
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/META-INF/MANIFEST.MF 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,20 @@
+Manifest-Version: 1.0
+Bundle-ActivationPolicy: lazy
+Bundle-Name: %pluginName
+Bundle-Activator: org.jboss.tools.esb.validator.ESBValidatorPlugin
+Bundle-ManifestVersion: 2
+Bundle-Vendor: %providerName
+Bundle-SymbolicName: org.jboss.tools.esb.validator;singleton:=true
+Bundle-Localization: plugin
+Export-Package: org.jboss.tools.esb.validator,
+ org.jboss.tools.esb.validator.ui
+Require-Bundle: org.jboss.tools.jst.web;visibility:=reexport,
+ org.jboss.tools.common.ui,
+ org.jboss.tools.jst.web.kb,
+ org.jboss.tools.esb.core,
+ org.eclipse.ui,
+ org.jboss.tools.esb.project.core,
+ org.eclipse.wst.validation,
+ org.eclipse.jdt.ui
+Bundle-Version: 2.0.0
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/META-INF/MANIFEST.MF
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/about.html
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/about.html
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/about.html 2010-04-23 12:42:17 UTC
(rev 21632)
@@ -0,0 +1,34 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<HTML>
+
+<head>
+<title>About</title>
+<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
+</head>
+
+<BODY lang="EN-US">
+
+<H3>About This Content</H3>
+
+<P>©2007 Red Hat, Inc. All rights reserved</P>
+
+<H3>License</H3>
+
+<P>Red Hat Inc., through its JBoss division, makes available all content in this
plug-in
+("Content"). Unless otherwise indicated below, the Content is provided to you
+under the terms and conditions of the Eclipse Public License Version 1.0
+("EPL"). A copy of the EPL is available at
+<A
href="http://www.eclipse.org/org/documents/epl-v10.php">http...;.
+For purposes of the EPL, "Program" will mean the Content.</P>
+
+<P>If you did not receive this Content directly from Red Hat Inc., the
+Content is being redistributed by another party ("Redistributor") and different
+terms and conditions may apply to your use of any object code in the Content.
+Check the Redistributor's license that was provided with the Content. If no such
+license exists, contact the Redistributor. Unless otherwise indicated below, the
+terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at
+ <A
href="http://www.jboss.org/tools">http://www.jboss.org/tools...
+
+</BODY>
+</HTML>
\ No newline at end of file
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/about.html
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/build.properties
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/build.properties
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/build.properties 2010-04-23 12:42:17
UTC (rev 21632)
@@ -0,0 +1,15 @@
+source.. = src/
+bin.includes = plugin.xml,\
+ META-INF/,\
+ plugin.properties,\
+ about.html,\
+ .,\
+ images/
+jars.compile.order = .
+src.includes = src/,\
+ images/,\
+ plugin.xml,\
+ plugin.properties,\
+ build.properties,\
+ about.html,\
+ META-INF/
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/build.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.properties
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.properties
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.properties 2010-04-23 12:42:17
UTC (rev 21632)
@@ -0,0 +1,4 @@
+providerName=JBoss by Red Hat
+pluginName=ESB Validator Plugin
+
+PreferencePage_Validator=ESB Validator
\ No newline at end of file
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml 2010-04-23 12:42:17 UTC
(rev 21632)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.0"?>
+<plugin>
+
+ <extension point="org.eclipse.core.runtime.preferences">
+ <initializer
class="org.jboss.tools.esb.validator.ESBPreferenceInitializer"/>
+ </extension>
+
+ <extension
+ point="org.jboss.tools.jst.web.kb.validator">
+ <validator
+ class="org.jboss.tools.esb.validator.ESBCoreValidator"
+ id="org.jboss.tools.esb.validator.ESBCoreValidator">
+ </validator>
+ </extension>
+
+ <extension point="org.eclipse.ui.preferencePages">
+ <page
+ category="org.jboss.tools.common.model.ui.MainPreferencePage"
+ class="org.jboss.tools.esb.validator.ui.ESBValidatorPreferencePage"
+ id="org.jboss.tools.esb.validator.ui.ESBValidatorPreferencePage"
+ name="%PreferencePage_Validator">
+ </page>
+ </extension>
+
+
+</plugin>
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/plugin.xml
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/esb/plugins/org.jboss.tools.esb.validator/plugin_ja.properties
===================================================================
--- trunk/esb/plugins/org.jboss.tools.esb.validator/plugin_ja.properties
(rev 0)
+++ trunk/esb/plugins/org.jboss.tools.esb.validator/plugin_ja.properties 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,2 @@
+providerName=JBoss by Red Hat
+pluginName=ESB \u30B3\u30A2\u30FB\u30D7\u30E9\u30B0\u30A4\u30F3
Property changes on: trunk/esb/plugins/org.jboss.tools.esb.validator/plugin_ja.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
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
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBCoreValidator.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,225 @@
+package org.jboss.tools.esb.validator;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.TreeSet;
+
+import org.eclipse.core.resources.IFile;
+import org.eclipse.core.resources.IFolder;
+import org.eclipse.core.resources.IMarker;
+import org.eclipse.core.resources.IProject;
+import org.eclipse.core.resources.IResource;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.wst.validation.internal.core.ValidationException;
+import org.eclipse.wst.validation.internal.provisional.core.IReporter;
+import org.jboss.tools.common.model.XModelObject;
+import org.jboss.tools.common.model.util.EclipseResourceUtil;
+import org.jboss.tools.common.model.util.PositionSearcher;
+import org.jboss.tools.common.text.ITextSourceReference;
+import org.jboss.tools.esb.core.ESBProjectConstant;
+import org.jboss.tools.esb.core.facet.IJBossESBFacetDataModelProperties;
+import org.jboss.tools.esb.core.model.ESBConstants;
+import org.jboss.tools.jst.web.kb.internal.validation.ContextValidationHelper;
+import org.jboss.tools.jst.web.kb.internal.validation.ProjectValidationContext;
+import org.jboss.tools.jst.web.kb.internal.validation.ValidatingProjectSet;
+import org.jboss.tools.jst.web.kb.internal.validation.ValidatorManager;
+import org.jboss.tools.jst.web.kb.validation.IValidatingProjectSet;
+import org.jboss.tools.jst.web.kb.validation.IValidationContext;
+import org.jboss.tools.jst.web.kb.validation.IValidator;
+import org.jboss.tools.jst.web.model.project.ext.store.XMLValueInfo;
+
+public class ESBCoreValidator extends ESBValidationErrorManager implements IValidator {
+ public static final String ID =
"org.jboss.tools.esb.validator.ESBCoreValidator";
+
+ String projectName;
+ Map<IProject, IValidationContext> contexts = new HashMap<IProject,
IValidationContext>();
+
+ public String getId() {
+ return ID;
+ }
+
+ public IValidatingProjectSet getValidatingProjects(IProject project) {
+ IValidationContext rootContext = contexts.get(project);
+ if(rootContext == null) {
+ rootContext = new ProjectValidationContext();
+ contexts.put(project, rootContext);
+ }
+
+ List<IProject> projects = new ArrayList<IProject>();
+ projects.add(project);
+ return new ValidatingProjectSet(project, projects, rootContext);
+ }
+
+ public boolean shouldValidate(IProject project) {
+ String esbContentFolder = null;
+
+ try {
+ esbContentFolder =
project.getPersistentProperty(IJBossESBFacetDataModelProperties.QNAME_ESB_CONTENT_FOLDER);
+ } catch (CoreException e) {
+ //ignore
+ }
+
+ if(esbContentFolder != null) return true;
+
+ try {
+ return project != null && project.isAccessible() &&
project.hasNature(ESBProjectConstant.ESB_PROJECT_NATURE);
+ } catch (CoreException e) {
+ ESBValidatorPlugin.log(e);
+ }
+ return false;
+ }
+
+ /*
+ * (non-Javadoc)
+ * @see
org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#init(org.eclipse.core.resources.IProject,
org.jboss.tools.jst.web.kb.internal.validation.ContextValidationHelper,
org.jboss.tools.jst.web.kb.internal.validation.ValidatorManager,
org.eclipse.wst.validation.internal.provisional.core.IReporter,
org.jboss.tools.jst.web.kb.validation.IValidationContext)
+ */
+ @Override
+ public void init(IProject project, ContextValidationHelper validationHelper,
org.eclipse.wst.validation.internal.provisional.core.IValidator manager, IReporter
reporter) {
+ super.init(project, validationHelper, manager, reporter);
+// cdiProject = CDICorePlugin.getCDIProject(project, false);
+ projectName = project.getName();
+ }
+
+ public IStatus validate(Set<IFile> changedFiles, IProject project,
+ ContextValidationHelper validationHelper, ValidatorManager manager,
+ IReporter reporter) throws ValidationException {
+ init(project, validationHelper, manager, reporter);
+
+ for (IFile file: changedFiles) {
+ String name = file.getName();
+ if(!name.endsWith(".xml")) continue;
+ XModelObject o = EclipseResourceUtil.createObjectForResource(file);
+ if(o != null &&
o.getModelEntity().getName().startsWith(ESBConstants.ENT_ESB_FILE)) {
+ validateESBConfigFile(o, file);
+ }
+ }
+
+ return OK_STATUS;
+ }
+
+ private void validateESBConfigFile(XModelObject object, IFile file) {
+// System.out.println("Validate ESB Config " + file);
+ validateChannelIDRefs(object, file);
+ }
+
+ public IStatus validateAll(IProject project,
+ ContextValidationHelper validationHelper, ValidatorManager manager,
+ IReporter reporter) throws ValidationException {
+ init(project, validationHelper, manager, reporter);
+ displaySubtask(ESBValidatorMessages.VALIDATING_PROJECT, new String[]{projectName});
+
+ String esbContentFolder = null;
+
+ try {
+ esbContentFolder =
project.getPersistentProperty(IJBossESBFacetDataModelProperties.QNAME_ESB_CONTENT_FOLDER);
+ } catch (CoreException e) {
+ //ignore
+ }
+
+ if(esbContentFolder != null) {
+ IFolder esbContent = project.getFolder(new Path(esbContentFolder +
"/META-INF"));
+ if(esbContent != null && esbContent.exists()) {
+ IResource[] rs = null;
+ try {
+ rs = esbContent.members();
+ } catch (CoreException e) {
+ ESBValidatorPlugin.log(e);
+ }
+ for (IResource r: rs) {
+ if(r instanceof IFile) {
+ IFile file = (IFile)r;
+ String name = file.getName();
+ if(!name.endsWith(".xml")) continue;
+ XModelObject o = EclipseResourceUtil.createObjectForResource(file);
+ if(o != null &&
o.getModelEntity().getName().startsWith(ESBConstants.ENT_ESB_FILE)) {
+ validateESBConfigFile(o, file);
+ }
+ }
+ }
+ }
+ }
+
+ return OK_STATUS;
+ }
+
+
+ void validateChannelIDRefs(XModelObject object, IFile file) {
+ XModelObject servicesFolder = object.getChildByPath("Services");
+ if(servicesFolder == null) return;
+ Map<String, String> ids = getAllChannelRefIDs(object);
+ XModelObject[] services = servicesFolder.getChildren();
+ for (XModelObject service: services) {
+ XModelObject listenersFolder = service.getChildByPath("Listeners");
+ XModelObject[] listeners = listenersFolder.getChildren();
+ for (XModelObject listener: listeners) {
+ String channelIDRef = listener.getAttributeValue(ESBConstants.ATTR_BUS_ID_REF);
+ if(channelIDRef == null) continue;
+ String entity = ids.get(channelIDRef);
+ if(channelIDRef.length() == 0) {
+ //no id set, it is not an error
+ } else if(entity == null) {
+ //addError - no id found
+ IMarker marker =
addError(ESBValidatorMessages.LISTENER_REFERENCES_NON_EXISTENT_CHANNEL,
+ ESBPreferences.LISTENER_REFERENCES_NON_EXISTENT_CHANNEL,
getSourceReference(listener, ESBConstants.ATTR_BUS_ID_REF), file);
+ if(marker != null) try {
+ marker.setAttribute("path", listener.getPath());
+ marker.setAttribute("attribute", ESBConstants.ATTR_BUS_ID_REF);
+ } catch (CoreException e) {
+ e.printStackTrace();
+ }
+ } else {
+ String busEntityPrefix = getBusEntityPrefix(listener.getModelEntity().getName());
+ if(busEntityPrefix != null && !entity.startsWith(busEntityPrefix)) {
+ IMarker marker =
addError(ESBValidatorMessages.LISTENER_REFERENCES_INCOMPATIBLE_CHANNEL,
+ ESBPreferences.LISTENER_REFERENCES_INCOMPATIBLE_CHANNEL,
getSourceReference(listener, ESBConstants.ATTR_BUS_ID_REF), file);
+ if(marker != null) try {
+ marker.setAttribute("path", listener.getPath());
+ marker.setAttribute("attribute", ESBConstants.ATTR_BUS_ID_REF);
+ } catch (CoreException e) {
+ e.printStackTrace();
+ }
+ }
+ }
+ }
+ }
+ }
+ private String getBusEntityPrefix(String listenerEntity) {
+ if(listenerEntity == null) return null;
+ if(listenerEntity.startsWith("ESBListener")) {
+ return null;
+ }
+ if(listenerEntity.startsWith("ESBJCAGateway")) {
+ return "ESBJMSBus";
+ }
+ int i = listenerEntity.indexOf("Listener");
+ if(i < 0) return null;
+ return listenerEntity.substring(0, i) + "Bus";
+ }
+ //id - bus entity
+ private Map<String, String> getAllChannelRefIDs(XModelObject object) {
+ Map<String, String> result = new HashMap<String, String>();
+ XModelObject[] ps = object.getChildByPath("Providers").getChildren();
+ for (int i = 0; i < ps.length; i++) {
+ XModelObject[] cs = ps[i].getChildren();
+ for (int j = 0; j < cs.length; j++) {
+ if(cs[j].getModelEntity().getAttribute(ESBConstants.ATTR_BUS_ID) != null) {
+ String v = cs[j].getAttributeValue(ESBConstants.ATTR_BUS_ID);
+ if(v != null && v.length() > 0) {
+ result.put(v, cs[j].getModelEntity().getName());
+ }
+ }
+ }
+ }
+
+ return result;
+ }
+
+ ITextSourceReference getSourceReference(XModelObject o, String attr) {
+ return new XMLValueInfo(o, attr);
+ }
+}
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBCoreValidator.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferenceInitializer.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferenceInitializer.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferenceInitializer.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,35 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.validator;
+
+import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
+import org.eclipse.core.runtime.preferences.DefaultScope;
+import org.eclipse.core.runtime.preferences.IEclipsePreferences;
+import org.eclipse.core.runtime.preferences.IScopeContext;
+import org.jboss.tools.common.preferences.SeverityPreferences;
+
+/**
+ * @author Viacheslav Kabanovich
+ */
+public class ESBPreferenceInitializer extends AbstractPreferenceInitializer {
+
+ /* (non-Javadoc)
+ * @see
org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer#initializeDefaultPreferences()
+ */
+ @Override
+ public void initializeDefaultPreferences() {
+ IEclipsePreferences defaultPreferences = ((IScopeContext) new
DefaultScope()).getNode(ESBValidatorPlugin.PLUGIN_ID);
+ for (String name : ESBPreferences.SEVERITY_OPTION_NAMES) {
+ defaultPreferences.put(name, SeverityPreferences.ERROR);
+ }
+// defaultPreferences.put(CDIPreferences.DECORATOR_HAS_NAME, CDIPreferences.WARNING);
+ }
+}
\ No newline at end of file
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferenceInitializer.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferences.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferences.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferences.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,72 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.validator;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import org.eclipse.core.resources.IProject;
+import org.jboss.tools.common.preferences.SeverityPreferences;
+
+/**
+ * @author Alexey Kazakov
+ */
+public class ESBPreferences extends SeverityPreferences {
+
+ public static final Set<String> SEVERITY_OPTION_NAMES = new
HashSet<String>();
+
+ private static ESBPreferences INSTANCE = new ESBPreferences();
+
+ //Channel ID ref group
+
+ public static final String LISTENER_REFERENCES_NON_EXISTENT_CHANNEL =
INSTANCE.createSeverityOption("listenerReferencesNonExistentChannel");
//$NON-NLS-1
+ public static final String LISTENER_REFERENCES_INCOMPATIBLE_CHANNEL =
INSTANCE.createSeverityOption("listenerReferencesIncompatibleChannel");
//$NON-NLS-1
+
+ /**
+ * @return the only instance of CDIPreferences
+ */
+ public static ESBPreferences getInstance() {
+ return INSTANCE;
+ }
+
+ private ESBPreferences() {
+ }
+
+ /* (non-Javadoc)
+ * @see
org.jboss.tools.common.preferences.SeverityPreferences#createSeverityOption(java.lang.String)
+ */
+ @Override
+ protected String createSeverityOption(String shortName) {
+ String name = getPluginId() + ".validator.problem." + shortName;
//$NON-NLS-1$
+ SEVERITY_OPTION_NAMES.add(name);
+ return name;
+ }
+
+ /* (non-Javadoc)
+ * @see org.jboss.tools.common.preferences.SeverityPreferences#getPluginId()
+ */
+ @Override
+ protected String getPluginId() {
+ return ESBValidatorPlugin.PLUGIN_ID;
+ }
+
+ /* (non-Javadoc)
+ * @see org.jboss.tools.common.preferences.SeverityPreferences#getSeverityOptionNames()
+ */
+ @Override
+ protected Set<String> getSeverityOptionNames() {
+ return SEVERITY_OPTION_NAMES;
+ }
+
+ public static boolean shouldValidateCore(IProject project) {
+ return true;
+ }
+}
\ No newline at end of file
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBPreferences.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidationErrorManager.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidationErrorManager.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidationErrorManager.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,26 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.validator;
+
+import org.eclipse.core.resources.IProject;
+import org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager;
+
+public class ESBValidationErrorManager extends ValidationErrorManager {
+
+ /*
+ * (non-Javadoc)
+ * @see
org.jboss.tools.jst.web.kb.internal.validation.ValidationErrorManager#getPreference(org.eclipse.core.resources.IProject,
java.lang.String)
+ */
+ @Override
+ protected String getPreference(IProject project, String preferenceKey) {
+ return ESBPreferences.getInstance().getProjectPreference(project, preferenceKey);
+ }
+}
\ No newline at end of file
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidationErrorManager.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorMessages.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorMessages.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorMessages.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,29 @@
+/*******************************************************************************
+ * Copyright (c) 2007 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.validator;
+
+import org.eclipse.osgi.util.NLS;
+
+public class ESBValidatorMessages extends NLS {
+ private static final String BUNDLE_NAME =
"org.jboss.tools.esb.validator.messages"; //$NON-NLS-1$
+
+ public static String ESB_CORE_PLUGIN_NO_MESSAGE;
+
+ public static String VALIDATING_RESOURCE;
+ public static String VALIDATING_PROJECT;
+
+ public static String LISTENER_REFERENCES_NON_EXISTENT_CHANNEL;
+ public static String LISTENER_REFERENCES_INCOMPATIBLE_CHANNEL;
+
+ static {
+ NLS.initializeMessages(BUNDLE_NAME, ESBValidatorMessages.class);
+ }
+}
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorMessages.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorPlugin.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorPlugin.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorPlugin.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,52 @@
+/*******************************************************************************
+ * Copyright (c) 2007 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.validator;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+
+/**
+ */
+public class ESBValidatorPlugin extends AbstractUIPlugin {
+ public static final String PLUGIN_ID = "org.jboss.tools.esb.validator";
//$NON-NLS-1$
+
+ public ESBValidatorPlugin() {
+ super();
+ INSTANCE = this;
+ }
+
+ public static void log(String msg) {
+ if(isDebugEnabled()) INSTANCE.getLog().log(new Status(Status.INFO, PLUGIN_ID,
Status.OK, msg, null));
+ }
+
+ public static void log(IStatus status) {
+ if(isDebugEnabled() || !status.isOK()) INSTANCE.getLog().log(status);
+ }
+
+ public static void log(String message, Throwable exception) {
+ INSTANCE.getLog().log(new Status(Status.ERROR, PLUGIN_ID, Status.OK, message,
exception));
+ }
+
+ public static void log(Exception ex) {
+ INSTANCE.getLog().log(new Status(Status.ERROR, PLUGIN_ID, Status.OK,
ESBValidatorMessages.ESB_CORE_PLUGIN_NO_MESSAGE, ex));
+ }
+
+ public static boolean isDebugEnabled() {
+ return INSTANCE.isDebugging();
+ }
+
+ public static ESBValidatorPlugin getDefault() {
+ return INSTANCE;
+ }
+
+ static ESBValidatorPlugin INSTANCE = null;
+}
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ESBValidatorPlugin.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages.properties
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages.properties
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages.properties 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,6 @@
+ESB_CORE_PLUGIN_NO_MESSAGE=No message
+VALIDATING_RESOURCE=project "{0}"; resource "{1}"
+VALIDATING_PROJECT=project "{0}"
+
+LISTENER_REFERENCES_NON_EXISTENT_CHANNEL=Listener references non-existent channel
+LISTENER_REFERENCES_INCOMPATIBLE_CHANNEL=Listener references incompatible channel
\ No newline at end of file
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages_ja.properties
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages_ja.properties
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages_ja.properties 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1 @@
+ESB_CORE_PLUGIN_NO_MESSAGE=\u30E1\u30C3\u30BB\u30FC\u30B8\u304C\u3042\u308A\u307E\u305B\u3093
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/messages_ja.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBConfigurationBlock.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBConfigurationBlock.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBConfigurationBlock.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,72 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.validator.ui;
+
+import java.util.ArrayList;
+
+import org.eclipse.core.resources.IProject;
+import org.eclipse.jdt.internal.ui.wizards.IStatusChangeListener;
+import org.eclipse.jface.dialogs.IDialogSettings;
+import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
+import org.jboss.tools.common.ui.preferences.SeverityConfigurationBlock;
+import org.jboss.tools.esb.validator.ESBPreferences;
+import org.jboss.tools.esb.validator.ESBValidatorPlugin;
+
+/**
+ * @author Viacheslav Kabanovich
+ */
+public class ESBConfigurationBlock extends SeverityConfigurationBlock {
+
+ private static final String SETTINGS_SECTION_NAME =
"CDIValidatorConfigurationBlock";
+
+ private static SectionDescription SECTION_CHANNEL_ID_REF = new SectionDescription(
+ ESBPreferencesMessages.ESBValidatorConfigurationBlock_section_channelidref,
+ new String[][]{
+ {ESBPreferences.LISTENER_REFERENCES_NON_EXISTENT_CHANNEL,
ESBPreferencesMessages.ESBValidatorConfigurationBlock_pb_listenerReferencesNonExistentChannel_label},
+ {ESBPreferences.LISTENER_REFERENCES_INCOMPATIBLE_CHANNEL,
ESBPreferencesMessages.ESBValidatorConfigurationBlock_pb_listenerReferencesIncompatibleChannel_label},
+ },
+ ESBValidatorPlugin.PLUGIN_ID
+ );
+
+ private static SectionDescription[] ALL_SECTIONS = new SectionDescription[]{
+ SECTION_CHANNEL_ID_REF,
+ };
+
+ private static Key[] getKeys() {
+ ArrayList<Key> keys = new ArrayList<Key>();
+ for (int i = 0; i < ALL_SECTIONS.length; i++) {
+ for (int j = 0; j < ALL_SECTIONS[i].options.length; j++) {
+ keys.add(ALL_SECTIONS[i].options[j].key);
+ }
+ }
+ return keys.toArray(new Key[0]);
+ }
+
+ public ESBConfigurationBlock(IStatusChangeListener context,
+ IProject project, IWorkbenchPreferenceContainer container) {
+ super(context, project, getKeys(), container);
+ }
+
+ @Override
+ protected SectionDescription[] getAllSections() {
+ return ALL_SECTIONS;
+ }
+
+ @Override
+ protected String getCommonDescription() {
+ return ESBPreferencesMessages.ESBValidatorConfigurationBlock_common_description;
+ }
+
+ @Override
+ protected IDialogSettings getDialogSettings() {
+ return
ESBValidatorPlugin.getDefault().getDialogSettings().getSection(SETTINGS_SECTION_NAME);
+ }
+}
\ No newline at end of file
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBConfigurationBlock.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,35 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+
+package org.jboss.tools.esb.validator.ui;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * @author Viacheslav Kabanovich
+ */
+public class ESBPreferencesMessages extends NLS {
+ private static final String BUNDLE_NAME =
"org.jboss.tools.esb.validator.ui.ESBPreferencesMessages"; //$NON-NLS-1$
+
+ // Validator Preference page
+ public static String ESBValidatorConfigurationBlock_common_description;
+
+ // Section Name
+ public static String ESBValidatorConfigurationBlock_section_channelidref;
+ public static String
ESBValidatorConfigurationBlock_pb_listenerReferencesNonExistentChannel_label;
+ public static String
ESBValidatorConfigurationBlock_pb_listenerReferencesIncompatibleChannel_label;
+
+ public static String ESB_VALIDATOR_PREFERENCE_PAGE_ESB_VALIDATOR;
+
+ static {
+ NLS.initializeMessages(BUNDLE_NAME, ESBPreferencesMessages.class);
+ }
+}
\ No newline at end of file
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.properties
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.properties
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.properties 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,19 @@
+##################################################################################
+### Copyright (c) 2009 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,
+### and is available at
http://www.eclipse.org/legal/epl-v10.html
+###
+### Contributors:
+### Red Hat, Inc. - initial API and implementation
+##################################################################################
+
+ESBValidatorConfigurationBlock_common_description=Select the severity level for the
following optional ESB Validator problems:
+
+##Section Channel ID Ref
+ESBValidatorConfigurationBlock_section_channelidref=Channel ID Ref
+ESBValidatorConfigurationBlock_pb_listenerReferencesNonExistentChannel_label=Listener
References Non-existent Channel:
+ESBValidatorConfigurationBlock_pb_listenerReferencesIncompatibleChannel_label=Listener
References Incompatible Channel:
+
+ESB_VALIDATOR_PREFERENCE_PAGE_ESB_VALIDATOR=ESB Validator
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBPreferencesMessages.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBValidatorPreferencePage.java
===================================================================
---
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBValidatorPreferencePage.java
(rev 0)
+++
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBValidatorPreferencePage.java 2010-04-23
12:42:17 UTC (rev 21632)
@@ -0,0 +1,54 @@
+/*******************************************************************************
+ * Copyright (c) 2009 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,
+ * and is available at
http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.esb.validator.ui;
+
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.ui.preferences.IWorkbenchPreferenceContainer;
+import org.jboss.tools.common.ui.preferences.SeverityPreferencePage;
+import org.jboss.tools.esb.validator.ESBValidatorPlugin;
+
+/**
+ * @author Viacheslav Kabanovich
+ */
+public class ESBValidatorPreferencePage extends SeverityPreferencePage {
+
+ public static final String PREF_ID =
"org.jboss.tools.esb.validator.ui.ESBValidatorPreferencePage"; //$NON-NLS-1$
+ public static final String PROP_ID =
"org.jboss.tools.esb.validator.ui.propertyPages.ESBValidatorPreferencePage";
//$NON-NLS-1$
+
+ public ESBValidatorPreferencePage() {
+ setPreferenceStore(ESBValidatorPlugin.getDefault().getPreferenceStore());
+ setTitle(ESBPreferencesMessages.ESB_VALIDATOR_PREFERENCE_PAGE_ESB_VALIDATOR);
+ }
+
+ /* (non-Javadoc)
+ * @see
org.eclipse.jdt.internal.ui.preferences.PropertyAndPreferencePage#getPreferencePageID()
+ */
+ @Override
+ protected String getPreferencePageID() {
+ return PREF_ID;
+ }
+
+ /* (non-Javadoc)
+ * @see
org.eclipse.jdt.internal.ui.preferences.PropertyAndPreferencePage#getPropertyPageID()
+ */
+ @Override
+ protected String getPropertyPageID() {
+ return PROP_ID;
+ }
+
+ @Override
+ public void createControl(Composite parent) {
+ IWorkbenchPreferenceContainer container = (IWorkbenchPreferenceContainer)
getContainer();
+ fConfigurationBlock = new ESBConfigurationBlock(getNewStatusChangedListener(),
getProject(), container);
+
+ super.createControl(parent);
+ }
+}
\ No newline at end of file
Property changes on:
trunk/esb/plugins/org.jboss.tools.esb.validator/src/org/jboss/tools/esb/validator/ui/ESBValidatorPreferencePage.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain