JBoss Tools SVN: r15548 - in branches/jbosstools-3.0.x: jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/3969 and 3 other directories.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2009-05-27 04:13:55 -0400 (Wed, 27 May 2009)
New Revision: 15548
Added:
branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/3969/
branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/3969/jbide3969.xhtml
branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/JBIDE3969Test.java
Modified:
branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
branches/jbosstools-3.0.x/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-3969, fix applied to branch
Added: branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/3969/jbide3969.xhtml
===================================================================
--- branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/3969/jbide3969.xhtml (rev 0)
+++ branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/resources/jsfTest/WebContent/pages/JBIDE/3969/jbide3969.xhtml 2009-05-27 08:13:55 UTC (rev 15548)
@@ -0,0 +1,12 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core">
+
+<ui:composition template="">
+<h:selectOneMenu value="#{test.test}">
+<div>a<div>t</div></div>
+</h:selectOneMenu>
+</ui:composition>
+</html>
\ No newline at end of file
Modified: branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java
===================================================================
--- branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2009-05-27 06:43:21 UTC (rev 15547)
+++ branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/JsfAllTests.java 2009-05-27 08:13:55 UTC (rev 15548)
@@ -53,6 +53,7 @@
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE3632Test;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE3650Test;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE3734Test;
+import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE3969Test;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE675Test;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE788Test;
import org.jboss.tools.jsf.vpe.jsf.test.jbide.JBIDE924Test;
@@ -131,6 +132,7 @@
suite.addTestSuite(JBIDE3482Test.class);
suite.addTestSuite(JBIDE3632Test.class);
suite.addTestSuite(JBIDE3650Test.class);
+ suite.addTestSuite(JBIDE3969Test.class);
// $JUnit-END$
// added by Max Areshkau
Added: branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/JBIDE3969Test.java
===================================================================
--- branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/JBIDE3969Test.java (rev 0)
+++ branches/jbosstools-3.0.x/jsf/tests/org.jboss.tools.jsf.vpe.jsf.test/src/org/jboss/tools/jsf/vpe/jsf/test/jbide/JBIDE3969Test.java 2009-05-27 08:13:55 UTC (rev 15548)
@@ -0,0 +1,51 @@
+/*******************************************************************************
+ * Copyright (c) 2007-2008 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
+ *
+ * Contributor:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.jsf.vpe.jsf.test.jbide;
+
+import org.eclipse.core.resources.IFile;
+import org.eclipse.ui.IEditorInput;
+import org.eclipse.ui.part.FileEditorInput;
+import org.jboss.tools.jsf.vpe.jsf.test.JsfAllTests;
+import org.jboss.tools.jst.jsp.jspeditor.JSPMultiPageEditor;
+import org.jboss.tools.vpe.ui.test.TestUtil;
+import org.jboss.tools.vpe.ui.test.VpeTest;
+
+/**
+ * @author mareshkau
+ *
+ */
+public class JBIDE3969Test extends VpeTest{
+
+ public JBIDE3969Test(String name) {
+ super(name);
+ }
+
+ public void testCorrectCustomElements() throws Throwable {
+ // set exception
+ setException(null);
+
+ // get test page path
+ IFile file = (IFile) TestUtil.getComponentPath("JBIDE/3969/jbide3969.xhtml",
+ JsfAllTests.IMPORT_PROJECT_NAME);
+
+ IEditorInput input = new FileEditorInput(file);
+
+ // open and get editor
+ JSPMultiPageEditor part = openEditor(input);
+
+ checkSourceSelection(part);
+
+ // check exception
+ if (getException() != null) {
+ throw getException();
+ }
+ }
+}
Modified: branches/jbosstools-3.0.x/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java
===================================================================
--- branches/jbosstools-3.0.x/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java 2009-05-27 06:43:21 UTC (rev 15547)
+++ branches/jbosstools-3.0.x/vpe/plugins/org.jboss.tools.vpe.xulrunner/src/org/jboss/tools/vpe/xulrunner/editor/XulRunnerEditor.java 2009-05-27 08:13:55 UTC (rev 15548)
@@ -383,7 +383,7 @@
}else {
getIFlasher().setColor(flasherHiddentElementColor);
}
- getIFlasher().drawElementOutline(element);
+ drawElementOutline(element);
}else {
getIFlasher().setColor(flasherHiddentElementColor);
@@ -391,7 +391,7 @@
if(domElement!=null) {
- getIFlasher().drawElementOutline(domElement);
+ drawElementOutline(domElement);
}
}
@@ -548,17 +548,17 @@
getIFlasher().setColor(flasherHiddentElementColor);
}
- getIFlasher().drawElementOutline(getLastSelectedElement());
+ drawElementOutline(getLastSelectedElement());
}else {
getIFlasher().setColor(flasherHiddentElementColor);
nsIDOMElement domElement = findVisbleParentElement(getLastSelectedElement());
if(domElement!=null) {
- getIFlasher().drawElementOutline(domElement);
+ drawElementOutline(domElement);
}
}
- } else if(getIFlasher()!=null&&Platform.getOSArch().equals(Platform.OS_MACOSX)){
+ } else if(getIFlasher()!=null&&Platform.OS_MACOSX.equals(Platform.getOS())){
//Max Areshkau (bug on Mac OS X, when we switch to preview from other view, selection rectangle doesn't disappear
//TODO Max Areshkau (may be exist passability not draw selection on resize event when we switches to other view)
try {
@@ -641,6 +641,34 @@
return null;
}
+ /**
+ * Decorator
+ * @author mareshkau
+ * @param domElement arround which border will be shown
+ *
+ */
+ private void drawElementOutline(nsIDOMElement domElement) {
+ //fix for JBIDE-3969
+ if(Platform.OS_MACOSX.equals(Platform.getOS())&&hasSelectInParenNodes(domElement.getParentNode())) {
+ return;
+ }
+ getIFlasher().drawElementOutline(domElement);
+ }
+ /**
+ * Checks if node has select in parent node, if has it's cause crash
+ * on OSX and xulrunner 1.8.1.3
+ * @param domElement
+ * @return
+ */
+ private boolean hasSelectInParenNodes(nsIDOMNode domNode){
+ if(domNode==null) {
+ return false;
+ }else if("select".equalsIgnoreCase(domNode.getNodeName())){
+ return true;
+ } else {
+ return hasSelectInParenNodes(domNode.getParentNode());
+ }
+ }
}
14 years, 11 months
JBoss Tools SVN: r15547 - in trunk/common/plugins: org.jboss.tools.common.gef/.settings and 10 other directories.
by jbosstools-commits@lists.jboss.org
Author: sflanigan
Date: 2009-05-27 02:43:21 -0400 (Wed, 27 May 2009)
New Revision: 15547
Added:
trunk/common/plugins/org.jboss.tools.common.gef/.settings/
trunk/common/plugins/org.jboss.tools.common.gef/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/Messages.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/messages.properties
trunk/common/plugins/org.jboss.tools.common.kb/.settings/
trunk/common/plugins/org.jboss.tools.common.kb/.settings/org.eclipse.jdt.core.prefs
Modified:
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/GEFEditor.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/ActionRegistrySupport.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCopyAction.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCutAction.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramPasteAction.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/PrintRetargetAction.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/editor/xpl/DefaultPaletteCustomizer.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/outline/xpl/DiagramContentOutlinePage.java
trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/xpl/GEFSplitter.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDinamicResource.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDocumentBuilderFactory.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbHtmlStore.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbPlugin.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbProposal.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbQuery.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbSchemaUtil.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldConvertor.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldResource.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldStore.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/SchemaNodeFactory.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/TagDescriptor.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfiguration.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfigurationFactory.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbPluginConfiguration.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/JspWtpKbConnector.java
trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/WtpKbConnector.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-3557 Externalize English strings
Added: trunk/common/plugins/org.jboss.tools.common.gef/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.gef/.settings/org.eclipse.jdt.core.prefs 2009-05-27 06:43:21 UTC (rev 15547)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/GEFEditor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/GEFEditor.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/GEFEditor.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -80,11 +80,11 @@
protected static final int PALETTE_MIN_SIZE = 23;
- private static final QualifiedName PALETTE_SIZE_KEY = new QualifiedName("",
- "palette_size");
+ private static final QualifiedName PALETTE_SIZE_KEY = new QualifiedName("", //$NON-NLS-1$
+ "palette_size"); //$NON-NLS-1$
- private static final QualifiedName ZOOM_SIZE_KEY = new QualifiedName("",
- "zoom_size");
+ private static final QualifiedName ZOOM_SIZE_KEY = new QualifiedName("", //$NON-NLS-1$
+ "zoom_size"); //$NON-NLS-1$
protected int lastPaletteLayout = -1;
@@ -460,7 +460,7 @@
return;
}
try {
- String s = "" + fixedSise;
+ String s = "" + fixedSise; //$NON-NLS-1$
file.setPersistentProperty(PALETTE_SIZE_KEY, s);
} catch (CoreException e) {
CommonPlugin.getPluginLog().logError(e);
@@ -492,7 +492,7 @@
return;
}
try {
- String s = "" + zoom;
+ String s = "" + zoom; //$NON-NLS-1$
file.setPersistentProperty(ZOOM_SIZE_KEY, s);
} catch (CoreException e) {
CommonPlugin.getPluginLog().logError(e);
Added: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/Messages.java (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/Messages.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -0,0 +1,19 @@
+package org.jboss.tools.common.gef;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.gef.messages"; //$NON-NLS-1$
+ public static String DefaultPaletteCustomizer_ErrorMessage;
+ public static String DiagramCopyAction_AcceleratorText;
+ public static String DiagramCutAction_AcceleratorText;
+ public static String DiagramPasteAction_AcceleratorText;
+ public static String PrintRetargetAction_Name;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/ActionRegistrySupport.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/ActionRegistrySupport.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/ActionRegistrySupport.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -79,7 +79,7 @@
}
public void contributeGEFToToolBar(IToolBarManager tbm) {
- tbm.add(getAction("Print_Diagram"));
+ tbm.add(getAction(PrintRetargetAction.ACTION_ID));
tbm.add(new Separator());
tbm.add(getAction(GEFActionConstants.ALIGN_LEFT));
tbm.add(getAction(GEFActionConstants.ALIGN_CENTER));
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCopyAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCopyAction.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCopyAction.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -15,6 +15,7 @@
import org.eclipse.ui.actions.ActionFactory;
import org.eclipse.ui.internal.WorkbenchImages;
import org.eclipse.gef.internal.GEFMessages;
+import org.jboss.tools.common.gef.Messages;
/**
@@ -43,7 +44,7 @@
setDisabledImageDescriptor(
WorkbenchImages.getImageDescriptor(
ISharedImages.IMG_TOOL_COPY_DISABLED));
- setAccelerator(convertAccelerator("CTRL+C"));
+ setAccelerator(convertAccelerator(Messages.DiagramCopyAction_AcceleratorText));
setEnabled(false);
}
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCutAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCutAction.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramCutAction.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -14,6 +14,7 @@
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.actions.ActionFactory;
import org.eclipse.ui.internal.WorkbenchImages;
+import org.jboss.tools.common.gef.Messages;
public abstract class DiagramCutAction extends DiagramSelectionAction {
@@ -38,7 +39,7 @@
setDisabledImageDescriptor(
WorkbenchImages.getImageDescriptor(
ISharedImages.IMG_TOOL_CUT_DISABLED));
- setAccelerator(convertAccelerator("CTRL+X"));
+ setAccelerator(convertAccelerator(Messages.DiagramCutAction_AcceleratorText));
setEnabled(false);
}
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramPasteAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramPasteAction.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/DiagramPasteAction.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -15,6 +15,7 @@
import org.eclipse.ui.actions.ActionFactory;
import org.eclipse.ui.internal.WorkbenchImages;
import org.eclipse.gef.internal.GEFMessages;
+import org.jboss.tools.common.gef.Messages;
/**
* An action to delete selected objects.
@@ -43,7 +44,7 @@
setDisabledImageDescriptor(
WorkbenchImages.getImageDescriptor(
ISharedImages.IMG_TOOL_PASTE_DISABLED));
- setAccelerator(convertAccelerator("CTRL+V"));
+ setAccelerator(convertAccelerator(Messages.DiagramPasteAction_AcceleratorText));
setEnabled(false);
}
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/PrintRetargetAction.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/PrintRetargetAction.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/action/PrintRetargetAction.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -13,15 +13,18 @@
import org.eclipse.jface.resource.ImageDescriptor;
+import org.jboss.tools.common.gef.Messages;
public class PrintRetargetAction extends RetargetAction{
+ static final String ACTION_ID = "Print_Diagram"; //$NON-NLS-1$
+
public PrintRetargetAction() {
- super("Print_Diagram","Print Diagram");
- setToolTipText("Print Diagram");
- setImageDescriptor(ImageDescriptor.createFromFile(getClass(), "icons/print.gif"));
+ super(ACTION_ID,Messages.PrintRetargetAction_Name);
+ setToolTipText(Messages.PrintRetargetAction_Name);
+ setImageDescriptor(ImageDescriptor.createFromFile(getClass(), "icons/print.gif")); //$NON-NLS-1$
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/editor/xpl/DefaultPaletteCustomizer.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/editor/xpl/DefaultPaletteCustomizer.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/editor/xpl/DefaultPaletteCustomizer.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -17,6 +17,7 @@
import org.eclipse.gef.ui.palette.customize.DefaultEntryPage;
import org.eclipse.gef.ui.palette.customize.DrawerEntryPage;
import org.eclipse.gef.ui.palette.customize.EntryPage;
+import org.jboss.tools.common.gef.Messages;
/**
*
@@ -25,7 +26,7 @@
*/
public class DefaultPaletteCustomizer extends PaletteCustomizer {
- protected static final String ERROR_MESSAGE = "Error";
+ protected static final String ERROR_MESSAGE = Messages.DefaultPaletteCustomizer_ErrorMessage;
/**
* @see org.eclipse.gef.ui.palette.PaletteCustomizer#getPropertiesPage(PaletteEntry)
Added: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/messages.properties
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/messages.properties (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/messages.properties 2009-05-27 06:43:21 UTC (rev 15547)
@@ -0,0 +1,5 @@
+DefaultPaletteCustomizer_ErrorMessage=Error
+DiagramCopyAction_AcceleratorText=CTRL+C
+DiagramCutAction_AcceleratorText=CTRL+X
+DiagramPasteAction_AcceleratorText=CTRL+V
+PrintRetargetAction_Name=Print Diagram
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/outline/xpl/DiagramContentOutlinePage.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/outline/xpl/DiagramContentOutlinePage.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/outline/xpl/DiagramContentOutlinePage.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -41,8 +41,8 @@
public class DiagramContentOutlinePage extends ContentOutlinePage implements IAdaptable {
//Warning: these icons may be moved from xpl!
- private static String OUTLINE_ICON_PATH = "outline.gif";
- private static String OVERVIEW_ICON_PATH = "overview.gif";
+ private static String OUTLINE_ICON_PATH = "outline.gif"; //$NON-NLS-1$
+ private static String OVERVIEW_ICON_PATH = "overview.gif"; //$NON-NLS-1$
private org.eclipse.ui.views.contentoutline.ContentOutlinePage poutline;
private GraphicalViewer graphicalViewer;
Modified: trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/xpl/GEFSplitter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/xpl/GEFSplitter.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.gef/src/org/jboss/tools/common/gef/xpl/GEFSplitter.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -25,7 +25,7 @@
private static final int SASH_WIDTH = 5;
private static final int FIXED_DRAG_MINIMUM = 62;
private static final int OTHER_DRAG_MINIMUM = 0;
- private static final String MAINTAIN_SIZE = "maintain size";
+ private static final String MAINTAIN_SIZE = "maintain size"; //$NON-NLS-1$
private int fixedSize = 150;
private int fixedDragMinimum;
Added: trunk/common/plugins/org.jboss.tools.common.kb/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.kb/.settings/org.eclipse.jdt.core.prefs 2009-05-27 06:43:21 UTC (rev 15547)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDinamicResource.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDinamicResource.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDinamicResource.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -19,19 +19,19 @@
*/
public interface KbDinamicResource extends KbResource {
- String BUNDLE_PROPERTY_TYPE = "bundleProperty";
- String BEAN_PROPERTY_TYPE = "beanProperty";
- String BEAN_METHOD_BY_SYGNATURE_TYPE = "beanMethodBySignature";
- String JSP_PATH_TYPE = "jspPath";
- String BUNDLE_NAME_TYPE = "bundleName";
- String VIEW_ACTIONS_TYPE = "viewActions";
- String IMAGE_FILE_TYPE = "file";
- String ENUMERATION_TYPE = "enumeration";
- String JSF_VARIABLES_TYPE = "jsfVariables";
- String FACELETS_JSFC_TYPE = "faceletsJsfCTags";
- String MANAGED_BEAN_NAME_TYPE = "managedBeanName";
- String JSF_ID = "jsfID";
- String TAGLIB_TYPE = "taglib";
+ String BUNDLE_PROPERTY_TYPE = "bundleProperty"; //$NON-NLS-1$
+ String BEAN_PROPERTY_TYPE = "beanProperty"; //$NON-NLS-1$
+ String BEAN_METHOD_BY_SYGNATURE_TYPE = "beanMethodBySignature"; //$NON-NLS-1$
+ String JSP_PATH_TYPE = "jspPath"; //$NON-NLS-1$
+ String BUNDLE_NAME_TYPE = "bundleName"; //$NON-NLS-1$
+ String VIEW_ACTIONS_TYPE = "viewActions"; //$NON-NLS-1$
+ String IMAGE_FILE_TYPE = "file"; //$NON-NLS-1$
+ String ENUMERATION_TYPE = "enumeration"; //$NON-NLS-1$
+ String JSF_VARIABLES_TYPE = "jsfVariables"; //$NON-NLS-1$
+ String FACELETS_JSFC_TYPE = "faceletsJsfCTags"; //$NON-NLS-1$
+ String MANAGED_BEAN_NAME_TYPE = "managedBeanName"; //$NON-NLS-1$
+ String JSF_ID = "jsfID"; //$NON-NLS-1$
+ String TAGLIB_TYPE = "taglib"; //$NON-NLS-1$
/**
* Sets a parameter for resource.
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDocumentBuilderFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDocumentBuilderFactory.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbDocumentBuilderFactory.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -31,7 +31,7 @@
try {
return new DocumentBuilderCreator().createDocumentBuilder(validating);
} catch (InterruptedException t) {
- KbPlugin.getPluginLog().logError("Cannot create document builder.", t);
+ KbPlugin.getPluginLog().logError("Cannot create document builder.", t); //$NON-NLS-1$
return null;
}
}
@@ -58,8 +58,8 @@
if(!validate) {
documentBuilder.setEntityResolver(new EntityResolver() {
public InputSource resolveEntity(java.lang.String publicId, java.lang.String systemId) throws SAXException, java.io.IOException {
- if((systemId != null) && systemId.toLowerCase().endsWith(".dtd")) { // this deactivates DTD
- return new InputSource(new ByteArrayInputStream("<?xml version='1.0' encoding='UTF-8'?>".getBytes()));
+ if((systemId != null) && systemId.toLowerCase().endsWith(".dtd")) { // this deactivates DTD //$NON-NLS-1$
+ return new InputSource(new ByteArrayInputStream("<?xml version='1.0' encoding='UTF-8'?>".getBytes())); //$NON-NLS-1$
} else {
return null;
}
@@ -67,7 +67,7 @@
});
}
} catch (ParserConfigurationException t) {
- KbPlugin.getPluginLog().logError("Document builder creation failed.", t);
+ KbPlugin.getPluginLog().logError("Document builder creation failed.", t); //$NON-NLS-1$
}
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbHtmlStore.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbHtmlStore.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbHtmlStore.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -127,7 +127,7 @@
String strQuery = cleanQuery(query);
if(strQuery == null) {
- String errorMessage = "ERROR: Bad query: \"" + query.getQuery() + "\". Query must starts with \"" + KbQuery.TAG_SEPARATOR + "\"";
+ String errorMessage = "ERROR: Bad query: \"" + query.getQuery() + "\". Query must starts with \"" + KbQuery.TAG_SEPARATOR + "\""; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
// KbPlugin.log(errorMessage);
throw new IllegalArgumentException(errorMessage);
}
@@ -138,7 +138,7 @@
int lastTagSeparator = strQuery.lastIndexOf(KbQuery.TAG_SEPARATOR);
String firstTag = null;
- String tagMask = "";
+ String tagMask = ""; //$NON-NLS-1$
if(lastTagSeparator > firstTagSeparator) {
firstTag = strQuery.substring(firstTagSeparator + KbQuery.TAG_SEPARATOR.length(), lastTagSeparator);
if(lastTagSeparator + KbQuery.TAG_SEPARATOR.length() < strQuery.length()) {
@@ -237,18 +237,18 @@
private KbProposal getEndTagProposal(KbQuery kbQuery) {
String query = kbQuery.getQuery();
- String mask = "";
+ String mask = ""; //$NON-NLS-1$
int lastSeparator = query.lastIndexOf(KbQuery.TAG_SEPARATOR);
if((lastSeparator!=-1)&&(lastSeparator + KbQuery.TAG_SEPARATOR.length()<query.length())) {
mask = query.substring(lastSeparator + KbQuery.TAG_SEPARATOR.length());
}
String lastTag = kbQuery.getLastTag();
- if((lastTag != null)&&(((mask.indexOf(KbQuery.DONT_FILTER_END_TAG_CHAR)!=-1)&&(KbQuery.DONT_FILTER_END_TAG_CHAR + lastTag).startsWith(mask))||(mask.equals("")))) {
+ if((lastTag != null)&&(((mask.indexOf(KbQuery.DONT_FILTER_END_TAG_CHAR)!=-1)&&(KbQuery.DONT_FILTER_END_TAG_CHAR + lastTag).startsWith(mask))||(mask.equals("")))) { //$NON-NLS-1$
if(checkNonRefusedEndTag(lastTag)) {
KbProposal proposal = new KbProposal();
- proposal.setLabel("/" + lastTag);
- proposal.setReplacementString("/" + lastTag);
+ proposal.setLabel("/" + lastTag); //$NON-NLS-1$
+ proposal.setReplacementString("/" + lastTag); //$NON-NLS-1$
return proposal;
}
}
@@ -338,7 +338,7 @@
String tagName = tagMask.substring(0, startAttributeName);
startAttributeName+=KbQuery.ATTRIBUTE_SEPARATOR.length();
if(startAttributeName == tagMask.length()) {
- return getAttributes(tagName, "");
+ return getAttributes(tagName, ""); //$NON-NLS-1$
}
int startAttributeValue = tagMask.indexOf(KbQuery.ENUMERATION_SEPARATOR);
@@ -349,15 +349,15 @@
String attributeName = tagMask.substring(startAttributeName, startAttributeValue);
startAttributeValue+=KbQuery.ENUMERATION_SEPARATOR.length();
if(startAttributeValue == tagMask.length()) {
- return getEnumeration(tagName, attributeName, "");
+ return getEnumeration(tagName, attributeName, ""); //$NON-NLS-1$
}
return getEnumeration(tagName, attributeName, KbQuery.decode(tagMask.substring(startAttributeValue)));
}
private synchronized boolean activateHtmlSchema() {
- String ERR_CANNNOT_LOAD_SCHEME = "Can't load HTML schema ''{0}''"; //$NON-NLS-N$
- String ERR_EXCEPTION_DURING_PARSING = "Exception happend during parsing ''{0}''"; //$NON-NLS-N$
+ String ERR_CANNNOT_LOAD_SCHEME = "Can't load HTML schema ''{0}''"; //$NON-NLS-1$
+ String ERR_EXCEPTION_DURING_PARSING = "Exception happend during parsing ''{0}''"; //$NON-NLS-1$
if(htmlSchemaIsActivating()) {
return false;
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbPlugin.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbPlugin.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -29,7 +29,7 @@
*/
public class KbPlugin extends BaseUIPlugin {
- public static final String PLUGIN_ID = "org.jboss.tools.common.kb";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.kb"; //$NON-NLS-1$
private File location;
// The shared instance
@@ -38,7 +38,7 @@
// A Map to save a descriptor for each image
private HashMap fImageDescRegistry = null;
- public static final String CA_ENUMERATION_IMAGE_PATH = "images/ca/icons_Enumeration.gif";
+ public static final String CA_ENUMERATION_IMAGE_PATH = "images/ca/icons_Enumeration.gif"; //$NON-NLS-1$
public KbPlugin() {
}
@@ -61,7 +61,7 @@
if(!isLocationSet) {
try {
isLocationSet = true;
- location = new File(FileLocator.resolve(KbPlugin.getDefault().getBundle().getEntry("/")).getPath());
+ location = new File(FileLocator.resolve(KbPlugin.getDefault().getBundle().getEntry("/")).getPath()); //$NON-NLS-1$
} catch (IOException e) {
getPluginLog().logError(e);
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbProposal.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbProposal.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbProposal.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -192,7 +192,7 @@
* @return
*/
public boolean isCloseTag() {
- return label != null && label.startsWith("/");
+ return label != null && label.startsWith("/"); //$NON-NLS-1$
}
/**
@@ -200,11 +200,11 @@
*/
public String toString() {
StringBuffer buffer = new StringBuffer();
- buffer.append("label: ");
+ buffer.append("label: "); //$NON-NLS-1$
buffer.append(label);
- buffer.append("\ncontextInfo: ");
+ buffer.append("\ncontextInfo: "); //$NON-NLS-1$
buffer.append(contextInfo);
- buffer.append("\nreplacementString: ");
+ buffer.append("\nreplacementString: "); //$NON-NLS-1$
buffer.append(replacementString);
return buffer.toString();
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbQuery.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbQuery.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbQuery.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -21,17 +21,17 @@
*/
public class KbQuery {
- public static final String XML_DECLARATION_QUERY = "?";
- public static final String TAG_SEPARATOR = "/";
- public static final String ATTRIBUTE_SEPARATOR = "@";
- public static final String PREFIX_SEPARATOR = ":";
- public static final String ENUMERATION_SEPARATOR = "=";
- public static final String DONT_FILTER_END_TAG_CHAR = "^";
- public static final String JSP_DIRECTIVE_QUERY = "@";
+ public static final String XML_DECLARATION_QUERY = "?"; //$NON-NLS-1$
+ public static final String TAG_SEPARATOR = "/"; //$NON-NLS-1$
+ public static final String ATTRIBUTE_SEPARATOR = "@"; //$NON-NLS-1$
+ public static final String PREFIX_SEPARATOR = ":"; //$NON-NLS-1$
+ public static final String ENUMERATION_SEPARATOR = "="; //$NON-NLS-1$
+ public static final String DONT_FILTER_END_TAG_CHAR = "^"; //$NON-NLS-1$
+ public static final String JSP_DIRECTIVE_QUERY = "@"; //$NON-NLS-1$
private static final char START_CODE_CHAR = '%';
private static final char END_CODE_CHAR = ';';
- private String query = "";
+ private String query = ""; //$NON-NLS-1$
private Collection resources = new ArrayList();
private Collection dinamicResources = new ArrayList();
@@ -75,11 +75,11 @@
*/
public String toString() {
StringBuffer result = new StringBuffer();
- result.append("Query string = [");
+ result.append("Query string = ["); //$NON-NLS-1$
result.append(query);
- result.append("]; Resources size = [");
+ result.append("]; Resources size = ["); //$NON-NLS-1$
result.append(resources.size());
- result.append("];");
+ result.append("];"); //$NON-NLS-1$
return result.toString();
}
@@ -144,8 +144,8 @@
return str;
}
StringBuffer result = new StringBuffer(str.length());
- StringTokenizer st = new StringTokenizer(str, "" + START_CODE_CHAR, false);
- if((!str.startsWith("" + START_CODE_CHAR))&&(st.hasMoreElements())) {
+ StringTokenizer st = new StringTokenizer(str, "" + START_CODE_CHAR, false); //$NON-NLS-1$
+ if((!str.startsWith("" + START_CODE_CHAR))&&(st.hasMoreElements())) { //$NON-NLS-1$
result.append(st.nextElement());
}
while(st.hasMoreElements()) {
@@ -160,7 +160,7 @@
result.append(s.substring(endCode));
}
} catch(NumberFormatException e) {
- String message = "ERROR: can't decode string=" + s;
+ String message = "ERROR: can't decode string=" + s; //$NON-NLS-1$
KbPlugin.getPluginLog().logError(message, e);
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbSchemaUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbSchemaUtil.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbSchemaUtil.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -105,7 +105,7 @@
String name = attributeType.getAttribute(SchemaNodeFactory.NAME_ATTRIBUTE);
attributes.append(' ');
attributes.append(name);
- attributes.append("=\"");
+ attributes.append("=\""); //$NON-NLS-1$
attributes.append('"');
}
return attributes.toString();
@@ -173,7 +173,7 @@
}
}
}
- return "";
+ return ""; //$NON-NLS-1$
}
/**
@@ -209,9 +209,9 @@
attributesD.remove(typeLow);
attributesI.add(typeLow);
} else if(attributesI.contains(typeLow)) {
- KbPlugin.getPluginLog().logWarning("Warning: attribute type " + type + " is declared more than once in element " + elementName + ".");
+ KbPlugin.getPluginLog().logWarning("Warning: attribute type " + type + " is declared more than once in element " + elementName + "."); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
} else if(!attributesI.contains(typeLow)) {
- KbPlugin.getPluginLog().logWarning("Warning: attribute type " + type + " is never used by an attribute in element " + elementName + ".");
+ KbPlugin.getPluginLog().logWarning("Warning: attribute type " + type + " is never used by an attribute in element " + elementName + "."); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
}
}
@@ -236,7 +236,7 @@
Iterator it = attributesD.iterator();
while(it.hasNext()) {
String a = it.next().toString();
- KbPlugin.getPluginLog().logWarning("Warning: attribute type is not defined for attribute " + a + " in element " + elementName + ".");
+ KbPlugin.getPluginLog().logWarning("Warning: attribute type is not defined for attribute " + a + " in element " + elementName + "."); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldConvertor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldConvertor.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldConvertor.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -39,16 +39,16 @@
*/
public class KbTldConvertor implements KbSchemaConvertor {
- private final static String TAG_ELEMENT_NAME = "tag";
- private final static String NAME_ELEMENT_NAME = "name";
- private final static String DESCRIPTION_ELEMENT_NAME = "description";
- private final static String ATTRIBUTE_ELEMENT_NAME = "attribute";
- private final static String REQUIRED_ELEMENT_NAME = "required";
- private final static String BODYCONTENT_ELEMENT_NAME_1_1 = "bodycontent";
- private final static String BODYCONTENT_ELEMENT_NAME_1_2 = "body-content";
- private final static String EMPTY_BODYCONTENT_TYPE = "empty";
- private final static String SHORT_NAME_1_1 = "shortname";
- private final static String SHORT_NAME_1_2 = "short-name";
+ private final static String TAG_ELEMENT_NAME = "tag"; //$NON-NLS-1$
+ private final static String NAME_ELEMENT_NAME = "name"; //$NON-NLS-1$
+ private final static String DESCRIPTION_ELEMENT_NAME = "description"; //$NON-NLS-1$
+ private final static String ATTRIBUTE_ELEMENT_NAME = "attribute"; //$NON-NLS-1$
+ private final static String REQUIRED_ELEMENT_NAME = "required"; //$NON-NLS-1$
+ private final static String BODYCONTENT_ELEMENT_NAME_1_1 = "bodycontent"; //$NON-NLS-1$
+ private final static String BODYCONTENT_ELEMENT_NAME_1_2 = "body-content"; //$NON-NLS-1$
+ private final static String EMPTY_BODYCONTENT_TYPE = "empty"; //$NON-NLS-1$
+ private final static String SHORT_NAME_1_1 = "shortname"; //$NON-NLS-1$
+ private final static String SHORT_NAME_1_2 = "short-name"; //$NON-NLS-1$
private static final KbTldConvertor INSTANCE = new KbTldConvertor();
@@ -76,11 +76,11 @@
if(resource instanceof KbTldResource) {
tldResource = (KbTldResource)resource;
} else {
- throw new IllegalArgumentException("KbTldConvertor.convertToSchema(KbResource resource): resource must be instance of KbTldResource");
+ throw new IllegalArgumentException("KbTldConvertor.convertToSchema(KbResource resource): resource must be instance of KbTldResource"); //$NON-NLS-1$
}
Properties attributes = new Properties();
attributes.put(SchemaNodeFactory.LOCATION_ATTRIBUTE, tldResource.getTldLocation());
- attributes.put(SchemaNodeFactory.JSF_ATTRIBUTE, "" + tldResource.isJsfResource());
+ attributes.put(SchemaNodeFactory.JSF_ATTRIBUTE, "" + tldResource.isJsfResource()); //$NON-NLS-1$
if(tldResource.getUri()!=null) {
attributes.put(SchemaNodeFactory.URI_ATTRIBUTE, tldResource.getUri());
}
@@ -89,7 +89,7 @@
InputStream is = tldResource.getInputStream();
if(is==null) {
if(KbPlugin.isDebugEnabled()) {
- KbPlugin.getPluginLog().logWarning(" WARNING! Can't get InputSource from resource (location: " + tldResource.getTldLocation() + ").");
+ KbPlugin.getPluginLog().logWarning(" WARNING! Can't get InputSource from resource (location: " + tldResource.getTldLocation() + ")."); //$NON-NLS-1$ //$NON-NLS-2$
}
return null;
}
@@ -145,7 +145,7 @@
*/
public Document convertToSchema(InputStream inputStream, Properties attributes, boolean jsfTld) {
- final String ERR_CANNOT_PARSE_TLD = "ERROR: Can't parse TLD file for converting to the Schema."; //$NON-NLS-N$
+ final String ERR_CANNOT_PARSE_TLD = "ERROR: Can't parse TLD file for converting to the Schema."; //$NON-NLS-1$
Document tldDocument = null;
Document schema = null;
@@ -235,7 +235,7 @@
Element attributeType = SchemaNodeFactory.getInstance().createAttributeType(schemaElement, attributes);
SchemaNodeFactory.getInstance().createDescription(attributeType, description);
- if(jsfTld || tldAttribute.getElementsByTagName("deferred-value").getLength()>0) {
+ if(jsfTld || tldAttribute.getElementsByTagName("deferred-value").getLength()>0) { //$NON-NLS-1$
// Add default proposals
Element[] proposals = createDefaultELProposals(schemaElement.getOwnerDocument());
for(int i=0; i<proposals.length; i++) {
@@ -259,19 +259,19 @@
String methodName = null;
Element proposal = null;
ArrayList<String> paramTypes = new ArrayList<String>();
- StringTokenizer st = new StringTokenizer(signature.trim(), " ()", false);
+ StringTokenizer st = new StringTokenizer(signature.trim(), " ()", false); //$NON-NLS-1$
if(st.hasMoreTokens()) {
- returnType = st.nextToken(" ");
+ returnType = st.nextToken(" "); //$NON-NLS-1$
if(st.hasMoreTokens()) {
- methodName = st.nextToken("(");
+ methodName = st.nextToken("("); //$NON-NLS-1$
if(methodName!=null) {
methodName = methodName.trim();
}
}
if(st.hasMoreTokens()) {
- String params = st.nextToken("()");
+ String params = st.nextToken("()"); //$NON-NLS-1$
if(params!=null) {
- StringTokenizer stParams = new StringTokenizer(params, ",", false);
+ StringTokenizer stParams = new StringTokenizer(params, ",", false); //$NON-NLS-1$
while(stParams.hasMoreTokens()) {
String param = stParams.nextToken().trim();
if(param.length()>0) {
@@ -283,17 +283,17 @@
}
if(returnType!=null && methodName!=null) {
- proposal = document.createElement("proposal");
- proposal.setAttribute("type", "beanMethodBySignature");
- Element param = document.createElement("param");
- param.setAttribute("name", "returnType");
- param.setAttribute("value", returnType);
+ proposal = document.createElement("proposal"); //$NON-NLS-1$
+ proposal.setAttribute("type", "beanMethodBySignature"); //$NON-NLS-1$ //$NON-NLS-2$
+ Element param = document.createElement("param"); //$NON-NLS-1$
+ param.setAttribute("name", "returnType"); //$NON-NLS-1$ //$NON-NLS-2$
+ param.setAttribute("value", returnType); //$NON-NLS-1$
proposal.appendChild(param);
for(int i=0; i<paramTypes.size(); i++) {
- param = document.createElement("param");
- param.setAttribute("name", "paramType");
- param.setAttribute("value", paramTypes.get(i).toString());
+ param = document.createElement("param"); //$NON-NLS-1$
+ param.setAttribute("name", "paramType"); //$NON-NLS-1$ //$NON-NLS-2$
+ param.setAttribute("value", paramTypes.get(i).toString()); //$NON-NLS-1$
proposal.appendChild(param);
}
}
@@ -302,23 +302,23 @@
}
private Element[] createDefaultELProposals(Document document) {
- Element jsfBeanProperty = document.createElement("proposal");
- jsfBeanProperty.setAttribute("type", "beanProperty");
+ Element jsfBeanProperty = document.createElement("proposal"); //$NON-NLS-1$
+ jsfBeanProperty.setAttribute("type", "beanProperty"); //$NON-NLS-1$ //$NON-NLS-2$
- Element jsfBundleProperty = document.createElement("proposal");
- jsfBundleProperty.setAttribute("type", "bundleProperty");
+ Element jsfBundleProperty = document.createElement("proposal"); //$NON-NLS-1$
+ jsfBundleProperty.setAttribute("type", "bundleProperty"); //$NON-NLS-1$ //$NON-NLS-2$
- Element jsfVariables = document.createElement("proposal");
- jsfVariables.setAttribute("type", "jsfVariables");
+ Element jsfVariables = document.createElement("proposal"); //$NON-NLS-1$
+ jsfVariables.setAttribute("type", "jsfVariables"); //$NON-NLS-1$ //$NON-NLS-2$
return new Element[]{jsfBeanProperty, jsfBundleProperty, jsfVariables};
}
private static String getDeferredMethodSignature(Element tldAttribute) {
- NodeList deferredMethods = tldAttribute.getElementsByTagName("deferred-method");
+ NodeList deferredMethods = tldAttribute.getElementsByTagName("deferred-method"); //$NON-NLS-1$
for(int i=0; i<deferredMethods.getLength(); i++) {
Element deferredMethod = (Element)deferredMethods.item(i);
- return getChildElementBody(deferredMethod, "method-signature");
+ return getChildElementBody(deferredMethod, "method-signature"); //$NON-NLS-1$
}
return null;
}
@@ -377,7 +377,7 @@
}
return sb.toString();
} else {
- return "";
+ return ""; //$NON-NLS-1$
}
}
@@ -414,8 +414,8 @@
* @return
*/
public OutputFormat createOutputFormat() {
- OutputFormat format = new OutputFormat("xml", "UTF-8", true);
- format.setLineSeparator("\r\n");
+ OutputFormat format = new OutputFormat("xml", "UTF-8", true); //$NON-NLS-1$ //$NON-NLS-2$
+ format.setLineSeparator("\r\n"); //$NON-NLS-1$
format.setIndent(4);
return format;
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldResource.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldResource.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldResource.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -107,13 +107,13 @@
}
private InputStream getInputStreamFromTldLocation() {
- final String ERR_TLD_FILE_DOSENT_EXIST = "ERROR: TLD file ''{0}'' doesn't exist!";
+ final String ERR_TLD_FILE_DOSENT_EXIST = "ERROR: TLD file ''{0}'' doesn't exist!"; //$NON-NLS-1$
InputStream is = null;
if (tldLocation == null) {
return null;
}
try {
- if (tldLocation.indexOf(":/") < 2) {
+ if (tldLocation.indexOf(":/") < 2) { //$NON-NLS-1$
File file = new File(tldLocation);
if (!file.exists()) {
return null;
@@ -121,7 +121,7 @@
is = new BufferedInputStream(new FileInputStream(file));
} else {
URL url = new URL(tldLocation);
- if("jar".equals(url.getProtocol()) || "file".equals(url.getProtocol())) {
+ if("jar".equals(url.getProtocol()) || "file".equals(url.getProtocol())) { //$NON-NLS-1$ //$NON-NLS-2$
is = url.openStream(); // Bug 8385 -fixed
}
}
@@ -308,17 +308,17 @@
*/
public String toString() {
StringBuffer buffer = new StringBuffer();
- buffer.append("[TLDlocation=\"");
+ buffer.append("[TLDlocation=\""); //$NON-NLS-1$
buffer.append(tldLocation);
- buffer.append("\" SchemaLocation=\"");
+ buffer.append("\" SchemaLocation=\""); //$NON-NLS-1$
buffer.append(schemaLocation);
- buffer.append("\"");
- buffer.append(" Prefixes=\"");
+ buffer.append("\""); //$NON-NLS-1$
+ buffer.append(" Prefixes=\""); //$NON-NLS-1$
buffer.append(prefixes);
- buffer.append("\"");
- buffer.append(" uri=\"");
+ buffer.append("\""); //$NON-NLS-1$
+ buffer.append(" uri=\""); //$NON-NLS-1$
buffer.append(uri);
- buffer.append("\"]");
+ buffer.append("\"]"); //$NON-NLS-1$
return buffer.toString();
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldStore.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldStore.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/KbTldStore.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -149,7 +149,7 @@
String key = needResources.hashCode() + cleanQuary;
- boolean faceletsHtml = cleanQuary.indexOf("0fHP:")>-1;
+ boolean faceletsHtml = cleanQuary.indexOf("0fHP:")>-1; //$NON-NLS-1$
Object o = faceletsHtml?getFaceletsHtmlTagInfoCache().get(key):getTagInfoCache().get(key);
if(o!=null) {
return (TagDescriptor)o;
@@ -254,7 +254,7 @@
}
if(strQuery.length() == KbQuery.TAG_SEPARATOR.length()) {
- return getTags(needResources, "");
+ return getTags(needResources, ""); //$NON-NLS-1$
}
int startTagName = strQuery.indexOf(KbQuery.PREFIX_SEPARATOR);
@@ -268,7 +268,7 @@
if(startAttributeName < 0){
String tagName = strQuery.substring(startTagName);
boolean tagMask = true;
- if(tagName.endsWith("/")) {
+ if(tagName.endsWith("/")) { //$NON-NLS-1$
tagMask = false;
tagName = tagName.substring(0, tagName.length()-1);
}
@@ -282,7 +282,7 @@
String tagName = strQuery.substring(startTagName, startAttributeName);
startAttributeName+=KbQuery.ATTRIBUTE_SEPARATOR.length();
if(startAttributeName == strQuery.length()) {
- return getAttributes(needResources, prefixName, tagName, "");
+ return getAttributes(needResources, prefixName, tagName, ""); //$NON-NLS-1$
}
int startAttributeValue = strQuery.indexOf(KbQuery.ENUMERATION_SEPARATOR);
@@ -296,7 +296,7 @@
// Collection needDinamicResources = convertQueryDinamicResourceToRegistretedDinamicResource(query.getDinamicResources());
Collection needDinamicResources = query.getDinamicResources();
if(startAttributeValue == strQuery.length()) {
- return getAttributeValue(needResources, needDinamicResources, prefixName, tagName, attributeName, "");
+ return getAttributeValue(needResources, needDinamicResources, prefixName, tagName, attributeName, ""); //$NON-NLS-1$
}
return getAttributeValue(needResources, needDinamicResources, prefixName, tagName, attributeName, KbQuery.decode(strQuery.substring(startAttributeValue)));
@@ -366,7 +366,7 @@
// return registerDinamicResource((KbDinamicResource)resource);
return (KbDinamicResource)resource;
} else {
- throw new IllegalArgumentException("KbTldStore.registerResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource");
+ throw new IllegalArgumentException("KbTldStore.registerResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource"); //$NON-NLS-1$
}
}
@@ -445,7 +445,7 @@
// TODO Stop loading and registration resource
}
} else {
- throw new IllegalArgumentException("KbTldStore.unregisterResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource");
+ throw new IllegalArgumentException("KbTldStore.unregisterResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource"); //$NON-NLS-1$
}
}
@@ -566,7 +566,7 @@
File schemaLocation = regResource.getSchemaLocation();
if((schemaLocation == null)||(!schemaLocation.exists())) {
if(KbPlugin.isDebugEnabled()) {
- KbPlugin.getPluginLog().logWarning("WARNING: Schema (location: " + schemaLocation + ") for resource (" + regResource +") does not exist!");
+ KbPlugin.getPluginLog().logWarning("WARNING: Schema (location: " + schemaLocation + ") for resource (" + regResource +") does not exist!"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
return;
}
@@ -616,23 +616,23 @@
private void loadRegistratedResources() {
// Get the schemas from extention point.
IExtensionRegistry registry = Platform.getExtensionRegistry();
- IExtensionPoint extensionPoint = registry.getExtensionPoint("org.jboss.tools.common.kb.tldResource");
+ IExtensionPoint extensionPoint = registry.getExtensionPoint("org.jboss.tools.common.kb.tldResource"); //$NON-NLS-1$
IExtension[] extensions = extensionPoint.getExtensions();
for (int i=0; i<extensions.length; i++) {
IExtension extension = extensions[i];
IConfigurationElement[] elements = extension.getConfigurationElements();
for(int j=0; j<elements.length; j++) {
- String uri = elements[j].getAttribute("uri");
- String location = elements[j].getAttribute("schema-location");
- String version = elements[j].getAttribute("version");
- String jsf = elements[j].getAttribute("jsf");
+ String uri = elements[j].getAttribute("uri"); //$NON-NLS-1$
+ String location = elements[j].getAttribute("schema-location"); //$NON-NLS-1$
+ String version = elements[j].getAttribute("version"); //$NON-NLS-1$
+ String jsf = elements[j].getAttribute("jsf"); //$NON-NLS-1$
if(uri==null || uri.length()==0 || location==null || location.length()==0) {
continue;
}
Bundle sourcePlugin = Platform.getBundle(elements[j].getNamespaceIdentifier());
File shemaLocation = null;
try {
- shemaLocation = new File(FileLocator.resolve(sourcePlugin.getEntry("/")).getPath(), location);
+ shemaLocation = new File(FileLocator.resolve(sourcePlugin.getEntry("/")).getPath(), location); //$NON-NLS-1$
} catch (IOException e) {
KbPlugin.getPluginLog().logError(e);
continue;
@@ -644,10 +644,10 @@
resource.setVersion(version);
}
resource.setCustomTld(false);
- resource.setJsfResource("true".equals(jsf));
+ resource.setJsfResource("true".equals(jsf)); //$NON-NLS-1$
registratedResources.put(resource, resource);
} else {
- String message = "Can't load KB schema: " + shemaLocation;
+ String message = "Can't load KB schema: " + shemaLocation; //$NON-NLS-1$
KbPlugin.getDefault().getLog().log(new Status(IStatus.WARNING, KbPlugin.PLUGIN_ID, IStatus.WARNING, message, null));
}
}
@@ -677,10 +677,10 @@
continue;
}
} catch (IOException e) {
- KbPlugin.getDefault().getLog().log(new Status(IStatus.ERROR, KbPlugin.PLUGIN_ID, IStatus.OK, "Can't parse Schema (location: " + schemas[i] + ")", e));
+ KbPlugin.getDefault().getLog().log(new Status(IStatus.ERROR, KbPlugin.PLUGIN_ID, IStatus.OK, "Can't parse Schema (location: " + schemas[i] + ")", e)); //$NON-NLS-1$ //$NON-NLS-2$
continue;
} catch (SAXException e) {
- KbPlugin.getDefault().getLog().log(new Status(IStatus.ERROR, KbPlugin.PLUGIN_ID, IStatus.OK, "Can't parse Schema (location: " + schemas[i] + ")", e));
+ KbPlugin.getDefault().getLog().log(new Status(IStatus.ERROR, KbPlugin.PLUGIN_ID, IStatus.OK, "Can't parse Schema (location: " + schemas[i] + ")", e)); //$NON-NLS-1$ //$NON-NLS-2$
continue;
}
// String tldLocation = schemas[i].getAbsolutePath();
@@ -704,7 +704,7 @@
resource.setTldContent(tldContent);
resource.setSchemaLocation(schemas[i]);
resource.setCustomTld(true);
- resource.setJsfResource("true".equals(jsf));
+ resource.setJsfResource("true".equals(jsf)); //$NON-NLS-1$
registratedResources.put(resource, resource);
}
}
@@ -713,7 +713,7 @@
* @return
*/
public KbResource getJspResource() {
- return getRegistratedResource(new KbTldResource("http://java.sun.com/JSP/Page", "", "jsp", null));
+ return getRegistratedResource(new KbTldResource("http://java.sun.com/JSP/Page", "", "jsp", null)); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
private ArrayList<KbProposal> getTags(Collection resources, String prefixMask) {
@@ -818,14 +818,14 @@
boolean ignoreCase = false;
String attr = element.getOwnerDocument().getDocumentElement().getAttribute(SchemaNodeFactory.IGNORE_CASE_ATTRIBUTE);
- ignoreCase = attr!=null && attr.equals("true");
+ ignoreCase = attr!=null && attr.equals("true"); //$NON-NLS-1$
ArrayList attributeTypes = KbSchemaUtil.getAttributeTypes(element);
for(int i=0; i<attributeTypes.size(); i++) {
Element attributeType = (Element)attributeTypes.get(i);
String attributeTypeName = attributeType.getAttribute(SchemaNodeFactory.NAME_ATTRIBUTE);
- boolean endsWithWildCard = attributeTypeName.endsWith("" + SchemaNodeFactory.WILD_CARD_CHAR);
+ boolean endsWithWildCard = attributeTypeName.endsWith("" + SchemaNodeFactory.WILD_CARD_CHAR); //$NON-NLS-1$
if(endsWithWildCard) {
attributeTypeName = attributeTypeName.substring(0, attributeTypeName.length() - 1);
}
@@ -868,7 +868,7 @@
String label = element.getAttribute(SchemaNodeFactory.NAME_ATTRIBUTE);
if(label == null || label.indexOf(SchemaNodeFactory.WILD_CARD_CHAR) >= 0) continue;
- String endTag = SchemaNodeFactory.REFUSED_BODY_CONTENT_TYPE.equals(element.getAttribute(SchemaNodeFactory.BODY_CONTENT_ATTRIBUTE))?" /":"";
+ String endTag = SchemaNodeFactory.REFUSED_BODY_CONTENT_TYPE.equals(element.getAttribute(SchemaNodeFactory.BODY_CONTENT_ATTRIBUTE))?" /":""; //$NON-NLS-1$ //$NON-NLS-2$
StringBuffer lb = new StringBuffer();
lb.append(prefix);
lb.append(KbQuery.PREFIX_SEPARATOR);
@@ -936,8 +936,8 @@
}
private HashMap<String,TldElement> getTldElementsByPrefix(Collection resources, String prefix, boolean mask) {
- String cacheKey = resources.hashCode() + "/" + prefix + "/" + mask;
- boolean faceletsHtml = prefix.equals("0fHP");
+ String cacheKey = resources.hashCode() + "/" + prefix + "/" + mask; //$NON-NLS-1$ //$NON-NLS-2$
+ boolean faceletsHtml = prefix.equals("0fHP"); //$NON-NLS-1$
HashMap<String,TldElement> o = faceletsHtml?getFaceletsHtmlTldElementsByPrefix().get(cacheKey):getTldElementsByPrefix().get(cacheKey);
if(o != null) return o;
@@ -993,7 +993,7 @@
}
private ArrayList<TldElement> getTldElementsByName(Collection resources, String prefixName, String name, boolean mask) {
- String cacheKey = resources.hashCode() + "/" + prefixName + "/" + name + "/" + mask;
+ String cacheKey = resources.hashCode() + "/" + prefixName + "/" + name + "/" + mask; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
ArrayList<TldElement> o = getTldElementsByName().get(cacheKey);
if(o != null) {
return o;
@@ -1003,7 +1003,7 @@
HashMap tldElementTypes = getTldElementsByPrefix(resources, prefixName, false);
if(!mask) {
- TldElement tldElementType = "0fHP".equals(prefixName)?(TldElement)tldElementTypes.get(name.toUpperCase()):(TldElement)tldElementTypes.get(name);
+ TldElement tldElementType = "0fHP".equals(prefixName)?(TldElement)tldElementTypes.get(name.toUpperCase()):(TldElement)tldElementTypes.get(name); //$NON-NLS-1$
if(tldElementType!=null) {
tldElementType.setElementType(TldElementType.TAG);
tldElements.add(tldElementType);
@@ -1017,7 +1017,7 @@
Element element = tldElementType.getElement();
if(i==0) {
String attr = element.getOwnerDocument().getDocumentElement().getAttribute(SchemaNodeFactory.IGNORE_CASE_ATTRIBUTE);
- ignoreCase = attr!=null && attr.equals("true");
+ ignoreCase = attr!=null && attr.equals("true"); //$NON-NLS-1$
}
String schemaTagName = element.getAttribute(SchemaNodeFactory.NAME_ATTRIBUTE);
boolean match = false;
@@ -1057,7 +1057,7 @@
public void run() {
loadingResources.put(resource, resource);
- String uniqFileName = "schema";
+ String uniqFileName = "schema"; //$NON-NLS-1$
Document document = KbTldConvertor.getInstance().convertToSchema(resource);
// KbPlugin.log("document: " + KbTldConvertor.getInstance().serialize(document.getDocumentElement()));
@@ -1071,10 +1071,10 @@
File schemaFolder = new File(schemaLocation);
schemaFolder.mkdirs();
- File schemaFile = new File(schemaLocation + "/" + uniqFileName + ".xml");
+ File schemaFile = new File(schemaLocation + "/" + uniqFileName + ".xml"); //$NON-NLS-1$ //$NON-NLS-2$
int i=1;
while(schemaFile.exists()) {
- schemaFile = new File(schemaLocation + "/" + uniqFileName + i++ + ".xml");
+ schemaFile = new File(schemaLocation + "/" + uniqFileName + i++ + ".xml"); //$NON-NLS-1$ //$NON-NLS-2$
}
try {
@@ -1112,8 +1112,8 @@
}
public OutputFormat createOutputFormat() {
- OutputFormat format = new OutputFormat("xml", "UTF-8", true);
- format.setLineSeparator("\r\n");
+ OutputFormat format = new OutputFormat("xml", "UTF-8", true); //$NON-NLS-1$ //$NON-NLS-2$
+ format.setLineSeparator("\r\n"); //$NON-NLS-1$
format.setIndent(2);
return format;
}
@@ -1183,15 +1183,15 @@
public String toString() {
StringBuffer result = new StringBuffer();
- result.append("Element: [");
+ result.append("Element: ["); //$NON-NLS-1$
result.append(element);
- result.append("]; Type: [");
+ result.append("]; Type: ["); //$NON-NLS-1$
result.append(elementType);
- result.append("]; Resource: [");
+ result.append("]; Resource: ["); //$NON-NLS-1$
result.append(resource);
- result.append("]; Prefix: [");
+ result.append("]; Prefix: ["); //$NON-NLS-1$
result.append(prefix);
- result.append("]");
+ result.append("]"); //$NON-NLS-1$
return result.toString();
}
@@ -1209,9 +1209,9 @@
return type;
}
- public static final TldElementType PREFIX = new TldElementType("Prefix");
- public static final TldElementType TAG = new TldElementType("Tag");
- public static final TldElementType ATTRIBUTE = new TldElementType("Attribute");
- public static final TldElementType ATTRIBUTE_VALUE = new TldElementType("Attribute value");
+ public static final TldElementType PREFIX = new TldElementType("Prefix"); //$NON-NLS-1$
+ public static final TldElementType TAG = new TldElementType("Tag"); //$NON-NLS-1$
+ public static final TldElementType ATTRIBUTE = new TldElementType("Attribute"); //$NON-NLS-1$
+ public static final TldElementType ATTRIBUTE_VALUE = new TldElementType("Attribute value"); //$NON-NLS-1$
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/SchemaNodeFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/SchemaNodeFactory.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/SchemaNodeFactory.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -24,48 +24,48 @@
*/
public class SchemaNodeFactory {
- public static final String SCHEMA_NODE = "schema";
- public static final String ELEMENT_TYPE_NODE = "element-type";
- public static final String ATTRIBUTE_TYPE_NODE = "attribute-type";
- public static final String TLD_CONTENT_NODE = "tld-content";
- public static final String ELEMENT_NODE = "element";
- public static final String ATTRIBUTE_NODE = "attribute";
- public static final String PARAM_NODE = "param";
- public static final String GROUP_NODE = "group";
- public static final String DESCRIPTION_NODE = "description";
- public static final String PREFIX_ATTRIBUTE = "prefix";
- public static final String NAME_ATTRIBUTE = "name";
- public static final String IGNORE_CASE_ATTRIBUTE = "ignore-case";
- public static final String TYPE_ATTRIBUTE = "type";
- public static final String PROPOSAL_NODE = "proposal";
- public static final String CONTENT_ATTRIBUTE = "content";
- public static final String DEFAULT_ATTRIBUTE = "default";
- public static final String REQUIRED_ATTRIBUTE = "required";
- public static final String PREFERABLE_ATTRIBUTE = "preferable";
- public static final String URI_ATTRIBUTE = "uri";
- public static final String URL_ATTRIBUTE = "url";
- public static final String VERSION_ATTRIBUTE = "version";
- public static final String JSF_ATTRIBUTE = "jsf";
- public static final String LOCATION_ATTRIBUTE = "location";
- public static final String ROOT_ELEMENT_ATTRIBUTE = "root-element";
- public static final String VALUES_ATTRIBUTE = "values";
- public static final String VALUE_ATTRIBUTE = "value";
- public static final String ENUMERATION_TYPE = "enumeration";
+ public static final String SCHEMA_NODE = "schema"; //$NON-NLS-1$
+ public static final String ELEMENT_TYPE_NODE = "element-type"; //$NON-NLS-1$
+ public static final String ATTRIBUTE_TYPE_NODE = "attribute-type"; //$NON-NLS-1$
+ public static final String TLD_CONTENT_NODE = "tld-content"; //$NON-NLS-1$
+ public static final String ELEMENT_NODE = "element"; //$NON-NLS-1$
+ public static final String ATTRIBUTE_NODE = "attribute"; //$NON-NLS-1$
+ public static final String PARAM_NODE = "param"; //$NON-NLS-1$
+ public static final String GROUP_NODE = "group"; //$NON-NLS-1$
+ public static final String DESCRIPTION_NODE = "description"; //$NON-NLS-1$
+ public static final String PREFIX_ATTRIBUTE = "prefix"; //$NON-NLS-1$
+ public static final String NAME_ATTRIBUTE = "name"; //$NON-NLS-1$
+ public static final String IGNORE_CASE_ATTRIBUTE = "ignore-case"; //$NON-NLS-1$
+ public static final String TYPE_ATTRIBUTE = "type"; //$NON-NLS-1$
+ public static final String PROPOSAL_NODE = "proposal"; //$NON-NLS-1$
+ public static final String CONTENT_ATTRIBUTE = "content"; //$NON-NLS-1$
+ public static final String DEFAULT_ATTRIBUTE = "default"; //$NON-NLS-1$
+ public static final String REQUIRED_ATTRIBUTE = "required"; //$NON-NLS-1$
+ public static final String PREFERABLE_ATTRIBUTE = "preferable"; //$NON-NLS-1$
+ public static final String URI_ATTRIBUTE = "uri"; //$NON-NLS-1$
+ public static final String URL_ATTRIBUTE = "url"; //$NON-NLS-1$
+ public static final String VERSION_ATTRIBUTE = "version"; //$NON-NLS-1$
+ public static final String JSF_ATTRIBUTE = "jsf"; //$NON-NLS-1$
+ public static final String LOCATION_ATTRIBUTE = "location"; //$NON-NLS-1$
+ public static final String ROOT_ELEMENT_ATTRIBUTE = "root-element"; //$NON-NLS-1$
+ public static final String VALUES_ATTRIBUTE = "values"; //$NON-NLS-1$
+ public static final String VALUE_ATTRIBUTE = "value"; //$NON-NLS-1$
+ public static final String ENUMERATION_TYPE = "enumeration"; //$NON-NLS-1$
public static final String BUNDLE_NAME_TYPE = KbDinamicResource.BUNDLE_NAME_TYPE;
- public static final String ENUMERATION_SEPARATOR = ",";
- public static final String ATTRIBUTE_TYPE_SEPARATOR = ",";
- public static final String CONTENT_TYPE_MIXED = "mixed";
- public static final String TRUE_REQUIRED_ATTRIBUTE = "true";
- public static final String FALSE_REQUIRED_ATTRIBUTE = "false";
- public static final String START_TAG_ATTRIBUTE = "start-tag";
- public static final String END_TAG_ATTRIBUTE = "end-tag";
- public static final String OPTIONAL_TAG_TYPE = "optional";
- public static final String REQUIRED_TAG_TYPE = "required";
- public static final String REFUSED_TAG_TYPE = "refused";
- public static final String BODY_CONTENT_ATTRIBUTE = "body-content";
- public static final String ALLOWED_BODY_CONTENT_TYPE = "allowed";
- public static final String REFUSED_BODY_CONTENT_TYPE = "refused";
- public static final String OPTIONAL_BODY_CONTENT_TYPE = "optional";
+ public static final String ENUMERATION_SEPARATOR = ","; //$NON-NLS-1$
+ public static final String ATTRIBUTE_TYPE_SEPARATOR = ","; //$NON-NLS-1$
+ public static final String CONTENT_TYPE_MIXED = "mixed"; //$NON-NLS-1$
+ public static final String TRUE_REQUIRED_ATTRIBUTE = "true"; //$NON-NLS-1$
+ public static final String FALSE_REQUIRED_ATTRIBUTE = "false"; //$NON-NLS-1$
+ public static final String START_TAG_ATTRIBUTE = "start-tag"; //$NON-NLS-1$
+ public static final String END_TAG_ATTRIBUTE = "end-tag"; //$NON-NLS-1$
+ public static final String OPTIONAL_TAG_TYPE = "optional"; //$NON-NLS-1$
+ public static final String REQUIRED_TAG_TYPE = "required"; //$NON-NLS-1$
+ public static final String REFUSED_TAG_TYPE = "refused"; //$NON-NLS-1$
+ public static final String BODY_CONTENT_ATTRIBUTE = "body-content"; //$NON-NLS-1$
+ public static final String ALLOWED_BODY_CONTENT_TYPE = "allowed"; //$NON-NLS-1$
+ public static final String REFUSED_BODY_CONTENT_TYPE = "refused"; //$NON-NLS-1$
+ public static final String OPTIONAL_BODY_CONTENT_TYPE = "optional"; //$NON-NLS-1$
public static final char WILD_CARD_CHAR = '*';
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/TagDescriptor.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/TagDescriptor.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/TagDescriptor.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -58,13 +58,13 @@
*/
public String toString() {
StringBuffer sb = new StringBuffer();
- sb.append("[tagName=")
+ sb.append("[tagName=") //$NON-NLS-1$
.append(tagName)
- .append("; hasBody=")
+ .append("; hasBody=") //$NON-NLS-1$
.append(hasBody)
- .append("; hasClosingTag=")
+ .append("; hasClosingTag=") //$NON-NLS-1$
.append(hasClosingTag)
- .append(";]");
+ .append(";]"); //$NON-NLS-1$
return sb.toString();
}
@@ -156,7 +156,7 @@
public KbProposal generateProposal() {
KbProposal proposal = new KbProposal();
- String endTag = hasBody()?"":" /";
+ String endTag = hasBody()?"":" /"; //$NON-NLS-1$ //$NON-NLS-2$
StringBuffer lb = new StringBuffer();
if(prefix!=null && prefix.length()>0) {
lb.append(prefix);
@@ -171,7 +171,7 @@
for(int i=0; i<attributeList.size(); i++) {
AttributeDescriptor attribute = (AttributeDescriptor)attributeList.get(i);
if(attribute.isRequired()) {
- attributes.append(" ").append(attribute.getName()).append("=\"\"");
+ attributes.append(" ").append(attribute.getName()).append("=\"\""); //$NON-NLS-1$ //$NON-NLS-2$
}
}
lb.append(attributes);
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfiguration.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfiguration.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfiguration.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -15,15 +15,15 @@
*/
public interface KbConfiguration {
- public static final String SCHEMA_FOLDER_NAME = "schemas";
- public static final String SCHEMA_DTD_FOLDER_NAME = "dtd";
- public static final String SCHEMA_TLD_FOLDER_NAME = "tld";
- public static final String SCHEMA_HTML_FOLDER_NAME = "html";
- public static final String SCHEMA_JSP_FOLDER_NAME = "jsp";
- public static final String SCHEMA_HTML_FILE_NAME = "htmlschema.xml";
- public static final String SCHEMA_JSP_FILE_NAME = "jspschema.xml";
- public static final String SCHEMA_JSP_DIRECTIVE_FILE_NAME = "jspdirectiveschema.xml";
- public static final String HTML_MAP_FILE_NAME = "htmlmap.object";
+ public static final String SCHEMA_FOLDER_NAME = "schemas"; //$NON-NLS-1$
+ public static final String SCHEMA_DTD_FOLDER_NAME = "dtd"; //$NON-NLS-1$
+ public static final String SCHEMA_TLD_FOLDER_NAME = "tld"; //$NON-NLS-1$
+ public static final String SCHEMA_HTML_FOLDER_NAME = "html"; //$NON-NLS-1$
+ public static final String SCHEMA_JSP_FOLDER_NAME = "jsp"; //$NON-NLS-1$
+ public static final String SCHEMA_HTML_FILE_NAME = "htmlschema.xml"; //$NON-NLS-1$
+ public static final String SCHEMA_JSP_FILE_NAME = "jspschema.xml"; //$NON-NLS-1$
+ public static final String SCHEMA_JSP_DIRECTIVE_FILE_NAME = "jspdirectiveschema.xml"; //$NON-NLS-1$
+ public static final String HTML_MAP_FILE_NAME = "htmlmap.object"; //$NON-NLS-1$
/**
*
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfigurationFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfigurationFactory.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbConfigurationFactory.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -15,10 +15,10 @@
*/
public class KbConfigurationFactory {
- public static final String CONFIGURATION_SYSTEM_PROPERTY_NAME = "org.jboss.tools.common.kb.configuration";
+ public static final String CONFIGURATION_SYSTEM_PROPERTY_NAME = "org.jboss.tools.common.kb.configuration"; //$NON-NLS-1$
- public static final String TEST_CONFIGURATION = "test";
- public static final String PLUGIN_CONFIGURATION = "plugin";
+ public static final String TEST_CONFIGURATION = "test"; //$NON-NLS-1$
+ public static final String PLUGIN_CONFIGURATION = "plugin"; //$NON-NLS-1$
private static final KbConfigurationFactory INSTANCE = new KbConfigurationFactory();
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbPluginConfiguration.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbPluginConfiguration.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/configuration/KbPluginConfiguration.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -24,7 +24,7 @@
public static final String CUSTOM_SCHEMA_LOCATION = copyKbSchemasFromPluginToWorkSpace();
public static final String CUSTOM_SCHEMA_DTD_LOCATION = CUSTOM_SCHEMA_LOCATION + File.separator + SCHEMA_DTD_FOLDER_NAME;
- public static final String CUSTOM_SCHEMA_TLD_LOCATION = CUSTOM_SCHEMA_LOCATION + File.separator + "custom" + File.separator + SCHEMA_TLD_FOLDER_NAME;
+ public static final String CUSTOM_SCHEMA_TLD_LOCATION = CUSTOM_SCHEMA_LOCATION + File.separator + "custom" + File.separator + SCHEMA_TLD_FOLDER_NAME; //$NON-NLS-1$
public static final String SCHEMA_HTML_FILE_LOCATION = KbPlugin.getDefault().getLocation() + File.separator + SCHEMA_FOLDER_NAME + File.separator + SCHEMA_HTML_FOLDER_NAME + File.separator + SCHEMA_HTML_FILE_NAME;
public static final String SCHEMA_JSP_FILE_LOCATION = KbPlugin.getDefault().getLocation() + File.separator + SCHEMA_FOLDER_NAME + File.separator + SCHEMA_JSP_FOLDER_NAME + File.separator + SCHEMA_JSP_FILE_NAME;
public static final String CUSTOM_SCHEMA_JSP_DIRECTIVE_FILE_LOCATION = CUSTOM_SCHEMA_LOCATION + File.separator + SCHEMA_JSP_FOLDER_NAME + File.separator + SCHEMA_JSP_DIRECTIVE_FILE_NAME;
@@ -36,7 +36,7 @@
}
private static String copyKbSchemasFromPluginToWorkSpace() {
- IPath path = Platform.getLocation().append(".metadata/.plugins/").append(KbPlugin.PLUGIN_ID).append(SCHEMA_FOLDER_NAME);
+ IPath path = Platform.getLocation().append(".metadata/.plugins/").append(KbPlugin.PLUGIN_ID).append(SCHEMA_FOLDER_NAME); //$NON-NLS-1$
File workSpaceCustomSchemaLocation = path.toFile();
return workSpaceCustomSchemaLocation.toString();
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/JspWtpKbConnector.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/JspWtpKbConnector.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/JspWtpKbConnector.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -104,7 +104,7 @@
*/
public JspWtpKbConnector() {
jspResource = KbTldStore.getInstance().getJspResource();
- ((KbTldResource)jspResource).addPrefix("jsp");
+ ((KbTldResource)jspResource).addPrefix("jsp"); //$NON-NLS-1$
registerResources = new ArrayList<KbResource>();
registerJspResource();
registretedDinamicResources = new ArrayList<KbDinamicResource>();
@@ -135,8 +135,8 @@
* @see org.jboss.tools.common.kb.wtp.WtpKbConnector#getProposal(java.lang.String)
*/
public KbProposal getProposal(String query) throws KbException {
- if(!query.endsWith("/")) {
- query = query + "/";
+ if(!query.endsWith("/")) { //$NON-NLS-1$
+ query = query + "/"; //$NON-NLS-1$
}
// tracing would be fine here
// KbPlugin.log(query);
@@ -216,7 +216,7 @@
*/
public Collection<KbProposal> getProposals(String query) throws KbException {
boolean emptyQuery = false;
- if(query.equals("/")) {
+ if(query.equals("/")) { //$NON-NLS-1$
emptyQuery = true;
}
if(emptyQuery) {
@@ -301,7 +301,7 @@
registretedDinamicResources.add((KbDinamicResource)resource);
KbTldStore.getInstance().registerResource(resource);
} else {
- throw new IllegalArgumentException("JspWtpKbConnector.registerResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource");
+ throw new IllegalArgumentException("JspWtpKbConnector.registerResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource"); //$NON-NLS-1$
}
if(clearCash) {
clearCache(modified, false);
@@ -326,7 +326,7 @@
}
KbTldStore store = KbTldStore.getInstance();
- KbTldResource resource = new KbTldResource(uri, "", "", version);
+ KbTldResource resource = new KbTldResource(uri, "", "", version); //$NON-NLS-1$ //$NON-NLS-2$
List<String> result = store.getAllTagNamesFromResource(resource);
getTagNamesCache().put(key, result);
return result;
@@ -356,7 +356,7 @@
KbTldStore.getInstance().unregisterResource(resource);
registretedDinamicResources.remove(resource);
} else {
- throw new IllegalArgumentException("JspKbConnector.unregisterResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource");
+ throw new IllegalArgumentException("JspKbConnector.unregisterResource(KbResource resource): resource must be instance of KbTldResource or KbDinamicResource"); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/WtpKbConnector.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/WtpKbConnector.java 2009-05-27 06:37:36 UTC (rev 15546)
+++ trunk/common/plugins/org.jboss.tools.common.kb/src/org/jboss/tools/common/kb/wtp/WtpKbConnector.java 2009-05-27 06:43:21 UTC (rev 15547)
@@ -22,7 +22,7 @@
* @author Igels
*/
public interface WtpKbConnector extends KbConnector {
- public static String ADD_HTML_PREFIX = "4YTR:";
+ public static String ADD_HTML_PREFIX = "4YTR:"; //$NON-NLS-1$
/**
*
14 years, 11 months
JBoss Tools SVN: r15546 - in trunk/smooks/plugins: org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/core and 8 other directories.
by jbosstools-commits@lists.jboss.org
Author: DartPeng
Date: 2009-05-27 02:37:36 -0400 (Wed, 27 May 2009)
New Revision: 15546
Added:
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextContentProposal.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextProposalProvider.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertiesProposalProvider.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/MultiTextContentAdapter.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodContentProposal.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodProposalProvider.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/XMLStructuredModelProposal.java
Modified:
trunk/smooks/plugins/org.jboss.tools.smooks.core/plugin.properties
trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/core/SmooksCoreActivator.java
trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/esbrouting/provider/RouteBeanItemProvider.java
trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/javabean/impl/JavabeanPackageImpl.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/PropertyUICreator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SelectoreSelectionDialog.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SmooksStuffPropertyDetailPage.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/freemarker/TemplateUICreator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaMethodsSelectionDialog.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaPropertiesSelectionDialog.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanExpressionUICreator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanWiringUICreator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/PropertiesAndSetterMethodSearchFieldEditorCreator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/smooks/ConditionTypeUICreator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BeanIdRefProposalProvider.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertyUtils.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SelectorContentProposalProvider.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SmooksUIUtils.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/AbstractValidator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/BeanIdRefValidator.java
trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/SmooksModelValidator.java
Log:
JBIDE-4232
1.Fix a bug (set Text value to CDATA , there is a superfluous '\r')
2.Re-design the details page of Wiring and Value Binding
3.Add content assist for "SetterMethod" and "Property" text control.
4.Add content assist for "Expression". ( I like this feature)
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.core/plugin.properties
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.core/plugin.properties 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.core/plugin.properties 2009-05-27 06:37:36 UTC (rev 15546)
@@ -180,7 +180,7 @@
_UI_InlineDirective_replace_literal = replace
_UI_InlineDirective_insertbefore_literal = insertbefore
_UI_InlineDirective_insertafter_literal = insertafter
-_UI_BindingsType_type = Bindings
+_UI_BindingsType_type = Java Object
_UI_DecodeParamType_type = Decode Param
_UI_ExpressionType_type = Expression
_UI_ValueType_type = Value Binding
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/core/SmooksCoreActivator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/core/SmooksCoreActivator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/core/SmooksCoreActivator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -1,5 +1,6 @@
package org.jboss.tools.smooks.core;
+import org.eclipse.jface.resource.ImageRegistry;
import org.eclipse.ui.plugin.AbstractUIPlugin;
import org.osgi.framework.BundleContext;
@@ -47,4 +48,15 @@
return plugin;
}
+ /* (non-Javadoc)
+ * @see org.eclipse.ui.plugin.AbstractUIPlugin#initializeImageRegistry(org.eclipse.jface.resource.ImageRegistry)
+ */
+ @Override
+ protected void initializeImageRegistry(ImageRegistry reg) {
+ super.initializeImageRegistry(reg);
+ reg.put("BindingsType",imageDescriptorFromPlugin(PLUGIN_ID, "/icons/full/obj16/BindingsType.gif"));
+ reg.put("ExpressionType",imageDescriptorFromPlugin(PLUGIN_ID, "/icons/full/obj16/ExpressionType.gif"));
+ reg.put("ValueType",imageDescriptorFromPlugin(PLUGIN_ID, "/icons/full/obj16/ValueType.gif"));
+ reg.put("WiringType",imageDescriptorFromPlugin(PLUGIN_ID, "/icons/full/obj16/WiringType.gif"));
+ }
}
\ No newline at end of file
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/esbrouting/provider/RouteBeanItemProvider.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/esbrouting/provider/RouteBeanItemProvider.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/esbrouting/provider/RouteBeanItemProvider.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -246,10 +246,19 @@
*/
@Override
public String getText(Object object) {
+
String label = ((RouteBean)object).getToServiceName();
- return label == null || label.length() == 0 ?
- getString("_UI_RouteBean_type") :
- getString("_UI_RouteBean_type") + " " + label;
+ String categoryName = ((RouteBean)object).getToServiceCategory();
+ boolean returnServiceName = false;
+ if(label != null && label.length() != 0 && categoryName != null && categoryName.length() != 0){
+ returnServiceName = true;
+ }
+ if(returnServiceName){
+ return getString("_UI_RouteBean_type") + " (" + label+" : " + categoryName + ")";
+ }else{
+ return getString("_UI_RouteBean_type");
+ }
+
}
/**
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/javabean/impl/JavabeanPackageImpl.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/javabean/impl/JavabeanPackageImpl.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.core/src/org/jboss/tools/smooks/model/javabean/impl/JavabeanPackageImpl.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -890,7 +890,7 @@
source,
new String[] {
"name", "expression_._type",
- "kind", "simple"
+ "kind", "mixed"
});
addAnnotation
(getExpressionType_Value(),
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/PropertyUICreator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/PropertyUICreator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/PropertyUICreator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -243,7 +243,7 @@
if (editValue != null) {
combo.setText(editValue.toString());
}
- List<String> list = SmooksUIUtils.getBeanIdList(smooksResourceList);
+ List<String> list = SmooksUIUtils.getBeanIdStringList(smooksResourceList);
for (Iterator<String> iterator = list.iterator(); iterator.hasNext();) {
String beanId = (String) iterator.next();
combo.add(beanId);
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SelectoreSelectionDialog.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SelectoreSelectionDialog.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SelectoreSelectionDialog.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -255,8 +255,8 @@
if (model != null) {
list.add(model);
}
- } finally {
-
+ }catch(Throwable t){
+ // ignore
}
}
if (SmooksModelUtils.INPUT_TYPE_XML.equals(type)) {
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SmooksStuffPropertyDetailPage.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SmooksStuffPropertyDetailPage.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/SmooksStuffPropertyDetailPage.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -124,6 +124,7 @@
if (list != null) {
for (Iterator<?> iterator = list.iterator(); iterator.hasNext();) {
AttributeFieldEditPart attributeFieldEditPart = (AttributeFieldEditPart) iterator.next();
+ if(attributeFieldEditPart == null) continue;
Object attribute = attributeFieldEditPart.getAttribute();
if (attribute != null && attributeFieldEditPart != null) {
currentPropertyUIMap.put(attribute, attributeFieldEditPart);
@@ -158,6 +159,7 @@
if (list != null) {
for (Iterator<?> iterator = list.iterator(); iterator.hasNext();) {
AttributeFieldEditPart attributeFieldEditPart = (AttributeFieldEditPart) iterator.next();
+ if(attributeFieldEditPart == null) continue;
Object attribute = attributeFieldEditPart.getAttribute();
if (attribute != null && attributeFieldEditPart != null) {
currentPropertyUIMap.put(attribute, attributeFieldEditPart);
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/freemarker/TemplateUICreator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/freemarker/TemplateUICreator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/freemarker/TemplateUICreator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -14,16 +14,21 @@
import java.util.List;
import org.eclipse.emf.ecore.EAttribute;
+import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.xml.type.AnyType;
import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain;
import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
+import org.eclipse.swt.events.DisposeEvent;
+import org.eclipse.swt.events.DisposeListener;
import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.forms.widgets.FormToolkit;
import org.jboss.tools.smooks.configuration.actions.OpenEditorEditInnerContentsAction;
import org.jboss.tools.smooks.configuration.editors.AttributeFieldEditPart;
import org.jboss.tools.smooks.configuration.editors.PropertyUICreator;
import org.jboss.tools.smooks.configuration.editors.SmooksMultiFormEditor;
+import org.jboss.tools.smooks.configuration.editors.uitls.FieldAssistDisposer;
import org.jboss.tools.smooks.configuration.editors.uitls.SmooksUIUtils;
import org.jboss.tools.smooks.model.freemarker.FreemarkerPackage;
@@ -60,6 +65,26 @@
AttributeFieldEditPart cdatatext = SmooksUIUtils.createCDATAFieldEditor("Inline Template", editingdomain,
toolkit, parent, model, openCDATAEditorAction, true);
+ Control c = cdatatext.getContentControl();
+
+ if (c instanceof Text) {
+ final FieldAssistDisposer disposer = SmooksUIUtils.addBindingsContextAssistToText((Text) c, SmooksUIUtils
+ .getSmooks11ResourceListType((EObject) model));
+ c.addDisposeListener(new DisposeListener() {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.swt.events.DisposeListener#widgetDisposed(org
+ * .eclipse.swt.events.DisposeEvent)
+ */
+ public void widgetDisposed(DisposeEvent e) {
+ disposer.dispose();
+ }
+
+ });
+ }
list.add(cdatatext);
// AttributeFieldEditPart commenttext =
// SmooksUIUtils.createCommentFieldEditor("Template Contents(Comment)",
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaMethodsSelectionDialog.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaMethodsSelectionDialog.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaMethodsSelectionDialog.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -63,13 +63,16 @@
MethodSelectionDialog dialog = new MethodSelectionDialog(shell, resource, clazz);
if (dialog.open() == Dialog.OK) {
Method pd = (Method) dialog.getCurrentSelection();
+ if(pd == null){
+ return null;
+ }
return pd.getName();
}else{
return null;
}
}
MessageDialog.openInformation(shell, "Can't open dialog",
- "Can't open java methods selection dialog.");
+ "Can't open java methods selection dialog.Please check the 'class' value of Java Object.");
return null;
}
@@ -103,7 +106,7 @@
fl.marginHeight = 10;
fl.marginWidth = 10;
composite.setLayout(fl);
- viewer = new TableViewer(composite, SWT.BORDER);
+ viewer = new TableViewer(composite, SWT.BORDER|SWT.FULL_SELECTION);
Table table = viewer.getTable();
TableColumn nameColumn = new TableColumn(table, SWT.NONE);
nameColumn.setWidth(100);
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaPropertiesSelectionDialog.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaPropertiesSelectionDialog.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavaPropertiesSelectionDialog.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -10,9 +10,10 @@
******************************************************************************/
package org.jboss.tools.smooks.configuration.editors.javabean;
-import java.beans.PropertyDescriptor;
+import java.lang.reflect.Array;
import org.eclipse.jdt.core.IJavaProject;
+import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jface.dialogs.Dialog;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.viewers.DoubleClickEvent;
@@ -39,7 +40,7 @@
import org.jboss.tools.smooks.configuration.editors.GraphicsConstants;
import org.jboss.tools.smooks.configuration.editors.uitls.IFieldDialog;
import org.jboss.tools.smooks.configuration.editors.uitls.IModelProcsser;
-import org.jboss.tools.smooks.configuration.editors.uitls.JavaPropertyUtils;
+import org.jboss.tools.smooks.configuration.editors.uitls.ProjectClassLoader;
/**
* @author Dart (dpeng(a)redhat.com)
@@ -48,28 +49,54 @@
*/
public class JavaPropertiesSelectionDialog implements IFieldDialog {
- private IJavaProject resource;
+ private IJavaProject project;
- private Class<?> clazz;
+ private String className;
- public JavaPropertiesSelectionDialog(IJavaProject resource, Class<?> clazz) {
+ public JavaPropertiesSelectionDialog(IJavaProject resource, String className) {
super();
- this.resource = resource;
- this.clazz = clazz;
+ this.project = resource;
+ this.className = className;
}
public Object open(Shell shell) {
- if (resource != null && clazz != null) {
- PropertySelectionDialog dialog = new PropertySelectionDialog(shell, resource, clazz);
- if (dialog.open() == Dialog.OK) {
- PropertyDescriptor pd = (PropertyDescriptor) dialog.getCurrentSelection();
- return pd.getName();
- }else{
- return null;
+ String errorMessage = "";
+ if(project == null){
+ errorMessage = "Please make sure the project is the 'Java Project'";
+ }
+ try {
+ if (project != null && className != null) {
+ Class<?> clazz = null;
+ ProjectClassLoader classLoader;
+
+ classLoader = new ProjectClassLoader(project);
+
+ if (className.endsWith("[]")) {
+ String arrayClassName = className.substring(0, className.length() - 2);
+ clazz = classLoader.loadClass(arrayClassName);
+ Object arrayInstance = Array.newInstance(clazz, 0);
+ clazz = arrayInstance.getClass();
+ } else {
+ clazz = classLoader.loadClass(className);
+ }
+ JavaBeanModel beanModel = JavaBeanModelFactory.getJavaBeanModel(clazz);
+ PropertySelectionDialog dialog = new PropertySelectionDialog(shell, project, beanModel);
+ if (dialog.open() == Dialog.OK) {
+ JavaBeanModel pd = (JavaBeanModel) dialog.getCurrentSelection();
+ if(pd == null){
+ return null;
+ }
+ return pd.getName();
+ } else {
+ return null;
+ }
}
+ } catch (JavaModelException e) {
+ errorMessage = "";
+ } catch (ClassNotFoundException e) {
+ errorMessage = "'" + className + "' can't be found.";
}
- MessageDialog.openInformation(shell, "Can't open dialog",
- "Can't open java properties selection dialog.");
+ MessageDialog.openInformation(shell, "Can't open dialog", "Can't get properties of '" + className + "'.\n" + errorMessage);
return null;
}
@@ -77,19 +104,17 @@
private TableViewer viewer;
- private Class<?> clazz;
-
private Object currentSelection;
-
-
+ private JavaBeanModel beanModel = null;
+
public PropertySelectionDialog(IShellProvider parentShell) {
super(parentShell);
}
- public PropertySelectionDialog(Shell parentShell, IJavaProject project, Class<?> clazz) {
+ public PropertySelectionDialog(Shell parentShell, IJavaProject project, JavaBeanModel beanModel) {
super(parentShell);
- this.clazz = clazz;
+ this.beanModel = beanModel;
}
@Override
@@ -103,7 +128,7 @@
fl.marginHeight = 10;
fl.marginWidth = 10;
composite.setLayout(fl);
- viewer = new TableViewer(composite, SWT.BORDER);
+ viewer = new TableViewer(composite, SWT.BORDER|SWT.FULL_SELECTION);
Table table = viewer.getTable();
TableColumn nameColumn = new TableColumn(table, SWT.NONE);
nameColumn.setWidth(100);
@@ -114,9 +139,8 @@
table.setHeaderVisible(true);
viewer.setContentProvider(new PropertyDescriptorContentProvider());
viewer.setLabelProvider(new PropertyDescriptorLabelProvider());
- PropertyDescriptor[] pds = JavaPropertyUtils.getPropertyDescriptor(clazz);
- viewer.setInput(pds);
- viewer.addDoubleClickListener(new IDoubleClickListener(){
+ viewer.setInput(beanModel);
+ viewer.addDoubleClickListener(new IDoubleClickListener() {
public void doubleClick(DoubleClickEvent event) {
okPressed();
}
@@ -126,7 +150,7 @@
currentSelection = ((IStructuredSelection) event.getSelection()).getFirstElement();
}
});
- getShell().setText(clazz.getSimpleName() + "'s Properties");
+ getShell().setText(beanModel.getName() + "'s Properties");
return composite;
}
@@ -142,6 +166,9 @@
private class PropertyDescriptorContentProvider implements IStructuredContentProvider {
public Object[] getElements(Object inputElement) {
+ if (inputElement instanceof JavaBeanModel) {
+ return ((JavaBeanModel) inputElement).getChildren().toArray();
+ }
if (inputElement.getClass().isArray()) {
return (Object[]) inputElement;
}
@@ -168,17 +195,13 @@
}
public String getColumnText(Object element, int columnIndex) {
- if (element instanceof PropertyDescriptor) {
- PropertyDescriptor p = (PropertyDescriptor) element;
+ if (element instanceof JavaBeanModel) {
+ JavaBeanModel p = (JavaBeanModel) element;
switch (columnIndex) {
case 0:
return p.getName();
case 1:
- Class<?> cla = p.getPropertyType();
- if(cla.isArray()){
- return cla.getComponentType().getName() + "[]";
- }
- return cla.getName();
+ return p.getBeanClassString();
}
}
return getText(element);
@@ -192,6 +215,6 @@
public void setModelProcesser(IModelProcsser processer) {
// TODO Auto-generated method stub
-
+
}
}
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanExpressionUICreator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanExpressionUICreator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanExpressionUICreator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -14,17 +14,19 @@
import java.util.List;
import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.xml.type.AnyType;
+import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain;
import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
+import org.eclipse.swt.events.DisposeEvent;
+import org.eclipse.swt.events.DisposeListener;
import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.jboss.tools.smooks.configuration.actions.OpenEditorEditInnerContentsAction;
import org.jboss.tools.smooks.configuration.editors.AttributeFieldEditPart;
import org.jboss.tools.smooks.configuration.editors.IPropertyUICreator;
-import org.jboss.tools.smooks.configuration.editors.PropertyUICreator;
import org.jboss.tools.smooks.configuration.editors.SmooksMultiFormEditor;
+import org.jboss.tools.smooks.configuration.editors.uitls.FieldAssistDisposer;
import org.jboss.tools.smooks.configuration.editors.uitls.SmooksUIUtils;
import org.jboss.tools.smooks.model.javabean.JavabeanPackage;
@@ -32,7 +34,8 @@
* @author Dart (dpeng(a)redhat.com)
*
*/
-public class JavabeanExpressionUICreator extends PropertyUICreator implements IPropertyUICreator {
+public class JavabeanExpressionUICreator extends PropertiesAndSetterMethodSearchFieldEditorCreator implements
+ IPropertyUICreator {
/*
* (non-Javadoc)
@@ -45,34 +48,50 @@
* org.jboss.tools.smooks.configuration.editors.SmooksMultiFormEditor)
*/
@Override
- public List<AttributeFieldEditPart> createExtendUIOnBottom(AdapterFactoryEditingDomain editingdomain, FormToolkit toolkit,
- Composite parent, Object model, SmooksMultiFormEditor formEditor) {
+ public List<AttributeFieldEditPart> createExtendUIOnBottom(AdapterFactoryEditingDomain editingdomain,
+ FormToolkit toolkit, Composite parent, Object model, SmooksMultiFormEditor formEditor) {
List<AttributeFieldEditPart> list = new ArrayList<AttributeFieldEditPart>();
- OpenEditorEditInnerContentsAction openCDATAEditorAction = new OpenEditorEditInnerContentsAction(editingdomain,
- (AnyType) model, SmooksUIUtils.VALUE_TYPE_TEXT, "txt");
+ AttributeFieldEditPart cdatatext = SmooksUIUtils.createCDATAFieldEditor("Expression", editingdomain, toolkit,
+ parent, model, null, true);
+ if (cdatatext != null) {
+ list.add(cdatatext);
+
+ Control c = cdatatext.getContentControl();
+
+ if(c instanceof Text){
+ final FieldAssistDisposer disposer = SmooksUIUtils.addBindingsContextAssistToText((Text)c, SmooksUIUtils.getSmooks11ResourceListType((EObject)model));
+ c.addDisposeListener(new DisposeListener(){
- AttributeFieldEditPart cdatatext = SmooksUIUtils.createStringFieldEditor("Expression", parent, editingdomain,
- toolkit, null, model, true, false, false, 300, null, SmooksUIUtils.VALUE_TYPE_TEXT,
- openCDATAEditorAction);
-
- if(cdatatext != null){
- list.add(cdatatext);
+ /* (non-Javadoc)
+ * @see org.eclipse.swt.events.DisposeListener#widgetDisposed(org.eclipse.swt.events.DisposeEvent)
+ */
+ public void widgetDisposed(DisposeEvent e) {
+ disposer.dispose();
+ }
+
+ });
+ }
}
- openCDATAEditorAction.setRelateText((Text)cdatatext.getContentControl());
-
return list;
}
-
- public List<AttributeFieldEditPart> createExtendUIOnTop(AdapterFactoryEditingDomain editingdomain, FormToolkit toolkit,
- Composite parent, Object model, SmooksMultiFormEditor formEditor) {
- List<AttributeFieldEditPart> list = createElementSelectionSection("Execute On Element", editingdomain, toolkit,
- parent, model, formEditor, JavabeanPackage.Literals.EXPRESSION_TYPE__EXEC_ON_ELEMENT,
- JavabeanPackage.Literals.EXPRESSION_TYPE__EXEC_ON_ELEMENT_NS);
-
+
+ public List<AttributeFieldEditPart> createExtendUIOnTop(AdapterFactoryEditingDomain editingdomain,
+ FormToolkit toolkit, Composite parent, Object model, SmooksMultiFormEditor formEditor) {
+
+ List<AttributeFieldEditPart> list = new ArrayList<AttributeFieldEditPart>();
+
+ AttributeFieldEditPart pEditPart = createPropertiesSearchFieldEditor(toolkit, parent, getPropertyDescriptor(
+ editingdomain, JavabeanPackage.Literals.EXPRESSION_TYPE__PROPERTY, model), model);
+ AttributeFieldEditPart mEditPart = createMethodsSearchFieldEditor(toolkit, parent, getPropertyDescriptor(
+ editingdomain, JavabeanPackage.Literals.EXPRESSION_TYPE__SETTER_METHOD, model), model);
+ list.add(pEditPart);
+ list.add(mEditPart);
+ list.addAll(createElementSelectionSection("Execute On Element", editingdomain, toolkit, parent, model,
+ formEditor, JavabeanPackage.Literals.EXPRESSION_TYPE__EXEC_ON_ELEMENT,
+ JavabeanPackage.Literals.EXPRESSION_TYPE__EXEC_ON_ELEMENT_NS));
+
return list;
}
-
-
/*
* (non-Javadoc)
@@ -92,6 +111,12 @@
if (feature == JavabeanPackage.Literals.EXPRESSION_TYPE__VALUE) {
return true;
}
+ if (feature == JavabeanPackage.Literals.EXPRESSION_TYPE__PROPERTY) {
+ return true;
+ }
+ if (feature == JavabeanPackage.Literals.EXPRESSION_TYPE__SETTER_METHOD) {
+ return true;
+ }
return super.ignoreProperty(feature);
}
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanWiringUICreator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanWiringUICreator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/JavabeanWiringUICreator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.smooks.configuration.editors.javabean;
+import java.util.ArrayList;
import java.util.List;
import org.eclipse.emf.ecore.EAttribute;
@@ -28,17 +29,18 @@
@Override
protected boolean canCreatePropertiesSearchFieldEditor(EAttribute feature) {
- if (feature == JavabeanPackage.eINSTANCE.getWiringType_Property()) {
- return true;
- }
+ // if (feature == JavabeanPackage.eINSTANCE.getWiringType_Property()) {
+ // return true;
+ // }
return false;
}
@Override
protected boolean canCreateMethodsSearchFieldEditor(EAttribute feature) {
- if (feature == JavabeanPackage.eINSTANCE.getWiringType_SetterMethod()) {
- return true;
- }
+ // if (feature ==
+ // JavabeanPackage.eINSTANCE.getWiringType_SetterMethod()) {
+ // return true;
+ // }
return super.canCreateMethodsSearchFieldEditor(feature);
}
@@ -57,6 +59,12 @@
if (feature == JavabeanPackage.eINSTANCE.getWiringType_WireOnElementNS()) {
return true;
}
+ if (feature == JavabeanPackage.eINSTANCE.getWiringType_Property()) {
+ return true;
+ }
+ if (feature == JavabeanPackage.eINSTANCE.getWiringType_SetterMethod()) {
+ return true;
+ }
return super.ignoreProperty(feature);
}
@@ -71,11 +79,21 @@
* org.jboss.tools.smooks.configuration.editors.SmooksMultiFormEditor)
*/
@Override
- public List<AttributeFieldEditPart> createExtendUIOnTop(AdapterFactoryEditingDomain editingdomain, FormToolkit toolkit,
- Composite parent, Object model, SmooksMultiFormEditor formEditor) {
- return createElementSelectionSection("Wrie On Element", editingdomain, toolkit, parent, model, formEditor,
+ public List<AttributeFieldEditPart> createExtendUIOnTop(AdapterFactoryEditingDomain editingdomain,
+ FormToolkit toolkit, Composite parent, Object model, SmooksMultiFormEditor formEditor) {
+
+ List<AttributeFieldEditPart> list = new ArrayList<AttributeFieldEditPart>();
+
+ AttributeFieldEditPart pEditPart = createPropertiesSearchFieldEditor(toolkit, parent, getPropertyDescriptor(
+ editingdomain, JavabeanPackage.eINSTANCE.getWiringType_Property(), model), model);
+ AttributeFieldEditPart mEditPart = createMethodsSearchFieldEditor(toolkit, parent, getPropertyDescriptor(
+ editingdomain, JavabeanPackage.eINSTANCE.getWiringType_SetterMethod(), model), model);
+ list.add(pEditPart);
+ list.add(mEditPart);
+ list.addAll(createElementSelectionSection("Wrie On Element", editingdomain, toolkit, parent, model, formEditor,
JavabeanPackage.eINSTANCE.getWiringType_WireOnElement(),
- JavabeanPackage.Literals.WIRING_TYPE__WIRE_ON_ELEMENT_NS);
+ JavabeanPackage.Literals.WIRING_TYPE__WIRE_ON_ELEMENT_NS));
+ return list;
}
@Override
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/PropertiesAndSetterMethodSearchFieldEditorCreator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/PropertiesAndSetterMethodSearchFieldEditorCreator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/javabean/PropertiesAndSetterMethodSearchFieldEditorCreator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -47,11 +47,11 @@
}
protected String getPropertiesSearchButtonName(){
- return "Search property";
+ return "Browse";
}
protected String getMethodsSearchButtonName(){
- return "Search setter method";
+ return "Browse";
}
protected AttributeFieldEditPart createPropertiesSearchFieldEditor(FormToolkit toolkit, Composite parent,
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/smooks/ConditionTypeUICreator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/smooks/ConditionTypeUICreator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/smooks/ConditionTypeUICreator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -13,15 +13,21 @@
import java.util.ArrayList;
import java.util.List;
+
import org.eclipse.emf.ecore.EAttribute;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain;
import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
+import org.eclipse.swt.events.DisposeEvent;
+import org.eclipse.swt.events.DisposeListener;
import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.forms.widgets.FormToolkit;
import org.jboss.tools.smooks.configuration.editors.AttributeFieldEditPart;
import org.jboss.tools.smooks.configuration.editors.PropertyUICreator;
import org.jboss.tools.smooks.configuration.editors.SmooksMultiFormEditor;
+import org.jboss.tools.smooks.configuration.editors.uitls.FieldAssistDisposer;
import org.jboss.tools.smooks.configuration.editors.uitls.SmooksUIUtils;
import org.jboss.tools.smooks.model.smooks.SmooksPackage;
@@ -69,8 +75,23 @@
public List<AttributeFieldEditPart> createExtendUIOnBottom(AdapterFactoryEditingDomain editingdomain,
FormToolkit toolkit, Composite parent, Object model, SmooksMultiFormEditor formEditor) {
List<AttributeFieldEditPart> list = new ArrayList<AttributeFieldEditPart>();
- AttributeFieldEditPart cdatatext = SmooksUIUtils.createCDATAFieldEditor("Condition Value", editingdomain,
+ AttributeFieldEditPart cdatatext = SmooksUIUtils.createCDATAFieldEditor("Inline Condition", editingdomain,
toolkit, parent, model, null,true);
+ Control c = cdatatext.getContentControl();
+
+ if(c instanceof Text){
+ final FieldAssistDisposer disposer = SmooksUIUtils.addBindingsContextAssistToText((Text)c, SmooksUIUtils.getSmooks11ResourceListType((EObject)model));
+ c.addDisposeListener(new DisposeListener(){
+
+ /* (non-Javadoc)
+ * @see org.eclipse.swt.events.DisposeListener#widgetDisposed(org.eclipse.swt.events.DisposeEvent)
+ */
+ public void widgetDisposed(DisposeEvent e) {
+ disposer.dispose();
+ }
+
+ });
+ }
list.add(cdatatext);
return list;
}
@@ -87,6 +108,12 @@
if (feature == SmooksPackage.eINSTANCE.getConditionType_Value()) {
return true;
}
+ if (feature == SmooksPackage.eINSTANCE.getConditionType_Evaluator()) {
+ return true;
+ }
+ if (feature == SmooksPackage.eINSTANCE.getConditionType_Id()) {
+ return true;
+ }
return super.ignoreProperty(feature);
}
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BeanIdRefProposalProvider.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BeanIdRefProposalProvider.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BeanIdRefProposalProvider.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -37,7 +37,7 @@
List<IContentProposal> proposalList = new ArrayList<IContentProposal>();
SmooksResourceListType listType = getSmooksResourceList(model);
if(listType != null){
- List<String> idList = SmooksUIUtils.getBeanIdList(listType);
+ List<String> idList = SmooksUIUtils.getBeanIdStringList(listType);
for (Iterator<String> iterator = idList.iterator(); iterator.hasNext();) {
String id = (String) iterator.next();
Added: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextContentProposal.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextContentProposal.java (rev 0)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextContentProposal.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -0,0 +1,109 @@
+/*******************************************************************************
+ * Copyright (c) 2008 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.smooks.configuration.editors.uitls;
+
+import org.eclipse.jface.fieldassist.IContentProposal;
+
+/**
+ * @author Dart (dpeng(a)redhat.com)
+ *
+ */
+public class BindingsContextContentProposal implements IContentProposal {
+
+ private int startIndex = 0;
+
+ private String content = null;
+
+ public static final int BINDINGS = 1;
+
+ public static final int PROPERTIES = 2;
+
+ public static final int WIRTINGS = 3;
+
+ public static final int EXPRESSIONS = 4;
+
+ private int type = BINDINGS;
+
+ public BindingsContextContentProposal(int type , String content,int startIndex){
+ this.startIndex = startIndex;
+ this.content = content;
+ this.type = type;
+ }
+
+
+ /**
+ * @return the type
+ */
+ public int getType() {
+ return type;
+ }
+
+
+
+ /**
+ * @param type the type to set
+ */
+ public void setType(int type) {
+ this.type = type;
+ }
+
+
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getContent()
+ */
+ public String getContent() {
+ // TODO Auto-generated method stub
+ return content;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getCursorPosition()
+ */
+ public int getCursorPosition() {
+ if(content != null){
+ return getContent().length() + startIndex ;
+ }
+ return startIndex;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getDescription()
+ */
+ public String getDescription() {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getLabel()
+ */
+ public String getLabel() {
+ String name = "";
+ if(type == BINDINGS){
+ name = "Java Object";
+ }
+ if(type == PROPERTIES){
+ name = "Value Binding";
+ }
+ if(type == WIRTINGS){
+ name = "Wiring";
+ }
+ if(type == EXPRESSIONS){
+ name = "Expression";
+ }
+ if(name.length() != 0 && content != null){
+ return content + " - ( " + name + " )";
+ }
+ return content;
+ }
+
+}
Property changes on: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextContentProposal.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextProposalProvider.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextProposalProvider.java (rev 0)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextProposalProvider.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -0,0 +1,215 @@
+/*******************************************************************************
+ * Copyright (c) 2008 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.smooks.configuration.editors.uitls;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.jface.fieldassist.IContentProposal;
+import org.eclipse.jface.fieldassist.IContentProposalProvider;
+import org.eclipse.swt.widgets.Text;
+import org.jboss.tools.smooks.model.javabean.BindingsType;
+import org.jboss.tools.smooks.model.javabean.ExpressionType;
+import org.jboss.tools.smooks.model.javabean.ValueType;
+import org.jboss.tools.smooks.model.javabean.WiringType;
+import org.jboss.tools.smooks.model.smooks.SmooksResourceListType;
+
+/**
+ * @author Dart (dpeng(a)redhat.com)
+ *
+ */
+public class BindingsContextProposalProvider implements IContentProposalProvider {
+
+ private Text textControl;
+
+ private List<BindingsType> bindingsList = null;
+
+ private List<String> bindingsIDList = null;
+
+ public BindingsContextProposalProvider(SmooksResourceListType listType, Text textControl) {
+ this.textControl = textControl;
+ bindingsList = SmooksUIUtils.getBeanIdList(listType);
+ bindingsIDList = SmooksUIUtils.getBeanIdStringList(listType);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.IContentProposalProvider#getProposals(java
+ * .lang.String, int)
+ */
+ public IContentProposal[] getProposals(String contents, int position) {
+ if (contents.length() == 2) {
+ System.out.println();
+ }
+ if (bindingsList == null || bindingsList.isEmpty()) {
+ return new IContentProposal[] {};
+ }
+ String content = textControl.getText(0, textControl.getCaretPosition() - 1);
+
+ ContextString currentContextString = loadContextString(content);
+
+ char dotChar = currentContextString.getEndChar();
+ int endIndex = currentContextString.getEndIndex();
+ String replaceContent = currentContextString.getContent();
+ List<IContentProposal> plist = new ArrayList<IContentProposal>();
+ if (dotChar == '.') {
+
+ BindingsType bindings = loadContextBindings(textControl.getText(0, endIndex - 1));
+ if (bindings != null) {
+ List<ValueType> valueList = bindings.getValue();
+ for (Iterator<?> iterator = valueList.iterator(); iterator.hasNext();) {
+ ValueType valueType = (ValueType) iterator.next();
+ String property = valueType.getProperty();
+ if (property != null) {
+ if (property.toLowerCase().startsWith(replaceContent.toLowerCase())) {
+ plist.add(new BindingsContextContentProposal(BindingsContextContentProposal.PROPERTIES,
+ property, position - replaceContent.length()));
+ }
+ }
+ }
+ List<WiringType> wiringList = bindings.getWiring();
+ for (Iterator<?> iterator = wiringList.iterator(); iterator.hasNext();) {
+ WiringType wiringType = (WiringType) iterator.next();
+ String property = wiringType.getProperty();
+ if (property != null) {
+ if (property.toLowerCase().startsWith(replaceContent.toLowerCase())) {
+ plist.add(new BindingsContextContentProposal(BindingsContextContentProposal.WIRTINGS,
+ property, position - replaceContent.length()));
+ }
+ }
+ }
+
+ List<ExpressionType> expressionList = bindings.getExpression();
+ for (Iterator<?> iterator = expressionList.iterator(); iterator.hasNext();) {
+ ExpressionType wiringType = (ExpressionType) iterator.next();
+ String property = wiringType.getProperty();
+ if (property != null) {
+ if (property.toLowerCase().startsWith(replaceContent.toLowerCase())) {
+ plist.add(new BindingsContextContentProposal(BindingsContextContentProposal.EXPRESSIONS,
+ property, position - replaceContent.length()));
+ }
+ }
+ }
+ }
+ } else {
+ for (Iterator<String> iterator = bindingsIDList.iterator(); iterator.hasNext();) {
+ String id = (String) iterator.next();
+ if (id.toLowerCase().startsWith(replaceContent.toLowerCase())) {
+ plist.add(new BindingsContextContentProposal(BindingsContextContentProposal.BINDINGS, id, position
+ - replaceContent.length()));
+ }
+ }
+ }
+
+ return plist.toArray(new IContentProposal[] {});
+ }
+
+ private BindingsType loadContextBindings(String content) {
+ ContextString cs = loadContextString(content);
+ // if (cs.endChar != '.') {
+ String name = cs.getContent();
+
+ for (Iterator<?> iterator = bindingsList.iterator(); iterator.hasNext();) {
+ BindingsType bindings = (BindingsType) iterator.next();
+ String id = bindings.getBeanId();
+ if (id != null) {
+ if (id.equalsIgnoreCase(name)) {
+ return bindings;
+ }
+ }
+ }
+ // }
+ return null;
+ }
+
+ private ContextString loadContextString(String content) {
+ char[] chars = content.toCharArray();
+ char dotChar = ' ';
+ int endIndex = 0;
+ for (int i = chars.length - 1; i > 0; i--) {
+ char c = chars[i];
+ if (c != ' ' && c != '\r' && c != '\n' && c != '\t' && Character.isLetterOrDigit(c)) {
+ continue;
+ }
+ dotChar = c;
+ endIndex = i;
+ break;
+ }
+ ContextString cs = new ContextString();
+ cs.setEndChar(dotChar);
+ if (content.length() == 0) {
+ cs.setContent(content);
+ } else {
+ cs.setContent(content.substring(endIndex + 1, content.length()));
+ }
+ if (endIndex == 0) {
+ cs.setContent(content.substring(endIndex, content.length()));
+ }
+ cs.setEndIndex(endIndex);
+ return cs;
+ }
+
+ private class ContextString {
+ char endChar = ' ';
+ String content = null;
+ int endIndex = 0;
+
+ /**
+ * @return the endIndex
+ */
+ public int getEndIndex() {
+ return endIndex;
+ }
+
+ /**
+ * @param endIndex
+ * the endIndex to set
+ */
+ public void setEndIndex(int endIndex) {
+ this.endIndex = endIndex;
+ }
+
+ /**
+ * @return the endChar
+ */
+ public char getEndChar() {
+ return endChar;
+ }
+
+ /**
+ * @param endChar
+ * the endChar to set
+ */
+ public void setEndChar(char endChar) {
+ this.endChar = endChar;
+ }
+
+ /**
+ * @return the content
+ */
+ public String getContent() {
+ return content;
+ }
+
+ /**
+ * @param content
+ * the content to set
+ */
+ public void setContent(String content) {
+ this.content = content;
+ }
+
+ }
+
+}
Property changes on: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/BindingsContextProposalProvider.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertiesProposalProvider.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertiesProposalProvider.java (rev 0)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertiesProposalProvider.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -0,0 +1,82 @@
+/*******************************************************************************
+ * Copyright (c) 2008 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.smooks.configuration.editors.uitls;
+
+import java.lang.reflect.Array;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.resources.IProject;
+import org.eclipse.jdt.core.JavaCore;
+import org.eclipse.jdt.core.JavaModelException;
+import org.eclipse.jface.fieldassist.IContentProposal;
+import org.eclipse.jface.fieldassist.IContentProposalProvider;
+import org.jboss.tools.smooks.configuration.editors.IXMLStructuredObject;
+import org.jboss.tools.smooks.configuration.editors.javabean.JavaBeanModel;
+import org.jboss.tools.smooks.configuration.editors.javabean.JavaBeanModelFactory;
+
+/**
+ * @author Dart (dpeng(a)redhat.com)
+ *
+ */
+public class JavaPropertiesProposalProvider implements IContentProposalProvider {
+
+ private JavaBeanModel beanModel;
+
+ public JavaPropertiesProposalProvider(IProject project,String className){
+ try {
+ if (project != null && className != null) {
+ Class<?> clazz = null;
+ ProjectClassLoader classLoader;
+
+ classLoader = new ProjectClassLoader(JavaCore.create(project));
+
+ if (className.endsWith("[]")) {
+ String arrayClassName = className.substring(0, className.length() - 2);
+ clazz = classLoader.loadClass(arrayClassName);
+ Object arrayInstance = Array.newInstance(clazz, 0);
+ clazz = arrayInstance.getClass();
+ } else {
+ clazz = classLoader.loadClass(className);
+ }
+ beanModel = JavaBeanModelFactory.getJavaBeanModel(clazz);
+ }
+ } catch (JavaModelException e) {
+ } catch (ClassNotFoundException e) {
+ }
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposalProvider#getProposals(java.lang.String, int)
+ */
+ public IContentProposal[] getProposals(String contents, int position) {
+ if(beanModel == null){
+ return new IContentProposal[]{};
+ }
+ List<IContentProposal> list = new ArrayList<IContentProposal>();
+ List<IXMLStructuredObject> children = beanModel.getChildren();
+ for (Iterator<?> iterator = children.iterator(); iterator.hasNext();) {
+ IXMLStructuredObject structuredObject = (IXMLStructuredObject) iterator.next();
+ if(structuredObject != null && structuredObject instanceof JavaBeanModel){
+ String name = ((JavaBeanModel)structuredObject).getName();
+ if(name != null){
+ if(name.toLowerCase().startsWith(contents.toLowerCase())){
+ list.add(new XMLStructuredModelProposal(structuredObject));
+ }
+ }
+ }
+ }
+
+ return list.toArray(new IContentProposal[]{});
+ }
+
+}
Property changes on: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertiesProposalProvider.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertyUtils.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertyUtils.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/JavaPropertyUtils.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -26,6 +26,9 @@
}
public static Method[] getSetterMethods(Class<?> clazz){
+ if(clazz == null){
+ return new Method[]{};
+ }
Method[] methods = clazz.getMethods();
List<Method> mlist = new ArrayList<Method>();
for (int i = 0; i < methods.length; i++) {
Added: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/MultiTextContentAdapter.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/MultiTextContentAdapter.java (rev 0)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/MultiTextContentAdapter.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -0,0 +1,164 @@
+/*******************************************************************************
+ * Copyright (c) 2008 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.smooks.configuration.editors.uitls;
+
+import org.eclipse.jface.fieldassist.TextContentAdapter;
+import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.graphics.Rectangle;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Text;
+
+/**
+ * @author Dart (dpeng(a)redhat.com)
+ *
+ */
+public class MultiTextContentAdapter extends TextContentAdapter {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#getControlContents(org
+ * .eclipse.swt.widgets.Control)
+ */
+ @Override
+ public String getControlContents(Control control) {
+ // TODO Auto-generated method stub
+ return super.getControlContents(control);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#getCursorPosition(org
+ * .eclipse.swt.widgets.Control)
+ */
+ @Override
+ public int getCursorPosition(Control control) {
+ // TODO Auto-generated method stub
+ return super.getCursorPosition(control);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#getInsertionBounds(org
+ * .eclipse.swt.widgets.Control)
+ */
+ @Override
+ public Rectangle getInsertionBounds(Control control) {
+ // TODO Auto-generated method stub
+ Rectangle re = super.getInsertionBounds(control);
+ return re;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#getSelection(org.eclipse
+ * .swt.widgets.Control)
+ */
+ @Override
+ public Point getSelection(Control control) {
+ // TODO Auto-generated method stub
+ return super.getSelection(control);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#insertControlContents
+ * (org.eclipse.swt.widgets.Control, java.lang.String, int)
+ */
+ @Override
+ public void insertControlContents(Control control, String text, int cursorPosition) {
+ Text te = (Text) control;
+ int caretPosition = te.getCaretPosition() - 1;
+ if (caretPosition < 0) {
+ caretPosition = 0;
+ }
+ String content = te.getText(0, caretPosition);
+ char[] chars = content.toCharArray();
+ int endIndex = 0;
+ for (int i = chars.length - 1; i > 0; i--) {
+ char c = chars[i];
+ if (c != ' ' && c != '\r' && c != '\n' && c != '\t' && Character.isLetterOrDigit(c)) {
+ continue;
+ }
+ endIndex = i;
+ break;
+ }
+ if (content.length() == 0) {
+ } else {
+ content = content.substring(endIndex + 1, content.length());
+ }
+ String all = te.getText();
+ String first="";
+ if(all.length() != 0){
+ first = all.substring(0, endIndex + 1);
+ }
+ if (endIndex == 0) {
+ first = "";
+ }
+ String second = "";
+ if(all.length() != 0){
+ second = all.substring(endIndex + 1 + content.length(), all.length());
+ }
+ if (all.length() == 1) {
+ second = "";
+ }
+ all = first + text + second;
+ te.setText(all);
+ ((Text) control).setSelection(cursorPosition, cursorPosition);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#setControlContents(org
+ * .eclipse.swt.widgets.Control, java.lang.String, int)
+ */
+ @Override
+ public void setControlContents(Control control, String text, int cursorPosition) {
+ super.setControlContents(control, text, cursorPosition);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#setCursorPosition(org
+ * .eclipse.swt.widgets.Control, int)
+ */
+ @Override
+ public void setCursorPosition(Control control, int position) {
+ // TODO Auto-generated method stub
+ super.setCursorPosition(control, position);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.fieldassist.TextContentAdapter#setSelection(org.eclipse
+ * .swt.widgets.Control, org.eclipse.swt.graphics.Point)
+ */
+ @Override
+ public void setSelection(Control control, Point range) {
+ // TODO Auto-generated method stub
+ super.setSelection(control, range);
+ }
+}
Property changes on: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/MultiTextContentAdapter.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SelectorContentProposalProvider.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SelectorContentProposalProvider.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SelectorContentProposalProvider.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -40,6 +40,9 @@
* .lang.String, int)
*/
public IContentProposal[] getProposals(String contents, int position) {
+ if(contents.indexOf("h") != -1){
+ System.out.println();
+ }
List<Object> list = SelectoreSelectionDialog.generateInputData(extType);
if(list == null || list.isEmpty()){
return new IContentProposal[]{};
Added: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodContentProposal.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodContentProposal.java (rev 0)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodContentProposal.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -0,0 +1,61 @@
+/*******************************************************************************
+ * Copyright (c) 2008 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.smooks.configuration.editors.uitls;
+
+import java.lang.reflect.Method;
+
+import org.eclipse.jface.fieldassist.IContentProposal;
+
+/**
+ * @author Dart (dpeng(a)redhat.com)
+ *
+ */
+public class SetterMethodContentProposal implements IContentProposal {
+
+
+ private String content = null;
+
+ public SetterMethodContentProposal(Method method){
+ content = method.getName();
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getContent()
+ */
+ public String getContent() {
+ return content;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getCursorPosition()
+ */
+ public int getCursorPosition() {
+ if(content != null){
+ return content.length();
+ }
+ return 0;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getDescription()
+ */
+ public String getDescription() {
+ return null;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getLabel()
+ */
+ public String getLabel() {
+ return content;
+ }
+
+}
Property changes on: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodContentProposal.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodProposalProvider.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodProposalProvider.java (rev 0)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodProposalProvider.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -0,0 +1,53 @@
+/*******************************************************************************
+ * Copyright (c) 2008 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.smooks.configuration.editors.uitls;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.jface.fieldassist.IContentProposal;
+import org.eclipse.jface.fieldassist.IContentProposalProvider;
+
+/**
+ * @author Dart (dpeng(a)redhat.com)
+ *
+ */
+public class SetterMethodProposalProvider implements IContentProposalProvider {
+
+
+ private Method[] settMethods = null;
+
+ public SetterMethodProposalProvider(Class<?> clazz){
+ settMethods = JavaPropertyUtils.getSetterMethods(clazz);
+ }
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposalProvider#getProposals(java.lang.String, int)
+ */
+ public IContentProposal[] getProposals(String contents, int position) {
+ if(settMethods == null || settMethods.length == 0){
+ return new IContentProposal[]{};
+ }
+
+ List<IContentProposal> list = new ArrayList<IContentProposal>();
+ for (int i = 0; i < settMethods.length; i++) {
+ Method m = settMethods[i];
+ String n = m.getName();
+ if(n != null){
+ if(n.toLowerCase().startsWith(contents)){
+ list.add(new SetterMethodContentProposal(m));
+ }
+ }
+ }
+ return list.toArray(new IContentProposal[]{});
+ }
+
+}
Property changes on: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SetterMethodProposalProvider.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SmooksUIUtils.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SmooksUIUtils.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/SmooksUIUtils.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -52,6 +52,7 @@
import org.eclipse.jface.fieldassist.ControlDecoration;
import org.eclipse.jface.fieldassist.FieldDecoration;
import org.eclipse.jface.fieldassist.FieldDecorationRegistry;
+import org.eclipse.jface.fieldassist.IContentProposal;
import org.eclipse.jface.fieldassist.IContentProposalListener;
import org.eclipse.jface.fieldassist.IContentProposalListener2;
import org.eclipse.jface.fieldassist.IContentProposalProvider;
@@ -105,16 +106,20 @@
import org.jboss.tools.smooks.configuration.editors.CurrentProjecViewerFilter;
import org.jboss.tools.smooks.configuration.editors.FieldMarkerComposite;
import org.jboss.tools.smooks.configuration.editors.FileSelectionWizard;
+import org.jboss.tools.smooks.configuration.editors.GraphicsConstants;
import org.jboss.tools.smooks.configuration.editors.IXMLStructuredObject;
import org.jboss.tools.smooks.configuration.editors.OpenFileHyperLinkListener;
import org.jboss.tools.smooks.configuration.editors.SelectorAttributes;
import org.jboss.tools.smooks.configuration.editors.SelectoreSelectionDialog;
+import org.jboss.tools.smooks.configuration.editors.javabean.JavaBeanModel;
import org.jboss.tools.smooks.configuration.editors.javabean.JavaMethodsSelectionDialog;
import org.jboss.tools.smooks.configuration.editors.javabean.JavaPropertiesSelectionDialog;
+import org.jboss.tools.smooks.core.SmooksCoreActivator;
import org.jboss.tools.smooks.model.graphics.ext.DocumentRoot;
import org.jboss.tools.smooks.model.graphics.ext.SmooksGraphicsExtType;
import org.jboss.tools.smooks.model.graphics.ext.util.SmooksGraphicsExtResourceFactoryImpl;
import org.jboss.tools.smooks.model.javabean.BindingsType;
+import org.jboss.tools.smooks.model.javabean.provider.Javabean1EditPlugin;
import org.jboss.tools.smooks.model.smooks.AbstractResourceConfig;
import org.jboss.tools.smooks.model.smooks.ConditionType;
import org.jboss.tools.smooks.model.smooks.SmooksResourceListType;
@@ -150,7 +155,10 @@
public static final String[] SELECTOR_SPERATORS = new String[] { " ", "/" };
- public static List<String> getBeanIdList(SmooksResourceListType resourceList) {
+ public static List<String> getBeanIdStringList(SmooksResourceListType resourceList) {
+ if (resourceList == null) {
+ return null;
+ }
List<AbstractResourceConfig> rlist = resourceList.getAbstractResourceConfig();
List<String> beanIdList = new ArrayList<String>();
for (Iterator<?> iterator = rlist.iterator(); iterator.hasNext();) {
@@ -165,6 +173,21 @@
return beanIdList;
}
+ public static List<BindingsType> getBeanIdList(SmooksResourceListType resourceList) {
+ if (resourceList == null) {
+ return null;
+ }
+ List<AbstractResourceConfig> rlist = resourceList.getAbstractResourceConfig();
+ List<BindingsType> beanIdList = new ArrayList<BindingsType>();
+ for (Iterator<?> iterator = rlist.iterator(); iterator.hasNext();) {
+ AbstractResourceConfig abstractResourceConfig = (AbstractResourceConfig) iterator.next();
+ if (abstractResourceConfig instanceof BindingsType) {
+ beanIdList.add((BindingsType) abstractResourceConfig);
+ }
+ }
+ return beanIdList;
+ }
+
public static void createMixedTextFieldEditor(String label, AdapterFactoryEditingDomain editingdomain,
FormToolkit toolkit, Composite parent, Object model, boolean linkLabel, IHyperlinkListener listener) {
createMixedTextFieldEditor(label, editingdomain, toolkit, parent, model, false, 0, linkLabel, false, listener,
@@ -564,9 +587,9 @@
}
if (editValue != null && valueIsSet) {
valueText.setText(editValue);
-// if (editValue.length() > 0 && section != null) {
-// section.setExpanded(true);
-// }
+ // if (editValue.length() > 0 && section != null) {
+ // section.setExpanded(true);
+ // }
}
if (valueType == VALUE_TYPE_TEXT && model instanceof AnyType && fEditingDomain != null) {
valueText.addModifyListener(new ModifyListener() {
@@ -579,7 +602,11 @@
SmooksModelUtils.setTextToSmooksType(fEditingDomain, (AnyType) fm, null);
} else {
if (!valueText.getText().equals(text)) {
- SmooksModelUtils.setTextToSmooksType(fEditingDomain, (AnyType) fm, valueText.getText());
+ String vt = valueText.getText();
+ if (vt != null) {
+ vt = vt.replaceAll("\r", "");
+ }
+ SmooksModelUtils.setTextToSmooksType(fEditingDomain, (AnyType) fm, vt);
}
}
}
@@ -596,7 +623,11 @@
SmooksModelUtils.setCommentToSmooksType(fEditingDomain, (AnyType) fm, null);
} else {
if (!valueText.getText().equals(text)) {
- SmooksModelUtils.setCommentToSmooksType(fEditingDomain, (AnyType) fm, valueText.getText());
+ String vt = valueText.getText();
+ if (vt != null) {
+ vt = vt.replaceAll("\r", "");
+ }
+ SmooksModelUtils.setCommentToSmooksType(fEditingDomain, (AnyType) fm, vt);
}
}
}
@@ -613,7 +644,11 @@
SmooksModelUtils.setCDATAToSmooksType(fEditingDomain, (AnyType) fm, null);
} else {
if (!valueText.getText().equals(text)) {
- SmooksModelUtils.setCDATAToSmooksType(fEditingDomain, (AnyType) fm, valueText.getText());
+ String vt = valueText.getText();
+ if (vt != null) {
+ vt = vt.replaceAll("\r", "");
+ }
+ SmooksModelUtils.setCDATAToSmooksType(fEditingDomain, (AnyType) fm, vt);
}
}
}
@@ -720,12 +755,12 @@
return createStringFieldEditor(label, parent, editingdomain, toolkit, null, model, true, true, false, 300,
null, VALUE_TYPE_CDATA, action);
}
-
+
public static AttributeFieldEditPart createCDATAFieldEditor(String label,
AdapterFactoryEditingDomain editingdomain, FormToolkit toolkit, Composite parent, Object model,
- OpenEditorEditInnerContentsAction action,boolean expanedEditor) {
+ OpenEditorEditInnerContentsAction action, boolean expanedEditor) {
return createStringFieldEditor(label, parent, editingdomain, toolkit, null, model, true, true, false, 300,
- null, VALUE_TYPE_CDATA, action,expanedEditor);
+ null, VALUE_TYPE_CDATA, action, expanedEditor);
}
public static AttributeFieldEditPart createCommentFieldEditor(String label,
@@ -734,12 +769,12 @@
return createStringFieldEditor(label, parent, editingdomain, toolkit, null, model, true, true, false, 300,
null, VALUE_TYPE_COMMENT, action);
}
-
+
public static AttributeFieldEditPart createCommentFieldEditor(String label,
AdapterFactoryEditingDomain editingdomain, FormToolkit toolkit, Composite parent, Object model,
- OpenEditorEditInnerContentsAction action,boolean expandEditor) {
+ OpenEditorEditInnerContentsAction action, boolean expandEditor) {
return createStringFieldEditor(label, parent, editingdomain, toolkit, null, model, true, true, false, 300,
- null, VALUE_TYPE_COMMENT, action,expandEditor);
+ null, VALUE_TYPE_COMMENT, action, expandEditor);
}
public static AttributeFieldEditPart createJavaTypeSearchFieldEditor(Composite parent, FormToolkit toolkit,
@@ -784,8 +819,7 @@
notificationComposite.setLayoutData(gd);
editpart.setFieldMarker(notificationComposite);
- final SearchComposite searchComposite = new SearchComposite(tcom, toolkit, "Search Class", dialog,
- SWT.NONE);
+ final SearchComposite searchComposite = new SearchComposite(tcom, toolkit, "Browse", dialog, SWT.NONE);
gd = new GridData(GridData.FILL_HORIZONTAL);
searchComposite.setLayoutData(gd);
Object editValue = getEditValue(propertyDescriptor, model);
@@ -874,7 +908,11 @@
}
public static IResource getResource(EObject model) {
+ if (model == null)
+ return null;
final Resource resource = ((EObject) model).eResource();
+ if (resource == null)
+ return null;
URI uri = resource.getURI();
IResource workspaceResource = null;
if (uri.isPlatformResource()) {
@@ -898,16 +936,40 @@
final EObject model) {
String classString = ((BindingsType) container).getClass_();
IJavaProject project = getJavaProject(container);
+ Class<?> clazz = null;
try {
ProjectClassLoader classLoader = new ProjectClassLoader(project);
- Class<?> clazz = classLoader.loadClass(classString);
- JavaMethodsSelectionDialog dialog = new JavaMethodsSelectionDialog(project, clazz);
- return SmooksUIUtils.createDialogFieldEditor(parent, toolkit, propertyDescriptor, "Select method", dialog,
- (EObject) model);
+ clazz = classLoader.loadClass(classString);
} catch (Exception e) {
// ignore
}
- return null;
+ JavaMethodsSelectionDialog dialog = new JavaMethodsSelectionDialog(project, clazz);
+ AttributeFieldEditPart editPart = SmooksUIUtils.createDialogFieldEditor(parent, toolkit, propertyDescriptor,
+ buttonName, dialog, (EObject) model);
+
+ Control c = editPart.getContentControl();
+ if (c instanceof SearchComposite) {
+ Text text = ((SearchComposite) c).getText();
+ IResource resource = getResource(model);
+ if (resource != null) {
+ final FieldAssistDisposer disposer = addJavaSetterMethodFieldAssistToText(text, clazz);
+ text.addDisposeListener(new DisposeListener() {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.swt.events.DisposeListener#widgetDisposed
+ * (org.eclipse.swt.events.DisposeEvent)
+ */
+ public void widgetDisposed(DisposeEvent e) {
+ disposer.dispose();
+ }
+
+ });
+ }
+ }
+ return editPart;
}
public static String generateFullPath(IXMLStructuredObject node, final String sperator) {
@@ -1095,16 +1157,33 @@
final EObject model) {
String classString = ((BindingsType) container).getClass_();
IJavaProject project = getJavaProject(container);
- try {
- ProjectClassLoader classLoader = new ProjectClassLoader(project);
- Class<?> clazz = classLoader.loadClass(classString);
- JavaPropertiesSelectionDialog dialog = new JavaPropertiesSelectionDialog(project, clazz);
- return SmooksUIUtils.createDialogFieldEditor(parent, toolkit, propertyDescriptor, "Select property",
- dialog, (EObject) model);
- } catch (Exception e) {
- // ignore
+ JavaPropertiesSelectionDialog dialog = new JavaPropertiesSelectionDialog(project, classString);
+ AttributeFieldEditPart editPart = SmooksUIUtils.createDialogFieldEditor(parent, toolkit, propertyDescriptor,
+ buttonName, dialog, (EObject) model);
+ Control c = editPart.getContentControl();
+ if (c instanceof SearchComposite) {
+ Text text = ((SearchComposite) c).getText();
+ IResource resource = getResource(model);
+ if (resource != null) {
+ final FieldAssistDisposer disposer = addJavaPropertiesFieldAssistToText(text, resource.getProject(),
+ classString);
+ text.addDisposeListener(new DisposeListener() {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.swt.events.DisposeListener#widgetDisposed
+ * (org.eclipse.swt.events.DisposeEvent)
+ */
+ public void widgetDisposed(DisposeEvent e) {
+ disposer.dispose();
+ }
+
+ });
+ }
}
- return null;
+ return editPart;
}
public static Object getEditValue(IItemPropertyDescriptor propertyDescriptor, Object model) {
@@ -1382,6 +1461,169 @@
}
+ public static FieldAssistDisposer addJavaPropertiesFieldAssistToText(Text text, IProject project, String className) {
+ // Decorate the text widget with the light-bulb image denoting content
+ // assist
+ int bits = SWT.DOWN | SWT.LEFT;
+ ControlDecoration controlDecoration = new ControlDecoration(text, bits);
+ // Configure text widget decoration
+ // No margin
+ controlDecoration.setMarginWidth(0);
+ // Custom hover tip text
+ if (isLinuxOS()) {
+ controlDecoration.setDescriptionText("Content Assist Available (Ctrl + space)");
+ } else {
+ controlDecoration.setDescriptionText("Content Assist Available (Alt + /)");
+ }
+ // Custom hover properties
+ controlDecoration.setShowHover(true);
+ controlDecoration.setShowOnlyOnFocus(true);
+ // Hover image to use
+ FieldDecoration contentProposalImage = FieldDecorationRegistry.getDefault().getFieldDecoration(
+ FieldDecorationRegistry.DEC_CONTENT_PROPOSAL);
+ controlDecoration.setImage(contentProposalImage.getImage());
+
+ // Default text widget adapter for field assist
+ TextContentAdapter textContentAdapter = new TextContentAdapter();
+ // Content assist command
+ String command = "org.eclipse.ui.edit.text.contentAssist.proposals"; //$NON-NLS-1$
+
+ // Create the proposal provider
+ JavaPropertiesProposalProvider proposalProvider = new JavaPropertiesProposalProvider(project, className);
+ // Create the adapter
+ ContentAssistCommandAdapter adapter = new ContentAssistCommandAdapter(text, textContentAdapter,
+ proposalProvider, command, allEnglishCharas);
+ // Configure the adapter
+ // Add label provider
+ ILabelProvider labelProvider = new LabelProvider() {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.viewers.LabelProvider#getText(java.lang.Object)
+ */
+ @Override
+ public String getText(Object element) {
+ if (element instanceof XMLStructuredModelProposal) {
+ return ((XMLStructuredModelProposal) element).getLabel();
+ }
+ return super.getText(element);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.viewers.LabelProvider#getImage(java.lang.Object
+ * )
+ */
+ @Override
+ public Image getImage(Object element) {
+ if (element instanceof XMLStructuredModelProposal) {
+ if (((XMLStructuredModelProposal) element).getXmlStructuredObject() instanceof JavaBeanModel) {
+ return SmooksConfigurationActivator.getDefault().getImageRegistry().get(
+ GraphicsConstants.IMAGE_JAVA_ATTRIBUTE);
+ }
+ }
+ return super.getImage(element);
+ }
+
+ };
+ adapter.setLabelProvider(labelProvider);
+ // Replace text field contents with accepted proposals
+ adapter.setProposalAcceptanceStyle(ContentProposalAdapter.PROPOSAL_REPLACE);
+ // Disable default filtering - custom filtering done
+ adapter.setFilterStyle(ContentProposalAdapter.FILTER_NONE);
+ // Add listeners required to reset state for custom filtering
+ SelectorConentProposalListener proposalListener = new SelectorConentProposalListener();
+ adapter.addContentProposalListener((IContentProposalListener) proposalListener);
+ adapter.addContentProposalListener((IContentProposalListener2) proposalListener);
+
+ return new FieldAssistDisposer(adapter, (IContentProposalListener) proposalListener,
+ (IContentProposalListener2) proposalListener);
+
+ }
+
+ public static FieldAssistDisposer addJavaSetterMethodFieldAssistToText(Text text, Class<?> clazz) {
+ // Decorate the text widget with the light-bulb image denoting content
+ // assist
+ int bits = SWT.DOWN | SWT.LEFT;
+ ControlDecoration controlDecoration = new ControlDecoration(text, bits);
+ // Configure text widget decoration
+ // No margin
+ controlDecoration.setMarginWidth(0);
+ // Custom hover tip text
+ if (isLinuxOS()) {
+ controlDecoration.setDescriptionText("Content Assist Available (Ctrl + space)");
+ } else {
+ controlDecoration.setDescriptionText("Content Assist Available (Alt + /)");
+ }
+ // Custom hover properties
+ controlDecoration.setShowHover(true);
+ controlDecoration.setShowOnlyOnFocus(true);
+ // Hover image to use
+ FieldDecoration contentProposalImage = FieldDecorationRegistry.getDefault().getFieldDecoration(
+ FieldDecorationRegistry.DEC_CONTENT_PROPOSAL);
+ controlDecoration.setImage(contentProposalImage.getImage());
+
+ // Default text widget adapter for field assist
+ TextContentAdapter textContentAdapter = new TextContentAdapter();
+ // Content assist command
+ String command = "org.eclipse.ui.edit.text.contentAssist.proposals"; //$NON-NLS-1$
+
+ // Create the proposal provider
+ SetterMethodProposalProvider proposalProvider = new SetterMethodProposalProvider(clazz);
+ // Create the adapter
+ ContentAssistCommandAdapter adapter = new ContentAssistCommandAdapter(text, textContentAdapter,
+ proposalProvider, command, allEnglishCharas);
+ // Configure the adapter
+ // Add label provider
+ ILabelProvider labelProvider = new LabelProvider() {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.viewers.LabelProvider#getText(java.lang.Object)
+ */
+ @Override
+ public String getText(Object element) {
+ if (element instanceof SetterMethodContentProposal) {
+ return ((SetterMethodContentProposal) element).getLabel();
+ }
+ return super.getText(element);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.viewers.LabelProvider#getImage(java.lang.Object
+ * )
+ */
+ @Override
+ public Image getImage(Object element) {
+ return SmooksConfigurationActivator.getDefault().getImageRegistry().get(
+ GraphicsConstants.IMAGE_JAVA_ATTRIBUTE);
+ }
+
+ };
+ adapter.setLabelProvider(labelProvider);
+ // Replace text field contents with accepted proposals
+ adapter.setProposalAcceptanceStyle(ContentProposalAdapter.PROPOSAL_REPLACE);
+ // Disable default filtering - custom filtering done
+ adapter.setFilterStyle(ContentProposalAdapter.FILTER_NONE);
+ // Add listeners required to reset state for custom filtering
+ SelectorConentProposalListener proposalListener = new SelectorConentProposalListener();
+ adapter.addContentProposalListener((IContentProposalListener) proposalListener);
+ adapter.addContentProposalListener((IContentProposalListener2) proposalListener);
+
+ return new FieldAssistDisposer(adapter, (IContentProposalListener) proposalListener,
+ (IContentProposalListener2) proposalListener);
+
+ }
+
public static FieldAssistDisposer addBeanIdRefAssistToCombo(Combo combo, EObject model) {
// Decorate the text widget with the light-bulb image denoting content
// assist
@@ -1432,6 +1674,100 @@
(IContentProposalListener2) proposalListener);
}
+ public static FieldAssistDisposer addBindingsContextAssistToText(Text text, SmooksResourceListType model) {
+ // Decorate the text widget with the light-bulb image denoting content
+ // assist
+ int bits = SWT.CENTER | SWT.LEFT;
+ ControlDecoration controlDecoration = new ControlDecoration(text, bits);
+ // Configure text widget decoration
+ // No margin
+ controlDecoration.setMarginWidth(0);
+ // Custom hover tip text
+ if (isLinuxOS()) {
+ controlDecoration.setDescriptionText("Content Assist Available (Ctrl + space)");
+ } else {
+ controlDecoration.setDescriptionText("Content Assist Available (Alt + /)");
+ }
+ // Custom hover properties
+ controlDecoration.setShowHover(true);
+ controlDecoration.setShowOnlyOnFocus(true);
+ // Hover image to use
+ FieldDecoration contentProposalImage = FieldDecorationRegistry.getDefault().getFieldDecoration(
+ FieldDecorationRegistry.DEC_CONTENT_PROPOSAL);
+ controlDecoration.setImage(contentProposalImage.getImage());
+
+ // Default text widget adapter for field assist
+ MultiTextContentAdapter textContentAdapter = new MultiTextContentAdapter();
+ // Content assist command
+ String command = "org.eclipse.ui.edit.text.contentAssist.proposals"; //$NON-NLS-1$
+ // Set auto activation character to be a '.'
+
+ // Create the proposal provider
+ BindingsContextProposalProvider proposalProvider = new BindingsContextProposalProvider(model, text);
+ // Create the adapter
+ char[] chars = new char[allEnglishCharas.length + 1];
+ System.arraycopy(allEnglishCharas, 0, chars, 0, allEnglishCharas.length);
+ chars[chars.length - 1] = '.';
+ ContentAssistCommandAdapter adapter = new ContentAssistCommandAdapter(text, textContentAdapter,
+ proposalProvider, command, chars);
+ // Configure the adapter
+ // Add label provider
+ ILabelProvider labelProvider = new LabelProvider() {
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.viewers.LabelProvider#getImage(java.lang.Object
+ * )
+ */
+ @Override
+ public Image getImage(Object element) {
+ if (element instanceof BindingsContextContentProposal) {
+ int type = ((BindingsContextContentProposal) element).getType();
+ switch (type) {
+ case BindingsContextContentProposal.BINDINGS:
+ return SmooksCoreActivator.getDefault().getImageRegistry().get("BindingsType");
+ case BindingsContextContentProposal.EXPRESSIONS:
+ return SmooksCoreActivator.getDefault().getImageRegistry().get("ExpressionType");
+ case BindingsContextContentProposal.PROPERTIES:
+ return SmooksCoreActivator.getDefault().getImageRegistry().get("ValueType");
+ case BindingsContextContentProposal.WIRTINGS:
+ return SmooksCoreActivator.getDefault().getImageRegistry().get("WiringType");
+ }
+ }
+ return super.getImage(element);
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.eclipse.jface.viewers.LabelProvider#getText(java.lang.Object)
+ */
+ @Override
+ public String getText(Object element) {
+ if (element instanceof IContentProposal) {
+ return ((IContentProposal) element).getLabel();
+ }
+ return super.getText(element);
+ }
+
+ };
+ adapter.setLabelProvider(labelProvider);
+ // Replace text field contents with accepted proposals
+ adapter.setProposalAcceptanceStyle(ContentProposalAdapter.PROPOSAL_INSERT);
+ // Disable default filtering - custom filtering done
+ adapter.setFilterStyle(ContentProposalAdapter.FILTER_NONE);
+ // Add listeners required to reset state for custom filtering
+ SelectorConentProposalListener proposalListener = new SelectorConentProposalListener();
+ adapter.addContentProposalListener((IContentProposalListener) proposalListener);
+ adapter.addContentProposalListener((IContentProposalListener2) proposalListener);
+
+ return new FieldAssistDisposer(adapter, (IContentProposalListener) proposalListener,
+ (IContentProposalListener2) proposalListener);
+ }
+
public static TypeFieldAssistDisposer addTypeFieldAssistToText(Text text, IProject project, int searchScope) {
// Decorate the text widget with the light-bulb image denoting content
// assist
Added: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/XMLStructuredModelProposal.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/XMLStructuredModelProposal.java (rev 0)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/XMLStructuredModelProposal.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -0,0 +1,83 @@
+/*******************************************************************************
+ * Copyright (c) 2008 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.smooks.configuration.editors.uitls;
+
+import org.eclipse.jface.fieldassist.IContentProposal;
+import org.jboss.tools.smooks.configuration.editors.IXMLStructuredObject;
+import org.jboss.tools.smooks.configuration.editors.javabean.JavaBeanModel;
+
+/**
+ * @author Dart (dpeng(a)redhat.com)
+ *
+ */
+public class XMLStructuredModelProposal implements IContentProposal {
+
+ private IXMLStructuredObject xmlStructuredObject;
+
+ private String content = null;
+
+ public XMLStructuredModelProposal(IXMLStructuredObject xmlStructuredObject){
+ this.xmlStructuredObject = xmlStructuredObject;
+ content = this.xmlStructuredObject.getNodeName();
+ if(xmlStructuredObject instanceof JavaBeanModel){
+ content = ((JavaBeanModel)this.xmlStructuredObject).getName();
+ }
+ }
+
+
+ /**
+ * @return the xmlStructuredObject
+ */
+ public IXMLStructuredObject getXmlStructuredObject() {
+ return xmlStructuredObject;
+ }
+
+
+ /**
+ * @param xmlStructuredObject the xmlStructuredObject to set
+ */
+ public void setXmlStructuredObject(IXMLStructuredObject xmlStructuredObject) {
+ this.xmlStructuredObject = xmlStructuredObject;
+ }
+
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getContent()
+ */
+ public String getContent() {
+ return content;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getCursorPosition()
+ */
+ public int getCursorPosition() {
+ if(content != null){
+ return content.length();
+ }
+ return 0;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getDescription()
+ */
+ public String getDescription() {
+ return null;
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.fieldassist.IContentProposal#getLabel()
+ */
+ public String getLabel() {
+ return content;
+ }
+
+}
Property changes on: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/editors/uitls/XMLStructuredModelProposal.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/AbstractValidator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/AbstractValidator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/AbstractValidator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -23,52 +23,57 @@
/**
* @author Dart (dpeng(a)redhat.com)
- *
+ *
*/
public abstract class AbstractValidator implements ISmooksValidator {
-
-
- /* (non-Javadoc)
- * @see org.jboss.tools.smooks.configuration.validate.ISmooksValidator#validate(java.util.Collection, org.eclipse.emf.edit.domain.EditingDomain)
+ /*
+ * (non-Javadoc)
+ *
+ * @see
+ * org.jboss.tools.smooks.configuration.validate.ISmooksValidator#validate
+ * (java.util.Collection, org.eclipse.emf.edit.domain.EditingDomain)
*/
public List<Diagnostic> validate(Collection<?> selectedObjects, EditingDomain editingDomain) {
preStartValidation();
List<Diagnostic> list = new ArrayList<Diagnostic>();
- for (Iterator<?> iterator = selectedObjects.iterator(); iterator.hasNext();) {
- Object object = (Object) iterator.next();
- Diagnostic d = validateModel(object, editingDomain);
- if(d != null){
- list.add(d);
- }
- if (object instanceof EObject) {
- List<Diagnostic> dd = validate(((EObject) object).eContents(),editingDomain);
- if (dd != null) {
- list.addAll(dd);
+ try {
+ for (Iterator<?> iterator = selectedObjects.iterator(); iterator.hasNext();) {
+ Object object = (Object) iterator.next();
+ Diagnostic d = validateModel(object, editingDomain);
+ if (d != null) {
+ list.add(d);
}
+ if (object instanceof EObject) {
+ List<Diagnostic> dd = validate(((EObject) object).eContents(), editingDomain);
+ if (dd != null) {
+ list.addAll(dd);
+ }
+ }
}
+ } catch (Throwable t) {
+
}
return list;
}
-
- protected void preStartValidation(){
-
- }
- protected Diagnostic newDiagnostic(int severity , String message , Object model, EAttribute property){
- return new BasicDiagnostic(severity, "org.jboss.tools", 0, message, new Object[] {
- model, property });
+ protected void preStartValidation() {
+
}
-
- protected Diagnostic newWaringDiagnostic(String message , Object model, EAttribute property){
+
+ protected Diagnostic newDiagnostic(int severity, String message, Object model, EAttribute property) {
+ return new BasicDiagnostic(severity, "org.jboss.tools", 0, message, new Object[] { model, property });
+ }
+
+ protected Diagnostic newWaringDiagnostic(String message, Object model, EAttribute property) {
return newDiagnostic(Diagnostic.WARNING, message, model, property);
}
-
- protected Diagnostic newErrorDiagnostic(String message , Object model, EAttribute property){
+
+ protected Diagnostic newErrorDiagnostic(String message, Object model, EAttribute property) {
return newDiagnostic(Diagnostic.ERROR, message, model, property);
}
-
- protected Diagnostic validateModel(Object model , EditingDomain editingDomain){
+
+ protected Diagnostic validateModel(Object model, EditingDomain editingDomain) {
return null;
}
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/BeanIdRefValidator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/BeanIdRefValidator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/BeanIdRefValidator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -58,7 +58,7 @@
Object obj = resource.getContents().get(0);
if (obj instanceof DocumentRoot) {
SmooksResourceListType listType = ((DocumentRoot) obj).getSmooksResourceList();
- List<String> ids = SmooksUIUtils.getBeanIdList(listType);
+ List<String> ids = SmooksUIUtils.getBeanIdStringList(listType);
idList.addAll(ids);
}
if (idList.isEmpty()) {
Modified: trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/SmooksModelValidator.java
===================================================================
--- trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/SmooksModelValidator.java 2009-05-27 06:25:34 UTC (rev 15545)
+++ trunk/smooks/plugins/org.jboss.tools.smooks.ui/src/org/jboss/tools/smooks/configuration/validate/SmooksModelValidator.java 2009-05-27 06:37:36 UTC (rev 15546)
@@ -282,7 +282,6 @@
@Override
public ValidationResult validate(IResource resource, int kind, ValidationState state, IProgressMonitor monitor) {
- System.out.println("validate file : " + resource.getFullPath().toString() + ", change type is " + kind);
AdapterFactoryEditingDomain editingDomain = newEditingDomain();
if (editingDomain == null)
return null;
@@ -324,6 +323,5 @@
}
public void validate(IValidationContext helper, IReporter reporter) throws ValidationException {
- System.out.println("validate helper");
}
}
14 years, 11 months
JBoss Tools SVN: r15545 - trunk/seam/plugins/org.jboss.tools.seam.xml/resources/help.
by jbosstools-commits@lists.jboss.org
Author: scabanovich
Date: 2009-05-27 02:25:34 -0400 (Wed, 27 May 2009)
New Revision: 15545
Modified:
trunk/seam/plugins/org.jboss.tools.seam.xml/resources/help/keys-seam.properties
Log:
https://jira.jboss.org/jira/browse/JBIDE-4377
Modified: trunk/seam/plugins/org.jboss.tools.seam.xml/resources/help/keys-seam.properties
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.xml/resources/help/keys-seam.properties 2009-05-27 06:24:07 UTC (rev 15544)
+++ trunk/seam/plugins/org.jboss.tools.seam.xml/resources/help/keys-seam.properties 2009-05-27 06:25:34 UTC (rev 15545)
@@ -1020,6 +1020,9 @@
FileSeamComponents21_AddImport.Title=Seam Import
SeamComponent_AddAnyProperty.WindowTitle=Add Property
+SeamComponent20_Properties.Title=Seam Component
+SeamComponent21_Properties.Title=Seam Component
+
SeamComponent_AddAnyProperty.Title=Property
SeamComponent20_AddProperty.WindowTitle=Add Simple Property
14 years, 11 months
JBoss Tools SVN: r15544 - in trunk/common/plugins: org.jboss.tools.common/.settings and 16 other directories.
by jbosstools-commits@lists.jboss.org
Author: sflanigan
Date: 2009-05-27 02:24:07 -0400 (Wed, 27 May 2009)
New Revision: 15544
Added:
trunk/common/plugins/org.jboss.tools.common.el.core/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Messages.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/messages.properties
trunk/common/plugins/org.jboss.tools.common/.settings/
trunk/common/plugins/org.jboss.tools.common/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/Messages.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/messages.properties
Modified:
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Activator.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ELReferenceList.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/GlobalELReferenceList.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/Tokenizer.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/TokenizerFactory.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELResolverFactoryManager.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ElVarSearcher.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/Var.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentExpressionImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELComplexExpressionImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInstanceImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInvocationExpressionImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMethodInvocationImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELModelImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMultiExpressionImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELOperatorImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELParametersImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELPropertyInvocationImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELValueExpressionImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/ELParserImpl.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/CallRule.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/ExpressionRule.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/OperationRule.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgEndTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgStartTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/CommaTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/DotTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/EndELTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprEndTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprStartTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/JavaNameTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/OperationTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamEndTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamStartTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamUtil.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/PrimitiveValueTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StartELTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StringTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/UnaryTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/WhiteSpaceTokenDescription.java
trunk/common/plugins/org.jboss.tools.common.el.ui/.settings/org.eclipse.jdt.core.prefs
trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/Activator.java
trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/GlobalElVariablesComposite.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/CommonPlugin.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/MethodNotImplementedException.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/BaseUIPlugin.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/StatusFactory.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/DefaultProblemReporter.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemBuffer.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemReportingHelper.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/Submit.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/text/TextProposal.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/FileUtil.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/ResourcesUtils.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/DtdResolver.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/ErrorHandlerImpl.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SAXValidator.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SafeDocumentBuilderFactory.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolver.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolverImpl.java
trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLUtilities.java
Log:
https://jira.jboss.org/jira/browse/JBIDE-3557 Externalize English strings
Added: trunk/common/plugins/org.jboss.tools.common/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common/.settings/org.eclipse.jdt.core.prefs 2009-05-27 06:24:07 UTC (rev 15544)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/CommonPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/CommonPlugin.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/CommonPlugin.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -24,7 +24,7 @@
public class CommonPlugin extends BasePlugin {
- public static final String PLUGIN_ID = "org.jboss.tools.common";
+ public static final String PLUGIN_ID = "org.jboss.tools.common"; //$NON-NLS-1$
protected static CommonPlugin instance;
private static String environment;
@@ -52,41 +52,41 @@
*/
public static String getEnvironment() {
if(environment == null) {
- String osName = System.getProperty("os.name");
- String javaVersion = System.getProperty("java.version");
- String studioName = "unknown";
- String studioVersion = "unknown";
- String eclipseVersion = "unknown";
- String eclipseBuildId = "unknown";
+ String osName = System.getProperty("os.name"); //$NON-NLS-1$
+ String javaVersion = System.getProperty("java.version"); //$NON-NLS-1$
+ String studioName = "unknown"; //$NON-NLS-1$
+ String studioVersion = "unknown"; //$NON-NLS-1$
+ String eclipseVersion = "unknown"; //$NON-NLS-1$
+ String eclipseBuildId = "unknown"; //$NON-NLS-1$
- Bundle studio = Platform.getBundle("org.jboss.tools.common");
+ Bundle studio = Platform.getBundle("org.jboss.tools.common"); //$NON-NLS-1$
if(studio!=null) {
Dictionary studioDic = studio.getHeaders();
- studioName = (String)studioDic.get("Bundle-Name");
- studioVersion = (String)studioDic.get("Bundle-Version");
+ studioName = (String)studioDic.get("Bundle-Name"); //$NON-NLS-1$
+ studioVersion = (String)studioDic.get("Bundle-Version"); //$NON-NLS-1$
}
- Bundle eclipse = Platform.getBundle("org.eclipse.platform");
+ Bundle eclipse = Platform.getBundle("org.eclipse.platform"); //$NON-NLS-1$
if(eclipse!=null) {
Dictionary eclipseDic = eclipse.getHeaders();
- eclipseVersion = (String)eclipseDic.get("Bundle-Version");
+ eclipseVersion = (String)eclipseDic.get("Bundle-Version"); //$NON-NLS-1$
FileInputStream fis = null;
try {
- String path = FileLocator.resolve(eclipse.getEntry("/")).getPath();
+ String path = FileLocator.resolve(eclipse.getEntry("/")).getPath(); //$NON-NLS-1$
if(path!=null) {
- File aboutMappings = new File(path, "about.mappings");
+ File aboutMappings = new File(path, "about.mappings"); //$NON-NLS-1$
if(aboutMappings.exists()) {
Properties properties = new Properties();
fis = new FileInputStream(aboutMappings);
properties.load(fis);
- String buildId = properties.getProperty("0");
+ String buildId = properties.getProperty("0"); //$NON-NLS-1$
if(buildId!=null && buildId.length()>0) {
eclipseBuildId = buildId;
}
}
}
} catch (IOException e) {
- getPluginLog().logError("Error in getting environment info: " + e.getMessage());
+ getPluginLog().logError("Error in getting environment info: " + e.getMessage()); //$NON-NLS-1$
} finally {
if(fis!=null) {
try {
@@ -97,10 +97,10 @@
}
}
}
- StringBuffer result = new StringBuffer(studioName).append(" ").append(studioVersion).
- append(", Eclipse ").append(eclipseVersion).append(" ").
- append(eclipseBuildId).append(", Java ").append(javaVersion).
- append(", ").append(osName);
+ StringBuffer result = new StringBuffer(studioName).append(" ").append(studioVersion). //$NON-NLS-1$
+ append(", Eclipse ").append(eclipseVersion).append(" "). //$NON-NLS-1$ //$NON-NLS-2$
+ append(eclipseBuildId).append(", Java ").append(javaVersion). //$NON-NLS-1$
+ append(", ").append(osName); //$NON-NLS-1$
environment = result.toString();
}
return environment;
Added: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/Messages.java (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/Messages.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -0,0 +1,20 @@
+package org.jboss.tools.common;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.messages"; //$NON-NLS-1$
+ public static String BaseUIPlugin_ErrorDialogTitle;
+ public static String SAXValidator_IOExceptionMessage;
+ public static String SAXValidator_SAXExceptionMessage;
+ public static String SAXValidator_UnableToInstantiateMessage;
+ public static String XMLUtilities_IOExceptionMessage;
+ public static String XMLUtilities_SAXExceptionMessage;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/MethodNotImplementedException.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/MethodNotImplementedException.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/MethodNotImplementedException.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -17,7 +17,7 @@
public class MethodNotImplementedException extends RuntimeException {
public MethodNotImplementedException() {
- super("Method is not implemented yet");
+ super("Method is not implemented yet"); //$NON-NLS-1$
}
public MethodNotImplementedException(String message, Throwable cause) {
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/BaseUIPlugin.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/BaseUIPlugin.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/BaseUIPlugin.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -15,6 +15,7 @@
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.jboss.tools.common.Messages;
/**
* Provides an easy way to log status of events.
@@ -65,6 +66,6 @@
logError(message, t);
Shell shell = Display.getDefault().getActiveShell();
IStatus s = StatusFactory.getInstance(IStatus.ERROR, this.getBundle().getSymbolicName(), message, t);
- ErrorDialog.openError(shell, "Hibernate Console", message, s);
+ ErrorDialog.openError(shell, Messages.BaseUIPlugin_ErrorDialogTitle, message, s);
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/StatusFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/StatusFactory.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/log/StatusFactory.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -16,8 +16,8 @@
public class StatusFactory {
public final static int UNDEFINED_ERROR = 0;
public final static String UNSPECIFIED_MESSAGE = null;
- public final static String EMPTY_MESSAGE = "";
- public final static String EMPTY_PLUGIN = "";
+ public final static String EMPTY_MESSAGE = ""; //$NON-NLS-1$
+ public final static String EMPTY_PLUGIN = ""; //$NON-NLS-1$
public static IStatus getInstance(int severity, String pluginId,
int code, String message, Throwable t) {
Added: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/messages.properties
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/messages.properties (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/messages.properties 2009-05-27 06:24:07 UTC (rev 15544)
@@ -0,0 +1,6 @@
+BaseUIPlugin_ErrorDialogTitle=Hibernate Console
+SAXValidator_IOExceptionMessage=Unidentified parser error
+SAXValidator_SAXExceptionMessage=Unidentified parser error
+SAXValidator_UnableToInstantiateMessage=error: Unable to instantiate parser ({0})
+XMLUtilities_IOExceptionMessage=Unexpected parser error
+XMLUtilities_SAXExceptionMessage=Unexpected parser error
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/DefaultProblemReporter.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/DefaultProblemReporter.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/DefaultProblemReporter.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -21,7 +21,7 @@
public void reportProblem(IStatus status) {
if(status != null) {
- Platform.getLog(Platform.getBundle("org.jboss.tools.common")).log(status);
+ Platform.getLog(Platform.getBundle("org.jboss.tools.common")).log(status); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemBuffer.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemBuffer.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemBuffer.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -35,7 +35,7 @@
*/
public void writeToBuffer(IStatus status) {
getEclipseLog();
- writer.logging(status, "org.jboss.tools.common");
+ writer.logging(status, "org.jboss.tools.common"); //$NON-NLS-1$
}
/**
@@ -50,7 +50,7 @@
int i = 0;
int c = 0;
while(i < s.length()) {
- i = s.indexOf("!ENTRY", i);
+ i = s.indexOf("!ENTRY", i); //$NON-NLS-1$
if(i >= 0) {
++c;
++i;
@@ -67,12 +67,12 @@
*/
public String getContent() {
File f = getLogFile();
- return (!f.isFile()) ? "" : FileUtil.readFile(f);
+ return (!f.isFile()) ? "" : FileUtil.readFile(f); //$NON-NLS-1$
}
public String getEclipseLogContent() {
File f = Platform.getLogFileLocation().toFile();
- return (f.isFile()) ? FileUtil.readFile(f) : "";
+ return (f.isFile()) ? FileUtil.readFile(f) : ""; //$NON-NLS-1$
}
public void clean() {
@@ -90,10 +90,10 @@
public void report(String text, String userEMail, String other, boolean cleanBuffer) {
StringBuffer sb = new StringBuffer();
if(userEMail != null && userEMail.trim().length() > 0) {
- sb.append("Customer e-mail=" + userEMail + "\n");
+ sb.append("Customer e-mail=" + userEMail + "\n"); //$NON-NLS-1$ //$NON-NLS-2$
}
if(other != null && other.length() > 0) {
- sb.append("Other=" + other + "\n");
+ sb.append("Other=" + other + "\n"); //$NON-NLS-1$ //$NON-NLS-2$
}
if(text != null) {
sb.append(text);
@@ -114,9 +114,9 @@
}
private File getLogFile() {
- Bundle b = Platform.getBundle("org.jboss.tools.common");
+ Bundle b = Platform.getBundle("org.jboss.tools.common"); //$NON-NLS-1$
String stateLocation = Platform.getStateLocation(b).toString().replace('\\', '/');
- String logLocation = stateLocation + "/.log";
+ String logLocation = stateLocation + "/.log"; //$NON-NLS-1$
return new File(logLocation);
}
}
\ No newline at end of file
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemReportingHelper.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemReportingHelper.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/ProblemReportingHelper.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -36,7 +36,7 @@
*/
public static void reportProblem(String plugin, String message, Throwable throwable) {
if(message==null) {
- throw new IllegalArgumentException("Message parameter cannot be null");
+ throw new IllegalArgumentException("Message parameter cannot be null"); //$NON-NLS-1$
}
IStatus status = new Status(IStatus.ERROR, plugin, 0, message, throwable);
reportProblem(status);
@@ -48,8 +48,8 @@
*/
public static void reportProblem(IStatus status) {
if(status == null) {
- reportProblem("org.jboss.tools.common",
- new IllegalArgumentException("Parameter 'status' cannt be null"));
+ reportProblem("org.jboss.tools.common", //$NON-NLS-1$
+ new IllegalArgumentException("Parameter 'status' cannot be null")); //$NON-NLS-1$
return;
}
IProblemReporter reporter = ProblemReporterFactory.getInstance().getProblemReporter();
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/Submit.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/Submit.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/reporting/Submit.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -27,11 +27,11 @@
*/
public class Submit {
- public static String REPORT_DESRIPTION_PARAMETER_NAME = CommonPlugin.getMessage("%reportParameterName");
+ public static String REPORT_DESRIPTION_PARAMETER_NAME = CommonPlugin.getMessage("%reportParameterName"); //$NON-NLS-1$
- private static String URL = CommonPlugin.getMessage("%reportingUrl");
- private static String JOB_NAME = CommonPlugin.getMessage("%reportingJobName");
- private static String ERROR_MESSAGE = CommonPlugin.getMessage("%errorReportingMessage");
+ private static String URL = CommonPlugin.getMessage("%reportingUrl"); //$NON-NLS-1$
+ private static String JOB_NAME = CommonPlugin.getMessage("%reportingJobName"); //$NON-NLS-1$
+ private static String ERROR_MESSAGE = CommonPlugin.getMessage("%errorReportingMessage"); //$NON-NLS-1$
private static Submit INSTANCE = new Submit();
@@ -61,7 +61,7 @@
String exceptionMessage = e.getMessage();
String message = ERROR_MESSAGE;
if(exceptionMessage!=null && exceptionMessage.trim().length()>0) {
- message = message + ".\r\n" + e.getClass().getName() + ": " + exceptionMessage;
+ message = message + ".\r\n" + e.getClass().getName() + ": " + exceptionMessage; //$NON-NLS-1$ //$NON-NLS-2$
}
Status status = new Status(IStatus.WARNING, CommonPlugin.PLUGIN_ID, IStatus.WARNING, message, e);
return status;
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/text/TextProposal.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/text/TextProposal.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/text/TextProposal.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -191,7 +191,7 @@
* @return
*/
public boolean isCloseTag() {
- return label != null && label.startsWith("/");
+ return label != null && label.startsWith("/"); //$NON-NLS-1$
}
/**
@@ -199,11 +199,11 @@
*/
public String toString() {
StringBuffer buffer = new StringBuffer();
- buffer.append("label: ");
+ buffer.append("label: "); //$NON-NLS-1$
buffer.append(label);
- buffer.append("\ncontextInfo: ");
+ buffer.append("\ncontextInfo: "); //$NON-NLS-1$
buffer.append(contextInfo);
- buffer.append("\nreplacementString: ");
+ buffer.append("\nreplacementString: "); //$NON-NLS-1$
buffer.append(replacementString);
return buffer.toString();
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/FileUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/FileUtil.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/FileUtil.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -56,13 +56,13 @@
} catch (CoreException e) {
CommonPlugin.getPluginLog().logError(e);
}
- return encoding != null ? encoding : "8859_1";
+ return encoding != null ? encoding : "8859_1"; //$NON-NLS-1$
}
public static String readFile(File f) {
- if(!f.isFile()) return "";
+ if(!f.isFile()) return ""; //$NON-NLS-1$
ReadBytes bs = readBytes(f);
- if(bs == null) return "";
+ if(bs == null) return ""; //$NON-NLS-1$
String encoding = getEncoding(bs.bs);
if(encoding == null) return new String(bs.bs, 0, bs.length);
try {
@@ -73,9 +73,9 @@
}
public static String readFileWithEncodingCheck(File f, String defaultEncoding) {
- if(!f.isFile()) return "";
+ if(!f.isFile()) return ""; //$NON-NLS-1$
ReadBytes bs = readBytes(f);
- if(bs == null) return "";
+ if(bs == null) return ""; //$NON-NLS-1$
String encoding = getEncoding(bs.bs);
if(encoding == null) encoding = validateEncoding(defaultEncoding, null);
if(encoding == null) return new String(bs.bs, 0, bs.length);
@@ -170,7 +170,7 @@
// FIXME Size of string buffer should be set to size of file by default
// to avoid StringBuffer extension on each append
public static String readStream(InputStream is) {
- StringBuffer sb = new StringBuffer("");
+ StringBuffer sb = new StringBuffer(""); //$NON-NLS-1$
try {
byte[] b = new byte[4096];
while(true) {
@@ -193,8 +193,8 @@
if(value == null) return false;
String encoding = getEncoding(value);
if(encoding == null) encoding = validateEncoding(defaultEncoding, null);
- if(value.startsWith("<?xml")) {
- String s = validateEncoding(encoding, "UTF-8");
+ if(value.startsWith("<?xml")) { //$NON-NLS-1$
+ String s = validateEncoding(encoding, "UTF-8"); //$NON-NLS-1$
if(encoding == null) {
encoding = s;
} else if(s == null || !s.equals(encoding)) {
@@ -211,9 +211,9 @@
if(f.isFile() && !isSameFile(f)) f.delete();
if(!f.exists()) f.createNewFile();
} catch (IOException e) {
- CommonPlugin.getPluginLog().logError("Problem writing to file " + f, e);
+ CommonPlugin.getPluginLog().logError("Problem writing to file " + f, e); //$NON-NLS-1$
} catch (SecurityException e) {
- CommonPlugin.getPluginLog().logError("Problem writing to file " + f, e);
+ CommonPlugin.getPluginLog().logError("Problem writing to file " + f, e); //$NON-NLS-1$
}
PrintWriter pw = new PrintWriter(new FileWriter(f));
pw.print(value);
@@ -445,10 +445,10 @@
public static void add(File f, String name, JarOutputStream jos) throws IOException {
String en = name;
- if(f.isDirectory()) en += "/";
- JarEntry entry = (en.endsWith("/")) ? null : new JarEntry(en);
+ if(f.isDirectory()) en += "/"; //$NON-NLS-1$
+ JarEntry entry = (en.endsWith("/")) ? null : new JarEntry(en); //$NON-NLS-1$
if(f.isDirectory()) {
- if("/".equals(en)) en = "";
+ if("/".equals(en)) en = ""; //$NON-NLS-1$ //$NON-NLS-2$
File[] fs = f.listFiles();
if(fs != null) for (int i = 0; i < fs.length; i++)
add(fs[i], en + fs[i].getName(), jos);
@@ -519,7 +519,7 @@
if(url == null) return null;
String resultUrl = url.replace('\\', '/');
/// if(!url.startsWith("file:/")) return url;
- if(!resultUrl.startsWith("file:")) return resultUrl;
+ if(!resultUrl.startsWith("file:")) return resultUrl; //$NON-NLS-1$
int iLast = resultUrl.lastIndexOf(':'), iFirst = resultUrl.indexOf(':');
return (iLast == iFirst) ? resultUrl.substring(5) : resultUrl.substring(iLast - 1);
}
@@ -533,19 +533,19 @@
int i = 0;
while(i < r.length && i < p.length && r[i].equalsIgnoreCase(p[i])) ++i;
StringBuffer sb = new StringBuffer();
- for (int k = i; k < r.length; k++) sb.append("/..");
- for (int k = i; k < p.length; k++) sb.append("/").append(p[k]);
+ for (int k = i; k < r.length; k++) sb.append("/.."); //$NON-NLS-1$
+ for (int k = i; k < p.length; k++) sb.append("/").append(p[k]); //$NON-NLS-1$
return sb.toString();
}
private static String[] tokenizePath(String path) {
String tokenizedPath = path.replace('\\', '/');
- StringTokenizer st = new StringTokenizer(tokenizedPath, "/");
+ StringTokenizer st = new StringTokenizer(tokenizedPath, "/"); //$NON-NLS-1$
ArrayList l = new ArrayList();
while(st.hasMoreTokens()) {
String t = st.nextToken();
- if(t.length() == 0 || t.equals(".")) continue;
- if(t.equals("..")) {
+ if(t.length() == 0 || t.equals(".")) continue; //$NON-NLS-1$
+ if(t.equals("..")) { //$NON-NLS-1$
if(l.size() > 0) l.remove(l.size() - 1);
continue;
}
@@ -557,20 +557,20 @@
public static String encode(String text, String encoding) {
if(true) return text;
try {
- byte[] bs = text.getBytes(System.getProperty("file.encoding"));
+ byte[] bs = text.getBytes(System.getProperty("file.encoding")); //$NON-NLS-1$
ByteArrayInputStream is = new ByteArrayInputStream(bs);
InputStreamReader r = new InputStreamReader(is, encoding);
char[] cs = new char[bs.length];
int l = r.read(cs, 0, cs.length);
return new String(cs, 0, l);
} catch (IOException e) {
- if("UTF-8".equals(encoding)) return text;
- return encode(text, "UTF-8");
+ if("UTF-8".equals(encoding)) return text; //$NON-NLS-1$
+ return encode(text, "UTF-8"); //$NON-NLS-1$
}
}
public static String encodeDefault(String text) {
- return encode(text, System.getProperties().getProperty("file.encoding"));
+ return encode(text, System.getProperties().getProperty("file.encoding")); //$NON-NLS-1$
}
/*
@@ -624,10 +624,10 @@
public static String getEncoding(String s) {
if(s == null) return null;
- if(s.startsWith("<?xml")) {
- int i = s.indexOf("encoding=");
+ if(s.startsWith("<?xml")) { //$NON-NLS-1$
+ int i = s.indexOf("encoding="); //$NON-NLS-1$
if(i < 0) return null;
- i += "encoding=".length() + 1;
+ i += "encoding=".length() + 1; //$NON-NLS-1$
int j = s.indexOf('\"', i);
if(j < 0) return null;
return s.substring(i, j);
@@ -643,7 +643,7 @@
if(validEncodings.contains(encoding)) return encoding;
if(invalidEncodings.contains(encoding)) return defaultEncoding;
try {
- if(defaultEncoding != null && defaultEncoding.equals("UTF-16")) {
+ if(defaultEncoding != null && defaultEncoding.equals("UTF-16")) { //$NON-NLS-1$
new String(XML_16, 0, XML_16.length, encoding);
} else {
new String(XML_8, 0, XML_8.length, encoding);
@@ -663,15 +663,15 @@
if(bs.length < 20) return null;
if(startsWith(bs, XML_8)) {
int i = getIndex(bs, (byte)'?', 5);
- if(i < 0) return "UTF-8";
+ if(i < 0) return "UTF-8"; //$NON-NLS-1$
String encoding = getEncoding(new String(bs, 0, i));
- return validateEncoding(encoding, "UTF-8");
+ return validateEncoding(encoding, "UTF-8"); //$NON-NLS-1$
} else if(startsWith(bs, XML_16)) {
int i = getIndex(bs, (byte)'?', XML_16.length);
- if(i < 0) return "UTF-16";
+ if(i < 0) return "UTF-16"; //$NON-NLS-1$
try {
- String encoding = getEncoding(new String(bs, 0, i, "UTF-16"));
- return validateEncoding(encoding, "UTF-16");
+ String encoding = getEncoding(new String(bs, 0, i, "UTF-16")); //$NON-NLS-1$
+ return validateEncoding(encoding, "UTF-16"); //$NON-NLS-1$
} catch (UnsupportedEncodingException e) {
return null;
}
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/ResourcesUtils.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/ResourcesUtils.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/util/ResourcesUtils.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -71,7 +71,7 @@
}
public static IProject importExistingProject(IProject project, String location, String name, IProgressMonitor monitor, boolean refreshWorkspace) throws CoreException {
- IPath path = new Path(location).append(".project");
+ IPath path = new Path(location).append(".project"); //$NON-NLS-1$
IProjectDescription description = ResourcesPlugin.getWorkspace().loadProjectDescription(path);
description.setName(name);
project.create(description, monitor);
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/DtdResolver.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/DtdResolver.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/DtdResolver.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -45,19 +45,19 @@
location = XMLCorePlugin.getDefault().getDefaultXMLCatalog().resolveURI(systemId);
}
if(location == null) {
- if(systemId != null && systemId.startsWith("file:") && systemId.endsWith(".xsd")) {
+ if(systemId != null && systemId.startsWith("file:") && systemId.endsWith(".xsd")) { //$NON-NLS-1$ //$NON-NLS-2$
int i = systemId.replace('\\', '/').lastIndexOf('/');
String systemId2 = systemId.substring(i + 1);
location = XMLCorePlugin.getDefault().getDefaultXMLCatalog().resolveURI(systemId2);
}
}
- if((location == null || location.startsWith("http:")) && systemId != null) {
- Bundle b = Platform.getBundle("org.eclipse.jst.standard.schemas");
+ if((location == null || location.startsWith("http:")) && systemId != null) { //$NON-NLS-1$
+ Bundle b = Platform.getBundle("org.eclipse.jst.standard.schemas"); //$NON-NLS-1$
if(b != null) {
- int q = systemId.lastIndexOf("/");
+ int q = systemId.lastIndexOf("/"); //$NON-NLS-1$
String s = systemId.substring(q + 1);
- URL u = b.getEntry("/dtdsAndSchemas/" + s);
+ URL u = b.getEntry("/dtdsAndSchemas/" + s); //$NON-NLS-1$
try {
if(u != null) {
u = FileLocator.resolve(u);
@@ -73,9 +73,9 @@
if(location == null) {
if(systemId != null && !unfound.contains(systemId)) {
unfound.add(systemId);
- CommonPlugin.getPluginLog().logError("Cannot find locally: "
- + "Public ID " + publicId
- + " System ID " + systemId);
+ CommonPlugin.getPluginLog().logError("Cannot find locally: " //$NON-NLS-1$
+ + "Public ID " + publicId //$NON-NLS-1$
+ + " System ID " + systemId); //$NON-NLS-1$
}
}
if(location!=null) {
@@ -84,27 +84,27 @@
File file = new File(url.getFile());
if(file.isFile()) {
return new FileInputStream(file);
- } else if("jar".equals(url.getProtocol())) {
+ } else if("jar".equals(url.getProtocol())) { //$NON-NLS-1$
return url.openStream();
}
} catch(FileNotFoundException e) {
- CommonPlugin.getPluginLog().logError("Error in DtdResolver: " + e.getMessage());
+ CommonPlugin.getPluginLog().logError("Error in DtdResolver: " + e.getMessage()); //$NON-NLS-1$
}
}
String resourceType = null;
if(systemId!=null) {
- if(systemId.toLowerCase().endsWith(".dtd")) {
- resourceType = "DTD";
- } else if(systemId.toLowerCase().endsWith(".xsd")) {
- resourceType = "XSD";
+ if(systemId.toLowerCase().endsWith(".dtd")) { //$NON-NLS-1$
+ resourceType = "DTD"; //$NON-NLS-1$
+ } else if(systemId.toLowerCase().endsWith(".xsd")) { //$NON-NLS-1$
+ resourceType = "XSD"; //$NON-NLS-1$
}
}
InputStream is = null;
if(resourceType!=null) { // this deactivates DTD and XSD
try {
URL url = new URL(systemId);
- if("http".equals(url.getProtocol())) {
+ if("http".equals(url.getProtocol())) { //$NON-NLS-1$
is = HttpUtil.getInputStreamFromUrlByGetMethod(systemId);
}
} catch (MalformedURLException e) {
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/ErrorHandlerImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/ErrorHandlerImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/ErrorHandlerImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -34,7 +34,7 @@
}
private void add(SAXParseException e) {
- errors.add("" + e.getMessage() + ":" + e.getLineNumber() + ":" + e.getColumnNumber());
+ errors.add("" + e.getMessage() + ":" + e.getLineNumber() + ":" + e.getColumnNumber()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SAXValidator.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SAXValidator.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SAXValidator.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -14,6 +14,7 @@
import java.io.IOException;
import java.io.Reader;
import java.net.URL;
+import java.text.MessageFormat;
import java.util.HashSet;
import java.util.Set;
@@ -21,6 +22,7 @@
import org.apache.xerces.xni.XMLResourceIdentifier;
import org.eclipse.core.runtime.Platform;
import org.jboss.tools.common.CommonPlugin;
+import org.jboss.tools.common.Messages;
import org.jboss.tools.common.util.FileUtil;
import org.osgi.framework.Bundle;
import org.xml.sax.SAXException;
@@ -36,16 +38,16 @@
*/
public class SAXValidator {
- protected static final String FATAL_ERROR_PROCESSING_FEATURE_ID = "http://apache.org/xml/features/continue-after-fatal-error";
- protected static final String ENTITY_RESOLVER_PROPERTY_ID = "http://apache.org/xml/properties/internal/entity-resolver";
- protected static final String NAMESPACES_FEATURE_ID = "http://xml.org/sax/features/namespaces";
- protected static final String NAMESPACE_PREFIXES_FEATURE_ID = "http://xml.org/sax/features/namespace-prefixes";
- protected static final String VALIDATION_FEATURE_ID = "http://xml.org/sax/features/validation";
- protected static final String VALIDATION_SCHEMA_FEATURE_ID = "http://apache.org/xml/features/validation/schema";
- protected static final String VALIDATION_SCHEMA_CHECKING_FEATURE_ID = "http://apache.org/xml/features/validation/schema-full-checking";
- protected static final String VALIDATION_DYNAMIC_FEATURE_ID = "http://apache.org/xml/features/validation/dynamic";
+ protected static final String FATAL_ERROR_PROCESSING_FEATURE_ID = "http://apache.org/xml/features/continue-after-fatal-error"; //$NON-NLS-1$
+ protected static final String ENTITY_RESOLVER_PROPERTY_ID = "http://apache.org/xml/properties/internal/entity-resolver"; //$NON-NLS-1$
+ protected static final String NAMESPACES_FEATURE_ID = "http://xml.org/sax/features/namespaces"; //$NON-NLS-1$
+ protected static final String NAMESPACE_PREFIXES_FEATURE_ID = "http://xml.org/sax/features/namespace-prefixes"; //$NON-NLS-1$
+ protected static final String VALIDATION_FEATURE_ID = "http://xml.org/sax/features/validation"; //$NON-NLS-1$
+ protected static final String VALIDATION_SCHEMA_FEATURE_ID = "http://apache.org/xml/features/validation/schema"; //$NON-NLS-1$
+ protected static final String VALIDATION_SCHEMA_CHECKING_FEATURE_ID = "http://apache.org/xml/features/validation/schema-full-checking"; //$NON-NLS-1$
+ protected static final String VALIDATION_DYNAMIC_FEATURE_ID = "http://apache.org/xml/features/validation/dynamic"; //$NON-NLS-1$
- protected static final String DEFAULT_SAX_PARSER_CLASS_NAME = "org.apache.xerces.parsers.SAXParser";
+ protected static final String DEFAULT_SAX_PARSER_CLASS_NAME = "org.apache.xerces.parsers.SAXParser"; //$NON-NLS-1$
/**
*
@@ -72,9 +74,9 @@
try {
parserInstance.setProperty(ENTITY_RESOLVER_PROPERTY_ID, new XMLEntityResolverImpl());
} catch (SAXNotRecognizedException e1) {
- CommonPlugin.getPluginLog().logError( e1.getMessage()+"", e1);
+ CommonPlugin.getPluginLog().logError( e1.getMessage()+"", e1); //$NON-NLS-1$
} catch (SAXNotSupportedException e1) {
- CommonPlugin.getPluginLog().logError( e1.getMessage()+"", e1);
+ CommonPlugin.getPluginLog().logError( e1.getMessage()+"", e1); //$NON-NLS-1$
}
parserInstance.setContentHandler(handler);
@@ -93,7 +95,7 @@
parser.setFeature(name, value);
} catch (SAXException e) {
// TODO - Move to NLS bundle
- CommonPlugin.getPluginLog().logError("warning: Parser does not support feature ("+name+")", e);
+ CommonPlugin.getPluginLog().logError("warning: Parser does not support feature ("+name+")", e); //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -107,7 +109,7 @@
try {
parser.setProperty(name, value);
} catch (SAXException e) {
- CommonPlugin.getPluginLog().logError("warning: Parser does not support feature ("+name+")", e);
+ CommonPlugin.getPluginLog().logError("warning: Parser does not support feature ("+name+")", e); //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -123,20 +125,18 @@
try {
XMLReader parser = createParser();
if(parser==null) {
- // TODO - Move to NLS bundle
- return new String[]{ "error: Unable to instantiate parser ("+DEFAULT_SAX_PARSER_CLASS_NAME+")"};
+ return new String[]{ MessageFormat.format(
+ Messages.SAXValidator_UnableToInstantiateMessage, DEFAULT_SAX_PARSER_CLASS_NAME)};
}
parser.setErrorHandler(h);
parser.parse(is);
} catch (SAXException e) {
if(h.errors.isEmpty()) {
- // TODO - Move to NLS bundle
- return new String[]{"Unidentified parser error:0:0",e.getMessage()};
+ return new String[]{Messages.SAXValidator_SAXExceptionMessage+":0:0",e.getMessage()}; //$NON-NLS-1$
}
} catch (IOException e) {
if(h.errors.isEmpty()) {
- // TODO - Move to NLS bundle
- return new String[]{"Unidentified parser error:0:0",e.getMessage()};
+ return new String[]{Messages.SAXValidator_IOExceptionMessage+":0:0",e.getMessage()}; //$NON-NLS-1$
}
} finally {
// Thread.currentThread().setContextClassLoader(cc);
@@ -162,34 +162,34 @@
Bundle b = Platform.getBundle(CommonPlugin.PLUGIN_ID);
String location = Platform.getStateLocation(b).toString().replace('\\', '/');
- if(!location.endsWith("/")) {
- location += "/";
+ if(!location.endsWith("/")) { //$NON-NLS-1$
+ location += "/"; //$NON-NLS-1$
}
String urlString = null;
URL url = null;
try {
- url = Platform.resolve(b.getEntry("/"));
+ url = Platform.resolve(b.getEntry("/")); //$NON-NLS-1$
urlString = url.toString();
- if(!urlString.endsWith("/")) {
- urlString += "/";
+ if(!urlString.endsWith("/")) { //$NON-NLS-1$
+ urlString += "/"; //$NON-NLS-1$
}
- urlString += "schemas";
+ urlString += "schemas"; //$NON-NLS-1$
} catch (IOException e) {
CommonPlugin.getPluginLog().logError(e);
}
- File f1 = new File(url.getFile() + "/schemas/catalog.xml");
- File f2 = new File(location + "schemas/catalog.xml");
+ File f1 = new File(url.getFile() + "/schemas/catalog.xml"); //$NON-NLS-1$
+ File f2 = new File(location + "schemas/catalog.xml"); //$NON-NLS-1$
if(f2.exists()) {
- return "file:///" + location + "schemas/catalog.xml";
+ return "file:///" + location + "schemas/catalog.xml"; //$NON-NLS-1$ //$NON-NLS-2$
}
FileUtil.copyDir(f1.getParentFile(), f2.getParentFile(), true);
String text = FileUtil.readFile(f2);
- while(text.indexOf("%install%") >= 0) {
- int i = text.indexOf("%install%");
+ while(text.indexOf("%install%") >= 0) { //$NON-NLS-1$
+ int i = text.indexOf("%install%"); //$NON-NLS-1$
text = text.substring(0, i) + urlString + text.substring(i + 9);
}
FileUtil.writeFile(f2, text);
- return "file:///" + location + "schemas/catalog.xml";
+ return "file:///" + location + "schemas/catalog.xml"; //$NON-NLS-1$ //$NON-NLS-2$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SafeDocumentBuilderFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SafeDocumentBuilderFactory.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/SafeDocumentBuilderFactory.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -24,8 +24,8 @@
public class SafeDocumentBuilderFactory extends Thread {
public static final EntityResolver EMPTY_RESOLVER = new EntityResolver() {
public InputSource resolveEntity(java.lang.String publicId, java.lang.String systemId) throws SAXException, java.io.IOException {
- if((systemId != null) && systemId.toLowerCase().endsWith(".dtd")) { // this deactivates DTD
- return new InputSource(new ByteArrayInputStream("<?xml version='1.0' encoding='UTF-8'?>".getBytes()));
+ if((systemId != null) && systemId.toLowerCase().endsWith(".dtd")) { // this deactivates DTD //$NON-NLS-1$
+ return new InputSource(new ByteArrayInputStream("<?xml version='1.0' encoding='UTF-8'?>".getBytes())); //$NON-NLS-1$
} else {
return null;
}
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolver.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolver.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolver.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -94,8 +94,8 @@
}
}
- if(deactivate && (systemId != null) && (source == null) && (systemId.toLowerCase().endsWith(".dtd"))) { // this deactivates DTD
- source = new InputSource(new ByteArrayInputStream("<?xml version='1.0' encoding='UTF-8'?>".getBytes()));
+ if(deactivate && (systemId != null) && (source == null) && (systemId.toLowerCase().endsWith(".dtd"))) { // this deactivates DTD //$NON-NLS-1$
+ source = new InputSource(new ByteArrayInputStream("<?xml version='1.0' encoding='UTF-8'?>".getBytes())); //$NON-NLS-1$
}
return source;
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolverImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolverImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLEntityResolverImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -49,7 +49,7 @@
result = new XMLInputSource(rid.getPublicId(), systemId, rid.getBaseSystemId(), is, null);
}
} catch (SAXException e) {
- CommonPlugin.getPluginLog().logError( "Exception publicId=" + publicId + " systemId=" + systemId + " exception=" + e.getClass().getName() + ":" + e.getMessage());
+ CommonPlugin.getPluginLog().logError( "Exception publicId=" + publicId + " systemId=" + systemId + " exception=" + e.getClass().getName() + ":" + e.getMessage()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
}
return result;
Modified: trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLUtilities.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLUtilities.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common/src/org/jboss/tools/common/xml/XMLUtilities.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -28,6 +28,7 @@
import org.apache.xml.serialize.OutputFormat;
import org.apache.xml.serialize.XMLSerializer;
import org.jboss.tools.common.CommonPlugin;
+import org.jboss.tools.common.Messages;
import org.w3c.dom.Comment;
import org.w3c.dom.DOMException;
import org.w3c.dom.DOMImplementation;
@@ -240,11 +241,11 @@
builder.parse(is);
} catch (IOException e) {
if(h.errors.isEmpty()) {
- return new String[]{"Unexpected parser error:0:0",e.toString()};
+ return new String[]{Messages.XMLUtilities_IOExceptionMessage+":0:0",e.toString()}; //$NON-NLS-1$
}
} catch (SAXException e) {
if(h.errors.isEmpty()) {
- return new String[]{"Unexpected parser error:0:0",e.toString()};
+ return new String[]{Messages.XMLUtilities_SAXExceptionMessage+":0:0",e.toString()}; //$NON-NLS-1$
}
}
return h.errors.toArray(new String[0]);
@@ -262,8 +263,8 @@
serialize(element, new BufferedWriter(fw));
fw.close();
}
- static final String ENCODING = "encoding=\"";
- static final String UTF8 = "UTF-8";
+ static final String ENCODING = "encoding=\""; //$NON-NLS-1$
+ static final String UTF8 = "UTF-8"; //$NON-NLS-1$
public static String getEncoding(String body) {
int i = body.indexOf(ENCODING);
@@ -280,7 +281,7 @@
}
public static OutputFormat createOutputFormat(String encoding) {
OutputFormat format = new OutputFormat(Method.XML, encoding == null || encoding.length() == 0?null:encoding, true);
- format.setLineSeparator(System.getProperty("line.separator", LineSeparator.Web));
+ format.setLineSeparator(System.getProperty("line.separator", LineSeparator.Web)); //$NON-NLS-1$
format.setIndent(1);
return format;
}
@@ -373,17 +374,17 @@
public static final void setCDATA(Element element, String data) {
element.appendChild(element.getOwnerDocument().createCDATASection(
- data!=null?data:""));
+ data!=null?data:"")); //$NON-NLS-1$
}
public static final void setText(Element element, String data) {
element.appendChild(element.getOwnerDocument().createTextNode(
- data!=null?data:""));
+ data!=null?data:"")); //$NON-NLS-1$
}
public static final void setComment(Element element, String data) {
Comment comm = element.getOwnerDocument().createComment(
- data!=null?data:"");
+ data!=null?data:""); //$NON-NLS-1$
element.getParentNode().insertBefore(comm, element);
}
Added: trunk/common/plugins/org.jboss.tools.common.el.core/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/.settings/org.eclipse.jdt.core.prefs (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/.settings/org.eclipse.jdt.core.prefs 2009-05-27 06:24:07 UTC (rev 15544)
@@ -0,0 +1 @@
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Activator.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Activator.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Activator.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -20,7 +20,7 @@
public class Activator extends BaseUIPlugin {
// The plug-in ID
- public static final String PLUGIN_ID = "org.jboss.tools.common.el";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.el"; //$NON-NLS-1$
// The shared instance
private static Activator plugin;
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ELReferenceList.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ELReferenceList.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/ELReferenceList.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -19,7 +19,7 @@
public class ELReferenceList extends ResourceReferenceList {
/** The PROPERT y_ NAME. */
- private static QualifiedName PROPERTY_NAME = new QualifiedName("", "org.jboss.tools.vpe.editor.css.ELReference");
+ private static QualifiedName PROPERTY_NAME = new QualifiedName("", "org.jboss.tools.vpe.editor.css.ELReference"); //$NON-NLS-1$ //$NON-NLS-2$
/** The instance. */
static ELReferenceList instance = new ELReferenceList();
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/GlobalELReferenceList.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/GlobalELReferenceList.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/GlobalELReferenceList.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -20,7 +20,7 @@
*/
public class GlobalELReferenceList extends ResourceReferenceList {
/** The PROPERT y_ NAME. */
- private static QualifiedName PROPERTY_NAME = new QualifiedName("", "org.jboss.tools.vpe.editor.css.GlobalELReference");
+ private static QualifiedName PROPERTY_NAME = new QualifiedName("", "org.jboss.tools.vpe.editor.css.GlobalELReference"); //$NON-NLS-1$ //$NON-NLS-2$
/** The instance. */
private static GlobalELReferenceList instance = new GlobalELReferenceList();
Added: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Messages.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Messages.java (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/Messages.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -0,0 +1,32 @@
+package org.jboss.tools.common.el.core;
+
+import org.eclipse.osgi.util.NLS;
+
+public class Messages extends NLS {
+ private static final String BUNDLE_NAME = "org.jboss.tools.common.el.core.messages"; //$NON-NLS-1$
+ public static String CallRule_ExpectingCommaOrRParen;
+ public static String CallRule_ExpectingRBrace;
+ public static String CallRule_ExpectingRBracket;
+ public static String CallRule_ExpectingRParen;
+ public static String CallRule_UnexpectedLParen;
+ public static String ExpressionRule_CannotStartWithBinaryOp;
+ public static String ExpressionRule_CannotStartWithInstanceof;
+ public static String ExpressionRule_ExpectingExpression;
+ public static String ExpressionRule_ExpectingJavaName;
+ public static String JavaNameTokenDescription_Name;
+ public static String OperationRule_ExpectingRBrace;
+ public static String OperationRule_ExpectingRBracket;
+ public static String OperationRule_ExpectingRParen;
+ public static String OperationTokenDescription_Name;
+ public static String PrimitiveValueTokenDescription_ArgMustResolveToIntegerOrString;
+ public static String PrimitiveValueTokenDescription_Name;
+ public static String StringTokenDescription_Name;
+ public static String WhiteSpaceTokenDescription_Name;
+ static {
+ // initialize resource bundle
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+
+ private Messages() {
+ }
+}
Added: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/messages.properties
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/messages.properties (rev 0)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/messages.properties 2009-05-27 06:24:07 UTC (rev 15544)
@@ -0,0 +1,18 @@
+CallRule_ExpectingCommaOrRParen=Expecting ',' or ')'
+CallRule_ExpectingRBrace=Expecting '}'
+CallRule_ExpectingRBracket=Expecting ']'
+CallRule_ExpectingRParen=Expecting ')'
+CallRule_UnexpectedLParen=Unexpected symbol '('
+ExpressionRule_CannotStartWithBinaryOp=Expression cannot start with binary operator.
+ExpressionRule_CannotStartWithInstanceof=Expression cannot start with instanceof.
+ExpressionRule_ExpectingExpression=Expecting expression
+ExpressionRule_ExpectingJavaName=Expecting Java method or property name
+JavaNameTokenDescription_Name=NAME
+OperationRule_ExpectingRBrace=Expecting '}'
+OperationRule_ExpectingRBracket=Expecting ']'
+OperationRule_ExpectingRParen=Expecting ')'
+OperationTokenDescription_Name=Operator
+PrimitiveValueTokenDescription_ArgMustResolveToIntegerOrString=Argument must resolve to integer or string.
+PrimitiveValueTokenDescription_Name=Primitive
+StringTokenDescription_Name=String
+WhiteSpaceTokenDescription_Name=Whitespace
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/Tokenizer.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/Tokenizer.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/Tokenizer.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -60,7 +60,7 @@
for (int i = 0; i < ds.length; i++) {
int type = ds[i].getType();
if(tokenDescriptions.containsKey(type)) {
- throw new IllegalArgumentException("Token type " + type + " is not unique.");
+ throw new IllegalArgumentException("Token type " + type + " is not unique."); //$NON-NLS-1$ //$NON-NLS-2$
}
tokenDescriptions.put(type, ds[i]);
}
@@ -93,7 +93,7 @@
this.sourceString = sourceString;
errors.clear();
index = initialOffset;
- start = new LexicalToken(initialOffset, 0, "", -1000);
+ start = new LexicalToken(initialOffset, 0, "", -1000); //$NON-NLS-1$
last = start;
state = BasicStates.STATE_EXPECTING_EL;
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/TokenizerFactory.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/TokenizerFactory.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/parser/TokenizerFactory.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -106,7 +106,7 @@
}
public static void main(String[] args) {
- String text = "ioioio#{a(1.2e1i) + b c + d}ioioio#{0}";
+ String text = "ioioio#{a(1.2e1i) + b c + d}ioioio#{0}"; //$NON-NLS-1$
//"#{a[b()['l'].j]}";
//"#{g11.g12.y13} #{#{ #{a14.b15(x.t.u(uu.ii[9], j)).b16(m17(v18(i19[2]).u20).)+ a21(c.).b.}";
//"#{not a.b(x,y) + s.h((6 != -8) & (7 + -iy88.g[9].h(7 div 8).i.j)+(8) ? 4 : 7,'p', a.b.c.d[null])}";
@@ -117,28 +117,28 @@
while(ti != null) {
int type = ti.getType();
- System.out.println(type + ":" + ti.getText() + ":");
+ System.out.println(type + ":" + ti.getText() + ":"); //$NON-NLS-1$ //$NON-NLS-2$
ti = ti.getNextToken();
}
List<SyntaxError> errors = t.getErrors();
for (SyntaxError e: errors) {
- System.out.println("state=" + e.getState() + " position=" + e.getPosition() + " problem=" + e.getProblem());
+ System.out.println("state=" + e.getState() + " position=" + e.getPosition() + " problem=" + e.getProblem()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
ELParser parser = ELParserUtil.getJbossFactory().createParser();
ELModel model = parser.parse(text, 0, 90);
System.out.println(model);
ELExpression expr = model.getInstances().get(0).getExpression();
- System.out.println("Expression=" + expr);
+ System.out.println("Expression=" + expr); //$NON-NLS-1$
List<ELInvocationExpression> is = expr.getInvocations();
- System.out.println("Invocations:");
+ System.out.println("Invocations:"); //$NON-NLS-1$
for (ELInvocationExpression i : is) {
System.out.println(i);
}
int off = 8;
ELExpression expr1 = ELUtil.findExpression(model, off);
- System.out.println("Expression at " + off + ": " + expr1);
+ System.out.println("Expression at " + off + ": " + expr1); //$NON-NLS-1$ //$NON-NLS-2$
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELResolverFactoryManager.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELResolverFactoryManager.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ELResolverFactoryManager.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -64,22 +64,22 @@
}
Set<ELResolver> resolverSet = new HashSet<ELResolver>();
IExtensionRegistry registry = Platform.getExtensionRegistry();
- IExtensionPoint extensionPoint = registry.getExtensionPoint("org.jboss.tools.common.el.core.elResolver"); //$NON-NLS-N$1
+ IExtensionPoint extensionPoint = registry.getExtensionPoint("org.jboss.tools.common.el.core.elResolver"); //$NON-NLS-1$
IExtension[] extensions = extensionPoint.getExtensions();
for (int i=0; i<extensions.length; i++) {
IExtension extension = extensions[i];
IConfigurationElement[] elements = extension.getConfigurationElements();
for(int j=0; j<elements.length; j++) {
- IConfigurationElement[] natures = elements[i].getChildren("project-nature"); //$NON-NLS-N$1
+ IConfigurationElement[] natures = elements[i].getChildren("project-nature"); //$NON-NLS-1$
for (int k = 0; k < natures.length; k++) {
- String natureId = natures[k].getAttribute("id"); //$NON-NLS-N$1
+ String natureId = natures[k].getAttribute("id"); //$NON-NLS-1$
try {
if(project.hasNature(natureId)) {
- Object resolver = natures[k].createExecutableExtension("resolver-class"); //$NON-NLS-N$1
+ Object resolver = natures[k].createExecutableExtension("resolver-class"); //$NON-NLS-1$
if(resolver instanceof ELResolver) {
resolverSet.add((ELResolver)resolver);
} else {
- Activator.getPluginLog().logError(resolver.getClass().getName() + " must be instance of org.jboss.tools.common.el.core.resolver.ELResolver");
+ Activator.getPluginLog().logError(resolver.getClass().getName() + " must be instance of org.jboss.tools.common.el.core.resolver.ELResolver"); //$NON-NLS-1$
}
}
} catch (InvalidRegistryObjectException e) {
@@ -88,17 +88,17 @@
Activator.getPluginLog().logError(e);
}
}
- IConfigurationElement[] factories = elements[i].getChildren("factory"); //$NON-NLS-N$1
+ IConfigurationElement[] factories = elements[i].getChildren("factory"); //$NON-NLS-1$
for (int k = 0; k < factories.length; k++) {
try {
- Object factory = factories[k].createExecutableExtension("class"); //$NON-NLS-N$1
+ Object factory = factories[k].createExecutableExtension("class"); //$NON-NLS-1$
if(factory instanceof ELResolverFactory) {
ELResolver resolver = ((ELResolverFactory)factory).createResolver(resource);
if(resolver!=null) {
resolverSet.add(resolver);
}
} else {
- Activator.getPluginLog().logError(factory.getClass().getName() + " must be instance of org.jboss.tools.common.el.core.resolver.ELResolverFactory");
+ Activator.getPluginLog().logError(factory.getClass().getName() + " must be instance of org.jboss.tools.common.el.core.resolver.ELResolverFactory"); //$NON-NLS-1$
}
} catch (CoreException e) {
Activator.getPluginLog().logError(e);
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ElVarSearcher.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ElVarSearcher.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/ElVarSearcher.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -35,8 +35,8 @@
*/
public class ElVarSearcher {
- private final static String VAR_ATTRIBUTE_NAME = "var";
- private final static String VALUE_ATTRIBUTE_NAME = "value";
+ private final static String VAR_ATTRIBUTE_NAME = "var"; //$NON-NLS-1$
+ private final static String VALUE_ATTRIBUTE_NAME = "value"; //$NON-NLS-1$
private IFile file;
private ELCompletionEngine engine;
@@ -219,7 +219,7 @@
declLength = varNameEnd - varNameStart;
}
var = var.trim();
- if(!"".equals(var)) {
+ if(!"".equals(var)) { //$NON-NLS-1$
String value = element.getAttribute(VALUE_ATTRIBUTE_NAME);
if(value!=null) {
value = value.trim();
@@ -247,9 +247,9 @@
ArrayList<Var> parentVars = new ArrayList<Var>();
for (Var var : vars) {
ELExpression token = var.getElToken();
- if(token!=null && !token.getText().endsWith(".")) {
+ if(token!=null && !token.getText().endsWith(".")) { //$NON-NLS-1$
String varName = var.getName();
- if(el.equals(varName) || el.startsWith(varName.trim()+".")) {
+ if(el.equals(varName) || el.startsWith(varName.trim()+".")) { //$NON-NLS-1$
if(var.getElToken()!=null && initializeNestedVars) {
Var parentVar = findVarForEl(var.getElToken().getText(), parentVars, true);
if(parentVar!=null) {
@@ -267,7 +267,7 @@
}
if(resolvedToken!=null) {
String oldText = var.getElToken().getText();
- String newValue = "#{" + resolvedToken.getText() + oldText.substring(parentVar.getName().length()) + "}";
+ String newValue = "#{" + resolvedToken.getText() + oldText.substring(parentVar.getName().length()) + "}"; //$NON-NLS-1$ //$NON-NLS-2$
var.value = newValue;
var.elToken = var.parseEl(newValue);
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/TypeInfoCollector.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -291,7 +291,7 @@
}
public boolean isJavaLangObject() {
- return "java.lang.Object".equals(getDeclaringTypeQualifiedName());
+ return "java.lang.Object".equals(getDeclaringTypeQualifiedName()); //$NON-NLS-1$
}
public MemberInfo getParentMember() {
@@ -590,11 +590,11 @@
return false;
}
- return (((getName().startsWith("get") && !getName().equals("get")) || getName().startsWith("is")) && getNumberOfParameters() == 0);
+ return (((getName().startsWith("get") && !getName().equals("get")) || getName().startsWith("is")) && getNumberOfParameters() == 0); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
public boolean isSetter() {
- return ((getName().startsWith("set") && !getName().equals("set")) && getNumberOfParameters() == 1);
+ return ((getName().startsWith("set") && !getName().equals("set")) && getNumberOfParameters() == 1); //$NON-NLS-1$ //$NON-NLS-2$
}
public List<String> getAsPresentedStrings() {
@@ -764,12 +764,12 @@
}
boolean isDataModelObject(IType type) throws JavaModelException {
- return isInstanceofType(type, "javax.faces.model.DataModel");
+ return isInstanceofType(type, "javax.faces.model.DataModel"); //$NON-NLS-1$
}
public static boolean isResourceBundle(IType type) {
try {
- return isInstanceofType(type, "java.util.ResourceBundle");
+ return isInstanceofType(type, "java.util.ResourceBundle"); //$NON-NLS-1$
} catch (JavaModelException e) {
return false;
}
@@ -782,7 +782,7 @@
}
IType type = mbr.getMemberType();
if(type!=null) {
- return isInstanceofType(type, "java.util.Map") || isInstanceofType(type, "java.util.Collection");
+ return isInstanceofType(type, "java.util.Map") || isInstanceofType(type, "java.util.Collection"); //$NON-NLS-1$ //$NON-NLS-2$
}
return false;
} catch (JavaModelException e) {
@@ -844,10 +844,10 @@
void addInfoForDataModelVariable() {
fMethods.add(new MethodInfo(fType,
fType.getFullyQualifiedName(),
- "getRowCount", Modifier.PUBLIC,
+ "getRowCount", Modifier.PUBLIC, //$NON-NLS-1$
new String[0],
new String[0],
- "int",
+ "int", //$NON-NLS-1$
fTypeInfo,
fTypeInfo,
false));
@@ -856,19 +856,19 @@
void addInfoForDataModelObject() {
fMethods.add(new MethodInfo(fType,
fType.getFullyQualifiedName(),
- "size", Modifier.PUBLIC,
+ "size", Modifier.PUBLIC, //$NON-NLS-1$
new String[0],
new String[0],
- "int",
+ "int", //$NON-NLS-1$
fTypeInfo,
fTypeInfo,
false));
fMethods.add(new MethodInfo(fType,
fType.getFullyQualifiedName(),
- "isEmpty", Modifier.PUBLIC,
+ "isEmpty", Modifier.PUBLIC, //$NON-NLS-1$
new String[0],
new String[0],
- "boolean",
+ "boolean", //$NON-NLS-1$
fTypeInfo,
fTypeInfo,
false));
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/Var.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/Var.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/core/resolver/Var.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -47,7 +47,7 @@
}
ELExpression parseEl(String el) {
- if(el.length()>3 && el.startsWith("#{") && el.endsWith("}")) {
+ if(el.length()>3 && el.startsWith("#{") && el.endsWith("}")) { //$NON-NLS-1$ //$NON-NLS-2$
ELParser parser = factory.createParser();
ELModel model = parser.parse(el);
if(model == null || model.getSyntaxErrors().size() > 0) return null;
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentExpressionImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentExpressionImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentExpressionImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -42,7 +42,7 @@
}
public String toString() {
- return super.toString() + ((argument != null) ? argument.toString() : "");
+ return super.toString() + ((argument != null) ? argument.toString() : ""); //$NON-NLS-1$
}
public ELObjectType getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELArgumentImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -52,7 +52,7 @@
if(child instanceof ELExpressionImpl) {
setArgument((ELExpressionImpl)child);
} else {
- throw new IllegalArgumentException("EL argument can have only EL expression as its child.");
+ throw new IllegalArgumentException("EL argument can have only EL expression as its child."); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELComplexExpressionImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELComplexExpressionImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELComplexExpressionImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -57,7 +57,7 @@
if(child instanceof ELExpressionImpl) {
setExpression((ELExpressionImpl)child);
} else {
- throw new IllegalArgumentException("EL instance can have only EL expression as child.");
+ throw new IllegalArgumentException("EL instance can have only EL expression as child."); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInstanceImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInstanceImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInstanceImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -62,7 +62,7 @@
if(child instanceof ELExpressionImpl) {
setExpression((ELExpressionImpl)child);
} else {
- throw new IllegalArgumentException("EL instance can have only EL expression as child.");
+ throw new IllegalArgumentException("EL instance can have only EL expression as child."); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInvocationExpressionImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInvocationExpressionImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELInvocationExpressionImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -46,7 +46,7 @@
}
public String toString() {
- return left != null ? left.toString() : "";
+ return left != null ? left.toString() : ""; //$NON-NLS-1$
}
public void collectInvocations(List<ELInvocationExpression> list) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMethodInvocationImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMethodInvocationImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMethodInvocationImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -46,7 +46,7 @@
}
public String toString() {
- return super.toString() + ((parameters != null) ? parameters.toString() : "");
+ return super.toString() + ((parameters != null) ? parameters.toString() : ""); //$NON-NLS-1$
}
public ELObjectType getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELModelImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELModelImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELModelImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -51,7 +51,7 @@
if(child instanceof ELInstanceImpl) {
addInstance((ELInstanceImpl)child);
} else {
- throw new IllegalArgumentException("EL root can have onle ELInstances as its children.");
+ throw new IllegalArgumentException("EL root can have only ELInstances as its children."); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMultiExpressionImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMultiExpressionImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELMultiExpressionImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -44,13 +44,13 @@
} else if(child instanceof ELOperatorImpl) {
addOperator((ELOperatorImpl)child);
} else {
- throw new IllegalArgumentException("EL instance can have only EL expression as child.");
+ throw new IllegalArgumentException("EL instance can have only EL expression as child."); //$NON-NLS-1$
}
}
public void addExpression(ELExpressionImpl expression) {
if(expressions.size() > operators.size()) {
- throw new IllegalArgumentException("Expecting operator");
+ throw new IllegalArgumentException("Expecting operator"); //$NON-NLS-1$
}
super.addChild(expression);
expressions.add(expression);
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELOperatorImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELOperatorImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELOperatorImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -25,7 +25,7 @@
}
public String toString() {
- return getFirstToken() != null ? getFirstToken().getText() : "";
+ return getFirstToken() != null ? getFirstToken().getText() : ""; //$NON-NLS-1$
}
public ELObjectType getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELParametersImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELParametersImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELParametersImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -56,7 +56,7 @@
if(child instanceof ELExpressionImpl) {
addParameter((ELExpressionImpl)child);
} else {
- throw new IllegalArgumentException("EL parameters can have only EL expressions as its children.");
+ throw new IllegalArgumentException("EL parameters can have only EL expressions as its children."); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELPropertyInvocationImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELPropertyInvocationImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELPropertyInvocationImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -56,12 +56,12 @@
}
String p = ((ELPropertyInvocationImpl)left).getQualifiedName();
if(p == null) return null;
- return p + "." + name.getText();
+ return p + "." + name.getText(); //$NON-NLS-1$
}
public String toString() {
- return super.toString() + (dot != null ? dot.getText() : "")
- + (name != null ? name.getText() : "");
+ return super.toString() + (dot != null ? dot.getText() : "") //$NON-NLS-1$
+ + (name != null ? name.getText() : ""); //$NON-NLS-1$
}
public ELObjectType getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELValueExpressionImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELValueExpressionImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/model/ELValueExpressionImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -24,7 +24,7 @@
}
public String toString() {
- return getFirstToken() != null ? getFirstToken().getText() : "";
+ return getFirstToken() != null ? getFirstToken().getText() : ""; //$NON-NLS-1$
}
public ELObjectType getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/ELParserImpl.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/ELParserImpl.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/ELParserImpl.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -52,7 +52,7 @@
public ELModelImpl parse(LexicalToken start) {
if(current != null) {
- throw new RuntimeException("Cannot reuse parser while it is running.");
+ throw new RuntimeException("Cannot reuse parser while it is running."); //$NON-NLS-1$
}
try {
ELModelImpl model = new ELModelImpl();
@@ -91,7 +91,7 @@
//create fake invocation expression
expression = new ELPropertyInvocationImpl();
int p = current != null ? current.getStart() : instance.getEndPosition();
- LexicalToken t = new LexicalToken(p, 0, "", JavaNameTokenDescription.JAVA_NAME);
+ LexicalToken t = new LexicalToken(p, 0, "", JavaNameTokenDescription.JAVA_NAME); //$NON-NLS-1$
expression.setFirstToken(t);
expression.setLastToken(t);
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/CallRule.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/CallRule.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/CallRule.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.rule;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.IRule;
import org.jboss.tools.common.el.core.parser.Tokenizer;
import org.jboss.tools.common.el.internal.core.parser.token.ArgEndTokenDescription;
@@ -98,18 +99,18 @@
public String getProblem(int state, Tokenizer tokenizer) {
if(ParamUtil.isMethodParamContext(tokenizer.getContext())) {
- return "Expecting ',' or ')'";
+ return Messages.CallRule_ExpectingCommaOrRParen;
} else if(ParamUtil.isComplexExpressionContext(tokenizer.getContext())) {
- return "Expecting ')'";
+ return Messages.CallRule_ExpectingRParen;
} else if(ParamUtil.isArgContext(tokenizer.getContext())) {
- return "Expecting ']'";
+ return Messages.CallRule_ExpectingRBracket;
}
if(state == STATE_EXPECTING_CALL_AFTER_METHOD) {
if(ParamStartTokenDescription.INSTANCE.isStart(tokenizer, tokenizer.getCurrentIndex())) {
- return "Unexpected symbol '('";
+ return Messages.CallRule_UnexpectedLParen;
}
}
- return "Expecting '}'";
+ return Messages.CallRule_ExpectingRBrace;
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/ExpressionRule.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/ExpressionRule.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/ExpressionRule.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.rule;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.IRule;
import org.jboss.tools.common.el.core.parser.Tokenizer;
import org.jboss.tools.common.el.internal.core.parser.token.ArgEndTokenDescription;
@@ -127,15 +128,15 @@
public String getProblem(int state, Tokenizer tokenizer) {
if(state == STATE_EXPECTING_NAME) {
- return "Expecting Java method or property name";
+ return Messages.ExpressionRule_ExpectingJavaName;
} else {
if(OperationTokenDescription.INSTANCE.isStart(tokenizer, tokenizer.getCurrentIndex())) {
- return "Expression cannot start with binary operator.";
+ return Messages.ExpressionRule_CannotStartWithBinaryOp;
}
if(JavaNameTokenDescription.INSTANCEOF_INSTANCE.isStart(tokenizer, tokenizer.getCurrentIndex())) {
- return "Expression cannot start with instanceof.";
+ return Messages.ExpressionRule_CannotStartWithInstanceof;
}
- return "Expecting expression";
+ return Messages.ExpressionRule_ExpectingExpression;
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/OperationRule.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/OperationRule.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/rule/OperationRule.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.rule;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.IRule;
import org.jboss.tools.common.el.core.parser.Tokenizer;
import org.jboss.tools.common.el.internal.core.parser.token.ArgEndTokenDescription;
@@ -72,13 +73,13 @@
public String getProblem(int state, Tokenizer tokenizer) {
if(ParamUtil.isMethodParamContext(tokenizer.getContext())) {
- return "Expecting ')'";
+ return Messages.OperationRule_ExpectingRParen;
} else if(ParamUtil.isComplexExpressionContext(tokenizer.getContext())) {
- return "Expecting ')'";
+ return Messages.OperationRule_ExpectingRParen;
} else if(ParamUtil.isArgContext(tokenizer.getContext())) {
- return "Expecting ']'";
+ return Messages.OperationRule_ExpectingRBracket;
}
- return "Expecting '}'";
+ return Messages.OperationRule_ExpectingRBrace;
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgEndTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgEndTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgEndTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -29,7 +29,7 @@
*/
public class ArgEndTokenDescription extends ConstantTokenDescription {
public static final int ARG_END = 11;
- public static final String CLOSE = "]";
+ public static final String CLOSE = "]"; //$NON-NLS-1$
public static ArgEndTokenDescription INSTANCE = new ArgEndTokenDescription();
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgStartTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgStartTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ArgStartTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -19,7 +19,7 @@
*/
public class ArgStartTokenDescription extends ConstantTokenDescription {
public static final int ARG_START = 10;
- public static final String OPEN = "[";
+ public static final String OPEN = "["; //$NON-NLS-1$
public static ArgStartTokenDescription INSTANCE = new ArgStartTokenDescription();
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/CommaTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/CommaTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/CommaTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -23,7 +23,7 @@
public static CommaTokenDescription INSTANCE = new CommaTokenDescription();
public CommaTokenDescription () {
- super(",", COMMA);
+ super(",", COMMA); //$NON-NLS-1$
}
public boolean isStart(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/DotTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/DotTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/DotTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -21,7 +21,7 @@
public static DotTokenDescription INSTANCE = new DotTokenDescription();
public DotTokenDescription () {
- super(".", DOT);
+ super(".", DOT); //$NON-NLS-1$
}
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/EndELTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/EndELTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/EndELTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -24,7 +24,7 @@
public static EndELTokenDescription INSTANCE = new EndELTokenDescription();
public EndELTokenDescription () {
- super("}", END_EL);
+ super("}", END_EL); //$NON-NLS-1$
}
public boolean isStart(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprEndTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprEndTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprEndTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -23,7 +23,7 @@
public static ExprEndTokenDescription INSTANCE = new ExprEndTokenDescription();
public ExprEndTokenDescription () {
- super(")", EXPR_END);
+ super(")", EXPR_END); //$NON-NLS-1$
}
public boolean isStart(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprStartTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprStartTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ExprStartTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -23,7 +23,7 @@
public static ExprStartTokenDescription INSTANCE = new ExprStartTokenDescription();
public ExprStartTokenDescription () {
- super("(", EXPR_START);
+ super("(", EXPR_START); //$NON-NLS-1$
}
public boolean read(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/JavaNameTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/JavaNameTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/JavaNameTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.token;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.ITokenDescription;
import org.jboss.tools.common.el.core.parser.Tokenizer;
@@ -26,7 +27,7 @@
public static ConstantTokenDescription INSTANCEOF_INSTANCE = InstanceofTokenDescription.INSTANCE;
public String getName() {
- return "NAME";
+ return Messages.JavaNameTokenDescription_Name;
}
public int getType() {
@@ -65,11 +66,11 @@
public static InstanceofTokenDescription INSTANCE = new InstanceofTokenDescription();
private static final String[] OPS_2 = {
- "instanceof"
+ "instanceof" //$NON-NLS-1$
};
public InstanceofTokenDescription() {
- super("!", INSTANCEOF);
+ super("!", INSTANCEOF); //$NON-NLS-1$
}
public boolean isStart(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/OperationTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/OperationTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/OperationTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.token;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.ITokenDescription;
import org.jboss.tools.common.el.core.parser.Tokenizer;
@@ -22,18 +23,18 @@
public static final int OPERATION = 12;
static String[] OPS = {
- "&&", "||", "==", "!=", "<=", ">=",
- "+", "-", "*", "/", "&", "%", "|", "?" , ":", "^", "<", ">",
+ "&&", "||", "==", "!=", "<=", ">=", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$
+ "+", "-", "*", "/", "&", "%", "|", "?" , ":", "^", "<", ">", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$ //$NON-NLS-7$ //$NON-NLS-8$ //$NON-NLS-9$ //$NON-NLS-10$ //$NON-NLS-11$ //$NON-NLS-12$
};
private static final String[] OPS_2 = {
- "div", "and", "or", "not", "mod",
- "eq", "ne", "lt", "gt", "ge", "le",
+ "div", "and", "or", "not", "mod", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
+ "eq", "ne", "lt", "gt", "ge", "le", //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$ //$NON-NLS-6$
};
public static OperationTokenDescription INSTANCE = new OperationTokenDescription();
public String getName() {
- return "Operator";
+ return Messages.OperationTokenDescription_Name;
}
public int getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamEndTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamEndTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamEndTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -23,7 +23,7 @@
public static ParamEndTokenDescription INSTANCE = new ParamEndTokenDescription();
public ParamEndTokenDescription () {
- super(")", PARAM_END);
+ super(")", PARAM_END); //$NON-NLS-1$
}
public boolean isStart(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamStartTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamStartTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamStartTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -23,7 +23,7 @@
public static ParamStartTokenDescription INSTANCE = new ParamStartTokenDescription();
public ParamStartTokenDescription () {
- super("(", PARAM_START);
+ super("(", PARAM_START); //$NON-NLS-1$
}
public boolean read(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamUtil.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamUtil.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/ParamUtil.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -19,7 +19,7 @@
*
*/
public class ParamUtil {
- static String PARAM_HISTORY = "(_level";
+ static String PARAM_HISTORY = "(_level"; //$NON-NLS-1$
static class ParamHistory extends ArrayList<String>{
private static final long serialVersionUID = 1L;
@@ -40,17 +40,17 @@
public static boolean isMethodParamContext(Properties context) {
ParamHistory i = (ParamHistory)(context.get(PARAM_HISTORY));
- return i != null && i.size() > 0 && "params".equals(i.get(i.size() - 1));
+ return i != null && i.size() > 0 && "params".equals(i.get(i.size() - 1)); //$NON-NLS-1$
}
public static boolean isArgContext(Properties context) {
ParamHistory i = (ParamHistory)(context.get(PARAM_HISTORY));
- return i != null && i.size() > 0 && "arg".equals(i.get(i.size() - 1));
+ return i != null && i.size() > 0 && "arg".equals(i.get(i.size() - 1)); //$NON-NLS-1$
}
public static boolean isComplexExpressionContext(Properties context) {
- ParamHistory i = (ParamHistory)(context.get("(_level"));
- return i != null && i.size() > 0 && "expr".equals(i.get(i.size() - 1));
+ ParamHistory i = (ParamHistory)(context.get("(_level")); //$NON-NLS-1$
+ return i != null && i.size() > 0 && "expr".equals(i.get(i.size() - 1)); //$NON-NLS-1$
}
public static void closeCurrentParamContext(Properties context) {
@@ -61,18 +61,18 @@
}
public static void openMethodParamContext(Properties context) {
- ParamHistory i = (ParamHistory)(context.get("(_level"));
- i.add("params");
+ ParamHistory i = (ParamHistory)(context.get("(_level")); //$NON-NLS-1$
+ i.add("params"); //$NON-NLS-1$
}
public static void openComplexExpressionContext(Properties context) {
- ParamHistory i = (ParamHistory)(context.get("(_level"));
- i.add("expr");
+ ParamHistory i = (ParamHistory)(context.get("(_level")); //$NON-NLS-1$
+ i.add("expr"); //$NON-NLS-1$
}
public static void openArgContext(Properties context) {
- ParamHistory i = (ParamHistory)(context.get("(_level"));
- i.add("arg");
+ ParamHistory i = (ParamHistory)(context.get("(_level")); //$NON-NLS-1$
+ i.add("arg"); //$NON-NLS-1$
}
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/PrimitiveValueTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/PrimitiveValueTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/PrimitiveValueTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.token;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.ITokenDescription;
import org.jboss.tools.common.el.core.parser.SyntaxError;
import org.jboss.tools.common.el.core.parser.Tokenizer;
@@ -26,10 +27,10 @@
public static PrimitiveValueTokenDescription INSTANCE = new PrimitiveValueTokenDescription();
private static final String[] OPS_2 = {
- "null", "true", "false",
+ "null", "true", "false", //$NON-NLS-1$//$NON-NLS-2$//$NON-NLS-3$
};
public String getName() {
- return "Primitive";
+ return Messages.PrimitiveValueTokenDescription_Name;
}
public int getType() {
@@ -79,12 +80,12 @@
return true;
}
- static String TYPE_CHAR = "lLfFdD";
+ static String TYPE_CHAR = "lLfFdD"; //$NON-NLS-1$
private boolean readNumber(Tokenizer tokenizer, int offset) {
int i = offset;
int dotCount = 1;
int dotOffset = -1;
- if(tokenizer.startsWith("0x")) {
+ if(tokenizer.startsWith("0x")) { //$NON-NLS-1$
i += 2;
dotCount = 0;
}
@@ -140,7 +141,7 @@
&& tokenizer.getLastToken().getType() == ArgStartTokenDescription.ARG_START
&& dotCount < 1) {
SyntaxError error = new SyntaxError(dotOffset, BasicStates.STATE_EXPECTING_ARG);
- error.setProblem("Argument must resolve to integer or string.");
+ error.setProblem(Messages.PrimitiveValueTokenDescription_ArgMustResolveToIntegerOrString);
tokenizer.addSyntaxError(error);
}
tokenizer.addToken(getType(), offset, i);
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StartELTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StartELTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StartELTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -23,8 +23,8 @@
public static StartELTokenDescription INSTANCE = new StartELTokenDescription();
public StartELTokenDescription () {
- super("#{", START_EL);
- addContent("${");
+ super("#{", START_EL); //$NON-NLS-1$
+ addContent("${"); //$NON-NLS-1$
}
public boolean read(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StringTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StringTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/StringTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.token;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.ITokenDescription;
import org.jboss.tools.common.el.core.parser.Tokenizer;
@@ -24,7 +25,7 @@
public static StringTokenDescription INSTANCE = new StringTokenDescription();
public String getName() {
- return "String";
+ return Messages.StringTokenDescription_Name;
}
public int getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/UnaryTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/UnaryTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/UnaryTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -23,15 +23,15 @@
public static UnaryTokenDescription INSTANCE = new UnaryTokenDescription();
private static final String[] OPS_2 = {
- "not", "empty"
+ "not", "empty" //$NON-NLS-1$//$NON-NLS-2$
};
public UnaryTokenDescription() {
- super("!", UNARY);
- addContent("--");
- addContent("++");
- addContent("+");
- addContent("-");
+ super("!", UNARY); //$NON-NLS-1$
+ addContent("--"); //$NON-NLS-1$
+ addContent("++"); //$NON-NLS-1$
+ addContent("+"); //$NON-NLS-1$
+ addContent("-"); //$NON-NLS-1$
}
public boolean isStart(Tokenizer tokenizer, int offset) {
Modified: trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/WhiteSpaceTokenDescription.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/WhiteSpaceTokenDescription.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.core/src/org/jboss/tools/common/el/internal/core/parser/token/WhiteSpaceTokenDescription.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -10,6 +10,7 @@
******************************************************************************/
package org.jboss.tools.common.el.internal.core.parser.token;
+import org.jboss.tools.common.el.core.Messages;
import org.jboss.tools.common.el.core.parser.ITokenDescription;
import org.jboss.tools.common.el.core.parser.Tokenizer;
@@ -24,7 +25,7 @@
public static WhiteSpaceTokenDescription INSTANCE = new WhiteSpaceTokenDescription();
public String getName() {
- return "Whitespace";
+ return Messages.WhiteSpaceTokenDescription_Name;
}
public int getType() {
Modified: trunk/common/plugins/org.jboss.tools.common.el.ui/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.ui/.settings/org.eclipse.jdt.core.prefs 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.ui/.settings/org.eclipse.jdt.core.prefs 2009-05-27 06:24:07 UTC (rev 15544)
@@ -4,4 +4,5 @@
org.eclipse.jdt.core.compiler.compliance=1.5
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
org.eclipse.jdt.core.compiler.source=1.5
Modified: trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/Activator.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/Activator.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/Activator.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -20,7 +20,7 @@
public class Activator extends AbstractUIPlugin {
// The plug-in ID
- public static final String PLUGIN_ID = "org.jboss.tools.common.el.ui";
+ public static final String PLUGIN_ID = "org.jboss.tools.common.el.ui"; //$NON-NLS-1$
// The shared instance
private static Activator plugin;
Modified: trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/GlobalElVariablesComposite.java
===================================================================
--- trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/GlobalElVariablesComposite.java 2009-05-27 06:00:55 UTC (rev 15543)
+++ trunk/common/plugins/org.jboss.tools.common.el.ui/src/org/jboss/tools/common/el/ui/GlobalElVariablesComposite.java 2009-05-27 06:24:07 UTC (rev 15544)
@@ -33,7 +33,7 @@
*/
@Override
protected String createGroupLabel() {
- return "";
+ return ""; //$NON-NLS-1$
}
/**
@@ -49,7 +49,7 @@
*/
@Override
protected String getEntity() {
- return "VPEGlobalElReference";
+ return "VPEGlobalElReference"; //$NON-NLS-1$
}
/**
@@ -62,7 +62,7 @@
@Override
protected ResourceReference getDefaultResourceReference() {
- ResourceReference rf = new ResourceReference("", ResourceReference.GLOBAL_SCOPE);
+ ResourceReference rf = new ResourceReference("", ResourceReference.GLOBAL_SCOPE); //$NON-NLS-1$
rf.setGlobal(true);
return rf;
}
14 years, 11 months
JBoss Tools SVN: r15543 - in trunk: jmx/plugins/org.jboss.tools.jmx.ui/META-INF and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2009-05-27 02:00:55 -0400 (Wed, 27 May 2009)
New Revision: 15543
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF
trunk/jmx/plugins/org.jboss.tools.jmx.ui/META-INF/MANIFEST.MF
Log:
weird changes causing workspace to fail
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF 2009-05-27 01:04:00 UTC (rev 15542)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF 2009-05-27 06:00:55 UTC (rev 15543)
@@ -42,11 +42,11 @@
org.eclipse.search,
org.apache.ant,
org.jboss.ide.eclipse.as.core,
- org.eclipse.ui.navigator;bundle-version="3.3.100",
- org.eclipse.ui.views.log;bundle-version="1.0.0",
- org.jboss.tools.jmx.ui;bundle-version="0.2.2",
- org.jboss.tools.jmx.core;bundle-version="0.2.1",
- org.eclipse.jst.j2ee.core;bundle-version="1.1.0"
+ org.eclipse.ui.navigator,
+ org.eclipse.ui.views.log,
+ org.jboss.tools.jmx.ui,
+ org.jboss.tools.jmx.core,
+ org.eclipse.jst.j2ee.core
Eclipse-LazyStart: true
Export-Package: org.jboss.ide.eclipse.as.ui,
org.jboss.ide.eclipse.as.ui.dialogs,
Modified: trunk/jmx/plugins/org.jboss.tools.jmx.ui/META-INF/MANIFEST.MF
===================================================================
--- trunk/jmx/plugins/org.jboss.tools.jmx.ui/META-INF/MANIFEST.MF 2009-05-27 01:04:00 UTC (rev 15542)
+++ trunk/jmx/plugins/org.jboss.tools.jmx.ui/META-INF/MANIFEST.MF 2009-05-27 06:00:55 UTC (rev 15543)
@@ -1,7 +1,8 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %BundleName
-Bundle-SymbolicName: org.jboss.tools.jmx.ui;singleton:=trueBundle-Version: 1.0.1.qualifier
+Bundle-SymbolicName: org.jboss.tools.jmx.ui;singleton:=true
+Bundle-Version: 1.0.1.qualifier
Bundle-Activator: org.jboss.tools.jmx.ui.JMXUIActivator
Bundle-Vendor: %BundleProvider
Require-Bundle: org.eclipse.ui,
14 years, 11 months
JBoss Tools SVN: r15542 - trunk/jmx/releng/psfs.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2009-05-26 21:04:00 -0400 (Tue, 26 May 2009)
New Revision: 15542
Added:
trunk/jmx/releng/psfs/athena.psf
Removed:
trunk/jmx/releng/psfs/jmxAndAthena.psf
Log:
https://jira.jboss.org/jira/browse/JBDS-737 easier to maintain if file only contains athena stuff, not athena + JMX
Copied: trunk/jmx/releng/psfs/athena.psf (from rev 15541, trunk/jmx/releng/psfs/jmxAndAthena.psf)
===================================================================
--- trunk/jmx/releng/psfs/athena.psf (rev 0)
+++ trunk/jmx/releng/psfs/athena.psf 2009-05-27 01:04:00 UTC (rev 15542)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<psf version="2.0">
+<provider id="org.eclipse.team.cvs.core.cvsnature">
+<project reference="1.0,:pserver:anonymous@dev.eclipse.org:/cvsroot/technology,org.eclipse.dash/athena/org.eclipse.dash.commonbuilder/org.eclipse.dash.commonbuilder.releng,org.eclipse.dash.common.releng"/>
+<project reference="1.0,:pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse,org.eclipse.releng.basebuilder,org.eclipse.releng.basebuilder,R35_M6"/>
+</provider>
+</psf>
\ No newline at end of file
Property changes on: trunk/jmx/releng/psfs/athena.psf
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Deleted: trunk/jmx/releng/psfs/jmxAndAthena.psf
===================================================================
--- trunk/jmx/releng/psfs/jmxAndAthena.psf 2009-05-27 01:02:53 UTC (rev 15541)
+++ trunk/jmx/releng/psfs/jmxAndAthena.psf 2009-05-27 01:04:00 UTC (rev 15542)
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<psf version="2.0">
-<provider id="org.tigris.subversion.subclipse.core.svnnature">
-<project reference="0.9.3,svn://svn.jboss.org/repos/jbosstools/trunk/jmx/features/org.jboss.t..."/>
-<project reference="0.9.3,svn://svn.jboss.org/repos/jbosstools/trunk/jmx/features/org.jboss.t..."/>
-<project reference="0.9.3,svn://svn.jboss.org/repos/jbosstools/trunk/jmx/plugins/org.jboss.to..."/>
-<project reference="0.9.3,svn://svn.jboss.org/repos/jbosstools/trunk/jmx/plugins/org.jboss.to..."/>
-<project reference="0.9.3,svn://svn.jboss.org/repos/jbosstools/trunk/jmx/tests/org.jboss.tool..."/>
-<project reference="0.9.3,svn://svn.jboss.org/repos/jbosstools/trunk/jmx/tests/org.jboss.tool..."/>
-<project reference="0.9.3,svn://svn.jboss.org/repos/jbosstools/trunk/jmx/tests/org.jboss.tool..."/>
-</provider>
-<provider id="org.eclipse.team.cvs.core.cvsnature">
-<project reference="1.0,:pserver:anonymous@dev.eclipse.org:/cvsroot/technology,org.eclipse.dash/athena/org.eclipse.dash.commonbuilder/org.eclipse.dash.commonbuilder.releng,org.eclipse.dash.common.releng"/>
-<project reference="1.0,:pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse,org.eclipse.releng.basebuilder,org.eclipse.releng.basebuilder,R35_M6"/>
-</provider>
-</psf>
\ No newline at end of file
14 years, 11 months
JBoss Tools SVN: r15541 - in trunk/jmx/features/org.jboss.tools.jmx.feature: sourceTemplateFeature and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2009-05-26 21:02:53 -0400 (Tue, 26 May 2009)
New Revision: 15541
Added:
trunk/jmx/features/org.jboss.tools.jmx.feature/rootfiles/
trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/feature.properties
trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/license.html
Log:
https://jira.jboss.org/jira/browse/JBDS-737
Added: trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/feature.properties
===================================================================
--- trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/feature.properties (rev 0)
+++ trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/feature.properties 2009-05-27 01:02:53 UTC (rev 15541)
@@ -0,0 +1,21 @@
+# properties file for org.jboss.tools.jmx.source
+featureName=JMX Console Source
+featureProvider=JBoss, a division of Red Hat
+
+# "updateSiteName" property - label for the update site
+updateSiteName=JBossTools Update Site
+
+# "description" property - description of the feature
+description=eclipse-jmx is a JMX console which is used to manage Java applications through JMX and its RMI Connector. eclipse-jmx can be run from the Eclipse IDE.
+
+# "licenseURL" property - URL of the "Feature License"
+# do not translate value - just change to point to a locale-specific HTML page
+licenseURL=license.html
+
+# START NON-TRANSLATABLE
+# "license" property - text of the "Feature Update License"
+# should be plain text version of license agreement pointed to be "licenseURL"
+license=ECLIPSE FOUNDATION SOFTWARE USER AGREEMENT\nMarch 17, 2005\n\nUsage Of Content\n\nTHE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR\nOTHER MATERIALS FOR OPEN SOURCE PROJECTS (COLLECTIVELY "CONTENT").\nUSE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS\nAGREEMENT AND/OR THE TERMS AND CONDITIONS OF LICENSE AGREEMENTS OR\nNOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU\nAGREE THAT YOUR USE OF THE CONTENT IS GOVERNED BY THIS AGREEMENT\nAND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS\nOR NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE\nTERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND CONDITIONS\nOF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED\nBELOW, THEN YOU MAY NOT USE THE CONTENT.\n\nApplicable Licenses\n\nUnless otherwise indicated, all Content made available by the Eclipse Foundation\nis provided to you under the terms and conditio!
ns of the Eclipse Public\nLicense Version 1.0 ("EPL"). A copy of the EPL is provided with this\nContent and is also available at http\://www.eclipse.org/legal/epl-v10.html.\nFor purposes of the EPL, "Program" will mean the Content.\n\nContent includes, but is not limited to, source code, object code,\ndocumentation and other files maintained in the Eclipse.org CVS\nrepository ("Repository") in CVS modules ("Modules") and made available\nas downloadable archives ("Downloads").\n\n- Content may be structured and packaged into modules to facilitate delivering,\nextending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"),\nplug-in fragments ("Fragments"), and features ("Features").\n- Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java? ARchive)\nin a directory named "plugins".\n- A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material.\nEach Feature may be packaged as a sub-directory in a directory!
named "features".\nWithin a Feature, files named "feature.xml" may co
ntain a list of the names and version\nnumbers of the Plug-ins and/or Fragments associated with that Feature.\n- Features may also include other Features ("Included Features"). Within a Feature, files\nnamed "feature.xml" may contain a list of the names and version numbers of Included Features.\n\nFeatures may also include other Features ("Included Features"). Files named\n"feature.xml" may contain a list of the names and version numbers of\nIncluded Features.\n\nThe terms and conditions governing Plug-ins and Fragments should be\ncontained in files named "about.html" ("Abouts"). The terms and\nconditions governing Features and Included Features should be contained\nin files named "license.html" ("Feature Licenses"). Abouts and Feature\nLicenses may be located in any directory of a Download or Module\nincluding, but not limited to the following locations\:\n\n- The top-level (root) directory\n- Plug-in and Fragment directories\n- Inside Plug-ins and Fragments packaged as JAR!
s\n- Sub-directories of the directory named "src" of certain Plug-ins\n- Feature directories\n\nNote\: if a Feature made available by the Eclipse Foundation is installed using the\nEclipse Update Manager, you must agree to a license ("Feature Update\nLicense") during the installation process. If the Feature contains\nIncluded Features, the Feature Update License should either provide you\nwith the terms and conditions governing the Included Features or inform\nyou where you can locate them. Feature Update Licenses may be found in\nthe "license" property of files named "feature.properties". Such Abouts,\nFeature Licenses and Feature Update Licenses contain the terms and\nconditions (or references to such terms and conditions) that govern your\nuse of the associated Content in that directory.\n\nTHE ABOUTS, FEATURE LICENSES AND FEATURE UPDATE LICENSES MAY REFER\nTO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS.\nSOME OF THESE OTHER LICENSE AGREEMENTS MA!
Y INCLUDE (BUT ARE NOT LIMITED TO)\:\n\n- Common Public License Versio
n 1.0 (available at http\://www.eclipse.org/legal/cpl-v10.html)\n- Apache Software License 1.1 (available at http\://www.apache.org/licenses/LICENSE)\n- Apache Software License 2.0 (available at http\://www.apache.org/licenses/LICENSE-2.0)\n- IBM Public License 1.0 (available at http\://oss.software.ibm.com/developerworks/opensource/license10.html)\n- Metro Link Public License 1.00 (available at http\://www.opengroup.org/openmotif/supporters/metrolink/license.html)\n- Mozilla Public License Version 1.1 (available at http\://www.mozilla.org/MPL/MPL-1.1.html)\n\nIT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR\nTO USE OF THE CONTENT. If no About, Feature License or Feature Update License\nis provided, please contact the Eclipse Foundation to determine what terms and conditions\ngovern that particular Content.\n\nCryptography\n\nContent may contain encryption software. The country in which you are\ncurrently may have restrictions on the import, posse!
ssion, and use,\nand/or re-export to another country, of encryption software. BEFORE\nusing any encryption software, please check the country's laws,\nregulations and policies concerning the import, possession, or use,\nand re-export of encryption software, to see if this is permitted.\n\nJava and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.\n
+# END NON-TRANSLATABLE
+########### end of license property ##########################################
+
\ No newline at end of file
Property changes on: trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/feature.properties
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/license.html
===================================================================
--- trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/license.html (rev 0)
+++ trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/license.html 2009-05-27 01:02:53 UTC (rev 15541)
@@ -0,0 +1,79 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<html>
+<head>
+<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
+<title>Eclipse.org Software User Agreement</title>
+</head>
+
+<body lang="EN-US" link=blue vlink=purple>
+<h2>Eclipse Foundation Software User Agreement</h2>
+<p>March 17, 2005</p>
+
+<h3>Usage Of Content</h3>
+
+<p>THE ECLIPSE FOUNDATION MAKES AVAILABLE SOFTWARE, DOCUMENTATION, INFORMATION AND/OR OTHER MATERIALS FOR OPEN SOURCE PROJECTS
+ (COLLECTIVELY "CONTENT"). USE OF THE CONTENT IS GOVERNED BY THE TERMS AND CONDITIONS OF THIS AGREEMENT AND/OR THE TERMS AND
+ CONDITIONS OF LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW. BY USING THE CONTENT, YOU AGREE THAT YOUR USE
+ OF THE CONTENT IS GOVERNED BY THIS AGREEMENT AND/OR THE TERMS AND CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR
+ NOTICES INDICATED OR REFERENCED BELOW. IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS OF THIS AGREEMENT AND THE TERMS AND
+ CONDITIONS OF ANY APPLICABLE LICENSE AGREEMENTS OR NOTICES INDICATED OR REFERENCED BELOW, THEN YOU MAY NOT USE THE CONTENT.</p>
+
+<h3>Applicable Licenses</h3>
+
+<p>Unless otherwise indicated, all Content made available by the Eclipse Foundation is provided to you under the terms and conditions of the Eclipse Public License Version 1.0
+ ("EPL"). A copy of the EPL is provided with this Content and is also available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+ For purposes of the EPL, "Program" will mean the Content.</p>
+
+<p>Content includes, but is not limited to, source code, object code, documentation and other files maintained in the Eclipse.org CVS repository ("Repository") in CVS
+ modules ("Modules") and made available as downloadable archives ("Downloads").</p>
+
+<ul>
+ <li>Content may be structured and packaged into modules to facilitate delivering, extending, and upgrading the Content. Typical modules may include plug-ins ("Plug-ins"), plug-in fragments ("Fragments"), and features ("Features").</li>
+ <li>Each Plug-in or Fragment may be packaged as a sub-directory or JAR (Java™ ARchive) in a directory named "plugins".</li>
+ <li>A Feature is a bundle of one or more Plug-ins and/or Fragments and associated material. Each Feature may be packaged as a sub-directory in a directory named "features". Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of the Plug-ins
+ and/or Fragments associated with that Feature.</li>
+ <li>Features may also include other Features ("Included Features"). Within a Feature, files named "feature.xml" may contain a list of the names and version numbers of Included Features.</li>
+</ul>
+
+<p>The terms and conditions governing Plug-ins and Fragments should be contained in files named "about.html" ("Abouts"). The terms and conditions governing Features and
+Included Features should be contained in files named "license.html" ("Feature Licenses"). Abouts and Feature Licenses may be located in any directory of a Download or Module
+including, but not limited to the following locations:</p>
+
+<ul>
+ <li>The top-level (root) directory</li>
+ <li>Plug-in and Fragment directories</li>
+ <li>Inside Plug-ins and Fragments packaged as JARs</li>
+ <li>Sub-directories of the directory named "src" of certain Plug-ins</li>
+ <li>Feature directories</li>
+</ul>
+
+<p>Note: if a Feature made available by the Eclipse Foundation is installed using the Eclipse Update Manager, you must agree to a license ("Feature Update License") during the
+installation process. If the Feature contains Included Features, the Feature Update License should either provide you with the terms and conditions governing the Included Features or
+inform you where you can locate them. Feature Update Licenses may be found in the "license" property of files named "feature.properties" found within a Feature.
+Such Abouts, Feature Licenses, and Feature Update Licenses contain the terms and conditions (or references to such terms and conditions) that govern your use of the associated Content in
+that directory.</p>
+
+<p>THE ABOUTS, FEATURE LICENSES, AND FEATURE UPDATE LICENSES MAY REFER TO THE EPL OR OTHER LICENSE AGREEMENTS, NOTICES OR TERMS AND CONDITIONS. SOME OF THESE
+OTHER LICENSE AGREEMENTS MAY INCLUDE (BUT ARE NOT LIMITED TO):</p>
+
+<ul>
+ <li>Common Public License Version 1.0 (available at <a href="http://www.eclipse.org/legal/cpl-v10.html">http://www.eclipse.org/legal/cpl-v10.html</a>)</li>
+ <li>Apache Software License 1.1 (available at <a href="http://www.apache.org/licenses/LICENSE">http://www.apache.org/licenses/LICENSE</a>)</li>
+ <li>Apache Software License 2.0 (available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>)</li>
+ <li>IBM Public License 1.0 (available at <a href="http://oss.software.ibm.com/developerworks/opensource/license10.html">http://oss.software.ibm.com/developerworks/opensource/license10.html</a>)</li>
+ <li>Metro Link Public License 1.00 (available at <a href="http://www.opengroup.org/openmotif/supporters/metrolink/license.html">http://www.opengroup.org/openmotif/supporters/metrolink/license.html</a>)</li>
+ <li>Mozilla Public License Version 1.1 (available at <a href="http://www.mozilla.org/MPL/MPL-1.1.html">http://www.mozilla.org/MPL/MPL-1.1.html</a>)</li>
+</ul>
+
+<p>IT IS YOUR OBLIGATION TO READ AND ACCEPT ALL SUCH TERMS AND CONDITIONS PRIOR TO USE OF THE CONTENT. If no About, Feature License, or Feature Update License is provided, please
+contact the Eclipse Foundation to determine what terms and conditions govern that particular Content.</p>
+
+<h3>Cryptography</h3>
+
+<p>Content may contain encryption software. The country in which you are currently may have restrictions on the import, possession, and use, and/or re-export to
+ another country, of encryption software. BEFORE using any encryption software, please check the country's laws, regulations and policies concerning the import,
+ possession, or use, and re-export of encryption software, to see if this is permitted.</p>
+
+<small>Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both.</small>
+</body>
+</html>
Property changes on: trunk/jmx/features/org.jboss.tools.jmx.feature/sourceTemplateFeature/license.html
___________________________________________________________________
Name: svn:mime-type
+ text/plain
14 years, 11 months
JBoss Tools SVN: r15540 - trunk/jmx/features/org.jboss.tools.jmx.tests.feature.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2009-05-26 21:02:29 -0400 (Tue, 26 May 2009)
New Revision: 15540
Modified:
trunk/jmx/features/org.jboss.tools.jmx.tests.feature/build.properties
trunk/jmx/features/org.jboss.tools.jmx.tests.feature/feature.xml
Log:
https://jira.jboss.org/jira/browse/JBDS-737 add test source plugins
Modified: trunk/jmx/features/org.jboss.tools.jmx.tests.feature/build.properties
===================================================================
--- trunk/jmx/features/org.jboss.tools.jmx.tests.feature/build.properties 2009-05-27 01:02:01 UTC (rev 15539)
+++ trunk/jmx/features/org.jboss.tools.jmx.tests.feature/build.properties 2009-05-27 01:02:29 UTC (rev 15540)
@@ -1,5 +1,7 @@
bin.includes = feature.xml,\
feature.properties,\
license.html
-generate.plugin(a)org.jboss.tools.tests.source.feature=org.jboss.tools.tests.feature
+generate.plugin(a)org.jboss.tools.jmx.core.test.source=org.jboss.tools.jmx.core.test
+generate.plugin(a)org.jboss.tools.jmx.ui.test.source=org.jboss.tools.jmx.ui.test
+generate.plugin(a)org.jboss.tools.jmx.ui.test.interactive.source=org.jboss.tools.jmx.ui.test.interactive
root=rootfiles
\ No newline at end of file
Modified: trunk/jmx/features/org.jboss.tools.jmx.tests.feature/feature.xml
===================================================================
--- trunk/jmx/features/org.jboss.tools.jmx.tests.feature/feature.xml 2009-05-27 01:02:01 UTC (rev 15539)
+++ trunk/jmx/features/org.jboss.tools.jmx.tests.feature/feature.xml 2009-05-27 01:02:29 UTC (rev 15540)
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<feature
- id="org.jboss.tools.jmx.tests"
+ id="org.jboss.tools.jmx.tests.feature"
label="%featureName"
- version="0.2.2.qualifier"
+ version="1.0.1.qualifier"
provider-name="%featureProvider"
image="eclipse_update_120.jpg">
@@ -52,15 +52,33 @@
version="0.0.0"/>
<plugin
+ id="org.jboss.tools.jmx.core.test.source"
+ download-size="0"
+ install-size="0"
+ version="0.0.0"/>
+
+ <plugin
id="org.jboss.tools.jmx.ui.test"
download-size="0"
install-size="0"
version="0.0.0"/>
<plugin
+ id="org.jboss.tools.jmx.ui.test.source"
+ download-size="0"
+ install-size="0"
+ version="0.0.0"/>
+
+ <plugin
id="org.jboss.tools.jmx.ui.test.interactive"
download-size="0"
install-size="0"
version="0.0.0"/>
-
+
+ <plugin
+ id="org.jboss.tools.jmx.ui.test.interactive.source"
+ download-size="0"
+ install-size="0"
+ version="0.0.0"/>
+
</feature>
14 years, 11 months